Re: [NTG-context] How to use MPgraphic with options?

2009-04-09 Thread Mikael Persson
I think this is one way:

\startuseMPgraphic{ARule}
 draw origin -- (\MPvar{mylength},0) ;
\stopuseMPgraphic

\def\ARule#1{%
\setupMPvariables[ARule][mylength=#1]
\useMPgraphic{ARule}
}

\starttext
Foo \ARule{5mm} bar \ARule{10mm}
\stoptext

Best regards, Mikael

On Thu, Apr 9, 2009 at 8:07 AM, Wei-Wei Guo wwgu...@gmail.com wrote:
 Dear all,

 I need to use many rules with different lengths. Is there any way to
 implement
 function like below:

  \startuniqueMPgraphic{ARule}{length}
  draw origin -- (\MPvar{length},0) ;
  \stopuniqueMPgraphic

  \uniqueMPgraphic[length=5mm]{ARule}

 The example cannot be run. I only use it to explain what I want.

 Any suggestion is appreciated.

 Best wishes,
 Wei-Wei
 ___
 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
 ___

___
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] hyphenation in latest

2009-04-09 Thread Thomas A. Schmitz


On Apr 9, 2009, at 12:00 AM, Hans Hagen wrote:


maybe somethign with the greek patterns then?

\starttext

\definedfont[cambria]

\language[agr] % try different ones
\the\normallanguage

\input tufte

\stoptext


I have looked at the Greek patterns, and there's nothing wrong with  
them; I also tried with older patterns from 2007 which I know worked a  
while ago - nothing, no hyphenation at all. Language like fr and de  
work, but I would need another example with a non-Latin script. Can  
anybody test with Russian or Ukrainian?


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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] hyphenation in latest

2009-04-09 Thread Vyatcheslav Yatskovsky
I can. Please, explain what have to be tested in Russian and Ukrainian, 
and what result are expected?


Vyatcheslav

maybe somethign with the greek patterns then?

  \starttext

  \definedfont[cambria]

  \language[agr] % try different ones
  \the\normallanguage

  \input tufte

  \stoptext
   


I have looked at the Greek patterns, and there's nothing wrong with
them; I also tried with older patterns from 2007 which I know worked a
while ago - nothing, no hyphenation at all. Language like fr and de
work, but I would need another example with a non-Latin script. Can
anybody test with Russian or Ukrainian?

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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] hyphenation in latest

2009-04-09 Thread Thomas A. Schmitz


On Apr 9, 2009, at 8:35 AM, Vyatcheslav Yatskovsky wrote:

I can. Please, explain what have to be tested in Russian and  
Ukrainian, and what result are expected?


Vyatcheslav


Great. Just run a simple test file like this

\usetypescriptfile[type-gentium] % or any other typescript that has  
Cyrillic

\usetypescript[gentium]
\setupbodyfont[gentium,12pt]

\starttext

{\language[agr] \the\normallanguage φιλοσοφία  
\hyphenatedword{φιλοσοφία}}


{\language[XXX] \the\normallanguage \hyphenatedword{YYY}}

\stoptext

where XXX is the language code for Russian (ru, I assume?) or  
Ukrainian (uk?), and YYY is a Russian/Ukrainian word long enough to  
allow hyphenation. The output should show you the word with the proper  
hyphenation (whereas here, there is no hyphenation in the Greek word.


Thanks!

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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] Weird interline spacing

2009-04-09 Thread Khaled Hosny
In the attached file, loading the font with \setupbodyfont gives
narrower interline spacing than with font (you have to comment out the
\setupbodyfont line to see this), I'm not sure if this is normal, but
the first case gives different interline spaces from line to line. I
tested it with two different fonts.

Regards,
 Khaled

-- 
 Khaled Hosny
 Arabic localiser and member of Arabeyes.org team
 Free font developer
\starttypescript [serif][arabic]
 \usetypescript  [serif][fallback]
 \definefontsynonym  [Serif][name:arabictypesetting] [features=arabic]
\stoptypescript

\starttypescript  [arabic]
  \definetypeface [arabic][rm] [serif] [arabic]  [default] 
\stoptypescript
 
\usetypescript[arabic]
\setupbodyfont[arabic]
%\font\ara=name:arabictypesetting*arabic at 10pt\ara

\startbuffer[testtext]
أيًا كانت طبيعة عملك فإن المحافظة على سلامة الحاسوب هي الخطوة الأولى على درب الافظة على الخصوصية. لذا فقبل أن تَشغَل بالك بكلمات السر و تأمين الاتصالات و المحو الآمن و غيرها من موضوعات، عليك التيقن من أن الحاسوب الذي تعمل عليه ليس عرضة لهجمات المخترقين أو موبوءا بالبرمجيات الخبيثة مثل الفيروسات و أحصنة طروادة و البرمجيات التجسسية. بغير هذا التيقن من سلامة النظام لا يمكن ضمان فعالية أو جدوى أي من الأساليب و الممارسات المقصود بها حماية الخصوصية و زيادة الأمان.

هذا الفصل يتناول كيفية استخدام أدوات برمجية مثل أڤاست و سپاي بوت و جدار النار كومودو لحماية الحاسوب من عدوى البرمجيات الخبيثة و من خروقات المخترقين. البرمجيات المشروحة في هذا الفصل تعمل على نظام التشغيل وِندوز، و هو بطبيعته الأكثر عرضة لمثل هذه التهديدات، إلا أن كل نظم التشغيل يمكن تأمينها بأساليب مشابهة.
\stopbuffer
\starttext
\textdir TRT\pardir TRT
\getbuffer[testtext]

\stoptext


signature.asc
Description: Digital signature
___
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] setup/startnarrower question

2009-04-09 Thread Wolfgang Schuster


Am 08.04.2009 um 16:52 schrieb frantisek holop:


hi there,

what would be the equivalent of the following

\startnarrower[2*left,0*right]
\stopnarrower

using

\setupnarrower ?


not possible


my problem is that \setupnarrower takes dimensions, while
\startnarrower takes...  i am not sure what actually...


it's a comma list


\startnarrower[..,...,..] ... \stopnarrower
...   n*left n*middle n*right

and why does e.g.

\setupnarrower[left=4em, right=0pt]

still have a right side margin


where is a right margin?

what you do with \setupnarrower is to set the width for the
left, right keys in \startnarrower

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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] new beta

2009-04-09 Thread Ulrike Fischer
Am Wed, 08 Apr 2009 21:43:01 +0200 schrieb Hans Hagen:


 It works partly: After I called luatools --generate mtxrun now finds
 also fonts in my various texmf-trees (and not only the one in the
 system folder), but mtxrun works only if I move first font-syn.lua
 in the folder of mtxrun. But this only a small nuisance. 

 hm, i'll have a look at it; i wonder why it fails since it has worked 
 for ages

 what does luatools font-syn.lua return ?

 Nothing if I remove the file from the folder. When the file is in
 the folder then I get the answer font-syn.lua: 

 I:\TeX-Roots\luatexmf\texmf\scripts\context\lualuatex --luaonly
 luatools.lua font-syn.lua
 font-syn.lua

 what does luatools --verbose return?
 
 luatools --verbose xxx
 
 should report the loaded databases

This reports:


I:\TeX-Roots\luatexmf\texmf\scripts\context\lualuatex --luaonly
luatools.lua -- verbose xxx
LuaTools | variable SELFAUTOLOC set to
I:/TeX-Roots/luatexmf/texmf/bin
LuaTools | variable SELFAUTODIR set to I:/TeX-Roots/luatexmf/texmf
LuaTools | variable SELFAUTOPARENT set to I:/TeX-Roots/luatexmf
LuaTools | variable TEXMFCNF set to
{$SELFAUTODIR,$SELFAUTOPARENT}{,{/share,}/te
xmf{-local,.local,}/web2c}
LuaTools | loading configuration for
I:/TeX-Roots/luatexmf/texmf/web2c from C:/D
OKUME~1/Ulle/LOKALE~1/Temp/luatex-cache/context/7f537eee11bb8927aceaff94d1daa001
/trees/62cf2e94005cc799da35acaa6d6d5848
LuaTools | locating list of I:/TeX-Roots/luatexmf/texmf

[... for all roots list are located]

LuaTools | loading files for I:/TeX-Roots/luatexmf/texmf from
C:/DOKUME~1/Ulle/L
OKALE~1/Temp/luatex-cache/context/7f537eee11bb8927aceaff94d1daa001/trees/9f4ba8a
35f231f48e68c2d0976d83a4b

[... loading files for all roots]


I looked in the lua-file for the luatexmf/texmf-root: It contains an
entry for font-syn.lua:

['font-syn.lua']='tex/context/base',

I also deleted all the luc-files to exclude the possibility that is
them which are corrupted, but I still don't get a result for the
file (or other files in my roots). I also moved the databases to a
folder without spaces (by setting TMP), but this didn't work either.
So I think that luatools is either not loading the databases or
doesn't use them correctly. 

-- 
Ulrike Fischer 

___
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] How to use MPgraphic with options?

2009-04-09 Thread Wei-Wei Guo

Thanks!

Best wishes,
Wei-Wei

Mikael Persson 写道:

I think this is one way:

\startuseMPgraphic{ARule}
 draw origin -- (\MPvar{mylength},0) ;
\stopuseMPgraphic

\def\ARule#1{%
\setupMPvariables[ARule][mylength=#1]
\useMPgraphic{ARule}
}

\starttext
Foo \ARule{5mm} bar \ARule{10mm}
\stoptext

Best regards, Mikael



___
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] hyphenation in latest

2009-04-09 Thread Hans Hagen

Thomas A. Schmitz wrote:


On Apr 9, 2009, at 12:00 AM, Hans Hagen wrote:


maybe somethign with the greek patterns then?

\starttext

\definedfont[cambria]

\language[agr] % try different ones
\the\normallanguage

\input tufte

\stoptext


I have looked at the Greek patterns, and there's nothing wrong with 
them; I also tried with older patterns from 2007 which I know worked a 
while ago - nothing, no hyphenation at all. Language like fr and de 
work, but I would need another example with a non-Latin script. Can 
anybody test with Russian or Ukrainian?


weird, as the catcodes look ok


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: 038 477 53 69 | fax: 038 477 53 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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Weird interline spacing

2009-04-09 Thread Hans Hagen

Khaled Hosny wrote:

In the attached file, loading the font with \setupbodyfont gives
narrower interline spacing than with font (you have to comment out the
\setupbodyfont line to see this), I'm not sure if this is normal, but
the first case gives different interline spaces from line to line. I
tested it with two different fonts.


\font does nothing with interlinespace at all

\setupbodyfont does set the interlinespace as defined by the bodyfont 
environment (2.8 ex by default with a 72:28 ht/dp ratio)



-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: 038 477 53 69 | fax: 038 477 53 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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] hyphenation in latest

2009-04-09 Thread Thomas A. Schmitz


On Apr 9, 2009, at 12:18 PM, Thomas A. Schmitz wrote:



On Apr 9, 2009, at 12:11 PM, Hans Hagen wrote:


weird, as the catcodes look ok



Hmm, I'll do some more tests later; I'll be offline until Sunday  
night. But it doesn't work in mkii either, so the bug probably is  
with the pattern file.


OK, just one more detail before I leave: I get proper hyphenation with  
luatex version 0.35.0 and ConTeXt version 2009.02.24 (had this older  
version still on my linux box). lang-agr.pat in this version and the  
most recent beta is identical. So it's not the pattern file itself  
which is at fault; in between, something must have changed in the way  
the patterns are loaded and used, either in luatex itself or in ConTeXt.


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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] new beta

2009-04-09 Thread Hans Hagen

Ulrike Fischer wrote:

Am Wed, 08 Apr 2009 21:43:01 +0200 schrieb Hans Hagen:



It works partly: After I called luatools --generate mtxrun now finds
also fonts in my various texmf-trees (and not only the one in the
system folder), but mtxrun works only if I move first font-syn.lua
in the folder of mtxrun. But this only a small nuisance. 


hm, i'll have a look at it; i wonder why it fails since it has worked 
for ages



what does luatools font-syn.lua return ?



Nothing if I remove the file from the folder. When the file is in
the folder then I get the answer font-syn.lua: 


I:\TeX-Roots\luatexmf\texmf\scripts\context\lualuatex --luaonly
luatools.lua font-syn.lua
font-syn.lua



what does luatools --verbose return?
 

luatools --verbose xxx
 

should report the loaded databases


This reports:


I:\TeX-Roots\luatexmf\texmf\scripts\context\lualuatex --luaonly
luatools.lua -- verbose xxx
LuaTools | variable SELFAUTOLOC set to
I:/TeX-Roots/luatexmf/texmf/bin
LuaTools | variable SELFAUTODIR set to I:/TeX-Roots/luatexmf/texmf
LuaTools | variable SELFAUTOPARENT set to I:/TeX-Roots/luatexmf
LuaTools | variable TEXMFCNF set to
{$SELFAUTODIR,$SELFAUTOPARENT}{,{/share,}/te
xmf{-local,.local,}/web2c}
LuaTools | loading configuration for
I:/TeX-Roots/luatexmf/texmf/web2c from C:/D
OKUME~1/Ulle/LOKALE~1/Temp/luatex-cache/context/7f537eee11bb8927aceaff94d1daa001
/trees/62cf2e94005cc799da35acaa6d6d5848
LuaTools | locating list of I:/TeX-Roots/luatexmf/texmf

[... for all roots list are located]

LuaTools | loading files for I:/TeX-Roots/luatexmf/texmf from
C:/DOKUME~1/Ulle/L
OKALE~1/Temp/luatex-cache/context/7f537eee11bb8927aceaff94d1daa001/trees/9f4ba8a
35f231f48e68c2d0976d83a4b

[... loading files for all roots]


I looked in the lua-file for the luatexmf/texmf-root: It contains an
entry for font-syn.lua:

['font-syn.lua']='tex/context/base',

I also deleted all the luc-files to exclude the possibility that is
them which are corrupted, but I still don't get a result for the
file (or other files in my roots). I also moved the databases to a
folder without spaces (by setting TMP), but this didn't work either.
So I think that luatools is either not loading the databases or
doesn't use them correctly. 


can you set TEXMFCACHE explicitly, say

set TEXMFCACHE=c:/temp

and then run luatools --generate again


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: 038 477 53 69 | fax: 038 477 53 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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Weird interline spacing

2009-04-09 Thread Wolfgang Schuster


Am 09.04.2009 um 13:00 schrieb Khaled Hosny:


On Thu, Apr 09, 2009 at 12:14:28PM +0200, Hans Hagen wrote:

Khaled Hosny wrote:

In the attached file, loading the font with \setupbodyfont gives
narrower interline spacing than with font (you have to comment out  
the
\setupbodyfont line to see this), I'm not sure if this is normal,  
but

the first case gives different interline spaces from line to line. I
tested it with two different fonts.


\font does nothing with interlinespace at all

\setupbodyfont does set the interlinespace as defined by the bodyfont
environment (2.8 ex by default with a 72:28 ht/dp ratio)


OK, however that was a side issue, my real problem is the variable
interline spacing, see the attached file; the first interline space is
considerably larger than the others, this seems to be due to the
diacritics on the second line. Shouldn't the interline space to be  
fixed

in all lines?


change the line distance, you could check it with \showgrid.

a distance of 4ex is enough, \setupinterlinespace[line=4ex]

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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] core-gen.tex

2009-04-09 Thread Wolfgang Schuster

Hi Hans,

there is a type in core-gen.tex

\setvalu...@av@\v!middle}{\secondofthreearguments}
  ^^
  medium

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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] hyphenation in latest

2009-04-09 Thread Thomas A. Schmitz


On Apr 9, 2009, at 12:11 PM, Hans Hagen wrote:


weird, as the catcodes look ok



Hmm, I'll do some more tests later; I'll be offline until Sunday  
night. But it doesn't work in mkii either, so the bug probably is with  
the pattern file.


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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] colored backgrounds in displayed math

2009-04-09 Thread Sanjoy Mahajan
In displayed math I was trying to highlight a piece of a formula using a
gray background.  After a few spacing failures with \framed, I
discovered \mframed in the core-rul.tex source file.  The comments there
say:

%D As usual, one can specify in what way the text should be
%D framed. One should be aware of the fact that, inorder to
%D preserve the proper spacing, the \type {offset} is set to
%D \type {overlay} and \type {frameoffset} is used used
%D instead.

But I couldn't get the following example of setting frameoffset to
enlarge the box; instead the gray box barely surrounds the x^2/2.  Is
the cause the \@@oioffset in line 1502 of core-rul.tex:

   [\c!frameoffset=\@@oioffset,\c!offset=\v!overlay,#2]

(I'm using ConTeXt - 2008.10.31 13:58, Mk II)

\setupcolors[state=start]

\def\graymath{\mframed[frame=off,
background=color,
backgroundcolor=gray,
frameoffset=5pt]}

\starttext

\startformula
\ln(1+x) = \graymath{x- \displaystyle{x^2\over2}} + \cdots
\stopformula

\stoptext
___
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] core-gen.tex

2009-04-09 Thread Hans Hagen

Wolfgang Schuster wrote:

Hi Hans,

there is a type in core-gen.tex

\setvalu...@av@\v!middle}{\secondofthreearguments}
  ^^
  medium


ok ... more efficient too ...

\letvalu...@av@\v!big   }\thirdofthreearguments
\letvalu...@av@\v!medium}\secondofthreearguments
\letvalu...@av@\v!small }\firstofthreearguments




-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: 038 477 53 69 | fax: 038 477 53 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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] hyphenation in latest

2009-04-09 Thread Hans Hagen

Thomas A. Schmitz wrote:


On Apr 9, 2009, at 12:18 PM, Thomas A. Schmitz wrote:



On Apr 9, 2009, at 12:11 PM, Hans Hagen wrote:


weird, as the catcodes look ok



Hmm, I'll do some more tests later; I'll be offline until Sunday 
night. But it doesn't work in mkii either, so the bug probably is with 
the pattern file.


