Re: [NTG-context] Module `database' and UTF8?
Hello, you seem to be the first one (beside me and Taco) to complain about that bug, so perhaps Hans will have one reason more to try to fix it now (or perhaps to port it to lua, but then you'll have to wait for some time). My observations are (were - I'm currently not behind a ConTeXt machine) as follows: - 8-bit encodings seem to work OK (I had to convert a few files to cp1250 just because of that bug, but then it worked OK) - there are two completely different approaches - one imitates pere csv (Taco's) and one parses anything "TeX-ish" and also obeys TeX commands (Hans's). - Taco's approach has been fixed (utf-8 worked ok after a patch), so if you don't need TeX commands inside your tables, set "quotechar" to whatever, which will trigger Taco's mode - Hans's approach has a bug in utf-8 handling. But the problem only appears if the very first character in the cell is something non-ascii So in the case of březen duben květen červen it's probably only the last word the one which is causing problems A temporary solution might be to define quotechar (which is probably what you have already tried) or to wait for Hans to fix it. I find the module really useful, but I don't understand a bit in that file (even Taco addmited that it was the "worst-readable" macro he has ever wrote ;) I assume that you've seen the MyWay about it (http://wiki.contextgarden.net/My_Way) - feel free to post any comments about its unreadability ;). Mojca On 1/20/07, Michal Kvasnicka wrote: > Good evening. > > I apologize that I bother you now so much with my own problems but I > have to rewrite some of my macros right now for some reason. > > I found there is a great `database' module. I tried it with ConTeXt > version 2007.01.12 15:56, perl TeXExec 5.4.3, and pdfetex 1.40.1 under > SuSE Linux 10.1. I use input encoding regime utf8, and fonts in ec-lm > encoding. I set it this way: > \defineseparatedlist[CSV] > [separator=tab,%{,}, %quotechar={"}, >before=\bTABLE, after=\eTABLE, >first=\bTR, last=\eTR, >left=\bTD, right=\eTD] > And call it with \processseparatedfile[CSV][file.csv]. > > It works well with words without accents. If there is an accented letter > in the file.csv, it failes with this error message: > ! Argument of \utftwouniglph has an extra }. > > \par > >} > \dodoprocessseplist #1#2->\edef \!!stringa {#1} > \ifx [EMAIL PROTECTED] > \!!stringa ... > PŘÍJMY leden únor > březen duben květen červen > červenecsrpe... > > \doprocessseplist ...elax ->\dodoprocessseplist #1 > \relax \relax > \relax \end > \doprocessseparatedfileline ...plist \line \relax > \else \expanded > {\processq... > ... > > Can you help me to make it work? > > Many thanks. Yours > Michal Kvasnicka ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Are before=command parameters expanded?
I noticed some strange behavior which resulted from the fact that the before value is expanded in \setupfootnotes. For example, the following test case will break if \noexpand is removed: \setupfootnotes[before=\noexpand\undefined] \starttext \stoptext Is this the intended behavior or is this a bug? Thanks, --Mike Bird ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] pdfetex 1.40.1 + ghosscript problem? More findings
On 1/20/07, Michal Kvasnicka <[EMAIL PROTECTED]> wrote: > Good evening. > > I found some more puzzling things. I write them here fore anybody who > may be interested. :-) > > I tried to typeset a document using two font families: TrueType Gentium > by SIL, and Adobe OpenType Myriad. First I converted Myriad to Type1 > using fontforge, then I prepared metrics for all fonts with TeXFont > using ec-lm encoding. I found this: > > (1) Any ConTeXt document produced by pdfetex 1.40.1 (even this one: > \setupoutput[pdf] > \starttext > \input tufte > \stoptext > makes my GhostScript (gs Ghostscript 8.15.3 under SuSE Linux 10.1) die > with this error: > Warning: An error occurred while reading an XREF table. > The file has been damaged. This may have been caused > by a problem while converting or transfering the file. > Ghostscript will attempt to recover the data. >ERROR: /undefined in /BXlevel > etc. There was a gs bug (#688787 /undefined in /BXlevel) for this error, but in that case the pdf file really was corrupt although the user said it worked with Adobe Reader. I tried your first test on Fedora Core 5 with TL2007 (test inst iso from 20070115) which also has a gs-8.15 version, and don't get an error. [EMAIL PROTECTED] TL2007]$ cat cont-try.tex \setupoutput[pdf] \starttext \input tufte \stoptext [EMAIL PROTECTED] TL2007]$ texmfstart texexec cont-try [...] This is pdfTeXk, Version 3.141592-1.40.1 (Web2C 7.5.6) \write18 enabled. %&-line parsing enabled. (/mnt/hdb/opt/tex/texlive/2005/texmf/web2c/natural.tcx) entering extended mode (./cont-try.tex ConTeXt ver: 2006.08.08 21:51 fmt: 2007.1.14 int: english mes: english [...] [EMAIL PROTECTED] TL2007]$ pdffonts cont-try.pdf name type emb sub uni object ID --- --- --- - ORKXYQ+LMRoman12-Regular Type 1 yes yes yes 5 0 [EMAIL PROTECTED] TL2007]$ pdfinfo cont-try.pdf Title: cont-try Subject: Keywords: Author: Creator:ConTeXt - 2006.08.08 21:51 Producer: pdfTeX-1.40.1 CreationDate: Sat Jan 20 15:29:21 2007 ModDate:20070120 Tagged: no Pages: 1 Encrypted: no Page size: 595.276 x 841.89 pts (A4) File size: 26205 bytes Optimized: no PDF version:1.5 -- George N. White III <[EMAIL PROTECTED]> Head of St. Margarets Bay, Nova Scotia ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Module `database' and UTF8?
Good evening. I apologize that I bother you now so much with my own problems but I have to rewrite some of my macros right now for some reason. I found there is a great `database' module. I tried it with ConTeXt version 2007.01.12 15:56, perl TeXExec 5.4.3, and pdfetex 1.40.1 under SuSE Linux 10.1. I use input encoding regime utf8, and fonts in ec-lm encoding. I set it this way: \defineseparatedlist[CSV] [separator=tab,%{,}, %quotechar={"}, before=\bTABLE, after=\eTABLE, first=\bTR, last=\eTR, left=\bTD, right=\eTD] And call it with \processseparatedfile[CSV][file.csv]. It works well with words without accents. If there is an accented letter in the file.csv, it failes with this error message: ! Argument of \utftwouniglph has an extra }. \par } \dodoprocessseplist #1#2->\edef \!!stringa {#1} \ifx [EMAIL PROTECTED] \!!stringa ... PŘÍJMY leden únor březen duben květen červen červenecsrpe... \doprocessseplist ...elax ->\dodoprocessseplist #1 \relax \relax \relax \end \doprocessseparatedfileline ...plist \line \relax \else \expanded {\processq... ... Can you help me to make it work? Many thanks. Yours Michal Kvasnicka ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] pdfetex 1.40.1 + ghosscript problem? More findings
Good evening. I found some more puzzling things. I write them here fore anybody who may be interested. :-) I tried to typeset a document using two font families: TrueType Gentium by SIL, and Adobe OpenType Myriad. First I converted Myriad to Type1 using fontforge, then I prepared metrics for all fonts with TeXFont using ec-lm encoding. I found this: (1) Any ConTeXt document produced by pdfetex 1.40.1 (even this one: \setupoutput[pdf] \starttext \input tufte \stoptext makes my GhostScript (gs Ghostscript 8.15.3 under SuSE Linux 10.1) die with this error: Warning: An error occurred while reading an XREF table. The file has been damaged. This may have been caused by a problem while converting or transfering the file. Ghostscript will attempt to recover the data. ERROR: /undefined in /BXlevel etc. However, if I make a ps-file out of it using AdobeReader, I can view/print it with my GhostScript. The newest Ghostscript (Ghostscript 8.54 (2006-05-17)) doesn't write this error message but the rest of problems (see below) is the same. (2) When I typeset my document only with the Gentium font, or only with the Myriad font, or with a combination of the Gentium and LatinModern, or the Gentium and TrueType version of Myriad (made fontforge), the outcome is the same as (1). (3) If I try to combine TrueType Gentium and Type1 Myriad, my GhostScript failes to view/print it properly: strange letters appear in the text. I've got no idea what's wrong. By the way, my input regime is now utf8. Do you thing this is problem of ConTeXt, or pdfetex, or GhostScript? Whom should I tell it? Yours Michal Kvasnicka P.S. I apologize to all of you who are bothered by this topic. ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
[NTG-context] Imposition struggles
Help! I need to get a book on paper... Using: ConTeXt ver: 2007.01.18 12:57 MKII fmt: 2007.1.19 int: english/english Problem: By means of veroffset and horoffset the arranged pages should be placed in the center of the sheet. However, depending on the number of pages, the last sheets get typeset wronlgy (shifted unexpectedly to the left). Please try the attached sample file. Willi % TEST imposition % Problems: % option "cutspace" in \setuplayout is not honored % option ver/horoffset do unexpected shifts of the pages on the sheet % % By means of ver/horoffset the pages should be put centered on the sheet, in order % to be able to fold and cut the sheets. % Context file % filename: imposition-test.tex % Willi Egger % 20-01-2007 \mainlanguage[nl] \usetypescript[palatino][texnansi] \setupbodyfont[palatino, rm, 11pt] % Data for the setup of the layout % Relation between height and width of the PAGE 3 : 2 % Kanon 12 % Paper height (A - D) 200 mm % Paper length (A - B) 267 mm % Inner margin 11 mm % Top margin 17 mm % Outer margin 22 mm % Lower margin 33 mm % Height typesetting area 150 mm % Width typesetting area 100 mm \definepapersize[Test][height=200mm, width=137.5mm] %incl. 4 mm bindingcorection \setuppapersize[Test][A4,landscape] \setuplayout [% % cutspace=5mm, veroffset=5mm, horoffset=-11mm, topspace=17mm, backspace=15mm, %incl. 4 mm bindingcorrection leftmargin=10mm, margindistance=1mm, width=100mm, header=0pt, headerdistance=0pt, footer=1.5\bodyfontsize, footerdistance= 3\bodyfontsize, height=167mm, marking=on] \setuppagenumbering[location={footer,right},alternative=doublesided] \setuparranging[2*2*4] \setupitemgroup[itemize] [1] [symbol=2, before={\blank[small]}, inbetween={\blank[small]}, after={\blank[small]}] \starttext % \dorecurse {30}{% This works as expected! \dorecurse {35}{% \subject{A text by Ward} \input ward \subject{A text by Louis Couperus} Overglanzende mooi was Emeralda, schitterend schoon als geen vrouw in het rijk, geen prinses in andere rijken. Zij was heel groot en vorstelijk van gestalte; zij liep heel recht en fier en trotsch; zij wàs heel trotsch, want na den dood van den koning zoû zij heerschen op den troon van het Rijk van het Verleden. IJverzuchtig op al de macht, die haar deel zoû zijn, wees zij af alle de prinsen, die dongen om hare hand. Zij sprak nooit anders dan om te bevelen, en alleen voor haar vader boog zij het hoofd. Zij droeg altijd zwaar brokaat, zilver- of goud-, en bezaaid met gesteente, en lange mantels van ruischend sindaal met breed hermelijn omzoomd; een diadeem van de eêlste juweelen flonkerde steeds in haar rossiggoud haar, en ook haar oogen waren juweel: twee prachtige groene smaragden, waarin een zwarte karbonkel was de pupil; en men fluisterde geheimzinnig, dat haar hart was geslepen uit én enkelen reuzerobijn \unknown \startitemize \item First item \item Second item \item Third item \stopitemize} \stoptext ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
Re: [NTG-context] setup linecorrection
David Arnold wrote: > All, > > How do you set up: > > \startlinecorrection[blank] >\midaligned{\getbuffer[table]} > \stoplinecorrection > > so ensuing lines are not indented? There is not actual support for that, but this should work: \let\MYstoplinecorrection\stoplinecorrection \def\stoplinecorrection{\MYstoplinecorrrection\noindentation} Best, Taco ___ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context