[texworks] TeXworks 0.4.3 : where is the transcript file

Philip TAYLOR P.Taylor at Rhul.Ac.Uk
Sun Nov 13 11:13:22 CET 2011



Charlie Sharpsteen wrote:

> I'm just a TeXworks user as well---I do some development work because I
> want to have stable Mac builds and a better PDF viewer.
>
> Since you have experience working with HTML, perhaps you know a bit of
> JavaScript. In that case, you could write a script for TeXworks that
> adds the feature you want without having to know about C++ or compiling
> things from source:

> Give a man a fish and you feed him for a day. Teach a man to fish and you
> feed him for a lifetime.
>
> With projects like TeXworks, no-one is getting paid to do development.
> Therefore, the responsibility (and freedom!) falls upon us as users to
> implement the features we want.

I understand your sentiments, Charlie, and I appreciate both
your first approximation to "Open log file" and your beliefs.
I too very much believe in "teaching a man to fish", which is
why I occasionally respond to questions on TeXhax and elsewhere
with solutions that do /not/ rely on any package and which
are intended to encourage the reader/user to /think/ rather than
just look for a canned solution.

But (as Reinhard has said), getting access to the document's log
file is pretty fundamantal for an editor that is intended solely
for use with TeX, and if a clean and elegant solution could be
added by a more knowledgeable user to TeXworks, then I am certain
that I, and many others, would be profoundly grateful.

** Phil.

P.S. A few questions, if I may ?  In

> // TeXworksScript
> // Title: Open TeX logfile
> // Description: Attempts to open the logfile for the current document
> // Author: Charlie Sharpsteen
> // Version: 0.1
> // Date: 2011-11-12
> // Script-Type: standalone
>
> logfileName = TW.target.fileName.replace(RegExp('\.(tex\|pdf)$'), '.log');
> TW.app.openFileFromScript(logfileName, TW);
>
> undefined;

(1) Why is the solidus in "\.(tex\|pdf)" escaped ?
Do you not want its alternation functionality rather
than the symbol <solidus> ?

(2) What rôle does "undefined;" play

(3) What should I do with this code in order to use
it in conjunction with TeXworks, and how might I go
about adding entries to the menu system so that under
the "Window" menu I am automatically offered
<jobname>.log as well as <jobname>.pdf as soon as
compilation has taken place ?

(4) "TeXdoc TeXworks" yields the following :

> Public domain.  Originally written by Karl Berry, 2009.
>
> TeXworks is a cross-platform GUI front end for TeX, written by Jonathan Kew.
> Its home page is http://tug.org/texworks, with links to documentation,
> articles, and othe resources.
>
> TeX Live includes a Windows binary for TeXworks, and MacTeX includes a
> MacOSX binary.  No other binaries are included, because it depends
> (implicitly or explicitly) on so many libraries that it is impossible to
> ship anything that has a chance of working across different releases.
>
> So for other platforms, please download from the TeXworks home page if
> available, or compile from source.

How is one intended to learn about the scripting API of TeXworks ?


More information about the texworks mailing list