On 2017-01-17, Richard Heck wrote:
> On 01/17/2017 02:55 AM, Jürgen Spitzmüller wrote:
>> Am Montag, den 16.01.2017, 22:17 +0000 schrieb Guenter Milde:

>>> Now we have 3 specs:

>>> 1. Unicode: Break Opportunity Before and After

>>> 2. --- ligature: Break opportunity after, no hyphenation of word
>>> before
>>>    (also with literal EM DASH and \textemdash macro with non-TeX
>>> fonts).

>>> 3. \textemdash macro (and literal EM DASH with inputenc-utf8) and TeX
>>> fonts:
>>>    no break opportunity. Hyphenation of word before allowed.

>>> What should be the LyX behaviour?
>> 2.

> I agree with Jürgen, mostly because this is the old and expected
> behavior. On the other hand, I can see why \textemdash is useful for
> some people. I hate to suggest a preference, or document setting, but....?

Thank you for the fast responses.
We have a clear favourite, that is backwards compatible and should work as
expected for English and German (u.a.) use cases.


Possible implementations:

I suggest adding an "\allowbreak" after the \textemdash macro.

+1 keep configurability
+1 keep distinction of "real" EM DASH and --- (e.g. input via copy-past or
   with temporary spaces).
+1 almost backwards compatible
-1 hyphenation of the preceding word allowed wiht 8-bit fonts but not with
   Unicode fonts.

a) use "\textemdash\allowbreak" in lib/unicodesymbols and
   i)  "force=utf8"
   ii) an "emdash" feature that rebinds the EM DASH character (x2014)
         to "\textemdash\allowbreak" if the inputencoding is utf8.
         
b) redefine "\textemdash":

    \let\origtextemdash\textemdash
    \renewcommand{\textemdash}{\origtextemdash\allowbreak}

My preference is a)ii).   

Alternatively,

c) use "---" in lib/unicodesymbols and 
   procede as in a) for inputencoding utf8

Günter   

Reply via email to