Re: [NTG-context] Support of PDF Optional Content Groups (Layers)
> Am 19.11.2014 um 21:19 schrieb Christoph Reller : > > On 11/17/2014 13:43 PM, Hans Hagen wrote: > > On 11/17/2014 11:51 AM, Christoph Reller wrote: > > > Is there any way to construct "Set-OCG-State Actions" with ConTeXt? (See > > > Section 8.5 Actions in the PDF Reference.) I admit that this is an > > > advanced feature of PDF and that most viewers apart from the Adobe > > > Reader are not capable of handling OCGs correctly. > > > > I'm not sure what you mean but with the \goto command you can do a lot, > > including sequences of actions that enable/disable layers and so (often > > these things are done via javascript actions). > > Thank you Hans for the pointer to \goto. Unfortunately, javascript is not > suitable for my purpose because the PDF will be converted to PDF/A2. I want > to switch on and off OCGs but with Set-OCG-State actions. Even if this is > beyond the capabilities of ConTeXt, it is nice to know that there is a > javascript-based solution. Can you show a example for this. At the moment you can disable layers when the document is printed. 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 ___
Re: [NTG-context] Adjusting topspace for letterhead in layer construct
> Am 19.11.2014 um 18:41 schrieb jdh : > > > > mtx-context | current version: 2014.10.18 14:30 > > I only want about 3 to 5 mm between the physical top of the page and the top > of the letterhead (in this example, a company's and contact information). > > In \setlayer I set y=3mm > > > The pdf view of the output looks good, but an actual printout (and a look at > a print preview with a pdf viewer) of the generated pdf file puts the top of > the letterhead about 17 mm down from the top edge. This is too much. I > tried adjusting topspace and topdistance to 0 didn't seem to have any affect. Check your printer settings, most printers downscale the document when the distance between the text and the margins are too small. 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 ___
Re: [NTG-context] Natural tables introduces spaces in \type
On 11/5/2014 21:50 PM, Christoph Reller wrote: > On 11/5/2014 10:28 AM, Hans Hagen wrote: > > On 11/5/2014 8:09 AM, Christoph Reller wrote: > > > Thank you very much Hans! > > > > > > Maybe you could tell me why the following still produces a space in > > > front of the full stop: > > > > > > \definetype[ctype][compact=absolute] > > > \starttext > > > \bTABLE > > >\bTR \bTD \ctype{\test.txt} \eTD \eTR > > > \eTABLE > > > \stoptext > > > > because the absolute cleaner only deals with \foo { and \foo [ > > > > > If this issue is resolved I will be glad to wikify. > > > > i'll add the . to the filter criteria > > Thank you for the explanation. I am not sure if it is a wise idea to add > only "." (the full stop). I tried the following characters, and they all > are preceded by a space: > > . - _ # % , ; @ ! > > Basically, what I want is to write a file system path name such as > C:\Path_to-my\file.ext. The above characters are all valid file system > characters. Is there a better solution? Or are you willing to add all the > above (maybe except for # and %) to the absolute cleaner? For anybody interested in this: I have decided to resort to \hyphenatedurl{...}. This means that I have to escape \ as \\, # as \# and % as \letterpercent. Let me know if you have a better solution. Christoph ___ 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] Support of PDF Optional Content Groups (Layers)
On 11/17/2014 13:43 PM, Hans Hagen wrote: > On 11/17/2014 11:51 AM, Christoph Reller wrote: > > Is there any way to construct "Set-OCG-State Actions" with ConTeXt? (See > > Section 8.5 Actions in the PDF Reference.) I admit that this is an > > advanced feature of PDF and that most viewers apart from the Adobe > > Reader are not capable of handling OCGs correctly. > > I'm not sure what you mean but with the \goto command you can do a lot, > including sequences of actions that enable/disable layers and so (often > these things are done via javascript actions). Thank you Hans for the pointer to \goto. Unfortunately, javascript is not suitable for my purpose because the PDF will be converted to PDF/A2. I want to switch on and off OCGs but with Set-OCG-State actions. Even if this is beyond the capabilities of ConTeXt, it is nice to know that there is a javascript-based solution. Christoph ___ 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] layer letterhead and top down distance
I am using: mtx-context | current version: 2014.10.18 14:30 I am typesetting a simple letterhead for correspondence. The design calls for only about a 3 to 5 mm distance between the physical top of the page and the top of the typeset letterhead. The pdf view of the output looks good, but an actual printout (and a look at a "print preview" with a pdf viewer) of the generated pdf file puts the top of the letterhead about 17 mm (14mm over target size) down from the top edge. This is too much. I tried adjusting topspace and topdistance to 0 didn't seem to have any affect. In \setlayer I set y=3mm I tried adjusting topspace but it didn't do what I wanted and topdistance was already 0. I am using theh ConText standalone: mtx-context version: 2014.10.18 14:30 Here is a simple minimal file. % % Start of minimal example \setuppapersize[letter][letter] \setuppagenumbering[location=footer] \setuplayout[ backspace=31mm, header=5mm, rightmargin=2cm, leftmargin=2cm ] \definelayer [Logo] % name of the layer we are defining [ repeat=yes, x=5mm,y=3mm, % Just what is this? hoffset=0mm,voffset=0mm, % and what is this? ...offset from where? width=\paperwidth ] \setupTABLE[r][1,2,3][height=5mm,frame=off] % Put letterhead information in here. \starttext \setlayer[Logo][] { \bTABLE \bTR \bTD \eTD \bTD \sc{Company Name}\eTD \bTD \sc{info}@\sc{something}.\sc{where} \eTD \eTR \bTR \bTD \eTD \bTD 2059 Forest Ave, Ste X \eTD \bTD \sc{www}.\sc{domain}.\sc{topleveldomain} \eTD \eTR \bTR \bTD \eTD \bTD City, Province \eTD \bTD Tel (xxx) 999-1234 \eTD \eTR \eTABLE } \setupbackgrounds[page][background=Logo] ~% Need `` to avoid a NULL content page so can generate a pdf \stoptext % % End of minimal example Regards ___ 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] Adjusting topspace for letterhead in layer construct
mtx-context | current version: 2014.10.18 14:30 I only want about 3 to 5 mm between the physical top of the page and the top of the letterhead (in this example, a company's and contact information). In \setlayer I set y=3mm The pdf view of the output looks good, but an actual printout (and a look at a print preview with a pdf viewer) of the generated pdf file puts the top of the letterhead about 17 mm down from the top edge. This is too much. I tried adjusting topspace and topdistance to 0 didn't seem to have any affect. I am using theh ConText standalone: mtx-context version: 2014.10.18 14:30 Here is a simple minimal exmple: % % Start of minimal example \setuppapersize[letter][letter] \setuppagenumbering[location=footer] \setuplayout[ backspace=31mm, header=5mm, rightmargin=2cm, leftmargin=2cm ] \definelayer [Logo] % name of the layer we are defining [ repeat=yes, x=5mm,y=3mm, % Just what is this? hoffset=0mm,voffset=0mm, % and what is this? ...offset from where? width=\paperwidth ] \setupTABLE[r][1,2,3][height=5mm,frame=off] % Put letterhead information in here. \starttext \setlayer[Logo][] { \bTABLE \bTR \bTD \eTD \bTD \sc{Company Name}\eTD \bTD \sc{info}@\sc{something}.\sc{where} \eTD \eTR \bTR \bTD \eTD \bTD 2059 Forest Ave, Ste X \eTD \bTD \sc{www}.\sc{domain}.\sc{topleveldomain} \eTD \eTR \bTR \bTD \eTD \bTD City, Province \eTD \bTD Tel (xxx) 999-1234 \eTD \eTR \eTABLE } \setupbackgrounds[page][background=Logo] ~% Need `` to avoid a NULL content page so can generate a pdf \stoptext % % End of minimal example ___ 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] \preventmode does not work
(This is a bump, with an improved example, of my earlier note on the subject.) In MKIV, \preventmode does not work. It appears to do the opposite of what is intended, and enable the specified mode. It also does not prevent the explicit enablement of a mode (as can be seen by uncommenting the commented line in the MWE). I have not tested it with MKII , where it might work. (Will ConTeXt online ever be restored?) This goes back to TL14 and likely earlier. Do I misunderstand what \preventmode should do, or have I misused it? And why are there {curlies} instead of [squares] around the mode name in \doifmode and friends? MWE, run context MWE.tex: \starttext \preventmode[X] %\enablemode[X] \doifmode{X}{!} \stoptext -- Rik Kabel ___ 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 ___