-
Notifications
You must be signed in to change notification settings - Fork 659
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[css-overflow][css-text-decor] should text-decoration include ellipsis? #6531
Comments
My perhaps-naive assumption would be that it does apply; other text effects, like 'color', do. |
The CSS Working Group just discussed The full IRC log of that discussion<fremy> Topic: should text-decoration include ellipsis?<astearns> github: https://github.com//issues/6531 <florian> q+ <fremy> fantasai: I have no strong opinion on this issue <fremy> TabAtkins: The question is whether the text decoration should apply to the ellipsis dots <fremy> TabAtkins: currently all implementations don't do it <fremy> TabAtkins: but the dots use the font, color, etc of the text it replaces <tantek> interesting that every implementation "missed it" <fremy> TabAtkins: so this seems like a bug to me <astearns> ack florian <fremy> TabAtkins: but are there implementations where this would be difficult to do? <PeterC> q+ <tantek> I’m curious if there's author consensus on this rather than reasoning from a spec/purity perspective <fremy> florian: my intuition is similar <fremy> florian: an issue is that the ellipsis is not supposed to be scrollable <fremy> florian: so that makes it different from the rest of the text <iank_> q+ <fremy> florian: because the text is located elsewhere <fremy> florian: so it's a different line, not the same line <fremy> TabAtkins: ah yes, if you have a wavy underline, the junction would be very undefined <astearns> ack PeterC <tantek> q? <tantek> I'm not seeing any author input on the issue <fremy> TabAtkins: so, this looks more like an abspos, which don't have text decoration inherit <fremy> PeterC: from an implementation perspective, if the text is using a color font and the following characters might or might have had color characters <fremy> PeterC: it's not clear what the implementation should do with the ellispsis <astearns> ack iank_ <fremy> PeterC: but indeed that doesn't sound like easy case all the time <fremy> iank_: I think the scrolling of ellipsis is not a requirement, it's a may <fremy> iank_: we would likely object to a change to make normative <tantek> q+ to say I’m a soft -1 on this, absent any author input/prefs on this, I’d rather NOT ask implementaitons to change something they happen to be interoperable on <fremy> iank_: because we want to keep shaping <fremy> iank_: so we would not want to make it an abspos <astearns> ack tantek <Zakim> tantek, you wanted to say I’m a soft -1 on this, absent any author input/prefs on this, I’d rather NOT ask implementaitons to change something they happen to be interoperable <Zakim> ... on <fremy> iank_: webkit does the same <fremy> iank_: but not firefox, which does the abspos <fremy> tantek: I haven't seen much request for it <fremy> tantek: and we have interop now <fremy> tantek: so maybe not changing is an option too <fremy> astearns: ok, time is up, let's bring this back to the issue |
@bfgeek During the call you objected to "ellipsis at paint time" (and thus, "keep the ellipsis in place as you scroll the content"), because Chromium does text shaping between the final text before the clip and the ellipsis itself. That isn't actually what the spec requires, tho, if I'm reading it correctly - it's allowed to do that shaping, and @frivoal was talking about just reshaping as different characters popped in as the "visual edge" of the overflowing content. I understand, tho, that "invoke text-shaping during accelerated scrolling" isn't very viable, and the two current solutions (ellipsize once and scroll the text+ellipsis as a block, or spam the ellipsis as a paint-time effect over the content) are more amenable there. |
A possibly-related question: should Testing current browsers with
indicates that:
|
Possible complication there is that hyphens aren't responsive to scrolling, whereas the ellipsis is (per spec) intended to be. (At least, not accelerated scrolling; if you trigger layout changes such that text is re-laid out, that's a different story.) (I think it's thus clear that the decoration should apply to the hyphen, as it's very straightforwardly Just Some Text.) |
Agree that the scrolling issue is a difference. However, it's less clear to me that a (soft) hyphen is Just Some Text and so necessarily carries the decoration. The hyphen is a transient rendering-time effect that arises just because of the particular context in which the text is being shown; it is not part of the textual data (most evidently in the case of auto-hyphenation, when there's not even In that respect, it's very much like the ellipsis; neither of them are "present" in the text. |
There are a lot of sutble interactions with now the spec is currently worded which aren't ideal in my opinion. (As a note - there are lots of shoulds in the section when its trying specify the scrolling behaviour - turning these shoulds into musts is what I'd object to).
Its important to realize here also that the "overflow: scroll" case isn't how "text-overflow: ellipsis" is being used by authors. The primary case is the "overflow: hidden" case. |
My point is that the hyphen is present as a direct result of, and integral to, text layout. The presence/location of the hyphen won't change for anything short of a text re-layout; as such, it has as much "solidity" on the page as literal text does. The ellipsis is, in some situations, opposed to that, where it can change its presence/location on things that don't otherwise cause text layout, such as scrolling.
Tongue-in-cheek counterpoint: marquee usage, for ellipsizing long song titles as they scroll back and forth automatically. |
Which are implemented with composited transform animations 😜 . |
Given the following (demo), should the decorations extend to cover the “…” or “,,,”?
No known impl says yes, but I couldn’t find it specified anywhere in css-overflow or css-text-decor. @mrego thought it would be good to ask after seeing this code in Chromium:
The text was updated successfully, but these errors were encountered: