Am attempting to get an underlined head style (chapter) with: \setuphead[chapter][textcommand=\underbar] But I get no underline. Am I doing something wrong? I can, of course, achieve the result at each chapter level with \startchapter[title={\underbar{text}}] but would prefer to achieve this with \setuphead Julian
jbf schrieb am 21.09.2023 um 05:03:
Am attempting to get an underlined head style (chapter) with:
\setuphead[chapter][textcommand=\underbar]
But I get no underline. Am I doing something wrong? I can, of course, achieve the result at each chapter level with \startchapter[title={\underbar{text}}] but would prefer to achieve this with \setuphead
\setuphead[chapter][textcommand={\setbar[underbar]}] \starttext \chapter{\samplefile{ward}} \stoptext Wolfgang
However, Wolfgang, if I do, e.g. \setuphead[chapter][textcommand={\setbar[underbar]}] \starttext \startchapter[title={My title}] \input ward \stopchapter \stoptext Then I do not get My Title with underline, which is what I want, and nor is anything else underlined in 'Ward'. Could it be something to do with the version of LMTX? Mine is 2022.08.25 19:21 LMTX. I do have a workaround, with a \defineframed[underbarframed] and then setting offsets accordingly and using that as a textcommand. Julian On 21/9/23 14:26, Wolfgang Schuster wrote:
jbf schrieb am 21.09.2023 um 05:03:
Am attempting to get an underlined head style (chapter) with:
\setuphead[chapter][textcommand=\underbar]
But I get no underline. Am I doing something wrong? I can, of course, achieve the result at each chapter level with \startchapter[title={\underbar{text}}] but would prefer to achieve this with \setuphead
\setuphead[chapter][textcommand={\setbar[underbar]}]
\starttext
\chapter{\samplefile{ward}}
\stoptext
Wolfgang
jbf schrieb am 21.09.2023 um 07:01:
However, Wolfgang, if I do, e.g.
\setuphead[chapter][textcommand={\setbar[underbar]}]
\starttext
\startchapter[title={My title}]
\input ward
\stopchapter
\stoptext
Then I do not get My Title with underline, which is what I want, and nor is anything else underlined in 'Ward'.
I get a line below the chapter title with LMTX and LuaTeX with the current ConTeXt version. %%%% begin example \setuphead [chapter] [textcommand={\setbar[underbar]}] \starttext \startchapter[title={My title}] \input ward \stopchapter \stoptext %%%% end example The line is limited to the title because the textcommand key is used to set \underbar, when you want a line below the whole chapter content you can use the insidesection and aftersection keys. %%%% begin example \setuphead [chapter] [insidesection={\startbar[underbar]}, aftersection={\stopbar}] \starttext \startchapter[title={My title}] \input ward \stopchapter \stoptext %%%% end example Wolfgang
participants (2)
-
jbf
-
Wolfgang Schuster