ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Problem with hanging punctuation - a bug?
@ 2009-11-30  8:55 Tomas Bures
  2009-11-30 10:56 ` Hans Hagen
  2009-11-30 10:56 ` Taco Hoekwater
  0 siblings, 2 replies; 9+ messages in thread
From: Tomas Bures @ 2009-11-30  8:55 UTC (permalink / raw)
  To: ntg-context

[-- Attachment #1: Type: text/plain, Size: 4381 bytes --]

Dear all,

I've noticed some strange behavior of hanging punctuation (protrusion). 
The hyphens in hyphenated words are sometimes protruded and sometimes not.

I wasn't able to find out the rule, but I managed to reduce the problem 
to having just one paragraph that repeats several times in the document. 
You may notice that the last two paragraphs do not have the hyphens 
protruded.

In my original document, I'm using Minion Pro, however, I was able to 
reproduce this strange behavior with Pagella as well.

I'm attaching PDF showing this behavior. The contex source file is below.

Please, does anyone know how to fix this strange behavior? I would like 
to keep the protrusion as it makes the whole document better aligned.

Thank you very much. Best regards,
Tomas



\mainlanguage[cs]

\definefontfeature[ssp-default][default][protrusion=quality,expansion=quality]

\starttypescript[serif][pagella]
   \definefontsynonym[Pagella-Regular]    [file:texgyrepagella-regular]
\stoptypescript

\starttypescript[serif][pagella]
   \definefontsynonym[Serif]           [Pagella-Regular] 
[features=ssp-default]
\stoptypescript

\definetypeface[ssp][rm][serif][pagella][default]


\setupbodyfont[ssp,12pt]

\setupalign[hanging,hz]

\setuppapersize[A5][A5]

\setuplayout[grid=yes]

\setupindenting[small,yes]

\showgrid

\starttext

Sankránti je jeden z~nejdůležitějších svátků. Pro lidstvo je svátkem 
prakticky každý den. Lidé si však ve své nevědomosti vyhradili jako 
svátky jen několik dnů a~ostatní jsou dny obyčejné. Mnozí slaví tento 
den, aniž by opravdu znali jeho význam. V~této části světa dnes lidé 
uctívají krávy a~býky. Býci jsou vybraně zkrášleni množstvím ozdob 
a~látek a~voděni po ulicích. Nazývají je gangiréddulu (posvátní býci). 
A~nejen to, býky a~krávy symbolicky oddávají. Osoba, která ozdobeného 
býka vede se nazývá gangiréddudásu.

Sankránti je jeden z~nejdůležitějších svátků. Pro lidstvo je svátkem 
prakticky každý den. Lidé si však ve své nevědomosti vyhradili jako 
svátky jen několik dnů a~ostatní jsou dny obyčejné. Mnozí slaví tento 
den, aniž by opravdu znali jeho význam. V~této části světa dnes lidé 
uctívají krávy a~býky. Býci jsou vybraně zkrášleni množstvím ozdob 
a~látek a~voděni po ulicích. Nazývají je gangiréddulu (posvátní býci). 
A~nejen to, býky a~krávy symbolicky oddávají. Osoba, která ozdobeného 
býka vede se nazývá gangiréddudásu.

Sankránti je jeden z~nejdůležitějších svátků. Pro lidstvo je svátkem 
prakticky každý den. Lidé si však ve své nevědomosti vyhradili jako 
svátky jen několik dnů a~ostatní jsou dny obyčejné. Mnozí slaví tento 
den, aniž by opravdu znali jeho význam. V~této části světa dnes lidé 
uctívají krávy a~býky. Býci jsou vybraně zkrášleni množstvím ozdob 
a~látek a~voděni po ulicích. Nazývají je gangiréddulu (posvátní býci). 
A~nejen to, býky a~krávy symbolicky oddávají. Osoba, která ozdobeného 
býka vede se nazývá gangiréddudásu.

Sankránti je jeden z~nejdůležitějších svátků. Pro lidstvo je svátkem 
prakticky každý den. Lidé si však ve své nevědomosti vyhradili jako 
svátky jen několik dnů a~ostatní jsou dny obyčejné. Mnozí slaví tento 
den, aniž by opravdu znali jeho význam. V~této části světa dnes lidé 
uctívají krávy a~býky. Býci jsou vybraně zkrášleni množstvím ozdob 
a~látek a~voděni po ulicích. Nazývají je gangiréddulu (posvátní býci). 
A~nejen to, býky a~krávy symbolicky oddávají. Osoba, která ozdobeného 
býka vede se nazývá gangiréddudásu.

Sankránti je jeden z~nejdůležitějších svátků. Pro lidstvo je svátkem 
prakticky každý den. Lidé si však ve své nevědomosti vyhradili jako 
svátky jen několik dnů a~ostatní jsou dny obyčejné. Mnozí slaví tento 
den, aniž by opravdu znali jeho význam. V~této části světa dnes lidé 
uctívají krávy a~býky. Býci jsou vybraně zkrášleni množstvím ozdob 
a~látek a~voděni po ulicích. Nazývají je gangiréddulu (posvátní býci). 
A~nejen to, býky a~krávy symbolicky oddávají. Osoba, která ozdobeného 
býka vede se nazývá gangiréddudásu.

\stoptext

[-- Attachment #2: bug.pdf --]
[-- Type: application/pdf, Size: 17665 bytes --]

[-- Attachment #3: Type: text/plain, Size: 486 bytes --]

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

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

* Re: Problem with hanging punctuation - a bug?
  2009-11-30  8:55 Problem with hanging punctuation - a bug? Tomas Bures
@ 2009-11-30 10:56 ` Hans Hagen
  2009-11-30 10:56 ` Taco Hoekwater
  1 sibling, 0 replies; 9+ messages in thread
From: Hans Hagen @ 2009-11-30 10:56 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Tomas Bures wrote:
> Dear all,
> 
> I've noticed some strange behavior of hanging punctuation (protrusion). 
> The hyphens in hyphenated words are sometimes protruded and sometimes not.
> 
> I wasn't able to find out the rule, but I managed to reduce the problem 
> to having just one paragraph that repeats several times in the document. 
> You may notice that the last two paragraphs do not have the hyphens 
> protruded.
> 
> In my original document, I'm using Minion Pro, however, I was able to 
> reproduce this strange behavior with Pagella as well.
> 
> I'm attaching PDF showing this behavior. The contex source file is below.
> 
> Please, does anyone know how to fix this strange behavior? I would like 
> to keep the protrusion as it makes the whole document better aligned.

we found out that there is a buglet in luatex itself so you have to wait 
till the next luatex release; a temporary fix is:

\let\textdir\gobblethreearguments

but make sure that you remove such a hack after an update

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

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


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

* Re: Problem with hanging punctuation - a bug?
  2009-11-30  8:55 Problem with hanging punctuation - a bug? Tomas Bures
  2009-11-30 10:56 ` Hans Hagen
@ 2009-11-30 10:56 ` Taco Hoekwater
  2009-11-30 11:44   ` Tomas Bures
  2009-11-30 17:33   ` Superscript-fontfeature for footnotenumbers Andreas Harder
  1 sibling, 2 replies; 9+ messages in thread
From: Taco Hoekwater @ 2009-11-30 10:56 UTC (permalink / raw)
  To: mailing list for ConTeXt users



Tomas Bures wrote:
> Dear all,
> 
> I've noticed some strange behavior of hanging punctuation (protrusion).
> The hyphens in hyphenated words are sometimes protruded and sometimes not.

It is a bug in luatex that will be fixed in the next beta. For the
moment (assuming you do not need multi-directional output) the
workaround is to add

  \def\textdir#1#2#3{}

to your document preamble.

Best wishes,
Taco


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


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

* Re: Problem with hanging punctuation - a bug?
  2009-11-30 10:56 ` Taco Hoekwater
@ 2009-11-30 11:44   ` Tomas Bures
  2009-11-30 17:33   ` Superscript-fontfeature for footnotenumbers Andreas Harder
  1 sibling, 0 replies; 9+ messages in thread
From: Tomas Bures @ 2009-11-30 11:44 UTC (permalink / raw)
  To: ntg-context

Wonderful! It works now. Thank you very much Hans and Taco.

Tomas

On 11/30/2009 11:56 AM, Taco Hoekwater wrote:
>
>
> Tomas Bures wrote:
>> Dear all,
>>
>> I've noticed some strange behavior of hanging punctuation (protrusion).
>> The hyphens in hyphenated words are sometimes protruded and sometimes not.
>
> It is a bug in luatex that will be fixed in the next beta. For the
> moment (assuming you do not need multi-directional output) the
> workaround is to add
>
>    \def\textdir#1#2#3{}
>
> to your document preamble.
>
> Best wishes,
> Taco
>
>
> ___________________________________________________________________________________
> 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
___________________________________________________________________________________


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

* Superscript-fontfeature for footnotenumbers
  2009-11-30 10:56 ` Taco Hoekwater
  2009-11-30 11:44   ` Tomas Bures
@ 2009-11-30 17:33   ` Andreas Harder
  2009-11-30 17:47     ` Hans Hagen
  1 sibling, 1 reply; 9+ messages in thread
From: Andreas Harder @ 2009-11-30 17:33 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Hi all,

I'm trying to set the superscript-fontfeature for footnote-numbers, but there isn't a '(text)numberstyle'-command, so what's the way to achieve this?

So far I've this:

\starttypescript [serif] [linlibertine]
  \definefontsynonym [Serif] [LinLibertine-Regular] [features=default]
\stoptypescript

\starttypescript [serif] [linlibertine]
  \definefontsynonym [LinLibertine-Regular] [name:linuxlibertineo] [features=default]
\stoptypescript

\starttypescript [linlibertine]
  \definetypeface [linlibertine] [rm] [serif] [linlibertine] [default]
\stoptypescript

\definefontfeature[sups][sups=yes]

\usetypescript[linlibertine]
\setupbodyfont[linlibertine]

% \defineconversion[sups][\red\setff{sups}\arabicnumerals]
\definestructureconversionset[sups][][Romannumerals]

\setupnote
  [footnote]
  [command=\myfootnotecommand,
  % numberconversionset=sups,
  % textnumberstyle=\setff{sups}, % would be nice
  ]

\def\myfootnotecommand#1{\hbox to .5em{\setff{sups}#1}}


\starttext 
\dorecurse{12}{This\footnote{Hello World #1} is a test. }
\stoptext


Thanks in advance

	Andreas
___________________________________________________________________________________
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
___________________________________________________________________________________


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

* Re: Superscript-fontfeature for footnotenumbers
  2009-11-30 17:33   ` Superscript-fontfeature for footnotenumbers Andreas Harder
@ 2009-11-30 17:47     ` Hans Hagen
  2009-11-30 17:54       ` Andreas Harder
  0 siblings, 1 reply; 9+ messages in thread
From: Hans Hagen @ 2009-11-30 17:47 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Andreas Harder wrote:
> Hi all,
> 
> I'm trying to set the superscript-fontfeature for footnote-numbers, but there isn't a '(text)numberstyle'-command, so what's the way to achieve this?
> 
> So far I've this:
> 
> \starttypescript [serif] [linlibertine]
>   \definefontsynonym [Serif] [LinLibertine-Regular] [features=default]
> \stoptypescript
> 
> \starttypescript [serif] [linlibertine]
>   \definefontsynonym [LinLibertine-Regular] [name:linuxlibertineo] [features=default]
> \stoptypescript
> 
> \starttypescript [linlibertine]
>   \definetypeface [linlibertine] [rm] [serif] [linlibertine] [default]
> \stoptypescript
> 
> \definefontfeature[sups][sups=yes]
> 
> \usetypescript[linlibertine]
> \setupbodyfont[linlibertine]
> 
> % \defineconversion[sups][\red\setff{sups}\arabicnumerals]
> \definestructureconversionset[sups][][Romannumerals]
> 
> \setupnote
>   [footnote]
>   [command=\myfootnotecommand,
>   % numberconversionset=sups,
>   % textnumberstyle=\setff{sups}, % would be nice
>   ]
> 
> \def\myfootnotecommand#1{\hbox to .5em{\setff{sups}#1}}
> 
> 
> \starttext 
> \dorecurse{12}{This\footnote{Hello World #1} is a test. }
> \stoptext

I need to look into the numberstyle comand as well as some duplicate 
command being applied but here is a test

\setupnote
   [footnote]
   [command=Z,
    style=X,
    textstyle=Q,
    numbercommand=N\setff{sups},
    textcommand=T\setff{sups},
    numberstyle=S\setff{sups},
   %style=\setff{sups}, % interesting effect
   ]

for the moment stick to

\setupnote
   [footnote]
   [command=,
    textstyle=,
    numbercommand=\setff{sups},
    textcommand=\setff{sups}]






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

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


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

* Re: Superscript-fontfeature for footnotenumbers
  2009-11-30 17:47     ` Hans Hagen
@ 2009-11-30 17:54       ` Andreas Harder
  2009-11-30 23:01         ` Hans Hagen
  0 siblings, 1 reply; 9+ messages in thread
From: Andreas Harder @ 2009-11-30 17:54 UTC (permalink / raw)
  To: mailing list for ConTeXt users


Am 30.11.2009 um 18:47 schrieb Hans Hagen:

> Andreas Harder wrote:
>> Hi all,
>> I'm trying to set the superscript-fontfeature for footnote-numbers, but there isn't a '(text)numberstyle'-command, so what's the way to achieve this?
>> So far I've this:
>> \starttypescript [serif] [linlibertine]
>>  \definefontsynonym [Serif] [LinLibertine-Regular] [features=default]
>> \stoptypescript
>> \starttypescript [serif] [linlibertine]
>>  \definefontsynonym [LinLibertine-Regular] [name:linuxlibertineo] [features=default]
>> \stoptypescript
>> \starttypescript [linlibertine]
>>  \definetypeface [linlibertine] [rm] [serif] [linlibertine] [default]
>> \stoptypescript
>> \definefontfeature[sups][sups=yes]
>> \usetypescript[linlibertine]
>> \setupbodyfont[linlibertine]
>> % \defineconversion[sups][\red\setff{sups}\arabicnumerals]
>> \definestructureconversionset[sups][][Romannumerals]
>> \setupnote
>>  [footnote]
>>  [command=\myfootnotecommand,
>>  % numberconversionset=sups,
>>  % textnumberstyle=\setff{sups}, % would be nice
>>  ]
>> \def\myfootnotecommand#1{\hbox to .5em{\setff{sups}#1}}
>> \starttext \dorecurse{12}{This\footnote{Hello World #1} is a test. }
>> \stoptext
> 
> I need to look into the numberstyle comand as well as some duplicate command being applied but here is a test
> 
> \setupnote
>  [footnote]
>  [command=Z,
>   style=X,
>   textstyle=Q,
>   numbercommand=N\setff{sups},
>   textcommand=T\setff{sups},
>   numberstyle=S\setff{sups},
>  %style=\setff{sups}, % interesting effect
>  ]
> 
> for the moment stick to
> 
> \setupnote
>  [footnote]
>  [command=,
>   textstyle=,
>   numbercommand=\setff{sups},
>   textcommand=\setff{sups}]

Thank you, it works! … and was so easy

Andreas
___________________________________________________________________________________
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
___________________________________________________________________________________


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

* Re: Superscript-fontfeature for footnotenumbers
  2009-11-30 17:54       ` Andreas Harder
@ 2009-11-30 23:01         ` Hans Hagen
  2009-12-01 13:18           ` Andreas Harder
  0 siblings, 1 reply; 9+ messages in thread
From: Hans Hagen @ 2009-11-30 23:01 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Andreas Harder wrote:

>> I need to look into the numberstyle comand as well as some duplicate command being applied but here is a test

\setupenumerations
   [footnote]
   [     style=\type{(es)},
     headstyle=\type{(hs)}]

\setupnote
   [footnote]
   [        style=\type{(s)},
          command=\type{(c)},
      textcommand=\type{(tc)},
        textstyle=\type{(ts)},
      numberstyle=\type{(ns)},
    numbercommand=\type{(nc)}]

\setuplayout[backspace=6cm,marginwidth=cm,width=middle]

\starttext
     \dorecurse{9}{This\footnote{Hello World #1} is a test.\par }
\stoptext

i added numberstyle ... this test shows where thinsg end up

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

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


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

* Re: Superscript-fontfeature for footnotenumbers
  2009-11-30 23:01         ` Hans Hagen
@ 2009-12-01 13:18           ` Andreas Harder
  0 siblings, 0 replies; 9+ messages in thread
From: Andreas Harder @ 2009-12-01 13:18 UTC (permalink / raw)
  To: mailing list for ConTeXt users


Am 01.12.2009 um 00:01 schrieb Hans Hagen:

> Andreas Harder wrote:
> 
>>> I need to look into the numberstyle comand as well as some duplicate command being applied but here is a test
> 
> \setupenumerations
>  [footnote]
>  [     style=\type{(es)},
>    headstyle=\type{(hs)}]
> 
> \setupnote
>  [footnote]
>  [        style=\type{(s)},
>         command=\type{(c)},
>     textcommand=\type{(tc)},
>       textstyle=\type{(ts)},
>     numberstyle=\type{(ns)},
>   numbercommand=\type{(nc)}]
> 
> \setuplayout[backspace=6cm,marginwidth=cm,width=middle]
> 
> \starttext
>    \dorecurse{9}{This\footnote{Hello World #1} is a test.\par }
> \stoptext
> 
> i added numberstyle ... this test shows where thinsg end up

Thank you, this make things clear.

Greetings,
	Andreas
___________________________________________________________________________________
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
___________________________________________________________________________________


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

end of thread, other threads:[~2009-12-01 13:18 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-11-30  8:55 Problem with hanging punctuation - a bug? Tomas Bures
2009-11-30 10:56 ` Hans Hagen
2009-11-30 10:56 ` Taco Hoekwater
2009-11-30 11:44   ` Tomas Bures
2009-11-30 17:33   ` Superscript-fontfeature for footnotenumbers Andreas Harder
2009-11-30 17:47     ` Hans Hagen
2009-11-30 17:54       ` Andreas Harder
2009-11-30 23:01         ` Hans Hagen
2009-12-01 13:18           ` Andreas Harder

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).