Re: [NTG-context] listings.sty
On Thu, 10 Jul 2008 02:27:45 +0200, Mohamed Bana <[EMAIL PROTECTED]> wrote: > Peter Münster free.fr> writes: > >> >> Hello, >> I suggested to the author of the very feature rich LaTeX-Listings >> package, >> Carsten Heinz, to port this package to ConTeXt, and it seems, that he is >> interested. But before doing it, there are some questions: >> >> * What do Hans and other people thing about that? >> * listings.sty uses keyval.sty, how is the proper ConTeXt-way to do the >> same things as keyval, or should listings stay with keyval? I don't see the point. The native ConTeXt verbatim support seems to cover all what listings can do. The wiki page gives some examples: http://wiki.contextgarden.net/Verbatim_text Regards, BG ___ 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 ___
Re: [NTG-context] markup format ---> ConTeXt
On Tue, 03 Jun 2008 08:48:39 +0200, Maurice Diamantini <[EMAIL PROTECTED]> wrote: > - dbcontext seams not to be maintained very much dbcontext is still alive, but asleep because of few users, and mostly works in the current state. You can give it a try. You can provide your own context layout to customize section titles and layout. It is much cleaner and easier than the latex .sty hack. As an example of the powerful layout capabilities that ConTeXt provides, you can build a PDF with a layout similar to what docbook FO does. Regards, BG ___ 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 ___
Re: [NTG-context] Write once layout everwhere (?)
Hello, On Sun, 10 Jun 2007 17:31:45 -0500, Pepe Barbe <[EMAIL PROTECTED]> wrote: > I have used ConTeXt in the past and I have been very pleased with it > and the results obtained, much more than LaTeX. > > Now I am looking into a solution that would allow me to layout the > content ConTeXt and in other formats that ConTeXt does not (Forgive my > ignorance, if I am wrong) output, like HTML, Plain Text, or RTF (Those > are the formats that I can think of that are interesting to me > currently). > > Reading the Wiki one of those solutions would be XML, but I know very > little about the subject, so this email is to ask about experiences in > similar endeavors, other solutions for the same problem and how > practical this is. > > I suppose that I would use this for general writing and for academic > as well (Maths and engineering). XML is a good format if you need several output formats without losing information (XHTML, HTML, PDF, manpages, plain text). But I recommend some well established grammar (DITA, DocBook) to be able to use their official transformation tools, and to be able to use some XML WYSIWYG editor that supports them natively (like XXE). Strangely enough the PDF output is weakest point since most of the tools use FO and the related compilers (well known FOP, maybe xmlroff, maybe fotex) which can give very ugly output. The only good compiler I know is XEP, but it is not free (there's a full featured personnal edition that sticks its logo on every page). For docbook, you can try marginal tools to convert the XML to *tex formats (DocbookInContext, db2latex, dblatex). You can also directly use the native XML handling of context (method used by DocbookInContext) but IMHO it needs some context knowledge. Personnaly I use docbook, mostly because I have to produce PDF, HTML, and troff (manpages) outputs. It is even possible to convert some already existing manpages to docbook with doclifter. Regards, BG ___ 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 ___
Re: [NTG-context] Write once layout everwhere (?)
On Mon, 11 Jun 2007 11:42:23 -0400, Aditya Mahajan <[EMAIL PROTECTED]> wrote: Thanks. I had not looked at them and some of the things about handling at the ConTeXt end are more clear now. But I think that I did not explain my question correctly. What I do not understand how are abbreviations etc. handled by xslt for conversion into html. For example, how do I write an xsl style sheet that converts this xml input I study which stands for into html as I study EECS which stands for Electrical Engineering and Computer Science I know that this is not the right list to ask this sort of questions, but I am hoping that there are xml users here and they will be able to point me to the right direction. I haven't followed the thread, but attached an idea of doing what you want with XSLT. Note that your example is not valid at all (commas between attributes, missing ending '/' for empty elements). BTW, it's not a good idea to use the same attribute ("value") as an reference identifier, and for referencing to another element. Regards, myxsl.xsl Description: Binary data I study which stands for ___ 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 ___
Re: [NTG-context] [OT] dblatex
On Tue, 29 May 2007 22:31:08 +0200, luigi scarso <[EMAIL PROTECTED]> wrote: > On 5/29/07, nico <[EMAIL PROTECTED]> wrote: >> On Tue, 29 May 2007 09:11:57 +0200, luigi scarso >> <[EMAIL PROTECTED]> >> wrote: >> >> > http://dblatex.sourceforge.net/ >> > DocBook to LaTeX/ConTeXt Publishing Does anyone know something about >> it ? >> >> Do you have precise questions? > dbcontext-0.2pre.tar.bz2 : 11 Sep 06 > dblatex-0.2.5.tar.bz2:27 Apr 07 > It seems that dccontext is stopped. Not really stopped, rather dormant. The main reasons are: - Context moves so much, and my system is so screwed up, that I cannot update to a recent context release. - There are very few users interested by dbcontext and then few bug reports or update demands. - There are some big fishes asking for latex solutions (gimp, kde docs). - Few users are ready to switch from latex to context, at least because of install troubles and dependencies. - I can hardly convince people to use context if the context version suggested in the release note is not available from context site (it was before the foundry museum). I still think context overclasses latex, but its systematic refactoring and use of emergent/latest software have their drawbacks, for end users, but for tools depending on it too. But I believe that with the new context versioning scheme, the debian and Peter Munster packaging efforts, it can become more popular. Of course, I need to update my machine too ;-) Regards, BG ___ 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 ___
Re: [NTG-context] [OT] dblatex
On Tue, 29 May 2007 09:11:57 +0200, luigi scarso <[EMAIL PROTECTED]> wrote: > http://dblatex.sourceforge.net/ > DocBook to LaTeX/ConTeXt Publishing Does anyone know something about it ? Indeed, i'm the humble maintainer of this DocBook to ConTeXt attempt. Do you have precise questions? You can reply directly to me, to not bother the list. Regards, BG ___ 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 ___
Re: [NTG-context] new to ConTeXt
On Wed, 08 Nov 2006 20:53:37 +0100, Pablo Rodríguez <[EMAIL PROTECTED]> wrote: > nico wrote: >>> On Tue, 7 Nov 2006, Pablo Rodríguez wrote: >>>> Thanks for your answer, Hans. Sorry for not answering before (these >>>> days >>>> I find myself installing a new computer and moving data into it). >>>> >>>> It seems that the task is more difficult than I thought (although >>>> x-contm.tex seems a very interesting example to begin with). >> >> Since this thread is also talking about some tools, I'll complete the >> list >> with dbcontext (http://dblatex.sf.net) on which I contribute, that >> translates DocBook to ConTeXt via XSL stylesheets. I guess that many >> aspects could be directly handled by context. > > Thanks for your answer. I know that XML can be converted to > TeX/LaTeX/ConTeXt using XSL, but my XML is TEI (http://www.tei-c.org/) > and not DocBook. If I would use XSL transformation, I guess it would be > easier (at least for me) to adapt the already existing TEI-XML->LaTeX > XSL files and adapt them to ConTeXt. I wonder (out of ignorance) whether > this would be a better way than parsing the XML directly with ConTeXt. I have no experience with handling XML directly with context, but I guess it's the most elegant way of processing, since it relies upon only one tool (no XSLT processor, no stylesheet, no glue to pass the output to texexec), there is no intermediate step, and the code should be smaller. But for me the drawback is that you need a good perception about how context/tex works (things about grouping, how macros expand and other funny things) and debugging might be harder. At least XSL gives an output that you can tweak until something compiles and gives the expected output :-) The other thing is that there are some specific processings that I have no idea how it can be implemented with context. This said, I know there are many people who happily process their XML docs directly with context. Maybe they could also give their feedback. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] new to ConTeXt
On Tue, 7 Nov 2006 17:34:54 -0500 (EST), Aditya Mahajan <[EMAIL PROTECTED]> wrote: > On Tue, 7 Nov 2006, Pablo Rodríguez wrote: > >> Thanks for your answer, Hans. Sorry for not answering before (these days >> I find myself installing a new computer and moving data into it). >> >> It seems that the task is more difficult than I thought (although >> x-contm.tex seems a very interesting example to begin with). > > You can also check the thread > http://archive.contextgarden.net/thread/20050225.103441.cda2d788.en.html#20050225.103441.cda2d788 > for some discussion on getting started with XML and context. Since this thread is also talking about some tools, I'll complete the list with dbcontext (http://dblatex.sf.net) on which I contribute, that translates DocBook to ConTeXt via XSL stylesheets. I guess that many aspects could be directly handled by context. Here are some examples built from DocBook sources: http://dblatex.sourceforge.net/example/svn-book-by-dbcontext.pdf, http://dblatex.sourceforge.net/example/divepython-dbc.pdf.bz2. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] calculations
On Wed, 20 Sep 2006 00:04:33 +0200, Henning Hraban Ramm <[EMAIL PROTECTED]> wrote: > Thank you, but now I always get: > > ! Illegal unit of measure (pt inserted). > > . > \figurewidth ->545. > 03625pt > \dodostartlilypond ...expr (\LPscale \figurewidth >) \ifdim \FigWidth > >\localh... \figurewidth is not a dimension. I guess the following should work: \def\LPscale{.6315789} % downscale the image \ifvmode \getfiguredimensions[\bufferprefix lilypond-\the\lily!figures.pdf][]% \leavevmode% \newdimen\FigWidth \newdimen\FigWidthReal=\figurewidth \FigWidth=\dimexpr(\LPscale\FigWidthReal) \ifdim\FigWidth>\localhsize \!!dimena=\localhsize \advance\!!dimena by-\FigWidth \noindent\hskip\!!dimena \fi \fi \externalfigure[\lily!img][scale=\dimexpr(1000\LPscale)]% Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] calculations
On Tue, 19 Sep 2006 22:53:18 +0200, Henning Hraban Ramm <[EMAIL PROTECTED]> wrote: > I need to downscale every score to 63%, and the shown width check > should use the corrected width. > How can I do that? (FigWidth should be LPscale * figurewidth) I don't know what you really want to do, but an example of computation could look like this: \newdimen\myfigwidth \newdimen\myfigurewidth \def\myscale{.63} \figurewidth=23pt \myfigwidth=\dimexpr(\myscale\myfigurewidth) \starttext \the\myfigwidth \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Captions in Combinations
On Sun, 17 Sep 2006 14:35:36 -0500, Pepe Barbe <[EMAIL PROTECTED]> wrote: > Did you find a solution for my problem? Because I couldn't find your > answer in the email. Look more carefully the mail, I guess that the problem was missing braces: \placefigure [center] {Combination Caption} { \startcombination [2*1] {\framed[height=.45\textwidth,width=.45\textwidth]{My Graphic 1}}{Text: Test. Math: $Test$} {\framed[height=.45\textwidth,width=.45\textwidth]{My Graphic 2}}{Text: Test. Math: $Test$} \stopcombination } Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] listoffloats question
On Fri, 01 Sep 2006 17:14:01 +0200, richard rascher-friesenhausen <[EMAIL PROTECTED]> wrote: > Hello, > > in my scripts i use different kinds of figure, defined as floats cloned > from the original ConTeXt figure: > > \definefloat[afigure][afigures][figure] > \definefloat[bfigure][bfigures][figure] > > In my script environment i use different setups for figure, afigure and > bfigure that are not shown here. > Using cloning, all figures use the same counter, which is nice. Really? In which release the counter is the same? With your case, I have here the figure numbers 1, 1, 1, 2, 2, 2. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] layout question
On Tue, 29 Aug 2006 10:11:37 +0200, richard rascher-friesenhausen <[EMAIL PROTECTED]> wrote: > nico schrieb: >> Defining a new float gives another floating object with its own counter, >> list, etc. >> >> Maybe you can stay with only one kind of float. The following looks like >> the expected rendering, but I don't understand the default placement of >> the second large figure. >> >> % float defs >> %--- >> \setupfloat[figure][minwidth=\rightmarginwidth, >> criterium=\rightmarginwidth, >> location=middle, >> default={outermargin,here}] >> > Thanks for that solution. It solves the problem with the list of > figures. But for the text+margin figures i have to look, if they are > placed on an odd or even page, to set the placing correctly. They should > always be shifted to the outer margin. But your solution avoids the > extra definition of margin images. Yes, I don't understand why it behaves like this. I thought that it would be put in the middle. > Do you know the meanings of the criterium. minwidth and maxwidth options > of \setupfloat and how they interact with each other and with default? It's explained in details.pdf. In brief, for margin floats: criterium=: says that when the figure width is greater than , the figure is put in the text area. When the figure width is less than , it is put in the default specified margin (here: outermargin). default=: default setting for that kind of float, including the chosen placement area (outermargin), until the criterium is reached. maxwidth=: gives the alignment delimiter in the margin, so that the figure will not go outside the specified width in the margin, but it will grow in the text area instead. minwidth=: ensures that the figure can take at least this width, so that if the figure width is smaller (and location=middle) it will be centered in this area. I hope there's no missunderstanding in these explainations (others can tell). Anyway, it cannot be better than the details doc that shows how it looks. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] comment flush?
Hello, There's a strange behaviour with comments when using \startcomment...\stopcomment. In some cases the comments are skipped. The comment always appears with \comment{...}. Here is a summary of the tests I've done: Case OK: comment starting a paragraph Case KO: comment at the end of a single paragraph Case OK: another paragraph follows the comment Case KO: the comment is within a single paragraph Case NOK: the comment appears (not in the last paragraph), but not in the middle of the paragraph, but at the end. Case OK: comment starting a paragraph \setupcolors[state=start] \setupinteraction[state=start] \setupinteractionscreen[options=max] \starttext \startcomment blah blah blah blah blah blah \stopcomment \input tufte \stoptext Case KO: comment at the end of a single paragraph \setupcolors[state=start] \setupinteraction[state=start] \setupinteractionscreen[options=max] \starttext \input tufte \startcomment blah blah blah blah blah blah \stopcomment \stoptext Case OK: another paragraph follows the comment \setupcolors[state=start] \setupinteraction[state=start] \setupinteractionscreen[options=max] \starttext \input tufte \startcomment blah blah blah blah blah blah \stopcomment \input tufte \stoptext Case KO: the comment is within a single paragraph \setupcolors[state=start] \setupinteraction[state=start] \setupinteractionscreen[options=max] \starttext \input tufte \startcomment blah blah blah blah blah blah \stopcomment \input tufte \stoptext Case NOK: the comment appears, but not in the middle of the paragraph, but at the end \setupcolors[state=start] \setupinteraction[state=start] \setupinteractionscreen[options=max] \starttext \input tufte \startcomment blah blah blah blah blah blah \stopcomment \input tufte \input tufte \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] layout question
On Mon, 28 Aug 2006 21:42:10 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >>> 1) Is it possible, to have only one list of figures, numbering all >>> figures with the same counter? My first >>> attempts with \definecombinedlist did not work. >> >> Defining a new float gives another floating object with its own counter, > > \definefloat[myfloat][figure] > > will give you \myfloat which inherits from \figure Hm, the setup is inherited, but it has its own counter, its own label, etc. isn't it? Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] layout question
On Mon, 28 Aug 2006 10:58:58 +0200, richard rascher-friesenhausen <[EMAIL PROTECTED]> wrote: > Hans Hagen schrieb: >> >> did you read details.pdf ? Lots of margin stuff with figures in there >> >> Hans >> >> > Hello, > > this weekend i looked a bit into details.pdf an came up with a solution > of my figure placing problem: [...] > > Now, the figures are at my desired places. But i have three different > kinds of figures and three different lists of figures. > > 1) Is it possible, to have only one list of figures, numbering all > figures with the same counter? My first > attempts with \definecombinedlist did not work. Defining a new float gives another floating object with its own counter, list, etc. Maybe you can stay with only one kind of float. The following looks like the expected rendering, but I don't understand the default placement of the second large figure. \setuppapersize[A4][A4] \setuplayout[width=middle, cutspace=2.3in, margindistance=.25in, leftmargin=0.5in,rightmargin=2.3in] \setuplayout[backspace=\dimexpr(\leftmarginwidth+\leftmargindistance)] \setuppagenumbering[alternative=doublesided] % float defs %--- \setupfloat[figure][minwidth=\rightmarginwidth, criterium=\rightmarginwidth, location=middle, default={outermargin,here}] \showframe %=== \starttext %=== \placelistoffigures \hairline The very first page with a small image in the (bigger) margin. \placefigure {a margin image} {\framed[width=\marginwidth,height=3cm]{image}} \inmargin{Tufte text} \input tufte And now a larger image in the text and margin \placefigure[inner]{a text+margin image} {\framed[width=1.2\textwidth,height=3cm]{image}} \dorecurse{14}{Some text. } \placefigure[middle]{a text image} {\framed[width=.3\textwidth,height=1cm]{text image}} \dorecurse{14}{Some text.~} %--- \page %--- The second page with a small image in the (bigger) margin. \placefigure {a margin image} {\framed[width=\marginwidth,height=3cm]{image}} \input tufte And now a larger image in the text and margin % % Default placement sounds strange to me... % Force with middle to have the entire figure visible % %\placefigure{a text+margin image} \placefigure[middle]{a text+margin image} {\framed[width=1.2\textwidth,height=3cm]{image}} \inmargin{Tufte text} \input tufte \placefigure[middle]{a text image} {\framed[width=.3\textwidth,height=1cm]{text image}} \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Layout and textwidth/textmargin
On Sun, 27 Aug 2006 21:10:12 +0200, <[EMAIL PROTECTED]> wrote: >> What is wrong in there? >> >> \definelayout[odd] >>[width=middle, >> backspace=7cm, >> cutspace=5cm] >> >> \definelayout[even] >>[backspace=8cm, >> cutspace=2cm, >> width=middle] >> >> \setuplayout > > Hallo! > > This doesn't work here, too! Yes, Hans sent me off-list a patch that works fine with the beta 2006.08.22 release. The given example is: \setuppagenumbering[alternative=doublesided] \setuplayout [width=11cm] \definelayout [odd] [backspace=1cm] \definelayout [even] [backspace=4cm] \definelayout [5][backspace=5cm] \definelayout [6][backspace=5cm] \definelayout [-2] [backspace=0cm,cutspace=0cm] \definelayout [last] [backspace=0cm,cutspace=0cm] \checkcurrentlayout \showframe \starttext \dorecurse{20} {\input knuth \endgraf \input tufte \endgraf} \stoptext Thanks again to Hans that I guess will include it in a next release. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Layout and textwidth/textmargin
On Sat, 26 Aug 2006 22:29:23 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > Willi Egger wrote: >> Hi, >> >> To me it should not be necessary to define odd and even layouts for your >> purposes. (Of course I stand corrected!) >> > in the case that one has a strangely assymetric layout (no mirroring) > one can do > > \setuplayout[odd] [] > \setuplayout[even][] But it doesn't work. In the following case it is simply ignored (default setting used). I've this behaviour with live context too. What's wrong? \setuplayout[odd] [width=middle, backspace=7cm, cutspace=5cm] \setuplayout[even] [backspace=8cm, cutspace=4cm, width=middle] \starttext \dorecurse{4}{ \section{Hello} \input knuth \endgraf \subsection{Sub Hello} \input tufte \endgraf} \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Layout and textwidth/textmargin
On Thu, 24 Aug 2006 20:37:46 +0200, nico <[EMAIL PROTECTED]> wrote: > Hello, > > I wonder if it is possible to setup a layout with these requirements: > > - it can be doublesided, that is, when doublesided the left margin (LM) > and right margin (RM) are different and mirrored on right/left pages. > > - the headings (section, etc.) start just after the left margin. > > - the text body has an extra left text margin (TM) that is not mirrored. > > Here is an example of the expected output in doublesided mode: > > Left Page: > LM TM RM > |<--7--><-- 8--> <-5->| > | 1. This is a Title | > | | > | This is the text body | > | that has a bigger left | > | margin.| > > Right Page: > > RMTMLM > |<-5-><-- 8--> <--7-->| > | The test continues on| > | This page. | > | | > | 2. Another Title | > | | Well, I start from the beginning with odd/even layout setting, and the following does not work. The behaviour I see is that only the odd setting is used. What is wrong in there? \definelayout[odd] [width=middle, backspace=7cm, cutspace=5cm] \definelayout[even] [backspace=8cm, cutspace=2cm, width=middle] \setuplayout %\showlayout \starttext \dorecurse{4}{ \section{Hello} \input knuth \endgraf \subsection{Sub Hello} \input tufte \endgraf} \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Layout and textwidth/textmargin
Hello, I wonder if it is possible to setup a layout with these requirements: - it can be doublesided, that is, when doublesided the left margin (LM) and right margin (RM) are different and mirrored on right/left pages. - the headings (section, etc.) start just after the left margin. - the text body has an extra left text margin (TM) that is not mirrored. Here is an example of the expected output in doublesided mode: Left Page: LM TM RM |<--7--><-- 8--> <-5->| | 1. This is a Title | | | | This is the text body | | that has a bigger left | | margin.| Right Page: RMTMLM |<-5-><-- 8--> <--7-->| | The test continues on| | This page. | | | | 2. Another Title | | | For singlesided documents I can play with a setup like this (the margindistances should be taken into account too): \setuphead[section][margin=-TM] \setuplayout[leftmargin=TM+LM, rightmargin=RM, backspace=TM+LM, width=\paperwidth-(RM+TM+LM)] For doublesided documents I thought about using textwidth or textmargin, but in this case the text margin is applied on left and right (the text is in the middle). Should I play with other setup parameters? What is the best way to achieve this? Thanks for any hint, Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] How to \processcommalist inside another commalist?
On Mon, 21 Aug 2006 23:08:59 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: >>> but after some thinking I realized that it would indeed be a better >>> idea (less to type?) to have >>> \useGNUPLOTgraphic[name][1,3] >>> and >>> \useGNUPLOTgraphic[name][1,3][width=.9\textwidth] >>> instead. >>> >>> At the beginning the main reason against it was that I didn't know how >>> to distinguish which kind of parameters are being used in the second >>> pair of brackets, but I guess that I can safely use \ifnumberelse as a >>> test on the first item to distinguish between the two. >>> >> >> Maybe you could play only with the parameter count. The limitation is >> that >> an empty second argument is required when only options need to be >> passed. >> > why? in that case #3 is empty and #2 contains the options Hm, I thought that the initial goal was to know if the parameter passed is a number list, or an option list. In the suggested code, the assumption is that the number list (if any) is always the second parameter. If not, how to handle those cases? \useGNUPLOTgraphic[name][2,3,5] \useGNUPLOTgraphic[name][width=2in] But I guess there are clever internal macros that could help :-) Regards, BG >> \def\printPrime#1{#1 is prime.\crlf} >> >> \def\useGNUPLOTgraphic >>{\dotripleempty\douseGNUPLOTgraphic} >> >> \def\douseGNUPLOTgraphic[#1][#2][#3]% >>{\ifthirdargument >> \doprime{#2} >> parameters are #3 >> \getparameters[gnuplot][#3] >> \else\ifsecondargument >> \doprime{#2} >> \fi\fi} >> >> \def\doprime#1{\processcommalist[#1]\printPrime} >> >> \starttext >> \useGNUPLOTgraphic[name] >> \useGNUPLOTgraphic[name][2,3,5] >> \useGNUPLOTgraphic[name][3,5,7][width=2in] >> \useGNUPLOTgraphic[name][][width=4in] >> \stoptext ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] How to \processcommalist inside another commalist?
On Mon, 21 Aug 2006 20:35:27 +0200, Mojca Miklavec <[EMAIL PROTECTED]> wrote: >> %% Why using parameter for this? > > I was sure that someone would ask that. I want to provide optional > parameters for both numbers and scaling: > \useGNUPLOTgraphic[name] > or > \useGNUPLOTgraphic[name][width=.9\textwidth] > or > \useGNUPLOTgraphic[name][n={1,3}] > or > \useGNUPLOTgraphic[name][n={1,3},width=.9\textwidth] > > but after some thinking I realized that it would indeed be a better > idea (less to type?) to have > \useGNUPLOTgraphic[name][1,3] > and > \useGNUPLOTgraphic[name][1,3][width=.9\textwidth] > instead. > > At the beginning the main reason against it was that I didn't know how > to distinguish which kind of parameters are being used in the second > pair of brackets, but I guess that I can safely use \ifnumberelse as a > test on the first item to distinguish between the two. Maybe you could play only with the parameter count. The limitation is that an empty second argument is required when only options need to be passed. \def\printPrime#1{#1 is prime.\crlf} \def\useGNUPLOTgraphic {\dotripleempty\douseGNUPLOTgraphic} \def\douseGNUPLOTgraphic[#1][#2][#3]% {\ifthirdargument \doprime{#2} parameters are #3 \getparameters[gnuplot][#3] \else\ifsecondargument \doprime{#2} \fi\fi} \def\doprime#1{\processcommalist[#1]\printPrime} \starttext \useGNUPLOTgraphic[name] \useGNUPLOTgraphic[name][2,3,5] \useGNUPLOTgraphic[name][3,5,7][width=2in] \useGNUPLOTgraphic[name][][width=4in] \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] How to \processcommalist inside another commalist?
On Mon, 21 Aug 2006 17:23:48 +0200, Mojca Miklavec <[EMAIL PROTECTED]> wrote: > Hello, > > I tried to print out primes (well, I tried to do something else, but I > needed a more illustrative example), but it seems that my approach was > too naive: > > \def\arePrime[#1]{% > \bgroup > \getparameters[Prime][p=,#1] > \def\printPrime##1{##1 is prime.\crlf} > \processcommalist[\Primep]\printPrime > \egroup} > > \starttext > \arePrime[p={2,3,5}] > \stoptext My 2 cents contribution: \def\printPrime#1{#1 is prime.\crlf} %% Why using parameter for this? \def\arePrime[#1]{% \bgroup \processcommalist[#1]\printPrime \egroup} %% Expand the parameter before processing \def\arePrimeN[#1]{% \bgroup \getparameters[Prime][p=,#1] \expandafter\processcommalist\expandafter[\Primep]\printPrime \egroup} \starttext \arePrime[2,3,5] \arePrimeN[p={2,3,5}] \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] slightly OT: presentation tool
On Wed, 12 Jul 2006 14:52:24 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > Johan Sandblom wrote: >> Looks amazing. Looking at the license it appears in fact to be free as >> > i suppose that it more or less has to be free anyway because gs and > python are used Don't know for gs, but you there's no need to be free when using python (http://www.python.org/psf/license). Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Page breaking problem
On Tue, 20 Jun 2006 10:55:43 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> >> Hi Hans, since textbackground seems now the default background feature >> to >> use, do you plan to fix the textbackground overlapping trouble i >> submitted >> some time ago? >> > remind me what it was ... In the case of mail [1] textbackground overlapped bottom footnote texts or top floats if the backgrounded stuff covered two pages. You suggested to use \chardef\kindofpagetextareas\plusone to prevent from this behaviour. Using this setting fixed it, but introduced some kind of vertical stretchiness failure so that page text can overlap a bottom footnote text as shown in the case of mail [2]. So, both textbackground/page modes have their limitation that makes textbackground use not satisfying. So, it would be great if it could be fixed. I haven't installed the latest context release yet, but there's the same behaviour with context live. Thanks, BG [1]: http://archive.contextgarden.net/message/20060523.101005.80b07059.en.html The test case: \definecolor[ScreenGray][s=.95] \definetextbackground[grayback] [background=color, backgroundcolor=ScreenGray, frame=on, strut=yes, width=broad, location=paragraph, framecolor=ScreenGray, leftoffset=\topskipgap, before=\blank, after=\blank, align=right] \starttext A footnote\footnote{Covered by the background, right?}. \input tufte \input tufte \input tufte \input tufte \starttextbackground[grayback] \input tufte \stoptextbackground \stoptext [2]: http://archive.contextgarden.net/message/20060524.162941.8a054666.en.html The test case: \chardef\kindofpagetextareas\plusone \setupcolors[state=start] \setupwhitespace[medium] % needed to activate the buggy stuff... \definetextbackground[listing][background=color] \starttext \input tufte\footnote{A footnote} blah blah blah blah blah \section{Section} \input tufte blah blah \startitemize \item a \item a \item a \item a \item a \item a \stopitemize \stoptext ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Page breaking problem
On Mon, 19 Jun 2006 12:20:05 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > Helin Gai wrote: >> Hi, I'm new to ConTeXt and I'm preparing a document for my own >> reference. The source code is below. I came across a few weird >> issues: 1) I don't quite understand why the page break occurs on > because of \startbackground, best use textbackgrounds Hi Hans, since textbackground seems now the default background feature to use, do you plan to fix the textbackground overlapping trouble i submitted some time ago? Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Page breaking problem
On Mon, 19 Jun 2006 18:45:32 +0800, Helin Gai <[EMAIL PROTECTED]> wrote: > Thanks Hans for the prompt reply. > > I tried the following code: > > \definetextbackground[A] > [frame=off,location=paragraph,backgroundcolor=gray] > \setuptyping[before={\starttextbackground[A]},after= > {\stoptextbackground}] > > But this resulted in tons of errors. Could you give some instruction > as to how to proceed? I don't know if it's the mailer that wrapped the text, but you should stuck option=value, like this: \setuptyping[before={\starttextbackground[A]}, after={\stoptextbackground}] With a "old" release (2006.05.23), it works fine. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] How to hyperlink pdf?
On Sun, 18 Jun 2006 09:27:48 -0700, Johannes Graumann <[EMAIL PROTECTED]> wrote: > Aditya Mahajan wrote: > >> \setupinteraction[state=start] > > Thanks. This will hyperlink the section numbers (like 2.2) from the TOC > to > the actual section ... is there any way to extend the link to the page > numbers in the TOC as well? That's where I intuitively looked first ... To have only pagenumbers in TOC, try: \setupcombinedlist [content] [interaction=pagenumber] Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Fonts problem
On Wed, 31 May 2006 15:21:15 +0200, Jean Magnan de Bornier <[EMAIL PROTECTED]> wrote: > Le 31 mai à 14:30:33 Jean Magnan de Bornier <[EMAIL PROTECTED]> écrit > notamment: > > | but with the pdf option I get something unexpected: > > And here's what texexec says about that: > .. > Warning: pdfetex (file > /usr/local/teTeX/share/texmf-local/fonts/map/dvipdfm/con > text/original-base.map): invalid entry for `fmvr8x': font file missing I had the same trouble. As Hans said: your texmf.cnf file should contain: TEXFONTMAPS = .;$TEXMF/fonts/map/{$progname,pdftex,dvips,}//;$TEXMF/{$progname,pdftex,dvips}/{config,}// Maybe something should be written on wiki about these dvipdfm font troubles that cover many threads now. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Paragraph line breaking
Hello, I'm trying to tweak some parameters to avoid lines going into the margin when it contains long words. Using \setuptolerance[tolerant (or verytolerant)] helps much but sometimes it isn't enough. My questions are: - Using \filename doesn't hyphenate on backslash characters (which is interesting for Windows paths). Is is intended? - Is there a macro or something like this that I could put before the maybe too long word so that it breaks the line if the word doesn't fit in the line? - Is there a mechanism to define an arbitrary hyphenation pattern? - What are the other parameters I could try to avoid an overlong line? Looking at the style.pdf file, i don't realy know what is pertinent for my purpose. Thanks for any hint. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] A question for you
On Fri, 26 May 2006 20:01:57 -0600, Idris Samawi Hamid <[EMAIL PROTECTED]> wrote: > Which typesetting tasks do you NOT do in ConTeXt, and what do you prefer > to use for those tasks? I don't use context for any technical documentation that requires several output formats (HTML, PDF, troff for manpages), and i use DocBook instead, well suited for a wide range of transformation. This said, I now uses context as backend typesetting engine to convert the DocBook documents into PDF. I can then control the (high quality) output rendering, what I cannot do with XSL FO based transformation, and I don't need java neither (required to process FO, unless you use foxet, maybe). > What typesetting tasks do you find difficult-to-onerous in ConTeXt (even > in nothing else is available)? Common documents exchanged with colleagues (who have falled into the dark side of MS wor(l)d). BTW, I think that the biggest limitation to have context more used is the installation difficulties: too many dependencies to update by hand (tetex, LM fonts, launching scripts, config files), no standard installation (what about having one day something like a "configure; make install"), no packaging à la RPM, apt-get, or portinstall. Of course, once done, upgrading the context release is not a big deal, but the first step is not obvious. It's the only explanation I've found why latex is so popular; knowing a bit more the context interface and features I now look latex as a stone age tex macro package. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] 'Dot' after Float label Howto?
On Wed, 24 May 2006 13:26:51 -0700, Johannes Graumann <[EMAIL PROTECTED]> wrote: > Hello, > > My proofreader wants the float labels ("Figure 2.5") to end with a dot as > well (as in "Figure 2.5."). > Can somebody please point me at how to achieve that? I thought that stopper would do it, but either I misuse it, or there's a bug in there: the dot appears twice! \setupcaption[figure][stopper=.] \starttext \chapter{joke} \placefigure{What} {\framed[width=5cm]{Hi}} \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] problem with \setupitemize
On Wed, 24 May 2006 17:53:54 +0200 (CEST), Peter Münster <[EMAIL PROTECTED]> wrote: > Hello, > > "\setupitemize[packed][margin=3em]" > does not work, but > "\setupitemize[packed] > \setupitemize[margin=3em]" > works. > Is this normal or a bug?` I guess it's because that with more than one option group, the first is for the kind of item (1, n, etc.), at least as shown in the manual. The following works: \setupitemize[1][packed][margin=3em] Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Textbackground overlapping
On Wed, 24 May 2006 01:50:41 +0200, nico <[EMAIL PROTECTED]> wrote: > On Tue, 23 May 2006 17:15:28 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > >>> >> not yet interfaced but public anyway >> >> \chardef\kindofpagetextareas\plusone >> > But I've seen a side effect of this setting. It appears rarely, and I had > difficulties to reproduce it. So, please find attached the cut-and-pasted > buggy page to have exactly the same placements. Here is a simple test case able to reproduce the problem (same behaviour with context live). Seems related to some vertical stretching stuff in a page. \chardef\kindofpagetextareas\plusone \setupcolors[state=start] \setupwhitespace[medium] % needed to activate the buggy stuff... \definetextbackground[listing][background=color] \starttext \input tufte\footnote{A footnote} blah blah blah blah blah \section{Section} \input tufte blah blah \startitemize \item a \item a \item a \item a \item a \item a \stopitemize \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Textbackground overlapping
On Tue, 23 May 2006 17:15:28 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: not yet interfaced but public anyway \chardef\kindofpagetextareas\plusone Ah, yes, there's no more overlapping for both test cases. But I've seen a side effect of this setting. It appears rarely, and I had difficulties to reproduce it. So, please find attached the cut-and-pasted buggy page to have exactly the same placements. The problem is that with this setting the blank spaces around titles or paragraphs is a bit greater than it was. It's not an issue by itself, but then the text sometimes overlap the bottom footnote. Note that there's no textbackground involved in attached the case. It is defined only to activate the behaviour via the \enabletextarearegistration call. Regards, BG textback3.tex.gz Description: GNU Zip compressed data ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Textbackground overlapping (2)
Hello, Sorry, just another overlapping case I should have put in the preceding mail: when a float cuts the backgrounded stuff, the float is backgrounded too. Maybe harder to fix. An example showing both cases (footnote + float): \definecolor[ScreenGray][s=.95] \definetextbackground[grayback] [background=color, backgroundcolor=ScreenGray, frame=on, strut=yes, width=broad, location=paragraph, framecolor=ScreenGray, leftoffset=\topskipgap, before=\blank, after=\blank, align=right] \starttext A footnote\footnote{Covered by the background, right?}. \input tufte \input tufte \input tufte \input tufte \starttextbackground[grayback] \input tufte \stoptextbackground \placefigure[top]{joke}{\framed[width=5cm]{Hi}} \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Textbackground overlapping
Hello, When the backgrounded stuff starts from one page up to the following, it doesn't take care about the bottom footnotes, so that they are covered by the background. Here is a small example: \definecolor[ScreenGray][s=.95] \definetextbackground[grayback] [background=color, backgroundcolor=ScreenGray, frame=on, strut=yes, width=broad, location=paragraph, framecolor=ScreenGray, leftoffset=\topskipgap, before=\blank, after=\blank, align=right] \starttext A footnote\footnote{Covered by the background, right?}. \input tufte \input tufte \input tufte \input tufte \starttextbackground[grayback] \input tufte \stoptextbackground \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Background placement
On Mon, 22 May 2006 14:32:45 -0400 (EDT), Aditya Mahajan <[EMAIL PROTECTED]> wrote: > On Mon, 22 May 2006, nico wrote: > >> The problem often occurs just after a heading starting at the top of a >> page (section, enumeration title). Here is an example showing the >> behaviour: > > I had a similar problem in the past, and Hans suggested to use > starttextbackground instead of background. background is supposed to be > deprecated. Deprecated? Really? > Try the following code and see if you get what you want. > > setuplayout[middle] > \setupcolors[state=start] > > \definecolor[ScreenGray][s=0.95] > > \definetextbackground[listing] Yes, thanks, it works (this time I haven't the weird behaviour I had some time ago with textbackground... strange). But it's time consuming and looks then as an overkill solution. To build a 400p book (on a slow machine, it's true): - It takes 396s with background, - It takes 539s with textbackground, and I've 260 MP graph files generated! Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Background width (was framedtext)
On Mon, 22 May 2006 15:10:21 +0200, Taco Hoekwater <[EMAIL PROTECTED]> wrote: > andrea valle wrote: >> (Just to say it's a question I was going to post too) >> >> -a- >> >> On 22 May 2006, at 12:54, nico wrote: >> >>> Hello, >>> >>> Is there a way (magical option) to have the framedtext width adapt to >>> the environment width where it is put? > > \defineframedtext[mybox] [width=local] Thanks, It works fine for framedtext! Unfortunately it doesn't help with background. Another option? The same case with background instead of framedtext: \setuplayout[middle] \setupcolors[state=start] \setupbackground [background=screen, frame=on, strut=yes, width=local, before=\blank, after=\blank] \starttext Here is an example: \startitemize[n] \item \input tufte \startbackground Some backgrounded text \stopbackground \input tufte \stopitemize Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Framedtext width
Hello, Is there a way (magical option) to have the framedtext width adapt to the environment width where it is put? I've tried width=broad, but it always uses the page \textwidth, even if the framedtext is in an item or something like this. There is the same behaviour for background too. An example: \setuplayout[middle] \setupcolors[state=start] \defineframedtext[mybox] [width=broad, frame=on, before=\blank, after=\blank] \starttext Here is an example: \startitemize[n] \item \input tufte \startmybox Some text in the box \stopmybox \input tufte \stopitemize \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Background placement
Hello, The placement of backgrounded text is sometimes unexpected: it forces a page break even if there's much room in the page to put the whole thing. Searching in the mailing list I've found one thread about the subject (http://archive.contextgarden.net/message/20051205.090518.90cc69d4.en.html), but playing with \setupinterlinespace as suggested doesn't help. The problem often occurs just after a heading starting at the top of a page (section, enumeration title). Here is an example showing the behaviour: \setuplayout[middle] \setupcolors[state=start] % Background \definecolor[ScreenGray][s=.95] \setupbackground [background=screen, frame=on, strut=yes, width=broad, before=\blank, after=\blank, framecolor=ScreenGray, align=right] % Verbatim environment for programlisting \definetyping[programlisting] \setuptyping[programlisting] [bodyfont=small, before={\startbackground}, after={\stopbackground}] \starttext \input tufte \input tufte \input tufte \input tufte \input tufte \section{joke} Here is an example: \startprogramlisting Some code \stopprogramlisting And the text continues... \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Text style in bookmarks
On Sun, 21 May 2006 19:20:38 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> Hello, >> >> Is there a trick so that I can put styles like {\bf ...} or {\tt ...} in >> the headings without having any weird text in the bookmarks? >> > \setupinteraction[state=start] > > \appendtoks > \let\groupedcommand\thirdofthreearguments > \to \simplifiedcommands > > % no command for monospaced yet > > \unprotected \definealternativestyle [\v!mono] [\tt] [] > > \placebookmarks > \starttext > \chapter{test \mono{test} \bold{test}} > \stoptext > > (i will add the extra definitions to the core) Thanks! Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Text style in bookmarks
On Sat, 20 May 2006 12:17:06 -0700, Johannes Graumann <[EMAIL PROTECTED]> wrote: > nico wrote: >> >> Thanks, but it is not a global heading style I look for, but the ability >> to do things like this: >> >> \section{This {\tt file} {\em is} {\bf quite important}} >> >> So that it appears "This file is quite important" in the bookmark, >> instead >> of "This {file} {is} {quite important}". > > Hehe - may be first time I can help ;0) > > Recently I asked for something similar: how to get a short version of a > figure caption into the List of Figures while maintaining the long > version > in the actual caption. As a solution Hans came up with the 'selector' > feature below (not sure wheather the last release has it yet). Look in > the > archive ... > > If I understand you correctly this may be applicable to your problem. Well, yes, the selector is something I should try (it's in the distribution now). I just wanted to avoid writing two titles, since they are generated from a single source. BTW, using \bookmark as alternative title in bookmark would also work. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Text style in bookmarks
Hi Willi, On Sat, 20 May 2006 20:14:30 +0200, Willi Egger <[EMAIL PROTECTED]> wrote: > Provided I understnad you correctly, then you could play with code as: > > \setuphead Thanks, but it is not a global heading style I look for, but the ability to do things like this: \section{This {\tt file} {\em is} {\bf quite important}} So that it appears "This file is quite important" in the bookmark, instead of "This {file} {is} {quite important}". Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Text style in bookmarks
Hello, Is there a trick so that I can put styles like {\bf ...} or {\tt ...} in the headings without having any weird text in the bookmarks? Adding \bf or \tt as empty macros to the simplifiedcommands doesn't avoid the curly braces to appear (which is normal). Do I need to use something like \def\textbf#1{\def\textbf#1{\bgroup\bf #1\egroup} to have this working? Thanks for any hint. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] open math
On Fri, 19 May 2006 22:30:20 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> On Thu, 18 May 2006 22:02:03 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: >> >> Just a question about the ctx file as described in the doc: does it mean >> that every XML file is processed first by 'openmath' and then >> 'mathadore'? >> >> If so, why not using the xsltproc piping, avoiding the intermediate .om >> files? >> > i'm not aware of piping ... how does the command look then? Thinking a bit about this, you could avoid using two passes, by merging both stylesheets. The only limitation is the need of the node-set EXSL function (but available in xsltproc by default). Simple example: The main stylesheet (say, x-openmath.xsl): http://www.w3.org/1999/XSL/Transform"; xmlns:exsl="http://exslt.org/common"; exclude-result-prefixes="exsl" version='1.0'> The imported ones: x-sm2om.xsl --- http://www.w3.org/1999/XSL/Transform";> http://www.openmath.org/OpenMath 2.0 x-om2cml.xsl http://www.w3.org/1999/XSL/Transform";> http://www.openmath.org/OpenMath 2.0 XML file - a b c d e xsltproc x-openmath.xsl example.xml It should be checked on the real stylesheets, but it should work. It's nicer than piping commands, and should take less time to process. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] open math
On Fri, 19 May 2006 22:30:20 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> On Thu, 18 May 2006 22:02:03 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: >> >>> Hi, >>> >>> For those interested in mathml/openmath ... i've added some support for >>> openmath -> mathml conversion to the distribution (there is some stuff >>> in the manual svn repos as well). I dunno how many of you actually have >>> used openmath. Anyhow, it makes a nice demo of applying ctx job >>> description files (used for automatic preprocessing of the xml files to >>> content mathml and such). >> >> Just a question about the ctx file as described in the doc: does it mean >> that every XML file is processed first by 'openmath' and then >> 'mathadore'? >> >> If so, why not using the xsltproc piping, avoiding the intermediate .om >> files? >> > i'm not aware of piping ... how does the command look then? Provided that it's possible to pipe commands via ctx and/or texexec: xsltproc x-sm2om.xsl foo.xml | xsltproc -o foo.prep x-openmath.xsl - Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] open math
On Thu, 18 May 2006 22:02:03 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > Hi, > > For those interested in mathml/openmath ... i've added some support for > openmath -> mathml conversion to the distribution (there is some stuff > in the manual svn repos as well). I dunno how many of you actually have > used openmath. Anyhow, it makes a nice demo of applying ctx job > description files (used for automatic preprocessing of the xml files to > content mathml and such). Just a question about the ctx file as described in the doc: does it mean that every XML file is processed first by 'openmath' and then 'mathadore'? If so, why not using the xsltproc piping, avoiding the intermediate .om files? Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Weird texexec hang
On Fri, 19 May 2006 15:52:56 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> Yes, replacing background by a framedtext works fine. In fact I used >> that >> (and the 300 pages book compiled fine :-) but I changed to background to >> allow the code portions to split in several pages (when put in normal >> text >> flow). But if you say that background should be avoided in floats i'll >> use >> the framed typing definition for floats (that cannot split anyway). >> > i adapted the backgrounds to recognize floats, i'll sen dyou the file Ok, thanks, i'll try it. >> BTW, is there other known unsafe combinations to avoid? >> > well, \starttextbackground is the more modern way to go (only one level > needed since one can hook in mp code) I tried this too, but it became a real nightmare. It compiles ok, but is so slow: there were hundred of MP files, and the result was ugly (strange offsets, strange framed lines, strange color...). I deduced that I certainly did something wrong, but had no time to investigate in this area. And the compilation time is certainly the main drawback for me. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Weird texexec hang
On Fri, 19 May 2006 15:00:31 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> Hello, >> >> It took me quite some time to extract the following sequence from a 300p >> book, that makes the compilation hang. It looks like if it's in an >> infinite loop, but I don't know what happens. It seems related to the >> interaction of float, verbatim, and background stuff. >> >> I thought it was a local resource problem (few memory on my machine) but >> trying the code in live context never gave something either (i hope it >> is >> not still running!). >> >> What's wrong in my definitions/setups to have such a behaviour? >> > backgrounds inside a float ... not the ideal combination (some otr > intereference), What does mean otr? > but how about: Yes, replacing background by a framedtext works fine. In fact I used that (and the 300 pages book compiled fine :-) but I changed to background to allow the code portions to split in several pages (when put in normal text flow). But if you say that background should be avoided in floats i'll use the framed typing definition for floats (that cannot split anyway). BTW, is there other known unsafe combinations to avoid? Thanks, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Weird texexec hang
Hello, I took me quite some time to extract the following sequence from a 300p book, that makes the compilation hang. It looks like if it's in an infinite loop, but I don't know what happens. It seems related to the interaction of float, verbatim, and background stuff. I thought it was a local resource problem (few memory on my machine) but trying the code in live context never gave something either (i hope it is not still running!). What's wrong in my definitions/setups to have such a behaviour? \setuplayout[middle] \setupcolors[state=start] \setupinteraction[state=start] \definefloat[dbsidebar] \setupfloat [dbsidebar] [criterium=0.7\textwidth, leftmargindistance=-\outercombitotal, rightmargindistance=-\outercombitotal, default={outer,middle}] \setupcaption[dbsidebar][location=bottom,number=no] \defineframedtext [framesidebar] [width=.9\textwidth,bodyfont=small, corner=round,background=screen,backgroundscreen=.95] \setupbackground [background=screen, frame=on, strut=yes, topoffset=2mm, width=broad, before=\blank, after={\blank[small]}, align=right] % Verbatim environment for programlisting \definetyping[code] \setuptyping[code] [bodyfont=small, before={\startbackground}, after={\stopbackground}] \starttext \input tufte \input tufte \placedbsidebar{joke} {\startframesidebar \startcode some code \stopcode \stopframesidebar} \input tufte \input tufte \placedbsidebar{joke} {\startframesidebar \startcode some code \stopcode \stopframesidebar} \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Wrong image size evaluation
On Thu, 18 May 2006 17:28:42 +0200, Taco Hoekwater <[EMAIL PROTECTED]> wrote: > nico wrote: >> Hello, >> >> I have some troubles with a PNG image, that is not correctly rendered by >> context (too small). The difference I've found with another correctly >> displayed image is that the file does not contain any resolution unit >> (but >> a pixels/inch default seems reasonable). > > But pixels/cm is equally reasonable, and that is why pdftex ignores > invalid settings in PNG images completely, and uses its internal > default instead. You can control that default resolution by setting > \pdfimageresolution to an appropriate guess: > >{\pdfimageresolution=72 \externalfigure[ch01dia1.png]} But 72 means 72 dots per inch, isn't it? The file already contains that information (field Resolution given by identify). It's the unit that is missing (but when you set pdfimageresolution there isn't any unit either, the unit is implicit). But indeed setting the resolution by hand makes it work, thanks. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Wrong image size evaluation
Hello, I have some troubles with a PNG image, that is not correctly rendered by context (too small). The difference I've found with another correctly displayed image is that the file does not contain any resolution unit (but a pixels/inch default seems reasonable). Is there a workaround or specific setup to make this work (without explicit width setting)? Here is the test file I use. If you wish I can send the images, or find the troublesome PNG image at: http://svnbook.red-bean.com/trac/browser/trunk/src/en/book/images/ch01dia1.png?format=raw Thanks for your help. \starttext \startyping identify -verbose images/ch02dia1.png images/ch02dia1.png PNG 146x168 146x168+0+0 PseudoClass 135c 2kb 0.008u 0:01 Image: images/ch02dia1.png Format: PNG (Portable Network Graphics) Geometry: 146x168 Resolution: 28.34x28.34 Units: PixelsPerCentimeter \stoptyping \externalfigure[images/ch02dia1.png] \startyping identify -verbose images/ch01dia1.png images/ch01dia1.png PNG 511x585 511x585+0+0 DirectClass 54kb 0.094u 0:01 Image: images/ch01dia1.png Format: PNG (Portable Network Graphics) Geometry: 511x585 Resolution: 72x72 Units: Undefined \stoptyping \externalfigure[images/ch01dia1.png] \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Several publication lists
On Wed, 17 May 2006 11:08:50 +0200, Taco Hoekwater <[EMAIL PROTECTED]> wrote: > nico wrote: >> I don't know if it's doable or if it breaks the consistency of the >> current >> interface, but I would see something like the list mechanism: > > <> Ok, I can wait. If I can help by testing some beta releases of the module, tell me. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Several publication lists
On Tue, 16 May 2006 15:27:46 +0200, Taco Hoekwater <[EMAIL PROTECTED]> wrote: > nico wrote: >> >> Hm, I think it could be interesting to add such a feature to context, >> but >> I understand it cannot be done immediately. Latex already have such >> things > > Sure. Can you point me to the documentation of 'bibtopic' http://www.tex.ac.uk/tex-archive/macros/latex/contrib/bibtopic/bibtopic.pdf > and also > propose a calling / configuration syntax for the ConTeXt version? > (it is easier for me if I know what to work towards) I don't know if it's doable or if it breaks the consistency of the current interface, but I would see something like the list mechanism: \definebiblist[name][\setupbiblist options] \setupbiblist[name][\setuppublicationlist options] \setupbibfile[name][\setupbibtex options] \placebiblist[name] \definecombinedbiblist[bibgroup][biblist list][\setupcombinedlist options] \setupcombinedlist[bibgroup][ not yet clear what options it should provide ] \startbibentry[name][\startpublication options] \setupcite[name][what][options] (name optional) \cite[name][what][ref] or \cite[what][name:ref] (name optional) To keep the current interface, a default global publication list could exist: \setuppublicationlist = \setupbiblist[publication] \startpublication = \startbibentry[publication] \placepublications = \placebiblist[publication] \setupbibtex = \setupbibfile[publication] Example of use: % the specs come only from bibtex files \definebiblist[specs][criterium=all] \setupbibtex[specs][database={spec1,spec2},sort=short] \definebiblist[manuals][criterium=all] \setupbibtex[manuals][database=manbase,sort=short] % also an embedded definition for the manuals \startbibentry[manuals][k=me,t=manual,a=Hoekwater,y=2006] \author[]{Taco}[T.]{}{Hoekwater} \title{Publication Module} \stopbibentry % all the biblio stuff \definecombinedbiblist[allbibs][specs,manuals][criterium=all] % let's go \starttext \chapter{The doc} \section{References in the chapter} \subsection{Specifications} \placebiblist[specs][criterium=cite] \subsection{Manuals} \placebiblist[manuals][criterium=local] \section{Introduction} As explained in \cite[manuals][key][me]... \chapter{References Summary} \placecombinedlist[allbibs] \stoptext What is not clear for me: - if the bibentry numbering must be global or could restart to 1 for each list, - if it is really feasible to place the biblists several times in the doc, and if so, to which list the \cite actually points to. I hope that all of this doesn't sound too stupid :-) Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Several publication lists
On Tue, 16 May 2006 10:38:18 +0200, Taco Hoekwater <[EMAIL PROTECTED]> wrote: > nico wrote: >> Hello, >> >> I wonder if it is possible to display several publication lists. Can we >> achieve this with the bib module? What I would like to do is to split >> the >> publication list into different sections, like this: > > You cannot do this, sorry. Hm, I think it could be interesting to add such a feature to context, but I understand it cannot be done immediately. Latex already have such things (chapterbib, bibtopic) and IMHO there is a real need for this. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Bibliography and whitespace
Hello, When I use \placebublications the white space I've set is no more taken into account. Besides, in the example below the space between the heading (Biblio) and the publication is also too small. Regards, BG \usemodule[bib] \setupwhitespace[big] \setuppublications[criterium=all] \startpublication[k=TDG,t=book] \title{The Definitive Guide} \author[]{Norman}[]{Norman}{Walsh} \author[]{Leonard}[]{Leonard}{Muellner} \isbn{156592-{}580-{}7} \pubname{O'Reilly} \stoppublication \starttext \section{Biblio} \placepublications \section{Para} this is a paragraph. this is a paragraph. this is a paragraph. this is a paragraph. this is a paragraph. \stoptext ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Several publication lists
Hello, I wonder if it is possible to display several publication lists. Can we achieve this with the bib module? What I would like to do is to split the publication list into different sections, like this: \section{Bibliography} \subsection{Specifications} ... Here are the list of publications that are specifications ... \subsection{Manuals} ... Here some manuals ... Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Table nesting
Hello, I try to nest some tables, but the following case crashes, telling about some tex capacity exceeded. But i don't really believe in some capacity problem since it works fine when removing the enclosing of \bTABLEbody \eTABLEbody. BTW, is there some method/option to change the space size between the cell rules and the cell content? Regards, BG \starttext \startbuffer[2] \bTABLE[align=lohi,width=.5\hsize] \bTR\bTD c \eTD\bTD d\eTD\eTR \bTR\bTD c \eTD\bTD d\eTD\eTR \eTABLE \stopbuffer \startbuffer \bTABLE[align=lohi,width=.5\hsize] \bTR\bTD \getbuffer[2] \eTD\bTD d\eTD\eTR \eTABLE \stopbuffer \bTABLE[frame=on,split=repeat,width=.3\textwidth] \bTABLEbody \bTR \bTD a foo \eTD \bTD a bar \eTD \bTD a baz \eTD \eTR \bTR \bTD b foo \eTD \bTD \getbuffer \eTD \bTD b baz \eTD \eTR \bTR \bTD c foo \eTD \bTD c bar \eTD \bTD c baz \eTD \eTR \eTABLEbody \eTABLE \stoptext ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] brace error after a \placefigure
On Sat, 13 May 2006 04:08:58 -0400, Sanjoy Mahajan <[EMAIL PROTECTED]> wrote: > I can't figure out what causes the brace error with this test.tex > example file: > > \starttext > \placefigure[margin]{A caption}{\externalfigure[]} > > {test}. > \stoptext Yes, strange. Looks like a grouping issue around this in page-flt: \ifmargeblokken % waarschijnlijk gebroken ! ! ! ! \doifinset\v!margin{#2} {\endgraf \bgroup\everypar{\egroup\the\everypar}% \hsize\@@mbwidth}% \fi inmargin seems to work, but i don't know if it should do the same thing. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Linux: ConTeXt in local texmf-tree and Ruby scripts - HOWTO?
On Thu, 11 May 2006 10:12:58 -0700, Johannes Graumann <[EMAIL PROTECTED]> wrote: > I'm at the end of my knowledge and intuition. Can anybody help > circumventing > the need for the monster 'ruby ~/texmf/scripts/context/ruby/texexec.rb > document.tex'? Since I'm lazy, I didn't add any new path nor link, but just created the following wrapper texexec script in a classical bin directory (/usr/local/bin): #!/bin/sh ruby /your/path/texmf/scripts/context/ruby/texmfstart.rb texexec.rb $@ Don't know if it can help in your case. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] new release
On Thu, 11 May 2006 00:11:47 +0200, Thomas A. Schmitz <[EMAIL PROTECTED]> wrote: > Yes, that's strange. I just checked, and everything is golden on a linux > system (gentoo, but I gues the same is true for other linux distros). So > I really don't see why OS X should behave differently. Is there any > debugging info that I could provide? How 'bout the other OS X users (I > seem to recall there were quite a few of them): do you get the same > error? Strictly speaking it's not OSX, but i've a FreeBSD distro, which is close, and it works fine. Are you sure you have the permission to write in any of these paths? BTW, i find dangerous to do (kpse.formatpath method): # locate writable path if ! formatpath.empty? then formatpath.split_path.each do |fp| fp.gsub!(/\\/,'/') # remove funny patterns fp.sub!(/^!!/,'') fp.sub!(/\/+$/,'') fp.sub!(/unsetengine/,if enginepath then engine else '' end) if ! fp.empty? && (fp != '.') then # strip (possible engine) and test for writeability fpp = fp.sub(/#{engine}\/*$/,'') if FileTest.directory?(fpp) && FileTest.writable?(fpp) then # use this path formatpath = fp.dup break end end end end # needed ! begin File.makedirs(formatpath) ; rescue ; end ; If none of the paths from formatpath is valid, we keep the whole concat path in this variable... that then is used to create a directory tree. Thomas, maybe that you have ugly directories created starting with an hidden directory named ".:". You should check that. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Wiki verbatim updated
Hello, I should have written this a long time ago when Hans improved drastically this feature. For those who may be interested in: http://wiki.contextgarden.net/Verbatim_text#Line_numbering Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] List of Formulas
On Tue, 09 May 2006 23:38:47 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> Hello, >> >> Is it possible to display a list of the numbered formulas (done with >> \placeformula)? I tried \placelist[formula] without success. >> > you want to see the formulas too? Well, no, i just wanted a list, like a list of tables, figures, or enumerations, with the pages where they appear. But ok, since it is not available by default, i can put each formula in a specific Equation enumeration an then do a \placelist[enumeration:Equation]. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Global and per product TOC
Hello, I would like to be able to have a set of books in a single document, and think the project/product model could be used. In the big manual it is said that one can have a completecontent per product. I would like a global TOC, and for each product a TOC per product (in this case per book). Currently each book have the whole project TOC. How to achieve this? Thanks for any hint. The structure I've tried: \startproject proj % global TOC \completecontent \product book1 \product book2 \stopproject -- \startproduct book1 \project proj % well, to put in an environment file... \startsectionblockenvironment[frontpart] \setuppagenumber[number=1] \setuppagenumbering[conversion=romannumerals] \stopsectionblockenvironment \startsectionblockenvironment[bodypart] \setuppagenumber[number=1] \stopsectionblockenvironment \starttext \startfrontmatter % Local book TOC? \completecontent[criterium=local] \chapter{A} a \chapter{B} a \stopfrontmatter \startbodymatter \chapter{A} a \chapter{B} a \stopbodymatter \startappendices \chapter{A} a \chapter{B} a \stopappendices \stoptext \stopproduct - (The same for book2) Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] List of Formulas
Hello, Is it possible to display a list of the numbered formulas (done with \placeformula)? I tried \placelist[formula] without success. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] \quad in pdf author
On Tue, 9 May 2006 12:50:05 -0400 (EDT), Aditya Mahajan <[EMAIL PROTECTED]> wrote: > Hi, > > \setupinteraction >[ > author={Author 1 \quad Author 2}, >] > > gives me "Author 1 hskip 1em" in pdf info. Is there some way to ensure > that \quad is ignored when used in \setupinteraction[...]. As Hans said once, you can do this: \appendtoks \def\quad{}% \to \simplifiedcommands \setupinteraction [state=start, author={Author 1 \quad Author 2}] \starttext bla \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] new release
On Tue, 09 May 2006 17:16:38 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: >> #ENV['TEXFONTMAPS'] = >> ".;\$TEXMF/fonts/map/{#{backend},pdftex,dvips,}//" > i wonder why this does not work Unix likes column separator (and often cannot stand windows one ;-). If i change ';' into ':' it works. BTW, why is this set? Isn't it up to texmf.cnf to configure this (like for texexec.pl)? Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] new release
On Tue, 09 May 2006 15:11:23 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: What's wrong? >>> maybe you need to run mktexlsr >>> >> Doesn't help, and the required map files are here for a while (eg: >> kpsewhich ec-base.map gives >> /usr/local/share/texmf-local/fonts/map/pdftex/context/ec-base.map). >> >> I tried to use the perl version, and now it tries to find stuff in >> dvipdfm >> fonts, which plants: >> >> Warning: pdfetex (file >> /usr/local/share/texmf-local/fonts/map/dvipdfm/context/original-base.map): >> invalid entry for `fmvr8x': font file missing >> >> It works if i remove (or rename) the dvipdfm directory. >> >> What can i do to have ruby thing working, and pdftex fonts used instead >> of >> dvipdfm ones? >> > your texmf.cnf file should contain: > > TEXFONTMAPS = > .;$TEXMF/fonts/map/{$progname,pdftex,dvips,}//;$TEXMF/{$progname,pdftex,dvips}/{config,}// For the ruby issue: if I remove the TEXFONTMAPS environment setting from tex.rb, it works on my machine. I don't know if it can be a fix working on any platform: def fixbackendvars(backend) if backend then report("fixing backend map path for #{backend}") if getvariable('verbose') ENV['backend'] = backend ; ENV['progname']= backend unless validtexengine(backend) #ENV['TEXFONTMAPS'] = ".;\$TEXMF/fonts/map/{#{backend},pdftex,dvips,}//" else report("unable to fix backend map path") if getvariable('verbose') end end Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] new release
On Tue, 09 May 2006 15:11:23 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> On Tue, 09 May 2006 11:09:43 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: >> >> >>> nico wrote: >>> >>>> On Mon, 08 May 2006 13:04:58 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: >>>> >>>> >>>> Got big problems with the fonts that are no more found when using the >>>> ruby >>>> stuff. Since the unix stubs are crappy, I do this: >>>> >>>> ruby /usr/local/share/texmf-local/scripts/context/ruby/texmfstart.rb >>>> texexec.rb --pdf typefile.tex >> >>>> What's wrong? >>>> >>> maybe you need to run mktexlsr >>> >> Doesn't help, and the required map files are here for a while (eg: >> kpsewhich ec-base.map gives >> /usr/local/share/texmf-local/fonts/map/pdftex/context/ec-base.map). >> >> I tried to use the perl version, and now it tries to find stuff in >> dvipdfm >> fonts, which plants: >> >> Warning: pdfetex (file >> /usr/local/share/texmf-local/fonts/map/dvipdfm/context/original-base.map): >> invalid entry for `fmvr8x': font file missing >> >> It works if i remove (or rename) the dvipdfm directory. >> >> What can i do to have ruby thing working, and pdftex fonts used instead >> of >> dvipdfm ones? >> > your texmf.cnf file should contain: > > TEXFONTMAPS = > .;$TEXMF/fonts/map/{$progname,pdftex,dvips,}//;$TEXMF/{$progname,pdftex,dvips}/{config,}// > > as long as we have no uniform map file syntax, progs needs to be able to > find their own map files Ok, thanks, modifying texmf.cnf as you say fixes the path precedence. Now, is there a ruby debug mode to see why the paths are lost with texexec.rb? Or tests I could do to find out what happens? Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] new release
On Mon, 08 May 2006 13:04:58 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > Hi, > > Today i'll upload a new release. Highlights: > > - some fixes/extensions discussed the last few weeks What about fixing this one (http://archive.contextgarden.net/message/20060430.190029.2f68d437.en.html)? Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] new release
On Tue, 09 May 2006 11:09:43 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> On Mon, 08 May 2006 13:04:58 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: >> >> >> Got big problems with the fonts that are no more found when using the >> ruby >> stuff. Since the unix stubs are crappy, I do this: >> >> ruby /usr/local/share/texmf-local/scripts/context/ruby/texmfstart.rb >> texexec.rb --pdf typefile.tex >> > this should be ok in this mornings version Seems that the unix texmfstart stub is missing. >> What's wrong? >> > maybe you need to run mktexlsr Doesn't help, and the required map files are here for a while (eg: kpsewhich ec-base.map gives /usr/local/share/texmf-local/fonts/map/pdftex/context/ec-base.map). I tried to use the perl version, and now it tries to find stuff in dvipdfm fonts, which plants: Warning: pdfetex (file /usr/local/share/texmf-local/fonts/map/dvipdfm/context/original-base.map): invalid entry for `fmvr8x': font file missing It works if i remove (or rename) the dvipdfm directory. What can i do to have ruby thing working, and pdftex fonts used instead of dvipdfm ones? Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] new release
On Mon, 08 May 2006 13:04:58 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > Hi, > > Today i'll upload a new release. Got big problems with the fonts that are no more found when using the ruby stuff. Since the unix stubs are crappy, I do this: ruby /usr/local/share/texmf-local/scripts/context/ruby/texmfstart.rb texexec.rb --pdf typefile.tex What's wrong? Here is the log: This is pdfeTeX, Version 3.141592-1.21a-2.2 (Web2C 7.5.4) (format=cont-en 2006.5.8) 8 MAY 2006 19:55 entering extended mode (/usr/local/share/texmf-local/web2c/natural.tcx) **typefile.tex emergencyend (./typefile.tex ConTeXt ver: 2006.05.08 12:59 fmt: 2006.5.8 int: english mes: english language: language en is active system : cont-new loaded (/usr/local/share/texmf-local/tex/context/base/cont-new.tex systems : beware: some patches loaded from cont-new.tex color : palette rollover is available ) system : cont-old loaded (/usr/local/share/texmf-local/tex/context/base/cont-old.tex loading : Context Old Macros ) system : cont-fil loaded (/usr/local/share/texmf-local/tex/context/base/cont-fil.tex loading : Context File Synonyms ) system : cont-sys loaded (/usr/local/share/texmf-dist/tex/context/user/cont-sys.tex (/usr/local/share/texmf-local/tex/context/base/type-exa.tex) (/usr/local/share/texmf-local/tex/context/base/type-syn.tex) (/usr/local/share/texmf-local/tex/context/base/type-enc.tex) (/usr/local/share/texmf-local/tex/context/base/type-siz.tex) (/usr/local/share/texmf-local/tex/context/base/type-map.tex) (/usr/local/share/texmf-local/tex/context/base/type-spe.tex) (/usr/local/share/texmf-local/tex/context/base/type-akb.tex)) bodyfont: 12pt rm is loaded language: patterns nl->texnansi:texnansi->1->2:3 nl->ec:ec->2->2:3 fr-> texnansi:texnansi->3->2:3 fr->ec:ec->4->2:3 de->texnansi:texnansi->5->2:3 de->e c:ec->6->2:3 it->texnansi:texnansi->7->2:3 it->ec:ec->8->2:3 pt->texnansi:texna nsi->9->2:3 pt->ec:ec->10->2:3 hr->ec:ec->11->2:3 pl->pl0:pl0->12->2:3 pl->ec:e c->13->2:3 pl->qx:qx->14->2:3 cz->il2:il2->15->2:3 cz->ec:ec->16->2:3 sk->il2:i l2->17->2:3 sk->ec:ec->18->2:3 sl->ec:ec->19->2:3 en->ec:ec->21->2:3 uk->ec:ec- > 22->2:3 us->ec:ec->23->2:3 agr->agr:agr->24->2:3 da->ec:ec->25->2:3 > sv->ec:ec- > 26->2:3 af->ec:ec->27->2:3 no->ec:ec->28->2:3 deo->ec:ec->29->2:3 > es->ec:ec->3 0->2:3 ca->ec:ec->31->2:3 la->ec:ec->32->2:3 ro->ec:ec->33->2:3 tr->ec:ec->34-> 2:3 fi->ec:ec->36->2:3 hu->ec:ec->37->2:3 loaded specials: tex,postscript,rokicki loaded \openout2 = `typefile.tui'. system : typefile.top loaded (./typefile.top specials: loading definition file tpd (/usr/local/share/texmf-local/tex/context/base/spec-tpd.tex specials: loading definition file fdf (/usr/local/share/texmf-local/tex/context/base/spec-fdf.tex) specials: fdf loaded ) specials: fdf,tpd loaded ) \openout0 = `typefile-mpgraph.mp'. \openout0 = `mpgraph.mp'. (./typefile.tuo) (./typefile.tuo) (./typefile.tuo) (./typefile.tuo) (./typefile.tuo) (./typefile.tuo) (./typefile.tuo) (./typefile.tuo) (./typefile.tuo) (./typefile.tuo) (./typefile.tuo) (./typefile.tuo) systems : begin file typefile at line 146 (/usr/local/share/texmf-local/tex/context/base/pdfr-ec.tex) verbatim: file ./test-001.tex does not exist verbatim: file joke does not exist fonts : resetting map file list fonts : using map file: original-base fonts : using map file: ec-public-lm fonts : using map file: ec-base fonts : using map file: 8r-base fonts : using map file: t5-base fonts : using map file: original-ams-base fonts : using map file: original-ams-euler fonts : using map file: original-public-lm [1.1 Warning: pdfetex (file original-empty.map): cannot open font map file Warning: pdfetex (file original-base.map): cannot open font map file Warning: pdfetex (file ec-public-lm.map): cannot open font map file Warning: pdfetex (file ec-base.map): cannot open font map file Warning: pdfetex (file 8r-base.map): cannot open font map file Warning: pdfetex (file t5-base.map): cannot open font map file Warning: pdfetex (file original-ams-base.map): cannot open font map file Warning: pdfetex (file original-ams-euler.map): cannot open font map file Warning: pdfetex (file original-public-lm.map): cannot open font map file ] [2.2] systems : end file typefile at line 167 ) Here is how much of TeX's memory you used: 1168 strings out of 58787 21094 string characters out of 563686 4585586 words of memory out of 5529308 39652 multiletter control sequences out of 1+10 75349 words of font info for 38 fonts, out of 50 for 2000 232 hyphenation exceptions out of 1000 47i,18n,54p,252b,773s stack positions out of 1500i,500n,5000p,20b,5000s PDF statistics: 10 PDF objects out of 30 0 na
Re: [NTG-context] Footnotes lost in description terms
On Mon, 08 May 2006 01:28:59 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: >>> send me a test file showing both >> >> Here it is. The first and third description terms containing footnotes >> are wrapped. The second term does not contain footnote and is not >> wrapped (it's the file committed in contexttest). > > it took me quitea while to find out that it's in the the description > preroll which meant that the calculated width was too small and > therefore the real thing wrapped Thanks much, it works fine. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Footnotes lost in description terms
On Sun, 07 May 2006 19:52:23 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: Thanks, it works fine. But as a side effect (not introduced by the patch) it seems that putting footnotes in a term sets a fixed width to this term: in the example the term wraps, even if I set width=broad in the description definition. If the term does not contain a footnote, it is not wrapped. send me a test file showing both Here it is. The first and third description terms containing footnotes are wrapped. The second term does not contain footnote and is not wrapped (it's the file committed in contexttest). Regards, BG test-002.tex Description: TeX document ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Description nesting
On Sat, 06 May 2006 10:30:24 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> Hello, >> >> Is there a way to nest some descriptions, where the nested descriptions >> respect the enclosing indentation? >> > btw, we need some test files for descriptions in the test-suite I've added two tests under core-des.tex/, one about basic combination of location and width options, the other about the footnotes. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Footnotes lost in description terms
On Sat, 06 May 2006 09:51:38 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> Hello, >> >> When some footnotes are put in description terms, their number appears >> in >> the terms but their text don't appear at the bottom of the page. Is it a >> known limitation? >> > of boxed stuff, indeed, so we need to postpone and flush Thanks, it works fine. But as a side effect (not introduced by the patch) it seems that putting footnotes in a term sets a fixed width to this term: in the example the term wraps, even if I set width=broad in the description definition. If the term does not contain a footnote, it is not wrapped. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Description nesting
On Sat, 06 May 2006 10:29:56 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> Hello, >> >> Is there a way to nest some descriptions, where the nested descriptions >> respect the enclosing indentation? >> > you can play with this patch Ok, it works fine, thanks! It also makes the indentation of a hanging description put in an itemize more consistent. BTW, I wonder if it should not be also applied to location=left. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Footnotes lost in description terms
Hello, When some footnotes are put in description terms, their number appears in the terms but their text don't appear at the bottom of the page. Is it a known limitation? Here is an example: \definedescription[descr][ headstyle=bold,style=normal,align=left,location=hanging, width=broad,margin=1cm] \setupwhitespace[medium] \starttext Here is a footnote\footnote{In a simple paragraph}. \startdescr{This\footnote{A footnote} term contains\footnote{Another one} a footnote} This is a shorter item label, and some text\footnote{What about this?} that talks about it. The text is wrapped into a paragraph, with successive lines indented. \stopdescr \startdescr{This\footnote{More footnotes} term contains\footnote{Another again} a footnote} This is a shorter item label, and some text that talks about it. The text is wrapped into a paragraph, with successive lines indented. \stopdescr Here is a footnote\footnote{After the descriptions}. \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Description nesting
Hello, Is there a way to nest some descriptions, where the nested descriptions respect the enclosing indentation? Funnily the wiki speaks about the subject (http://wiki.contextgarden.net/Description) but doesn't give any solution (btw, the given solution to have several paragraphs in a description looks obsolete since \start \stop works pretty well). Here is an example that I would like to see working: \definedescription[descr][ headstyle=bold,style=normal,align=left,location=hanging, width=broad,margin=1cm] \setupwhitespace[medium] \starttext \startdescr{Para} This is a shorter item label, and some text that talks about it. The text is wrapped into a paragraph, with successive lines indented. This is another paragraph under the "Para" item. \startdescr{SubPara1} This is a shorter item label, and some text that talks about it. The text is wrapped into a paragraph, with successive lines indented. \stopdescr \startdescr{SubPara2} This is a shorter item label, and some text that talks about it. The text is wrapped into a paragraph, with successive lines indented. \stopdescr \stopdescr \stoptext ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Itemize head symbol
On Fri, 5 May 2006 01:37:45 -0400 (EDT), Aditya Mahajan <[EMAIL PROTECTED]> wrote: >> Yes, that's it. I wondered if it was possible a to specify a different >> symbol for a head, something like this: >> >> \startitemize[n][headstyle=bold] >> \head Default head symbol (here a number)\par Body >> \head Default head symbol again\par Body >> \symhead{U} The head symbol is U\par Body >^^^ > > How about \headsym{U} Ah yes, it works! So, it exists. Thanks! Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] dbcontext
Hello, Just for your information, dbcontext-0.1.0 is now released and available at http://dblatex.sf.net. It is another attempt to convert DocBook V4 documents to PDF by using ConTeXt, by using XSL stylesheets to translate from XML to context macros. It is quite experimental but can already handle basic documents. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] ConTeXt + MetaUML
On Tue, 02 May 2006 16:55:45 +0200, Renaud AUBIN <[EMAIL PROTECTED]> wrote: > Hi all, > > Some times ago, I have discovered MetaUML via the MetaPost ML. As a > consequence, I have tried to use it with ConTeXt... Here is the result: > > Considering a VERY simple example: [...] > > Apparently, MetaUML is based on boxes.mp > > (temp-mpgraph.mp (/usr/share/texmf-tetex/metapost/metauml/metauml.mp > HERE > (/usr/share/texmf-tetex/metapost/base/boxes.mp) > (/usr/share/texmf-tetex/metapost/metauml/util_infrastructure.mp > (/usr/share/texmf-tetex/metapost/metauml/util_log.mp)) > > > > It have already tried to use boxes.mp in ConTeXt in the past, but > switched for metaobj because: > 1. metaobj is more suitable to my needs > 2. boxes.mp causes troubles when used with ConTeXT > > I'll keep searching a solution but if one of yours has already dealt > with this kind of problems and succeeded in using boxes or, best, > MetaUML... I remember I had such troubles when including boxes. It makes a mess when included in a graphic. Inluding it via \startMPinclusions makes your example work. \starttext \startMPinclusions input metauml.mp; \stopMPinclusions \startuseMPgraphic{xx} Class.A("A")()(); drawObject(A); \stopuseMPgraphic \placefigure[here][fig:xx]{xx}{\useMPgraphic{xx}} \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Table of contents and List of figures
On Mon, 01 May 2006 13:07:08 +0200, WN <[EMAIL PROTECTED]> wrote: > Both your solutions work, great !! Thanks > > BTW One question, as I am still learning Context (simple user), but > where did you find these options for \completecontent ? > I could not find it in the manuals, Wiki and this mailing list. It's in the big manual (cont-enp), in the section "References/Table of contents". The complete list of options is given for setuplist (p 150), and examples of placelist are given (p 155-159). The manual is far complete but need a careful read (many information in few pages). Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Table of contents and List of figures
On Sun, 30 Apr 2006 19:13:34 +0200, WN <[EMAIL PROTECTED]> wrote: > Question 1) : > > In my document I am using > \setupcombinedlist[content][alternative=c,aligntitle=no,width=4em] > and now I want to use the same layout for the list of figures but there > is not something equivalent like > \setupcombinedlist[figure][alternative=c,aligntitle=no,width=4em] The TOC is a combination of several lists (chapter, section, etc.), but a LOF is a single list. Try: \setuplist[figure][alternative=c,aligntitle=no,width=4em] or: \placelist[figure][alternative=c,aligntitle=no,width=4em] > Question 2): > > In my document I am also using \part and in the TOC the part number > prefixes the pagenumber like > > I want to get rid of the partnumbers which are prefixed to the > pagenumbers > so my TOC looks like > > Deel I Klassieke Elektrodynamica . . . . . . . . . . . . . . . . . . 1 Try this: \completecontent[partnumber=no] Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] \typefile with a file in \usepath fails
On Sun, 30 Apr 2006 18:59:53 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> On Sun, 30 Apr 2006 15:22:49 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: >> >> >>>>> what version of context do you run? i though that i added support for >>>>> that some time ago >>>>> >>>> Version 2006.04.27. >>>> >>>> \dodotypefile checks where the file is, but a following call to >>>> \makelocreadfilename seems to set improperly \readfilename, but I'm >>>> not >>>> sure to understand correctly the code. > it's > > \makelocreadfilename{#3}% > > that does the search With the following patch it works: the \filepath found is used to expand the filename. \makelocreadfilename is still used, but i don't understand its role. \def\dodotypefile[#1][#2]#3% {\bgroup \let\currenttypingclass\??tp \edef\currenttyping{#1}% \typingparameter\c!before \doiflocfileelse{#3} \donetrue % sets \readfilename {\doifinputfileelse{#3} {\donetrue\def\readfilename{\pathplusfile{\filepath}{#3}}} % here the filename is absolute \donefalse}% \ifdone \startpacked % includes \bgroup \dosetuptypelinenumbering{#2}% \doifinset{\typingparameter\c!option}{\v!commands,\v!slanted,\v!normal} {\setuptyping[#1][\c!option=\v!none]}% \doif{\typingparameter\c!option}\v!color {\expandafter\aftersplitstring#3\at.\to\prettyidentifier \settypingparameter\c!option{\prettyidentifier}}% \initializetyping \startverbatimcolor % still use this macro, but applied to \readfilename instead of #3 \makelocreadfilename{\readfilename}% \doifundefinedelse{\currenttypingclass#3\v!global\c!start} ... Now it can wait a real fix :-) Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] \typefile with a file in \usepath fails
On Sun, 30 Apr 2006 18:59:53 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> On Sun, 30 Apr 2006 15:22:49 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: >> >> >>>>> what version of context do you run? i though that i added support for >>>>> that some time ago >>>>> >>>> Version 2006.04.27. >>>> >>>> \dodotypefile checks where the file is, but a following call to >>>> \makelocreadfilename seems to set improperly \readfilename, but I'm >>>> not >>>> sure to understand correctly the code. >>>> >>>> >>> \tracefilestrue >>> >>> >> Hm, verbatim seems not using the file interface: there's no trace about >> file found or not related to typefile. Another thing I did is to patch >> \processfileverbatim to trace what is actually the file used: >> >> \def\processfileverbatim#1% >>{\par >> \bgroup >> \writestatus{jo}{file=#1} >> ... >> >> And doing: >> >> \typefile{list1.tex} % file in the current directory (ok) >> \typefile{test-001.tex} % file in the \usepath directory (nok) >> \typefile{joke} % file that does not exist (ok, an error is printed) >> \typefile{pos2.tex} % again a local existing file (ok) >> >> Gives the traces: >> >> systems : begin file typefile at line 79 >> jo : file=list1.tex >> systems : searching for pdfr-ec on tex path >> systems : pdfr-ec located >> (/usr/local/share/texmf-local/tex/context/base/pdfr-ec.tex) >> jo : file=test-001.tex >> verbatim: file joke does not exist >> jo : file=pos2.tex >> >> So, the actual file path is not used, but it is the argument passed that >> is always used. >> > it's > > \makelocreadfilename{#3}% > > that does the search Really? As far as I understand the code, it sets \readfilename and \locreadfilename in a clean way, and that's all: \def\makelocreadfilename#1% {\sanitizefilename#1\to\readfilename \checkfilename\readfilename \ifcase\kindoffile \edef\locreadfilename{\pathplusfile\f!currentpath{#1}}% \fi} Anyway, if it's that call that should expand the filename, it does not work. In \dodotypefile the search is done previously by a call to \doifinputfileelse that sets \filepath (set again to \readfilename but I don't know why), but this result is not used since \readfilename is re-set to #3 by \makelocreadfilename. But you know this far better than I :-) Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] \typefile with a file in \usepath fails
On Sun, 30 Apr 2006 15:22:49 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: >>> what version of context do you run? i though that i added support for >>> that some time ago >> >> Version 2006.04.27. >> >> \dodotypefile checks where the file is, but a following call to >> \makelocreadfilename seems to set improperly \readfilename, but I'm not >> sure to understand correctly the code. >> > \tracefilestrue > Hm, verbatim seems not using the file interface: there's no trace about file found or not related to typefile. Another thing I did is to patch \processfileverbatim to trace what is actually the file used: \def\processfileverbatim#1% {\par \bgroup \writestatus{jo}{file=#1} ... And doing: \typefile{list1.tex} % file in the current directory (ok) \typefile{test-001.tex} % file in the \usepath directory (nok) \typefile{joke} % file that does not exist (ok, an error is printed) \typefile{pos2.tex} % again a local existing file (ok) Gives the traces: systems : begin file typefile at line 79 jo : file=list1.tex systems : searching for pdfr-ec on tex path systems : pdfr-ec located (/usr/local/share/texmf-local/tex/context/base/pdfr-ec.tex) jo : file=test-001.tex verbatim: file joke does not exist jo : file=pos2.tex So, the actual file path is not used, but it is the argument passed that is always used. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] \typefile with a file in \usepath fails
On Sun, 30 Apr 2006 12:33:20 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> Hello, >> >> \typefile does not output a file not in the current directory but >> available from a path defined by \usepath. It sounds like a bug since >> the >> file is actually found; if not, a message telling that the file does not >> exist would be printed. >> >> Example: >> \usepath[/path/to/my/file] >> \typefile{filebasename} >> >> > what version of context do you run? i though that i added support for > that some time ago Version 2006.04.27. \dodotypefile checks where the file is, but a following call to \makelocreadfilename seems to set improperly \readfilename, but I'm not sure to understand correctly the code. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] \typefile with a file in \usepath fails
Hello, \typefile does not output a file not in the current directory but available from a path defined by \usepath. It sounds like a bug since the file is actually found; if not, a message telling that the file does not exist would be printed. Example: \usepath[/path/to/my/file] \typefile{filebasename} Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Part head centering and empty header
On Thu, 27 Apr 2006 15:56:47 -0700, Johannes Graumann <[EMAIL PROTECTED]> wrote: > Hello > > I have coded my 'Appendix' like so: [...] > > \startappendices > \setuppagenumbering[way=bytext,partnumber=no,conversion=numbers,location={header,right}] > \framed > [% > height=\textheight,% > frame=off,% > ] > { > \part{Appendices} > } > {\stopappendices} > > Which gives me a nicely vertically and horizontally centered title. One > problem remains though: I can't get rid of the page number. The > framed '\setuphead[part]' commands concerning header and footer are > being > overruled and I can't figure out how to have an empty header for just the > page containing the frame. You're right; I don't know how to fix this, but for the centering aspect I would suggest another approach that is more in the context way of doing: \def\PartTitle#1#2% {\framed[frame=off,height=\textheight,width=\textwidth,align={middle,lohi}]{#2}% \pagebreak} \setuphead [part] [header=empty, footer=empty, alternative=middle, placehead=yes, resetnumber=no, % number=no, command=\PartTitle, page=right ] \starttext \startappendices \setuppagenumbering[way=bytext,partnumber=no,conversion=numbers, location={header,right}] \part{Some Appendices} \chapter{Chapter 1} A text \stopappendices \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Part and pagenumbers
On Thu, 27 Apr 2006 12:24:38 -0700, Johannes Graumann <[EMAIL PROTECTED]> wrote: > Hello, > > Whe I use \part, the pagenumbers switch to 'partno.-reset_pageno.' Can > somebody please point out to me how to just have my pre-'part' page > numbering run on? I'm not sure if you want to keep the part page number printed or not. Anyway, to have the page numbering continue try way=bytext, and to remove the part number printed try partnumber=no. \startbodymatter \setuppagenumbering[way=bytext,partnumber=no] \part{A part} Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] verb-c and tabulator width
On Wed, 26 Apr 2006 21:26:08 +0200 (CEST), Peter Münster <[EMAIL PROTECTED]> wrote: > On Wed, 26 Apr 2006, nico wrote: > >> On Wed, 26 Apr 2006 19:43:48 +0200 (CEST), Peter Münster >> <[EMAIL PROTECTED]> >> wrote: >> >> > One (probably there will come more) question: >> > How could I adjust the width of the tabulator? >> >> Use the tab option (not specific to C): > > Thanks! In fact I should have looked into texshow instead of relying on > the > old \chardef\spacespertab=... > > I'm sorry, here comes already my second problem: > > \usemodule[verb-c] > \setupcolors[state=start] > \setuptyping[option=C,tab=4] > \starttext > Contents of file \type{test.c}: > \startC > /** Doing this and that. > \param i the index */ > void do_this(int i){ > int bla; > } > \stopC > > Here we get \quotation{\type{! Missing number, treated as zero.}}: > \typefile{test.c} > \stoptext > > Could you help again? Sorry, this time I cannot help. I think it's a bug in verb-c that makes a mess with standard C comments on several lines. C++/ISO C99 comments (//) seem correctly handled. Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Table width trouble
On Wed, 26 Apr 2006 00:11:56 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> On Sun, 23 Apr 2006 18:28:20 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: >> >> >>> nico wrote: >>> >>>> Hello, >>>> >>>> I come back with that damn table test case. With release 2006.04.22: >>>> [...] >>>> >>>> >>>> >>> \long\def\dohandleTBLcellA#1#2[#3]#4% >>> >> >> Thanks, it does it. Another torture case: when column widths are >> partially >> defined, it can give a weird result (here the last column has almost >> disppeared). Since it's a limit case, I don't know if it's worth being >> fixed. >> > indeed a strange case > > the best is to collect them so that i can look into them some rainy day > > (btw, if users have interesting example tables that demo something not > in ennatab, then we can add them there) I haven't ready-to-add tables, but maybe the following topics could be added (unless you want to let them to wiki): - use of \bTABLEhead..\eTABLEhead \bTABLEbody..\eTABLEbody and split=repeat, - use of the options distance, leftmargindistance, etc, - use of negative column/row values (not in the wiki). Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Itemize head symbol
On Wed, 26 Apr 2006 00:13:09 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> Hello, >> >> Is it possible to change the symbol of \head in an itemize list, like >> \sym >> does for \item? >> > i'm not sure if i understand the question ... heads are like items so > the same symbols apply (or do you want different symbols for \item and > \head in one itemize?) Yes, that's it. I wondered if it was possible a to specify a different symbol for a head, something like this: \startitemize[n][headstyle=bold] \head Default head symbol (here a number)\par Body \head Default head symbol again\par Body \symhead{U} The head symbol is U\par Body \head The default symbol again\par Body \stopitemize But according to your answer, I guess it's not available :-) Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] verb-c and tabulator width
On Wed, 26 Apr 2006 19:43:48 +0200 (CEST), Peter Münster <[EMAIL PROTECTED]> wrote: > Hello, > thanks to Nikolai for the verb-c module! > > One (probably there will come more) question: > How could I adjust the width of the tabulator? Use the tab option (not specific to C): \usemodule[verb-c] \setupcolors[state=start] \starttext \startC[tab=2] if (i == 0) { a = b; } else { a = c; } \stopC \startC[tab=4] if (i == 0) { a = b; } else { a = c; } \stopC \startTEX[tab=8] \startC[tab=4] if (i == 0) { a = b; } else { a = c; } \stopC \stopTEX \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Table width trouble
On Sun, 23 Apr 2006 18:28:20 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >> Hello, >> >> I come back with that damn table test case. With release 2006.04.22: >> [...] >> >> > \long\def\dohandleTBLcellA#1#2[#3]#4% Thanks, it does it. Another torture case: when column widths are partially defined, it can give a weird result (here the last column has almost disppeared). Since it's a limit case, I don't know if it's worth being fixed. \bTABLE[frame=on] \setupTABLE[c][2][width=3em] \setupTABLE[c][3][width=3em] \bTR \bTD[nc=2] A \eTD\bTD x \eTD \bTD[nc=2] B \eTD \eTR \bTR \bTD X \eTD \bTD[nc=3] C \eTD \bTD x \eTD \eTR \bTR \bTD[nc=2] D \eTD \bTD x \eTD \bTD[nc=2] E \eTD \eTR \eTABLE Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Putting things over a figure
Hello, I need a mechanism with which I can put several things (text, image) at a precise position over a figure. The position is expressed in percentage (x,y) of the figure dimensions. The lower-left corner is (0,0). I did the following that works for my own needs, but maybe a higher level interface (layer?) could do the same. Any comment or improvement is welcome. \newdimen\overfigwd \newdimen\overfight % Put the figure and define the x/y percentage factor for the calspairs. \def\startoverfig {\dodoubleempty\dostartoverfig} \def\dostartoverfig[#1][#2]% {\bgroup \setbox\scratchbox\hbox{\externalfigure[#1][#2]}% \overfigwd=\wd\scratchbox \overfight=\ht\scratchbox \setuppositioning[unit=pt, xfactor=\withoutpt\the\dimexpr(\overfigwd/100), yfactor=\withoutpt\the\dimexpr(\overfight/100)]% \startpositioning \position(0,0){\box\scratchbox}} \def\stopoverfig {\stoppositioning\egroup} % Put (centered) at the position (x%,y%) on the figure. % The lower-left corner is (0,0) \def\calspair(#1,#2)#3% {\setbox0\hbox{#3}% \position[xoffset=\dimexpr(-\wd0/2), yoffset=\dimexpr(-\ht0/2)](#1,{\numexpr(100-#2)}){#3}} %% \setupcolors[state=start] \starttext \startoverfig[duck-small] \calspair(0,0){A} \calspair(100,100){B} \stopoverfig \startoverfig[duck-small][width=4cm,frame=on] \calspair(0,0){A} \calspair(100,100){B} \calspair(50,50){\framed[background=color,backgroundcolor=green]{Hello}} \stopoverfig \startoverfig[unknown] \calspair(30,0){A} \calspair(100,100){B} \stopoverfig \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Table width trouble
Hello, I come back with that damn table test case. With release 2006.04.22: - it works fine when the column width is passed as table option, - it's wrong when the width is passed via a column setup only, - it works ok when both table and column option are passed, and it's the column option that is used (which is the expected behaviour). - it's ok when no width specified at all. \starttext \startbuffer \bTR \bTD[nc=2] A \eTD\bTD x \eTD \bTD[nc=2] B \eTD \eTR \bTR \bTD X \eTD \bTD[nc=3] C \eTD \bTD x \eTD \eTR \bTR \bTD[nc=2] D \eTD \bTD x \eTD \bTD[nc=2] E \eTD \eTR \stopbuffer % ok \bTABLE[frame=on,width=3em] \getbuffer \eTABLE % nok, messy table \bTABLE[frame=on] \setupTABLE[c][each][width=3em] \getbuffer \eTABLE % ok, width=3em for each column \bTABLE[frame=on,width=0.1pt] \setupTABLE[c][each][width=3em] \getbuffer \eTABLE % ok \bTABLE[frame=on] \getbuffer \eTABLE \stoptext Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] Document Structuring
On Sat, 22 Apr 2006 12:16:10 +0200, Hans Hagen <[EMAIL PROTECTED]> wrote: > nico wrote: >>> nico wrote: >>>> >>>> \setuphead[part][conversion=Romannumerals] >>>> [...] >> Ok, but then >> >> \definehead[xx][chapter] >> >> \setupsection[\sectionofhead{chapter}][conversion=Romannumerals] >> \setupsection[\sectionofhead{xx}][conversion=Character] >> >> will put Character conversion for both chapter and xx heading. That's >> why >> i thought it could be interesting to have the conversion option also for >> setuphead, to limit the conversion to one heading. >> >> btw, it seems strange to have so many setuphead command options >> (textcommand, numbercommand, deepnumbercommand) to format completely the >> head rendering, and not the ability to change only the head number >> conversion without changing the whole global section level. >> > it can be done at the sectionblock level (see chinese) Hm, I've missed something. I see nothing about sectionblock in chinese, but at page 10 there is: \setuphead [section] [conversion=chinese] \setuphead [chapter] [conversion=] \setuphead [section] [conversion=numbers] Regards, BG ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context