[texworks] ArabTeX and TeXworks
Bruno Voisin
bvoisin at me.com
Thu May 20 11:14:13 CEST 2010
Le 20 mai 2010 à 07:23, Helge Kruse a écrit :
> Alternatively, you may wish to use a different encoding (such as
> UTF-8) to avoid loss of data.
>
> Adding the line
> % !TEX encoding = UTF-8 Unicode
> at the top stops complaining and the compiled PDF looks like Arabic.
Thanks for reminding this, I always forget. It ensures TeXworks uses UTF-8 for opening and saving this particular .tex file, independent of the setting in the editor prefs.
The original encoding names are UTF-8 for TeXworks, yielding the comment line
% !TEX encoding = UTF-8
and UTF-8 Unicode for TeXShop, yielding
% !TEX encoding = UTF-8 Unicode
but for compatibility TeXworks understands both.
More precisely, the available encodings are those known to Qt, listed at
http://qt.nokia.com/doc/4.6/qtextcodec.html
namely
Apple Roman
Big5
Big5-HKSCS
CP949
EUC-JP
EUC-KR
GB18030-0
IBM 850
IBM 866
IBM 874
ISO 2022-JP
ISO 8859-1 to 10
ISO 8859-13 to 16
Iscii-Bng, Dev, Gjr, Knd, Mlm, Ori, Pnj, Tlg, and Tml
JIS X 0201
JIS X 0208
KOI8-R
KOI8-U
MuleLao-1
ROMAN8
Shift-JIS
TIS-620
TSCII
UTF-8
UTF-16
UTF-16BE
UTF-16LE
UTF-32
UTF-32BE
UTF-32LE
Windows-1250 to 1258
WINSAMI2
They are the encodings in the Preferences > Source > Encoding menu.
For compatibility with TeXShop, some synonyms are defined in
http://code.google.com/p/texworks/source/browse/trunk/src/TeXDocument.cpp#802
namely
MacOSRoman = Apple Roman
IsoLatin = ISO 8859-1
IsoLatin2 = ISO 8859-2
IsoLatin5 = ISO 8859-5
IsoLatin9 = ISO 8859-9
SJIS_X0213 = Shift-JIS
EUC_JP = EUC-JP
UTF-8 Unicode = UTF-8
Standard Unicode = UTF-16
Windows Cyrillic = Windows-1251
KOI8_R = KOI8-R
GB 18030 = GB18030-0
The above info is taken from a previous post by Jonathan Kew, see
http://tug.org/pipermail/texworks/2010q1/002426.html
Bruno Voisin
More information about the texworks
mailing list