Re: [NTG-context] \copypages[][n=...] not working

2012-10-28 Thread Procházka Lukáš
Hello Hans, thanks for the patch; I guess it will be added to the next beta - ? Best regards, Lukas On Sun, 28 Oct 2012 11:34:41 +0100, Hans Hagen pra...@wxs.nl wrote: \def\page_selectors_copy[#filename][#settings][#figuresettings]% {\bgroup \getfiguredimensions[#filename]%

Re: [NTG-context] using variable for subscript in math+lua

2012-10-25 Thread Procházka Lukáš
On Thu, 25 Oct 2012 20:02:22 +0200, Otared Kavian ota...@gmail.com wrote: Hi Philipp, Thanks to you, Dalyoung and Hans for the nice example using luacode. I was wonedring how would you modify your code in order to be able to change the name of the matrix if necessary. For instance, how to

Re: [NTG-context] Lua in Ctx: require() fails?

2012-10-24 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, When I make e:\tmp\whatever.lua (current path) e:\tmp\whatever\something.lua And run \starttext \enabletrackers[resolvers.libraries] \startluacode print(LUAINPUTS,os.getenv(LUAINPUTS)) require(whatever) ; require(something) ; \stopluacode

Re: [NTG-context] TABLE: header with a thick bottom line

2012-10-23 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Mon, 22 Oct 2012 17:45:21 +0200, Marco Patzer home...@lavabit.com wrote: http://wiki.contextgarden.net/TABLE#Rules_with_different_thickness ... I knew this snippet; unfortunately, there were some bindings or relationships that I didn't understand fully. Marco Anyway, after some

[NTG-context] \copypages[][n=...] not working

2012-10-23 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, I've just updated Ctx: ConTeXt ver: 2012.10.22 23:51 MKIV fmt: 2012.10.23 int: english/english - it seems \copypages ignores the 'n' specification: \starttext \copypages[t2.pdf][n=1] \stoptext - both t2.pdf pages are inserted. Any command option changed? Fix needed?

Re: [NTG-context] Lua in Ctx: require() fails?

2012-10-23 Thread Procházka Lukáš Ing . - Pontex s . r . o .
...@wxs.nl wrote: On 8-10-2012 15:57, Procházka Lukáš Ing. - Pontex s. r. o. wrote: The intention is Ctx to find and load its original texmfcnf.lua and then to load my texmfcnf.lua which would modify only some elements (namely: the LUAINPUTS member). texmf-local\web2c I'd like

Re: [NTG-context] Lua in Ctx: require() fails?

2012-10-23 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Tue, 23 Oct 2012 16:13:31 +0200, Hans Hagen pra...@wxs.nl wrote: On 23-10-2012 16:14, Procházka Lukáš Ing. - Pontex s. r. o. wrote: Hello, my trick with LUAINPUTS system variable stopped working after the today's Ctx update. afaik nothing changed; best run with \enabletrackers

Re: [NTG-context] Lua in Ctx: require() fails?

2012-10-23 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Tue, 23 Oct 2012 16:53:01 +0200, Hans Hagen pra...@wxs.nl wrote: On 23-10-2012 16:37, Procházka Lukáš Ing. - Pontex s. r. o. wrote: resolverslibraries ! checking for Test.lua using lua path d:/Lukas/Lua/?.lua in the output log but d:\Lukas\Lua\Test.lua is not found here

[NTG-context] Color red:3

2012-10-22 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, there is a color red:3 noticed at http://wiki.contextgarden.net/Colors. However, the following code doesn't work with color red:3 specification: \starttext \showcolor[rgb] \color[red]{AAA} \color[red:3]{AAA} \stoptext So, how it the matter with using red:3 correctly?

Re: [NTG-context] Color red:3

2012-10-22 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Mon, 22 Oct 2012 11:11:08 +0200, luigi scarso luigi.sca...@gmail.com wrote: On Mon, Oct 22, 2012 at 11:10 AM, Procházka Lukáš Ing. - Pontex s. r. o. l...@pontex.cz wrote: Hello, there is a color red:3 noticed at http://wiki.contextgarden.net/**Colorshttp://wiki.contextgarden.net/Colors

Re: [NTG-context] Color red:3

2012-10-22 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Ah ok , it was an image. The text says You find lists of predefined colors in the files colo-xxx.tex,.. but colo*tex it's an old file -- it should be colo-rgb.mkii , ie pdftex So %%test.mkii \setupcolors[state=start] \starttext \showcolor[rgb] \color[red]{AAA} \color[red:3]{AAA} \stoptext

Re: [NTG-context] trimwhite utility (was: Current ConTeXt wiki)

2012-10-22 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Mon, 22 Oct 2012 11:54:14 +0200, Mojca Miklavec mojca.miklavec.li...@gmail.com wrote: On Sun, Oct 21, 2012 at 10:14 PM, Procházka Lukáš wrote: Btw: I didn't use/test the utility so far, but I believe it really removes the content out of the trimming area; Do you mean that it removes

[NTG-context] TABLE: header with a thick bottom line

2012-10-22 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, how to achieve the table header to have a thick bottom line? Here are my two attempts: \starttext \bTABLE \setupTABLE[width=broad] \setupTABLE[header][align=middle] \bTABLEhead \bTR[bottomframe=on,rulethickness=2mm]\bTH a\eTH\bTH b\eTH\eTR \eTABLEhead

Re: [NTG-context] Color red:3

2012-10-22 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Mon, 22 Oct 2012 13:53:31 +0200, Philipp Gesang philipp.ges...@alumni.uni-heidelberg.de wrote: You don’t have to, these colors were upgraded to a superior way of being defined (colo-imp-dem.mkiv): · \setupcolor[dem]

Re: [NTG-context] TABLE: header with a thick bottom line

2012-10-22 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Mon, 22 Oct 2012 16:41:46 +0200, Aditya Mahajan adit...@umich.edu wrote: If you want only the bottom border (and no other border), ... No, I want all borders with default thickness but head bottom border thicker; this is most common look of my tables: +---+---+ | a | b | - header

Re: [NTG-context] trimwhite utility (was: Current ConTeXt wiki)

2012-10-21 Thread Procházka Lukáš
On Sat, 20 Oct 2012 13:49:05 +0200, Marco Patzer home...@lavabit.com wrote: 2012-10-20 Hans Hagen: Another option is to use pdftrimwhite, which is part of the minimals rather than pdfcrop. if needed I can make a mtx-trimwhite (lua instead of perl) +1 If you decide to rewrite

Re: [NTG-context] making tables with lua

2012-10-17 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, my experience is that the best way is to create the table first, then to call Lua function to typeset the table. You may choose whether the table will be typeset with 'tabulate' family functions or 'TABLE' family; I may recommend you the latter as it gives you much more control of the

Re: [NTG-context] making tables with lua

2012-10-17 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Wed, 17 Oct 2012 10:34:22 +0200, Jeong Dal hak...@me.com wrote: Dear Proch?zka Luk?? Ing and Hans, Thank you for the reply. It works fine. I modify your code to write a matrix and it also works too. \startformula \startluacode local NC, NR = context.NC, context.NR local t =

Re: [NTG-context] New module: pararef

2012-10-16 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, thanks for the job. Would you kindly add a Czech alternative: \setupparareftext[cz][braketOpen={(}] % Should be bracketOpen \setupparareftext[cz][braketClose={)}] % Should be bracketClose \setupparareftext[cz][atpageLeft={ na stran\ecaron\ }] \setupparareftext[cz][atpageRight={}]

Re: [NTG-context] Lua in Ctx: require() fails? (solved)

2012-10-08 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Fri, 05 Oct 2012 10:57:15 +0200, Hans Hagen pra...@wxs.nl wrote: On 5-10-2012 08:13, Procházka Lukáš Ing. - Pontex s. r. o. wrote: On Thu, 04 Oct 2012 13:32:42 +0200, Hans Hagen pra...@wxs.nl wrote: btw, you should adapt LUAINPUTS and not some other environment variable .. after all

Re: [NTG-context] Lua in Ctx: require() fails? (solved)

2012-10-05 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Thu, 04 Oct 2012 13:32:42 +0200, Hans Hagen pra...@wxs.nl wrote: btw, you should adapt LUAINPUTS and not some other environment variable .. after all, luatex is not native lua so you need to avoid conflicts in case you hav einstalled both ... I just added SET LUAINPUTS=%LUA_PATH% to the

[NTG-context] Math and units

2012-10-04 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, which is the most correct way to display units (here: kN) in math formula? \starttext \startformula a = 210 kN % kN is shown like a variable (here: like 'a'), which is unwanted \stopformula \startformula a = 210 \unit{kN} % No unit is displayed (?!) \stopformula

Re: [NTG-context] Math and units

2012-10-04 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Thu, 04 Oct 2012 11:32:20 +0200, Wolfgang Schuster wolfgang.schus...@gmail.com wrote: The units code doesn’t know how to deal with “N” but you can use the full name of the unit (can also be lowercase) or “n” which is also accepted. \starttext \startformula a = \unit{210 kilo Newton}

[NTG-context] Lua in Ctx: require() fails?

2012-10-04 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, I just renewed ConTeXt and new error when using require appears (it worked OK until the update): t-Req.mkiv \startluacode require Test-U \stopluacode \starttext A \stoptext mtx-context | run 1: luatex

Re: [NTG-context] Math and units

2012-10-04 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Thu, 04 Oct 2012 12:04:14 +0200, Alan BRASLAU alan.bras...@cea.fr wrote: \startformula a = 21407 g \stopformula :) The units code should certainly know how to deal with N... Alan - But g is shown like a variable (here: like 'a') - unwanted... I must substitute N - Newton... Lukas

Re: [NTG-context] Lua in Ctx: require() fails?

2012-10-04 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Thu, 04 Oct 2012 13:27:40 +0200, Hans Hagen pra...@wxs.nl wrote: On 4-10-2012 12:09, Procházka Lukáš Ing. - Pontex s. r. o. wrote: Personally - I've been using require file-name so far at many places and there was no problem with it. try with \enabletrackers[resolvers.libraries] - OK

[NTG-context] TABLE and row/column align settings

2012-10-03 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, I have a complicated TABLE, but I simplified it to the following example: \def\DoTable#1{% \bTABLE \setupTABLE[width=2cm] \setupTABLE[column][#1][align=flushright] % ... [1] \setupTABLE[row][1][align=middle] %

Re: [NTG-context] TABLE and row/column align settings

2012-10-03 Thread Procházka Lukáš Ing . - Pontex s . r . o .
...@gmail.com wrote: Am 03.10.2012 um 10:16 schrieb Procházka Lukáš Ing. - Pontex s. r. o. l...@pontex.cz: Hello, I have a complicated TABLE, but I simplified it to the following example: \def\DoTable#1{% \bTABLE \setupTABLE[width=2cm] \setupTABLE[column][#1][align=flushright

Re: [NTG-context] TABLE and row/column align settings

