• Hyphenation and U+00AD conditional hyphen

    From Stan Brown@21:1/5 to All on Sun Dec 17 11:47:52 2023
    NOTE: I use _ to represent U+00AD, the conditional hyphen.

    In my css I have
    body { hyphens:auto; }

    <https://drafts.csswg.org/css-text/#valdef-hyphens-auto> says
    "Automatic hyphenation opportunities elsewhere WITHIN A WORD must be
    ignored if the word contains a conditional hyphen. ... [emphasis
    added]"

    I don't know whether "within a word" is meant to include placing a
    conditional hyphen immediately before the first character of a word.
    If it is, that would make that word automatically hyphens:none, and
    one character is obviously shorter than <span class="..."> ...
    </span>

    Firefox (for several years now) does treat a leading conditional
    hyphen that way, and doesn't auto-hyphenate the word. For instance,
    "personal" breaks as "per- sonal"
    "_personal" goes to the next line as "personal"
    "person_al" goes to the next line as "personal"

    Chrome (the current version), however, just ignores the leading
    conditional hyphen though it does follow the spec for a conditional
    hyphen somewhere between the first and last characters of the word.
    For instance,
    "personal" breaks as "per- sonal"
    "_personal" breaks as "per- sonal"
    "person_al" goes to the next line as "personal"

    Is Chrome wrong here, or is a leading conditional hyphen not within
    the meaning of "Within a word" and UAs get to make up their own
    minds?

    (For those who may be wondering, the documents I'm preparing are not
    on the Web, but have a restricted audience where I can be sure that
    everyone's PC has the font I specify, and it's not important if they
    don't see hyphenation on their phones.)

    --
    Stan Brown, Tehachapi, California, USA
    https://BrownMath.com/

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Stan Brown@21:1/5 to Stan Brown on Mon Feb 19 16:15:25 2024
    Presumably this hasn't been answered because no one knows the answer,
    or the ones who do are uninterested in the topic. But I'm just giving
    it one more shot, in case a knowledgeable and interested person just
    happened not to see it.

    On Sun, 17 Dec 2023 11:47:52 -0800, Stan Brown wrote:

    NOTE: I use _ to represent U+00AD, the conditional hyphen.

    In my css I have
    body { hyphens:auto; }

    <https://drafts.csswg.org/css-text/#valdef-hyphens-auto> says
    "Automatic hyphenation opportunities elsewhere WITHIN A WORD must be
    ignored if the word contains a conditional hyphen. ... [emphasis
    added]"

    I don't know whether "within a word" is meant to include placing a conditional hyphen immediately before the first character of a word.
    If it is, that would make that word automatically hyphens:none, and
    one character is obviously shorter than <span class="..."> ...
    </span>

    Firefox (for several years now) does treat a leading conditional
    hyphen that way, and doesn't auto-hyphenate the word. For instance,
    "personal" breaks as "per- sonal"
    "_personal" goes to the next line as "personal"
    "person_al" goes to the next line as "personal"

    Chrome (the current version), however, just ignores the leading
    conditional hyphen though it does follow the spec for a conditional
    hyphen somewhere between the first and last characters of the word.
    For instance,
    "personal" breaks as "per- sonal"
    "_personal" breaks as "per- sonal"
    "person_al" goes to the next line as "personal"

    Is Chrome wrong here, or is a leading conditional hyphen not within
    the meaning of "Within a word" and UAs get to make up their own
    minds?

    (For those who may be wondering, the documents I'm preparing are not
    on the Web, but have a restricted audience where I can be sure that everyone's PC has the font I specify, and it's not important if they
    don't see hyphenation on their phones.)



    --
    Stan Brown, Tehachapi, California, USA
    https://BrownMath.com/

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)