ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Wolfgang Schuster <schuster.wolfgang@googlemail.com>
To: ntg-context@ntg.nl
Subject: Re: Long heading alignment
Date: Mon, 26 Mar 2007 21:08:48 +0200	[thread overview]
Message-ID: <20070326210848.001faafb.schuster.wolfgang@googlemail.com> (raw)
In-Reply-To: <853380686@web.de>

On Sun, 25 Mar 2007 21:36:12 +0200
Paul Schalck <schickele@web.de> wrote:

> Hello!
> 
> First, I want to thank you all. It's my first post here, but I've read many of your emails before, and I've already found a lot of solutions for my problems in there. I'm using Context intensely since several months (before, I was Latex) and at the moment, I'm setting my first big document (400 pages, very boring) with it.
> 
> My issue: I have a little problem with headings I can't solve by my own. It's rather simple: I would like to align headings that span across multiple lines on the left margin, like this:
> 
> a) This is (not really) a very, very, very
> loooooooooooooooong title 
> 
> and not that way:
> 
> a) This is (not really) a very, very, very
>    loooooooooooooooong title
> 
> The use of (\setuphead[section][command=\MySectionCommand] disables the standard alignment mechanism. I wonder if there is a simpler way to achieve this.
> 
> Any ideas? Thank you very much!
> 
> Scheeni Grieß (it's Alsatian German)
> Paul

Hi Paul,

the solution to you problem is very simple:

\def\MySectionCommand#1#2%
  {\vbox
     {\hsize\textwidth
       #1 #2}}

\setuphead
  [section]
  [command=\MySectionCommand]

\starttext

\section{\dorecurse{100}{foo }}

\stoptext

To learn more about this you can read the german book Einführung in TeX:
http://www.ruhr-uni-bochum.de/www-rz/schwanbs/TeX/

Wolfgang

      reply	other threads:[~2007-03-26 19:08 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-03-25 19:36 Paul Schalck
2007-03-26 19:08 ` Wolfgang Schuster [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20070326210848.001faafb.schuster.wolfgang@googlemail.com \
    --to=schuster.wolfgang@googlemail.com \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).