OK, just one more detail before I leave: I get proper hyphenation with 
luatex version 0.35.0 and ConTeXt version 2009.02.24 (had this older 
version still on my linux box). lang-agr.pat in this version and the 
most recent beta is identical. So it's not the pattern file itself which 
is at fault; in between, something must have changed in the way the 
patterns are loaded and used, either in luatex itself or in ConTeXt.


in lang-grk ...

\installlanguage
  [\s!agr]
  [\s!default=\s!gr,
   \s!patterns=\s!agr,
   \s!mapping=\s!agr,
   \s!encoding=\s!agr]

there are no gr patterns so you need to specify another set


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: 038 477 53 69 | fax: 038 477 53 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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] new beta

2009-04-09 Thread Ulrike Fischer
Am Thu, 09 Apr 2009 11:36:58 +0200 schrieb Hans Hagen:


 It works partly: After I called luatools --generate mtxrun now finds
 also fonts in my various texmf-trees (and not only the one in the
 system folder), but mtxrun works only if I move first font-syn.lua
 in the folder of mtxrun. But this only a small nuisance. 

OK, I found the source of the problem:

If I replace in luatools.lua (function input.aux.find_file) the line
5294

 if find(path,//$) then recurse = true  else recurse = false end 

by 

 if find(path,//$) then recurse = true  else recurse = true end

(that means if I set recurse=true for all cases) then files are
found. 

The problems seems to be that luatools appends // only to one of my
roots (the last mentioned in $TEXMF). The output of the path
variable in the above code is:

I:/TeX-Roots/luatexmf/texmf
...
J:/MIKTEX2.7
C:/Dokumente und
Einstellungen/Ulle/Anwendungsdaten/MiKTeX/2.7/scripts//

So the above test is false for most of my roots. 

The change doesn't help with mtxrun ;-(.

-- 
Ulrike Fischer 

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

2009-04-09 Thread Vyatcheslav Yatskovsky

Hello Thomas and everybody,

I've checked hyph patterns for Russian and languages provided by you. I 
discovered that nothing has changed for last month -- the result is 
exactly the same for luatex 0.35 and 0.37, as well as respective ConTeXt 
builds.


Two demo images are attached.

Vyatcheslav


Hi Vyatcheslav,

I append a file that I have used, can you simply add tests for Russian 
and Ukrainian? Yes, I'm using mkiv, latest beta, luatex 0.37.


Thanks for your help - I will be offline until Sunday night.

All best

Thomas




attachment: LuaTeX 0.37.0-2009040118 ConTeXt 2009.04.06.pngattachment: LuaTeX 0.35.0-2009022423 ConTeXt 2009.03.27.png___
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 beta

2009-04-09 Thread Vyatcheslav Yatskovsky

Hello Ulrike,

If you use Windows, try the GUI installer. It sets all needed env vars 
globally, and always works like a charm :)


http://minimals.contextgarden.net/setup/context-installer/ContextMinimalInstall.exe

(But beware, it may interfere with MikTeX registry settings).

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


[NTG-context] t-vim failed under windows

2009-04-09 Thread Andy Wong
Hello,

I have tried the example using the vim mode to typeset some c codes. When I
run the sample file, context stop with errors. the sample file and log file
as
list below. I use the windowsXP with the minimal context from ConTeXt garden
and \write18 is enabled.  From the log file, it seems the vim command is not
properly quoted as follows:

MTXrun | executing: vim -u NONE -e -C -n -V10log -c set tabstop=8 -c
syntax
on -c set syntax=c -c let contextstartline=1 -c let contextstopline=0
-c
source c:/context/tex/texmf-context/tex/context/third/vim/2context.vim -c
wqa
vimdemo-vimsyntax.tmp 
I check the t-vim.tex, the definition of the vim command is correct. I don't
know why the \shellescapedquote is not properly resolved.
Any help? thanks.

Andy

---
Sample file:_

\setupcolors[state=start]
\usetypescript[modern-base][texnansi]
\setupbodyfont[modern,10pt]
\usemodule[vim]
\starttext
\title{Matlab Code Listing -- Color}
\definevimtyping [C] [syntax=c]
\startC
#include stdio.h
#include stdlib.h
void main()
{
   printf(Hello World\n) ;
   return;
}
\stopC
\stoptext
--

The Log file 


C:\Documents\TeXcontext --verbose vimdemo.tex
MTXrun | variable SELFAUTOLOC set to c:/context/tex/texmf-mswin/bin
MTXrun | variable SELFAUTODIR set to c:/context/tex/texmf-mswin
MTXrun | variable SELFAUTOPARENT set to c:/context/tex
MTXrun | variable TEXMFCNF set to
c:\context\tex\texmf{-local,-context,}/web2c
MTXrun | loading configuration for c:/context/tex/texmf/web2c from
c:/context/te
x/texmf-cache/luatex-cache/context/2fea56f92e5267d7cc9662e4d5f52e1e/trees/53ad5f
8b88994bdd02baa17501789699
MTXrun | locating list of c:/context/tex/texmf-project
MTXrun | locating list of c:/context/tex/texmf-fonts
MTXrun | locating list of c:/context/tex/texmf-local
MTXrun | locating list of c:/context/tex/texmf-mswin
MTXrun | locating list of c:/context/tex/texmf-context
MTXrun | locating list of c:/context/tex/texmf-extra
MTXrun | locating list of c:/context/tex/texmf
MTXrun | loading files for c:/context/tex/texmf-mswin from
c:/context/tex/texmf-
cache/luatex-cache/context/2fea56f92e5267d7cc9662e4d5f52e1e/trees/ad82a2edc94cf3
e384a3b09c57286765
MTXrun | loading files for c:/context/tex/texmf-context from
c:/context/tex/texm
f-cache/luatex-cache/context/2fea56f92e5267d7cc9662e4d5f52e1e/trees/3063f1ad75eb
7de075a8e56a9b4e93ce
MTXrun | loading files for c:/context/tex/texmf from
c:/context/tex/texmf-cache/
luatex-cache/context/2fea56f92e5267d7cc9662e4d5f52e1e/trees/e4a2bdb91bf5cb68211e
9b73648a473b
MTXrun | using script:
c:/context/tex/texmf-context/scripts/context/lua/mtx-cont
ext.lua
MTXrun | run 1: luatex
--fmt=c:/context/tex/texmf-cache/luatex-cache/context/2f
ea56f92e5267d7cc9662e4d5f52e1e/formats/cont-en
--lua=c:/context/tex/texmf-cach
e/luatex-cache/context/2fea56f92e5267d7cc9662e4d5f52e1e/formats/cont-en.luc
./
vimdemo.tex
This is LuaTeX, Version snapshot-0.37.0-2009040118 (Web2C 7.5.7)
 \write18 enabled.
(vimdemo.tex
ConTeXt  ver: 2009.04.06 18:43 MKIV  fmt: 2009.4.6  int: english/english
system : cont-new loaded
(c:/context/tex/texmf-context/tex/context/base/cont-new.tex
systems : beware: some patches loaded from cont-new.tex
(c:/context/tex/texmf-context/tex/context/base/cont-new.mkiv)
(c:/context/tex/te
xmf-context/tex/context/base/cont-mtx.tex))
system : cont-fil loaded
(c:/context/tex/texmf-context/tex/context/base/cont-fil.tex
loading : ConTeXt File Synonyms
)
system : cont-sys loaded
(c:/context/tex/texmf-context/tex/context/user/cont-sys.tex
(c:/context/tex/texm
f-context/tex/context/base/type-tmf.tex)
(c:/context/tex/texmf-context/tex/conte
xt/base/type-siz.tex
(c:/context/tex/texmf-context/tex/context/base/type-siz.mki
v)) (c:/context/tex/texmf-context/tex/context/base/type-otf.tex
(c:/context/tex/
texmf-context/tex/context/base/type-otf.mkiv))
system : module plus loaded
(c:/context/tex/texmf-context/tex/context/base/m-plus.tex))
system : vimdemo.top loaded
(vimdemo.top)
specials   : pdftex loaded
language   : language en is active
color  : mpcmyk color space is supported
color  : mpspot color space is supported
color  : system rgb is global activated
system : module vim loaded
(c:/context/tex/texmf-context/tex/context/third/vim/t-vim.tex
loading : Context Module for ViM Sytax Highlighting
color  : system hex is loaded
(c:/context/tex/texmf-context/tex/context/base/colo-hex.tex))
systems : begin file vimdemo at line 5
title   : - Matlab Code Listing -- Color
MTXrun | variable SELFAUTOLOC set to c:/context/tex/texmf-mswin/bin
MTXrun | variable SELFAUTODIR set to c:/context/tex/texmf-mswin
MTXrun | variable SELFAUTOPARENT set to c:/context/tex
MTXrun | variable TEXMFCNF set to
c:\context\tex\texmf{-local,-context,}/web2c
MTXrun | loading 

[NTG-context] pdfsplit

2009-04-09 Thread Wolfgang Schuster

Hi Hans,

the pdfsplit option for texexec use the name texexec.pdf for each of  
the document and only the last page remains because all other are  
overwritten, can you add the pagenumber (texexec-1.pdf, texexec-2.pdf  
etc.) to the filename.


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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] new beta

2009-04-09 Thread Hans Hagen

Ulrike Fischer wrote:

Am Thu, 09 Apr 2009 11:36:58 +0200 schrieb Hans Hagen:



It works partly: After I called luatools --generate mtxrun now finds
also fonts in my various texmf-trees (and not only the one in the
system folder), but mtxrun works only if I move first font-syn.lua
in the folder of mtxrun. But this only a small nuisance. 


OK, I found the source of the problem:

If I replace in luatools.lua (function input.aux.find_file) the line
5294

 if find(path,//$) then recurse = true  else recurse = false end 

by 


 if find(path,//$) then recurse = true  else recurse = true end

(that means if I set recurse=true for all cases) then files are
found. 


The problems seems to be that luatools appends // only to one of my
roots (the last mentioned in $TEXMF). The output of the path
variable in the above code is:

I:/TeX-Roots/luatexmf/texmf

J:/MIKTEX2.7
C:/Dokumente und
Einstellungen/Ulle/Anwendungsdaten/MiKTeX/2.7/scripts//

So the above test is false for most of my roots. 


The change doesn't help with mtxrun ;-(.


hm, but this // is determined by the configuration file texmf.cnf

tweaking the script for miktex and then breaking my own system is a bit 
tricky


how does your texmf spec look? (the one with the //)? maybe i need to 
fix the expander (quite tricky code)


Hans


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: 038 477 53 69 | fax: 038 477 53 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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] Paragraphs in Layers

2009-04-09 Thread Design Department
Why does the following produce a single line when the layer content
produces four lines in normal flow?
How are paragraphs and new lines produced in layers?

I've tried \par, \endgraf, \crlf and \\ without success.

\definelayer[TicketSummary]
  [x=\backspace, y=\topspace
width=4in, height=4in,
repeat=no]
\setlayer[TicketSummary]
  [hoffset=.5\backspace, voffset=2.5in]{
\bold{Client Name:}
Acme Corporation

\bold{Location of Work:}
Main warehouse
}

-- 
david
___
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] Paragraphs in Layers

2009-04-09 Thread Wolfgang Schuster


Am 09.04.2009 um 21:40 schrieb Design Department:


Why does the following produce a single line when the layer content
produces four lines in normal flow?
How are paragraphs and new lines produced in layers?


Use \setlayerframed.

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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Paragraphs in Layers

2009-04-09 Thread Design Department
Just tried the following snippet on the live.contextgarden.net with no joy:
The layer content appears on a single line, whether I use \par, \\,
\endgraf, \crlf or no line ending at all.

\definelayer[TicketSummary]
  [x=\backspace, y=\topspace
width=4in, height=4in,
repeat=no]
\setlayerframed[TicketSummary]
  [hoffset=.5\backspace, voffset=2.5in]{
\bold{Client Name:} \\
Acme Corporation \\
\bold{Location of Work:}
Main warehouse
}

\setupbackgrounds[page][background={TicketSummary}]

\starttext
Hello world!
\stoptext

-- 
david
___
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] \rightarrow missing?

2009-04-09 Thread Alan BRASLAU
Indeed, it seems to be broken in mkiv
\rightarrow
\to
\leftarrow
...

However, \leftrightarrow works.

So, currently, it is hard to typeset limits under mkiv!

Alan


On Tuesday 31 March 2009 09:14:16 Hans Hagen wrote:
 Aditya Mahajan wrote:
  On Mon, 30 Mar 2009, Jesse Alama wrote:
  It seems that \rightarrow is missing.  The command exists, in the sense
  that its use doesn't lead to an error, but it doesn't lead to anything
  in the output.  Minimal example:
 
  \starttext
  $\rightarrow$
  \stoptext
 
  Hans,
 
  What does the new arrow function in math-vfu.lua supposed to do?

 it will be used instead of the macro based one (as luatex has native
 support for such extenders now) but i had to wait till you fixed all the
 other arrows that you added someplace

 Hans

___
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] Paragraphs in Layers

