[texworks] Hello and a few suggestions

Marcin Borkowski mbork at atos.wmid.amu.edu.pl
Fri May 22 09:25:27 CEST 2009


I've recently looked at the TeXworks application.  I find it a very
nice thing - although I will most probably not switch to it, being a
long-time Emacs user;).  (But, who knows; emacs has poor support for
ConTeXt, which I happen to use more and more...)  Definitely I will
recommend TeXworks to people new to the TeX world.

I have, however, a few suggestions and remarks.

1. The "tags" option doesn't work for me.  (I used r290.)

2. I think that two options could be added without cluttering the UI;
they are present in Emacs with AUCTeX and *very* useful:
  (a) it would be nice if I could select (highlight) a portion of text,
      then select some option (called, let's say, "apply command to
      selection"); then a dialog appears where I can write a command or
      environment (using autocompletion), and after confirming, the
      selected portion of text is enclosed as the #INS# part of the
      completion code.  This way, I could easily
      italicize/emphasize/boldify/index/flushleft/anything a word or a
      part of the text.
  (b) Similarly, it would be nice to be able to *change* the "nearest"
      (i.e., the smallest-scope enclosing one) environment (or, e.g.,
      font changing command).  (In AUCTeX, this is triggered by C-u C-c
      C-e or C-u C-c C-f.)  Despite sounding complicated, this is
      extremely useful.

3. In general, I would love to have more text-changing and cursor-moving
commands bound to different keystrokes, possibly configurable.  Maybe it
could be a plugin, so that novices wouldn't be surprised by pressing
something accidentally.

4. Last but not least: I think that autocompletion needs a bit of
rework: I think that the markup with the #...# and the bullet sign is
not really a good idea.  It would be better to stick to ASCII.
Personally, instead of #RET#, I would choose, say, ^^J (which is
consistent with low-level TeX and even more unlikely to appear in TeX
documents than #RET#); instead of #INS# and bullet I would use the
syntax <some text> (as in vim's LateX-suite).  The rationale is:

(a) it is unlikely that someone actually uses such a character string in
a TeX document; usually, you either want "\langle ... \rangle", or (in
maths) "... < ... < ..." (with both signs having the same "direction").

(b) after pressing c-tab, you might just find the next occurence of
<[a-z ]*> in the document and highlight it; it would be better than a
bullet, because inside the "angles" you might put a short explanation
what goes here; for example, you could put this into the template set:

\begin{tabular}{<format>}^^J  <first row>^^J\end{tabular}^^J<>

The idea is that you could put just <> if explanation is not needed (in
this case, after the \end{...}, so that it's easier for the user to jump
there after finishing the tabular).  Also, the first <...> could play
the role of the current #INS#.

I think this would enhance the usability: this way, the templates could
be more self-explanatory.  On the other hand, accidentally leaving a
bullet and LaTeXing a document seems to be harmless; maybe the "typeset"
option could issue some kind of warning if a regex <[a-z ]*> is detected
somewhere in the document...

Hope this helps - and please keep up the good work!


Marcin Borkowski (http://mbork.pl)

More information about the texworks mailing list