Dear all,

First the good news: I have succeeded in typesetting a table!

I first changed all tag names from <table, <entry, <row to <cals:table, <cals:entry, <cals:row, etc. Then the table is read in.

However, the table setup cannot be manipulated by means of the directives, because - according to the log file - the directives inside the cdx-file are not found (lxml: no directives found in 'x-cals-test.cdx').

Without the directives, the cals table are typeset according to a rough standard (framed). I typeset them in a separate document (pdf), which I insert as a pdf graphic (mediaobject) file in my main document. This works to some extent for short tables, but not for tables that cover more than one page. This procedure is also cumbersome, for some font specifications etc. have to be transferred to the tex file, and if you change one file, you have to change the other as wel. I am now thinking to typeset them with latex instead.

Since one of the main problems seems to be that the cdx file is loaded, but that the directives are not found, I tried to solve this problem by putting the directives in my docbook xml file, but that did not work either. (I also tried a number of other things.)

Can anyone give me a straight minimal example of what to write in my environment file or in my docbook file in order to typeset a text that contains the adapted cals tables? Which xmlsetsetup do I need?

I have read Hans' brief explanation of the directives (http://www.ntg.nl/maps/37/06.pdf), but well, I am not a programmer, I need a more straightforward example in order to understand the logics.

Or is it too early for these wishes? Perhaps should we accept that, in spite of everything, for the time being docbook files that contain cals tables simply cannot be typeset with ConTeXt?

Regards,

Robert

P.S. I use a minimal installation on Mac OS X 10.6.


Op 11 mrt 2011, om 09:35 heeft R. Ermers het volgende geschreven:

Dear contexers,

I get the impression that cals tables need to be processed separately from the main docbook file.
Instead of <table> and <tbody>, etc. the tags are changed into <cals:table>, <cals:tbody>, etc.

I first tried to process the file x-cals-test.tex pointed to by Hans.

This file loads two other files
\starttext
\xmlloaddirectives{x-cals-test.cdx}
\xmlprocess{main}{x-cals-test.xml}{}
\stoptext

However, the file x-cals-test.xml is not valid.

Therefore I took one of the simple cals tables from within that file, making sure it contains one of the cdx attributes (cdx="vertical") and saved it in x-cals-test2.xml. My xml software says that the file is valid, and it opens normally.

The file are processed now, but the table is not typeset.
Instead there is an error message printed in the pdf file: invalid xml file - parsed text.

The log file says: lxml            : no directives found in 'x-cals-test.cdx' (more log information further)

It seems that the directives are not processed.

<x-cals-test2.xml>


Regards,

Robert




systems         : begin file cals-test.tex at line 50
lxml            : no directives found in 'x-cals-test.cdx'
systems         : end file cals-test.tex at line 53
 )
mkiv lua stats : used config file          - /prog2/context/tex/texmf/web2c/texmfcnf.lua
mkiv lua stats : used cache path           - /prog2/context/tex/texmf-cache/luatex-cache/context/b37116f3b39a5afbaa249111be7bfbba
mkiv lua stats : input load time           - 0.008 seconds
mkiv lua stats : stored bytecode data      - 261 modules, 56 tables, 317 chunks
mkiv lua stats : loaded tex modules        - 1 requested, 1 found (*-cals), 0 missing
mkiv lua stats : cleaned up reserved nodes - 30 nodes, 9 lists of 411
mkiv lua stats : node memory usage         - 18 glue_spec
mkiv lua stats : node list callback tasks  - 6 unique task lists, 1 instances (re)created, 397 calls
mkiv lua stats : used backend              - pdf (backend for directly generating pdf output)
mkiv lua stats : result saved in file      - cals-test.pdf
mkiv lua stats : fonts load time           - 0.197 seconds 
mkiv lua stats : luatex banner             - this is luatex, version beta-0.65.0-2010121316
mkiv lua stats : control sequences         - 29719 of 165536
mkiv lua stats : current memory usage      - 41 MB (ctx: 42 MB)




Op 9 mrt 2011, om 14:30 heeft Hans Hagen het volgende geschreven:

On 8-3-2011 9:00, R. Ermers wrote:
Dear ConTeXers,

I still have not been able to find out how to proceed with my docbook xml document, which contains a number of cals tables.
The cals module is loaded by means of \usemodule[cals].

How to proceed from here?

Any clue is appreciated!

x-cals-test.*

in the test suite

-----------------------------------------------------------------
                                         Hans Hagen | PRAGMA ADE
             Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
                                            | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________