* reset \use[sub]path @ 2003-11-03 19:12 Pawel Jackowski na Onet 2003-11-03 21:05 ` Hans Hagen 0 siblings, 1 reply; 27+ messages in thread From: Pawel Jackowski na Onet @ 2003-11-03 19:12 UTC (permalink / raw) Hi all! Lets consider the following situation. There are 3 catalogs; ./lofo1, ./lofo2, ./lofo3, each of them contains files 'aqq.xml' and 'cow.png' for example. Filenames are the same, but they may have different content. I need to include all these files into one PDF document WITHOUT giving absolute paths in TeX code. I tried something like \usepath[lofo1] \processXMLfilegrouped{aqq.xml} \usepath[lofo2] \processXMLfilegrouped{aqq.xml} \usepath[lofo3] \processXMLfilegrouped{aqq.xml} but in this example the same file (./lofo1/aqq.xml) will be processed 3 times and that is not what I need. Actually the situation is even more complicated; I have quite big XML tree with hunderts of files and images, with dozens of catalogs. I wrote a perl script which change current directory for each process and run texexec in changed one. And it works OK since I want to have separate PDF document from each `lofo?' catalog. But how to make one PDF document in such situation using \use[sub]path texnique? In other words, how to reset settings from \usepath and \usesubpath commands? And how to do the same for externalfigures? Thanks in advance, Pawe/l ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: reset \use[sub]path 2003-11-03 19:12 reset \use[sub]path Pawel Jackowski na Onet @ 2003-11-03 21:05 ` Hans Hagen 2003-11-04 6:41 ` Pawel Jackowski na Onet 2003-11-15 21:36 ` page backgrounds Thomas A.Schmitz 0 siblings, 2 replies; 27+ messages in thread From: Hans Hagen @ 2003-11-03 21:05 UTC (permalink / raw) At 20:12 03/11/2003, you wrote: >In other words, how to reset settings from \usepath and \usesubpath >commands? And how to do the same for externalfigures? \usesubpath[reset] Hans ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: reset \use[sub]path 2003-11-03 21:05 ` Hans Hagen @ 2003-11-04 6:41 ` Pawel Jackowski na Onet 2003-11-10 16:37 ` Patrick Gundlach 2003-11-15 21:36 ` page backgrounds Thomas A.Schmitz 1 sibling, 1 reply; 27+ messages in thread From: Pawel Jackowski na Onet @ 2003-11-04 6:41 UTC (permalink / raw) problem: reseting input paths Hi Hans At 20:12 03/11/2003, Pawel wrote: > >In other words, how to reset settings from \usepath and \usesubpath >commands? And how to do the same for externalfigures? From: "Hans Hagen" <pragma@wxs.nl> > \usesubpath[reset] Thanks a lot but I still can't get it. After inspecting core-job.tex file and tried 'reset' option. Also without expected results. So what is wrong in the following code? \starttext \usesubpath[lofo1] \processXMLfilegrouped{aqq.xml} \usesubpath[reset] \usesubpath[lofo2] \processXMLfilegrouped{aqq.xml} \usesubpath[reset] \write16{\allinputpaths} \stoptext In this example \allinputpaths comma-list written to log looks like this: lofo1,lofo1/reset,lofo1/lofo2,lofo1/reset/lofo2,lofo1/reset/reset,lofo1/lofo 2/reset,lofo1/reset/lofo2/reset So 'reset' is treated as a directory name. Why? What am I doing wrong? Pawe/l ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: reset \use[sub]path 2003-11-04 6:41 ` Pawel Jackowski na Onet @ 2003-11-10 16:37 ` Patrick Gundlach 2003-11-10 17:26 ` Hans Hagen 2003-11-10 19:59 ` Pawel Jackowski na Onet 0 siblings, 2 replies; 27+ messages in thread From: Patrick Gundlach @ 2003-11-10 16:37 UTC (permalink / raw) Hi, > From: "Hans Hagen" <pragma@wxs.nl> >> \usesubpath[reset] Hans, are you sure about that? (\use*sub*path) > Also without expected results. So what is wrong in the following > code? > > \starttext > \usesubpath[lofo1] > \processXMLfilegrouped{aqq.xml} > \usesubpath[reset] try: \usepath[reset] Patrick -- You are your own rainbow! ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: Re: reset \use[sub]path 2003-11-10 16:37 ` Patrick Gundlach @ 2003-11-10 17:26 ` Hans Hagen 2003-11-10 19:59 ` Pawel Jackowski na Onet 1 sibling, 0 replies; 27+ messages in thread From: Hans Hagen @ 2003-11-10 17:26 UTC (permalink / raw) At 17:37 10/11/2003, you wrote: >Hi, > > > > From: "Hans Hagen" <pragma@wxs.nl> > >> \usesubpath[reset] > >Hans, are you sure about that? >(\use*sub*path) > > > Also without expected results. So what is wrong in the following > > code? > > > > > \starttext > > \usesubpath[lofo1] > > \processXMLfilegrouped{aqq.xml} > > \usesubpath[reset] > >try: \usepath[reset] indeed reset only works for usepath (has to do with the fact that any \usesubpath triggers extension of the path list) Hans ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: Re: reset \use[sub]path 2003-11-10 16:37 ` Patrick Gundlach 2003-11-10 17:26 ` Hans Hagen @ 2003-11-10 19:59 ` Pawel Jackowski na Onet 2003-11-10 23:02 ` Patrick Gundlach 1 sibling, 1 reply; 27+ messages in thread From: Pawel Jackowski na Onet @ 2003-11-10 19:59 UTC (permalink / raw) [-- Attachment #1: Type: text/plain, Size: 1153 bytes --] Problem: reset path > > Also without expected results. So what is wrong in the following > > code? > > > > > \starttext > > \usesubpath[lofo1] > > \processXMLfilegrouped{aqq.xml} > > \usesubpath[reset] > > try: \usepath[reset] I did so. I've noticed that 'reset' option works for \usepath only but I still get the solution. Please consider the following example (attached). We have './lofo1' and './lofo2' directories, each contains 'x.xml' file (the same filename but different content). ConTeXt code is as following: \starttext \usepath[lofo1] \processXMLfilegrouped{x.xml} \usepath[reset] \usepath[lofo2] \processXMLfilegrouped{x.xml} \stoptext In this case 'reset' option works probably OK, since \allinputpaths variable IS redefined to \empty (lines 99 to 104 of core-job.tex). So I expect that the first processed XML file should be './lofo1/x.xml' and the second -- './lofo2/x.xml'. But './lofo1/x.xml' file is processed twice instead. What construction should I use to process two or more XML files, which have the same name but different localization? I'm aware that my problem is not common but... Thanks for Your help, Pawe/l [-- Attachment #2: usepath.zip --] [-- Type: application/octet-stream, Size: 6083 bytes --] ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: reset \use[sub]path 2003-11-10 19:59 ` Pawel Jackowski na Onet @ 2003-11-10 23:02 ` Patrick Gundlach 2003-11-11 7:05 ` Pawel Jackowski na Onet 0 siblings, 1 reply; 27+ messages in thread From: Patrick Gundlach @ 2003-11-10 23:02 UTC (permalink / raw) Hello again, > I did so. I've noticed that 'reset' option works for \usepath only but I > still get the solution. Please consider the following example > (attached). OK, I had a close look at it and digged into deeper mechanisms of path handling in ConTeXt. ConTeXt stores the exact location of a file just by the filename. Once you read x.xml, ConTeXt remembers where it is. You get a hint when saying \tracefilestrue in your tex source. Next time you read x.xml, ConTeXt looks into its internal macros (fn..x.xml in this case) and reads the full path. And this is lofo1 in your case. I don't have a solution for you. Sorry. Patrick -- You are your own rainbow! ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: Re: reset \use[sub]path 2003-11-10 23:02 ` Patrick Gundlach @ 2003-11-11 7:05 ` Pawel Jackowski na Onet 0 siblings, 0 replies; 27+ messages in thread From: Pawel Jackowski na Onet @ 2003-11-11 7:05 UTC (permalink / raw) Problem: paths in ConTeXt > OK, I had a close look at it and digged into deeper mechanisms of > path handling in ConTeXt. > > ConTeXt stores the exact location of a file just by the filename. > Once you read x.xml, ConTeXt remembers where it is. You get a hint > when saying \tracefilestrue in your tex source. Next time you read > x.xml, ConTeXt looks into its internal macros (fn..x.xml in this > case) and reads the full path. And this is lofo1 in your case. > > > I don't have a solution for you. Sorry. Thanks anyway. No solution at this point is also some kinf of hint -) Regards, Pawe/l ^ permalink raw reply [flat|nested] 27+ messages in thread
* page backgrounds 2003-11-03 21:05 ` Hans Hagen 2003-11-04 6:41 ` Pawel Jackowski na Onet @ 2003-11-15 21:36 ` Thomas A.Schmitz 2003-11-16 20:08 ` Thomas A.Schmitz 2003-11-16 22:32 ` Patrick Gundlach 1 sibling, 2 replies; 27+ messages in thread From: Thomas A.Schmitz @ 2003-11-15 21:36 UTC (permalink / raw) These are my first forays into the unknown territories of Metapost. The following code is copied verbatim from the matafun-manual: \startuniqueMPgraphic{copyright} picture p ; p := btex COPYRIGHT etex rotated 90 ; setbounds p to boundingbox p enlarged 1pt ; draw p withcolor .8white ; currentpicture := currentpicture xysized (\overlaywidth,\overlayheight) ; \stopuniqueMPgraphic \defineoverlay[copyright][\uniqueMPgraphic{copyright}] \setupbackgrounds[text][rightmargin][background=copyright] But I don't see anything. The log shows that metapost calculated a background, but I don't see anything. What am I doing wrong? Best Thomas ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: page backgrounds 2003-11-15 21:36 ` page backgrounds Thomas A.Schmitz @ 2003-11-16 20:08 ` Thomas A.Schmitz 2003-11-17 9:59 ` Patrick Gundlach 2003-11-16 22:32 ` Patrick Gundlach 1 sibling, 1 reply; 27+ messages in thread From: Thomas A.Schmitz @ 2003-11-16 20:08 UTC (permalink / raw) Let me provide an answer myself: the btex ... etex doesn't seem to work. This code: \startuseMPgraphic{draft} draw "DRAFT" infont "phvb" scaled 9 rotated 57 withcolor .85white ; currentpicture := currentpicture ysized (\overlayheight-3cm) ; \stopuseMPgraphic \defineoverlay[draft][\uniqueMPgraphic{draft}] \setupbackgrounds[page][background=draft] will do what I want: provide a "watermark" for my document (or, as Hans writes, an "annoying text"). However, when I try the same with draw btex draft etex I don't get any output. Could you please verify if this is the case in your version of ConTeXt as well? Here's what I have (it's a vanilla teTeX implementation): ConTeXt ver: 2003.9.19 fmt: 2003.9.30 int: english mes: english MetaPost (Web2C 7.5.2) 0.641 Best Thomas ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: page backgrounds 2003-11-16 20:08 ` Thomas A.Schmitz @ 2003-11-17 9:59 ` Patrick Gundlach 2003-11-17 13:09 ` Thomas A. Schmitz 0 siblings, 1 reply; 27+ messages in thread From: Patrick Gundlach @ 2003-11-17 9:59 UTC (permalink / raw) "Thomas A.Schmitz" <thomas.schmitz@uni-bonn.de> writes: > Let me provide an answer myself: the btex ... etex doesn't seem to > work. This code: make sure \protectbufferstrue is set in cont-sys.tex Patrick -- You are your own rainbow! ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: Re: page backgrounds 2003-11-17 9:59 ` Patrick Gundlach @ 2003-11-17 13:09 ` Thomas A. Schmitz 2003-11-17 14:03 ` Otared Kavian ` (2 more replies) 0 siblings, 3 replies; 27+ messages in thread From: Thomas A. Schmitz @ 2003-11-17 13:09 UTC (permalink / raw) On Monday, November 17, 2003, at 10:59 AM, Patrick Gundlach wrote: > > make sure \protectbufferstrue is set in cont-sys.tex > Thanks, Patrick. \protectbufferstrue is uncommented (I guess that's the default, isn't it?). Does the btex...etex work on your box? Could anyone running Mac OS X (10.2 for the time being) verify if it works on their systems? Best Thomas ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: Re: page backgrounds 2003-11-17 13:09 ` Thomas A. Schmitz @ 2003-11-17 14:03 ` Otared Kavian 2003-11-17 14:41 ` Patrick Gundlach 2003-11-17 14:43 ` Patrick Gundlach 2003-11-17 14:08 ` Patrick Gundlach 2003-11-17 14:20 ` Adam Lindsay 2 siblings, 2 replies; 27+ messages in thread From: Otared Kavian @ 2003-11-17 14:03 UTC (permalink / raw) >On Monday, November 17, 2003, at 10:59 AM, Patrick Gundlach wrote: >> >>make sure \protectbufferstrue is set in cont-sys.tex >> >Thanks, Patrick. \protectbufferstrue is uncommented (I guess that's >the default, isn't it?). Does the btex...etex work on your box? >Could anyone running Mac OS X (10.2 for the time being) verify if it >works on their systems? > >Best > >Thomas Hi Thomas, I use Mac OS X (10.3 since today... but the following is independent of whether you use 10.2 or 10.3) together with TeXShop and Gerben Wierda's distribution of TeX. The first example you sent, that is: %% first example \startuniqueMPgraphic{copyright} picture p ; p := btex COPYRIGHT etex rotated 90 ; setbounds p to boundingbox p enlarged 1pt ; draw p withcolor .8white ; currentpicture := currentpicture xysized (\overlaywidth,\overlayheight) ; \stopuniqueMPgraphic \defineoverlay[copyright][\uniqueMPgraphic{copyright}] \setupbackgrounds[text][rightmargin][background=copyright] \starttext \input knuth.tex \stoptext %% end first example does not produce what is expected. The second example you sent, that is: %% second example \startuseMPgraphic{draft} draw "draft" infont "phvb" scaled 9 rotated 65 withcolor .95white ; currentpicture := currentpicture ysized (\overlayheight-3cm) ; \stopuseMPgraphic \defineoverlay[draft][\uniqueMPgraphic{draft}] \setupbackgrounds[page][background=draft] \starttext \input knuth.tex \stoptext %% end second example does produce the watermark "draft". The third example %% third example \startuseMPgraphic{brouillon} draw btex brouillon etex ; % draw "brouillon" infont "phvb" scaled 6 rotated 70 withcolor .95white ; currentpicture := currentpicture ysized (\overlayheight-3cm) ; \stopuseMPgraphic \defineoverlay[brouillon][\uniqueMPgraphic{brouillon}] \setupbackgrounds[page][background=brouillon] \starttext \input knuth.tex \stoptext %% end third example does not produce what is expected. I should say that I am not enough self-confidence to change the file cont-sys.tex as suggested by Patrick... Best regards: OK ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: page backgrounds 2003-11-17 14:03 ` Otared Kavian @ 2003-11-17 14:41 ` Patrick Gundlach 2003-11-17 14:43 ` Patrick Gundlach 1 sibling, 0 replies; 27+ messages in thread From: Patrick Gundlach @ 2003-11-17 14:41 UTC (permalink / raw) Otared Kavian <otared@wanadoo.fr> writes: [...] (I changed the lines....) > The third example > does not produce what is expected. what did you expect? > \startuseMPgraphic{brouillon} > draw btex brouillon etex ; > currentpicture := currentpicture ysized (\overlayheight-3cm) ; this command scales (vertically) the brouillon to \overlayheight -3 cm. This is very large > \stopuseMPgraphic > \defineoverlay[brouillon][\uniqueMPgraphic{brouillon}] > \setupbackgrounds[page][background=brouillon] and this one centers your graphic (the large brouillon) on the page. > I should say that I am not enough self-confidence to change the file > cont-sys.tex as suggested by Patrick... If you get some results from btex...etex, you don't have to. Patrick -- You are your own rainbow! ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: page backgrounds 2003-11-17 14:03 ` Otared Kavian 2003-11-17 14:41 ` Patrick Gundlach @ 2003-11-17 14:43 ` Patrick Gundlach 1 sibling, 0 replies; 27+ messages in thread From: Patrick Gundlach @ 2003-11-17 14:43 UTC (permalink / raw) Hi again, > The first example you sent, that is: [...] > does not produce what is expected. It should print "COPYRIGHT" in the right margin. It works fine here. Patrick -- You are your own rainbow! ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: page backgrounds 2003-11-17 13:09 ` Thomas A. Schmitz 2003-11-17 14:03 ` Otared Kavian @ 2003-11-17 14:08 ` Patrick Gundlach 2003-11-17 14:20 ` Adam Lindsay 2 siblings, 0 replies; 27+ messages in thread From: Patrick Gundlach @ 2003-11-17 14:08 UTC (permalink / raw) Hello, > Thanks, Patrick. \protectbufferstrue is uncommented (I guess that's > the default, isn't it?). Right, I just checked. It was a common error in the past. > Does the btex...etex work on your box? Could anyone running Mac OS X > (10.2 for the time being) verify if it works on their systems? Yes, it does work here on OS X (Jaguar). I tried your example from yesterday (slightly patched, though because there was no \starttext...) Please post your complete logfile. Patrick ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: Re: page backgrounds 2003-11-17 13:09 ` Thomas A. Schmitz 2003-11-17 14:03 ` Otared Kavian 2003-11-17 14:08 ` Patrick Gundlach @ 2003-11-17 14:20 ` Adam Lindsay 2 siblings, 0 replies; 27+ messages in thread From: Adam Lindsay @ 2003-11-17 14:20 UTC (permalink / raw) Thomas A. Schmitz said this at Mon, 17 Nov 2003 14:09:45 +0100: > >On Monday, November 17, 2003, at 10:59 AM, Patrick Gundlach wrote: >> >> make sure \protectbufferstrue is set in cont-sys.tex >> >Thanks, Patrick. \protectbufferstrue is uncommented (I guess that's the >default, isn't it?). Does the btex...etex work on your box? Could >anyone running Mac OS X (10.2 for the time being) verify if it works on >their systems? After verifying configuration on my machines, it works. The TeXLive2003 on MacOSX install (main computer) worked fine, without anything extra. I have a gwTeX install on a second computer, and it took a bit of work to get it going: enabled \write18 by changing shell_escape to 't' in texmf.cnf Copied user/cont-sys.rme to user/cont-sys.tex. Did a 'sudo texhash' to be sure changes are made. Edited cont-sys.tex and uncommented the following lines: \runMPgraphicstrue \runMPTEXgraphicstrue \useMETAFUNformattrue % make sure you have a format! In short, I followed the suggestions in minstall.pdf! After all that, I was able to run both the "copyright" and "draft" examples without any problem. The down-side is that it takes a bit of confidence at the command line to find all these files. I have to wonder if it would help to ship and configure gwTeX/ConTeXt with better defaults for the Mac... Otared, I would suggest making the changes recommended in pages 8-9... they unlock a lot of functionality that seems to be "hidden" in ConTeXt! adam -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Adam T. Lindsay atl@comp.lancs.ac.uk Computing Dept, Lancaster University +44(0)1524/594.537 Lancaster, LA1 4YR, UK Fax:+44(0)1524/593.608 -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: page backgrounds 2003-11-15 21:36 ` page backgrounds Thomas A.Schmitz 2003-11-16 20:08 ` Thomas A.Schmitz @ 2003-11-16 22:32 ` Patrick Gundlach 1 sibling, 0 replies; 27+ messages in thread From: Patrick Gundlach @ 2003-11-16 22:32 UTC (permalink / raw) Hello Thomas, > These are my first forays into the unknown territories of Metapost. You'll enjoy your journey once you get MP working. > The following code is copied verbatim from the matafun-manual: [...] > But I don't see anything. The log shows that metapost calculated a > background, but I don't see anything. What am I doing wrong? Your complete log might be interesting. Did you enable the write18 feature in texmf.cnf (not necessary, but nice since it lets tex generate the MP graphics on the fly)? Did you put any text between \starttext and \stoptext? Do you have \protectbufferstrue in cont-sys.tex? Patrick ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: page backgrounds @ 2003-11-17 15:11 Thomas A. Schmitz 0 siblings, 0 replies; 27+ messages in thread From: Thomas A. Schmitz @ 2003-11-17 15:11 UTC (permalink / raw) Patrick, Otared, Adam, thanks for looking into this. Adam's solutions works, wonderful!! Now I'll be able to have lots of "annoying texts" as watermarks. But those were a lot of changes to config files. Though I feel confident on the command line, I must admit I never bothered to look into minstall.pdf; I figured I had a working installation. Adam, you're definitely right: it would be nice if we could have gwtex's standards set to something more useful! Thanks everybody, another satisfied customer! Thomas ^ permalink raw reply [flat|nested] 27+ messages in thread
* page backgrounds @ 2007-11-13 10:26 olivier Turlier 2007-11-13 15:52 ` Wolfgang Schuster 2007-11-13 18:12 ` Peter Rolf 0 siblings, 2 replies; 27+ messages in thread From: olivier Turlier @ 2007-11-13 10:26 UTC (permalink / raw) To: ntg-context [-- Attachment #1: Type: text/plain, Size: 392 bytes --] Hi everybody, I try to draw several metapost page backgrounds (code found at http://melusine.eu.org/syracuse/poulecl/divers/papiers/ ) for manual sketchs on A4 paper. Obviously, it does'nt work, and I don't know why. TIA for any answers. Not so short examples are attached. -- olivier Turlier CRP La Rouguière 101 Bd des libérateurs 13367 MARSEILLE CEDEX 11 04 91 66 58 10 [-- Attachment #2: pb-mp-bkgrd.zip --] [-- Type: application/x-zip, Size: 2877 bytes --] [-- Attachment #3: Type: text/plain, Size: 487 bytes --] ___________________________________________________________________________________ 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 : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: page backgrounds 2007-11-13 10:26 olivier Turlier @ 2007-11-13 15:52 ` Wolfgang Schuster 2007-11-13 18:12 ` Peter Rolf 1 sibling, 0 replies; 27+ messages in thread From: Wolfgang Schuster @ 2007-11-13 15:52 UTC (permalink / raw) To: mailing list for ConTeXt users 2007/11/13, olivier Turlier <o.turlier@gmail.com>: > Hi everybody, > I try to draw several metapost page backgrounds (code found at > http://melusine.eu.org/syracuse/poulecl/divers/papiers/ ) for manual > sketchs on A4 paper. > Obviously, it does'nt work, and I don't know why. > TIA for any answers. > Not so short examples are attached. Take a look into Hans MetaFun manual [1]. He defined a few MetaPost macros to draw grids (page 205+). [1] http://pragma-ade.nl/general/manuals/metafun-p.pdf 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 : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: page backgrounds 2007-11-13 10:26 olivier Turlier 2007-11-13 15:52 ` Wolfgang Schuster @ 2007-11-13 18:12 ` Peter Rolf 2007-11-14 15:46 ` olivier Turlier 1 sibling, 1 reply; 27+ messages in thread From: Peter Rolf @ 2007-11-13 18:12 UTC (permalink / raw) To: mailing list for ConTeXt users [-- Attachment #1: Type: text/plain, Size: 1089 bytes --] Hi Olivier, olivier Turlier schrieb: > Hi everybody, > I try to draw several metapost page backgrounds (code found at > http://melusine.eu.org/syracuse/poulecl/divers/papiers/ ) for manual > sketchs on A4 paper. > Obviously, it does'nt work, and I don't know why. > TIA for any answers. > Not so short examples are attached. not so short working example attached. I had some problems with MP (compilations stops in MP; CTRL-D or typing 'end' works)...I donno. Some eof mess. Best wishes, Peter > > > > ------------------------------------------------------------------------ > > ___________________________________________________________________________________ > 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 : https://foundry.supelec.fr/projects/contextrev/ > wiki : http://contextgarden.net > ___________________________________________________________________________________ [-- Attachment #2: papier-quadrille.tex --] [-- Type: text/plain, Size: 5902 bytes --] \mainlanguage[fr] %D Format de papier A4. \setuppapersize[A4][A4] \setuplayout [width=middle, topspace=1.5cm, height=middle, header=1cm, footer=1cm] \setupcolors[state=start] \MPinclusions{\input constantes.mp \input papiers.mp} \starttext %---------------------------------------------------------------------------------- \startuseMPgraphic{Papier5trait} %input constantes; %input papiers; color macouleur; macouleur = .7(green+blue); % beginfig(1); papiercinq((-5,-5),(5,5),macouleur); % endfig; % end \stopuseMPgraphic \defineoverlay[Papier5trait][\useMPgraphic{Papier5trait}] % \defineframedtext[Papier5trait][background=Papier5trait,width=fit,offset=2ex,frame=on,framecolor=red,rulethickness=3pt,corner=round,style=type] % \defineframedtext[Papier5trait][align=middle,width=\overlaywidth,height=\overlayheight,frame=off,background=Papier5trait] % \definetextbackground[Papier5trait][location=paragraph,backgroundcolor=white,before=\blank,after=\blank] \startsetups[Papier5trait] %\startstandardmakeup \setupbackgrounds [page] [background=Papier5trait] %\stopstandardmakeup \setuplayout%[reset] % without parameter--> recalculate layout \stopsetups %---------------------------------------------------------------------------------- \startuseMPgraphic{Papier5point} %input constantes; %input papiers; color macouleur; macouleur = .7(red+blue); % beginfig(1); papierpointe((-5,-5),(5,5),macouleur); % endfig; % end \stopuseMPgraphic \defineoverlay[Papier5point][\useMPgraphic{Papier5point}] % \defineframedtext[Papier5point][background=Papier5point,width=fit,offset=2ex,frame=off] \startsetups[Papier5point] %\startstandardmakeup \setupbackgrounds [page] [background=Papier5point] %\stopstandardmakeup \setuplayout%[reset] \stopsetups %---------------------------------------------------------------------------------- \startuseMPgraphic{Papiermillimetre} %input constantes; %input papiers; color macouleur; macouleur = .8*orange; % beginfig(1); papiermil((-4cm,-4cm),1,1,(-5,-5),(5,5),macouleur); % endfig; % end \stopuseMPgraphic \defineoverlay[Papiermillimetre][\useMPgraphic{Papiermillimetre}] % \defineframedtext[Papiermillimetre][background=Papiermillimetre,width=fit,offset=2ex,frame=off] \startsetups[Papiermillimetre] %\startstandardmakeup \setupbackgrounds [page] [background=Papiermillimetre] %\stopstandardmakeup \setuplayout%[reset] \stopsetups %---------------------------------------------------------------------------------- \startuseMPgraphic{Papier10trait} %input constantes; %input papiers; color macouleur; macouleur = .7(red+green); % beginfig(1); papierun((-5,-5),(5,5),macouleur); % endfig; % end \stopuseMPgraphic \defineoverlay[Papier10trait][\useMPgraphic{Papier10trait}] % \defineframedtext[Papier10trait][background=Papier10trait,width=fit,offset=2ex,frame=off] \startsetups[Papier10trait] %\startstandardmakeup \setupbackgrounds [page] [background=Papier10trait] %\stopstandardmakeup \setuplayout%[reset] \stopsetups %---------------------------------------------------------------------------------- \startuseMPgraphic{Papiercahierseyes} %input constantes; %input papiers; color macouleur; macouleur = .7[red,blue]; % beginfig(1); papiercahier((-5,-5),(5,5),macouleur); % endfig; % end \stopuseMPgraphic \defineoverlay[Papiercahierseyes][\useMPgraphic{Papiercahierseyes}] % \defineframedtext[Papiercahierseyes][background=Papiercahierseyes,width=fit,offset=2ex,frame=off] \startsetups[Papiercahierseyes] %\startstandardmakeup \setupbackgrounds [page] [background=Papiercahierseyes] %\stopstandardmakeup \setuplayout%[reset] \stopsetups %---------------------------------------------------------------------------------- \startuseMPgraphic{Papierisotrait} %input constantes; %input papiers; color macouleur; macouleur = .7[green,red]; % beginfig(1); papierisom((-5,-5),(5,5),macouleur); % endfig; % end \stopuseMPgraphic \defineoverlay[Papierisotrait][\useMPgraphic{Papierisotrait}] % \defineframedtext[Papierisotrait][background=Papierisotrait,width=fit,offset=2ex,frame=off] \startsetups[Papierisotrait] %\startstandardmakeup \setupbackgrounds [page] [background=Papierisotrait] %\stopstandardmakeup \setuplayout%[reset] \stopsetups %----------------------------------------------------------------------------- % \setupbackgrounds[page][background=Papier5trait] \setups[Papier5trait] \startstandardmakeup % \framed[background=Papier5trait]{1 } % \startPapier5trait 1 \vfill{} % \stopPapier5trait %\setupbackgrounds[page][background=] \page \stopstandardmakeup %----------------------------------------------------------------------------- % \setupbackgrounds[page][background=Papier5point] \setups[Papier5point] \startstandardmakeup 2 \vfill{} %\setupbackgrounds[page][background=] \page \stopstandardmakeup %----------------------------------------------------------------------------- % \setupbackgrounds[page][background=Papiermillimetre] \setups[Papiermillimetre] \startstandardmakeup % \startPapiermillimetre 3 \vfill{} % \stopPapiermillimetre %\setupbackgrounds[page][background=] \page \stopstandardmakeup %----------------------------------------------------------------------------- % \setupbackgrounds[page][background=Papier10trait] \setups[Papier10trait] \startstandardmakeup 4 \vfill{} %\setupbackgrounds[page][background=] \page \stopstandardmakeup %----------------------------------------------------------------------------- % \setupbackgrounds[page][background=Papiercahierseyes] \setups[Papiercahierseyes] \startstandardmakeup 5 \vfill{} %\setupbackgrounds[page][background=] \page \stopstandardmakeup %----------------------------------------------------------------------------- % \setupbackgrounds[page][background=Papierisotrait] \setups[Papierisotrait] \startstandardmakeup 6 \vfill{} %\setupbackgrounds[page][background=] \page \stopstandardmakeup \stoptext [-- Attachment #3: Type: text/plain, Size: 487 bytes --] ___________________________________________________________________________________ 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 : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: page backgrounds 2007-11-13 18:12 ` Peter Rolf @ 2007-11-14 15:46 ` olivier Turlier 0 siblings, 0 replies; 27+ messages in thread From: olivier Turlier @ 2007-11-14 15:46 UTC (permalink / raw) To: ntg-context Peter Rolf wrote: > Hi Olivier, > > olivier Turlier schrieb: >> Hi everybody, >> I try to draw several metapost page backgrounds (code found at >> http://melusine.eu.org/syracuse/poulecl/divers/papiers/ ) for manual >> sketchs on A4 paper. >> Obviously, it does'nt work, and I don't know why. >> TIA for any answers. >> Not so short examples are attached. > > not so short working example attached. I had some problems with MP > (compilations stops in MP; CTRL-D or typing 'end' works)...I donno. Some > eof mess. > > Best wishes, Peter >> >> >> >> ------------------------------------------------------------------------ >> >> ___________________________________________________________________________________ >> 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 : https://foundry.supelec.fr/projects/contextrev/ >> wiki : http://contextgarden.net >> ___________________________________________________________________________________ Hi Peter, Thanks for your answer. I'm still unable to produce the desired pdf, both on texlive 2005 (ubuntu festy) and 2007 (gutsy). I've located an error in a metapost "inclusion" file, because context is complaining in the log file : ... TeXExec | processing graphic 'papier-quadrille-mpgraph.mp' This is MetaPost, Version 0.993 (Web2C 7.5.6) (/usr/share/texmf/web2c/natural.tcx) (papier-quadrille-mpgraph.mp (constantes.mp) (papiers.mp >> papiers.mp >> papiers.mpx ! Unable to make mpx file. l.70 dotlabel.llft(btex $O$ etex,(x.origine*cm,y.origine*cm)); I'll test solutions later, as I just enter in a super-charged era @ work. Thanks again -- olivier Turlier CRP La Rouguière 101 Bd des libérateurs 13367 MARSEILLE CEDEX 11 04 91 66 58 10 ___________________________________________________________________________________ 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 : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ ^ permalink raw reply [flat|nested] 27+ messages in thread
* Page Backgrounds @ 2012-07-09 2:47 Kip Warner 2012-07-09 7:45 ` Hans Hagen 2012-07-09 8:06 ` Wolfgang Schuster 0 siblings, 2 replies; 27+ messages in thread From: Kip Warner @ 2012-07-09 2:47 UTC (permalink / raw) To: mailing list for ConTeXt users [-- Attachment #1.1: Type: text/plain, Size: 1524 bytes --] Hey list, On the cover page of my book I'd like just an image displayed and another image used as the background for every other page in the book. So I put this in my environment, % Cover image... \definelayer [CoverImage] [x=0mm, y=0mm, \paperwidth, \paperheight] \setupbackgrounds[page][background=CoverImage] \setlayer [CoverImage] % name of the layer {\externalfigure [Makeup/Images/Cover.jpg] [align=center, \paperwidth, \paperheight]} % the actual contents of the layer % Regular background image... \definelayer [BackgroundImage] [x=0mm, y=0mm, \paperwidth, \paperheight, repeat=yes] \setlayer [BackgroundImage] % name of the layer {\externalfigure [Makeup/Images/Background.png] [align=center, \paperwidth, \paperheight]} % the actual contents of the layer , the following in the book's first page, \setupbackgrounds[page][background=CoverImage] , and the following on second page, \setupbackgrounds[page][background=BackgroundImage] . But this does not work properly. What ends up happening is the cover image is displayed correctly, but every page after that just has a blank white background. -- Kip Warner -- Software Engineer OpenPGP encrypted/signed mail preferred http://www.thevertigo.com [-- Attachment #1.2: This is a digitally signed message part --] [-- Type: application/pgp-signature, Size: 198 bytes --] [-- Attachment #2: Type: text/plain, Size: 485 bytes --] ___________________________________________________________________________________ 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] 27+ messages in thread
* Re: Page Backgrounds 2012-07-09 2:47 Page Backgrounds Kip Warner @ 2012-07-09 7:45 ` Hans Hagen 2012-07-09 8:06 ` Wolfgang Schuster 1 sibling, 0 replies; 27+ messages in thread From: Hans Hagen @ 2012-07-09 7:45 UTC (permalink / raw) To: mailing list for ConTeXt users; +Cc: Kip Warner On 9-7-2012 04:47, Kip Warner wrote: > Hey list, > > On the cover page of my book I'd like just an image displayed and > another image used as the background for every other page in the book. > So I put this in my environment, > > % Cover image... > \definelayer > [CoverImage] > [x=0mm, y=0mm, > \paperwidth, > \paperheight] > \setupbackgrounds[page][background=CoverImage] > > \setlayer > [CoverImage] % name of the layer > {\externalfigure > [Makeup/Images/Cover.jpg] > [align=center, > \paperwidth, > \paperheight]} % the actual contents of the layer > > % Regular background image... > \definelayer > [BackgroundImage] > [x=0mm, y=0mm, > \paperwidth, > \paperheight, > repeat=yes] > > \setlayer > [BackgroundImage] % name of the layer > {\externalfigure > [Makeup/Images/Background.png] > [align=center, > \paperwidth, > \paperheight]} % the actual contents of the layer less code: \defineoverlay [BackgroundImage] [\overlayfigure{Makeup/Images/Background.png}] > , the following in the book's first page, > > \setupbackgrounds[page][background=CoverImage] > > , and the following on second page, > > \setupbackgrounds[page][background=BackgroundImage] > > .. But this does not work properly. What ends up happening is the cover > image is displayed correctly, but every page after that just has a blank > white background. state=repeat Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com | 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://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ ^ permalink raw reply [flat|nested] 27+ messages in thread
* Re: Page Backgrounds 2012-07-09 2:47 Page Backgrounds Kip Warner 2012-07-09 7:45 ` Hans Hagen @ 2012-07-09 8:06 ` Wolfgang Schuster 2012-07-10 0:28 ` Kip Warner 1 sibling, 1 reply; 27+ messages in thread From: Wolfgang Schuster @ 2012-07-09 8:06 UTC (permalink / raw) To: mailing list for ConTeXt users Am 09.07.2012 um 04:47 schrieb Kip Warner: > Hey list, > > On the cover page of my book I'd like just an image displayed and > another image used as the background for every other page in the book. > So I put this in my environment, > > % Cover image... > \definelayer > [CoverImage] > [x=0mm, y=0mm, > \paperwidth, > \paperheight] > \setupbackgrounds[page][background=CoverImage] > > \setlayer > [CoverImage] % name of the layer > {\externalfigure > [Makeup/Images/Cover.jpg] > [align=center, > \paperwidth, > \paperheight]} % the actual contents of the layer > > % Regular background image... > \definelayer > [BackgroundImage] > [x=0mm, y=0mm, > \paperwidth, > \paperheight, > repeat=yes] > > \setlayer > [BackgroundImage] % name of the layer > {\externalfigure > [Makeup/Images/Background.png] > [align=center, > \paperwidth, > \paperheight]} % the actual contents of the layer > > , the following in the book's first page, > > \setupbackgrounds[page][background=CoverImage] > > , and the following on second page, > > \setupbackgrounds[page][background=BackgroundImage] > > . But this does not work properly. What ends up happening is the cover > image is displayed correctly, but every page after that just has a blank > white background. \setupexternalfigures[directory=Makeup/Images] \defineoverlay [backgroundimage] [{\ifnum\rawcountervalue[userpage]=1\relax \overlayfigure{Cover}% \else \overlayfigure{Background}% \fi}] \setupbackgrounds[page][background=backgroundimage] \starttext \dorecurse{4}{\input knuth\page} \stoptext 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] 27+ messages in thread
* Re: Page Backgrounds 2012-07-09 8:06 ` Wolfgang Schuster @ 2012-07-10 0:28 ` Kip Warner 0 siblings, 0 replies; 27+ messages in thread From: Kip Warner @ 2012-07-10 0:28 UTC (permalink / raw) To: mailing list for ConTeXt users; +Cc: Hans Hagen [-- Attachment #1.1: Type: text/plain, Size: 627 bytes --] On Mon, 2012-07-09 at 10:06 +0200, Wolfgang Schuster wrote: > \setupexternalfigures[directory=Makeup/Images] > > \defineoverlay > [backgroundimage] > [{\ifnum\rawcountervalue[userpage]=1\relax > \overlayfigure{Cover}% > \else > \overlayfigure{Background}% > \fi}] > > \setupbackgrounds[page][background=backgroundimage] > > \starttext > \dorecurse{4}{\input knuth\page} > \stoptext > > Wolfgang Thanks Wolfgang. That did it. Although I did change userpage to realpage. -- Kip Warner -- Software Engineer OpenPGP encrypted/signed mail preferred http://www.thevertigo.com [-- Attachment #1.2: This is a digitally signed message part --] [-- Type: application/pgp-signature, Size: 198 bytes --] [-- Attachment #2: Type: text/plain, Size: 485 bytes --] ___________________________________________________________________________________ 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] 27+ messages in thread
end of thread, other threads:[~2012-07-10 0:28 UTC | newest] Thread overview: 27+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2003-11-03 19:12 reset \use[sub]path Pawel Jackowski na Onet 2003-11-03 21:05 ` Hans Hagen 2003-11-04 6:41 ` Pawel Jackowski na Onet 2003-11-10 16:37 ` Patrick Gundlach 2003-11-10 17:26 ` Hans Hagen 2003-11-10 19:59 ` Pawel Jackowski na Onet 2003-11-10 23:02 ` Patrick Gundlach 2003-11-11 7:05 ` Pawel Jackowski na Onet 2003-11-15 21:36 ` page backgrounds Thomas A.Schmitz 2003-11-16 20:08 ` Thomas A.Schmitz 2003-11-17 9:59 ` Patrick Gundlach 2003-11-17 13:09 ` Thomas A. Schmitz 2003-11-17 14:03 ` Otared Kavian 2003-11-17 14:41 ` Patrick Gundlach 2003-11-17 14:43 ` Patrick Gundlach 2003-11-17 14:08 ` Patrick Gundlach 2003-11-17 14:20 ` Adam Lindsay 2003-11-16 22:32 ` Patrick Gundlach 2003-11-17 15:11 Thomas A. Schmitz 2007-11-13 10:26 olivier Turlier 2007-11-13 15:52 ` Wolfgang Schuster 2007-11-13 18:12 ` Peter Rolf 2007-11-14 15:46 ` olivier Turlier 2012-07-09 2:47 Page Backgrounds Kip Warner 2012-07-09 7:45 ` Hans Hagen 2012-07-09 8:06 ` Wolfgang Schuster 2012-07-10 0:28 ` Kip Warner
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).