Re: [NTG-context] Question about chapter headings

2011-10-25 Thread Peter Münster
On Tue, Oct 25 2011, Alasdair McAndrew wrote: \def\chap#1#2{Chapter #1\crlf #2} \def\chap#1#2{\vbox{Chapter #1\crlf #2}} -- Peter ___ If your question is of interest to others as well, please add an

Re: [NTG-context] Question about chapter headings

2011-10-25 Thread Alasdair McAndrew
Thanks very much! (I'm embarrassed - I should have been able to work that one out for myself...) -Alasdair On Tue, Oct 25, 2011 at 5:55 PM, Peter Münster pmli...@free.fr wrote: On Tue, Oct 25 2011, Alasdair McAndrew wrote: \def\chap#1#2{Chapter #1\crlf #2} \def\chap#1#2{\vbox{Chapter

Re: [NTG-context] Question about chapter headings

2011-10-25 Thread Wolfgang Schuster
Am 25.10.2011 um 08:55 schrieb Peter Münster: On Tue, Oct 25 2011, Alasdair McAndrew wrote: \def\chap#1#2{Chapter #1\crlf #2} \def\chap#1#2{\vbox{Chapter #1\crlf #2}} Use uppercase or camelcase for self defined command and the chapter string can be set with label texts.

Re: [NTG-context] Question about chapter headings

2011-10-25 Thread Hans Hagen
On 25-10-2011 08:55, Peter Münster wrote: On Tue, Oct 25 2011, Alasdair McAndrew wrote: \def\chap#1#2{Chapter #1\crlf #2} \def\chap#1#2{\vbox{Chapter #1\crlf #2}} or: \defineheadplacement[MyHead][vertical]#1#2% {\vbox{Chapter #1\crlf #2}} which helps the calling code to make some

Re: [NTG-context] Links in exported XHTML file

2011-10-25 Thread Andreas Harder
On 25.10.2011, at 00:20, Hans Hagen wrote: On 24-10-2011 23:22, Andreas Harder wrote: On 24.10.2011, at 15:01, Hans Hagen wrote: On 21-10-2011 11:27, Andreas Harder wrote: \setupinteraction[state=start] \setupbackend[export=yes,xhtml=yes,css=export-example.css] \starttext

Re: [NTG-context] How do I test for empty labeltext?

2011-10-25 Thread Mojca Miklavec
On Mon, Oct 24, 2011 at 20:41, Hans Hagen pra...@wxs.nl wrote: On 24-10-2011 19:41, Mojca Miklavec wrote: Hello, The following code \setuplabeltext[test=] test is \doifemptyelse{\labeltext{test}}{empty}{not empty} doesn't work as intended for the reasons that I approximately understand

Re: [NTG-context] xml and lua again

2011-10-25 Thread Thomas A. Schmitz
On 10/24/11 8:48 PM, Hans Hagen wrote: sure, oryou can play with if xml.filter(t,.[@frame=on]) then the x-*.lua show some tricks OK, I'm in my stubborn mode then: why doesn't this work: \startbuffer[test] a nattable frame=on tr td1/td td2/td td3/td td4/td

Re: [NTG-context] xml and lua again

2011-10-25 Thread Wolfgang Schuster
Am 25.10.2011 um 11:43 schrieb Thomas A. Schmitz: On 10/24/11 8:48 PM, Hans Hagen wrote: sure, oryou can play with if xml.filter(t,.[@frame=on]) then the x-*.lua show some tricks OK, I'm in my stubborn mode then: why doesn't this work: […] \startxmlsetups xml:nattable

Re: [NTG-context] How do I test for empty labeltext?

2011-10-25 Thread Hans Hagen
On 25-10-2011 11:26, Mojca Miklavec wrote: On Mon, Oct 24, 2011 at 20:41, Hans Hagenpra...@wxs.nl wrote: On 24-10-2011 19:41, Mojca Miklavec wrote: Hello, The following code \setuplabeltext[test=] test is \doifemptyelse{\labeltext{test}}{empty}{not empty} doesn't work as intended for the

Re: [NTG-context] xml and lua again

2011-10-25 Thread Hans Hagen
On 25-10-2011 11:43, Thomas A. Schmitz wrote: \startxmlsetups xml:nattable \startluacode if xml.attribute(t, /, frame, off) == on then context(Yes, the frame is really on!) else context(Nope, sorry, it's still off.) end context(true) context.placefigure( { here }, none , function()

Re: [NTG-context] xml and lua again

2011-10-25 Thread Thomas A. Schmitz
On 10/25/11 12:17 PM, Hans Hagen wrote: see Wolfgangs answer anyway, best move the lua code and wrap it in a function document.MyWhatever ... now its get defined each time Hans Wolfgang, Hans, thanks a lot, this works now. Will now try and move the code to a ctxluafile and see if I can

[NTG-context] xml and lpath

2011-10-25 Thread Martin Fechner
Hi all, I'm testing the possibilities of xml and ConTeXt. I was wondering if it is possible to make an extra setup for every text-element. So it would be possible to have an setup in a very flexible way. It should be something like this: \startbuffer[text] a b First text. hiding

[NTG-context] Luatex question

2011-10-25 Thread Lutz Haseloff
Hi all, some months ago I printed the name of the current font with following code: \starttext The current font is: \ctxlua{tex.print(font.getfont(font.current()).fullname)}. \stoptext Now I get an error message: ! LuaTeX error main ctx instance:1: no string to print stack traceback:

Re: [NTG-context] Luatex question

2011-10-25 Thread luigi scarso
On Tue, Oct 25, 2011 at 2:09 PM, Lutz Haseloff lutz.hasel...@googlemail.com wrote: Hi all, some months ago I printed the name of the current font with following code: \starttext The current font is: \ctxlua{tex.print(font.getfont(font.current()).fullname)}. \stoptext Now I get an error

Re: [NTG-context] xml and lpath

2011-10-25 Thread Hans Hagen
On 25-10-2011 12:52, Martin Fechner wrote: Hi all, I'm testing the possibilities of xml and ConTeXt. I was wondering if it is possible to make an extra setup for every text-element. So it would be possible to have an setup in a very flexible way. It should be something like this:

Re: [NTG-context] Luatex question

2011-10-25 Thread Hans Hagen
On 25-10-2011 14:09, Lutz Haseloff wrote: Hi all, some months ago I printed the name of the current font with following code: \starttext The current font is: \ctxlua{tex.print(font.getfont(font.current()).fullname)}. \stoptext Now I get an error message: ! LuaTeX errormain ctx instance:1: no

Re: [NTG-context] Luatex question

2011-10-25 Thread Lutz Haseloff
Thank you for your detailed information. 2011/10/25 Hans Hagen pra...@wxs.nl: On 25-10-2011 14:09, Lutz Haseloff wrote: Hi all, some months ago I printed the name of the current font with following code: \starttext The current font is:

Re: [NTG-context] xml and lpath

2011-10-25 Thread Martin Fechner
Am 25.10.2011 14:20, schrieb Hans Hagen: \startxmlsetups xml:hiding \doifelse {\xmlatt{#1}{type}} {begin} { \startnointerference } { \stopnointerference } \stopxmlsetups \starttext \xmlprocessbuffer{main}{text}{} \stoptext maybe it makes sense to have a 'hide' flag built in the serializer

Re: [NTG-context] How do I test for empty labeltext?

2011-10-25 Thread Aditya Mahajan
On Tue, 25 Oct 2011, Mojca Miklavec wrote: you can try \doiftextelse instead Thank you very much. This works fine. This should probably be added to http://wiki.contextgarden.net/System_Macros/Branches_and_Decisions at least (possibly to reference next to labels as well), but I'm not sure

[NTG-context] tilde

2011-10-25 Thread Wolfgang Werners-Lucchini
Hallo, if I want a non-breaking-space I use a tilde '~' sign. For example in: bakerstreet~13 This has worked in my old context. But now, after my update, I get an very long space. Minimal example: \starttext \framed[align=flushright,width=broad]{Hello~World!} \stoptext Is this a bug? What

Re: [NTG-context] tilde

2011-10-25 Thread Marco
On 2011-10-25 Wolfgang Werners-Lucchini w...@musensturm.de wrote: if I want a non-breaking-space I use a tilde '~' sign. For example in: bakerstreet~13 This has worked in my old context. But now, after my update, I get an very long space. Minimal example: \starttext

[NTG-context] Galleries with photos from ConTeXt meetings: any ideas?

2011-10-25 Thread Mojca Miklavec
Hello, we currently have two old galleries on contextgarden.net (both hidden, no links to them and both password protected). We have additional galleries on Facebook (accessible to a rather wide audience). And dozens of other photos that have never been uploaded anywhere. And some galleries

[NTG-context] Some more ToC questions

2011-10-25 Thread Alasdair McAndrew
Thanks to the great expertise of folk on this mailgroup, I have my chapter headings set so that each one comes out as Chapter n Name of Chapter However, I have a few more questions. First: if I use completecontent to display the contents, how can I have the Contents title display without my