2009-04-09 Thread Wolfgang Schuster


Am 09.04.2009 um 22:14 schrieb Design Department:

Just tried the following snippet on the live.contextgarden.net with  
no joy:

The layer content appears on a single line, whether I use \par, \\,
\endgraf, \crlf or no line ending at all.


To help you I will explain why your setup did not work.

TeX use boxes to place text, two different types are available
and they are horizontal (\hbox) and vertical (\vbox) boxes.

Text in a horizontal box is placed in a single line and \par \vskip ...
is ignored, if your text is too long it runs over the right margin, only
text in a vertical box is placed in multiple lines.

The pure \setlayer command use a horizontal box for the content
and did therefore not work for you, \setlayerframed is (simplified)
a combination of \setlayer and \frame, the definition looks like
\setlayer[name][setup]{\framed{text}}.

The \framed command itself can act as horizontal or vertical box
dependent on the setup, by default it acts like a horizontal box,
to let it act as vertical box two setup need to be done
(1) the alignment (format) of the text needs to be set with
'align=left|normal|...' and (2) it needs either a width or
a height with is done with 'width=...' or 'height=...' or
'lines=...'.

Your layer command should now look like:

\setlayerframed
  [TicketSummary]
  [hoffset=.5\backspace,
   voffset=2.5in,
   width=3cm,
   align=right]
  {\bold{Client Name:}\\
   Acme Corporation\\
   \bold{Location of Work:}
   Main warehouse}

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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Paragraphs in Layers

