1

I'm working in a ConTeXt document. I have this code:

\mainlanguage[es]
\language[es]
\setupcolors[state=start]
\usecolors[xwi]
\definecolor[color][maroon]
\setuphead[part][placehead=yes, bodypartlabel=part,
header=empty,
alternative=middle,
textstyle=\ss\smallcaps,
color=color,
numbercommand=\groupedcommand{}{\blank[2cm]},
after={\blank[3cm]},
]

\starttext

\part{{El platonismo matemático tradicional}}

\stoptext

I'd like to have the label "Parte 1" in black, and the title of the first part, "El platonismo matemático tradicional", asi it is, in maroon. ¿Haw can I do that? Thanks.

1
  • 1
    I was working on an alternative solution, but Henri's answer is better. Just one remark: please don't define a color by the name of "color." That's asking for trouble.
    – Thomas
    Aug 5, 2016 at 7:31

1 Answer 1

4

Use textcolor instead of color.

Colors are enabled by default in MkIV, so \setupcolors[state=start] is only necessary if you are typesetting with MkII (i.e. you use texexec instead of context) which you hopefully don't.

\mainlanguage[es]
\language[es]

\usecolors[xwi]
\definecolor[color][maroon]

\setuphead
  [part]
  [
    placehead=yes,
    bodypartlabel=part,
    header=empty,
    alternative=middle,
    textstyle=\ss\smallcaps,
    textcolor=color,
    numbercommand=\groupedcommand{}{\blank[2cm]},
    after={\blank[3cm]},
  ]

\starttext

\part{El platonismo matemático tradicional}

\stoptext

enter image description here

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .