Re: [NTG-context] \writetolist command...

2016-03-04 Thread Willi Egger
Hans, thank you for your tip!

Willi
> On 4 mrt. 2016, at 12:08, Hans Hagen <pra...@wxs.nl> wrote:
> 
> On 3/4/2016 5:37 AM, Willi Egger wrote:
>> Hi all,
>> 
>> I need to write to a list, however it appears that the second argument from 
>> \writetolist[name]{number}{ext} does not end up in the list. — What do I 
>> miss?
>> 
>> \starttext
>>  \startsubject[title=Contents]
>>  \placelist[section][criterium=all]
>>  \stopsubject
>> 
>>  \startsubject[title=A Paragraph as Subject]
>>  \writetolist[section]{1}{Writetolist: Subject title}
>>  \stopsubject
>> \stoptext
> 
> headnumber=always
> 
> 
> -
>  Hans Hagen | PRAGMA ADE
>  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
>  tel: 038 477 53 69 | www.pragma-ade.com | www.pragma-pod.nl
> -
> ___
> If your question is of interest to others as well, please add an entry to the 
> Wiki!
> 
> maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
> archive  : http://foundry.supelec.fr/projects/contextrev/
> wiki : http://contextgarden.net
> ___

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

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

Re: [NTG-context] \writetolist command...

2016-03-04 Thread Hans Hagen

On 3/4/2016 5:37 AM, Willi Egger wrote:

Hi all,

I need to write to a list, however it appears that the second argument from 
\writetolist[name]{number}{ext} does not end up in the list. — What do I miss?

\starttext
\startsubject[title=Contents]
\placelist[section][criterium=all]
\stopsubject

\startsubject[title=A Paragraph as Subject]
\writetolist[section]{1}{Writetolist: Subject title}
\stopsubject
\stoptext


headnumber=always


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

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

[NTG-context] \writetolist command...

2016-03-03 Thread Willi Egger
Hi all,

I need to write to a list, however it appears that the second argument from 
\writetolist[name]{number}{ext} does not end up in the list. — What do I miss?

\starttext
\startsubject[title=Contents]
\placelist[section][criterium=all]
\stopsubject

\startsubject[title=A Paragraph as Subject]
\writetolist[section]{1}{Writetolist: Subject title}
\stopsubject
\stoptext

Kind regards

Willi
___
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] Regression with \doboundtext in \writetolist

2015-10-11 Thread Hans Hagen

On 10/11/2015 5:21 AM, Rik Kabel wrote:

The following example works with older versions of ConTeXt, such as the
version from 20150325 in my repository. It fails with TL15 and later,
including the current standalone beta.

% macros=mkvi
\setwidthof {99}\to\IDWidth\relax
\def\STWidth{\dimexpr\textwidth-\IDWidth+1cm}
\definelist[OList]
\setuplist
[OList][criterium=all,alternative=c,pagecommand=\gobbleoneargument]

\starttexdefinition OLister #ID#String
{\writetolist[OList]{}{\hbox{\simplealignedbox{\IDWidth}{left}{#ID\quad}
{\doboundtext{#String}{\STWidth}{…}
\stoptexdefinition

\starttext
\OLister1{Some list testing text xxx xxx xxx xxx xxx xxx xxx xxx xxx
xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx}
\OLister2{Yet another list testing text xxx xxx xxx xxx xxx xxx xxx
xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx}
\OLister3{A list testing text xxx xxx xxx xxx xxx xxx xxx xxx xxx
xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx}
\OLister4{Different list testing text xxx xxx xxx xxx xxx xxx xxx
xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx}
\subject{List half width}
\startcolumns[n=2]
\placelist[OList]
\stopcolumns
\stoptext

With the 20150325 ConTeXt, there are .tuc file entries like:

["second"]="\\hbox {\\simplealignedbox {\\IDWidth
}{left}{2\\quad }{\\doboundtext {Yet another list testing text xxx
xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx
xxx}{\\STWidth }{…}}}",

but with more recent versions, the corresponding entry is:

["second"]="\\hbox {\\simplealignedbox {12.6pt}{left}{2\\quad
}{\\hbox {\\setbox \\scratchbox \\hbox {Yet another list testing
text xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx
xxx xxx}\\scratchdimen \\dimexpr \\textwidth -12.6pt+1cm\\relax
\\box \\scratchbox }}}",



\unexpanded\def\STWidth{\dimexpr\textwidth-\IDWidth+1cm}

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

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

Re: [NTG-context] Regression with \doboundtext in \writetolist

2015-10-11 Thread Wolfgang Schuster

Rik Kabel <mailto:cont...@rik.users.panix.com>
11. Oktober 2015 um 18:25
On 2015-10-11 06:11, Hans Hagen wrote:

On 10/11/2015 5:21 AM, Rik Kabel wrote:

The following example works with older versions of ConTeXt, such as the
version from 20150325 in my repository. It fails with TL15 and later,
including the current standalone beta.

% macros=mkvi
\setwidthof {99}\to\IDWidth\relax
\def\STWidth{\dimexpr\textwidth-\IDWidth+1cm}
\definelist[OList]
\setuplist
[OList][criterium=all,alternative=c,pagecommand=\gobbleoneargument]

\starttexdefinition OLister #ID#String
    
{\writetolist[OList]{}{\hbox{\simplealignedbox{\IDWidth}{left}{#ID\quad} 


{\doboundtext{#String}{\STWidth}{…}
\stoptexdefinition

\starttext
\OLister1{Some list testing text xxx xxx xxx xxx xxx xxx xxx xxx 
xxx

xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx}
\OLister2{Yet another list testing text xxx xxx xxx xxx xxx xxx xxx
xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx}
\OLister3{A list testing text xxx xxx xxx xxx xxx xxx xxx xxx xxx
xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx}
\OLister4{Different list testing text xxx xxx xxx xxx xxx xxx xxx
xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx}
\subject{List half width}
\startcolumns[n=2]
\placelist[OList]
\stopcolumns
\stoptext

With the 20150325 ConTeXt, there are .tuc file entries like:

["second"]="\\hbox {\\simplealignedbox {\\IDWidth
}{left}{2\\quad }{\\doboundtext {Yet another list testing text xxx
xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx
xxx}{\\STWidth }{…}}}",

but with more recent versions, the corresponding entry is:

["second"]="\\hbox {\\simplealignedbox {12.6pt}{left}{2\\quad
}{\\hbox {\\setbox \\scratchbox \\hbox {Yet another list testing
text xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx 
xxx

xxx xxx}\\scratchdimen \\dimexpr \\textwidth -12.6pt+1cm\\relax
\\box \\scratchbox }}}",



\unexpanded\def\STWidth{\dimexpr\textwidth-\IDWidth+1cm}

Yes, expansion needs to be delayed to get the current dimension when 
the list is placed. My error—thank you for the correction. But the 
regression is not resolved. The .tuc file now contains:


["second"]="\\hbox {\\simplealignedbox {12.6pt}{left}{2\\quad
}{\\hbox {\\setbox \\scratchbox \\hbox {Yet another list testing
text xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx
xxx xxx xxx}\\scratchdimen \\STWidth \\relax \\box \\scratchbox }}}",

Still no mention of dobounded text is carried into the list.
Is \limitatetext a option for you because unlike \doboundtext the 
command is unexpandable?


\starttext

\doboundtext {Thus, I came to the conclusion that the designer of a new 
system ...}{.5\textwidth}{...}


\limitatetext{Thus, I came to the conclusion that the designer of a new 
system ...}{.5\textwidth}{...}


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

Re: [NTG-context] Regression with \doboundtext in \writetolist

2015-10-11 Thread Rik

On 2015-10-11 12:56, Wolfgang Schuster wrote:
Is \limitatetext a option for you because unlike \doboundtext the 
command is unexpandable?


\starttext

\doboundtext {Thus, I came to the conclusion that the designer of a 
new system ...}{.5\textwidth}{...}


\limitatetext{Thus, I came to the conclusion that the designer of a 
new system ...}{.5\textwidth}{...}


\stoptext

Is it an option of which I am aware, yes. Do I desire to use it, no. 
Will I use it? Perhaps, if \doboundtext cannot be repaired. The 
resulting page with \limitatetext has large rivers of white on the page.


But more likely I will look for a hack to use \doboundtext to trim the 
text before writing it to the list, even though it loses the flexibility 
of computing the width dynamically.


Can you point to what changed between the 20150325 version and TL15 to 
break this?


--
Rik
___
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] Regression with \doboundtext in \writetolist

2015-10-11 Thread Rik Kabel

On 2015-10-11 06:11, Hans Hagen wrote:

On 10/11/2015 5:21 AM, Rik Kabel wrote:

The following example works with older versions of ConTeXt, such as the
version from 20150325 in my repository. It fails with TL15 and later,
including the current standalone beta.

% macros=mkvi
\setwidthof {99}\to\IDWidth\relax
\def\STWidth{\dimexpr\textwidth-\IDWidth+1cm}
\definelist[OList]
\setuplist
[OList][criterium=all,alternative=c,pagecommand=\gobbleoneargument]

\starttexdefinition OLister #ID#String
{\writetolist[OList]{}{\hbox{\simplealignedbox{\IDWidth}{left}{#ID\quad}
{\doboundtext{#String}{\STWidth}{…}
\stoptexdefinition

\starttext
\OLister1{Some list testing text xxx xxx xxx xxx xxx xxx xxx xxx xxx
xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx}
\OLister2{Yet another list testing text xxx xxx xxx xxx xxx xxx xxx
xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx}
\OLister3{A list testing text xxx xxx xxx xxx xxx xxx xxx xxx xxx
xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx}
\OLister4{Different list testing text xxx xxx xxx xxx xxx xxx xxx
xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx}
\subject{List half width}
\startcolumns[n=2]
\placelist[OList]
\stopcolumns
\stoptext

With the 20150325 ConTeXt, there are .tuc file entries like:

["second"]="\\hbox {\\simplealignedbox {\\IDWidth
}{left}{2\\quad }{\\doboundtext {Yet another list testing text xxx
xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx
xxx}{\\STWidth }{…}}}",

but with more recent versions, the corresponding entry is:

["second"]="\\hbox {\\simplealignedbox {12.6pt}{left}{2\\quad
}{\\hbox {\\setbox \\scratchbox \\hbox {Yet another list testing
text xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx
xxx xxx}\\scratchdimen \\dimexpr \\textwidth -12.6pt+1cm\\relax
\\box \\scratchbox }}}",



\unexpanded\def\STWidth{\dimexpr\textwidth-\IDWidth+1cm}

Yes, expansion needs to be delayed to get the current dimension when the 
list is placed. My error—thank you for the correction. But the 
regression is not resolved. The .tuc file now contains:


   ["second"]="\\hbox {\\simplealignedbox {12.6pt}{left}{2\\quad
   }{\\hbox {\\setbox \\scratchbox \\hbox {Yet another list testing
   text xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx
   xxx xxx}\\scratchdimen \\STWidth \\relax \\box \\scratchbox }}}",

Still no mention of dobounded text is carried into the list.
--
Rik
___
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] Regression with \doboundtext in \writetolist

2015-10-11 Thread Wolfgang Schuster

Rik 
11. Oktober 2015 um 21:20
On 2015-10-11 12:56, Wolfgang Schuster wrote:
Is it an option of which I am aware, yes. Do I desire to use it, no. 
Will I use it? Perhaps, if \doboundtext cannot be repaired. The 
resulting page with \limitatetext has large rivers of white on the page.


But more likely I will look for a hack to use \doboundtext to trim the 
text before writing it to the list, even though it loses the 
flexibility of computing the width dynamically.

Adding \noexpand before \doboundtext should work.

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

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

Re: [NTG-context] Regression with \doboundtext in \writetolist

2015-10-11 Thread Rik Kabel

On 2015-10-11 15:41, Wolfgang Schuster wrote:

Rik 
11. Oktober 2015 um 21:20
On 2015-10-11 12:56, Wolfgang Schuster wrote:
Is it an option of which I am aware, yes. Do I desire to use it, no. 
Will I use it? Perhaps, if \doboundtext cannot be repaired. The 
resulting page with \limitatetext has large rivers of white on the page.


But more likely I will look for a hack to use \doboundtext to trim 
the text before writing it to the list, even though it loses the 
flexibility of computing the width dynamically.

Adding \noexpand before \doboundtext should work.

Wolfgang


Indeed, it does. Thank you.

--
Rik
___
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] Regression with \doboundtext in \writetolist

2015-10-10 Thread Rik Kabel
The following example works with older versions of ConTeXt, such as the 
version from 20150325 in my repository. It fails with TL15 and later, 
including the current standalone beta.


   % macros=mkvi
   \setwidthof {99}\to\IDWidth\relax
   \def\STWidth{\dimexpr\textwidth-\IDWidth+1cm}
   \definelist[OList]
   \setuplist
   [OList][criterium=all,alternative=c,pagecommand=\gobbleoneargument]

   \starttexdefinition OLister #ID#String
   {\writetolist[OList]{}{\hbox{\simplealignedbox{\IDWidth}{left}{#ID\quad}
   {\doboundtext{#String}{\STWidth}{…}
   \stoptexdefinition

   \starttext
   \OLister1{Some list testing text xxx xxx xxx xxx xxx xxx xxx xxx xxx
   xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx}
   \OLister2{Yet another list testing text xxx xxx xxx xxx xxx xxx xxx
   xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx}
   \OLister3{A list testing text xxx xxx xxx xxx xxx xxx xxx xxx xxx
   xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx}
   \OLister4{Different list testing text xxx xxx xxx xxx xxx xxx xxx
   xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx}
   \subject{List half width}
   \startcolumns[n=2]
   \placelist[OList]
   \stopcolumns
   \stoptext

With the 20150325 ConTeXt, there are .tuc file entries like:

   ["second"]="\\hbox {\\simplealignedbox {\\IDWidth
   }{left}{2\\quad }{\\doboundtext {Yet another list testing text xxx
   xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx
   xxx}{\\STWidth }{…}}}",

but with more recent versions, the corresponding entry is:

   ["second"]="\\hbox {\\simplealignedbox {12.6pt}{left}{2\\quad
   }{\\hbox {\\setbox \\scratchbox \\hbox {Yet another list testing
   text xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx xxx
   xxx xxx}\\scratchdimen \\dimexpr \\textwidth -12.6pt+1cm\\relax
   \\box \\scratchbox }}}",

--
Rik
___
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] \writetolist in mkiv

2014-10-13 Thread Jano Kula

Thank you, Wolfgang, here is the working example for the structure manual ;)