2009-04-09 Thread Willi Egger
I do not know what you precisely want to achieve. You need to give  
dimensions to the framed part of the \setlayerframed. Position the  
layer with the layer definition. Preset the layer to lefttop and move  
it with the x and y keys.


\definelayer[TicketSummary]
   [x=\backspace, y=2\topspace,
preset=lefttop,
repeat=no]
\setlayerframed[TicketSummary]
   [width=\textwidth,height=.5in,align=flushleft]{
\bold{Client Name:} Acme Corporation \\
\bold{Location of Work:}
Main warehouse
}


Willi
On Apr 9, 2009, at 10:14 PM, Design Department wrote:


\definelayer[TicketSummary]
  [x=\backspace, y=\topspace
width=4in, height=4in,
repeat=no]
\setlayerframed[TicketSummary]
  [hoffset=.5\backspace, voffset=2.5in]{
\bold{Client Name:} \\
Acme Corporation \\
\bold{Location of Work:}
Main warehouse
}

\setupbackgrounds[page][background={TicketSummary}]

\starttext
Hello world!
\stoptext


___
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] colored backgrounds in displayed math

2009-04-09 Thread Wolfgang Schuster


Hi Sanjoy, welcome back

In displayed math I was trying to highlight a piece of a formula  
using a

gray background.  After a few spacing failures with \framed, I
discovered \mframed in the core-rul.tex source file.  The comments  
there

say:


Use backgroundoffset, not frameoffset.

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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Paragraphs in Layers

2009-04-09 Thread Design Department
Thks. I was incorrectly assuming that the dimension properties,
especially width, should be set in \definelayer.
I'm not clear on the purpose of a separate \definelayer command,
unless it's to allow the abstraction of layer offsets from topspace
and backspace value, the way I have in this example.

It works now, though, and I'll accept that as an answer given my
unwillingness to review that code for \definelayer ;-)


-- 
david
___
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] t-vim failed under windows

2009-04-09 Thread Aditya Mahajan

On Thu, 9 Apr 2009, Andy Wong wrote:


Hello,

I have tried the example using the vim mode to typeset some c codes. When I
run the sample file, context stop with errors. the sample file and log file
as
list below. I use the windowsXP with the minimal context from ConTeXt garden
and \write18 is enabled.  From the log file, it seems the vim command is not
properly quoted as follows:

MTXrun | executing: vim -u NONE -e -C -n -V10log -c set tabstop=8 -c
syntax
on -c set syntax=c -c let contextstartline=1 -c let contextstopline=0
-c
source c:/context/tex/texmf-context/tex/context/third/vim/2context.vim -c
wqa
vimdemo-vimsyntax.tmp 
I check the t-vim.tex, the definition of the vim command is correct. I don't
know why the \shellescapedquote is not properly resolved.
Any help? thanks.


Does changing noquote to noquotes in line 797 of t-vim help?

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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Paragraphs in Layers

2009-04-09 Thread Wolfgang Schuster


Am 09.04.2009 um 22:54 schrieb Design Department:


Thks. I was incorrectly assuming that the dimension properties,
especially width, should be set in \definelayer.
I'm not clear on the purpose of a separate \definelayer command,
unless it's to allow the abstraction of layer offsets from topspace
and backspace value, the way I have in this example.

It works now, though, and I'll accept that as an answer given my
unwillingness to review that code for \definelayer ;-)


\definelayer creates new element to place elements in the background
and \setlayer fills it with content.

the width and height for \definelayer have a different purpose
than the one for \setlayerframed, it's best to write just

\definelayer[mylayer]

or

\definelayer[mylayer][width=\paperwidth,height=\paperheight]

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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Paragraphs in Layers

