Hi there, I am taking a look at conTeXt as a means of typesetting documents with more advanced page layouts which otherwise would be produced with desktop publishing suites. I am very new to conTeXt, so I know very little about it. The only documentation I have been able to find on the internet is: ConTeXt Garden ConTeXt an excursion ConTeXt : The manual I have been sifting through these for a while, and whilst the documentation is good, I still have questions. I must apologise if I missed the answers in the docs or if the questions are just plain dumb. 1) Is there a way to make ConTeXt stricter? It seem that ConTeXt will not complain if you misspell the names of colours, layers, overlays etc. I would rather it did. 2) Is there a way to overlay many layers/overlays at one place. It seems using background= can only take 1 layer/overlay. Even better if I could offset the layer/overlay from an origin. 3) I have had difficulty pushing the whole layout including the margin to the right about 2cm. I have tried using setuplayout to alter leftedge, leftedgedistance and backspace. Is that not the way to do it? 3a) Similarly I would like to make the textheight longer so that the footer is about 1cm from the bottom of the page. I have had no luck in setting textheight using setuplayout. 4) Is there a module to parse CVS tags, like the RCS package for laTeX? 5) Can I use OpenType and TrueType fonts in ConTeXt? Ideally via fontspec. 6) Is there a book on ConTeXt for beginners aside from what I have already listed above? 7) Can I specify RGB colours in th 0 <= x <= 255 format? So far I have had to write a script to help me convert them. 8) Is anyone proficient with ConTeXt going to the Cork TeX User Group meeting? Thanks. -- Best Regards Edd http://students.dec.bournemouth.ac.uk/ebarrett
Hi Edd,
I am taking a look at conTeXt as a means of typesetting documents with more advanced page layouts which otherwise would be produced with desktop publishing suites.
I am very new to conTeXt, so I know very little about it. The only documentation I have been able to find on the internet is: ConTeXt Garden ConTeXt an excursion ConTeXt : The manual
You can find all manuals from Pragma on their homepage: http://www.pragma-ade.com/show-man-1.htm
I have been sifting through these for a while, and whilst the documentation is good, I still have questions. I must apologise if I missed the answers in the docs or if the questions are just plain dumb.
1) Is there a way to make ConTeXt stricter? It seem that ConTeXt will not complain if you misspell the names of colours, layers, overlays etc. I would rather it did.
2) Is there a way to overlay many layers/overlays at one place. It seems using background= can only take 1 layer/overlay. Even better if I could offset the layer/overlay from an origin.
1. You could set multiple overlays with a comma seperated list and braces before and after the list. [...,background={overlay 1,overlay 2,...,overlay n},...] 2. You could use the x and y or offset, hoffset and voffset parameters for \setlayer to set the distance from your layer from all four corners of the page, textblock or any other pageblock.
3) I have had difficulty pushing the whole layout including the margin to the right about 2cm. I have tried using setuplayout to alter leftedge, leftedgedistance and backspace. Is that not the way to do it?
The distance between the left margin of the paper and the left margin of the textblock is set with the backspace key for \setuplayout. \setuplayout[backspace=...]
3a) Similarly I would like to make the textheight longer so that the footer is about 1cm from the bottom of the page. I have had no luck in setting textheight using setuplayout.
You could set a fixed value for the footer and let TeX calculate the textheight. \setuplayout [bottomspace=1cm, height=fit]
4) Is there a module to parse CVS tags, like the RCS package for laTeX?
5) Can I use OpenType and TrueType fonts in ConTeXt? Ideally via fontspec.
It is possible to use TrueType and OpenType fonts with pdfTeX but this requires tfm files and a map file. The easier method is to use XeTeX or LuaTeX as engines and the only thing you need is a typescript file with the font names and their mapping to ConTeXt's own font names. http://wiki.contextgarden.net/Fonts_in_XeTeX (a little bit outdated) http://wiki.contextgarden.net/Mark_IV#Fonts_and_typescripts (shoudl also work with XeTeX)
6) Is there a book on ConTeXt for beginners aside from what I have already listed above?
7) Can I specify RGB colours in th 0 <= x <= 255 format? So far I have had to write a script to help me convert them.
This is not possible but you could use the hex notation \setupcolor[hex] \setupcolors[state=start] \definecolor[hexred] [#FF0000] \definecolor[hexgreen][h=00FF00] \starttext \color[hexred]{Red Text} \color[hexgreen]{Green Text} \stoptext
8) Is anyone proficient with ConTeXt going to the Cork TeX User Group meeting?
Thanks.
Wolfgang
Hi, Thanks for the input, that should be enough to keep me going. I am going to push some of this info back to conTeXt garden if that is okay. Will see you in Ireland Hans (if all goes to plan). -- Best Regards Edd http://students.dec.bournemouth.ac.uk/ebarrett
Edd Barrett wrote:
8) Is anyone proficient with ConTeXt going to the Cork TeX User Group meeting?
taco an i will be there 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 -----------------------------------------------------------------
On Wed, Apr 2, 2008 at 4:46 PM, Edd Barrett wrote: Hello,
1) Is there a way to make ConTeXt stricter? It seem that ConTeXt will not complain if you misspell the names of colours, layers, overlays etc. I would rather it did.
Currently not :(
3a) Similarly I would like to make the textheight longer so that the footer is about 1cm from the bottom of the page. I have had no luck in setting textheight using setuplayout.
Use height=... for that.
4) Is there a module to parse CVS tags, like the RCS package for laTeX?
There have been some attempts, but I don't remember the outcome.
5) Can I use OpenType and TrueType fonts in ConTeXt? Ideally via fontspec.
Fontspec is written for (Xe)LaTeX only (admittedly, it has some more advanced features in comparison to ConTeXt mechanisms), but both XeTeX and LuaTeX should nevertheless work OK with ConTeXt with no special package or module. Blame me for not updating the "Fonts in XeTeX" page on Wiki.
8) Is anyone proficient with ConTeXt going to the Cork TeX User Group meeting?
There is also a ConTeXt meeting in August (Easyjet flies from Stansted almost directly to the conference site), so if you want some more fun next to the lake in the middle of Alps, in a small country that you have probably never visited before, you're more than welcome to come. Mojca
On Thu, 3 Apr 2008, Mojca Miklavec wrote:
4) Is there a module to parse CVS tags, like the RCS package for laTeX?
There have been some attempts, but I don't remember the outcome.
Parsing tags is simple, for example, http://archive.contextgarden.net/message/20070920.231549.347dc370.en.html and http://archive.contextgarden.net/message/20080123.123404.d1e0dbab.en.html If you can specify exactly what you want, I can create a module for this. Aditya
On Thu, Apr 3, 2008 at 12:59 PM, Aditya Mahajan
Parsing tags is simple, for example, http://archive.contextgarden.net/message/20070920.231549.347dc370.en.html and http://archive.contextgarden.net/message/20080123.123404.d1e0dbab.en.html
If you can specify exactly what you want, I can create a module for this.
Just a way of isolating each of the marco's values that cvs defines. How about: ---8<--- \definecvskeyword[cvsdate][D/M/Y]{$Date$}% will be expanded upon commit to something like $Date: 1999/12/23 01:59:22 $ \starttext Last Updated: \cvskeyword[cvsdate] \stoptext ---8<--- would produce: Last Updated: 1999/12/23 01:59:22 List of standard keywords here, but bear in mind that users can ake their own per repository: http://badgertronics.com/writings/cvs/keywords.html Thoughts? -- Best Regards Edd http://students.dec.bournemouth.ac.uk/ebarrett
On Thu, Apr 03 2008, Edd Barrett wrote:
Just a way of isolating each of the marco's values that cvs defines. How about:
---8<--- \definecvskeyword[cvsdate][D/M/Y]{$Date$}% will be expanded upon commit to something like $Date: 1999/12/23 01:59:22 $ \starttext Last Updated: \cvskeyword[cvsdate] \stoptext ---8<---
would produce: Last Updated: 1999/12/23 01:59:22
Hello Edd, Perhaps like this: % engine=luatex \startluacode thirddata = thirddata or { } -- write the replacement string -- p: pattern -- r: replacement pattern -- s: subject function thirddata.replace(p, r, s) s = string.gsub(s, "^.-" .. p .. ".-$", r) tex.print(s) end \stopluacode \def\definereplacement{\doquadrupleargument\dodefinereplacement} \def\dodefinereplacement[#1][#2][#3][#4]{\expandafter \def\csname #1\endcsname{\ctxlua{thirddata.replace("#2", "#3", "#4")}}} \definereplacement[cvsdate] [(\%d+)/(\%d+)/(\%d+)] [\%3.\%2.\%1] [$Date: 1999/12/23 01:59:22 $] \definereplacement[cvstime] [(\%d+):(\%d+):(\%d+)] [\%1h \%2m \%3s] [$Date: 1999/12/23 01:59:22 $] \definereplacement[cvsfile] [: (.+),] [\\type{\%1}] [$RCSfile: keyword.html,v $] \starttext File: \cvsfile, last Updated: \cvsdate\ at \cvstime \stoptext Cheers, Peter -- http://pmrb.free.fr/contact/
participants (6)
-
Aditya Mahajan
-
Edd Barrett
-
Hans Hagen
-
Mojca Miklavec
-
Peter Münster
-
Wolfgang Schuster