Kirill Davidov schrieb am 14.09.2024 um 08:59:
Greetings,

As per Russian GOST standards, numbered section headings are flush left
and start with the paragraph indent. Is there a proper way to indent a
section heading? The code simulates what I want visually, but it
unfortunately causes the heading to poke out into the margins. That can
be troublesome if the title is long enough.

Example code to tinker with:

[...]


You have to use the narrow environment and apply it with the beforehead and afterhead command and in addition enable the aligntitle option.

%%%% begin example
\setupindenting
  [yes, 2.5em, first]

\setuphead
  [section]
  [
     align=flushleft,
     beforehead={\startnarrow[left=\parindent][left]},
     afterhead=\stopnarrow,
     aligntitle=yes,
     indentnext=yes,
   ]

\showframe

\startdocument

\startsection[title=Very long section title that makes you question the author's writing capabilities]

\input dijkstra

\stopsection

\stopdocument
%%%% end example

Wolfgang
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / 
https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki     : https://wiki.contextgarden.net
___________________________________________________________________________________

Reply via email to