[NTG-context] Uppercase headings

2006-03-31 Thread Ville Voipio
Title: Uppercase headings







I started to edit an old document with capitalized headings. Making the headings was rather difficult (as can be seen on this list about a year ago), and now it seems to have broken again.

I have:

\setuphead[title]
 [page=yes,
 before={\strut\blank[5*big]},
 after={\textrule\blank},
 align=middle,
 style=\tfb,
 textcommand=\WORD
 ]

This worked fine in the past. Not anymore:

8---


! You can't use `\relax' after \the.
recently read [EMAIL PROTECTED]@\@@pnstate

\pushmacro ...ame [EMAIL PROTECTED]@ \@@pushedmacro \endcsname
 \@@pushedmacro \endcsname #1
\makesectionformat ...macro \@@shortsectionnumber
 \let \@@shortsectionnumber...

\rawreference ...veryreference \makesectionformat
 \writereference {#2} {\sec...
argument ...\finalsectionnumber }{\asciititle }}
 }\fi \executeifdefi! Missing \endcsname inserted.
to be read again
 \let
\@@shortsectionnumber [EMAIL PROTECTED] \ifx \csname \??se #1
 \c!ownnumber \endcsname \r...

\makesectionformat ... \@@shortsectionnumber \let
 \@@shortsectionnumber \@@s...

\rawreference ...veryreference \makesectionformat
 \writereference {#2} {\sec...
argument ...\finalsectionnumber }{\asciititle }}
 }\fi \executeifdefined {\?...

\douppercase ...rstoftwoarguments \edef \ascii {#1
 }\edef \ascii {\expandafte...
...

8---

Using the trivial solution (\uppercase) does not work because with a non-il1 regime it does not handle the accented characters (A umlat, O umlaut) correctly. I use UTF, as it contains all the characters I need.

So, what has changed in the \WORD? It works \WORD{fine} within text but not in the headings.

TIA,

- Ville



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


Re: [NTG-context] Uppercase headings

2006-03-31 Thread Hans Hagen
Ville Voipio wrote:

 I started to edit an old document with capitalized headings. Making 
 the headings was rather difficult (as can be seen on this list about a 
 year ago), and now it seems to have broken again.

 I have:

 \setuphead[title]
   [page=yes,
   before={\strut\blank[5*big]},
   after={\textrule\blank},
   align=middle,
   style=\tfb,
   textcommand=\WORD
   ]

 This worked fine in the past. Not anymore:

 8---


 ! You can't use `\relax' after \the.
 recently read [EMAIL PROTECTED]@\@@pnstate

 \pushmacro ...ame [EMAIL PROTECTED]@ \@@pushedmacro \endcsname
   \@@pushedmacro 
 \endcsname #1
 \makesectionformat ...macro \@@shortsectionnumber
   \let 
 \@@shortsectionnumber...

 \rawreference ...veryreference \makesectionformat
   \writereference {#2} 
 {\sec...
 argument ...\finalsectionnumber }{\asciititle }}
   }\fi \executeifdefi! 
 Missing \endcsname inserted.
 to be read again
\let
 \@@shortsectionnumber [EMAIL PROTECTED] \ifx \csname \??se #1
   \c!ownnumber 
 \endcsname \r...

 \makesectionformat ... \@@shortsectionnumber \let
   
 \@@shortsectionnumber \@@s...

 \rawreference ...veryreference \makesectionformat
   \writereference {#2} 
 {\sec...
 argument ...\finalsectionnumber }{\asciititle }}
   }\fi 
 \executeifdefined {\?...

 \douppercase ...rstoftwoarguments \edef \ascii {#1
   }\edef \ascii 
 {\expandafte...
 ...

 8---

 Using the trivial solution (\uppercase) does not work because with a 
 non-il1 regime it does not handle the accented characters (A umlat, O 
 umlaut) correctly. I use UTF, as it contains all the characters I need.

 So, what has changed in the \WORD? It works \WORD{fine} within text 
 but not in the headings.

 TIA,

 - Ville

 

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


-- 

-
  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] Uppercase headings

2006-03-31 Thread Hans Hagen
Ville Voipio wrote:

 I started to edit an old document with capitalized headings. Making 
 the headings was rather difficult (as can be seen on this list about a 
 year ago), and now it seems to have broken again.

 I have:

 \setuphead[title]
   [page=yes,
   before={\strut\blank[5*big]},
   after={\textrule\blank},
   align=middle,
   style=\tfb,
   textcommand=\WORD
   ]

it's nearly impossible to get this working for all features (keep in mind that 
tex has no real feature to map font chars to other font chars)  esp those with 
special chars. 

