* nested itemize in margin
@ 2013-10-23 22:15 John Kitzmiller
2013-10-24 7:01 ` Wolfgang Schuster
0 siblings, 1 reply; 2+ messages in thread
From: John Kitzmiller @ 2013-10-23 22:15 UTC (permalink / raw)
To: ntg-context
To enumerate answer blanks in the right margin to match the question, thanks to Marco:
\define\ansblank{\inright{\getnumber[itemgroup:itemize]. \thinrules[n=1]}}
\setupitemgroup [itemize] [n,style=bold,right=\ansblank]
I am trying to augment this to handle nested itemizations so that the \getnumber in the right margin is from the parent itemize but the "\getletter" is from the child:
\starttext
\startitemize[n]
\item First
\item Second
\startitemize[a]
\item Related problem % Would like this to show 2 a. before the marginrule
\item Related question % Would like this to show 2 b. before the marginrule
\stopitemize
\item Third
\stopitemize
\stoptext
Desired output:
1. First 1. _________
2. Second
a. Related problem 2a. ________
b. Related question 2b. ________
3. Third 3. _________
My attempts have been to define a new "blank" and use [conversion=Character] along with stabs from cont-eni.pdf, but I am flailing and failing.
Thanks for any help,
John
___________________________________________________________________________________
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: nested itemize in margin
2013-10-23 22:15 nested itemize in margin John Kitzmiller
@ 2013-10-24 7:01 ` Wolfgang Schuster
0 siblings, 0 replies; 2+ messages in thread
From: Wolfgang Schuster @ 2013-10-24 7:01 UTC (permalink / raw)
To: mailing list for ConTeXt users
Am 24.10.2013 um 00:15 schrieb John Kitzmiller <kitz@inradius.net>:
>
> To enumerate answer blanks in the right margin to match the question, thanks to Marco:
>
> \define\ansblank{\inright{\getnumber[itemgroup:itemize]. \thinrules[n=1]}}
\defineconversionset[myitemize][n,a][n]
\define\ansblank
{\inright
{\simplealignedbox{3em}{flushright}{\convertedcounter[itemgroup:itemize][numberconversionset=myitemize].}
\thinrules[n=1]}}
Wolfgang
___________________________________________________________________________________
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-10-24 7:01 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-10-23 22:15 nested itemize in margin John Kitzmiller
2013-10-24 7:01 ` Wolfgang Schuster
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).