[NTG-context] Referencing a figure
I have written a macro to include figures. I pass the label name and the caption as the two arguments. But when I try to refer to the figure, it shows ??. Surely, my macro does not define the figure label as intended by me. What am I doing wrong? Also, while trying to debug this problem, I tried using *\version[temporary]* to see the labels as suggested in the Context manual (chapter on Cross References (page 207) of cont-ini.pdf). But it didn't show many the label of the figure. MWE: \useMPlibrary[dum] \unprotect \define[2]\dincludefigure{% \placefigure[fig:#1]{#2}{\externalfigure[dummy][width=10cm]}% }% \protect \starttext \dincludefigure{one}{A figure} I am refering to \in{Figure}[fig:one]. \stoptext ___ 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 ___
Re: [NTG-context] Referencing a figure
Hi! ···date: 2013-01-22, Tuesday···from: Devendra Ghate··· I have written a macro to include figures. I pass the label name and the caption as the two arguments. But when I try to refer to the figure, it shows ??. Surely, my macro does not define the figure label as intended by me. What am I doing wrong? If you specify only one optional argument of \placefloat, then leftmost in the list is assumed, i.e. the location. To get around this, either specify a location or add empty brackets if you’re content with the default: \define[2]\dincludefigure{% \placefigure[][fig:#1]{#2}{\externalfigure[dummy][width=10cm]}% }% Regards Philipp Also, while trying to debug this problem, I tried using *\version[temporary]* to see the labels as suggested in the Context manual (chapter on Cross References (page 207) of cont-ini.pdf). But it didn't show many the label of the figure. MWE: \useMPlibrary[dum] \unprotect \define[2]\dincludefigure{% \placefigure[fig:#1]{#2}{\externalfigure[dummy][width=10cm]}% }% \protect \starttext \dincludefigure{one}{A figure} I am refering to \in{Figure}[fig:one]. \stoptext ___ 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 ___ -- () ascii ribbon campaign - against html e-mail /\ www.asciiribbon.org - against proprietary attachments pgpBNDpF7YmDK.pgp Description: PGP signature ___ 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 ___
Re: [NTG-context] Referencing a figure
On 01/22/2013 03:48 PM, Philipp Gesang wrote: Hi! ···date: 2013-01-22, Tuesday···from: Devendra Ghate··· I have written a macro to include figures. I pass the label name and the caption as the two arguments. But when I try to refer to the figure, it shows ??. Surely, my macro does not define the figure label as intended by me. What am I doing wrong? If you specify only one optional argument of \placefloat, then leftmost in the list is assumed, i.e. the location. To get around this, either specify a location or add empty brackets if you're content with the default: \define[2]\dincludefigure{% \placefigure[][fig:#1]{#2}{\externalfigure[dummy][width=10cm]}% }% Regards Philipp Thank you Philipp. Devendra Also, while trying to debug this problem, I tried using *\version[temporary]* to see the labels as suggested in the Context manual (chapter on Cross References (page 207) of cont-ini.pdf). But it didn't show many the label of the figure. MWE: \useMPlibrary[dum] \unprotect \define[2]\dincludefigure{% \placefigure[fig:#1]{#2}{\externalfigure[dummy][width=10cm]}% }% \protect \starttext \dincludefigure{one}{A figure} I am refering to \in{Figure}[fig:one]. \stoptext ___ 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 ___ ___ 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 ___ ___ 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 ___
Re: [NTG-context] Referencing a Figure
On Thu, 29 Apr 2010, Troy Henderson wrote: I am trying to reference a figure, and the results are not as expected. Here is my snippet. \placefigure[fig:myfigure]{A beautiful circle}{ \startMPcode draw fullcircle scaled 72; \stopMPcode } Isn't Figure \in[fig:myfigure] beautiful? Try \placefigure[here][fig:myfigure]{A beautiful circle}{ ... Greetings Albrecht When this code renders, the text says Isn't Figure ?? beautiful? How can I get the correct figure number? Thanks, Troy ___ 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 ___ ___ 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 ___
[NTG-context] Referencing a Figure
I am trying to reference a figure, and the results are not as expected. Here is my snippet. \placefigure[fig:myfigure]{A beautiful circle}{ \startMPcode draw fullcircle scaled 72; \stopMPcode } Isn't Figure \in[fig:myfigure] beautiful? When this code renders, the text says Isn't Figure ?? beautiful? How can I get the correct figure number? Thanks, Troy ___ 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 ___
Re: [NTG-context] Referencing a Figure
On Thu, 29 Apr 2010, Troy Henderson wrote: I am trying to reference a figure, and the results are not as expected. Here is my snippet. \placefigure[fig:myfigure]{A beautiful circle}{ \placefigure[][fig:myfigure]{...}{...} \startMPcode draw fullcircle scaled 72; \stopMPcode } Isn't Figure \in[fig:myfigure] beautiful? When this code renders, the text says Isn't Figure ?? beautiful? How can I get the correct figure number? When \placefigure is used with only one optional argument, the optional argument is interpreted as the placement specifier (here, left, right, top, bottom), rather than the label. Aditya ___ 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 ___
Re: [NTG-context] Referencing a Figure
Beautiful. Thanks. ___ 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 ___