Re: [NTG-context] PDF Viewer Navigation Tree

2011-06-16 Thread Yury G. Kudryashov
Kip Warner wrote:

 Hey folks,
 
 I'm not sure where to be looking, as this may well be a feature already
 implemented in ConTeXt or its lower level dependencies. I couldn't find
 anything in the mailing archives, nor in the reference manual or wiki.
 
 In my PDF viewer Evince, I have a navigation tree in the side bar that
 allows me quick access to various parts of some PDF documents. When I
 was using Texinfo, this was generated automatically for each @chapter /
 @section / @subsection / etc when the PDF was being written out. I
 noticed this doesn't appear to happen automatically with ConTeXt.
 
 How does one go about doing the same in ConTeXt?
 
Try \setupinteraction[state=start].

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

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


[NTG-context] huge parentheses with xits

2011-04-16 Thread Yury G. Kudryashov
Hi!

The following works well with default font but produces too small 
parentheses with xits.

\doifmodeelse{xits}{\setupbodyfont[xits]}

\starttext
\startformula
\left(
\startmatrix[n=1]\dorecurse{10}{\NC 1\NR}\NC 1\NR\stopmatrix
\right)
\stopformula
\stoptext

Any ideas?

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

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


Re: [NTG-context] huge parentheses with xits

2011-04-16 Thread Yury G. Kudryashov
Aditya Mahajan wrote:

 On Sat, 16 Apr 2011, Yury G. Kudryashov wrote:
 
 Works correctly here (need to remove the last \NR due to a bug in
 \stopmatrix, but that increases the size of the parenthesis, not reduce
 it).
 
 Are you using the latest version of xits?
I used the latest xits but not the latest context.

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

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


Re: [NTG-context] Translating PDF-files

2011-01-20 Thread Yury G. Kudryashov
Alan BRASLAU wrote:

 A fun exercise is to put a text through google translate into any
 language, then pass the result back into the original language.
 
 via Russian: Fun exercise is to put the text through Google Translate in
 any language, and then pass the result back to the original language.
The Russian translation is much worse than the English-Russian-English 
one.

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

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


Re: [NTG-context] \note and \footnote

