[NTG-context] Broken mathalign in 2017.05.15
\starttext \startformula \startmathalignment[m=2,distance=4em] \NC \text{slope}_A \NC = 0 \NC \text{slope}_B \NC = \frac{1}{2} \NR \stopmathalignment \stopformula \stoptext In ConTeXt 2017.05.15 (shipped with TexLive 2017), the second column is formatted as text rather than math. The result gives 'slope_B' rather than placing B as a subscript. Online and with 2016.05.17 (shipped with TexLive 2016), the second column is formatted correctly as math. ___ 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] sectionconversionset not working for table of contents
Pablo, Excellent. Works like a charm. Many thanks. From Pablo's suggestion, I replaced my original two 'sectionblockenvironment' blocks with: \definestructureconversionset [sectionnumbers] [I,N,KR,a,m] [N] \definestructureconversionset [appendix:sectionnumbers] [O,A,R,r,KA] [R] \setupheads [chapter,section,subsection] [sectionconversionset=sectionnumbers] \startsectionblockenvironment [bodypart] \setuphead [chapter] [style={\rm\bf}, sectionsegments=chapter] \setuphead [section] [style={\ss\bf}, sectionsegments=section] \setuphead [subsection] [style={\sl}, sectionsegments=subsection] \stopsectionblockenvironment \startsectionblockenvironment [appendix] \setuphead [chapter] [style={\rm\bf}] \setuphead [section] [style={\sans}] \setuphead [subsection] [style={\sl}] \stopsectionblockenvironment ___ 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 ___
[NTG-context] sectionconversionset not working for table of contents
I am trying to number my bodymatter chapters differently than my appendix chapters but with little success. My attempts include the following: n If I do not assign a 'sectionconversionset' then the bodypart chapters are numbered with numerals and the appendix chapters are numbered with characters. However, sections and subsections are numbered with numerals in each the bodypart and appendix --- I don't want that. n Assigning a 'sectionconversionset' for the bodypart and appendix results in all chapters being numbered with numerals. Sections/subsections are still numerals. n Assigning a 'sectionconversionset' separately for each head type produces no change compared to the previous method. I obtained these results with the 2017 TeXLive version of ConTeXt 2017.05.15. The same result occurs with live.contextgarden.net. I've tried multiple variations, all with the same result. Any ideas would be greatly appreciated. Thanks. Kenny The rest of the message is a minimal example: \startsectionblockenvironment [bodypart] \definestructureconversionset [bodyset] [I,N,KR,a,m] [N] % unusual combination for testing \setuphead [chapter,section,subsection] [sectionconversionset=bodyset] \setuphead [chapter][style={\rm\bf}] \setuphead [section][style={\ss\bf}] \setuphead [subsection] [style={\sl}] \stopsectionblockenvironment \startsectionblockenvironment [appendix] \definestructureconversionset [appendixset] [O,A,R,r,KA] [R] \setuphead [chapter,section,subsection] [sectionconversionset=appendixset] \setuphead [chapter][style={\rm\bf}] \setuphead [section][style={\sans}] \setuphead [subsection] [style={\sl}] \stopsectionblockenvironment \setupcombinedlist [content] [list={chapter,section,subsection}] \setuplist [chapter] [style=\bigbodyfont\bold, alternative=b,] \setuplist [section] [width=2.0em, margin=2.0em, alternative=c,] \setuplist [subsection] [width=3.0em, margin=4.0em, style=slanted, alternative=c,] \startdocument \startfrontmatter \placecontent[criterium=all] \stopfrontmatter \startbodymatter \startchapter[title={The First Numerals Chapter}] \startsection[title={The First Caps-Romannumerals Section}] \input knuth \startsubsection[title={The First characters Subsection}] \input knuth \stopsubsection \stopsection \startsection[title={The Second Caps-Romannumerals Section}] \input knuth \stopsection \stopchapter \startchapter[title={The Second Numerals Chapter}] \startsection[title={The First Caps-Romannumerals Section}] \input knuth \stopsection \stopchapter \stopbodymatter \startappendices \startchapter[title={The First Characters Appendix}] \startsection[title={The First Romannumerals Section}] \input knuth \stopsection \stopchapter \startchapter[title={The Second Appendix}] \input knuth \startsection[title={The First Romannumerals Section}] \startsubsection[title={The First romannumerals Subsection}] \input knuth \stopsubsection \stopsection \stopchapter \stopappendices \stopdocument ___ 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 ___
[NTG-context] re-\place figure using the original figure number
I would like to have the same figure in multiple places in my document, but each instance should use the same figure number. \starttext \placefigure[right][fig-3-36]{}{\externalfigure[cow.pdf][width=2cm]} Here is the first instance of a figure, \in{Figure}[fig-3-36]. \placefigure[right][fig-4-200]{}{\externalfigure[mill.png][width=2cm]} Here is \in{Figure}[fig-4-200], just to spread things out. \placefigure[right][fig-3-36]{}{\externalfigure[cow.pdf][width=2cm]} Here is the original \in{Figure}[fig-3-36], but I would like for it to show the same figure number as the first instance \stoptext But I want the figure to be associated with certain text so that the user doesn't have to flip back to the original instance (it's a workbook of physics problems so certain setups get re-used). Any thoughts or suggestions would be great. ___ 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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
[NTG-context] split natural table
I use a natural table to format my page header. I have another natural table in the body. When the body's table is split onto the second page it interferes with the formatting of the header's table, but only the header-table on the first page. I've included an example. Run as-is, the header has the correct format. Uncomment the last row of the body table to see the incorrect header formatting. This behavior also occurs using live.contextgarden.net (today, 2013-05-21). The incorrect header table format occurs with split=yes and split=repeat for the body table. If split=no then the header table keeps the correct format. TexLive 2012 (updated 2013-05-20 to frozen version) LuaTeX beta-0.70.2-2012052410 ConTeXt: 2012.05.30 11:26 MkIV fmt: 2012.9.13 \setuppapersize[letter][letter] \setuplayout[topspace=0pt, header=42pt, headerdistance=6pt, ] \setuppagenumbering[location=] \setupwhitespace[none] \define\syllabusheader{% \vskip0.1mm \bTABLE[frame=off,width=\textwidth] \setupTABLE[c][1][width=fit, align=raggedright,style={\bfb\ss}] \setupTABLE[c][2][width=broad,align=center, style={\bfd\ss}] \setupTABLE[c][3][width=fit, align=raggedleft, style={\bfb\ss}] \bTR \bTD Left \eTD \bTD Center \eTD \bTD Right \eTD \eTR \eTABLE } \setupheadertexts[{\framed[corner=09,width=broad,align=center,height=\headerheight]% {\syllabusheader}}] \starttext \bTABLE[split=repeat] \setupTABLE[c][1][width=10em,align={center,lohi},style={\bfx}] \setupTABLE[r][1][align={hilo,center},style={\bfx}] \setupTABLE[c][2][width=20em,style={\tfx}] \bTABLEhead \bTR\bTH Row number \eTH\bTH Content \eTH\eTR \eTABLEhead \bTABLEbody \bTR\bTC 1 \eTC\bTC \input{knuth} \eTC\eTR \bTR\bTC 2 \eTC\bTC \input{knuth} \eTC\eTR \bTR\bTC 3 \eTC\bTC \input{knuth} \eTC\eTR % \bTR\bTC 4 \eTC\bTC \input{knuth} \eTC\eTR % Uncomment this line to see wrong behavior \eTABLEbody \eTABLE \stoptext ___ 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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] split natural table
From: ntg-context-boun...@ntg.nl [ntg-context-boun...@ntg.nl] on behalf of Wolfgang Schuster [schuster.wolfg...@gmail.com] Sent: Tuesday, May 21, 2013 12:20 PM To: mailing list for ConTeXt users Subject: Re: [NTG-context] split natural table Am 21.05.2013 um 18:55 schrieb Stephens, Kenny ksteph...@hsutx.edumailto:ksteph...@hsutx.edu: I use a natural table to format my page header. I have another natural table in the body. When the body’s table is split onto the second page it interferes with the formatting of the header’s table, but only the header-table on the first page. I’ve included an example. Run as-is, the header has the correct format. Uncomment the last row of the body table to see the incorrect header formatting. This behavior also occurs using live.contextgarden.nethttp://live.contextgarden.net (today, 2013-05-21). The incorrect header table format occurs with “split=yes” and “split=repeat” for the body table. If “split=no” then the header table keeps the correct format. TexLive 2012 (updated 2013-05-20 to frozen version) LuaTeX beta-0.70.2-2012052410 ConTeXt: 2012.05.30 11:26 MkIV fmt: 2012.9.13 \setuppapersize[letter][letter] \setuplayout[topspace=0pt, header=42pt, headerdistance=6pt, ] \setuppagenumbering[location=] \setupwhitespace[none] \define\syllabusheader{% \vskip0.1mm \bTABLE[frame=off,width=\textwidth] \setupTABLE[c][1][width=fit, align=raggedright,style={\bfb\ss}] \setupTABLE[c][2][width=broad,align=center, style={\bfd\ss}] \setupTABLE[c][3][width=fit, align=raggedleft, style={\bfb\ss}] \bTR \bTD Left \eTD \bTD Center \eTD \bTD Right \eTD \eTR \eTABLE } \setupheadertexts[{\framed[corner=09,width=broad,align=center,height=\headerheight]% {\syllabusheader}}] This is a known problem when you use the same table environment in the body and for the header, you can use \framed to get the same result without these problems (it’s also faster). \startsetups[header] \startframed[corner=09,width=max,height=max,align={middle,low},foregroundstyle=\ss\bfb,offset=1ex] \startoverlay {\leftaligned {Left}} {\midaligned {Middle}} {\rightaligned{Right}} \stopoverlay \stopframed \stopsetups \setupheadertexts[\texsetup{header}] Wolfgang -- This fails for me. I commented my approach and replaced it with yours. Here is what that section of the file now looks like: %\define\syllabusheader{% % \vskip0.1mm % \bTABLE[frame=off,width=\textwidth] % \setupTABLE[c][1][width=fit, align=raggedright,style={\bfb\ss}] % \setupTABLE[c][2][width=broad,align=center, style={\bfd\ss}] % \setupTABLE[c][3][width=fit, align=raggedleft, style={\bfb\ss}] % \bTR \bTD Left \eTD \bTD Center \eTD \bTD Right \eTD \eTR % \eTABLE % } %\setupheadertexts[{\framed[corner=09,width=broad,align=center,height=\headerheight]% % {\syllabusheader}}] \startsetups[header] \startframed[corner=09,width=max,height=max,align={middle,low},foregroundstyle=\ss\bfb,offset=1ex] \startoverlay {\leftaligned {Left}} {\midaligned {Middle}} {\rightaligned{Right}} \stopoverlay \stopframed \stopsetups \setupheadertexts[\texsetup{header}] But I get the error: ! Undefined control sequence. argument \texsetup {header}{}{}{} \firstoftwoarguments #1#2-#1 \doattributes ...sname #1#2\@EA \endcsname \fi {#4 }\dostopattributes \dosingletexts ...atetexts {#1#2#5}{#6{}{}{}}} \egroup argument ...tk \v!header \v!text \c!middletext } \hss }\hskip -\makeupwidth... \dododoplacelayouttextline ...#2 #3}\hbox to #1{#4 }\stoplayoutcomponent \get... ... l.46 \eTABLE But I like your idea. It is definitely cleaner and faster is always nice. Kenny ___ 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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
Re: [NTG-context] split natural table
Use the normal \framed command and replace \texsetup with \setups in \setupheadertexts and it will also work with your older version of context. \startsetups[header] \framed[corner=09,width=max,height=max,align={middle,low},foregroundstyle=\ss\bfb,offset=1ex]\bgroup \startoverlay {\leftaligned {Left}} {\midaligned {Middle}} {\rightaligned{Right}} \stopoverlay \egroup \stopsetups \setupheadertexts[\setups{header}] When you have a longer text for all three fields you need a different solution because \startoverlay … \stopoverlay can only position texts which fit in a single line. \startsetups[header] \framed[corner=09,width=max,height=max,foregroundstyle=\ss\bfb,offset=1ex]\bgroup \framed[frame=off,height=\vsize,width=.33\hsize,align={low,flushleft}] {Left} \framed[frame=off,height=\vsize,width=.33\hsize,align={low,middle}]{Middle} \framed[frame=off,height=\vsize,width=.33\hsize,align={low,flushright}]{Right} \egroup \stopsetups \setupheadertexts[\setups{header}] Wolfgang ___ I could not use \framed[corner=09,width=MAX,height=MAX,foregroundstyle=\ss\bfb,offset=1ex]\bgroup but \framed[corner=09,width=broad,height=\headerheight,foregroundstyle=\ss\bfb,offset=1ex]\bgroup worked perfectly. Many thanks. Keep up the good work on ConTeXt---it's becoming my favorite tool for creating materials for my courses, reports, letters, etc. Kenny ___ 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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___