ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* header to register
@ 2008-01-19 20:51 Henning Hraban Ramm
  2008-01-21  9:33 ` Wolfgang Schuster
  0 siblings, 1 reply; 17+ messages in thread
From: Henning Hraban Ramm @ 2008-01-19 20:51 UTC (permalink / raw)
  To: ConTeXt ML

Ahoi!

For a songbook I need a alphabetically sorted TOC.
As easy workaround I tried to use an register/index.
But I'd like to get my headers into the index without typing \index  
all the time.
But with my following setup I get only garbage numbers instead of my  
titles:

\setuphead[Titel]
[style={\hw\tfa}, page=yes, number=no, textcommand=\TitelFrame]
\def\TitelFrame#1{\index{#1}%
	\framed[
		width=\textwidth,
		height=7.5mm,
		frame=off,
		align={right,high},
		after={}, before={}]%
	{\switchtobodyfont[12pt]\hw\tfa #1}%
}

My .tuo file contains lines like:

\listentry{Titel}{2}{}{nihil ita ut videtur}{2--0-1-0-0-0-0-0--1}{3}%
...
\registerpage{index}{,}{1}{\dowritetolist \@@koppeling {}{nihil ita  
ut videtur}\v!head }}\fi \executeifdefined {\??ko Titel\c! 
deeptextcommand }\firstofoneargument {nihil ita ut videtur}\endstrut } 
{2--0-1-0-0-0-0-0--1}%

The 5th instead of the 4th parameter of \listentry is printed in the  
index.

My fault or a bug?


Versions:
This is pdfTeXk, Version 3.141592-1.40.3 (Web2C 7.5.6)
ConTeXt  ver: 2008.01.17 11:52 MKII  fmt: 2008.1.17  int: english/ 
english



Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net/texnique/
http://wiki.contextgarden.net
https://www.cacert.org (I'm an assurer)

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

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


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: header to register
  2008-01-19 20:51 header to register Henning Hraban Ramm
@ 2008-01-21  9:33 ` Wolfgang Schuster
  2008-01-21 20:04   ` Henning Hraban Ramm
  0 siblings, 1 reply; 17+ messages in thread
From: Wolfgang Schuster @ 2008-01-21  9:33 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Jan 19, 2008 9:51 PM, Henning Hraban Ramm <hraban@fiee.net> wrote:
> Ahoi!
>
> For a songbook I need a alphabetically sorted TOC.
> As easy workaround I tried to use an register/index.
> But I'd like to get my headers into the index without typing \index
> all the time.
> But with my following setup I get only garbage numbers instead of my
> titles:
>
> \setuphead[Titel]
> [style={\hw\tfa}, page=yes, number=no, textcommand=\TitelFrame]
> \def\TitelFrame#1{\index{#1}%
>         \framed[
>                 width=\textwidth,
>                 height=7.5mm,
>                 frame=off,
>                 align={right,high},
>                 after={}, before={}]%
>         {\switchtobodyfont[12pt]\hw\tfa #1}%
> }
>
> My .tuo file contains lines like:
>
> \listentry{Titel}{2}{}{nihil ita ut videtur}{2--0-1-0-0-0-0-0--1}{3}%
> ...
> \registerpage{index}{,}{1}{\dowritetolist \@@koppeling {}{nihil ita
> ut videtur}\v!head }}\fi \executeifdefined {\??ko Titel\c!
> deeptextcommand }\firstofoneargument {nihil ita ut videtur}\endstrut }
> {2--0-1-0-0-0-0-0--1}%
>
> The 5th instead of the 4th parameter of \listentry is printed in the
> index.
>
> My fault or a bug?

I haven't tested you example but you can try my solution.

\def\doplacesectiontitles#1:#2\relax
  {\line{#1\hfill\hbox to 3em{#2\hss}}}

\def\placesectiontitles#1%
  {\doplacesectiontitles#1\relax}

\definesorting
  [sectiontitle]
  [sectiontitles]

\setupsorting
  [sectiontitle]
  [criterium=all,
   command=\placesectiontitles]

\def\titleformat#1%
  {\bgroup
   \expanded{\sectiontitle[music:#1]{#1:\pagenumber}}%
   #1%
   \egroup}

\setuphead
  [chapter]
  [incrementnumber=list,
   coupling=chapter,
   deeptextcommand=\titleformat]

\def\placetitle
  {\setbox\scratchbox\vbox{\placelist[chapter][]}%
   \placelistofsectiontitles}

\starttext

\placetitle

\chapter{Knuth}\input knuth\par
\chapter{Tufte}\input tufte\par
\chapter{Reich}\input reich\par
\chapter{Materie}\input douglas\par
\chapter{Douglas}\input douglas\par
\chapter{Dawkins}\input dawkins\par
\chapter{Ward}\input ward\par
\chapter{Zapf}\input zapf\par
\chapter{Bryson}\input bryson\par
\chapter{Davis}\input davis\par
\chapter{Thuan}\input thuan\par
\chapter{Hawking}\input hawking\par
\chapter{Linden}\input linden\par
\chapter{Weisman}\input weisman\par

\stoptext

The names for the macros are not very well choosen and should be renamed
and the format the toc and the headers is also should be also changed but
the sorting works.

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

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


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: header to register
  2008-01-21  9:33 ` Wolfgang Schuster
