Re: [NTG-context] MetaFun: Confusion with `function()` and `xyscaled`

2011-10-22 Thread Hans Hagen

On 21-10-2011 22:53, Aditya Mahajan wrote:

Could someone please explain to me how `xyscaled` works in this case
please. I though `xyscaled (αcm, ζcm)` would set the object/path to a
width of α cm and a height of ζ cm.


IIRC, xysized does that. (I am usually confused between ..sized and
..scaled, but one of them scales to the given dimensions).


scaled is just multiplication so x scaled 1cm is x * 1 * cm which can be 
pretty large


Hans


-
  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
___

Re: [NTG-context] accessibility of PDF (inter word space

2011-10-22 Thread Hans Hagen

On 21-10-2011 12:44, Stefan Goßrau wrote:

Hello,

I am very new in Context and have my first Problems. I read a lot, but can't 
find the solution. I try to produce accessible PDF. One Point is, that they 
have to be reflowed in a PDF-Viewer. But if I reflow my documents, there are no 
interwordspaces. I know that there is no space-character in Tex. I found an 
work-around for pdftex with an patch.

\pdfmapline{+dummy-spacedummy-space.pfb}
\pdfgeninterwordspace


\setupstructure[state=start]


-
  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
___


Re: [NTG-context] Standardmakeup

2011-10-22 Thread Wolfgang Schuster

Am 21.10.2011 um 21:01 schrieb Willi Egger:

 Thank you Wolfgang.
 
 I do not remember but there was a time where \godown would not work without 
 the strut. So I have mistaken this.

The makeup environments put the content in a \vbox and at the begin of a \vbox 
a vertical skip isn’t discarded as it would happen when you have it at the 
begin of a new page but in such a case you can use “\blank[force,…]”.

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

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


[NTG-context] xml and lua again

2011-10-22 Thread Thomas A. Schmitz

Hi all,

again, I'm playing a bit with processing my xml in lua. I want a simple 
interface for processing tables (I don't need all the power and 
complexity of cals tables and want to learn something in the process). 
And I thought that collecting the setups in lua might be the easiest 
way, but so far, I haven't been successful. Here's an example:


\startbuffer[test]
a
  nattable frame=on
tr
  td1/td
  td2/td
  td3/td
  td4/td
/tr
tr
  td5/td
  td6/td
  td7/td
  td8/td
/tr
  /nattable
/a
\stopbuffer

\startxmlsetups xml:testsetups
\xmlsetsetup{main}{a|nattable|tr|td|}{xml:*}
\stopxmlsetups

\xmlregistersetup{xml:testsetups}

\startxmlsetups xml:a
\xmlflush{#1}
\stopxmlsetups

\startxmlsetups xml:nattable
\startluacode
  framestate = lxml.att(#1, frame)
  context(framestate)
  context(true)
  context.placefigure( { here }, none , function()
context.setupTABLE( { frame=on } )
context.bTABLE()
 context.xmlflush(#1)
context.eTABLE()
  end)
\stopluacode
\stopxmlsetups

\startxmlsetups xml:tr
\startluacode
  context.bTR()
context.xmlflush(#1)
  context.eTR()
\stopluacode
\stopxmlsetups

\startxmlsetups xml:td
\startluacode
  context.bTD()
context.xmlflush(#1)
  context.eTD()
\stopluacode
\stopxmlsetups

\starttext
\xmlprocessbuffer{main}{test}{}
\stoptext

question: I have the value on in the lua variable framestate. But 
how can I pass this on to the line

context.setupTABLE( { frame=on } )?
I tried something like
context.setupTABLE( { frame= .. framestate } )
but that doesn't work. Any suggestions?

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

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


[NTG-context] installing mkiv

2011-10-22 Thread Wolfgang Werners-Lucchini
Hallo,

I tried to install a mkiv-only context with:

first-setup --context=luatex

but there is no texmf-context folder.
What I am doing wrong?

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

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


Re: [NTG-context] installing mkiv

2011-10-22 Thread Wolfgang Schuster

Am 22.10.2011 um 19:59 schrieb Wolfgang Werners-Lucchini:

 Hallo,
 
 I tried to install a mkiv-only context with:
 
 first-setup --context=luatex
 
 but there is no texmf-context folder.
 What I am doing wrong?

It’s “first-setup.sh --engine=luatex”.

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

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


[NTG-context] Script to upload modules to context garden

2011-10-22 Thread Aditya Mahajan

Hi all,

I finally got tired of manually uploading new versions of modules to 
context garden. So, here is a ruby script that automates the task:


https://github.com/adityam/contextgarden-update/blob/master/update

This uses `mechanize` library for HTML scrapping and `highline` library 
for user interaction. To use the script, simply run


update [modulename]

The script will prompt you for username and password, then display a list 
of all the modules that you own, and you can select a module to update. 
Then, the script asks for a new version number and filename for the zip 
file and then uploads the module.


If the optional modulename argument is provided, then that module is 
automatically selected for update.


I don't try to parse the returned page, but simply dump it to the output.

Hopefully, someone else might find this useful.

Aditya
___
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
___