Dear Giovanni,
this of yours is a pretty cool project! Aside from the intrinsic value I
like a lot the extensive documentation you wrote.
I think this kid of efforts should be centralized in a repository, but I’m
not clear how to do it in an easy to maintain way. Are there any suggestions?
Best
Max
On 22. Jun 2019, at 13:23, Giovanni Piredda <address@hidden> wrote:
On 18.06.19 22:17, Massimiliano Gubinelli wrote:
I see, that indeed could be tricky. define is a special form which isI have been able to do the automatic loading. It is described in the help
interpreted differently at top level or inside a function. In particular I’m
not sure what will happen with a define inside a TeXmacs macro. But I think
you can try tm-define because this define symbols directly in the common
environment which all the scheme evaluation inherit. I think this is more
what you want.
Best
Max
On 18. Jun 2019, at 21:09, Giovanni Piredda <address@hidden> wrote:
On 18.06.19 22:05, Giovanni Piredda wrote:
Hi Massimiliano,More precisely it seems that within extern I cannot write a define ...
I have tried extern and it did not work.
instruction, but to be sure I would have to try again. I postpone and will
write together with the rest.
Giovanni
files, it took me a bit of time to follow the thread.
The right instruction is <use-module|([dir1 [dir2 ... dirn]] filename)> where
the Scheme list indicates the path, which as far as I understood must be a subpath
of one of the paths that TeXmacs know about (~/.TeXmacs/progs is one of them, so if
dir1 is a subdirectory of ~/.TeXmacs/progs, TeXmacs will find and load the Scheme
files).
The style file itself can be put in the "user" directory of TeXmacs, that is again
~/.TeXmacs, under /packages, and it will appear in the "Document->Style-> Add package"
menu.
I have not yet understood how to execute a macro only once inside TeXmacs, so
the macros I use to define the list of formats get executed every time
TeXmacs wants to (there is an update mechanism that I do not understand but I
guess it is the general update mechanism of TeXmacs). The multiple execution
has no effect, as the macros I wrote check for the existence of a format
before adding it, but I would like to correct this and get the behaviour I
want (only one execution for this macro). If anyone has a suggestion, thanks
in advance.
I have updated the files at https://github.com/pireddag/formatRef and I think
it is possible to use them even if they are not robust (multiple executions
that I have mentioned above, missing checks on input) and incomplete.
Incompleteness that I see: it is not possible to define a format where the
reference number is within parentheses, as the format string is always before
the reference. I have in mind a solution with string-split, and perhaps for
making it general I would need to understand better the TeXmacs format (with
trees) and how to manipulate it.
Archive powered by MHonArc 2.6.19.