[texworks] ver 567 Scripts - Cariag/Line returns now coming back as ??

Jonathan Kew jfkthame at googlemail.com
Wed Mar 17 15:37:06 CET 2010


On 17 Mar 2010, at 14:30, Bruno Voisin wrote:

> Le 17 mars 2010 à 14:41, Jonathan Kew a écrit :
> 
>> Simple: the first is wrong, the second is correct. So the question is, where's that "UTF--8" coming from? My guess is that there must be a "% !TEX encoding" line in your file.
> 
> Speaking of which: recently I was processing a file with either TeXworks or TeXShop (depending on the mood of the day), and noticed the difference in encoding names for the line
> 
> % !TEX encoding = <encoding>
> ....
> 
> I  couldn't find similar information in Alain's manual. The TeXworks wiki refers to the encoding pull-down menu in the Prefs
> 
> <Capture d’écran 2010-03-17 à 15.11.55.png><Capture d’écran 2010-03-17 à 15.12.34.png>
> 
> So this seems to imply the names are quite different and there are no standard names for the encodings. Is this the case? And is there somewhere an explanation of the names used by TeXworks? (I suppose if you don't know what a name means this implies you don't need the encoding anyway, but what's the name then for the widespread Windows Latin 1 aka Windows ANSI -- I imagine windows-1252, but this is far from obvious and requires some time spent on wikipedia.)
> 
> I tried to browse the sources to find a list of encodings somewhere inside, but didn't. Are the names inherited from Qt?

Yes; see http://qt.nokia.com/doc/4.6/qtextcodec.html.


> What's puzzling is that some of the templates in the source, for example trunk/res/resfiles/templates/Basic LaTeX documents/article.tex, seem to have been inherited from TeXShop and hence use
> 
> % !TEX encoding = UTF-8 Unicode
> 
> instead of
> 
> % !TEX encoding = UTF-8
> 
> Does this mean TeXShop's names for encodings are understood by TeXworks?

It knows some of them, anyhow - I thought this would be helpful to people who share documents, or use both.

See http://code.google.com/p/texworks/source/browse/trunk/src/TeXDocument.cpp#802.

JK




More information about the texworks mailing list