Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Mail Systems
Eclipse Documentation

How To Guides
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Problem Solutions
Privacy Policy




OpenOffice Writer 3.x Guide
Previous Page Home Next Page

Example: Assigning macros to shortcut keys

A common use for assigning macros to shortcut keys is to enable quick and easy insertion of special characters. This example shows how to st up keyboard shortcuts for inserting en-dashes and em-dashes.

First, you need to record a macro for inserting each type of dash. Then, you need to assign those macro to shortcut key combinations.

  1. Use Tools > Macros > Record Macro to start recording a macro. A small window is displayed so you know that is recording. Image:StopRecording3.png
  2. Use Insert > Special Characters to open the Special Characters dialog box. Scroll down until you find the en-dash (U+2013) and em-dash (U+2014) characters. Select one of them and click OK.
    Find and choose the en-dash.
  3. Click the Stop Recording button to stop recording, save the macro, and display the Basic Macros dialog. Type a descriptive name for the new macro in the Macro name box on the upper left.
    Naming the new macro and storing it.
  4. Be sure to open the library container named My Macros. Find the library named Standard under My Macros. Select Module1 and click Save.
  5. Repeat steps 1–4 to create other macros, for example to insert an em-dash.
  6. Use Tools > Customize > Keyboard tab. In the Shortcut keys list, pick an unused combination (for example, Ctrl+Shift+N for an en-dash). In the Category list, scroll down to Macros, click the + sign, then click the + next to the Standard library and choose Module1. In the Function list, choose Endash and click the Modify button on the upper right. The selected key combination now appears in the Keys list on the lower right, and Endash appears next to Ctrl+Shift+N in the Shortcut keys list.
    Defining keyboard shortcuts for running macros.
  7. Repeat for the em-dash macro, then click OK.
Image:Tip.png For inserting en- and em-dashes, and other special characters, you may find extensions such as Compose Special Characters useful. See Adding functionality with extensions.

OpenOffice Writer 3.x Guide
Previous Page Home Next Page

  Published under the terms of the Creative Commons License Design by Interspire