How to write in Hebrew or Arabic using Yudit

For efforts in internationalising Puppy and solving problems in this area
Post Reply
Message
Author
User avatar
don570
Posts: 5528
Joined: Wed 10 Mar 2010, 19:58
Location: Ontario

How to write in Hebrew or Arabic using Yudit

#1 Post by don570 »

Type in Hebrew or Arabic using Yudit

I have written this tutorial in the hope that it will aid in localization
of Puppy projects into Hebrew and Arabic.

There are four free bidirectional text programs available for linux OS,
Abiword,open office,Katoob, and Yudit. Katoob is an abandoned project.
Abiword claims that it is a bidirectional word processor
but it only has only limited abilities.
See picture of Abiword. click to enlarge.
Image
Worst of all, when it saves
a text file with directional info, other programs can't open it
properly. Oddly sometimes Abiword can't even open up it's own text files
properly when there is complex bidirectional info inside. On the other hand, Yudit text files
are opened correctly by other text editors* and is a mature program
that is still being supported.

So I will explain how to type in Hebrew or Arabic using the free
text editor 'Yudit'.
It can be downloaded

http://www.datafilehost.com/download-efdd6654.html

or a new version compiled in precise

http://www.datafilehost.com/download-1cb986e0.html


and here is a website explaining its use
http://www.murga-linux.com/puppy/viewto ... 65&t=57866

Here is a picture of Yudit using
Hebrew and Arabic to give you an idea of what is possible.
Image

This tutorial is divided into two parts. First of all the simple introduction,
then the second part will demonstrate the advanced features.
This tutorial is entirely in English because I don't understand a word of
Hebrew or Arabic ...but since no one else will write a tutorial on the topic, it is
left to me to fill the void.

You see that Yudit uses a black background for better visibility.

Ordinarily Yudit uses green characters and the typing is right to left
as you would expect.


In this tutorial I will follow the following color scheme:

green--------------->English i.e. European writing
red----------------->insertion mark(usually an arrowhead, (solid or open)
yellow--------------> Hebrew or Arabic writing
blue---------------->carriage return and punctuation
orange-------------->the color of numbers

...and I will always be typing left to right except when entering
a green English word....but more on that later.

When Yudit is first opened with a blank document the insertion
mark is, as expected, on the left side of document and the arrow
is pointing to the right.

However we want the insertion mark to be situated on the
right side of document and to have an arrowhead pointing to the left.

Here is our procedure:

We click twice on the icon named 'Document Text Embedding'. (It would be
more descriptive if the icon (or button) was labeled 'Alignment Tool').
This switches the side of document that the text is aligned to.

Image

Step 1: Click on 'Embedding override' icon (Note that it is in center of
3 green icons)

Step 2: Press <SPACEBAR> to start the text entering process

Step 3: Now click on 'Direction Override' icon.(It is to the left
of previous green icon)

Here is two pictures to help you find these icons.
Image

Image

The arrowhead is now pointing left (and solid red). You can now start typing
Hebrew or Arabic. These will be in yellow characters.
The arrow will now be pointing to the left. I will type the English phrase
'Here is my text.' and you will have to imagine that
it is in Hebrew or Arabic. Note the way this phrase appears on the screen.
Weird,yes,but this is how Hebrew and Arabic works. Think of it a backwards text.
See picture.
Image

Text wrapping should be 'ON' as default, so you can now type a long paragraph
and see it entirely on the screen while you type.

The pictures show the icons to click.
The icons are labeled thanks to 'Tooltips' .

At the end of your paragraph press <ENTER> and you can continue a new paragraph,
however you must start at step 1 again for this new paragraph.

Further editing is possible such as getting rid of unwanted spaces
by pressing <BACKSPACE>
When editing inside a word, the arrowhead opens up but it is still red.
Entering a number is easy.


Inserting European characters and words is very common and useful, for instance
technical documents always need a few English words to describe an action.
I will describe the simplest method I have found.
I suggest leaving a small empty space and once the paragraph is written, add in
the English words.

Step 1: click inside the empty space once,

Step 2: then click the center icon (i.e. Embedding override)

Step 3: Type in the English word. (Note how the insertion arrow now
points to the right and the text color is now green). Directional flow of
text has now reversed. See picture.

Image


To end the editing process click under paragraph. Press <ENTER>
to start a new paragraph underneath the previous one.
If you do anything wrong there is always the undo icon to click.
You can remove some text by selecting it first, then press <BACKSPACE>.
Note that Ctrl-z increases font size

Practice Practice Practice and it will become second nature.

Image
_________________________________________________________________
To remember this procedure I have memorized the phrase
center Space Left
referring to the center green icon ,the spacebar, then the icon to the left
of the center icon.
____________________________________________________________________
double click selects the word
a triple click selects the entire sentence
ctrl-m deletes the whole line
_________________________________________________________________

When Yudit opens it's own text files, it aligns the text to the left of page
but the directional flow of text has been preserved. See picture.
Press on 'Document text embedding' to switch sides.
Image
________________________________________________________________________
Note that numbers can be typed as well but they will be the color orange.

_________________________________________________________________________

If you are using Lucid Puppy 5.1 make sure that you install the fonts for Hebrew
and Arabic that are available from forum.
http://www.diddywahdiddy.net/Puppy500/Fonts-lupu510.pet
___________________________________________________________________________________
...and here is a picture of Hebrew mixed with English words constructed in
Yudit and opened in Geany
Image

_________________________________________________________________________

* I recommend that you avoid starting a paragraph with a <TAB>, use blank spaces instead.
Geany will become confused as to text direction if a paragraph begins with a tab.
Nicoedit despite being a simpler program does not have any problems displaying Yudit text
with a tab.

This picture shows what happens when Geany tries to open a Yudit text file
with a <Tab>

Image

The following picture shows that Nicoedit and Mousepad will
properly display a Yudit file

Image

Nicoedit will further edit the directional text whereas Geany is not
capable of this.
______________________________________________________________________________
Last edited by don570 on Wed 19 Jun 2013, 00:16, edited 1 time in total.

User avatar
don570
Posts: 5528
Joined: Wed 10 Mar 2010, 19:58
Location: Ontario

localization project

#2 Post by don570 »

Here is a typical localization problem requiring English to be translated into French.
Image


Here is the final translation(taken from real project)

Code: Select all

#browser installer
export LOC_001="Welcome to the"
export LOC_002="Please connect to the Internet and then Choose a Browser."
export LOC_003="Note"
export LOC_004="If you have less than 256 MB of RAM it is recommended you create a save file before installing a browser."
export LOC_005="Generic Browser -installed"
export LOC_006="Click to install Firefox"
export LOC_007="Click to install Seamonkey"
export LOC_008="Click to install Chromium"
export LOC_009="Click to install Opera"
export LOC_010="Click to make the generic browser the default browser, it is already on your system"

#browser installer
export LOC_001="Bienvenue dans"
export LOC_002="Connectez-vous à Internet et choisir un navigateur."
export LOC_003="Note"
export LOC_004="Avec moins de 254MB de RAM il est recommandé de créer une sauvegarde avant d'installer un Navigateur."
export LOC_005="Navigateur d'origine déja installé"
export LOC_006="Cliquer pour installer Firefox"
export LOC_007="Cliquer pour installer Seamonkey"
export LOC_008="Cliquer pour installer Chromium"
export LOC_009=" Cliquer pour installer Opera"
export LOC_010="Faire du Navigateur d'origine son navigateur par défaut. Il est déja installé"


Note that some technical English words need to be used. The flow of the text is
always toward the right because French is a European language..

The problem of localizing for the Arabic language does add some complexity but can easily be
solved with Yudit. I've divide up the problem into steps using Yudit.

Step 1: Remove English words between quotes. See picture.

Step 2: Write in Arabic or Hebrew between the quotes.

Step 3: Add in English technical words. See picture.

Step 4: Send as a text file back to developer.

Image

Image



The trick to doing Step 2 is to click on 'Embedding Override' followed by
clicking on 'Direction Override'. The arrow will now point to left and the text that
you enter will be yellow i.e. Arabic or Hebrew.


The trick to Step 3 is to click once on 'Embedding Override', then type the
English word. This is the same method as described in the first post.

Here is a sample of the finished localization project as the developer will see it.
(Hopefully your browser will display Arabic characters.)

Code: Select all

#browser installer
export LOC_001="Welcome to the"
export LOC_002="Please connect to the Internet and then Choose a Browser."
export LOC_003="Note"
export LOC_004="If you have less than 256 MB of RAM it is recommended you create a save file before installing a browser."
export LOC_005="Generic Browser -installed"
export LOC_006="Click to install Firefox"
export LOC_007="Click to install Seamonkey"
export LOC_008="Click to install Chromium"
export LOC_009="Click to install Opera"
export LOC_010="Click to make the generic browser the default browser, it is already on your system"

#browser installer
export LOC_001="وإنما الرقة  ‫English‬

User avatar
don570
Posts: 5528
Joined: Wed 10 Mar 2010, 19:58
Location: Ontario

#3 Post by don570 »

I've been testing yudit again to see if it can be used for Arabic.


yudit definitely writes in Arabic!!!

I installed the pet package in precise.

Opening a new document in Yudit is hard for some reason.
My solution... ----> I used Rox Filer to create a blank doument in /root,
then I open it with yudit.

I clicked the arrowhead in the window to set it up for
'Arabic' and started writing. The direction of the writing was
right to left which surprised me.

You should be able to take these characters and transfer them to Poedit
or geany for gettext translations.

Image



___________________________________________________

User avatar
AbdelAziz
Posts: 14
Joined: Wed 29 May 2013, 09:38
Location: Algeria

#4 Post by AbdelAziz »

Hi

Opening a new document in Yudit is working fine with me (using precise-5.6.1)
just one thing the keyboard map seems wrong to me or at least to the keyboard i'm using.

User avatar
L18L
Posts: 3479
Joined: Sat 19 Jun 2010, 18:56
Location: www.eussenheim.de/

yudit

#5 Post by L18L »

Code: Select all

# yudit
No locale support on this machine.
No locale support on this machine.
#
This machine has puppy precise 5.6.1 and locales are:

Code: Select all

# locale -a
C
de_DE.utf8
en_US
en_US.utf8
POSIX
ru_RU.utf8
#
Just wondering :roll:

User avatar
don570
Posts: 5528
Joined: Wed 10 Mar 2010, 19:58
Location: Ontario

#6 Post by don570 »

# yudit
No locale support on this machine.
I always use American keyboard layout and dejavu font is installed.
It then shows most of the characters of the foreign languages
(except Asian).

____________________________________________________________

Note to Arabic users


I've been reading through the manual for yudit.

Here's a couple of things I've learned


1) A hard space (or non-breaking space) can be entered
by choosing 'unicode' then typing u00A0

The unicode hexidecimal number for the current character
is printed along the bottom of window.



2) There is an embed icon on the top row of window that effects the
direction as well.

3) The keyboard mapping can be modified. The instructions are
in the manual. So it would be possible for you to print out to screen
an Arabic character that ordinarily wouldn't show.

__________________________________________

User avatar
don570
Posts: 5528
Joined: Wed 10 Mar 2010, 19:58
Location: Ontario

#7 Post by don570 »

I compiled the newest version of yudit 2.9.3
in precise. This stops the error complaint when launching
with the terminal, but I don't see much difference.

But it's best to use it. I posted it in first post above or

here it is again.

http://www.datafilehost.com/download-1cb986e0.html


--------------------------------------------------------------------

Post Reply