2012-10-03 Thread Procházka Lukáš Ing . - Pontex s . r . o .
The \setupTABLE calls do only store the settings but the values are used later when each cell is formatted and at this step row settings are processed before column settings BTW: Wouldn't be more flexible if the (stored) settings were processed in the order they have been defined? but when

[NTG-context] Some align observations

2012-10-02 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, I'm just curious: I tried to apply align specification to \b/e-TABLE, inframed, \start/stop-alignment and \start/stop-tabulate: \setupbodyfont[11pt] \starttext \bTABLE \setupTABLE[width=4cm,align=middle] \setupTABLE[column][1][align=left]

Re: [NTG-context] Full page figure

2012-09-25 Thread Procházka Lukáš Ing . - Pontex s . r . o .
... Maybe you should resize the page layout to full page with \setuplayout[page]. Lukas On Tue, 25 Sep 2012 08:37:05 +0200, Mikoláš Štrajt stra...@seznam.cz wrote: Hello everybody in list. I have drawn title page for my book on paper, later scanned it. And now I want to add it to my book

[NTG-context] No entry in the list of figures? (now without .pdf)

2012-09-25 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, suppose the following example: \starttext \startappendices \placelistoffigures % OK \placefigure[place]{Caption}{\externalfigure[cow][width=.25\textwidth]} \chapter{Foto} % Try to comment this! \placelistoffigures % No entry

[NTG-context] Space after caption of a float

2012-09-25 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, is there a built-in parameter for \setupcaptions which would affect the space after the caption? Or any other way? - Images here seem to me too close to each other; and I'm not able to add some extra space after the caption to get a bit bigger gap to the next object (image, text,

Re: [NTG-context] Space after caption of a float

