[XeTeX] hyphenating words with hyphen

Vadim Radionov vadim.radionov at gmail.com
Tue Oct 6 19:03:36 CEST 2009


It should be defined, I suppose.  But it often takes full 1000 units,
i.e., 10pt in 10pt size, be "m" 810 or 850 (I just looked at ITC
Charter and Caslon 540).

In Russian typography, the dash is usually about 20% shorter and has
nonzero side-bearings giving the effect of a thin space around the
dash.  That's not my own invention :)

Yours,

Vadim

On Tue, Oct 6, 2009 at 8:42 PM, Rembrandt Wolpert <wolpert at uark.edu> wrote:
>> x-scaling the em-dash which is often two wide
>
> I don't think the m-dash is "often too wide": it is defined by the length of
> "m" in the particular font. I think you wanted to say that you don't like
> the size of an m-dash and want an in-between-n-and-m-dash (now that's
> something for hyphenation :-)). I'm not sure if this is good typographical
> practice, though.
>
> Rembrandt
>
>
> On Tue, Oct 6, 2009 at 7:14 AM, Vadim Radionov <vadim.radionov at gmail.com>
> wrote:
>>
>> Thank you, Jonathan,
>>
>> That was my obvious typo -- i mixed up these two token lists.  This
>> way it works
>> fine!
>>
>> Yours,
>>
>> Vadim
>>
>> PS.  Another problem I've tried to solve with  \XeTeXinterchartoks is
>> x-scaling the em-dash which is often two wide (and copyright sometimes
>> prohibits changing the font itself).   So I can put
>>
>> \newXeTeXintercharclass\cyrdash
>> \XeTeXcharclass `\—\cyrdash
>> \XeTeXinterchartoks 0 \cyrdash = {\nobreak\hskip.125em\scalebox{.75}[1]}
>> \XeTeXinterchartoks \cyrdash 0 = {\hskip.125em}
>>
>> leaving no spaces around the dash. But unfortunately this does not
>> work in the very beinning of the paragraph.
>>
>>
>>
>> On Tue, Oct 6, 2009 at 3:47 PM, Jonathan Kew <jfkthame at googlemail.com>
>> wrote:
>> > On 6 Oct 2009, at 00:11, Vadim Radionov wrote:
>> >
>> >> Dear all,
>> >>
>> >> I'm missing this important detail in the manuals: what is the natural
>> >> way to get words with hyphen hyphenated in other places than that
>> >> hyphen?
>> >>
>> >> I tried
>> >>
>> >> \XeTeXinterchartokenstate 1
>> >>
>> >> \XeTeXcharclass `\- 150
>> >> \XeTeXinterchartoks 150 0 = {\nobreak\hskip0pt}
>> >> \XeTeXinterchartoks 0 150 = {\hskip0pt}
>> >>
>> >> and it works almost well -- except for, surprisingly, allowing a break
>> >> *before* the hyphen.
>> >
>> > That's not surprising: before the hyphen (class transition from 0->150),
>> > you
>> > have an \hskip. After it (150->0), you have \nobreak\hskip, so you won't
>> > get
>> > a break there -- though you might get one anyway because of the
>> > discretionary node that's automatically inserted after the hyphen.
>> >
>> > I think you want
>> >
>> >> \XeTeXinterchartoks 0 150 = {\nobreak\hskip0pt}
>> >
>> > to ensure that the \hskip before the hyphen is never taken as a possible
>> > breakpoint.
>> >
>> > (BTW, it would be better to use \newXeTeXintercharclass rather than
>> > picking
>> > an arbitrary number...)
>> >
>> > JK
>> >
>> >
>
>


More information about the XeTeX mailing list