Go to page:

Search:   Help

Navigation

Groups

LyX documentation

Edit

Shared groups

Links

Farsi

Categories: Windows, Farsi
<< | Page list | >>

How to set up LyX under Windows to use it for Farsi

Installation

  1. Install LyX for Windows
  2. Install the package arabi using MiKTeX's Package Manager.
  3. If LyX doesn't correctly accept your keyboard input, open the menu Tools → Preferences try to use a keyboard map as shown in this screenshot. Then click Save and restart LyX.

Testing the Installation

  1. Run LyX and press Ctrl+N to open a new document. Write a few words in English, and press Ctrl+R.
    A PDF viewer program should be opened; check that it displays the text correctly.
  2. Open another document and call the menu Document → Settings.
    Select there in the Language section "Farsi",
    press OK and type in a few words. Press Ctrl+R and check the output.

Possible problems

  • If you do not see Farsi, check that LyX's preferences are properly set (Check if the screen fonts support Farsi).

Notes

  • It is possible to add new templates to LyX. Place the template files in
    ~:\Documents and Settings\<username>\Application Data\LyX2.0\templates. Then reconfigure LyX by using the menu Tools → Reconfigure and restart LyX.

Setting Up LyX Under Ubuntu(mint) to Use it for Farsi

This description is not correct. For Farsi the LaTeX-package arabi should be used. This description is about the LaTeX-package arabtex that does not natively support Farsi.

  1. install LyX from mintinstall (package installer)
  2. install the package "texlive-lang-arab" from mintinstall
  3. open LyX and use the menu Tools → Reconfigure
  4. Start LyX, then in the menu Tools → Preferences go to Language Settings and select Language. Change Command start to \selectlanguage{arabic}, and change Language package to Custom, and enter \usepackage[farsi,arabic]{babel} in the provided text field.
  5. Still in Tools → Preferences, go to Output and select LaTeX, then change Use LaTeX font encoding to LAE,LFE in the provided text field.
  6. Still in Tools → Preferences, go to Editing and under Keyboard/Mouse check the Use keyboard map option and for First select Farsi from the *.kmap files that are shown when hitting the Browse button.
  7. Hit the Save button in the Preferences window then restart LyX.
  8. Still in Document → Settings, go to Language and select Arabic (Arab TeX) as the Language, then change Encoding to Other and select Unicode (utf8) as the encoding, then select None for the Language package option.
  9. Hit the Apply button then close the Document Settings window.
  10. Now enter text in your document (which should be going from right to left now), save the file as a LyX file, then select File → Export → PDF (pdflatex). You should get a PDF with Farsi in it.

References:http://forums.fedoraforum.org/showthread.php?t=268654

Using Farsi

Part numbering

When you are using a report or book document class, you will see that the parts are not numbered in the PDF output. The reason for this is that the default numbering for parts is Roman numbering. LaTeX's Farsi support automatically translates Arabic numbers to Farsi numbers, but cannot handle roman numbers.

You have two possibilities to overcome this:

  1. Redefine the part numbering from Roman numbers to Arabic ones by adding this line to your document preamble:
    \renewcommand{\thepart}{\arabic{part}}
  2. Make Roman numbering work in Farsi by redefining the part numbering with this line that you add as TeX code at the first line of your document:
    \renewcommand{\thepart}{\selectlanguage{english}\Roman{part}}
    Note that you need to mark this fist line as English in your document.

In this LyX file the two methods are demonstrated.

Windows Farsi

Edit - History - Print - Recent Changes - All Recent Changes - Search
Page last modified on 2013-05-26 18:32 CEST