|
User:Lorinda
From NeoWiki
Relatively new user of NeoOffice (beginning Spring 2006). Native English speaker but fairly fluent in French. Interested in assisting with translating the wiki into French, as well as helping to edit the English wiki as time permits. Part-time pastor and stay-at-home mom.
Provides this tip for creating a macro to automate the process of changing between languages:
- select some text, then click on the Record Macro button in the top buttonbar. (If there isn't one there, Click on the Tools menu choose Macros and then select Record Macro). A Stop Recording floating button will appear.
- Under the Format menu, choose Character and then choose the Font tab in the panel that comes up. In the Language dropdown, choose your first language, e.g. English (UK), and then click on OK.
- Now click on the Stop Recording floater – the Macro dialog will appear. Enter a meaningful name in the Macro Name field, top left, such as LangEnUK, and click on Save.
- Repeat the steps above, but choosing your second language, e.g. German (Germany), and assigning the second macro another name e.g. LangDeDE or whatever.
- Now to assign the keys: Under the Tools menu choose Configure... and then click on the Keyboard tab. Scroll down to the keystroke you want to assign, e.g. Cmd-shift-G for German (I know -D makes more sense, but that's already being used – though you can overwrite this assignation if you don't need a shortcut for right-to-left typing).
- In the Category panel bottom left, scroll down to NeoOffice BASIC, then click on the + to open the folder, then do the same with Standard within that folder, and click on Module1 within Standard. Then in the Function panel to its right, click on the macro you named, i.e. LangDeDE, then click on the Modify button above right to assign that macro to the keystroke you highlighted earlier.
- Repeat the above step with the second keystroke and the second macro, and then click on OK.
- 'tis done! Now when you select text and do cmd-shift-G, that text will be assigned German (Germany) language - ditto with cmd-shift-E and English (UK).
If you use more than two languages, you could write a more sophisticated macro with a list of language codes/numbers (the OOo BASIC uses numbers for language codes), so you could hit e.g. cmd-shift-L on the selected text and just enter a language code in a popup box and it would do the rest.
Edited by --Lorinda 11:23, 21 October 2006 (CDT) to add to the Wiki. For the original post on trinity, click here