2009-04-09 Thread luigi scarso
I have modify this sample

\newdimen\currentlayerheight
\newdimen\currentlayerwidth
\newbox\Content


\definelayer[TicketSummary]
 [x=\backspace, y=\topspace,
   width=4in, height=4in,
   repeat=no]
\setlayer[TicketSummary][hoffset=.5\backspace, voffset=2.5in]{%
\unprotect%
\currentlayerheight=\dimexpr\csname @@llTicketSummaryheight\endcsname\relax%
\currentlayerwidth=\dimexpr\csname @@llTicketSummarywidth\endcsname\relax%
\protect%
\setbox\Content=\vbox{\hsize=\currentlayerwidth%
   \bold{Client Name:} \\
   Acme Corporation \\
   \bold{Location of Work:}
   Main warehouse
   }%
\ht\Content=\currentlayerheight%
\ruledhbox{\box\Content}
}

\setupbackgrounds[page][background={TicketSummary}]

\starttext
Hello world!
\stoptext


minimals: no erros, bu evince says

Error: ExtGState 'Tr0' is unknown
Error: ExtGState 'Tr0' is unknown
Error: ExtGState 'Tr0' is unknown
Error: ExtGState 'Tr0' is unknown
Error: ExtGState 'Tr0' is unknown

minimals-beta: errors

! You can't use `\dimexpr' in restricted horizontal mode.
l.12 \currentlayerheight=\dimexpr
 \csname @@llTicketSummaryheight\endcsname\r...
?




-- 
luigi
___
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] Paragraphs in Layers

2009-04-09 Thread Wolfgang Schuster


Am 09.04.2009 um 23:44 schrieb luigi scarso:


\unprotect%
\currentlayerheight=\dimexpr\csname @@llTicketSummaryheight\endcsname 
\relax%
\currentlayerwidth=\dimexpr\csname @@llTicketSummarywidth\endcsname 
\relax%

\protect%


why unprotect/protect and why so many '%'?

\edef\currentlayerheight{\csname @@llTicketSummaryheight\endcsname}%
\edef\currentlayerwidth {\csname @@llTicketSummarywidth\endcsname}%


\setbox\Content=\vbox{\hsize=\currentlayerwidth%
  \bold{Client Name:} \\
  Acme Corporation \\
  \bold{Location of Work:}
  Main warehouse
  }%
\ht\Content=\currentlayerheight%


why not \vbox to \currentlayerheight


! You can't use `\dimexpr' in restricted horizontal mode.
l.12 \currentlayerheight=\dimexpr
\csname @@llTicketSummaryheight 
\endcsname\r...

?


\newdimen checks for the existence of a control sequence

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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \rightarrow missing?

2009-04-09 Thread Aditya Mahajan

On Thu, 9 Apr 2009, Alan BRASLAU wrote:


Indeed, it seems to be broken in mkiv
\rightarrow
\to
\leftarrow


Hans, this has to do with the arrow function in math-vfu. Do you know why 
this is failing?


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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Paragraphs in Layers

2009-04-09 Thread luigi scarso
On Fri, Apr 10, 2009 at 12:04 AM, Wolfgang Schuster
schuster.wolfg...@googlemail.com wrote:

 Am 09.04.2009 um 23:44 schrieb luigi scarso:

 \unprotect%
 \currentlayerheight=\dimexpr\csname
 @@llTicketSummaryheight\endcsname\relax%
 \currentlayerwidth=\dimexpr\csname @@llTicketSummarywidth\endcsname\relax%
 \protect%

 why unprotect/protect
unecessary -- quick cut and paste from other code --
but not wrong,

 and why so many '%'?
prevent spurios spaces

 \edef\currentlayerheight{\csname @@llTicketSummaryheight\endcsname}%
 \edef\currentlayerwidth {\csname @@llTicketSummarywidth\endcsname}%


 \setbox\Content=\vbox{\hsize=\currentlayerwidth%
  \bold{Client Name:} \\
  Acme Corporation \\
  \bold{Location of Work:}
  Main warehouse
  }%
 \ht\Content=\currentlayerheight%

 why not \vbox to \currentlayerheight
yes I mean
\ht\Content=\currentlayerheight%
\dp\Content=0pt%



 ! You can't use `\dimexpr' in restricted horizontal mode.
 l.12 \currentlayerheight=\dimexpr
                                \csname
 @@llTicketSummaryheight\endcsname\r...
 ?

 \newdimen checks for the existence of a control sequence

the point is that on minimals-beta there is an error,
on minimals no , but xpdf says

Error: ExtGState 'Tr0' is unknown
Error: ExtGState 'Tr0' is unknown
Error: ExtGState 'Tr0' is unknown
Error: ExtGState 'Tr0' is unknown
Error: ExtGState 'Tr0' is unknown

The code is not wrong -- maybe a bit strange

Also this is ok in minimals
fails in minimals-beta,
and I think It's legal code, but I can fail .

\newdimen\currentlayerheight
\starttext
\currentlayerheight=\dimexpr 12pt +0pt\relax%
\the\currentlayerheight
\stoptex\newdimen\currentlayerheight




-- 
luigi
___
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] Paragraphs in Layers

2009-04-09 Thread Wolfgang Schuster


Am 10.04.2009 um 00:53 schrieb luigi scarso:


and why so many '%'?

prevent spurios spaces


after \relax?


\newdimen checks for the existence of a control sequence


the point is that on minimals-beta there is an error,
on minimals no , but xpdf says

Error: ExtGState 'Tr0' is unknown
Error: ExtGState 'Tr0' is unknown
Error: ExtGState 'Tr0' is unknown
Error: ExtGState 'Tr0' is unknown
Error: ExtGState 'Tr0' is unknown

The code is not wrong -- maybe a bit strange


works fine here with preview app or adobe reader


Also this is ok in minimals
fails in minimals-beta,
and I think It's legal code, but I can fail .

\newdimen\currentlayerheight
\starttext
\currentlayerheight=\dimexpr 12pt +0pt\relax%
\the\currentlayerheight
\stoptex\newdimen\currentlayerheight


current: \newdimen\currentlayerheight - create new dimen register

