All, How do you get two enumerations to use a common counter? This didn't work. \setupoutput[pdf] \newcounter\NonFigCtr \define\nctr{\doglobal\increment\NonFigCtr \color[red]{[\NonFigCtr]}} \defineenumeration [remark] [location=serried, width=broad, text=Remark, headstyle=bold, inbetween=\blank, before=\blank, after=\blank, way=bysection, number=nctr] \defineenumeration [definition] [location=serried, width=broad, text=Definition, headstyle=bold, inbetween=\blank, before=\blank, after=\blank, way=bysection, number=nctr] \starttext \startremark Foo \stopremark \startdefinition Foo \stopdefinition \stoptext
David Arnold wrote:
All,
How do you get two enumerations to use a common counter? This didn't work.
just clone the definition one: \defineenumeration [remark] [location=serried, width=broad, text=Remark, headstyle=bold, inbetween=\blank, before=\blank, after=\blank, way=bysection] \defineenumeration [definition] [remark] [text=Definition] \starttext \startremark Foo \stopremark \startdefinition Foo \stopdefinition \stoptext
\setupoutput[pdf]
\newcounter\NonFigCtr \define\nctr{\doglobal\increment\NonFigCtr \color[red]{[\NonFigCtr]}}
\defineenumeration [remark] [location=serried, width=broad, text=Remark, headstyle=bold, inbetween=\blank, before=\blank, after=\blank, way=bysection, number=nctr]
\defineenumeration [definition] [location=serried, width=broad, text=Definition, headstyle=bold, inbetween=\blank, before=\blank, after=\blank, way=bysection, number=nctr]
\starttext
\startremark Foo \stopremark
\startdefinition Foo \stopdefinition
\stoptext _______________________________________________ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
-- ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
This is excellent. Now, how can I include this \placeformula[eq:nine] \startformula f(x)=x^2 \stopformula with the same common counter as remark and definition below?
just clone the definition one:
\defineenumeration [remark] [location=serried, width=broad, text=Remark, headstyle=bold, inbetween=\blank, before=\blank, after=\blank, way=bysection]
\defineenumeration [definition] [remark] [text=Definition]
\starttext \startremark Foo \stopremark \startdefinition Foo \stopdefinition \stoptext
\setupoutput[pdf]
\newcounter\NonFigCtr \define\nctr{\doglobal\increment\NonFigCtr \color[red]{[\NonFigCtr]}}
\defineenumeration [remark] [location=serried, width=broad, text=Remark, headstyle=bold, inbetween=\blank, before=\blank, after=\blank, way=bysection, number=nctr]
\defineenumeration [definition] [location=serried, width=broad, text=Definition, headstyle=bold, inbetween=\blank, before=\blank, after=\blank, way=bysection, number=nctr]
\starttext
\startremark Foo \stopremark
\startdefinition Foo \stopdefinition
\stoptext _______________________________________________ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
--
----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
_______________________________________________ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
David Arnold wrote:
This is excellent. Now, how can I include this
\placeformula[eq:nine] \startformula f(x)=x^2 \stopformula
with the same common counter as remark and definition below?
hm, it's incredible what users come up with but this time you're lucky -) \defineenumeration[whatever] \definenumber[davidsnumber] \setupnumber[whatever][number=davidsnumber] \setupnumber[formula] [number=davidsnumber] \starttext \placeformula[x] \startformula x\stopformula \startwhatever x\stopwhatever \placeformula[x] \startformula y\stopformula \startwhatever y\stopwhatever \stoptext (1) can you wikify this (2) can someone add this to the test suite since we need to make sure that it keeps working Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
participants (2)
-
David Arnold
-
Hans Hagen