From: Hans Hagen <pragma@wxs.nl>
To: ntg-context@ntg.nl
Subject: Re: about \inframed[] in \defineenumeration
Date: Tue, 5 Dec 2017 10:58:42 +0100 [thread overview]
Message-ID: <88774ea4-18d3-db7a-2019-e2f347bc9f52@wxs.nl> (raw)
In-Reply-To: <3A6C9D3B-1706-44D5-BB6F-65D2D89EC346@me.com>
On 12/4/2017 11:51 PM, Jeong Dal wrote:
> Hi,
>
> I run the old code which was fine 3 years ago, but now, it doesn’t work as before.
> At that time, I had “Example 1.1” inside the frame . Now I got text “Example 1.1” only without frame at all.
>
> Would you please tell me what should I change?
>
> Thank you for reading.
>
> Best regards,
>
> Dalyoung
>
> %%% minimal example %%%
> \setupcolors[state=start]
> \definecolor[dGreen] [r=0,g=.375,b=.0]
>
> \defineenumeration[Example]
> [command={\inframed[corner=round, background=color, backgroundcolor=darkgreen,height=1.3em]},
> text=Example,
> prefix=yes,
> prefixsegments=chapter,
> way=bychapter,
> number=yes,
> alternative=left,
> before={\blank[big]},
> after=\blank]
>
> \starttext
> \chapter{first}
> \startExample
> This is a test for enumeration.
> \stopExample
> \startExample
> This is a test for enumeration.
> \stopExample
> \stoptext
you need "numbercommand":
\defineenumeration
[Example]
[headcommand={\framed[background=color,backgroundcolor=red]},
numbercommand={\inframed[height=2ex,background=color,backgroundcolor=green]},
titlecommand={\inframed[height=2ex,background=color,backgroundcolor=blue]},
title=yes,
alternative=left,
before={\blank[big]},
after=\blank]
\starttext
\chapter{first}
\startExample{foo}
This is a test for enumeration.
\stopExample
\startExample
This is a test for enumeration.
\stopExample
\stoptext
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
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://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___________________________________________________________________________________
next prev parent reply other threads:[~2017-12-05 9:58 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <mailman.1513.1512287889.1988.ntg-context@ntg.nl>
2017-12-03 14:42 ` framed with titles Jeong Dal
2017-12-04 22:51 ` about \inframed[] in \defineenumeration Jeong Dal
2017-12-05 9:58 ` Hans Hagen [this message]
[not found] <mailman.1.1512471602.9861.ntg-context@ntg.nl>
2017-12-05 18:26 ` Jeong Dal
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=88774ea4-18d3-db7a-2019-e2f347bc9f52@wxs.nl \
--to=pragma@wxs.nl \
--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).