% \writetolist  local table of contents example
\def\ManualSubsection#1{\blank%
{\bf Manual Subsection #1}\par%
\writetolist[subsection]{}{Manual Subsection #1}%
\input tufte\relax}

\starttext
\dorecurse{3}{%
\startchapter[title=Chapter]
\placelist[section][criterium=chapter]
\startsection[title=Section]
\placelist[subsection][criterium=section]
\ManualSubsection{\recurselevel-1}
\ManualSubsection{\recurselevel-2}
\stopsection
\startsection[title=Section]
\placelist[subsection][criterium=section]
\ManualSubsection{\recurselevel-1}
\ManualSubsection{\recurselevel-2}
\stopsection
\stopchapter}
\stoptext




On 12.10.2014 23:06, Wolfgang Schuster wrote:


Am 12.10.2014 um 22:57 schrieb Jano Kula jano.k...@gmail.com:


Hello Wolfgang,

On 12.10.2014 21:28, Wolfgang Schuster wrote:


Am 12.10.2014 um 20:39 schrieb Jano Kula jano.k...@gmail.com:


Hello to everybody!

Minimal story
-
How to insert local TOC of manually created subsections after the section 
starts?

% start minimal example
\def\ManualSubsection#1{\blank%
{\bf Manual Subsection #1}\par%
\writetolist[subsection]{whatever}{Manual Subsection #1}%
\input tufte\relax}

\starttext
\dorecurse{3}{%
\startchapter[title=Chapter]
\placecontent[chapter,criterium=local] % local TOC OK


You can’t put a keyword (chapter) and a assignment (criterium=local) in the 
same argument
of a setup-command, what you’re looking for is 
\placelist[chapter][criterium=local].

Wolfgang


Thanks, got it: \placelist[section][criterium=local] places the list of 
sections included in the chapter.

Still, how to do the same with subsections manually inserted by 
\writetolist[subsection]{}{Subsection title}?


\placelist[subsection][criterium=section]

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

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



___
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] \writetolist in mkiv

2014-10-12 Thread Jano Kula

Hello to everybody!

Minimal story
-
How to insert local TOC of manually created subsections after the 
section starts?


% start minimal example
\def\ManualSubsection#1{\blank%
{\bf Manual Subsection #1}\par%
\writetolist[subsection]{whatever}{Manual Subsection #1}%
\input tufte\relax}

\starttext
\dorecurse{3}{%
\startchapter[title=Chapter]
\placecontent[chapter,criterium=local] % local TOC OK
\startsection[title=Section]
Here we would like to see the local list of manual subsections
\placecontent[section,criterium=local] % local TOC not OK
\ManualSubsection{\recurselevel-1}
\ManualSubsection{\recurselevel-2}
\stopsection
\stopchapter}
\stoptext
% stop minimal example

Longer Story

Predefined \startchapter|section inserts titledata in TUC file:
  [titledata]={
   [label]=chapter,
   [title]=Chapter,
  },
  ...
  [titledata]={
   [label]=section,
   [title]=Section,
  },
while \writetolist[subsection]{whatever}{Manual Subsection #1} inserts 
userdata:

  [userdata]={
   [first]=whatever,
   [second]=Manual Subsection \\recurselevel -1,
  },
Is this the reason and can I force to write titledata in the TUC file?

Real case is of course more complicated and also PDF hyperlinks should work.

Thank you in advance,

Jano

___
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] \writetolist in mkiv

2014-10-12 Thread Wolfgang Schuster

Am 12.10.2014 um 20:39 schrieb Jano Kula jano.k...@gmail.com:

 Hello to everybody!
 
 Minimal story
 -
 How to insert local TOC of manually created subsections after the section 
 starts?
 
 % start minimal example
 \def\ManualSubsection#1{\blank%
 {\bf Manual Subsection #1}\par%
 \writetolist[subsection]{whatever}{Manual Subsection #1}%
 \input tufte\relax}
 
 \starttext
 \dorecurse{3}{%
 \startchapter[title=Chapter]
 \placecontent[chapter,criterium=local] % local TOC OK

You can’t put a keyword (chapter) and a assignment (criterium=local) in the 
same argument
of a setup-command, what you’re looking for is 
\placelist[chapter][criterium=local].

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

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

Re: [NTG-context] \writetolist in mkiv

2014-10-12 Thread Jano Kula

Hello Wolfgang,

On 12.10.2014 21:28, Wolfgang Schuster wrote:


Am 12.10.2014 um 20:39 schrieb Jano Kula jano.k...@gmail.com:


Hello to everybody!

Minimal story
-
How to insert local TOC of manually created subsections after the section 
starts?

% start minimal example
\def\ManualSubsection#1{\blank%
{\bf Manual Subsection #1}\par%
\writetolist[subsection]{whatever}{Manual Subsection #1}%
\input tufte\relax}

\starttext
\dorecurse{3}{%
\startchapter[title=Chapter]
\placecontent[chapter,criterium=local] % local TOC OK


You can’t put a keyword (chapter) and a assignment (criterium=local) in the 
same argument
of a setup-command, what you’re looking for is 
\placelist[chapter][criterium=local].

Wolfgang


Thanks, got it: \placelist[section][criterium=local] places the list of 
sections included in the chapter.


Still, how to do the same with subsections manually inserted by 
\writetolist[subsection]{}{Subsection title}?


Jano

___
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] \writetolist in mkiv

2014-10-12 Thread Wolfgang Schuster

Am 12.10.2014 um 22:57 schrieb Jano Kula jano.k...@gmail.com:

 Hello Wolfgang,
 
 On 12.10.2014 21:28, Wolfgang Schuster wrote:
 
 Am 12.10.2014 um 20:39 schrieb Jano Kula jano.k...@gmail.com:
 
 Hello to everybody!
 
 Minimal story
 -
 How to insert local TOC of manually created subsections after the section 
 starts?
 
 % start minimal example
 \def\ManualSubsection#1{\blank%
 {\bf Manual Subsection #1}\par%
 \writetolist[subsection]{whatever}{Manual Subsection #1}%
 \input tufte\relax}
 
 \starttext
 \dorecurse{3}{%
 \startchapter[title=Chapter]
 \placecontent[chapter,criterium=local] % local TOC OK
 
 You can’t put a keyword (chapter) and a assignment (criterium=local) in the 
 same argument
 of a setup-command, what you’re looking for is 
 \placelist[chapter][criterium=local].
 
 Wolfgang
 
 Thanks, got it: \placelist[section][criterium=local] places the list of 
 sections included in the chapter.
 
 Still, how to do the same with subsections manually inserted by 
 \writetolist[subsection]{}{Subsection title}?

\placelist[subsection][criterium=section]

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

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

[NTG-context] writetolist doesn't include sectionnumber in mkiv?

2014-02-15 Thread Sanjoy Mahajan
With MkIV, I'm having trouble getting \writetolist to include
sectionnumbers.  Or at least, I cannot get the typeset list to include
the sectionnumbers (but maybe writetolist sent in the information).

Here's a minimal example, which is almost exactly the example from the
wiki at http://wiki.contextgarden.net/Command/setuplist.  The only change
is that I've included [order=command] so that the \hrule ends up at the
right place.

\definelist[Reprints][criterium=all]

\starttext
  \section{Sec 1}
  \writetolist[Reprints]{1.}{List entry A}
  \subsection{Subsec 1}
  \writebetweenlist[Reprints]{\hrule}
  \writetolist[Reprints]{2.}{List entry B}
  \completelist[Reprints][order=command]
\stoptext


When typeset (I'm using the 2014.02.14 beta), the completelist looks
like:


List entry A   1

List entry B   1

But the 1. and 2. didn't show up in the left column.

I tried adding \setuplist[Reprints][sectionnumber=yes] but that didn't
help.  Does one need to define an alternative that includes
sectionnumbers?

-Sanjoy
___
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] \placelist and \writetolist

2011-12-13 Thread Marco Pessotto

Hello!

I can't understand what I'm doing wrong here:

%

\setuplist[mylist]
  [alternative=c,
width=0mm,
style=\tfx,
criterium=all]

\starttext

\placelist[mylist]

\page[yes]

\input knuth

\writetolist[mylist]{}{Item}

\stoptext
% 

The document compiles fine with version 2011.05.18 22:2, but it fails
miserably with the latest (2011.11.29 23:11)
! Missing number, treated as zero.

system   tex  error on line 11 in file prova.tex: Missing number, 
treated as zero ...

 1 \setuplist[mylist]
 2   [alternative=c,
 3 width=0mm,
 4 style=\tfx,
 5 criterium=all]
 6 
 7 
 8 \starttext
 9 
10 \placelist[mylist]
11   
12 \page[yes]
13 
14 \input knuth
15 
16 \writetolist[mylist]{}{Item}
17 
18 \stoptext

to be read again 
   ,
\doplacestructurelist ...um = #2, number = #3,
   extras = #4, order = #...
\doplacerawlist ...ras }{\listparameter \c!order }
  \stoplistreferences \endgr...
\doplacelist ...ginoflist \doplacerawlist [#1][#2]
  \doendoflist 
\dodoubleemptyonespaced #1#2-#1[{#2}][]
 
to be read again 
   \par 
l.11 
 
? H
A number should have been here; I inserted `0'.
(If you can't figure out why I needed to see a number,
look up `weird error' in the index to The TeXbook.)

Thanks in advance.

-- 
Marco

___
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] \placelist and \writetolist

2011-12-13 Thread Wolfgang Schuster

Am 13.12.2011 um 11:41 schrieb Marco Pessotto:

 
 Hello!
 
 I can't understand what I'm doing wrong here:
 
 %
 
 \setuplist[mylist]
  [alternative=c,
width=0mm,
style=\tfx,
criterium=all]
 
 \starttext
 
 \placelist[mylist]
 
 \page[yes]
 
 \input knuth
 
 \writetolist[mylist]{}{Item}
 
 \stoptext
 % 
 
 The document compiles fine with version 2011.05.18 22:2, but it fails
 miserably with the latest (2011.11.29 23:11)

Replace \setuplist with \definelist, before you use a list you should create it.

Wolfgang

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

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


Re: [NTG-context] \placelist and \writetolist

2011-12-13 Thread Marco Pessotto
Wolfgang Schuster schuster.wolfg...@googlemail.com writes:

 Replace \setuplist with \definelist, before you use a list you should create 
 it.

I knew I was missing something obvious...

Thanks a lot, it works.

Best wishes

-- 
Marco

___
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] \writetolist spurious space in the first line hereafter

2011-03-17 Thread Willi Egger
Hi all,

I detected that after issuing \writetolist, that there is a unwanted space in 
the first line after this command. This occurs when indenting is on and off. 

Please refer to the attached minimal example.

I am using ConTeXt 2011.02.25 22:03, LuaTEX beta-0.65.0-2010121316

Kind regards

Willi



test-indenting.tex
Description: Binary data
___
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] \writetolist spurious space in the first line hereafter

2011-03-17 Thread Wolfgang Schuster

Am 17.03.2011 um 11:32 schrieb Willi Egger:

 Hi all,
 
 I detected that after issuing \writetolist, that there is a unwanted space in 
 the first line after this command. This occurs when indenting is on and off. 

Add a comment after the last brace, i.e.

  \writetolist[…]{}{…}%

and write the text in the second argument, the first is for the number of the 
header (in your case nothing) and the second for the text.

Wolfgang

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

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


Re: [NTG-context] \writetolist spurious space in the first line hereafter

2011-03-17 Thread Willi Egger
Hello Wolfgang!

thank you so much for this answer. Thanks to regular expressions it is now 
solved throughout the whole book.

Willi
On 17 Mar 2011, at 11:47, Wolfgang Schuster wrote:

 
 Am 17.03.2011 um 11:32 schrieb Willi Egger:
 
 Hi all,
 
 I detected that after issuing \writetolist, that there is a unwanted space 
 in the first line after this command. This occurs when indenting is on and 
 off. 
 
 Add a comment after the last brace, i.e.
 
  \writetolist[…]{}{…}%
 
 and write the text in the second argument, the first is for the number of the 
 header (in your case nothing) and the second for the text.
 
 Wolfgang
 
 ___
 If your question is of interest to others as well, please add an entry to the 
 Wiki!
 
 maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
 webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
 archive  : http://foundry.supelec.fr/projects/contextrev/
 wiki : http://contextgarden.net
 ___

___
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] How to avoid that \writetolist becomes a page-breaker

2010-12-15 Thread Hans Hagen

On 14-12-2010 10:32, Marco Pessotto wrote:


\subject{\bf My title!}
\dontleavehmode
\writetolist[myrandompart]{}{It's a test}

works. The question if is this the right thing to do, still remains,
though


it's quite ok as long as you realize that it introduces 'something' in 
the text stream, so


xxx

\dontleavehmode\writetolist[myrandompart]{}{It's a test}

xxx

is actually:


xxx

[something written to a list]

xxx

so when whitespace is setup, in some cases you can get some extra

also, the [something ...] can end up on the current page or the next 
one, depending on the circumstances


in practice it's no real problem as one will do explicit writes inside 
boxes or so


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

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


Re: [NTG-context] How to avoid that \writetolist becomes a page-breaker

2010-12-15 Thread Hans Hagen

On 14-12-2010 9:00, Marco Pessotto wrote:

\doneleavehmode
\writetolist[myrandompart]{It's a test}
\input knuth

i.e. just bind the write to some text

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

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


Re: [NTG-context] How to avoid that \writetolist becomes a page-breaker

2010-12-15 Thread Marco Pessotto
Hans Hagen pra...@wxs.nl writes:

 On 14-12-2010 9:00, Marco Pessotto wrote:

 \doneleavehmode
 \writetolist[myrandompart]{It's a test}
 \input knuth

 i.e. just bind the write to some text

Thanks for your answer. I'm on my way to the wiki :-)

-- 
Marco

___
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] How to avoid that \writetolist becomes a page-breaker

2010-12-14 Thread Marco Pessotto

Probably due to my abuse of \writetolist, I noticed that inserting
\writetolist right after \subject makes TeX to think that it can break
the page there without problems.

See the following minimal example:

%===cut here=

\definelist[myrandompart]

\starttext

\dorecurse{12}{
\input reich 
}
\subject{\bf Wrong!}
\writetolist[myrandompart]{It's a test}

\input knuth

\page

\dorecurse{12}{
\input reich 
}
\subject{\bf Correct!}
%\writetolist[myrandompart]{It's a test}

\input knuth

%===cut here=

I'm pretty sure the solution is out there.
Some hints would be very welcome.

Thanks in advance

-- 
Marco

___
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] How to avoid that \writetolist becomes a page-breaker

2010-12-14 Thread Marco Pessotto
Marco Pessotto melmo...@gmail.com writes:

 Probably due to my abuse of \writetolist, I noticed that inserting
 \writetolist right after \subject makes TeX to think that it can break
 the page there without problems.

 See the following minimal example:

 %===cut here=

 \definelist[myrandompart]

 \starttext

 \dorecurse{12}{
 \input reich 
 }
 \subject{\bf Wrong!}
 \writetolist[myrandompart]{It's a test}

 \input knuth

 \page

 \dorecurse{12}{
 \input reich 
 }
 \subject{\bf Correct!}
 %\writetolist[myrandompart]{It's a test}

 \input knuth

 %===cut here=

 I'm pretty sure the solution is out there.
 Some hints would be very welcome.

 Thanks in advance

To answer to my own question, it looks like that

\subject{\bf My title!}
\dontleavehmode
\writetolist[myrandompart]{}{It's a test}

works. The question if is this the right thing to do, still remains,
though

-- 
Marco

___
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] writetolist causes mystery blank

2010-07-08 Thread Michael Murphy

Hi all,

I'm having a but of a problem using writetolist. In principle, I want to 
insert something into the table of contents, but I don't want to disturb 
the flow of the text. Unfortunately, the following code seems to 
generate a blank at the top of the page:


\showframe
\showmakeup

\starttext
\writetolist[section]{}{}%
\framed{This box has been pushed down}
\stoptext

I've also tried using a section command where the output has been set to 
empty:


\showframe
\showmakeup

\setuphead[section][
  before=,
  after=,
  command=\mydonothing]

\def\mydonothing#1#2{}

\starttext
\section{}%
\framed{This box has been pushed down}
\stoptext

but that also gets me a blank. Incidentally, the same thing happens with 
writebetweenlist, (except that this seems to sometimes push content onto 
a new page for some reason).


Any ideas?

--
Michael Murphy
___
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] writetolist causes mystery blank

2010-07-08 Thread Hans Hagen

On 8-7-2010 7:33, Michael Murphy wrote:

Hi all,

I'm having a but of a problem using writetolist. In principle, I want to
insert something into the table of contents, but I don't want to disturb
the flow of the text. Unfortunately, the following code seems to
generate a blank at the top of the page:


mkii or mkiv or both?



\showframe
\showmakeup

\starttext
\writetolist[section]{}{}%
\framed{This box has been pushed down}
\stoptext

I've also tried using a section command where the output has been set to
empty:

\showframe
\showmakeup

\setuphead[section][
before=,
after=,
command=\mydonothing]

\def\mydonothing#1#2{}

\starttext
\section{}%
\framed{This box has been pushed down}
\stoptext

but that also gets me a blank. Incidentally, the same thing happens with
writebetweenlist, (except that this seems to sometimes push content onto
a new page for some reason).

Any ideas?




--

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

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


Re: [NTG-context] writetolist causes mystery blank

2010-07-08 Thread Michael Murphy

I'm having a but of a problem using writetolist. In principle, I want to
insert something into the table of contents, but I don't want to disturb
the flow of the text. Unfortunately, the following code seems to
generate a blank at the top of the page:


mkii or mkiv or both?


It looks like it only happens on mkiv.

--
Michael Murphy
___
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] \writetolist fails in footnotes when interaction is on

2010-06-22 Thread Hans Hagen

On 21-6-2010 7:11, Michael Saunders wrote:

\setupinteraction[state=start,color=,contrastcolor=,option=fit]

\definelabel[demonum][text=,before=,after=,way=bytext]

\definelist[demos]
\setuplist[demos][interaction=all,alternative=b,after=]

\starttext
\footnote{\writetolist[demos]{\nextdemonum}{demo title}}
\stoptext



Is there a way around this?


fixed in next beta

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

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


[NTG-context] \writetolist fails in footnotes when interaction is on

2010-06-20 Thread Michael Saunders
\setupinteraction[state=start,color=,contrastcolor=,option=fit]

\definelabel[demonum][text=,before=,after=,way=bytext]

\definelist[demos]
\setuplist[demos][interaction=all,alternative=b,after=]

\starttext
\footnote{\writetolist[demos]{\nextdemonum}{demo title}}
\stoptext



Is there a way around 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
___


[NTG-context] Inserting apropriate blank - indenting by \writetolist

2010-05-18 Thread Jaroslav Hajtmar

Hello all,
When I do:

\writetolist[chapter]{}{Appendicess}

then content is

1.  Section one
2.  Section two
  .  Appendices

stopper is visible - unacceptable for me


when I do:
\writebetweenlist[chapter]{Appendicess}

then content is

1.  Section one
2.  Section two
Appendices

without indentation - - unacceptable for me

Is there way to insert apropriate blank before word Appendicess to 
receive result:

1.  Section one
2.  Section two
 Appendices

My justification:
I am trying bypass this way  section numbering of miscellaneous parts of 
document, because I dont discover way to setting numbering of sections
in appendix part. When I turn on section numbering 
(\setupsectionblock[appendix][number=yes, ...) then result is:

1.  Section one
2.  Section two
...
A. Appendices

When I turn off section numbering 
(\setupsectionblock[appendix][number=no, ...) then result is:


1.  Section one
2.  Section two
  .  Appendices

it is unacceptable for me.

Last acceptable form is:
1.  Section one
2.  Section two
 Appendices

TIA Jaroslav







___
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] Inserting apropriate blank - indenting by \writetolist

2010-05-18 Thread Hans Hagen

On 18-5-2010 8:02, Jaroslav Hajtmar wrote:

Hello all,
When I do:

\writetolist[chapter]{}{Appendicess}

then content is

1. Section one
2. Section two
. Appendices

stopper is visible - unacceptable for me


when I do:
\writebetweenlist[chapter]{Appendicess}

then content is

1. Section one
2. Section two
Appendices

without indentation - - unacceptable for me


well, writebetween is just that, you can try

\writebetweenlist[chapter]{\hskip3em Appendicess}

(a more comples solution involves cloning chapter but i have no time for 
explaining that now)


Hans

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

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


Re: [NTG-context] Inserting apropriate blank - indenting by \writetolist

2010-05-18 Thread Jaroslav Hajtmar

Thanx Hans,
is there possibility insert by this way still pagenumber?
for example:
\writebetweenlist[Ikap]{\hskip2em {\bf Přílohy} \hfill\the\pagenumber } 
% get error



Thanx Jaroslav


Dne 18.5.2010 9:49, Hans Hagen napsal(a):

On 18-5-2010 8:02, Jaroslav Hajtmar wrote:

Hello all,
When I do:

\writetolist[chapter]{}{Appendicess}

then content is

1. Section one
2. Section two
. Appendices

stopper is visible - unacceptable for me


when I do:
\writebetweenlist[chapter]{Appendicess}

then content is

1. Section one
2. Section two
Appendices

without indentation - - unacceptable for me


well, writebetween is just that, you can try

\writebetweenlist[chapter]{\hskip3em Appendicess}

(a more comples solution involves cloning chapter but i have no time 
for explaining that now)


Hans

-
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
| www.pragma-pod.nl
-



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

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


[NTG-context] \writetolist vs \writebetweenlist

2007-02-14 Thread JOHN CULLETON
I can use \writebetweenlist to add a line to my TOC.  I have to put the page 
number in manually. Here is the statement:
\writebetweenlist[part]{\nimbus\zy{Part 1 Prerequisite for Success}\hfil 22\rm }

It would seem more sensible to use \writetolist and let Context determine the 
page number. But there are two problems:
1. There is an extra set of braces {} for \writetolist, the purpose of which is 
not stated.
2. A statement similar to the above but with \writetolist[part] and deleting 
the material from \hfil onward fails on interpetation of the formatting macro
\zy. This in turn is a call to the soul.sty package for letterspacing the 
entry.  Here is macro \zy:
\sodef\zy{}{.040em}{.25em plus .5em}{2em plus .1em minus .1em}
It works OK with \writebetweenlist but fails when part of \writetolist etc. 


I have two questions: 
1. What are the extra braces for in the \writetolist command description?
2. Given two sets of braces, where does the text of the par title go?



_
Need personalized email and website? Look no further. It's easy
with Doteasy $0 Web Hosting! Learn more at www.doteasy.com
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-06 Thread Martin Kolařík
Hi Hans and Vit,

I've attached pdf and tex made with texexec 8bit.tex using the last beta 
(with cp1250 regime). The version chapterB is what I am using now, chapterA 
version is straightforward but not functional.

From this my ideas from last mail came -- when I am expanding \XMLflush 
exactly and controlled, result is OK (the expansion stops before active 
characters start to expand.

IMHO, the solution on character level is something different (although it works 
:-); yes, I did not study Vit's problems from year before. I never had a 
problems with simple TeX (\chapter{čřžý}), only with XML :-), so for me it 
would be sufficient solve XML level. Of course, if it is stuff of other level, 
it cannot be solved in XML.

Thanks, Martin

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Behalf Of Hans Hagen
Sent: Wednesday, April 05, 2006 1:03 PM
To: mailing list for ConTeXt users
Subject: Re: [NTG-context] Problem with encoding, XML and writetolist...


Vit Zyka wrote:
 Martin Kolařík wrote:
   
 Hi Hans,

 I've analyzed the situation using different combinations of regimes and 
 encodings, including switching off handling (\donothandleactivecharacter) 
 and it seems to me, that every text with chars  127, which is fully 
 expanded (as in 8bit.tex), must cause difficulties, because TOC entry read 
 back from TUO is scanned independently and thus spaces are gobbled.
 

 Hi Martin,

 we have discussed this problem a year ago. In that time I solve it just 
 writing '{}' in each title where was needed, like

\chapter{Dobré{} ráno}

 Now I have cooked an automatic solution. It is not optimal (effective) 
 but working. The only needs is to redefine

\def\numcharacter#1{\char#1{}}
\let\dochar\numcharacter

 and to load appropriate encoding file once more. Since it is banned a 
 new macro \reuseencoding was introduce:

 For Hans:
 It would be nice if this feature was enabled in a standard distro. 
 Perhaps you will find some more optimal solution...

 ---
 \unprotected
 \def\doreuseencoding#1%
{\letvalue{\c!file\f!encodingprefix#1}\empty
 \makeshortfilename[\f!encodingprefix#1]%
 \startreadingfile
 \readsysfile\shortfilename
   {\showmessage\m!encodings2{#1}}
   {\showmessage\m!encodings3{#1}}%
 \stopreadingfile}
 \def\reuseencoding[#1]%
{\processcommalist[#1]\doreuseencoding}


 \def\numcharacter#1{\char#1{}}
 \let\dochar\numcharacter

 \reuseencoding[ec]

 \enableregime[latin2]

 \starttext
 \writetolist[chapter]{1}{Dobré ráno}
 \expanded{\writetolist[chapter]{2}{Dobré odpoledne}}

 \placecontent
 \stoptext
   
the {} may break liguature building (and maybe kerning) ... taco knows ...

I got a brainwave ... 

\enableregime[latin2]

\starttext

\def\numcharacter#1{\rawcharacter{#1}}%
\let\dochar\numcharacter

\writetolist[chapter]{1}{Dobré ráno}

\expanded{\writetolist[chapter]{2}{Dobré odpoledne}}

\placelist[chapter][criterium=text]

test

\typefile{test.tuo}

\stoptext

this can be sped up (a bit) with 

% \dostepwiserecurse{0}{255}{1}
%   {\setevalue{rchr:\recurselevel}{\rawcharacter\recurselevel}}

% \def\rawcharacter#1{\getvalue{rchr:#1}}

this means that all chars are round tripped to themselves in output files! 

raw characters are not active and they are therefore equivalent to \char  

it's enough then to put 

\def\numcharacter#1{\rawcharacter{#1}}%
\let\dochar\numcharacter

into cont-new.tex 

(i will discuss this in more detail with taco later) 

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
-

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


8bit.pdf
Description: Adobe PDF document


8bit.tex
Description: Binary data
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-05 Thread Martin Kolařík
Hi Hans,

I've analyzed the situation using different combinations of regimes and 
encodings, including switching off handling (\donothandleactivecharacter) and 
it seems to me, that every text with chars  127, which is fully expanded (as 
in 8bit.tex), must cause difficulties, because TOC entry read back from TUO is 
scanned independently and thus spaces are gobbled.

Now I have solved it using not-stable solution -- I am using triple sequence of 
\expandafter to expand \XMLflush after \chapter instead \expanded. The solution 
is not stable as it is ConTeXt implementation dependent.

On the other side, now I do not know, how to partially expand code 
\chaper{\XMLflush{XMLTag}} to obtain sequence of simple unexpanded chars. 
Simple \expandafter is not sufficient, more \expandafters is dirty trick and 
full expansion (\expanded) leads to TOC entry problem. In TeX source this 
cannot occur (or can occur in strange situations :-), in XML source this is 
almost rule.

Maybe it would be useful to have in XML engine macro, which expands XMLdata 
exactly to get read (original) content (like mine triple \expandafter). Maybe 
such macro already exists and I am a real fool :-)

Thank you for help, have a nice day,

Martin

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
 Behalf Of Hans Hagen
 Sent: Monday, April 03, 2006 11:57 AM
 To: [EMAIL PROTECTED]; mailing list for ConTeXt users
 Subject: Re: [NTG-context] Problem with encoding, XML and writetolist...
 
 
 Martin Kolařík wrote:
  Aha, here maybe will be the solution :-)
 
  I'am using standalone Win32 distribution from Pragma and I'm 
 running texexec with --translate=cp1252cs. Typescripts use il2, 
 which corresponds to fonts, of course. If I run the code without 
 XML (if I transcribe XML to \chapter etc.) I get toc entry correctly too.
 
  Where should I look for more? What is natural.ctx?

 this is a one-to-one translation vector, and the one standard 
 used by context; forget about all those other mappings, they can 
 be done using regimes; you can use an il2 input regime, and any 
 (resonable) font encoding, 
 
 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
 -
 
 ___
 ntg-context mailing list
 ntg-context@ntg.nl
 http://www.ntg.nl/mailman/listinfo/ntg-context
 

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-05 Thread Martin Kolařík
Hi Hans,

I've analyzed the situation using different combinations of regimes and 
encodings, including switching off handling (\donothandleactivecharacter) and 
it seems to me, that every text with chars  127, which is fully expanded (as 
in 8bit.tex), must cause difficulties, because TOC entry read back from TUO is 
scanned independently and thus spaces are gobbled.

Now I have solved it using not-stable solution -- I am using triple sequence of 
\expandafter to expand \XMLflush after \chapter instead \expanded. The solution 
is not stable as it is ConTeXt implementation dependent.

On the other side, now I do not know, how to partially expand code 
\chaper{\XMLflush{XMLTag}} to obtain sequence of simple unexpanded chars. 
Simple \expandafter is not sufficient, more \expandafters is dirty trick and 
full expansion (\expanded) leads to TOC entry problem. In TeX source this 
cannot occur (or can occur in strange situations :-), in XML source this is 
almost rule.

Maybe it would be useful to have in XML engine macro, which expands XMLdata 
exactly to get read (original) content (like mine triple \expandafter). Maybe 
such macro already exists and I am a real fool :-)

Thank you for help, have a nice day,

Martin

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
 Behalf Of Hans Hagen
 Sent: Monday, April 03, 2006 11:57 AM
 To: [EMAIL PROTECTED]; mailing list for ConTeXt users
 Subject: Re: [NTG-context] Problem with encoding, XML and writetolist...
 
 
 Martin Kolařík wrote:
  Aha, here maybe will be the solution :-)
 
  I'am using standalone Win32 distribution from Pragma and I'm 
 running texexec with --translate=cp1252cs. Typescripts use il2, 
 which corresponds to fonts, of course. If I run the code without 
 XML (if I transcribe XML to \chapter etc.) I get toc entry correctly too.
 
  Where should I look for more? What is natural.ctx?

 this is a one-to-one translation vector, and the one standard 
 used by context; forget about all those other mappings, they can 
 be done using regimes; you can use an il2 input regime, and any 
 (resonable) font encoding, 
 
 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
 -
 
 ___
 ntg-context mailing list
 ntg-context@ntg.nl
 http://www.ntg.nl/mailman/listinfo/ntg-context
 

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-05 Thread Hans Hagen
Martin Kolařík wrote:
 Hi Hans,

 I've analyzed the situation using different combinations of regimes and 
 encodings, including switching off handling (\donothandleactivecharacter) and 
 it seems to me, that every text with chars  127, which is fully expanded (as 
 in 8bit.tex), must cause difficulties, because TOC entry read back from TUO 
 is scanned independently and thus spaces are gobbled.

 Now I have solved it using not-stable solution -- I am using triple sequence 
 of \expandafter to expand \XMLflush after \chapter instead \expanded. The 
 solution is not stable as it is ConTeXt implementation dependent.

 On the other side, now I do not know, how to partially expand code 
 \chaper{\XMLflush{XMLTag}} to obtain sequence of simple unexpanded chars. 
 Simple \expandafter is not sufficient, more \expandafters is dirty trick and 
 full expansion (\expanded) leads to TOC entry problem. In TeX source this 
 cannot occur (or can occur in strange situations :-), in XML source this is 
 almost rule.

 Maybe it would be useful to have in XML engine macro, which expands XMLdata 
 exactly to get read (original) content (like mine triple \expandafter). Maybe 
 such macro already exists and I am a real fool :-)

 Thank you for help, have a nice day,
   
some commands indeed have keys like: 

expansion=no|yes|utf|xml|command 

and alike 

the problem is that when one does something \expanded{...} in a style, it 
bypasses this mechanism 

can you make me a (as small as possible) example of a doc? i can then test it 
here with my version 

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
-

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-05 Thread Vit Zyka
Martin Kolařík wrote:
 Hi Hans,
 
 I've analyzed the situation using different combinations of regimes and 
 encodings, including switching off handling (\donothandleactivecharacter) and 
 it seems to me, that every text with chars  127, which is fully expanded (as 
 in 8bit.tex), must cause difficulties, because TOC entry read back from TUO 
 is scanned independently and thus spaces are gobbled.

Hi Martin,

we have discussed this problem a year ago. In that time I solve it just 
writing '{}' in each title where was needed, like

   \chapter{Dobré{} ráno}

Now I have cooked an automatic solution. It is not optimal (effective) 
but working. The only needs is to redefine

   \def\numcharacter#1{\char#1{}}
   \let\dochar\numcharacter

and to load appropriate encoding file once more. Since it is banned a 
new macro \reuseencoding was introduce:

For Hans:
It would be nice if this feature was enabled in a standard distro. 
Perhaps you will find some more optimal solution...

---
\unprotected
\def\doreuseencoding#1%
   {\letvalue{\c!file\f!encodingprefix#1}\empty
\makeshortfilename[\f!encodingprefix#1]%
\startreadingfile
\readsysfile\shortfilename
  {\showmessage\m!encodings2{#1}}
  {\showmessage\m!encodings3{#1}}%
\stopreadingfile}
\def\reuseencoding[#1]%
   {\processcommalist[#1]\doreuseencoding}


\def\numcharacter#1{\char#1{}}
\let\dochar\numcharacter

\reuseencoding[ec]

\enableregime[latin2]

\starttext
\writetolist[chapter]{1}{Dobré ráno}
\expanded{\writetolist[chapter]{2}{Dobré odpoledne}}

\placecontent
\stoptext
---

 
 Now I have solved it using not-stable solution -- I am using triple sequence 
 of \expandafter to expand \XMLflush after \chapter instead \expanded. The 
 solution is not stable as it is ConTeXt implementation dependent.
 
 On the other side, now I do not know, how to partially expand code 
 \chaper{\XMLflush{XMLTag}} to obtain sequence of simple unexpanded chars. 
 Simple \expandafter is not sufficient, more \expandafters is dirty trick and 
 full expansion (\expanded) leads to TOC entry problem. In TeX source this 
 cannot occur (or can occur in strange situations :-), in XML source this is 
 almost rule.
 
 Maybe it would be useful to have in XML engine macro, which expands XMLdata 
 exactly to get read (original) content (like mine triple \expandafter). Maybe 
 such macro already exists and I am a real fool :-)
 
 Thank you for help, have a nice day,
 
 Martin
 
 
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Behalf Of Hans Hagen
Sent: Monday, April 03, 2006 11:57 AM
To: [EMAIL PROTECTED]; mailing list for ConTeXt users
Subject: Re: [NTG-context] Problem with encoding, XML and writetolist...


Martin Kolařík wrote:

Aha, here maybe will be the solution :-)

I'am using standalone Win32 distribution from Pragma and I'm 

running texexec with --translate=cp1252cs. Typescripts use il2, 
which corresponds to fonts, of course. If I run the code without 
XML (if I transcribe XML to \chapter etc.) I get toc entry correctly too.

Where should I look for more? What is natural.ctx?
  

this is a one-to-one translation vector, and the one standard 
used by context; forget about all those other mappings, they can 
be done using regimes; you can use an il2 input regime, and any 
(resonable) font encoding, 

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
-

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

 
 
 ___
 ntg-context mailing list
 ntg-context@ntg.nl
 http://www.ntg.nl/mailman/listinfo/ntg-context

-- 
===
Ing. Vít Zýka, Ph.D. TYPOkvítek

database publishing  databazove publikovani
data maintaining and typesetting in typographic quality
priprava dat a jejich sazba v typograficke kvalite

tel.: (+420) 777 198 189 www: http://typokvitek.com
===

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-05 Thread Hans Hagen
Vit Zyka wrote:
 Martin Kolařík wrote:
   
 Hi Hans,

 I've analyzed the situation using different combinations of regimes and 
 encodings, including switching off handling (\donothandleactivecharacter) 
 and it seems to me, that every text with chars  127, which is fully 
 expanded (as in 8bit.tex), must cause difficulties, because TOC entry read 
 back from TUO is scanned independently and thus spaces are gobbled.
 

 Hi Martin,

 we have discussed this problem a year ago. In that time I solve it just 
 writing '{}' in each title where was needed, like

\chapter{Dobré{} ráno}

 Now I have cooked an automatic solution. It is not optimal (effective) 
 but working. The only needs is to redefine

\def\numcharacter#1{\char#1{}}
\let\dochar\numcharacter

 and to load appropriate encoding file once more. Since it is banned a 
 new macro \reuseencoding was introduce:

 For Hans:
 It would be nice if this feature was enabled in a standard distro. 
 Perhaps you will find some more optimal solution...

 ---
 \unprotected
 \def\doreuseencoding#1%
{\letvalue{\c!file\f!encodingprefix#1}\empty
 \makeshortfilename[\f!encodingprefix#1]%
 \startreadingfile
 \readsysfile\shortfilename
   {\showmessage\m!encodings2{#1}}
   {\showmessage\m!encodings3{#1}}%
 \stopreadingfile}
 \def\reuseencoding[#1]%
{\processcommalist[#1]\doreuseencoding}


 \def\numcharacter#1{\char#1{}}
 \let\dochar\numcharacter

 \reuseencoding[ec]

 \enableregime[latin2]

 \starttext
 \writetolist[chapter]{1}{Dobré ráno}
 \expanded{\writetolist[chapter]{2}{Dobré odpoledne}}

 \placecontent
 \stoptext
   
the {} may break liguature building (and maybe kerning) ... taco knows ...

I got a brainwave ... 

\enableregime[latin2]

\starttext

\def\numcharacter#1{\rawcharacter{#1}}%
\let\dochar\numcharacter

\writetolist[chapter]{1}{Dobré ráno}

\expanded{\writetolist[chapter]{2}{Dobré odpoledne}}

\placelist[chapter][criterium=text]

test

\typefile{test.tuo}

\stoptext

this can be sped up (a bit) with 

% \dostepwiserecurse{0}{255}{1}
%   {\setevalue{rchr:\recurselevel}{\rawcharacter\recurselevel}}

% \def\rawcharacter#1{\getvalue{rchr:#1}}

this means that all chars are round tripped to themselves in output files! 

raw characters are not active and they are therefore equivalent to \char  

it's enough then to put 

\def\numcharacter#1{\rawcharacter{#1}}%
\let\dochar\numcharacter

into cont-new.tex 

(i will discuss this in more detail with taco later) 

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
-

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-05 Thread Vit Zyka
Hans Hagen wrote:
 Vit Zyka wrote:
 
Martin Kolařík wrote:
  

Hi Hans,

I've analyzed the situation using different combinations of regimes and 
encodings, including switching off handling (\donothandleactivecharacter) 
and it seems to me, that every text with chars  127, which is fully 
expanded (as in 8bit.tex), must cause difficulties, because TOC entry read 
back from TUO is scanned independently and thus spaces are gobbled.


Hi Martin,

we have discussed this problem a year ago. In that time I solve it just 
writing '{}' in each title where was needed, like

   \chapter{Dobré{} ráno}

Now I have cooked an automatic solution. It is not optimal (effective) 
but working. The only needs is to redefine

   \def\numcharacter#1{\char#1{}}
   \let\dochar\numcharacter

and to load appropriate encoding file once more. Since it is banned a 
new macro \reuseencoding was introduce:

For Hans:
It would be nice if this feature was enabled in a standard distro. 
Perhaps you will find some more optimal solution...

---
\unprotected
\def\doreuseencoding#1%
   {\letvalue{\c!file\f!encodingprefix#1}\empty
\makeshortfilename[\f!encodingprefix#1]%
\startreadingfile
\readsysfile\shortfilename
  {\showmessage\m!encodings2{#1}}
  {\showmessage\m!encodings3{#1}}%
\stopreadingfile}
\def\reuseencoding[#1]%
   {\processcommalist[#1]\doreuseencoding}


\def\numcharacter#1{\char#1{}}
\let\dochar\numcharacter

\reuseencoding[ec]

\enableregime[latin2]

\starttext
\writetolist[chapter]{1}{Dobré ráno}
\expanded{\writetolist[chapter]{2}{Dobré odpoledne}}

\placecontent
\stoptext
  
 
 the {} may break liguature building (and maybe kerning) ... taco knows ...

Hmmm, that's right.

 I got a brainwave ... 
 
 \enableregime[latin2]
 
 \starttext
 
 \def\numcharacter#1{\rawcharacter{#1}}%
 \let\dochar\numcharacter

So there is no need to have only 7-bit chars in tui/tuo etc.? All right, 
I think this will be better also for sorting. Sounds promissing.

 \writetolist[chapter]{1}{Dobré ráno}
 
 \expanded{\writetolist[chapter]{2}{Dobré odpoledne}}
 
 \placelist[chapter][criterium=text]
 
 test
 
 \typefile{test.tuo}
 
 \stoptext
 
 this can be sped up (a bit) with 
 
 % \dostepwiserecurse{0}{255}{1}
 %   {\setevalue{rchr:\recurselevel}{\rawcharacter\recurselevel}}
 
 % \def\rawcharacter#1{\getvalue{rchr:#1}}
 
 this means that all chars are round tripped to themselves in output files! 
 
 raw characters are not active and they are therefore equivalent to \char  
 
 it's enough then to put 
 
 \def\numcharacter#1{\rawcharacter{#1}}%
 \let\dochar\numcharacter
 
 into cont-new.tex 
 
 (i will discuss this in more detail with taco later) 

All right, thanks Hans,
Vit

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-05 Thread Hans Hagen
Vit Zyka wrote:

 So there is no need to have only 7-bit chars in tui/tuo etc.? All right, 
 I think this will be better also for sorting. Sounds promissing.
   
if the regime is the same for a whole document ... indeed

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
-

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-03 Thread Martin Kolařík
Hi Hans,

the test file is attached,

thanks,

Martin

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
 Behalf Of Hans Hagen
 Sent: Friday, March 31, 2006 7:01 PM
 To: [EMAIL PROTECTED]; mailing list for ConTeXt users
 Subject: Re: [NTG-context] Problem with encoding, XML and writetolist...


 Martin Kolařík wrote:
  Hi Hans,
 
  isn't there some news with the stuff?
 
 small test file needed to refresh my memory

 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
 -

 ___
 ntg-context mailing list
 ntg-context@ntg.nl
 http://www.ntg.nl/mailman/listinfo/ntg-context


___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-03 Thread Hans Hagen
Martin Kolařík wrote:
 Hi Hans,

 the test file is attached,
   
what input encoding is used here? 

i get the same chapter title as toc entry 

is your tex configured for 8 bit (natural.ctx) 

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
-

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-03 Thread Martin Kolařík
Aha, here maybe will be the solution :-)

I'am using standalone Win32 distribution from Pragma and I'm running texexec 
with --translate=cp1252cs. Typescripts use il2, which corresponds to fonts, of 
course. If I run the code without XML (if I transcribe XML to \chapter etc.) I 
get toc entry correctly too.

Where should I look for more? What is natural.ctx?

Thank you,

Martin


-Original Message-
From: Hans Hagen [mailto:[EMAIL PROTECTED]
Sent: Monday, April 03, 2006 10:36 AM
To: [EMAIL PROTECTED]; mailing list for ConTeXt users
Subject: Re: [NTG-context] Problem with encoding, XML and writetolist...


Martin Kolařík wrote:
 Hi Hans,

 the test file is attached,
   
what input encoding is used here? 

i get the same chapter title as toc entry 

is your tex configured for 8 bit (natural.ctx) 

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
-


___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-03 Thread Hans Hagen
Martin Kolařík wrote:
 Aha, here maybe will be the solution :-)

 I'am using standalone Win32 distribution from Pragma and I'm running texexec 
 with --translate=cp1252cs. Typescripts use il2, which corresponds to fonts, 
 of course. If I run the code without XML (if I transcribe XML to \chapter 
 etc.) I get toc entry correctly too.

 Where should I look for more? What is natural.ctx?
   
this is a one-to-one translation vector, and the one standard used by context; 
forget about all those other mappings, they can be done using regimes; you can 
use an il2 input regime, and any (resonable) font encoding, 

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
-

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-03 Thread Martin Kolařík
I was confused with typo (ctx=tcx :-) but I still did not succeed. I now 
installed last cont-tfm, I tried 8bit.tex (from the example) and nothing :-(

I am using now directly texexec 8bit.tex, which leads to natural.tcx and 
english interface, without anything more. I tried to change regimes in 8bit.tex 
too, and the characters were changing. So regimes are OK, result not.

Texexec still reports:

chapter : 1 ÄluŁou\char 163 c\char 237  kon\char 165  \char 250 p\char 
237

which is not good. And I am not able, when not using cp1250.tcx, recode win1250 
(default for win) to latin2. There I am able to write regime for myself 
(cp1250), but I suppose, that whenever characters will not expand to \char XXX 
form, cp1250.tcx still will be working and usable.

Cannot be set somewhere something badly in my local context configuration?

Thank you,

Martin

-Original Message-
From: Hans Hagen [mailto:[EMAIL PROTECTED]
Sent: Monday, April 03, 2006 11:57 AM
To: [EMAIL PROTECTED]; mailing list for ConTeXt users
Subject: Re: [NTG-context] Problem with encoding, XML and writetolist...


Martin Kolařík wrote:
 Aha, here maybe will be the solution :-)

 I'am using standalone Win32 distribution from Pragma and I'm running texexec 
 with --translate=cp1252cs. Typescripts use il2, which corresponds to fonts, 
 of course. If I run the code without XML (if I transcribe XML to \chapter 
 etc.) I get toc entry correctly too.

 Where should I look for more? What is natural.ctx?
   
this is a one-to-one translation vector, and the one standard used by context; 
forget about all those other mappings, they can be done using regimes; you can 
use an il2 input regime, and any (resonable) font encoding, 

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
-


___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-03 Thread Vit Zyka
Hans Hagen wrote:
 Martin Kolařík wrote:
 
Aha, here maybe will be the solution :-)

I'am using standalone Win32 distribution from Pragma and I'm running texexec 
with --translate=cp1252cs. Typescripts use il2, which corresponds to fonts, 
of course. If I run the code without XML (if I transcribe XML to \chapter 
etc.) I get toc entry correctly too.

Where should I look for more? What is natural.ctx?
  
 
 this is a one-to-one translation vector, and the one standard used by 
 context; forget about all those other mappings, they can be done using 
 regimes; you can use an il2 input regime, and any (resonable) font encoding, 
 
  Hans

specifically for you:

\mainlanguage[cz]
\enableregime[windows] % or \enableregime[latin2] for il2

is enough for Latin Modern and Czech.

Vit

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-03 Thread Martin Kolařík
Thanks Vit, your solution perfectly works (I tried it :-); but not for me -- in 
my case (and in another mine cases too) I use XML code, which remaps some 
pieces to \chapter. And during the expansion accented characters are replaced 
with \char xxx, this is written to tui/tuo file and read back without spaces 
-- the spaces are gobbled by TeX's number syntactic rule...

But, Hans, when I added \mainlanguage[cz] before \enableregime[windows] in 
8bit.tex and run texexec with --translate=cp1250cs, I got:

! Illegal parameter number in definition of \@@expanded.
to be read again
   \crcr
\oalign [EMAIL PROTECTED] \lineskip .25ex\ialign {##\crcr
  #1\crcr }}
\encircled ...\tx #1}}\hfil \crcr \mathhexbox 20D}
  }
\XML:dat:title -Ä
  luŁouŔcÝ koný ˙pÝ
\expanded ...\long \xdef \@@expanded {\noexpand #1
  }\@@expanded
l.3 /chapter

Thank you,

Martin

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Behalf Of Vit Zyka
Sent: Monday, April 03, 2006 1:18 PM
To: mailing list for ConTeXt users
Subject: Re: [NTG-context] Problem with encoding, XML and writetolist...


Hans Hagen wrote:
 Martin Kolařík wrote:
 
Aha, here maybe will be the solution :-)

I'am using standalone Win32 distribution from Pragma and I'm running texexec 
with --translate=cp1252cs. Typescripts use il2, which corresponds to fonts, 
of course. If I run the code without XML (if I transcribe XML to \chapter 
etc.) I get toc entry correctly too.

Where should I look for more? What is natural.ctx?
  
 
 this is a one-to-one translation vector, and the one standard used by 
 context; forget about all those other mappings, they can be done using 
 regimes; you can use an il2 input regime, and any (resonable) font encoding, 
 
  Hans

specifically for you:

\mainlanguage[cz]
\enableregime[windows] % or \enableregime[latin2] for il2

is enough for Latin Modern and Czech.

Vit

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-03 Thread Mojca Miklavec
On 4/3/06, Martin Kolařík wrote:

 which is not good. And I am not able, when not using cp1250.tcx, recode 
 win1250 (default for win) to latin2. There I am able to write regime for 
 myself (cp1250), but I suppose, that whenever characters will not expand to 
 \char XXX form, cp1250.tcx still will be working and usable.

Hans, I would guess that more than 50% of Slavic Windows users (ie.
Slovenian, Croatian, Chech, Slovak, ...) use the cp1250 encoding
(including me). Would it be possible to add at least this file
http://pub.mojca.org/tex/enco/contextbase/regi-cp1250.tex to the
default ConTeXt distribution? (with synonyms windows-1250 and
cp1250).

This has probably nothing to do with the problem described here, but I
believe that many users would appreciate to have that encoding
(called regime in ConTeXt) available.

 when I added \mainlanguage[cz] before \enableregime[windows] in 8bit.tex and 
 run
 texexec with --translate=cp1250cs, I got:

\enableregime[windows] is cp1252 (Western European Windows) not cp1250
(Central European Windows), --translate=cp1250cs is cp1250 (supposing
that you don't use \enableregime[windows], but the default one):
everything will be mixed up if you use both simultaneously.

If you download the file mentioned above (place it into the current
directory or somewhere in the TeX tree and refresh the filename
database) or if Hans adds it to the distribution, you can use
\input regi-cp1250
\enableregime[cp1250]

This probably won't solve your problem with missing spaces (didn't try
it), but you'll have the proper encoding.

Mojca
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-03 Thread Martin Kolařík
Thanks Mojca, I downloaded your regime file; now I will not need write it
myself :-)

Martin

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Behalf Of Mojca Miklavec
Sent: Monday, April 03, 2006 2:33 PM
To: [EMAIL PROTECTED]; mailing list for ConTeXt users; Hans Hagen
Subject: Re: [NTG-context] Problem with encoding, XML and writetolist...


On 4/3/06, Martin Kolařík wrote:

 which is not good. And I am not able, when not using cp1250.tcx, recode
win1250 (default for win) to latin2. There I am able to write regime for
myself (cp1250), but I suppose, that whenever characters will not expand to
\char XXX form, cp1250.tcx still will be working and usable.

Hans, I would guess that more than 50% of Slavic Windows users (ie.
Slovenian, Croatian, Chech, Slovak, ...) use the cp1250 encoding
(including me). Would it be possible to add at least this file
http://pub.mojca.org/tex/enco/contextbase/regi-cp1250.tex to the
default ConTeXt distribution? (with synonyms windows-1250 and
cp1250).

This has probably nothing to do with the problem described here, but I
believe that many users would appreciate to have that encoding
(called regime in ConTeXt) available.

 when I added \mainlanguage[cz] before \enableregime[windows] in 8bit.tex
and run
 texexec with --translate=cp1250cs, I got:

\enableregime[windows] is cp1252 (Western European Windows) not cp1250
(Central European Windows), --translate=cp1250cs is cp1250 (supposing
that you don't use \enableregime[windows], but the default one):
everything will be mixed up if you use both simultaneously.

If you download the file mentioned above (place it into the current
directory or somewhere in the TeX tree and refresh the filename
database) or if Hans adds it to the distribution, you can use
\input regi-cp1250
\enableregime[cp1250]

This probably won't solve your problem with missing spaces (didn't try
it), but you'll have the proper encoding.

Mojca
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-03 Thread Mojca Miklavec
On 2/28/06, Martin Kolařík wrote:
 Hi all,

 I have problem with chars encoding now; I have updated ConTeXt sometimes in
 January; before the time I was using old (year) version. In this
 prehistorical version the problem was not present.

 What is the stuff? The following code generates content with titles without
 spaces -- accented characters are replaced with \char XXX variant, so during
 reading TUI line TeX gobbles a space after XXX as a part of number syntax
 rule.

 Can I do something? With encoding? With XML?

Encoding has nothing to do with it. I don't really understand the
\[un]expanded commands in TeX, but this part could theoretically be
problematic:
 {\expanded
{\section{\XMLflush{title

Consider the following (encoding-independent) minimal example, just in
case that this can help any of the gurus to understand the problem:

\defineXMLenvironment
 [chapter]
 {\defineXMLsave[title]}
 {\expanded
{\section{\XMLflush{title

\starttext
\startbuffer
chapter
 title$a+b$/title
/chapter
\stopbuffer

\processXMLbuffer
\placecontent[criterium=all]
\stoptext

The entry in TOC is different from the title (one is in math mode and
the other one writen with dollars - literally).

Mojca


 Thank you very much, have a nice day, Martin

 Code:

 \defineXMLenvironment
   [chapter]
   {\defineXMLsave[title]}
   {\expanded
  {\chapter\XMLflush{title}}}

 \starttext

 \startbuffer

 chapter
   titleAhojá hojč kuna/title
 /chapter

 \stopbuffer

 \processXMLbuffer

 \completecontent[criterium=all]

 \stoptext
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-04-03 Thread Martin Kolařík
OK, expansion is not encoding, but expansion in this place here is not a
problem (I suppose). The section head is good, but the TOC entry not. So the
inner expansion (or conversion or detokenization or so) around writetolist
is probably affected by something, what now I cannot handle.

And what is strange -- Hans did not reproduce the behaviour (as he wrote),
so I am asking a trying to find the problem on my side (or lucky thougth
:-)...

Thank for your ideas and help,

Martin

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Behalf Of Mojca Miklavec
Sent: Monday, April 03, 2006 4:25 PM
To: [EMAIL PROTECTED]; mailing list for ConTeXt users
Subject: Re: [NTG-context] Problem with encoding, XML and writetolist...


On 2/28/06, Martin Kolařík wrote:
 Hi all,

 I have problem with chars encoding now; I have updated ConTeXt sometimes
in
 January; before the time I was using old (year) version. In this
 prehistorical version the problem was not present.

 What is the stuff? The following code generates content with titles
without
 spaces -- accented characters are replaced with \char XXX variant, so
during
 reading TUI line TeX gobbles a space after XXX as a part of number
syntax
 rule.

 Can I do something? With encoding? With XML?

Encoding has nothing to do with it. I don't really understand the
\[un]expanded commands in TeX, but this part could theoretically be
problematic:
 {\expanded
{\section{\XMLflush{title

Consider the following (encoding-independent) minimal example, just in
case that this can help any of the gurus to understand the problem:

\defineXMLenvironment
 [chapter]
 {\defineXMLsave[title]}
 {\expanded
{\section{\XMLflush{title

\starttext
\startbuffer
chapter
 title$a+b$/title
/chapter
\stopbuffer

\processXMLbuffer
\placecontent[criterium=all]
\stoptext

The entry in TOC is different from the title (one is in math mode and
the other one writen with dollars - literally).

Mojca


 Thank you very much, have a nice day, Martin

 Code:

 \defineXMLenvironment
   [chapter]
   {\defineXMLsave[title]}
   {\expanded
  {\chapter\XMLflush{title}}}

 \starttext

 \startbuffer

 chapter
   titleAhojá hojč kuna/title
 /chapter

 \stopbuffer

 \processXMLbuffer

 \completecontent[criterium=all]

 \stoptext
___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-03-31 Thread Martin Kolařík
Hi Hans,

isn't there some news with the stuff?

Thank you and have a nice day,

Martin

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Behalf Of Martin Kolařík
Sent: Tuesday, February 28, 2006 10:33 AM
To: mailing list for ConTeXt users
Subject: Re: [NTG-context] Problem with encoding, XML and writetolist...


Here the file with 8bit chars is,

Martin

-Original Message-
From: Hans Hagen [mailto:[EMAIL PROTECTED]
Sent: Tuesday, February 28, 2006 10:16 AM
To: [EMAIL PROTECTED]; mailing list for ConTeXt users
Subject: Re: [NTG-context] Problem with encoding, XML and writetolist...


� wrote:
 Hi all,

 I have problem with chars encoding now; I have updated ConTeXt sometimes in
 January; before the time I was using old (year) version. In this
 prehistorical version the problem was not present.

 What is the stuff? The following code generates content with titles without
 spaces -- accented characters are replaced with \char XXX variant, so during
 reading TUI line TeX gobbles a space after XXX as a part of number syntax
 rule.
   
can you send me a zip with the test file so that the 8 bit chars are ok? 

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
-


___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-03-31 Thread Hans Hagen
Martin Kolařík wrote:
 Hi Hans,

 isn't there some news with the stuff?
   
small test file needed to refresh my memory 

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
-

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Problem with encoding, XML and writetolist...

2006-02-28 Thread Hans Hagen
� wrote:
 Hi all,

 I have problem with chars encoding now; I have updated ConTeXt sometimes in
 January; before the time I was using old (year) version. In this
 prehistorical version the problem was not present.

 What is the stuff? The following code generates content with titles without
 spaces -- accented characters are replaced with \char XXX variant, so during
 reading TUI line TeX gobbles a space after XXX as a part of number syntax
 rule.
   
can you send me a zip with the test file so that the 8 bit chars are ok? 

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
-

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


[NTG-context] Problem with encoding, XML and writetolist...

2006-02-27 Thread Martin Kolařík
Hi all,

I have problem with chars encoding now; I have updated ConTeXt sometimes in
January; before the time I was using old (year) version. In this
prehistorical version the problem was not present.

What is the stuff? The following code generates content with titles without
spaces -- accented characters are replaced with \char XXX variant, so during
reading TUI line TeX gobbles a space after XXX as a part of number syntax
rule.

Can I do something? With encoding? With XML?

Thank you very much, have a nice day, Martin

Code:

\defineXMLenvironment
  [chapter]
  {\defineXMLsave[title]}
  {\expanded
 {\chapter\XMLflush{title}}}

\starttext

\startbuffer

chapter
  titleAhojá hojč kuna/title
/chapter

\stopbuffer

\processXMLbuffer

\completecontent[criterium=all]

\stoptext

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


[NTG-context] Problem with encoding, XML and writetolist...

2006-02-27 Thread Martin Kolařík
Hi Hans,

I have problem with chars encoding now; I have updated ConTeXt sometimes in
January; before the time I was using old (year) version. In this
prehistorical version the problem was not present.

What is the stuff? The following code generates content with titles without
spaces -- accented characters are replaced with \char XXX variant, so during
reading TUI line TeX gobbles a space after XXX as a part of number syntax
rule.

Can I do something? With encoding? With XML?

Thank you very much, have a nice day, Martin

Code:

\defineXMLenvironment
  [chapter]
  {\defineXMLsave[title]}
  {\expanded
 {\chapter\XMLflush{title}}}

\starttext

\startbuffer

chapter
  titleAhojá hojč kuna/title
/chapter

\stopbuffer

\processXMLbuffer

\completecontent[criterium=all]

\stoptext

___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context