@ 2008-01-21 20:04   ` Henning Hraban Ramm
  2008-01-22 10:30     ` Wolfgang Schuster
  2008-01-22 10:31     ` Wolfgang Schuster
  0 siblings, 2 replies; 17+ messages in thread
From: Henning Hraban Ramm @ 2008-01-21 20:04 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Am 2008-01-21 um 10:33 schrieb Wolfgang Schuster:

>> My .tuo file contains lines like:
>>
>> \listentry{Titel}{2}{}{nihil ita ut videtur}{2--0-1-0-0-0-0-0--1}{3}%
>> ...
>> \registerpage{index}{,}{1}{\dowritetolist \@@koppeling {}{nihil ita
>> ut videtur}\v!head }}\fi \executeifdefined {\??ko Titel\c!
>> deeptextcommand }\firstofoneargument {nihil ita ut videtur} 
>> \endstrut }
>> {2--0-1-0-0-0-0-0--1}%
>>
>> The 5th instead of the 4th parameter of \listentry is printed in the
>> index.
>>
>> My fault or a bug?
>
> I haven't tested you example but you can try my solution.

Thank you very much, but I'd like to stay with the index - I already  
added index entries for all my first lines of lyrics.
These entries work, but I'd really like to know why I get those  
numbers instead of my title strings.


Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net/texnique/
http://wiki.contextgarden.net
https://www.cacert.org (I'm an assurer)

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

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


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: header to register
  2008-01-21 20:04   ` Henning Hraban Ramm
@ 2008-01-22 10:30     ` Wolfgang Schuster
  2008-01-22 10:31     ` Wolfgang Schuster
  1 sibling, 0 replies; 17+ messages in thread
From: Wolfgang Schuster @ 2008-01-22 10:30 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Jan 21, 2008 9:04 PM, Henning Hraban Ramm <hraban@fiee.net> wrote:
> Am 2008-01-21 um 10:33 schrieb Wolfgang Schuster:
>
> >> My .tuo file contains lines like:
> >>
> >> \listentry{Titel}{2}{}{nihil ita ut videtur}{2--0-1-0-0-0-0-0--1}{3}%
> >> ...
> >> \registerpage{index}{,}{1}{\dowritetolist \@@koppeling {}{nihil ita
> >> ut videtur}\v!head }}\fi \executeifdefined {\??ko Titel\c!
> >> deeptextcommand }\firstofoneargument {nihil ita ut videtur}
> >> \endstrut }
> >> {2--0-1-0-0-0-0-0--1}%
> >>
> >> The 5th instead of the 4th parameter of \listentry is printed in the
> >> index.
> >>
> >> My fault or a bug?
> >
> > I haven't tested you example but you can try my solution.
>
> Thank you very much, but I'd like to stay with the index - I already
> added index entries for all my first lines of lyrics.
> These entries work, but I'd really like to know why I get those
> numbers instead of my title strings.
>
>
>
> Greetlings from Lake Constance!
> Hraban
> ---
> http://www.fiee.net/texnique/
> http://wiki.contextgarden.net
> https://www.cacert.org (I'm an assurer)
>
> ___________________________________________________________________________________
> If your question is of interest to others as well, please add an entry to the Wiki!
>
> maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
> archive  : https://foundry.supelec.fr/projects/contextrev/
> wiki     : http://contextgarden.net
> ___________________________________________________________________________________
>
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

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


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: header to register
  2008-01-21 20:04   ` Henning Hraban Ramm
  2008-01-22 10:30     ` Wolfgang Schuster
