DirectionService - User Manual
- DirectionService - User Manual
Tip: To download the user manual to your Mac, click here. This will omit the navigational interface and leave only the page content. Then, save the page to your Mac. For example, in Mozilla you use the Save Page as... menu command, and choose the Web Page, Complete format.
See also WritingDirectionMenu - similar utility, more convenient to use, specially for Panther users.
DirectionService/Support - (Hebrew) Improvements, compliments, wishlist, questions and ideas, you can and should write in the support page
DirectionService/Versions - (Hebrew) Revision history
Why Use DirectionService?
You can write in right to left languages like Hebrew and Arabic in most OS X applications. But because the right to left directionality support is incomplete, punctuation marks appear in the wrong place, and using English and Hebrew in the same paragraph is almost impossible, as you can see in the screen shot:
This problem can be solved in a rather simple way as proposed by a very nice person known as Mitz Pettel, by inserting a Unicode Right to Left mark at the beginning of each paragraph using the Unicode Hex Input keyboard layout. Later, Oren (better known as OBOS4ALL) found an application you can configure to insert direction mark when you press the Return key (see KeyXing). The direction service is doing a similar task: inserting directional marks into the text, thus setting the directionality of the text. The direction service has some advantages over the other solutions: It is easier to install, easier to use, costs less, and can do much more then insert direction marks (currently it does not, though).
When you should use DirectionService
Creating readable and editable documents on Mac running OS 10.2 and later, with applictions such as TextEdit and Mail. Although it is more comfortable to write in a Hebrew word processor like Mellel, other people might not have this application. You can send them a PDF file to overcome this, but then they can't edit the text easily.
Writing Emails in Right to Left languages to people using Mail or Mozilla, and other mail clients who support Unicode, on any platform.
Using Keynote and other Apple applications, enabling writing in right to left languages, but lacking the directionality control.
Creating plain text documents readable and editable on any platform supporting Unicode.
Tip: If you want to create a styled text for people using a PC, the best way is to save the file as PDF, because Hebrew RTF files with direction marks do not open nicely on a PC. Some people are happy with the results, but I am not - You should try it yourself. If you create a PDF file, I would recommend using real Hebrew word processor like Mellel, which supports character and paragraph styles, justified text etc.
How to Install
Like any other service, you can put this software into one of the Services folders. If you are the only user on your Mac, you can put the direction service into the Services folder in your Library folder inside your home folder. You can also put the service into the Services folder in the Library folder inside the partition where Mac OS X is installed. If you can't find these folders, you can created them yourself.
After you put DirectionService in it place, you should Log Out, and then Log In, in order to activate the service.
How to Use
Select direction of writing
Place the cursor in the point where you want to start a new writing direction, usually in the start of a new paragraph after you pressed the Return key - do not select any text, because it will be deleted! Choose the menu command Start Right to Left or Start Left to Right from the Direction menu in the Services menu, and keep writing as usual. You will be pleased to find that you can mix Hebrew and English text nicely. When you want to return to the default writing direction (left to right) Choose the menu command End Direction. If you to write entire paragraph with one direction, you could omit the direction ending mark. this works nicely with TextEdit and Mail, but might not display correctly in other applications or platforms.
Change the Direction of Existing Paragraph
Place the cursor in the beginning of the paragraph, do not select any text, because it will be deleted! and choose the menu command Start Right to Left or Start Left to Right from the Direction menu in the Services menu. The directionality of the text from the insertion point to the end of the paragraph will change. Again, you could omit the direction ending mark.
Chage the Direction of Some Text Within a Paragraph
Choose the text you want to change - a whole paragraph, some words or characters, as you need, and choose the menu command Right to Left or Left to Right. The selected text will change its direction.
A great advantage of this service is that it can be operated by keyboard shortcuts:
Start Right to Left
[[ltr(Command + Shift + <)]]
Start Left to Right
[[ltr(Command + Shift + >)]]
[[ltr(Command + /)]]
Remark: There is no shortcut to select direction of only a part of a paragraph, since this is rarely needed, especially in the next version, which enable you to select the whole document and align all the paragraphs in one menu command.
Is it possible to change the keyboard shortcuts?
The shortcuts to this service can contain a letter with or without the shift key. The Control or Option/Alt keys can not be used, neither the right or left arrows which are already taken by other applications. See DirectionService/support for my plans for the next version.
How can I update my DirectionService? I can't replace the old version with the new one? Help!
You can't delete an active service when the application is running. The easiest way is to move the service file out of the Services folder and put the new version inside, then Log Out. After you Log In, the new version will be active and you can trash the old version.
Advanced Tip: You can kill the service with the terminal command killall DirectionService, then you can replace the old version with the new one. You still need to Log Out in order to update the Services menu, though.
DirectionService - control writing direction
Copyright (C) 2003 Nir Soffer
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details: http://www.gnu.org/licenses/gpl.html
If you want to help with the development of this application you are invited to download the source code.
If you want to propose improvements your are invited to write in the support page: DirectionService/Support.
Thanks to Mitz Pettel and to Eyal Redler for their help
Thanks to the anonymous translator and other contributers in MacMac