ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Wolfgang Schuster <schuster.wolfgang@gmail.com>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: \convertnumber with macro parameter
Date: Tue, 11 Jun 2013 14:46:34 +0200	[thread overview]
Message-ID: <B096AF8B-C4A6-4B8C-BDCC-84B4A01F1F14@gmail.com> (raw)
In-Reply-To: <51B719E3.60102@gmail.com>


[-- Attachment #1.1: Type: text/plain, Size: 1121 bytes --]


Am 11.06.2013 um 14:36 schrieb Jan Pohanka <xhpohanka@gmail.com>:

> 
>>> \convertnumber does not work on command parameter. What am I doing wrong? I know that I can use conversion key in setuphead, but I need slightly more complicated command.
>> 
>> Use \setuphead[section][conversion=I], you can’t use \convertnumber
>> because the first argument is the formatted (styles and colors are applied)
>> content of the section number.
>> 
>> 
> Thanks, I'm aware of this method and I mentioned it in the original question. The question is what to do if I need to use the command key to apply more complex formating using \framed etc.
> At least I need to make  \section{My section title} to print
> 
> I. Section
> My section title


You can create your own section layout.

\definesectionalternative[mysection][renderingsetup=mysection]

\startsetups[mysection]
  \vbox\bgroup
    \headsetupspacing
    \strut\headnumbercontent\par
    \begstrut\headtextcontent\endstrut
  \egroup
\stopsetups

\setuplabeltext[en][section={}{Section]

\setuphead[section][alternative=mysection]

Wolfgang

[-- Attachment #1.2: Type: text/html, Size: 3487 bytes --]

[-- Attachment #2: Type: text/plain, Size: 485 bytes --]

___________________________________________________________________________________
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
___________________________________________________________________________________

  reply	other threads:[~2013-06-11 12:46 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-11 12:22 Jan Pohanka
2013-06-11 12:29 ` Wolfgang Schuster
2013-06-11 12:36   ` Jan Pohanka
2013-06-11 12:46     ` Wolfgang Schuster [this message]
2013-06-11 13:53       ` Jan Pohanka
2013-06-11 14:00         ` Wolfgang Schuster
2013-06-12  6:58           ` Jan Pohanka

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=B096AF8B-C4A6-4B8C-BDCC-84B4A01F1F14@gmail.com \
    --to=schuster.wolfgang@gmail.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).