- From: CSS Meeting Bot via GitHub <sysbot+gh@w3.org>
- Date: Mon, 01 Aug 2022 16:26:58 +0000
- To: public-css-archive@w3.org
The CSS Working Group just discussed `Underline Position for decorating box`. <details><summary>The full IRC log of that discussion</summary> <fantasai> Topic: Underline Position for decorating box<br> <fantasai> github: https://github.com/w3c/csswg-drafts/issues/5002<br> <TabAtkins> fantasai: undeline position requires udnerline to not move<br> <TabAtkins> fantasai: If the underline cuts thru text, the browser should have chosen initial position better<br> <TabAtkins> fantasai: but it shouldn't break it and shift some of them<br> <TabAtkins> fantasai: firefox avoids splitting. could be smarter about positioning, but it works<br> <fremy> q+<br> <TabAtkins> fantasai: but other browsers break the underline depending on vertical-align<br> <TabAtkins> iank_: our most recent beahvior is [missed]<br> <dbaron> s/[missed]/in Chrome Canary but not Chrome Stable/<br> <TabAtkins> iank_: I believe our current canary matches firefox in this case<br> <dbaron> iank_: When we filed this issue we were only investigating the issue.<br> <TabAtkins> iank_: We'll take the dominant baseline<br> <TabAtkins> iank_: so this should get us similar to firefox<br> <TabAtkins> fremy: our behavior we had with edge was intentional<br> <TabAtkins> fremy: woudln't break the line when the text was above the natural baseline, but would when it went lower<br> <TabAtkins> fremy: you never want underline to be striking thru text<br> <TabAtkins> fremy: but it does mean that with the new ink-skipping beahvior, it's probably not as bad to have the line go thru the text, since it doesn't visually cross it actually<br> <TabAtkins> fremy: so even tho i'd initially have said the edge behavior was what authors want, these days since we have ink-skipping the "always just use one baseline" is better<br> <TabAtkins> fremy: espeically if it's simpler and matches impls<br> <Rossen_> q?<br> <Rossen_> ack fremy<br> <TabAtkins> fantasai: So fremy i think you're proposing the spec doesn't change, and we encourage that the underline doesn't move for subscripts, but instead ink-skips as normal<br> <TabAtkins> fremy: I think ink-skipping is enabled by default?<br> <TabAtkins> fantasai: there's a handful of cjk characters that don't ink-skip, becuase they caused too much<br> <TabAtkins> fantasai: but i think they're not frequently used as subscripts<br> <TabAtkins> fremy: i think the edge issue was to break the baseline if it didn't ink skip, since we do ink-skip now that's not necessary<br> <TabAtkins> fantasai: So if you turn off skipping, should the browser be shifting baselines for subscripts?<br> <TabAtkins> fremy: I vote yes<br> <TabAtkins> jfkthame: I vote no, authors ahve properties they can use to control that<br> <TabAtkins> fremy: can't do that per span, can't affect parent's position<br> <TabAtkins> iank_: waht was edge's beahvor?<br> <TabAtkins> fremy: You draw the baseline at dominant position, but i fyou have text that would cross the underline, you break it and move it down for the text<br> <TabAtkins> iank_: so this would only be when they cross the characters<br> <TabAtkins> fremy: yes<br> <TabAtkins> iank_: I checked with koji, he says he'd prefer edge's beahvior here<br> <TabAtkins> iank_: I just loaded up edge behavior, it seems resilient<br> <Rossen_> q?<br> <TabAtkins> florian: I think if the author has sub or super they need to wkr around, they can use -position to work around it<br> <TabAtkins> florian: and we have :has() now so you can do em:has(sub)<br> <TabAtkins> fremy: it might only be on one lie<br> <TabAtkins> fremy: can't guarantee positioning even with text-underline-position<br> <TabAtkins> fantasai: I think authors want either skipping character or shifting the underline, don't think they want breaking<br> <TabAtkins> iank_: i don't particiularly like current firefox impl for this case<br> <TabAtkins> edge's behavior is resilient to these situations<br> <TabAtkins> fremy: not drawing underline on characters below baseline is a risk you don't draw at all, if an entire line is subbed<br> <astearns> would prefer an implementation that would set the baseline per spec and low enough for all spans on a line<br> <Rossen_> q?<br> <TabAtkins> iank_: I think only us and gecko have this behavior. i think we'd be willing to switch to edge's<br> <TabAtkins> iank_: what do daniel or jonathan think?<br> <TabAtkins> jfkthame: seems to be that gecko's behavior (has been there for many years) is fundamentally the right thing, and i'd prefer not to change it<br> <TabAtkins> iank_: why do you think it's right?<br> <TabAtkins> jfkthame: I think when an underline is specified on an element, it should be a continuous line, it shouldn't move about for some elements<br> <dholbert> i defer to jfkthame, (& haven't fully paged this topic in)<br> <TabAtkins> iank_: even if it obscures the subelements?<br> <TabAtkins> jfkthame: Sure, don't put lines on top of text, that's bad authoring<br> <TabAtkins> jfkthame: i think authors have neough control to do sensible things<br> <astearns> q+<br> <TabAtkins> iank_: I think it's quite common to get into this case<br> <TabAtkins> iank_: And to get yourself out o fit again by using additional elements<br> <TabAtkins> jfkthame: you mean common due to <sub>?<br> <TabAtkins> iank_: yeah you don't need to use any css to get into this<br> <Rossen_> ack astearns<br> <florian> q+<br> <TabAtkins> astearns: jonathan, would you be at all interested to move the underlie down when there's subscript, so there's a continuous line?<br> <TabAtkins> jfkthame: i think we could consider, and think spec currently allows for that<br> <TabAtkins> jfkthame: have some hesitation - if you underline some text that's broken across several, and sub is on one line, does it get a diff position from the other lines? maybe weird, but could think about it<br> <astearns> s/there’s a continuous line/there’s a continuous line for all the spans?/<br> <TabAtkins> iank_: Yeah I think shifting the whole thing isn't a good behavior<br> <Rossen_> a?<br> <Rossen_> q?<br> <TabAtkins> iank_: I think solution is to either drop the baseline entirely or have edge html's beahvior<br> <TabAtkins> fantasai: Spec did specify that kind of auto behavior in the past<br> <TabAtkins> fantasai: for l3 we made it up to the UA<br> <TabAtkins> fantasai: there used to be text specifying to move it on a per-line basis<br> <Rossen_> ack dbaron<br> <TabAtkins> dbaron: My memory of th espec was the opposite - it spec'd moving all the lines. i think that's harder but better behavior<br> <TabAtkins> dbaron: Also, in response to jonathan, another way for authors to hit this case is variabiity between fonts<br> <TabAtkins> dbaron: can hit it on some machines but not others due to font variations<br> <TabAtkins> dbaron: so this should work well as part of css's robustness to unexpected font metrics<br> <Rossen_> ack florian<br> <TabAtkins> florian: don't remember history, but spec as is today in position and offset, has a default of auto that allows for moving it down<br> <fantasai> “In determining the position of and thickness of text decoration lines, user agents MAY consider the font sizes of and dominant baselines of children. Of course, user agents MAY ignore children in these determinations. Such an averaging is done on a line per line basis.”<br> <TabAtkins> florian: but neither speaks to per-element or per-fragment<br> <fantasai> https://www.w3.org/TR/2003/CR-css3-text-20030514/#text-decoration-overview<br> <TabAtkins> florian: so currently ambiguous.<br> <Rossen_> a?<br> <Rossen_> q?<br> <TabAtkins> florian: maybe we start with more permissive version that allows either, and revisit in a bit to see if ther'es agreement?<br> <TabAtkins> florian: could say that browsers *may* do it on per-fragment<br> <fantasai> “In determining the position and thickness of text decoration lines, user agents may consider the font sizes and dominant baselines of descendants, but for a given element's decoration must use the same baseline and thickness on each line.”<br> <TabAtkins> florian: but not obliged to if it's bad<br> <fantasai> https://www.w3.org/TR/2010/WD-css3-text-20101005/#decoration<br> <TabAtkins> iank_: So allow both edge's and firefox's rednering?<br> <TabAtkins> florian: no. say you have a subscript in a long span. on first line you have a continuous line; it might be shifted down if the sub is there.<br> <TabAtkins> florian: So shift for the entire elmenet, but allow it to be per linebox fragment. not edge html style<br> <TabAtkins> iank_: don't think it's necessarily what devs expect<br> <TabAtkins> florian: will be odd if you ahve a multiline span to see the underline shifted on lines without a sub<br> <TabAtkins> iank_: i don't think either option is good<br> <TabAtkins> iank_: Both will look visually odd<br> <TabAtkins> fremy: don't like shifting per line either<br> <TabAtkins> Rossen_: so if we move forward with florian's proposal to make spec more permissive<br> <TabAtkins> TabAtkins: ian was objecting to that, he prefers edge's behavior<br> <TabAtkins> iank_: my strong pref and i think koji's is edge's beahvior<br> <TabAtkins> florian: have we looked at what other good typography stuff has done? we're not inventing the subject<br> <TabAtkins> jfkthame: usual answer in typo is you don't do underlining<br> <TabAtkins> astearns: or you're very explicit about the effect you want<br> <TabAtkins> astearns: indesign allows you to do whatever you want with the line tool<br> <florian> s/stuff/software/<br> <TabAtkins> astearns: so we're talkign about autoamted tools<br> <ChrisLilley> *use inline svg*<br> <TabAtkins> TabAtkins: but latex is automated too<br> <TabAtkins> fremy: for latex, subs don't get an underline, and people are asking about how to get it to work<br> <TabAtkins> fremy: so as far as i can see it just doesn't draw and that's bad<br> <TabAtkins> fantasai: i'd expect that you draw the underline at correct position and skip subs, or use a lower underline position<br> <TabAtkins> fantasai: just as a document style<br> <TabAtkins> florian: alan, you said indesign will do whatever, but it does it provide a way out of the box to do like edge, or do you have to do it manually?<br> <TabAtkins> astearns: i'd ahve to check<br> <TabAtkins> fantasai: don't think i've ever seen edge's behaior in a document taht wasn't generated by a browser<br> <jfkthame> fantasai++<br> <TabAtkins> fremy: i'd assume Word does that<br> <florian> s/will do/will let you do/<br> <TabAtkins> Rossen_: that's correct<br> <Rossen_> q?<br> <TabAtkins> Rossen_: so we have a spec that describes firefox behavior<br> <TabAtkins> Rossen_: we have a strong desire from blink to ipmlemenht the Word/Edge behavior<br> <TabAtkins> Rossen_: if we need to allow both, we need at least a MAY<br> <fremy> FWIW, Word does indeed behave like EdgeHTML<br> <TabAtkins> Rossen_: so that doesn't give us much specification<br> <TabAtkins> TabAtkins: it would still help with supers to make sure that's clear<br> <TabAtkins> florian: right, still an improvement over chrome's old behavior<br> <ChrisLilley> fremy probably both usind DirectWrite api<br> <futhark> present-<br> <fremy> ChrisLilley: quite likely, indeed<br> <TabAtkins> fantasai: think i don't really want to increase variations that typographers would be unhappy abot<br> <TabAtkins> fantasai: so don't want to adopt edge's behavior unless there's typography community people wanting it<br> <TabAtkins> iank_: do we ahve evidence that people dont' want it? that' surprising to me, sicne it's in Word<br> <TabAtkins> jfkthame: Word isn't generally considered the epitome of typography<br> <TabAtkins> jfkthame: just tested Pages on Mac, if you have a sub it moves the entire line's underline<br> <TabAtkins> iank_: per line or per paragraph?<br> <TabAtkins> jfkthame: didn't go that far<br> <TabAtkins> iank_: would it help to quickly show examples?<br> <TabAtkins> iank_: [old chrome behavior, baseline jumps all over for subs and supers. consistent per individual element]<br> <TabAtkins> iank_: [firefox's behavior, underline is just dominant. ink-skipping can make it appear to not draw for subs, depending on how the glyph is]<br> <TabAtkins> iank_: [dominant baseline *per element*, so lines without a sub/super still have the underline shifted]<br> <dholbert> FWIW, LibreOffice seems to match the EdgeHTML behavior (not that LibreOffice is necessarily the pinnacle of text layout; just as another-agreeing-implementation)<br> <TabAtkins> florian: I checked apple pages, it shifts per line, not per paragraph<br> <emeyer> q+<br> <TabAtkins> iank_: [Edge's behavior - underline is dominant, but subs break it and draw their own underline fragment to their dominant baseline. supers don't affect the underline]<br> <TabAtkins> fantasai: I think firefox's behavior is closest to what i'd expect form good typog<br> <emeyer> q-<br> <fantasai> emeyer: I agree<br> <TabAtkins> florian: firefox beahvior could be made smarter<br> <dbaron> s/typog/typography/<br> <dbaron> s/form/from/<br> <TabAtkins> fantasai: and i'd expect ink-skipping with a consisten tposition to look best<br> <TabAtkins> fantasai: if your'e not skipping, that's obvious a little bad<br> <bramus> (Sidenote for macOS users: System Preferences > Accessibility > Zoom: hit checkbox “Use scroll gesture …” and then you can zoom in by scrolling while holding a modifier key. Don’t know if that plays nice with screen sharing though)<br> <TabAtkins> fantasai: if you have a lot of subs and supers mixed together, you should probabyl generally choose a lower underlie position<br> <TabAtkins> fantasai: I don't think I'd expect Edge's behavior from a well-typeset doc<br> <TabAtkins> iank_: is it permissible to skip a giant sub?<br> <TabAtkins> fantasai: default is ink skipping<br> <TabAtkins> iank_: I mean skip entirely, not just ink-skip<br> <ChrisLilley> s/en tpos/ent pos/<br> <TabAtkins> iank_: ink skipping works for shorter cases, like this small B sub<br> <TabAtkins> iank_: but the big edge case is a long subscript<br> <TabAtkins> fantasai: we should be optimizing for reasonable cases<br> <TabAtkins> several: nah we've seen long subs<br> <Rossen_> q?<br> <TabAtkins> fantasai: i think standard will be short subscripts and we should optimize for that<br> <ChrisLilley> ironic typography<br> <TabAtkins> fantasai: there has been requests to turn off underline for an element, that's an open Text 4 request<br> <TabAtkins> fantasai: so if someone wanted to skip, that should be posible to spec<br> <TabAtkins> una: i noticed if you have a sub that's a link, that's common, it'll have a double underline - parent going thru it, then its underline<br> <TabAtkins> fantasai: yeah edge behavior gives you multiple, but spec behavior is to have one single line that doesn't move<br> <bkardell_> I was saying that I agree it is unusual for a long run of text as a subscript in general, but a lot of times superscripts are links, which generally are underlined<br> <TabAtkins> fantasai: so per spec you wouldn't have double underline<br> <TabAtkins> Rossen_: [shows Word with a bunch of different font-size subs, generating multiple staggered underlines]<br> <TabAtkins> Rossen_: this example where you break the first line for a subscript out of the larger set font<br> <fantasai> [changing the baseline position breaks the underline averaging segments in Word]<br> <TabAtkins> florian: I think this is different and more complex than what was described as edge behavior<br> <TabAtkins> florian: you're saying we ahve one continuous underline until we hit the sub, then it changes after th esub?<br> <TabAtkins> fantasai: that's because word doesn't have a nesting hierarchy, it's just a linear stream of elements. so it can't preserve across a sub break<br> <astearns> InDesign also does not have a hierarchy of elements. So I don’t think we should follow InDesign OR Word<br> <TabAtkins> florian: I think LibreOffice does the edge behavior but people are asking how to not do that on SE<br> <fantasai> s/preserve/preserve formatting/<br> <TabAtkins> fremy: I cared strongly when this was first filed because we didn't have agreement, but less now<br> <TabAtkins> fremy: I think Edge's behavior is safe, but if we think it's reasonable to cross the text and rely on ink skipping, i think it's an option. i don't think it's best but i'd be okay with it<br> <fantasai> s/agreement/ink skipping/<br> <TabAtkins> iank_: I want to talk with koji to see what he'd think about, not just ink skipping but totally skipping the sub; would be identical in common cases but different in the degenerate long-text case<br> <TabAtkins> fremy: only downside is it's entirely accidental if the whole text is subbed<br> <TabAtkins> fantasai: agree it shouldn't be defualt, author should opt in maybe<br> <TabAtkins> iank_: i'd agree<br> <TabAtkins> iank_: ink skipping doesn't necessarily get a good effect, it still looks like text is crossed out<br> <Rossen_> q?<br> <TabAtkins> Rossen_: so it sounds like firefox's behavior is still something we want to keep<br> <TabAtkins> Rossen_: strong desire from ian and team to experiement and see if they can get something closer to Edge behavior<br> <TabAtkins> Rossen_: q is how do we allow it<br> <emeyer> q+<br> <TabAtkins> fantasai: i don't think this is good to adtop unless people other than browser eng want it<br> <TabAtkins> fremy: Well Word is doing it and people use it every day<br> <TabAtkins> florian: I just went to Word support forum and answer for if you want to do another behavior is "use more advanced typesetting software"<br> <florian> https://answers.microsoft.com/en-us/msoffice/forum/all/underline-subscript-is-uneven/786e1222-87c4-4dc9-97de-83b3a08a32d8<br> <TabAtkins> fantasai: I want somebody specializing in good typog to say "Word behavior is good and waht we want"<br> <TabAtkins> fremy: yeah but usual policy is to say eve if layout is weird, text should be readable<br> <TabAtkins> fantasai: we try to make sure behavior is good by defualt, and resilient in weird. doesn't mean we choose bad beahvior because it's th emost straightforward way to be resilient<br> <Rossen_> ack emeyer<br> <TabAtkins> emeyer: from what i remember of edge and firefox cases, i do not see why we'd pick Edge over Firefox<br> <TabAtkins> emeyer: what firefox was doing for ink skipping and various cases seemed like a better approach on balance<br> <astearns> I dislike Edge’s behavior because it does two different things depending on whether a line starts with a span shifted up or shifted down relative to the rest of th eline<br> <TabAtkins> emeyer: i'm not a typog expert, but i spent a lot of time looking at text<br> <TabAtkins> emeyer: I'd be comfortable asking the wider community<br> <TabAtkins> emeyer: I agree with elika, we're trying to make typog better, let's actually make it better<br> <una> q?<br> <TabAtkins> una: do we want to do a survey?<br> <TabAtkins> una: my team can organize it<br> <TabAtkins> emeyer: would support it<br> <TabAtkins> Rossen_: would be helpful<br> <TabAtkins> ChrisLilley: should be clear it's "what do you want to see" not just "what does your software do"<br> <TabAtkins> fantasai: "what do you like better: picture, picture, picture"<br> <TabAtkins> florian: Also with short sub we seem to agree firefox is good, only for long do we disagree<br> <TabAtkins> florian: Isn't it pref to use the spec allowance to move the entire line down?<br> <TabAtkins> iank_: I think there's three options here<br> <TabAtkins> iank_: First is firefox's, for short subs ink-skipping makes it readable<br> <TabAtkins> iank_: Second is Edge, where subs move the line down<br> <TabAtkins> iank_: Third is don't draw the underline on subs at all<br> <fantasai> Fourth is move the line down<br> <TabAtkins> iank_: This has similar practical behavior ot Firefox's for short; for long it will be different<br> <Rossen_> For the record - neither of the answers posted by florian's link above are official Microsoft answers but folks from the community<br> <TabAtkins> florian: Think there's four - largely do firefox, but allow for shifting the whole run's underline, perhaps with a guard to ony do it when it's long<br> <TabAtkins> fantasai: don't think it's great, it's unpredictable then<br> <TabAtkins> fantasai: if you have five subs, two on a line skip but three shift, that's weird<br> <TabAtkins> fantasai: should pick one behavior, author can get other behaviors<br> <TabAtkins> Rossen_: we can decid enot to change<br> <TabAtkins> florian: i said my fourth was possibly conditional. if it's not conditional, it matches apple<br> <florian> s/apple/Apple Pages/<br> <TabAtkins> Rossen_: so we can't get resolution yet.<br> <TabAtkins> Rossen_: We want to do a survey that catches all the cases we just described, carefully not conditioning people to one tech or another<br> <TabAtkins> fantasai: I suggest me and Una work on this<br> <TabAtkins> Rossen_: And I think convo captures enough info for posterity<br> <fantasai> ACTION: fantasai and Una to make a survey about underlining subscripts<br> <TabAtkins> Rossen_: and strong desires of what we believe is good<br> <TabAtkins> Rossen_: anything else before we end?<br> <Rossen_> q?<br> <TabAtkins> Rossen_: so let's close the issue<br> <TabAtkins> <br dur=1hr><br> </details> -- GitHub Notification of comment by css-meeting-bot Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/5002#issuecomment-1201432730 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Monday, 1 August 2022 16:27:00 UTC