@ 2008-01-22 10:31     ` Wolfgang Schuster
  2008-01-23 21:04       ` Henning Hraban Ramm
  1 sibling, 1 reply; 17+ messages in thread
From: Wolfgang Schuster @ 2008-01-22 10:31 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Jan 21, 2008 9:04 PM, Henning Hraban Ramm <hraban@fiee.net> wrote:
> Am 2008-01-21 um 10:33 schrieb Wolfgang Schuster:
>
> >> My .tuo file contains lines like:
> >>
> >> \listentry{Titel}{2}{}{nihil ita ut videtur}{2--0-1-0-0-0-0-0--1}{3}%
> >> ...
> >> \registerpage{index}{,}{1}{\dowritetolist \@@koppeling {}{nihil ita
> >> ut videtur}\v!head }}\fi \executeifdefined {\??ko Titel\c!
> >> deeptextcommand }\firstofoneargument {nihil ita ut videtur}
> >> \endstrut }
> >> {2--0-1-0-0-0-0-0--1}%
> >>
> >> The 5th instead of the 4th parameter of \listentry is printed in the
> >> index.
> >>
> >> My fault or a bug?
> >
> > I haven't tested you example but you can try my solution.
>
> Thank you very much, but I'd like to stay with the index - I already
> added index entries for all my first lines of lyrics.
> These entries work, but I'd really like to know why I get those
> numbers instead of my title strings.