2010-12-23 Thread Yury G. Kudryashov
Jon Crump wrote:

 All,
 
 I thought to use TeX's \note[ref], but the following doesn't seem to work.
 
 \startxmlsetups xml:ref
 \define\thisRefName{\xmlatt{#1}{target}}
 \xmldoifelse{#1}{parent::d...@type='arText']}
 {\footnote[\thisRefName]{\xmlfirst{#1}
{root::/body/text/d...@type='fnotes']/no...@xml:id==string.sub('\xmlatt{#1}
{target}',2)]}}}
 {\note[\thisRefName]}
I'm not sure about expansion order. Probably \thisRefName is not expanded in 
one of the commands above. Could you please attach either a minimal working 
example (test.xml and test.tex that one can save and run context test), or 
log file?

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

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


[NTG-context] buffers and expansion order

2010-12-13 Thread Yury G. Kudryashov
Hi!

Why the following doesn't work?

\def\mybuf{\startbuffer[a]b\stopbuffer}
\mybuf

Actually, I need slightly more advanced command, but this is the minimal 
example.

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

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


Re: [NTG-context] Redundant equation is a MetaPost bug in MkIV?

2010-12-05 Thread Yury G. Kudryashov
Li Yanrui (李延瑞) wrote:

 Hi,
 
 Now it can not be compiled and luatex outputs:
 
 mplib   : loading 'metafun.mp' (experimental metapost version two)
 mplibmp terminal: ! Redundant equation.
 to be read again
;
 * u = 1cm;
  xmin = -2.6u; xmax = 4u; drawarrow (xmin,0)--(xmax,0);
  label.lf...
 
 ! Redundant equation.
 to be read again
 
 Is this a bug or it always need to use 'save' macro to hold these
 local variable in metafun?
ConTeXt compiles all metapost code in one long run, so you have to re-
declare 'u' to avoid this error (e.g. 'save' or 'numeric u;').


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

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


[NTG-context] Another TikZ problem with !

2010-12-03 Thread Yury G. Kudryashov
Hi!

Color is not the only place where TikZ treats ! in a special way. For 
example, in TikZ/LaTeX you can say:

\coordinate (A) at (0, 0);
\coordinate (B) at (1, 0);
\coordinate (C) at ($ (A)!.3!(B) $); % z.C = .3[z.A, z.B] in MetaPost
\coordinate (D) at (2, 1);
\coordinate (E) at ($ (A)!(B)!(D) $); % projection of (B) to (A)--(D).

This code fails in ConTeXt because ! is made a normal character.

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

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


[NTG-context] footnote conversion

2010-11-28 Thread Yury G. Kudryashov
Hi!

The following doesn't work in MkIV. Tried both current and beta.

\definenote[thanks][conversion=set 2]
\starttext
Test\thanks{Thanks}
\stoptext

I get Test^1 instead of a symbol.

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

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


[NTG-context] enumeration counters, way=bysection

2010-11-25 Thread Yury G. Kudryashov
Hi!

I want to have the following (Theorems and Lemmas share the counter, 
way=bysection):

Section 1. Foo

Theorem 1.1 Bar
Lemma 1.2 Baz

Section 2. Foo

Theorem 2.1 Bar
Lemma 2.2 Baz

The following used to work about a month or two ago.

\setupenumerations[way=bysection]
\newcounter\theorems
\defineenumeration[thm]
[text=Theorem,prefix=yes,prefixsegments=section,counter=theorems]
\defineenumeration[lem]
[text=Lemma,prefix=yes,prefixsegments=section,counter=theorems]
\starttext
\dorecurse{5}{
\section{Foo}
\startthm
Bar
\stopthm
\startlem
Baz
\stoplem
}
\stoptext

Today the counter doesn't reset, i.e. I get Theorem 2.3, Lemma 2.4, Theorem 
3.5 etc. How can I fix it?


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

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


Re: [NTG-context] enumeration counters, way=bysection

2010-11-25 Thread Yury G. Kudryashov
Wolfgang Schuster wrote:

 
 Am 25.11.2010 um 09:54 schrieb Yury G. Kudryashov:
 
 The following used to work about a month or two ago.
 
 \setupenumerations[way=bysection]
 \newcounter\theorems
 \defineenumeration[thm]
 [text=Theorem,prefix=yes,prefixsegments=section,counter=theorems]
 \defineenumeration[lem]
 [text=Lemma,prefix=yes,prefixsegments=section,counter=theorems]
 
 \newcounter has nothing to do with enumeration counter the counter key
 expects the name from another enumeration, e.g. „thm“
Thanks!

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

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


Re: [NTG-context] \todo

2010-11-23 Thread Yury G. Kudryashov
Procházka Lukáš wrote:

 Hello,
 
 is there in Ctx something like \todo command, provided by LaTeX via todo
 package (http://mirror.ctan.org/macros/latex/contrib/todo/todo.pdf)?
There is a fixme third-party module.

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

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


[NTG-context] sorting bibliography

2010-11-22 Thread Yury G. Kudryashov
Hi!

Could you please tell me how to sort bibliogrpahy in ConTeXt Mark IV? I've 
tried
\setuppublications[sorttype=author,sort=yes]
but this doesn't work.

It seems that bibl-tra.lua contains two compare() functions. Which one is 
used (my Lua knowledge is far from perfect)?

P.S.: I'm ready to convert my bibtex db to another format if this will help.

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

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


Re: [NTG-context] Furigana

2010-10-20 Thread Yury G. Kudryashov
S Barmeier wrote:

 Sorry to keep going on about this, but trying to load the
 project/environment with either of
 
 \project myproject
 \environment myenvironment
 
 in the component (directly after \startcomponent) gives me an error. It
 compiles fine without these commands, but then the \ruby command does
 not work. What am I doing wrong?
Could you please provide a small example?

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

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


Re: [NTG-context] \setupnote (was subfootnote)

2010-10-12 Thread Yury G. Kudryashov
luigi scarso wrote:

 On Tue, Oct 12, 2010 at 12:27 PM, Alan BRASLAU alan.bras...@cea.fr
 wrote:
 On Tuesday 12 October 2010 11:54:28 Steffen Wolfrum wrote:

 Hans recommended:

 \stopfootnote{}


 Thank you.

 This will work, but it is pretty ugly.%
 \startfootnote
 Hopefully Hans will fix this in mkiv.
 \stopfootnote{}
 In the meantime, we will just have to make do,
 but the special syntax as seen here raises eyebrows
 with my MS-Word bound collaborators.
 Maybe for now
 \let\StartFootnote\startfootnote
 \def\StopFootnote{\stopfootnote{}}
 and after fix
 \let\StartFootnote\startfootnote
 \let\StopFootnote\stopfootnote
How would that help? \somecommand automatically gobbles the next space.
 
 
 


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

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


Re: [NTG-context] export

2010-09-22 Thread Yury G. Kudryashov
Otared Kavian wrote:

 Hi Hans,
 
 Thanks for giving the information to those unlucky people who were not at
 the ConTeXt conference: Since I am interested in the feature you mention,
 I just tried with the latest beta you uploaded today, but the command
 \setupbackeds[export=yes] is unknown. Maybe there is a typo in what you
 said: could you please give a hint?
Try \setupbackends.
 
 Many thanks in advance: OK


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

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


Re: [NTG-context] tikz fading graphic

2010-09-07 Thread Yury G. Kudryashov
Peter Rolf wrote:

 Hi,
 
 this is the first time I use tikz and maybe something is missing in my
 example. I tried the second graphic from page 206 of the tikz manual.
 Sadly I only get a opaque blue square. Example and log file attached.
 
 Package tikz: Error! You need to say \usetikzlibrary{patterns}.
Read this error message.


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

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


Re: [NTG-context] linking to equations with leqalignno?

2010-09-05 Thread Yury G. Kudryashov
Otared Kavian wrote:

 Hi Pau,
 
 \define[1]\eqref{(\in[#1])} % this definition is optional…
\definereferenceformat[ineq][left=(,right=)]
 It is more handy to use \type{\eqref}: as one sees in equation
\ineq[nohair]

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

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


Re: [NTG-context] Fwd: Migrations: exactly LaTeX margins -- ConTeXt margins

2010-08-31 Thread Yury G. Kudryashov
Mojca Miklavec wrote:

 On Tue, Aug 31, 2010 at 09:42, Taco Hoekwater wrote:
 to use
 \documentclass[10pt,a4paper]{article}
 instead of 12pt, so one would need to account for that change as well.

One more warning: AFAIR, [10pt,a4paper] != [a4paper,10pt].

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

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


[NTG-context] diff mp-base.mp plain.mp

2010-08-27 Thread Yury G. Kudryashov
Hi!

In mp-base.mp dotlabel calls label twice. Once with t_, and once without. Is 
it intentional? plain.mp from texlive calls label only once with t_.

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

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


[NTG-context] show u; from TeX

2010-08-26 Thread Yury G. Kudryashov
Hi!

Is it possible to get the value of a MetaPost variable from TeX? It can, 
e.g., add show u; to MetaPost input, then parse output. I want to pretty-
print the values of some MetaPost variables.

Another question: is it possible to query the expansion of a macro from 
inside \directlua, if I have a variable that stores the macro name?

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

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


[NTG-context] graphics styles

2010-08-23 Thread Yury G. Kudryashov
Hi!

In tikz I can say
\draw[help lines] (0, 0) circle (1cm);
and setup what does help lines mean (color, linewidth etc.) in the 
environment file with \tikzset{help lines/.style={...}}.

Is there any way to do something similar with ConTeXt+MetaPost? Should I add 
drawoptions(\MPvar{another-style-name}) before each draw/fill command, and 
drawoptions() after it?

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

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


Re: [NTG-context] referenceformat, text

2010-08-09 Thread Yury G. Kudryashov
Hans Hagen wrote:

 On 9-8-2010 12:22, Yury G. Kudryashov wrote:
 
 \NC \in [x] \NC \in {left}[x] \NC \in {}{right}[x] \NC \in
  {left}{right}[x] \NC \NR
 I see no left or right in the first string in PDF output. Just
 1\t1\t1\t1.
 
 sure, as \in has no left and right (nor a setup)
Yes, but \in{left}{right}[x] has left and right but I don't see them 
in the output.

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

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


Re: [NTG-context] referenceformat, text

2010-08-09 Thread Yury G. Kudryashov
Hans Hagen wrote:

 On 9-8-2010 9:17, Yury G. Kudryashov wrote:
 Hans Hagen wrote:

 On 9-8-2010 12:22, Yury G. Kudryashov wrote:

 \NC \in [x] \NC \in {left}[x] \NC \in {}{right}[x] \NC \in
   {left}{right}[x] \NC \NR
 I see no left or right in the first string in PDF output. Just
 1\t1\t1\t1.

 sure, as \in has no left and right (nor a setup)
 Yes, but \in{left}{right}[x] has left and right but I don't see
 them in the output.
 
 i see them here so maybe your update went wrong
I don't see them in a fresh install. Probably you have some uncomitted 
stuff.

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

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


[NTG-context] referenceformat, text

2010-08-08 Thread Yury G. Kudryashov
Hi!

The following code:

\definereferenceformat[lem][text=Lemma]
\inlem[lem:mylemma]

produces just a number, no Lemma  prefix. I've sent a patch to fix it a 
while ago. Could you please apply it, or tell me why you don't want to apply 
it?

-- 
Yury G. Kudryashov--- a/tex/texmf-context/tex/context/base/strc-ref.mkiv	2010-05-21 15:44:04.0 +0400
+++ b/tex/texmf-context/tex/context/base/strc-ref.mkiv	2010-05-31 22:18:38.0 +0400
@@ -983,10 +983,13 @@
   {\ifx\next\bgroup
  \afterassignment\doinatreferenceonetwo
  \expandafter\leftreferencetoks
-   \else
+   \else\ifx\textofreference\empty
  \leftreferencetoks\emptytoks
- \expandafter\dodoinatreferencenone
-   \fi}
+ \expandafter\expandafter\expandafter\dodoinatreferencenone
+   \else
+ \leftreferencetoks{\textofreference}%
+ \expandafter\expandafter\expandafter\doinatreferenceonetwo
+   \fi\fi}
 
 \def\doinatreferenceonetwo
   {\futurelet\next\doinatreferencetwo}

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

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


Re: [NTG-context] referenceformat, text

2010-08-08 Thread Yury G. Kudryashov
Hans Hagen wrote:

 On 8-8-2010 2:44, Yury G. Kudryashov wrote:
 Hi!

 The following code:

 \definereferenceformat[lem][text=Lemma]
 \inlem[lem:mylemma]

 produces just a number, no Lemma  prefix. I've sent a patch to fix it a
 while ago. Could you please apply it, or tell me why you don't want to
 apply it?
 
 because it needs another patch, i'll look at it
It applies with some shift (GNU patch resolves this automatically), and 
works here.

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

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


Re: [NTG-context] referenceformat, text

2010-08-08 Thread Yury G. Kudryashov
Hans Hagen wrote:

 On 8-8-2010 7:19, Yury G. Kudryashov wrote:
 Hans Hagen wrote:

 On 8-8-2010 2:44, Yury G. Kudryashov wrote:
 Hi!

 The following code:

 \definereferenceformat[lem][text=Lemma]
 \inlem[lem:mylemma]

 produces just a number, no Lemma  prefix. I've sent a patch to fix it
 a while ago. Could you please apply it, or tell me why you don't want
 to apply it?

 because it needs another patch, i'll look at it
 It applies with some shift (GNU patch resolves this automatically), and
 works here.
 
 this is only one case (we also need labels, content, left and right to
 work ok)
At least left and right work ok without any patch.

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

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


Re: [NTG-context] two languages hyphenation

2010-06-25 Thread Yury G. Kudryashov
Hans Hagen wrote:

 On 25-6-2010 2:24, Mojca Miklavec wrote:
 Since they are written in two different scripts you can theoretically
 enable them simultaneously (but I'm not sure if this is supported by
 default).
 
 interesting and quite trivial to support ... do you have a test file?
I do.

% Just \usetypescript[xits] doesn't work for me (I have xits fonts in 
~/.fonts). Probably, it is already fixed in the latest beta.
\starttypescript [math] [xits] [name]
  \definefontsynonym[MathRoman][name:xitsmath] 
[features=math\mathsizesuffix]
\stoptypescript

\starttypescript [serif] [xits] [name]
  \definefontsynonym[Serif]  [name:xitsregular]
[features=default]
  \definefontsynonym[SerifBold]  [name:xitsbold]   
[features=default]
  \definefontsynonym[SerifItalic][name:xitsitalic] 
[features=default]
  \definefontsynonym[SerifBoldItalic][name:xitsbolditalic] 
[features=default]
\stoptypescript

\starttypescript[xits]
  \definetypeface [xits] [rm] [serif] [xits]   [default]
  \definetypeface [xits] [ss] [sans]  [heros]  [default] [rscale=0.9]
  \definetypeface [xits] [tt] [mono]  [modern] [default] [rscale=1.05]
  \definetypeface [xits] [mm] [math]  [xits]   [default]
\stoptypescript

\setupbodyfont[xits,12pt]

\starttext
% Hyphenated
{\language[ru]
\dorecurse{50}{русский текст }
}
% Not hyphenated
{\language[en]
\dorecurse{50}{русский текст }
}
% Not hyphenated
{\language[ru]
\dorecurse{50}{Multilingual }
}
% Hyphenated
{\language[en]
\dorecurse{50}{Multilingual }
}
\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  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Omitting hyphenation

2010-06-21 Thread Yury G. Kudryashov
Matija Šuklje wrote:

 Hullo,
 
 in Slovenian it's not allowed to word-wrap/hyphenate abbrevations. In the
 CV I'm writing right now, I have a few of those and they get hyphenated
 and broken.
 
 How can I tell that a single word/abbrevation should *not* be hyphenated
 and broken?
Try \hbox{word} (AFAIR, this is a plain TeX command)
 
 
 Cheers,
 Matija


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

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


Re: [NTG-context] References russian translation (Yury G. Kudryashov)

2010-06-19 Thread Yury G. Kudryashov
Vyatcheslav Yatskovsky wrote:

 References russian translation (Yury G. Kudryashov)
 
 What is Список літературі? In Ukrainian, it is Список літератури, if
 you meant this.
Thanks, I looked at Список літератури, typed Список літературі, and my 
wife (she is from Ukraine) haven't catched the typo.

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

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


[NTG-context] synctex and --result

2010-06-19 Thread Yury G. Kudryashov
Hi!

I try to use ConTeXt with synctex. I generate two versions of my paper, so I 
use --result option. Context renames the .pdf file, but not .synctex.gz, 
hence inverse search doesn't work. As a workaround, I renamed the draft for 
me version to the default output name.

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

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


Re: [NTG-context] References russian translation (Yury G. Kudryashov)

2010-06-19 Thread Yury G. Kudryashov
Vyatcheslav Yatskovsky wrote:

 Thanks for providing translations. )
 
 I also wonder why ru is specified in your code. Maybe ua (uk) ?
 % Список літератури
 \setupheadtext [\s!ru]
Copy+paste, forgotten to edit. Next time I will send just Russian, and 
you'll add Ukranian, OK (I'm from Russia, and don't speak Ukranian)?

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

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


Re: [NTG-context] synctex and --result

2010-06-19 Thread Yury G. Kudryashov
Hans Hagen wrote:

 On 19-6-2010 3:58, Yury G. Kudryashov wrote:
 Hi!

 I try to use ConTeXt with synctex. I generate two versions of my paper,
 so I use --result option. Context renames the .pdf file, but not
 .synctex.gz, hence inverse search doesn't work. As a workaround, I
 renamed the draft for me version to the default output name.
 
 indeed only the pdf,log,tuc files are renamed .. handling more is
 possible but i wonder where we will end then as there can be more such
 files
 
 i never use synctex but i suppose it's meant for a edit/preview cycle so
 normally one then deals with one file anyway
Yes. I had name-screen.pdf, name-print.pdf, name-draft.pdf and no name.pdf. 
I'll add you shouldn't use synctex with --result to wiki tomorrow.

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

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


[NTG-context] configure descriptions in place

2010-06-18 Thread Yury G. Kudryashov
Hi!

I have some lemmas with title, others without titles; some theorems should 
be numbered, others (e.g. cites from other articles) shouldn't. Is there any 
way to achieve this except for the following?

\defineenumeration[theorem][...]
\defineenumeration[exttheorem][theorem][number=no]

What do you think about the following syntax:

\definedescription[mydesc]

And after that

\startmydesc[label]
\stopmydesc

or

\startmydesc[title=yes][label]{md:a}
\stopmydesc

I think that it should not be hard to implement using \doifassignment, but I 
don't want to work on the patch that will be never accepted upstream.

P.S.: What about my patch for strc-ref that fixes 
\definereferenceformat[inlem][text=Lemma] ignoring text=?

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

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


[NTG-context] References russian translation

2010-06-18 Thread Yury G. Kudryashov
Hi!

Could you please add the following to lang-cyr.tex:

% Список литературы
\setupheadtext [\s!ru][pubs=\cyrillicS \cyrillicp \cyrillici
  \cyrillics \cyrillico \cyrillick
  \space \cyrillicl \cyrillici
  \cyrillict \cyrillice \cyrillicr
  \cyrillica \cyrillict \cyrillicu
  \cyrillicr \cyrillicery]
% Список літературі
\setupheadtext [\s!ru][pubs=\cyrillicS \cyrillicp \cyrillici
  \cyrillics \cyrillico \cyrillick
  \space \cyrillicl \cyrillicii
  \cyrillict \cyrillice \cyrillicr
  \cyrillica \cyrillict \cyrillicu
  \cyrillicr \cyrillicii]

BTW, what is the policy for replacing lang-*.tex with lang-*.mkii and lang-
*.mkiv? I'd prefer to type translations in unicode, not with commands like 
this.

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

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


Re: [NTG-context] Indent in publication list

2010-06-18 Thread Yury G. Kudryashov
richard.steph...@converteam.com wrote:

The cite is removed because the original message was HTML only. Please, 
never use HTML only messages.

Try
\setuppublicationlist[width=5mm]

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

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


[NTG-context] bibtex sort mkiv

2010-06-12 Thread Yury G. Kudryashov
Hi!

I try to sort my bibliography by athor:

\setupbibtex[database=these.bib,sort=author]
\setuppublications[numbering=yes,sorttype=bbl]
\starttext
\completepublications
\stoptext

The .bbl file is sorted, but references in the resulting .pdf are sorted in 
citation order.

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

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


[NTG-context] ↦ in xits

2010-06-12 Thread Yury G. Kudryashov
Hi!

I use $x↦2x$ in xits, and it prints x→2x instead of x↦2x. The same file 
works with latin modern. It seems that xits-math contains U+21A6 (↦) symbol 
(at least, kcharselect displays this character in xits-math font), so it 
should be related to some meta-information.

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

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


Re: [NTG-context] ↦ in xits

2010-06-12 Thread Yury G. Kudryashov
Khaled Hosny wrote:

 On Sat, Jun 12, 2010 at 01:19:08PM +0400, Yury G. Kudryashov wrote:
 Hi!
 
 I use $x↦2x$ in xits, and it prints x→2x instead of x↦2x. The same file
 works with latin modern. It seems that xits-math contains U+21A6 (↦)
 symbol (at least, kcharselect displays this character in xits-math font),
 so it should be related to some meta-information.
 
 ConTeXt try to compose U+21A6 from base part and the regular right arrow
 (U+2192), since that base part seems to be some un-encoded, Latin Modern
 specific glyph, you get only U+2192 with XITS.
Where can I find this in the source code?
 
 Ideally, it should be done the other way around, fake U+21A6 in Latin
 Modern virtual font and then use the proper code point everywhere (may
 be this what is actually done but I misinterpreted it).
 


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

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


Re: [NTG-context] error in first-setup.sh

2010-06-09 Thread Yury G. Kudryashov
Mojca Miklavec wrote:

 On Tue, Jun 8, 2010 at 16:50, Yury G. Kudryashov ur...@ya.ru wrote:
 Taco Hoekwater wrote:

 luigi scarso wrote:
 On my linux box32bit
 $bash first-setup.sh

 stops with
 Beta is a tad unstable at the moment, should be better in an hour or so.
 It seems that the real problem is in setup/linux-64/bin files which are
 rsync'ed by first-run.sh before running mtxrun. So, it is not even
 possible to install an old ConTeXt using minimals.
 
 It should be fixed soon (Hans already sent a patch that fixes it), but
 in the meantime you may comment out the line that syncs mtxrun and
 take an older mtxrun.lua - mtxrun from archive (for example from
 current).
 
 I'm a bit afraid that the new texmfcnf.lua that is needed will break
 the current though.
Yes, it breaks current. Could you please either fix it in beta, or post 
the patch to ML?

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

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


Re: [NTG-context] error in first-setup.sh

2010-06-08 Thread Yury G. Kudryashov
Taco Hoekwater wrote:

 luigi scarso wrote:
 On my linux box32bit
 $bash first-setup.sh
 
 stops with
 Beta is a tad unstable at the moment, should be better in an hour or so.
It seems that the real problem is in setup/linux-64/bin files which are 
rsync'ed by first-run.sh before running mtxrun. So, it is not even possible 
to install an old ConTeXt using minimals.

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

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


Re: [NTG-context] Cyrillic in Mark IV

2010-06-07 Thread Yury G. Kudryashov
Wolfgang Schuster wrote:

 Am 06.06.10 09:55, schrieb Yury G. Kudryashov:
 Hi!

 How can I typeset Russian in Mark IV? None of the examples from wiki
 work. I found TeXGyre and (no) Cyrillic thread, but there are no
 instructions, just Cyrillic doesn't work with TeXGyre anymore.

 
 You need a font with cyrillic glyphs, e.g. when you have microsofts core
 fonts
 installed this example works:
 
 \setupbodyfont[mscore]
 \starttext
 Немного русского текста для пробы.
 \stoptext
Thanks, this works but I don't like this font, and it breaks some math 
symbols. It would be nice to be able to use, for example, the same font 
LaTeX+babel use by default (btw, is it cm-unicode?).

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

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


Re: [NTG-context] referenceformat MkIV

2010-06-07 Thread Yury G. Kudryashov
taco wrote:

 
 Hi,
 
 Yury G. Kudryashov wrote:
 Another problem fixed by my patch:
 
 \definereferenceformat[ineq][text=equation]
 \starttext
 \placeformula[first]
 \startformula 1=1\stopformula
 \ineq[first]
 \stoptext
 printed 1, not equation 1.
 
 This problem is still there and needs fixing, but I think your patch
 has a bug (possibly because of the already done other bugfix).
 
 After patching, I think \doinatreferenceone should look like
 this:
 
 \def\doinatreferenceone
{\ifx\next\bgroup
   \afterassignment\doinatreferenceonetwo
   \expandafter\leftreferencetoks
 \else\ifx\textofreference\empty
   \leftreferencetoks\emptytoks
   \expandafter\expandafter\expandafter\dodoinatreferencenone
 \else
   \leftreferencetoks{\textofreference}%
   \expandafter\expandafter\expandafter\doinatreferenceonetwo
 \fi\fi}
Yes, this \doinatreference (with 3 \expandafter) works for me in the latest 
beta. Could you please replace current \doinatreference with this one?

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

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


[NTG-context] Cyrillic in Mark IV

2010-06-06 Thread Yury G. Kudryashov
Hi!

How can I typeset Russian in Mark IV? None of the examples from wiki work. I 
found TeXGyre and (no) Cyrillic thread, but there are no instructions, 
just Cyrillic doesn't work with TeXGyre anymore.

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

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


Re: [NTG-context] ConTeXt unit testing

2010-06-06 Thread Yury G. Kudryashov
Taco Hoekwater wrote:

 Mojca Miklavec wrote:
 On Sun, Jun 6, 2010 at 11:05, Taco Hoekwater wrote wrote:
 Mojca Miklavec wrote:
 On Sat, Jun 5, 2010 at 17:13, Yury G. Kudryashov wrote:
 Are there any automatic unit test for ConTeXt distribution?
 I'm thinking that we might want to set up one on a server.
 We already have a server for tests:

  http://foundry.supelec.fr/gf/project/contexttest/
 
 Yes, but some metadata is missing and some architecture to actually
 run those tests (some tests only make sense in MKII and some only in
 MKIV etc.).
 
 I would definitely prefer if some function run_the_unit_tests
 existed, but we probably need to write one first.
 
 Just saying there is no need for yet another server  (you cannot
 run tests server-side anyway).

Why? I was talking about fully automatic tests, not tests like compile and 
open result in the viewer. I understand that there is not too much 
functionality that can be tested automatically (hence, server-side), but at 
least some basic things can be tested.

Probably, more features can be tested server-side analyzing the result pdf 
file using some library (though I don't know the pdf-parsing libraries 
sufficiently good to implement it).

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

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


Re: [NTG-context] Removing Introduction section number

2010-06-06 Thread Yury G. Kudryashov
Vyatcheslav Yatskovsky wrote:

 Hello,
 
 It might be 100 time this question appears on the list, but I cannot
 find the answer.
 
 I need Introduction to have no number, and next section to have number
 1, so on. My current solution gives me number 2, instead.
There are two cases:
1. You want Introduction in the table of contents. Then you should copy 
section to another head, and setup it with number=no (have no time to test):

\definehead[secnonum][section]
\setuphead[secnonum][number=no]
\secnonum{Introduction}

2. You don't want Intruduction in the table of contents. Then just use 
\subject{Introduction}.

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

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


[NTG-context] dodosetreference undefined

2010-06-05 Thread Yury G. Kudryashov
Hi!

\dodosetreference is not defined, but \dododosetreference is defined twice 
in strc-ref.mkiv. This breaks \pagereference, hence t-fixme. I think that 
the first definition should be replaced with \def\dodosetreference.

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

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


[NTG-context] ConTeXt unit testing

2010-06-05 Thread Yury G. Kudryashov
Hi!

Are there any automatic unit test for ConTeXt distribution? At least the bug 
with referenceformat can be catched using something like

context test
pdftotext test.pdf test.txt
diff test.txt test.txt-good

And the bug with broken footnote can be catched using just context test.

If there are unit test, where can I find them (I'd like to add more)?
If there are no, any objections against adding them, and testing before 
releasing new beta?

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

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


Re: [NTG-context] Wrong spacing before and after commas in math(?)

2010-06-04 Thread Yury G. Kudryashov
Aditya Mahajan wrote:

 On Fri, 4 Jun 2010, Stefan Müller wrote:
 
 if I'm typesetting for example $(a,x,\dots,b)$ I see that the space
 before the x is too small.
 Does
 
 \setupmathematics[autopunctuation=no] % or yes
 
 give better result? (Are you using MKIV or MKII)?
I had a similar issue with MKIV. autopunctuation=no fixed it for me.


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

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


[NTG-context] links generated by \in don't work

2010-06-03 Thread Yury G. Kudryashov
Hi!

I try the following with current beta:

\setupinteraction[state=start]
\starttext
\placeformula[eq:test]
\startformula
1=1
\stopformula
\pagebreak
\in[eq:test]
\stoptext

When I click on the link, nothing happens. The links generated by 
LaTeX+hyperref work in the same viewer (okular, poppler based).

Sometimes links work, but point me to the page instead of specific location 
(e.g. theorem, lemma, etc.).

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

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


Re: [NTG-context] links generated by \in don't work

2010-06-03 Thread Yury G. Kudryashov
luigi scarso wrote:

 On Thu, Jun 3, 2010 at 5:32 PM, Yury G. Kudryashov ur...@ya.ru wrote:
 Hi!

 I try the following with current beta:

 \setupinteraction[state=start]
 \starttext
 \placeformula[eq:test]
 \startformula
 1=1
 \stopformula
 \pagebreak
 \in[eq:test]
 \stoptext

 When I click on the link, nothing happens. The links generated by
 LaTeX+hyperref work in the same viewer (okular, poppler based).
 true: it works ok with mkii.
I forgotten to say that I try this in mkiv.

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

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


Re: [NTG-context] referenceformat MkIV

2010-05-31 Thread Yury G. Kudryashov
Yury G. Kudryashov wrote:

 Hi!
 
 I try the following:
 
 \definereferenceformat[ineq][left=(,right=),text=Equation]
 \starttext
 \placeformula[first]
 \startformula
 2=2
 \stopformula
 In \in[first] ineq \ineq[first] in \in[first].
 \stoptext
 
 The result is:
 2 = 2 (1)
 In 1 ineq (1) in (1).
 
 It seems that \ineq doesn't clear some variables, and the next \in uses
 the previous format.

Please, apply the attached patch upstream. It fixed the problem for me.

Another problem fixed by my patch:

\definereferenceformat[ineq][text=equation]
\starttext
\placeformula[first]
\startformula 1=1\stopformula
\ineq[first]
\stoptext
printed 1, not equation 1.--- a/tex/texmf-context/tex/context/base/strc-ref.mkiv	2010-05-21 15:44:04.0 +0400
+++ b/tex/texmf-context/tex/context/base/strc-ref.mkiv	2010-05-31 22:18:38.0 +0400
@@ -983,10 +983,13 @@
   {\ifx\next\bgroup
  \afterassignment\doinatreferenceonetwo
  \expandafter\leftreferencetoks
-   \else
+   \else\ifx\textofreference\empty
  \leftreferencetoks\emptytoks
  \expandafter\dodoinatreferencenone
-   \fi}
+   \else
+ \leftreferencetoks{\textofreference}%
+ \expandafter\doinatreferenceonetwo
+   \fi\fi}
 
 \def\doinatreferenceonetwo
   {\futurelet\next\doinatreferencetwo}
@@ -1022,7 +1025,11 @@
\doifreferencefoundelse{#4}
  {\doifelsenothing{#1}\dosymbolreference\dowantedreference{#1}{#2}[#4]}%
  {\dounknownreference{#1}{#2}[#4]}%
-   \endgroup}
+   \endgroup%
+   \global\let\leftofreference\relax
+   \global\let\rightofreference\relax
+   \global\let\textofreference\empty
+   }
 
 \let\dosymbolreference\dowantedreference
 

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

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


Re: [NTG-context] referenceformat MkIV

2010-05-31 Thread Yury G. Kudryashov
taco wrote:

 
 Hi,
 Yury G. Kudryashov wrote:
 It seems that \ineq doesn't clear some variables, and the next \in uses
 the previous format.
 Please, apply the attached patch upstream. It fixed the problem for me.
 This problem was already fixed in the latest (internal?) beta.
I shall test once this beta will be published.
 Another problem fixed by my patch:
 
 \definereferenceformat[ineq][text=equation]
 \starttext
 \placeformula[first]
 \startformula 1=1\stopformula
 \ineq[first]
 \stoptext
 printed 1, not equation 1.
 
 This problem is still there and needs fixing, but I think your patch
 has a bug (possibly because of the already done other bugfix).
 
 After patching, I think \doinatreferenceone should look like
 this:
 
 \def\doinatreferenceone
{\ifx\next\bgroup
   \afterassignment\doinatreferenceonetwo
   \expandafter\leftreferencetoks
 \else\ifx\textofreference\empty
   \leftreferencetoks\emptytoks
   \expandafter\expandafter\expandafter\dodoinatreferencenone
 \else
   \leftreferencetoks{\textofreference}%
   \expandafter\expandafter\expandafter\doinatreferenceonetwo
 \fi\fi}
With published beta, I didn't need these \expandafter, but probably I missed 
some corner case, or they're needed with your internal fix.

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

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


Re: [NTG-context] unicode subscripts

2010-05-30 Thread Yury G. Kudryashov
Hans Hagen wrote:

 On 29-5-2010 6:58, Yury G. Kudryashov wrote:
 Hi!

 Unicode subscripts do not work (at least, in math):

 P.S.: Superscript digits work. Probably, the font contains ¹ but not ₁.
 
 in which case ... do you expect that glyph? or maybe one special for
 math? and does its size match the other superscripts that are not in the
 font? these super/sub things are historic ballast and not that useful
 
 anyhow, attached a way to deal with it in your document, but you have to
 load it explicitly with \usemodule[mathcrap]
OK, I shall replace all unicode sub/sup scripts with _ and ^.

Is it possible to print some warnings/errors for such crappy characters? As 
a user, I don't know in advance which characters are crappy.

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

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


[NTG-context] unicode integral sign

2010-05-29 Thread Yury G. Kudryashov
Hi!

I try the following:

\starttext
$∫_a^b \int_a^b$
\stoptext

In the first case, the integral sign is below the text. Should I use another 
font, or is it possible to fix with the default one?

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

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


[NTG-context] referenceformat MkIV

2010-05-29 Thread Yury G. Kudryashov
Hi!

I try the following:

\definereferenceformat[ineq][left=(,right=),text=Equation]
\starttext
\placeformula[first]
\startformula
2=2
\stopformula
In \in[first] ineq \ineq[first] in \in[first].
\stoptext

The result is:
2 = 2 (1)
In 1 ineq (1) in (1).

It seems that \ineq doesn't clear some variables, and the next \in uses the 
previous format.

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

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


Re: [NTG-context] unicode integral sign

2010-05-29 Thread Yury G. Kudryashov
Taco Hoekwater wrote:

 Yury G. Kudryashov wrote:
 Hi!
 
 I try the following:
 
 \starttext
 $∫_a^b \int_a^b$
 \stoptext
 
 In the first case, the integral sign is below the text. Should I use
 another font, or is it possible to fix with the default one?
 
 It is possible to fix this. The reason for the odd placement is that the
 'math code' of ∫ is not set up properly (and it probably isn't either
 for some other bare Unicode characters). To fix the hard way, add this
 at the top of your input file:
 
 \Umathcode `∫ = 1 0 `∫ % 1 == \mathop, 0=fam0, ∫=glyph
Is there any documentation on char-def.lua file format? If I'll understand 
it, I'll send a patch for the symbols I use.

Currently I have no idea why the following strings in char-def don't work.

[0x222B]={
  adobename=integral,
  category=sm,
  cjkwd=a,
  description=INTEGRAL,
  direction=on,
  linebreak=ai,
  mathspec={
{ class=nothing, name=intop },
{ class=limop  , name=int   },
  },
  unicodeslot=0x222B,
 },

Replacing mathspec=... with mathclass=limop, mathname=int seems to work 
(copied from n-ary summation).

BTW, in both solution ∫_a acts like \int\limits_a, not \int_a.

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

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


[NTG-context] unicode subscripts

2010-05-29 Thread Yury G. Kudryashov
Hi!

Unicode subscripts do not work (at least, in math):

\starttext
$a₀₁₂₃₄₅₆₇₈₉₋₌₊$
\stoptext

prints only a. The file char-def.lua contains block like this:
 [0x2080]={
  category=no,
  description=SUBSCRIPT ZERO,
  direction=en,
  linebreak=al,
  specials={ sub, 0x0030 },
  unicodeslot=0x2080,
 },

Which file should handle this specials={ sub, 0x0030 }?

P.S.: Superscript digits work. Probably, the font contains ¹ but not ₁.

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

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


[NTG-context] margin notes

2010-05-28 Thread Yury G. Kudryashov
Hi!

I try to use \inmargin{some text} in context Mk IV, and the resulting margin 
notes overlap. Is there any way to emulate LaTeX's marginpars (they're 
considered floats, hence can be moved to avoid overlaps)?

Minimal example:
\starttext
\inmargin{first}
\inmargin{second}
\stoptext
-- 
Yury G. Kudryashov


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

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


Re: [NTG-context] margin notes

2010-05-28 Thread Yury G. Kudryashov
Wolfgang Schuster wrote:

 Am 28.05.10 19:02, schrieb Yury G. Kudryashov:
 Hi!

 I try to use \inmargin{some text} in context Mk IV, and the resulting
 margin notes overlap. Is there any way to emulate LaTeX's marginpars
 (they're considered floats, hence can be moved to avoid overlaps)?
 \setupinmargin[stack=yes]
Thanks, it works!

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

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


[NTG-context] subformulas numbering doesn't work

2010-05-15 Thread Yury G. Kudryashov
Hi!

The following example from http://wiki.contextgarden.net/Math/Display#Sub-
Formula_Numbering doesn't work in MKIV:

\startsubformulas[eq:1]
\placeformula[eq:first]
\startformula
  c^2 = a^2 + b^2
\stopformula
\placeformula[eq:second]
\startformula
c^2 = a^2 + b^2
\stopformula
\stopsubformulas
Formula (\in[eq:1]) states 
the Pythagora's Theorem twice,
once in (\in[eq:first]) and 
again in (\in[eq:second]).

It produces formulas (1.a) and (2).

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

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


Re: [NTG-context] Installing minimals

2009-10-09 Thread Yury G. Kudryashov
В сообщении от 9 октября 2009 21:10:19 автор Hans Hagen написал:
 Alain Delmotte wrote:
 just add
 
 \syntex=1
SyncTeX docs say \synctex=1
 
 in your source

-- 
Yury G. Kudryashov,
mailto: urkud.ur...@gmail.com


signature.asc
Description: This is a digitally signed message part.
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

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


[NTG-context] subformulas end theorems in Mark IV

2009-09-15 Thread Yury G. Kudryashov
Hello!

I've tried the following example (from wiki):
\starttext
\startsubformulas[eq:1]
\placeformula[eq:first]
\startformula
  c^2 = a^2 + b^2
  \stopformula

  \placeformula[eq:second]
  \startformula
  c^2 = a^2 + b^2
  \stopformula
  \stopsubformulas
  Formula (\in[eq:1]) states
  the Pythagora's Theorem twice,
  once in (\in[eq:first]) and
  again in (\in[eq:second]).
\stoptext

I get Formula (??) states the Pythagora's Theorem twice, once in (1) and 
again in (2). In log I see 'unknown reference [][eq:1]'.

I also have label/ref problem with theorems. I define
\defineenumeration[theorem][text=Theorem,location=serried,right=.]
Later I use \starttheorem[thm:bony:random:open] ... \stoptheorem, \in{theorem}
[thm:bony:random:open], and get just 'theorem' instead of 'theorem 1'.
-- 
Yury G. Kudryashov,
mailto: urkud.ur...@gmail.com
___
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
___