[texworks] Scripting read access
st.loeffler at gmail.com
Wed Dec 8 20:32:50 CET 2010
having scripts disabled by default is an interesting proposition. The
original idea was to keep adding new scripts as simple as possible
(i.e., sparing the user the extra clicks to enable the script he
intentionally moved to the scripts folder, anyway). But in the interest
of security, this may be the smaller price to pay. Anyway, I have to
think about it. Jonathan, any comments?
On 2010-12-06 11:11, Paul A Norman wrote:
> Could I also please request that script readFile (and even writeFile)
> be available by default for the whole script folder and
> subdirectories to facilitate libraries and saving global
> Or a script accessible dedicated script-library folder, and
> script-data folder, please?
You can request it, of course, but the probability of this hitting
before 0.4 is very small. I originally intended to do what you suggest,
but there are implementation-specific problems. The only thing directly
available is the folder in which the script file is saved. The top
script folder is managed by a class called TWUtils, which handles many
other things as well, however. If we add that to scripting, we would end
up pulling in the whole spell checking library in each scripting plugin,
for example. So that is out of the question. We could do some code
restructuring, but that would have wide-reaching consequences.
Moreover, expanding the number of accessible folders later on is
backward compatible, so it can safely be postponed.
More information about the texworks