You could try to write \expanded{index{#1}} and use
deeptextcommand=\TitleFrame.

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

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


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: header to register
  2008-01-22 10:31     ` Wolfgang Schuster
@ 2008-01-23 21:04       ` Henning Hraban Ramm
  2008-01-28  8:16         ` Wolfgang Schuster
  0 siblings, 1 reply; 17+ messages in thread
From: Henning Hraban Ramm @ 2008-01-23 21:04 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Am 2008-01-22 um 11:31 schrieb Wolfgang Schuster:
> You could try to write \expanded{index{#1}} and use
> deeptextcommand=\TitleFrame.

Thank you, I always forget about \expanded, and I didn't know about  
deeptextcommand at all...

But it doesn't work, it stops with:

TitelNoToc      : - Inhalt
(./prd_creator.tuo
! Argument of \textormathspace has an extra }.
<inserted text>
                 \par
<to be read again>
                    }
\doregistertexthowto ...?id #1\c!textcommand }{#2}
                                                   \dostopattributes
\dohandleregisterentry ...exthowto {\v!index }{#1}
                                                   \fi \egroup \!! 
doneafalse
\c!entrya ...urround \z@ \ldots \textormathspace }
                                                   \global  
\firstregisterentr...
<argument> \c!entrya
                      \c!entryb \c!entryc \c!entryd
...
l.177 ...age{index}{,}{21}{2--0-6-0-0-0-0-0--5}{7}

probably caused by \dots in:
\Titel{Wach nun auf\dots}


with those definitions:

--- >8 ---
\def\dots{\thinspace.\thinspace.\thinspace.\thinspace}

\definehead[Titel][chapter]
\definehead[TitelNoToc][chapter]
\definehead[TitelNoPage][chapter]
\definehead[TitelKlein][chapter]
\def\TitelFrame#1{\expanded{\index{#1}}%
	\framed[
		width=\textwidth,
		height=7.5mm,
		frame=off,
		align={right,high},
		after={}, before={}]%
	{\switchtobodyfont[12pt]\hw\tfa #1}}
\def\TitelFrameKlein#1{\expanded{\index{#1}}%
	\framed[
		width=\textwidth,
		height=5mm,
		frame=off,
		align={right,high},
		after={}, before={}]%
	{\switchtobodyfont[10pt]\hw\tfb #1}}
\setuphead[Titel][page=yes, number=no, deeptextcommand=\TitelFrame]
\setuphead[TitelNoToc][page=yes, number=no, deeptextcommand=\TitelFrame]
\setuphead[TitelNoPage][page=no, number=no, deeptextcommand=\TitelFrame]
\setuphead[TitelKlein][page=no, number=no, deeptextcommand= 
\TitelFrameKlein]

--- 8< ---

Does that mean that must not use any commands (like \dots) in my  
\expanded{\index{#1}}?


Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net/texnique/
http://wiki.contextgarden.net
https://www.cacert.org (I'm an assurer)

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

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


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: header to register
  2008-01-23 21:04       ` Henning Hraban Ramm
@ 2008-01-28  8:16         ` Wolfgang Schuster
  2008-01-28 20:10           ` Henning Hraban Ramm
  0 siblings, 1 reply; 17+ messages in thread
From: Wolfgang Schuster @ 2008-01-28  8:16 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Jan 23, 2008 10:04 PM, Henning Hraban Ramm <hraban@fiee.net> wrote:
> Am 2008-01-22 um 11:31 schrieb Wolfgang Schuster:
> > You could try to write \expanded{index{#1}} and use
> > deeptextcommand=\TitleFrame.
>
> Thank you, I always forget about \expanded, and I didn't know about
> deeptextcommand at all...
>
> But it doesn't work, it stops with:
>
> TitelNoToc      : - Inhalt
> (./prd_creator.tuo
> ! Argument of \textormathspace has an extra }.
> <inserted text>
>                  \par
> <to be read again>
>                     }
> \doregistertexthowto ...?id #1\c!textcommand }{#2}
>                                                    \dostopattributes
> \dohandleregisterentry ...exthowto {\v!index }{#1}
>                                                    \fi \egroup \!!
> doneafalse
> \c!entrya ...urround \z@ \ldots \textormathspace }
>                                                    \global
> \firstregisterentr...
> <argument> \c!entrya
>                       \c!entryb \c!entryc \c!entryd
> ...
> l.177 ...age{index}{,}{21}{2--0-6-0-0-0-0-0--5}{7}
>
> probably caused by \dots in:
> \Titel{Wach nun auf\dots}
>
>
> with those definitions:
>
> --- >8 ---
> \def\dots{\thinspace.\thinspace.\thinspace.\thinspace}
>
> \definehead[Titel][chapter]
> \definehead[TitelNoToc][chapter]
> \definehead[TitelNoPage][chapter]
> \definehead[TitelKlein][chapter]
> \def\TitelFrame#1{\expanded{\index{#1}}%
>         \framed[
>                 width=\textwidth,
>                 height=7.5mm,
>                 frame=off,
>                 align={right,high},
>                 after={}, before={}]%
>         {\switchtobodyfont[12pt]\hw\tfa #1}}
> \def\TitelFrameKlein#1{\expanded{\index{#1}}%
>         \framed[
>                 width=\textwidth,
>                 height=5mm,
>                 frame=off,
>                 align={right,high},
>                 after={}, before={}]%
>         {\switchtobodyfont[10pt]\hw\tfb #1}}
> \setuphead[Titel][page=yes, number=no, deeptextcommand=\TitelFrame]
> \setuphead[TitelNoToc][page=yes, number=no, deeptextcommand=\TitelFrame]
> \setuphead[TitelNoPage][page=no, number=no, deeptextcommand=\TitelFrame]
> \setuphead[TitelKlein][page=no, number=no, deeptextcommand=
> \TitelFrameKlein]
>
> --- 8< ---
>
> Does that mean that must not use any commands (like \dots) in my
> \expanded{\index{#1}}?

You could use \unknown

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

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


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: header to register
  2008-01-28  8:16         ` Wolfgang Schuster
@ 2008-01-28 20:10           ` Henning Hraban Ramm
  2008-01-29 10:51             ` Wolfgang Schuster
  0 siblings, 1 reply; 17+ messages in thread
From: Henning Hraban Ramm @ 2008-01-28 20:10 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Am 2008-01-28 um 09:16 schrieb Wolfgang Schuster:

> On Jan 23, 2008 10:04 PM, Henning Hraban Ramm <hraban@fiee.net> wrote:
>> Am 2008-01-22 um 11:31 schrieb Wolfgang Schuster:
>>> You could try to write \expanded{index{#1}} and use
>>> deeptextcommand=\TitleFrame.
>>
>> Thank you, I always forget about \expanded, and I didn't know about
>> deeptextcommand at all...
>>
>> Does that mean that must not use any commands (like \dots) in my
>> \expanded{\index{#1}}?
>
> You could use \unknown

What should that do? And where/how would I use it?
Please don't expect me to know any lowlevel commands...

Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net/texnique/
http://wiki.contextgarden.net
https://www.cacert.org (I'm an assurer)

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

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


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: header to register
  2008-01-28 20:10           ` Henning Hraban Ramm
@ 2008-01-29 10:51             ` Wolfgang Schuster
  2008-01-29 14:31               ` Idris Samawi Hamid
  0 siblings, 1 reply; 17+ messages in thread
From: Wolfgang Schuster @ 2008-01-29 10:51 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Jan 28, 2008 9:10 PM, Henning Hraban Ramm <hraban@fiee.net> wrote:
> Am 2008-01-28 um 09:16 schrieb Wolfgang Schuster:
>
> > On Jan 23, 2008 10:04 PM, Henning Hraban Ramm <hraban@fiee.net> wrote:
> >> Am 2008-01-22 um 11:31 schrieb Wolfgang Schuster:
> >>> You could try to write \expanded{index{#1}} and use
> >>> deeptextcommand=\TitleFrame.
> >>
> >> Thank you, I always forget about \expanded, and I didn't know about
> >> deeptextcommand at all...
> >>
> >> Does that mean that must not use any commands (like \dots) in my
> >> \expanded{\index{#1}}?
> >
> > You could use \unknown
>
> What should that do? And where/how would I use it?
> Please don't expect me to know any lowlevel commands...

Hi Henning,

\unknown is no low level command, it is ConTeXt's command to produce
a ellipsis in the text, exactly what do you want to achieve with your \dots
command.

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

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


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: header to register
  2008-01-29 10:51             ` Wolfgang Schuster
@ 2008-01-29 14:31               ` Idris Samawi Hamid
  2008-01-29 16:35                 ` Wolfgang Schuster
  0 siblings, 1 reply; 17+ messages in thread
From: Idris Samawi Hamid @ 2008-01-29 14:31 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Tue, 29 Jan 2008 03:51:01 -0700, Wolfgang Schuster  
<schuster.wolfgang@googlemail.com> wrote:

>> > You could use \unknown
>>
>> What should that do? And where/how would I use it?
>> Please don't expect me to know any lowlevel commands...
>
> Hi Henning,
>
> \unknown is no low level command, it is ConTeXt's command to produce
> a ellipsis in the text, exactly what do you want to achieve with your  
> \dots
> command.

One can also use \textellipsis, which is more obvious ;-)

Idris

-- 
Professor Idris Samawi Hamid, Editor-in-Chief
International Journal of Shi`i Studies
Department of Philosophy
Colorado State University
Fort Collins, CO 80523

--
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

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


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: header to register
  2008-01-29 14:31               ` Idris Samawi Hamid
@ 2008-01-29 16:35                 ` Wolfgang Schuster
  2008-01-29 17:48                   ` Idris Samawi Hamid
  2008-01-30  8:43                   ` header to register Thomas A. Schmitz
  0 siblings, 2 replies; 17+ messages in thread
From: Wolfgang Schuster @ 2008-01-29 16:35 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Jan 29, 2008 3:31 PM, Idris Samawi Hamid <ishamid@colostate.edu> wrote:
> On Tue, 29 Jan 2008 03:51:01 -0700, Wolfgang Schuster
> <schuster.wolfgang@googlemail.com> wrote:
>
> >> > You could use \unknown
> >>
> >> What should that do? And where/how would I use it?
> >> Please don't expect me to know any lowlevel commands...
> >
> > Hi Henning,
> >
> > \unknown is no low level command, it is ConTeXt's command to produce
> > a ellipsis in the text, exactly what do you want to achieve with your
> > \dots
> > command.
>
> One can also use \textellipsis, which is more obvious ;-)

Try this:

\starttext
text\textellipsis

text\unknown
\stoptext

I prefer the second line (there a short discussion about this topic a
long time ago).

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

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


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: header to register
  2008-01-29 16:35                 ` Wolfgang Schuster
@ 2008-01-29 17:48                   ` Idris Samawi Hamid
  2008-01-29 20:01                     ` Henning Hraban Ramm
  2008-01-30  8:43                   ` header to register Thomas A. Schmitz
  1 sibling, 1 reply; 17+ messages in thread
From: Idris Samawi Hamid @ 2008-01-29 17:48 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Tue, 29 Jan 2008 09:35:12 -0700, Wolfgang Schuster  
<schuster.wolfgang@googlemail.com> wrote:

>> One can also use \textellipsis, which is more obvious ;-)
>
> Try this:
>
> \starttext
> text\textellipsis
>
> text\unknown
> \stoptext
>
> I prefer the second line

So do I. But I still use \dots mostly so I did not realize the difference;  
I thought they were the same (or forgot they are different).

Why the different definitions I wonder? Till then I'll proabably  
\let\textellipsis=\unknown.

> (there a short discussion about this topic a
> long time ago).

Yes, I was thinking of that when I wrote... need to research/review it  
again...

Best
Idris

-- 
Professor Idris Samawi Hamid, Editor-in-Chief
International Journal of Shi`i Studies
Department of Philosophy
Colorado State University
Fort Collins, CO 80523

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

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


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: header to register
  2008-01-29 17:48                   ` Idris Samawi Hamid
@ 2008-01-29 20:01                     ` Henning Hraban Ramm
  2008-01-29 20:09                       ` header to register (SOLVED) Henning Hraban Ramm
  0 siblings, 1 reply; 17+ messages in thread
From: Henning Hraban Ramm @ 2008-01-29 20:01 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Am 2008-01-29 um 18:48 schrieb Idris Samawi Hamid:

> So do I. But I still use \dots mostly so I did not realize the  
> difference;
> I thought they were the same (or forgot they are different).
>
> Why the different definitions I wonder? Till then I'll proabably
> \let\textellipsis=\unknown.
>
>> (there a short discussion about this topic a
>> long time ago).
>
> Yes, I was thinking of that when I wrote... need to research/review it
> again...

And I guess my usual redefinition of \dots as
\def\dots{\thinspace.\thinspace.\thinspace.\thinspace}
stems from one of that discussions.

But let me please revive the subject of this thread:
My problem is not with \dots, but with \index within a header command  
like this:

\setuphead[Titel][page=yes, number=no, textcommand=\TitelFrame]
\def\TitelFrame#1{\index{#1}%
	\framed[
		width=\textwidth,
		height=7.5mm,
		frame=off,
		align={right,high}]%
	{\hw\tfa #1}%
}

I can't tell if it's an expansion problem, but that's probable,  
because a single \index{foo} works.

Here's a rather minimal working example that shows the index problem  
(even if not the failure with my actual project):

\starttext

\def\MyTitle#1{{\index{#1}\bfa #1}}
\setuphead[chapter][page=no, number=no, textcommand=\MyTitle]


\chapter{Lalala}
\input tufte

\chapter{Bingo}
\input tufte

\chapter{Abrakadabra}
\input tufte

\completeindex

\stoptext



Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net/texnique/
http://wiki.contextgarden.net
https://www.cacert.org (I'm an assurer)

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

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


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: header to register (SOLVED)
  2008-01-29 20:01                     ` Henning Hraban Ramm
@ 2008-01-29 20:09                       ` Henning Hraban Ramm
  0 siblings, 0 replies; 17+ messages in thread
From: Henning Hraban Ramm @ 2008-01-29 20:09 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Am 2008-01-29 um 21:01 schrieb Henning Hraban Ramm:
> Here's a rather minimal working example that shows the index problem
> (even if not the failure with my actual project):

> \setuphead[chapter][page=no, number=no, textcommand=\MyTitle]

Sorry, in this case it's solvable with deeptextcommand=\MyTitle

And in my actual project I moved the \index to another place:

\def\TitelFrame#1{% Titel mit/ohne Formatierung
	\framed[
		width=\textwidth,
		height=7.5mm,
		frame=off,
		align={right,high},
		after={}, before={}]%
	{\index{#1}\switchtobodyfont[12pt]\hw\tfa #1}}

It doesn't work with \index before \framed or in before={}, what I  
tried before.

Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net/texnique/
http://wiki.contextgarden.net
https://www.cacert.org (I'm an assurer)

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

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


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: header to register
  2008-01-29 16:35                 ` Wolfgang Schuster
  2008-01-29 17:48                   ` Idris Samawi Hamid
@ 2008-01-30  8:43                   ` Thomas A. Schmitz
  2008-01-30 15:48                     ` Idris Samawi Hamid
  1 sibling, 1 reply; 17+ messages in thread
From: Thomas A. Schmitz @ 2008-01-30  8:43 UTC (permalink / raw)
  To: mailing list for ConTeXt users


On Jan 29, 2008, at 5:35 PM, Wolfgang Schuster wrote:

> Try this:
>
> \starttext
> text\textellipsis
>
> text\unknown
> \stoptext
>
> I prefer the second line (there a short discussion about this topic a
> long time ago).
>
> Wolfgang


Hi Wolfgang,

isn't this just a bug in lmodern? In any decent font, \textellipsis in  
fact gives exactly the output you get from \unknown here. There may be  
historical reasons why the glyph looks that way in cm and lm, but it  
certainly is unexpected compared to other fonts.

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

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


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: header to register
  2008-01-30  8:43                   ` header to register Thomas A. Schmitz
@ 2008-01-30 15:48                     ` Idris Samawi Hamid
  2008-01-30 19:11                       ` Henning Hraban Ramm
  0 siblings, 1 reply; 17+ messages in thread
From: Idris Samawi Hamid @ 2008-01-30 15:48 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Wed, 30 Jan 2008 01:43:46 -0700, Thomas A. Schmitz  
<thomas.schmitz@uni-bonn.de> wrote:

>> \starttext
>> text\textellipsis
>>
>> text\unknown
>> \stoptext
>>
>> I prefer the second line (there a short discussion about this topic a
>> long time ago).
>>
>> Wolfgang
>
>
> Hi Wolfgang,
>
> isn't this just a bug in lmodern? In any decent font, \textellipsis in
> fact gives exactly the output you get from \unknown here. There may be
> historical reasons why the glyph looks that way in cm and lm, but it
> certainly is unexpected compared to other fonts.

Or a bug in mkii:

enco-utf.tex:
Line 3055 : \def\textellipsis  {…} % HORIZONTAL ELLIPSIS

enco-def.tex:
\definecharacter textellipsis {\mathematics\cdots}

try this:

===============
% engine=luatex

\starttext
text\textellipsis

text\unknown
\stoptext
===============

Another big difference. \textellipsis behaves differently in mkii and mkiv.

Also, the lm ellipsis seems way too packed...

Best wishes
Idris

-- 
Professor Idris Samawi Hamid, Editor-in-Chief
International Journal of Shi`i Studies
Department of Philosophy
Colorado State University
Fort Collins, CO 80523

--
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

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

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: header to register
  2008-01-30 15:48                     ` Idris Samawi Hamid
@ 2008-01-30 19:11                       ` Henning Hraban Ramm
  0 siblings, 0 replies; 17+ messages in thread
From: Henning Hraban Ramm @ 2008-01-30 19:11 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Am 2008-01-30 um 16:48 schrieb Idris Samawi Hamid:

>> isn't this just a bug in lmodern? In any decent font,  
>> \textellipsis in
>> fact gives exactly the output you get from \unknown here. There  
>> may be
>> historical reasons why the glyph looks that way in cm and lm, but it
>> certainly is unexpected compared to other fonts.
>
> Or a bug in mkii:
>
> enco-utf.tex:
> Line 3055 : \def\textellipsis  {…} % HORIZONTAL ELLIPSIS
>
> enco-def.tex:
> \definecharacter textellipsis {\mathematics\cdots}

At least with Century Schoolbook on MkII \textellipsis is vertically  
shifted (like the colon · ), while \unknown or \dots sits on the  
baseline (…).

Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net/texnique/
http://wiki.contextgarden.net
https://www.cacert.org (I'm an assurer)

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

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


^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2008-01-30 19:11 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-01-19 20:51 header to register Henning Hraban Ramm
2008-01-21  9:33 ` Wolfgang Schuster
2008-01-21 20:04   ` Henning Hraban Ramm
2008-01-22 10:30     ` Wolfgang Schuster
2008-01-22 10:31     ` Wolfgang Schuster
2008-01-23 21:04       ` Henning Hraban Ramm
2008-01-28  8:16         ` Wolfgang Schuster
2008-01-28 20:10           ` Henning Hraban Ramm
2008-01-29 10:51             ` Wolfgang Schuster
2008-01-29 14:31               ` Idris Samawi Hamid
2008-01-29 16:35                 ` Wolfgang Schuster
2008-01-29 17:48                   ` Idris Samawi Hamid
2008-01-29 20:01                     ` Henning Hraban Ramm
2008-01-29 20:09                       ` header to register (SOLVED) Henning Hraban Ramm
2008-01-30  8:43                   ` header to register Thomas A. Schmitz
2008-01-30 15:48                     ` Idris Samawi Hamid
2008-01-30 19:11                       ` Henning Hraban Ramm

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).