Re: [NTG-context] columnset + floats = bad
Thanks for the suggestion Alan! I tried out the pagecolumns approach. According to the manual it seems to handle floats a bit better than the columnsets and I do not require spans right now. However, here another weird thing is happening. After the end of the pagecolumns an extra page is flushed even though it does not contain any material. Why? MWE is below, output of latest beta attached. Cheers, Henri --- \setuppapersize[A0] \setupbodyfont[sans,25pt] \definepagecolumns [threecolumn] [n=3] \setuppagecolumns [threecolumn] [distance=3cm] \starttext \startpagecolumns[threecolumn] \input lorem \column \input zapf\par \startplacefigure[title={\input zapf\par}] \externalfigure[dummy][width=\columnwidth] \stopplacefigure \input hawking\par \column \input Douglas\par \input bryson\par \startplacefigure[title={\input bryson\par}] \externalfigure[dummy][width=\columnwidth] \stopplacefigure \stoppagecolumns \stoptext On Mon, 2018-04-16 at 19:08 -0600, Alan Braslau wrote: > Hans points out that you need to use: > \setuplayout [grid=yes] > with columnsets (and floats). > > You can also try "pagecolumns", yet another mechanism, each has its own > charm. ;-) > > Alan > > > > > On Tue, 17 Apr 2018 12:59:46 +1200 > Henri Menkewrote: > > > > > Dear list, > > > > I wanted to make a conference poster in ConTeXt MKIV using the > > newcolumnsets. However, when I use floats weird shit is happening. > > Is this intended or am I doing something seriously wrong? MWE > > below, output of latest beta attached. > > > > Cheers, Henri > > > > --- > > > > \setuppapersize[A0] > > \setupbodyfont[sans,25pt] > > > > \usemodule[newcolumnsets] > > > > \definecolumnset > > [threecolumn] > > [n=3] > > > > \setupcolumnset > > [threecolumn] > > [distance=3cm] > > > > \starttext > > > > \startcolumnset[threecolumn] > > > > \input lorem > > > > \column > > > > \input zapf\par > > > > \startplacefigure[title={\input zapf\par}] > > \externalfigure[dummy][width=\textwidth] > > \stopplacefigure > > > > \input hawking\par > > > > \column > > > > \input Douglas\par > > > > \input bryson\par > > > > \startplacefigure[title={\input bryson\par}] > > \externalfigure[dummy][width=\textwidth] > > \stopplacefigure > > > > \stopcolumnset > > > > \stoptext test.pdf Description: Adobe PDF document ___ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___
Re: [NTG-context] Problem with Filter Module in latent context beta
On Tue, 17 Apr 2018, Aditya Mahajan wrote: On Tue, 17 Apr 2018, Hans Hagen wrote: On 4/17/2018 12:01 AM, Aditya Mahajan wrote: All features of the filter and vim modules work with the latest beta, except for one final bug: leading spaces are stripped from the buffer. \starttext \startbuffer[test] Leading spaces \stopbuffer \savebuffer[file=test-temp.tmp, prefix=no, list=test] \stoptext The leading spaces are stripped before the buffer is saved to the file temp.tmp. Is it possible for the leading space NOT to be stripped? (If not, I'll just document this as a feature :-). \samplefile{ward} \startnarrower \samplefile{ward} \startbuffer[test] Leading spaces And some more \stopbuffer \typebuffer[test] \stopnarrower \samplefile{ward} \startbuffer[test] Leading spaces And some more \stopbuffer \typebuffer[test] it is actually a feature to align the left edge relative to the least indented so that we can use them inside other constructs Now, as you're not afraid of low level code: \unprotect \unexpanded\def\StartAditya {\buff_pickup {Aditya}% {StartAditya}% {StopAditya}% {}% {\savebuffer[file=test-temp.tmp,prefix=no,list=Aditya]}% \zerocount} This is perfect as I am already using `\grabbufferdata` in my code. I can easily adapt it to use `\buff_pickup` instead. Thanks!. Does what you want but of course it's sort of ugly for a module to do that. What we can do is this which is still ugly but picking up verbatim is always ugly: \def\buff_start_indeed#1#2#3#4% {\edef\p_strip{\namedbufferparameter{#1}\c!strip}% \normalexpanded{\buff_pickup{#2}{#3}{#4}{}{\buff_stop{#4}}\ifx\p_strip\v!no\zerocount\else\plusone\fi}} \protect I want this to be configurable at runtime and the vim module already has code that enables `strip=yes` and `strip=no` options (I do this via a function in vim so that it works with both mkii and mkiv; although I don't think that anyone uses the mkii module any longer). I added `strip=yes` option to the filter module, which is now the default option. See "Stripping leading whitespace" in the module documentation (https://github.com/adityam/filter). This is a MkIV only feature and I will not implement it in MkII. I also made `strip=yes` to be the default in t-vim (to be consistent with t-filter). In t-vim, the `strip` option works with both mkii and mkiv. Aditya___ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___
Re: [NTG-context] Build for Alpine Linux
On 04/17/2018 05:25 PM, Arthur Reutenauer wrote: I can’t test musl support, but the new code should avoid the problem Thomas experienced. Best, Arthur I haven't had any trouble so far but need to test with another computer, tonight. Thomas ___ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___
Re: [NTG-context] Problem with Filter Module in latent context beta
On Tue, 17 Apr 2018, Hans Hagen wrote: On 4/17/2018 12:01 AM, Aditya Mahajan wrote: All features of the filter and vim modules work with the latest beta, except for one final bug: leading spaces are stripped from the buffer. \starttext \startbuffer[test] Leading spaces \stopbuffer \savebuffer[file=test-temp.tmp, prefix=no, list=test] \stoptext The leading spaces are stripped before the buffer is saved to the file temp.tmp. Is it possible for the leading space NOT to be stripped? (If not, I'll just document this as a feature :-). \samplefile{ward} \startnarrower \samplefile{ward} \startbuffer[test] Leading spaces And some more \stopbuffer \typebuffer[test] \stopnarrower \samplefile{ward} \startbuffer[test] Leading spaces And some more \stopbuffer \typebuffer[test] it is actually a feature to align the left edge relative to the least indented so that we can use them inside other constructs Now, as you're not afraid of low level code: \unprotect \unexpanded\def\StartAditya {\buff_pickup {Aditya}% {StartAditya}% {StopAditya}% {}% {\savebuffer[file=test-temp.tmp,prefix=no,list=Aditya]}% \zerocount} This is perfect as I am already using `\grabbufferdata` in my code. I can easily adapt it to use `\buff_pickup` instead. Thanks!. Does what you want but of course it's sort of ugly for a module to do that. What we can do is this which is still ugly but picking up verbatim is always ugly: \def\buff_start_indeed#1#2#3#4% {\edef\p_strip{\namedbufferparameter{#1}\c!strip}% \normalexpanded{\buff_pickup{#2}{#3}{#4}{}{\buff_stop{#4}}\ifx\p_strip\v!no\zerocount\else\plusone\fi}} \protect I want this to be configurable at runtime and the vim module already has code that enables `strip=yes` and `strip=no` options (I do this via a function in vim so that it works with both mkii and mkiv; although I don't think that anyone uses the mkii module any longer). Aditya___ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___
Re: [NTG-context] Problem with Filter Module in latent context beta
On 4/17/2018 12:01 AM, Aditya Mahajan wrote: All features of the filter and vim modules work with the latest beta, except for one final bug: leading spaces are stripped from the buffer. \starttext \startbuffer[test] Leading spaces \stopbuffer \savebuffer[file=test-temp.tmp, prefix=no, list=test] \stoptext The leading spaces are stripped before the buffer is saved to the file temp.tmp. Is it possible for the leading space NOT to be stripped? (If not, I'll just document this as a feature :-). \samplefile{ward} \startnarrower \samplefile{ward} \startbuffer[test] Leading spaces And some more \stopbuffer \typebuffer[test] \stopnarrower \samplefile{ward} \startbuffer[test] Leading spaces And some more \stopbuffer \typebuffer[test] it is actually a feature to align the left edge relative to the least indented so that we can use them inside other constructs Now, as you're not afraid of low level code: \unprotect \unexpanded\def\StartAditya {\buff_pickup {Aditya}% {StartAditya}% {StopAditya}% {}% {\savebuffer[file=test-temp.tmp,prefix=no,list=Aditya]}% \zerocount} \unexpanded\def\StopAditya {} \protect \StartAditya Leading spaces And some more \StopAditya (1) \typebuffer[Aditya] (2) \typefile{test-temp.tmp} Does what you want but of course it's sort of ugly for a module to do that. What we can do is this which is still ugly but picking up verbatim is always ugly: \unprotect \def\buff_start_indeed#1#2#3#4% {\edef\p_strip{\namedbufferparameter{#1}\c!strip}% \normalexpanded{\buff_pickup{#2}{#3}{#4}{}{\buff_stop{#4}}\ifx\p_strip\v!no\zerocount\else\plusone\fi}} \protect \definebuffer[Aditya][strip=no] \startAditya Leading spaces And some more And even more \stopAditya \typeAditya But then we need Wolfgang to double check if this extension has side effects elsewhere. Hans - Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl - ___ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___