[texworks] Wishlist for TeXworks 0.4.3+

Philip TAYLOR (Webmaster, Ret'd) P.Taylor at Rhul.Ac.Uk
Tue Nov 1 18:24:35 CET 2011

Arno Trautmann wrote:

> No good idea in my opinion. The editor should not change the document automatically.
 > I'd rather like to have a button that inserts the "% !TeX program = ",
 > as I can /never/ remember the exact syntax of this …

Philosophically, I agree with you.  In practice, I cannot
see that any harm can come from it, whereas I can envisage
a great deal of good ...  I was, after all, envisaging the
pragmat as being written to the in-editor copy, not to the
file itself, so unless the file were saved the pragmat would
not automatically be added to the file /qua/ file.

Herbert Schulz wrote:

> That's what Macros are for.

Two questions :

1) Does TeXworks support macros ?  There is no mention of them
in the Table of Contents to "A short manual for TEXworks" :


2) If so, does that mean that I could write a macro for TeXworks
such that when I set the typesetting engine to (say)
XeTeX for a document that has no %! TeX program pragmat,
this will automatically cause

	% !TeX program = xetex"

to be prepended to the source document if it does not already
have such a pragmat ?  (supplementary) or do you envisage it
as a two-stage process, whereby some as-yet-unspecified action
could cause the current processing engine to be identified
and a pragmat written ?  The second would add an unwanted step,
and therefore be sub-optimal (IMHO).

Philip Taylor

More information about the texworks mailing list