the best solution is to use a caps font (or to create a pseudo caps font ) 

btw, 

\starttext
  \title{test \eacute \beta}
\stoptext

works ok here (can you try the latest version - beta?) 

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] Uppercase headings

2006-03-31 Thread Ville Voipio
 it's nearly impossible to get this working for all features 
 (keep in mind that tex has no real feature to map font chars 
 to other font chars)  esp those with special chars. 

I know this is not a trivial question due to the number
of encodings and languages. However, what makes me a bit
puzzled is that the following works fine:

  \title{\WORD{Text with åäö etc.} }

So, the mechanism behind \WORD works well. It is just that
I cannot figure out how to use it. I emphasize that it used
to work fine even in the \setuphead definition, but that
was with an old version (April '05).

---

 works ok here (can you try the latest version - beta?) 

The version I am trying to use is rather a fresh one:

 TeXExec 5.4.3 - ConTeXt / PRAGMA ADE 1997-2005

   texexec : TeXExec 5.4.3 - ConTeXt / PRAGMA ADE 1997-2005
   texutil : TeXUtil 9.0.1 - ConTeXt / PRAGMA ADE 1992-2006
   tex : unknown
   context : ver: 2006.03.25 13:21
   cont-en : unknown
   cont-nl : unknown

Has there been any change after that? If not, I could brew up a
minimal example to illustrate the problem.

BR,

- Ville

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


Re: [NTG-context] Uppercase headings

2006-03-31 Thread Taco Hoekwater
Ville Voipio wrote:
 
 I started to edit an old document with capitalized headings. Making the 
 headings was rather difficult (as can be seen on this list about a year 
 ago), and now it seems to have broken again.
 
 I have:
 
 \setuphead[title]
   [page=yes,
   before={\strut\blank[5*big]},
   after={\textrule\blank},
   align=middle,
   style=\tfb,
   textcommand=\WORD
   ]
 
 This worked fine in the past. Not anymore:

Something like this is why there is a new syntax:

  \setuphead[title]
[deeptextcommand=\WORD]

Does that work?

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


Re: [NTG-context] Uppercase headings

2006-03-31 Thread Ville Voipio
  \setuphead[title]
[deeptextcommand=\WORD]

 Does that work?

It does, it does

You just saved my night. Can I send you a pint of beer somewhere?

---

I tried finding more information about deeptextcommand, but all I found was a 
brief comment about deep hooks in the release notes (19-Jan-06). I can write 
something about this into Wiki, but that requires me to understand a bit more. 
Where do I start looking for?

Thanks again,

- Ville
winmail.dat___
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context


Re: [NTG-context] Uppercase headings

2006-03-31 Thread Hans Hagen
Ville Voipio wrote:
  \setuphead[title]
[deeptextcommand=\WORD]

 Does that work?
 

 It does, it does

 You just saved my night. Can I send you a pint of beer somewhere?

 ---

 I tried finding more information about deeptextcommand, but all I found was a 
 brief comment about deep hooks in the release notes (19-Jan-06). I can write 
 something about this into Wiki, but that requires me to understand a bit 
 more. Where do I start looking for?
   
the source -) 

the problem with the non-deep command is that it gets more than just text fed 
... like the fontswitch, color, etc; if that info is subjected to uppercasing, 
strange side effects may appear; the deep command acts upon the text itself 

please, wikify this

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] Uppercase headings

2006-03-31 Thread Hans Hagen
Ville Voipio wrote:
  \setuphead[title]
[deeptextcommand=\WORD]

 Does that work?
 

 It does, it does

 You just saved my night. Can I send you a pint of beer somewhere?

 ---

 I tried finding more information about deeptextcommand, but all I found was a 
 brief comment about deep hooks in the release notes (19-Jan-06). I can write 
 something about this into Wiki, but that requires me to understand a bit 
 more. Where do I start looking for?
   

Don't do this if you don't want to get a nightmare ...

\def\ShowTwoArguments#1#2%
  {\showargument{#1}%
   \showargument{#2}}

\setuphead[chapter][command=\ShowTwoArguments]

\chapter{test}


-
  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