[NTG-context] Pgfplots - "reverse legend" by Lua
Lukáš Procházka
LPr at pontex.cz
Thu Dec 24 23:01:10 CET 2015
Hello,
On Tue, 22 Dec 2015 18:21:01 +0100, Hans Hagen <pragma at wxs.nl> wrote:
>> t = {["legend entries"]="{Cos,Sin2,Sin}", "reverse legend"}
>
> such a table is valid lua (mixture of indexed and hashed) but of course
> the application using it has to know how to use it
OK, so when '{["legend entries"]="{Cos,Sin2,Sin}", "reverse legend"}' is a valid Lua call and, what I guess, a valid Lua-to-context call -
- why the code doesn't work?
I also tried Aditya's way II - to build the "command-string" and to pass it to context:
"
context(string.format("\\startaxis[legend entries={%s},reverse legend]", "Sin,Cos"))
"
It works, although I'd rather use "context.startaxis{...options...}" style as it looks "nicer".
Next question - why
"
context[[\startaxis]]
"
doesn't work, whilst
context"\\startaxis"
does?
(See attached files.)
Best regards,
Lukas
> Hans
--
Ing. Lukáš Procházka | mailto:LPr at pontex.cz
Pontex s. r. o. | mailto:pontex at pontex.cz | http://www.pontex.cz
Bezová 1658
147 14 Praha 4
Tel: +420 241 096 751
Fax: +420 244 461 038
-------------- next part --------------
A non-text attachment was scrubbed...
Name: t-Plot4.mkiv
Type: application/octet-stream
Size: 715 bytes
Desc: not available
URL: <http://mailman.ntg.nl/pipermail/ntg-context/attachments/20151224/19334227/attachment-0001.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: t-Plot4.pdf
Type: application/pdf
Size: 14413 bytes
Desc: not available
URL: <http://mailman.ntg.nl/pipermail/ntg-context/attachments/20151224/19334227/attachment-0001.pdf>
More information about the ntg-context
mailing list