Macro "inside" \component.
Hi! This works: \startproduct assorted \project math_video_classes \unexpanded\def\pathrelativetome% {src/products/assorted/open_mapping_theorem/notes} % \component{\pathrelativetome} \component{src/products/assorted/open_mapping_theorem/notes} \stopproduct But this does not work (no PDF is generated): \startproduct assorted \project math_video_classes \unexpanded\def\pathrelativetome% {src/products/assorted/open_mapping_theorem/notes} \component{\pathrelativetome} % \component{src/products/assorted/open_mapping_theorem/notes} \stopproduct WHY? Thank you, André Caldas.
Am 07.10.2012 um 00:41 schrieb Andre Caldas
Hi!
This works:
\startproduct assorted \project math_video_classes
\unexpanded\def\pathrelativetome% {src/products/assorted/open_mapping_theorem/notes}
% \component{\pathrelativetome} \component{src/products/assorted/open_mapping_theorem/notes} \stopproduct
But this does not work (no PDF is generated):
\startproduct assorted \project math_video_classes
\unexpanded\def\pathrelativetome% {src/products/assorted/open_mapping_theorem/notes}
\component{\pathrelativetome} % \component{src/products/assorted/open_mapping_theorem/notes} \stopproduct
WHY?
Why don’t you use the \usepath command. \startproduct assorted \usepath[src/products/assorted/open_mapping_theorem] \component notes \stopproduct I don’t know if this works with so many subdirectories because you do normally set the first level subdirectory with \usepath[…] (can be a list of directories) and the second level inside the first level with \usesubpath[…]. When you put now “\component …” or “\component […]” in your product file context will look for the requested file in the given subdirectories. Wolfgang
Hello!
Why don’t you use the \usepath command.
Because it is too magical. We DO need magic to locate system
libraries. But we DO NOT need magic to locate our own project files.
For this reason, the C language has
#include
On Sun, Oct 07 2012, Andre Caldas wrote:
it makes no sense to me that I cannot call "\component \macroname". Isn't it an expected behaviour?
I don't know the answer, but there is a workaround: \def\MyMacro{my-component} \def\MyComponent#1{\cldcontext{"\\component " .. "#1"}} \startproduct test \MyComponent{\MyMacro} \stopproduct -- Peter
Am 07.10.2012 um 22:30 schrieb Peter Münster
On Sun, Oct 07 2012, Andre Caldas wrote:
it makes no sense to me that I cannot call "\component \macroname". Isn't it an expected behaviour?
I don't know the answer, but there is a workaround:
\def\MyMacro{my-component} \def\MyComponent#1{\cldcontext{"\\component " .. "#1"}} \startproduct test \MyComponent{\MyMacro} \stopproduct
\startproduct text \component [\MyMacro] \stopproduct Wolfgang
participants (4)
-
Andre Caldas
-
Peter Münster
-
Wolfgang Schuster
-
Wolfgang Schuster