2012-09-25 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Tue, 25 Sep 2012 10:42:30 +0200, Marco Patzer home...@lavabit.com wrote: 2012-09-25 Procházka Lukáš Ing. - Pontex s. r. o. l...@pontex.cz: Hi Lukáš, is there a built-in parameter for \setupcaptions which would affect the space after the caption? \setupcaptions [figure] [spaceafter

Re: [NTG-context] No entry in the list of figures? (now without .pdf)

2012-09-25 Thread Procházka Lukáš Ing . - Pontex s . r . o .
I recently encountered a similar problem with a table of contents [1]. I believe you need \placelistoffigures[criterium=text] for the second LOF since the default list criterium is local. Best regards, Matt [1] http://archive.contextgarden.net/message/20120919.215602.9a0f1f84.en.html ...

[NTG-context] Image/float infinite loop

2012-09-24 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, the following code goes into an infinite loop: \starttext \placefigure[place]{}{\externalfigure[cow]} \showexternalfigures[alternative=a] \stoptext I'm getting: mtx-context | run 1: luatex

[NTG-context] Long table centered on every page

2012-09-20 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello how to center a table over several pages? Suppose the following code: \def\TAB{% \bTABLE[split=repeat] \bTABLEhead \bTR \bTH head1 \eTH \eTR \eTABLEhead % \bTABLEbody \dorecurse{40}{% \bTR \bTD body \eTD \eTR

Re: [NTG-context] Long table centered on every page

2012-09-20 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, On Thu, 20 Sep 2012 15:51:23 +0200, Wolfgang Schuster wolfgang.schus...@gmail.com wrote: Use \placetable[force]{}{…} and omit the caption with the “none” keyword when you don’t want it. WOlfgang did you mean this? \def\TAB{% \bTABLE[split=repeat] \bTABLEhead \bTR

Re: [NTG-context] Long table centered on every page

2012-09-20 Thread Procházka Lukáš Ing . - Pontex s . r . o .
You need also the “split” keyword for the float. \starttext \startplacetable[location={force,split,none}] \bTABLE[split=repeat] \bTABLEhead \bTR \bTH head1 \eTH \eTR \eTABLEhead % \bTABLEbody \dorecurse{40}{% \bTR \bTD body \eTD \eTR

[NTG-context] CP 1250 component

2012-09-19 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, I have problem using CP 1250 and component/environment. Suppose having a simple example: t-M.mkiv - File of macro definitions %\enableregime[cp1250] \def\ccc{č} % A Czech letter with diacritics t-Env.mkiv - Environment file - just load macros %\enableregime[cp1250]

Re: [NTG-context] interesting link

2012-09-18 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, http://www.nongnu.org/gsl-shell/doc/ it looks useful... So far, I can't see any binding between GSL's 'graph.plot*()' and any output that would be accepted by ConTeXt; e.g. no .png nor MP code can be produced from GSL. It would be nice to have them as it seems many computations

Re: [NTG-context] Ctx: list of commands

2012-09-18 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, @Philipp: 1) is there a Ctx command/switch which would generate list of all current ConTeXt commands? E.g. Hi Lukáš, if you interpret “current Context commands” as “macros known to TeX”, you may try dumping the hashtable with these lines:

Re: [NTG-context] Ctx: list of commands

2012-09-18 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Tue, 18 Sep 2012 09:36:54 +0200, Peter Münster pmli...@free.fr wrote: - the command/macro \startluacode is missing (why?) and Are you sure? I can see it... ... You're right, I see it, too... Lukas ___ If

Re: [NTG-context] Ctx: list of commands

2012-09-18 Thread Procházka Lukáš Ing . - Pontex s . r . o .
http://pragma-ade.com/general/qrcs/setup-en.pdf … tex/texmf-context/tex/context/interface/cont-en.xml Thanks for the idea. Maybe both sources would be useful somehow but - they don't look up-to-date as e.g. the command \startluacode is not involved in any of both. Persisting question:

[NTG-context] Ctx: list of commands

2012-09-17 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, 1) is there a Ctx command/switch which would generate list of all current ConTeXt commands? E.g. context --list-of-commands Cmds.txt to produce Cmds.txt \startCAP \stopCAP \startCap \stopCap ... \writetoregister 2) The directory

Re: [NTG-context] Ctx: list of commands

2012-09-17 Thread Procházka Lukáš Ing . - Pontex s . r . o .
... Maybe I found something useful (initially I could not remember where and what to look for, but - ) c:\ConTeXt\tex\texmf-context\scripts\context\lua\mtx-interface.lua There is: ... local helpinfo = [[ ... --textpad generate textpad interface files --text

Re: [NTG-context] Setting options for every n-th row in natural TABLEs

2012-09-05 Thread Procházka Lukáš Ing . - Pontex s . r . o .
... Thanks Hans for implementation and Sietse for wikifying. BTW: Wouldn't be better to enclose ConText source on wiki into context mode=mkiv source=yes rather than texcode even if the source doesn't compile due to wiki-ConTeXt oldness? I believe one day the wiki-ConTeXt engine will be

[NTG-context] Component: \product, \project

2012-09-04 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, when looking at http://wiki.contextgarden.net/Project_structure - - why \product and/or \project specification is used in the COMPONENT in the example, or why is it supposed or even required to use in components? I imagined that component doesn't need to know in which project/product

Re: [NTG-context] Stretching width in natural TABLEs

2012-09-04 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, On Tue, 04 Sep 2012 05:02:01 +0200, Rogers, Michael K mrog...@emory.edu wrote: That's what I was afraid. It's just I had the same problem last week, and a deadline made me settle for the ad hoc approach. I was trying to solve the same situation several week ago. Finally, I measured

Re: [NTG-context] Component: \product, \project

2012-09-04 Thread Procházka Lukáš Ing . - Pontex s . r . o .
... Thanks for explanation, it's much clearer now. Best regards, Lukas On Tue, 04 Sep 2012 13:57:50 +0200, Sietse Brouwer sbbrou...@gmail.com wrote: Hello Lukáš, Usually, projects (collections of environment files) are applied at the product level. Sometimes, however, you want to apply one

Re: [NTG-context] Setting options for every n-th row in natural TABLEs

2012-09-03 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Natural tables have “odd” and “even” keywords for \setupTABLE but none in the way you like it. What I would do is to use a overlay in combination with metapost to create the background but there is no global register to access the current column/row of a cell, e.g. \currenttablecolumn (this

[NTG-context] Wiki example compilation failure

2012-09-03 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, maybe the known problem with the wiki and the current Ctx versions. The following code: \setuppapersize[A5] \starttext \definedelimitedtext[mydt] \setupdelimitedtext[mydt][left=\leftguillemot,right=\rightguillemot] \quotation{Clancy of the Overflow}, by Banjo Paterson \startmydt

Re: [NTG-context] Wiki example compilation failure

2012-09-03 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Mon, 03 Sep 2012 10:01:25 +0200, Sietse Brouwer sbbrou...@gmail.com wrote: http://wiki.contextgarden.net/Help:Context BTW: Which of the following specifications is correct [for wiki]: context mode=mkiv source=yes or context mode=mkiv source=yes? The former is used in the prelast example

Re: [NTG-context] Wiki example compilation failure

2012-09-03 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Mon, 03 Sep 2012 14:18:14 +0200, Sietse Brouwer sbbrou...@gmail.com wrote: context mode=mkiv source=yes or context mode=mkiv source=yes? Both work. Because both work, we have no way to force future edits to be XHTML compliant, so I don't think it is productive to try to enforce XHTML

Re: [NTG-context] MP TeX capacity exceeded

2012-09-02 Thread Procházka Lukáš
On Sat, 01 Sep 2012 21:47:21 +0200, Mojca Miklavec mojca.miklavec.li...@gmail.com wrote: On Sat, Sep 1, 2012 at 6:28 PM, Procházka Lukáš wrote: Hello, suppose having the following sample code: \starttext \startluacode context.startMPcode() for i = 1, -- 1000

Re: [NTG-context] Setting options for every n-th row in natural TABLEs

2012-09-02 Thread Procházka Lukáš
Hello, Lua solution: On Sun, 02 Sep 2012 17:59:55 +0200, Aditya Mahajan adit...@umich.edu wrote: Hi, On Edward Tufte's website, there is a discussion on zebra coloring in tables[1]. One of the suggestion is to add a horizontal rule after every third line or shade three lines with one

[NTG-context] MP TeX capacity exceeded

2012-09-01 Thread Procházka Lukáš
Hello, suppose having the following sample code: \starttext \startluacode context.startMPcode() for i = 1, -- 1000 -- OK 1e6 do context(draw (0,0) -- (5cm,5cm);) end context.stopMPcode() \stopluacode \stoptext

[NTG-context] Ctx ... Lua

2012-08-22 Thread Procházka Lukáš
Hello, sometimes in this mail discussion I'm encountering a Ctx/Lua command which has been unknown for me or I would use other (known) commands to do the job. So - would it be possible to explain - what's the difference/advantage btw \directlua and \ctxlua - what \ctxcommand{} does - what

Re: [NTG-context] test for (negative) number

2012-08-21 Thread Procházka Lukáš
On Mon, 20 Aug 2012 20:11:32 +0200, Sietse Brouwer sbbrou...@gmail.com wrote: Hi Peter, I recommend using the following handy little idiom: \ctxlua{commands.doifelse(-45 0)}{big}{small} % small It lets you do all sorts of things that are tricky in TeX: \ctxlua{ commands.doifelse(

Re: [NTG-context] test for (negative) number

2012-08-21 Thread Procházka Lukáš
... I also found another solution reposter before: \ctxlua{commands.testcase(condition)} { If true...} {If false} Note that both blocks (if-true and if-false) are mandatory. Considering Wolfgang's last answer, it would be better to write: \ctxcommand{testcase(condition)}

Re: [NTG-context] Throwing an error on missing image with \externalfigure

2012-08-17 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Fri, 17 Aug 2012 12:18:53 +0200, Peter Münster pmli...@free.fr wrote: On Fri, Aug 17 2012, Tobias Mueller wrote: And I wouldn't want to embarras myself by having a document missing images. So a failure in the build process would help me a lot. Instead of calling context directly, you can

[NTG-context] Footer text style

2012-08-16 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, I'm struggling a bit with setting font style for page footer: \setuppagenumbering [location={footer,middle}, ] \setupfooter[text][style=\bfc] \starttext \dorecurse{3}{\input knuth\page} \stoptext Why the footer is not bold and big ('\bfc')? - How to make it '\bfc'?

Re: [NTG-context] Footer text style

2012-08-16 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Thu, 16 Aug 2012 10:07:27 +0200, Hans Hagen pra...@wxs.nl wrote: On 16-8-2012 09:53, Procházka Lukáš Ing. - Pontex s. r. o. wrote: Hello, I'm struggling a bit with setting font style for page footer: \setuppagenumbering [location={footer,middle}, ] \setupfooter[text][style=\bfc

[NTG-context] Project automatic lookup for included directories

2012-08-15 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, I have a product file which includes an environment file placed two directories up. What is the default lookup of \environment? I thought it were at least one level up, but I'm not sure. My code so far is: \usepath[{.,..,../..}] \environment _e-Geom.mkiv % In fact in

Re: [NTG-context] \startcomponent, \startproduct... + automatic file name

2012-08-09 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Great, thank you. Lukas On Thu, 09 Aug 2012 11:27:08 +0200, Hans Hagen pra...@wxs.nl wrote: in the current beta you can say \startcomponent * Hans -- Ing. Lukáš Procházka [mailto:l...@pontex.cz] Pontex s. r. o. [mailto:pon...@pontex.cz] [http://www.pontex.cz] Bezová 1658 147 14

[NTG-context] \startcomponent, \startproduct... + automatic file name

2012-08-08 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, just a brief question - - is there a way how to obtain the current file name; to be possible to write e.g. C1.tex \startcomponent \thisfilename % Instead of \startcomponent C1 and P1.tex \startproduct \thisfilename % Instead of \startproduct P1 so that

Re: [NTG-context] A series of articles about text-editors for the MAPS

2012-08-08 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello Willi, is there a template for an article on My Favorite Text Editor? E.g. section names, setups for heads, paragraphs, page layouts... How large the article is supposed to be (e.g. in words of the text; and/or in pages, i.e. including images/screenshots)? What is the deadline for

Re: [NTG-context] setupbars

2012-07-10 Thread Procházka Lukáš Ing . - Pontex s . r . o .
... OK - On Tue, 10 Jul 2012 00:16:08 +0200, Hans Hagen pra...@wxs.nl wrote: actually it does accept more units but they were pretty small (needed an 1/u) anyhow, in the next beta we can do \starttext \setupbars[unit=mm,rulethickness=1] bar\startbar[underbar]foo\stopbar bar\blank

Re: [NTG-context] setupbars

2012-07-09 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Mon, 09 Jul 2012 09:26:51 +0200, Wolfgang Schuster schuster.wolfg...@gmail.com wrote: to allow “rulethickness=…pt”. +1 Lukas Wolfgang -- Ing. Lukáš Procházka [mailto:l...@pontex.cz] Pontex s. r. o. [mailto:pon...@pontex.cz] [http://www.pontex.cz] Bezová 1658 147 14 Praha 4

Re: [NTG-context] \box0 to Lua

2012-06-19 Thread Procházka Lukáš Ing . - Pontex s . r . o .
... Thanks Philipp and Hans for hints, I'll keep on trying. BTW: I'd never guess how Czech will become popular ;) Best regards, Lukas Na to budeš potřebovat node.hpack() (luatexref-t.pdf, s. 95). \starttext \startluacode context(typesetters.hpack(Na to budeš potřebovat

[NTG-context] \box0 to Lua

2012-06-18 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, (my apologies if this message is duplicated - our mail server was out-of-order some time) how to call \box0 and \hbox to3cm{abc} by Lua? \startluacode context[[\box0]] % OK but a nicer way preferred, so keep on trying - context.box(0) % Error context.box{0} % Error

[NTG-context] \box0 to Lua

2012-06-18 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, how to call \box0 and \hbox to3cm{abc} by Lua? \startluacode context[[\box0]] % OK but a nicer way preferred, so keep on trying - context.box(0) % Error context.box{0} % Error context.box0 % Error context.hbox({to = cm}, abc) % Error \stopluacode TIA. Best regards,

Re: [NTG-context] \box0 to Lua

2012-06-18 Thread Procházka Lukáš Ing . - Pontex s . r . o .
On Mon, 18 Jun 2012 16:56:56 +0200, Jaroslav Hajtmar hajt...@gyza.cz wrote: Ahoj... To bych ti rekl ... :-) tex.box[0].height ... To ale získáš jen výšku boxu, ne? Co když ten hbox chceš vysázet Luou na nějakou šířku? L. J. Dne 18.6.2012 16:53, Procházka Lukáš Ing. - Pontex s. r

Re: [NTG-context] \box0 to Lua

2012-06-18 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, sorry for impoliteness - last two messages should't have been addressed to the forum, but only to me and Jaroslav - thus in Czech. The question still lasts... Best regards, Lukas how to call \box0 and \hbox to3cm{abc} by Lua? \startluacode context[[\box0]] % OK but a nicer

[NTG-context] TABLE lines (frame)

2012-06-12 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, I'd need to create table with a head and a body, and with horizontal lines between rows disabled, excluding the head. Something like (ASCII art trial): +--+--+ | Head | Head | +--+--+ - Line here bellow the head is wanted (and can be thicker than the outer lines)...

Re: [NTG-context] TABLE lines (frame)

2012-06-12 Thread Procházka Lukáš Ing . - Pontex s . r . o .
... OK, this seems good. Actually, I need multi-line header, so two more questions: 1) Is there a way how to address rows (first, last) of the header part? Something like: \setupTABLE[header][r][1][topframe=on] \setupTABLE[header][r][last][bottomframe=on] - When I'd like to draw a line

Re: [NTG-context] Twittering

2012-06-11 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, IMHO - ConTeXt topics, questions and answers are usually to long to be shrunk to 140 characters. I think that the ConTeXt Point already exists - it's this forum and wiki (you'll see in the future that two sources are enough sometimes). The more sources (including twits), the more

Re: [NTG-context] Laundry symbols (now: altered picture)

2012-06-06 Thread Procházka Lukáš Ing . - Pontex s . r . o .
... OK, much clearer now. Thanks for explanation. Best regards, Lukas On Tue, 05 Jun 2012 18:06:28 +0200, Wolfgang Schuster schuster.wolfg...@googlemail.com wrote: Am 05.06.2012 um 17:13 schrieb Procházka Lukáš Ing. - Pontex s. r. o.: Thank you, Wolfgang. Two more questions, hope

[NTG-context] Laundry symbols (now: altered picture)

2012-06-05 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello ConTeXters, is there a way how to get laundry symbols into ConTeXt? - The image is copied from The Comprehensive LATEX Symbol List, Scott Pakin. TIA. Best regards, Lukas -- Ing. Lukáš Procházka [mailto:l...@pontex.cz] Pontex s. r. o. [mailto:pon...@pontex.cz]

Re: [NTG-context] Laundry symbols (now: altered picture)

2012-06-05 Thread Procházka Lukáš Ing . - Pontex s . r . o .
... Thanks both for your answers. My code so far is: \usesymbols[mvs] \starttext \startcolumns[n=2,rule=on] \showsymbolset[martinvogel 2] \stopcolumns \page \startcolumns[n=4,rule=on] \dorecurse{1024}{\recurselevel --\getglyph{marvosym}{\char\recurselevel\par}}

Re: [NTG-context] Laundry symbols (now: altered picture)

2012-06-05 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Thank you, Wolfgang. Two more questions, hope there'll be no more about this stuff. On Tue, 05 Jun 2012 17:01:28 +0200, Wolfgang Schuster schuster.wolfg...@googlemail.com wrote: \usesymbols[mvs] \starttext \symbol[martinvogel 2][ShortForty] \stoptext or \usesymbols[mvs]

[NTG-context] \processmarkdownfile gobbles all starting with % or \

2012-05-31 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, please see the example: \usemodule[markdown] \starttext \startmarkdown AAA -4 % BBB aaa \% bbb \stopmarkdown \processmarkdownfile{t-MD.mkiv} % = This file \stoptext When the t-MD.mkiv is processed by \processmarkdownfile, only AAA -4 appears from the line AAA

Re: [NTG-context] Argument to ConTeXt

2012-05-31 Thread Procházka Lukáš Ing . - Pontex s . r . o .
... OK, thanks for the patch. Lukas On Thu, 31 May 2012 10:24:52 +0200, Hans Hagen pra...@wxs.nl wrote: you can remove line 484 in mtx-context.lua -- jobname = file.removesuffix(jobname) -- Ing. Lukáš Procházka [mailto:l...@pontex.cz] Pontex s. r. o. [mailto:pon...@pontex.cz]

Re: [NTG-context] \processmarkdownfile gobbles all starting with % or \

2012-05-31 Thread Procházka Lukáš Ing . - Pontex s . r . o .
... Thanks Marco, this works much better. I found one fault - the code -4.0 % na +4.0 %. in the source is translated to -4.0 %na +4.0 %., so the space after the first is gobbled. But it is not so serious. Thanks anyway. Best regards, Lukas On Thu, 31 May 2012 14:14:11 +0200, Marco

Re: [NTG-context] \processmarkdownfile gobbles all starting with % or \

2012-05-31 Thread Procházka Lukáš Ing . - Pontex s . r . o .
... Thanks Aditya, here is also a sample attached. Best regards, Lukas On Thu, 31 May 2012 15:20:35 +0200, Aditya Mahajan adit...@umich.edu wrote: On Thu, 31 May 2012, Procházka Lukáš Ing. - Pontex s. r. o. wrote: ... Thanks Marco, this works much better. I found one fault - the code

[NTG-context] Argument to ConTeXt

2012-05-30 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, please see the following calling cases: 1) context.exe t6.mkiv --address=6 2) context.exe t6.2.mkiv --address=6 Content ot both .mkiv is identical - just to print the passed address value: \starttext A \directlua{print(@@@, document.arguments.address)} \stoptext The former

Re: [NTG-context] Problem calling system

2012-05-17 Thread Procházka Lukáš Ing . - Pontex s . r . o .
... Finally, I use the following to avoid ' in arguments and to keep to os.execute(): \bgroup \catcode`\%=11 \ctxlua{os.execute(([[echo lua -e print 'EXECUTE']]):gsub('(.-)', [[%1]]))} \egroup % Or: \startluacode os.execute(([[echo lua -e print 'EXECUTE']]):gsub('(.-)', [[%1]]))

Re: [NTG-context] Problem calling system

2012-05-15 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, I slightly modified the example - my code now is: \ctxlua{os.execute([[echo lua -e print 'WWW']])} \starttext A \stoptext So now I'm able to diagnose what exactly is passed to the command line. I'm getting: ... languageslanguage en is active lua -e print WWW

Re: [NTG-context] Problem calling system

2012-05-15 Thread Procházka Lukáš Ing . - Pontex s . r . o .
probably some os.execute parsing ... Do you mean Lua itself does the parsing and substitution? I guessed [lua]tex core... When I try to call on the command line: C:\Lukas\ConTeXt\TestDDvlua Lua 5.1.4 Copyright (C) 1994-2008 Lua.org, PUC-Rio os.execute([[lua -e print 'WWW']]) WWW

Re: [NTG-context] Problem calling system

2012-05-15 Thread Procházka Lukáš Ing . - Pontex s . r . o .
... I also tried: \write18{echo 'AAA'} \starttext A \stoptext Which gives: ... backend xmp using file 'c:/ConTeXt/tex/texmf-context/tex/context/base/lpdf-pdx.xml' AAA pagesflushing realpage 1, userpage 1 ... So it can be seen that ' changes to even in

[NTG-context] Problem calling system

2012-05-14 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, I'd need to call the OS, namely lua in it. I have the following code: \write18{lua -e require 'lfs'} \write18{lua -e require'lfs'} \starttext A \stoptext When calling directly from the command line lua -e require 'lfs' - there is no error. From within the Context code,

Re: [NTG-context] Problem calling system

2012-05-14 Thread Procházka Lukáš Ing . - Pontex s . r . o .
\ctxlua{os.execute(lua -e require 'lfs')} ... Gives: ... fontslatin modern fonts are not preloaded languageslanguage en is active ! LuaTeX error main ctx instance:1: attempt to call global 'e' (a nil value) stack traceback: main ctx instance:1: in main chunk.

Re: [NTG-context] Vertical alignment in nested itemizations

2012-05-10 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, - seems OK with my not-so-recent MkIV - see the attachment. Lukas On Thu, 10 May 2012 10:08:57 +0200, Hans Hagen pra...@wxs.nl wrote: It looks ok in mkii and mkiv ... can someone confirm the problem? Hans -- Ing. Lukáš Procházka [mailto:l...@pontex.cz] Pontex s. r. o.

Re: [NTG-context] Font for MetaPost graphics

2012-05-10 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, many thanks Marco for wikifying. On Tue, 08 May 2012 21:57:04 +0200, Marco net...@lavabit.com wrote: Thanks a lot Hans for implementing this. Wikified: http://wiki.contextgarden.net/Command/defineMPinstance http://wiki.contextgarden.net/Command/setupMPinstance Best wishes Marco

[NTG-context] Wiki - results differ?

2012-05-04 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, Wiki and a file processed on a local computer give different results - - please compare http://wiki.contextgarden.net/Command/doif...; and the example attached: \starttext \ctxlua{test = true} Test is \ctxlua{commands.testcase(test)}{True}{False}. \ctxlua{test = false}

[NTG-context] \inputif(file)exist(s)

2012-05-03 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, just a quick question - is there a command like \inputif(file)exist(s), which will \input a file if it exists, i.e. with no error if it doesn't? TIA. Lukas -- Ing. Lukáš Procházka [mailto:l...@pontex.cz] Pontex s. r. o. [mailto:pon...@pontex.cz] [http://www.pontex.cz] Bezová

Re: [NTG-context] \inputif(file)exist(s)

2012-05-03 Thread Procházka Lukáš Ing . - Pontex s . r . o .
... Great, thank you. Lukas On Thu, 03 May 2012 17:41:18 +0200, Aditya Mahajan adit...@umich.edu wrote: On Thu, 3 May 2012, Procházka Lukáš Ing. - Pontex s. r. o. wrote: Hello, just a quick question - is there a command like \inputif(file)exist(s), which will \input a file if it exists

[NTG-context] Background on the 1st page only, page numbering from the 2nd page

2012-05-02 Thread Procházka Lukáš Ing . - Pontex s . r . o .
Hello, how to specify the page background for the first page only and how to start page numbering from the second page? Here's my trial: \defineoverlay[Bkg][{\externalfigure[cow]}] \setupbackgrounds[paper][background=Bkg] %\setuppagenumbering[state=2] \starttext \dorecurse{5}{\input

Re: [NTG-context] Background on the 1st page only, page numbering from the 2nd page

2012-05-02 Thread Procházka Lukáš Ing . - Pontex s . r . o .
... One more question. Let's have three cases - some of them hide the page number on the first page, some of them don't. The question is - why: 1 - OK, no page number on page 1 \def\MyPageNumber#1{\doifelse{\pagenumber}{1}{}{\pagenumber}} % Testing \pagenumber

Re: [NTG-context] Background on the 1st page only, page numbering from the 2nd page

2012-05-02 Thread Procházka Lukáš Ing . - Pontex s . r . o .
wrote: On Wed, 2 May 2012 14:24:24 +0200 Wolfgang Schuster schuster.wolfg...@googlemail.com wrote: Am 02.05.2012 um 09:45 schrieb Procházka Lukáš Ing. - Pontex s. r. o.: how to specify the page background for the first page only and how to start page numbering from the second page

<    1   2   3   4   5   6   7   8   >