[texworks] SCRIPTING: global __FILE__ now only available when debugger on?
Paul A Norman
paul.a.norman at gmail.com
Sun Nov 20 09:57:13 CET 2011
Hi,
Here is something that appears to have recently developed.
I sat at a colleague's workstation setting up TeXworks for him, and some of
the scripts I gave him would not work.
Error message in Status bar suggested that the Qt supplied global __FILE__
did not exist.
Turned debugger on and everything worked with no errors.
Turned Debugger off, and script fails.
Seems any script locating the script's directory through __FILE__ no longer
works when the Debugger is off (eg .ui(s)). I don;t know when this started
but I am reasonably sure I have not had this happen at all before now. I
can not say what version of TW I last successfully ran __FILE__ with
Debugger off I am sorry.
Is this a new Qt 4.7.3 feature (hmm), or something I should put on Tw
issues?
If it is (Qt) permanent, can I please request an global scope property
be added to scripting giving the script's full path and file name?
Paul
//TeXworksScript
//Title: Experimental TW
//Description: Exploration of TW objects
//Author: Paul A. Norman
//Version: 0.9
//Date: 2010-11-04
//Script-Type: standalone
//Context: TeXDocument
//Shortcut: Alt+T, Alt+W
TW.information(null, "Check __FILE__", "Debugger on and off,
script name: \n" + __FILE__);
----- configuration info -----
TeXworks version : 0.5r950 (official)
Install location :
G:/latexportable/LaTexUtils/TeXWorks/texworks/TeXworks.exe
Library path : G:/latexportable/LaTexUtils/TeXWorks/texworks/config\
pdfTeX location :
G:/LaTeXPortable/LatexUtils/MikTex2.9.3927-Portable/miktex/bin/pdftex.exe
Operating system : Windows XP Professional Service Pack 3
Qt4 version : 4.7.3 (build) / 4.7.3 (runtime)
------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://tug.org/pipermail/texworks/attachments/20111120/2d3dbf41/attachment.html>
More information about the texworks
mailing list