beta: \newdimen\currentlayerheight - check if \currentlayerheight is  
already defined, it true write a message to the terminal and do  
nothing else create a new dimen register what did not happen here  
because \currentlayerheight is defined in page-lyr.tex


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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] t-vim failed under windows

2009-04-09 Thread Andy Wong
The same problem. It seems the \shellescapedquote generated to the wrong
position.
So vim complains the -c parameters is wrong.

Andy.

On Thu, Apr 9, 2009 at 4:22 PM, Aditya Mahajan adit...@umich.edu wrote:

 On Thu, 9 Apr 2009, Andy Wong wrote:

 Hello,

 I have tried the example using the vim mode to typeset some c codes. When
 I
 run the sample file, context stop with errors. the sample file and log
 file
 as
 list below. I use the windowsXP with the minimal context from ConTeXt
 garden
 and \write18 is enabled.  From the log file, it seems the vim command is
 not
 properly quoted as follows:

 MTXrun | executing: vim -u NONE -e -C -n -V10log -c set tabstop=8 -c
 syntax
 on -c set syntax=c -c let contextstartline=1 -c let
 contextstopline=0
 -c
 source c:/context/tex/texmf-context/tex/context/third/vim/2context.vim
 -c
 wqa
 vimdemo-vimsyntax.tmp 
 I check the t-vim.tex, the definition of the vim command is correct. I
 don't
 know why the \shellescapedquote is not properly resolved.
 Any help? thanks.


 Does changing noquote to noquotes in line 797 of t-vim help?

 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  : https://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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] language mix

2009-04-09 Thread Vyatcheslav Yatskovsky

Hello,

What about adding hyph-uk to the distribution? ;)

Next, how to mix two languages in a document? For example, I typeset in 
Russian, by occasionally use English words (or even sentences). How to 
make them both being hyphenated?

\language[ru,en] seems to be not supported.

Bets,
Vyatcheslav


___
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] \rightarrow missing?

2009-04-09 Thread Jesse Alama
I switched from MkIV to MkII today because of this gap in MkIV's math:
I need to submit a dissertation that has \rightarrow's in it.  Let's
hope that this issue is resolved soon.

Jesse

Alan BRASLAU alan.bras...@cea.fr writes:

 Indeed, it seems to be broken in mkiv
 \rightarrow
 \to
 \leftarrow
 ...

 However, \leftrightarrow works.

 So, currently, it is hard to typeset limits under mkiv!

 Alan


 On Tuesday 31 March 2009 09:14:16 Hans Hagen wrote:
 Aditya Mahajan wrote:
  On Mon, 30 Mar 2009, Jesse Alama wrote:
  It seems that \rightarrow is missing.  The command exists, in the sense
  that its use doesn't lead to an error, but it doesn't lead to anything
  in the output.  Minimal example:
 
  \starttext
  $\rightarrow$
  \stoptext
 
  Hans,
 
  What does the new arrow function in math-vfu.lua supposed to do?

 it will be used instead of the macro based one (as luatex has native
 support for such extenders now) but i had to wait till you fixed all the
 other arrows that you added someplace

 Hans

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


-- 
Jesse Alama (al...@stanford.edu)

___
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] xetex and attachment: troubles

2009-04-09 Thread Jesse Alama
Any progress on this?  As of 2009-04-09, attachments with xetex still
behave as Andrea described on 2008-03-31.  (I'm using the xetex in the
minimals.)

Jesse

Andrea Valle va...@di.unito.it writes:

 Thanks Mojca, Hans,

 ok, I've understood.

 :)

 -a-



 On 3 Apr 2008, at 12:17, Hans Hagen wrote:

 Mojca Miklavec wrote:

 On Thu, Apr 3, 2008 at 11:08 AM, Andrea Valle wrote:

 Thanks Mojca,

 The problem is not the --xtx switch, but the lack of support for
 the
 underlying (xdvipdfmx) driver.


 Sorry, please remember I'm very far from there...
 I was just meaning: the problem is in xetex engine?



 I googled a bit and found the following slides:
       http://project.ktug.or.kr/dvipdfmx/doc/tug2005.pdf
 see page 18 in particular.


 thanks, means really nothing to me :-)


 It was meant for someone else trying to help :-)


 she meant me; however, i have no test file and probably a non working 
 xetex on my machine (need to update)

 Hans

 -
                                            Hans Hagen | PRAGMA ADE
                Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
       tel: 038 477 53 69 | fax: 038 477 53 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  : https://foundry.supelec.fr/projects/contextrev/
 wiki     : http://contextgarden.net
 
 ___


 --
 Andrea Valle
 --
 CIRMA - DAMS
 Università degli Studi di Torino
 -- http://www.cirma.unito.it/andrea/
 -- http://www.myspace.com/andreavalle
 -- andrea.va...@unito.it
 --


 
 Think of it as seasoning
 . noise [salt] is boring
 . F(blah) [food without salt] can be boring
 . F(noise, blah) can be really tasty
 
 (Ken Perlin on noise)





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

-- 
Jesse Alama (al...@stanford.edu)

___
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] t-vim failed under windows

2009-04-09 Thread Aditya Mahajan

On Thu, 9 Apr 2009, Andy Wong wrote:


The same problem. It seems the \shellescapedquote generated to the wrong
position.
So vim complains the -c parameters is wrong.


Does

mtxrun --verbose  --noquotes bin:vim -u NONE

work correctly on windows?

What about if you run texexec --lua instead of context (with noquote 
changed to noquotes in t-vim.tex)?


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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] language mix

2009-04-09 Thread Wolfgang Schuster


Am 10.04.2009 um 02:29 schrieb Vyatcheslav Yatskovsky:


Hello,

What about adding hyph-uk to the distribution? ;)


It'S there but the pattern name is hyph-gb, see lang-ger.tex

Next, how to mix two languages in a document? For example, I typeset  
in Russian, by occasionally use English words (or even sentences).  
How to make them both being hyphenated?

\language[ru,en] seems to be not supported.


\mainlanguage[ru]

\starttext

bla bla bla more russian text {\uk something in english} and more text  
in russian


\stoptext

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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___