-
Notifications
You must be signed in to change notification settings - Fork 671
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-ruby][css-text-decor-4] Add over-most-under-last value to ruby-position & text-emphasis-position for captioning #2998
Comments
Neither |
@upsuper Seems like overkill. Not really something that needs to cascade independently afaik, doesn't have complex interactions with anything... Adding a value makes much more sense than adding a property. |
I think For justification we use the last line before any forced break. For text-indent we use the first line of a non-anonymous block. I have no idea what TTML’s markup model would require here... |
I don't think they are clear, tbh. I also thought about the last line, and that feels non-trivial to implement and may add some complexity, because If we change it to only do different thing on first line, that would probably make it easier to implement. |
@skynavga @cconcolato @palemieux ping! The TTML2 spec does answer the question:
So I think the answer is it is based on the line areas generated by layout of the base text, with ruby and text emphasis then inserted in the appropriate position as a later step. |
The Working Group just discussed The full IRC log of that discussion<dael> Topic: Add over-most-under-last value to ruby-position & text-emphasis-position for captioning<dael> github: https://github.com//issues/2998 <dael> astearns: fantasai added to agenda, updates by Nigel <dael> fantasai: The overall question was to add new value to ruby position prop to handle ttml behavior. First line has ruby on top, second on bottom. 3+ lines they're all on bottom. Question from WG is do we add it. There's details on how to segment text, block, linebreaks, etc? <dael> astearns: Is there a use case for changing behavior based on forced line break? <dael> fantasai: Use case is for captions, don't know what markup looks like. Guessing not on forced line breaks. <dael> dbaron: I can see why it's useful f or captions, but feels hard to impl for general case. What's previously local now needs bigger area <dael> florian: Solve by special case first line and having first line be over and rest under? <dael> florian: Since use case if for 2 line what we do for not 2 lines is error driven by use case so might as well do simple thing <dael> s/use case if/use case is <dael> florian: Then again why can't use first-line pseudo <dael> astearns: First-line psuedo is interesting idea. Gets functionality for block. Do first-line deal with blocks? <dael> fantasai: Only with firstline of not anon block <dael> astearns: Then first-line gives us what ttml looking for <dael> fantasai: I think so. Don't know nuances of what they're looking for <dael> astearns: Leave it as a question in the issue? Ask if we can let them do this using first-line <dael> fantasai: Alright <dael> florian: Need to make it explicit that this applies in first-line pseudo. <dael> fantasai: Have to check pseudo spec. And we can add example in ruby module to show this behavior <dael> fantasai: I think we need to call it out, not really clear. Have to add it explicitly <dael> astearns: Poss ttml people considered this and rejected so good to get their feedback on idea <dael> fantasai: prop: add ruby position to properties applying to first-line, respond to ttml suggesting we use first-lien for this behavior and check if it's a problem <dael> astearns: It jsut came up, could get shot down as soon as it's o n issue. not looking for resolution at this point. <dael> fantasai: We have a proposed resolution and asking for feedback <dael> astearns: We can come back next week. |
@nigelmegitt @palemieux would using ::first-line to set |
Hi @nigelmegitt and @palemieux, CSSWG wanted to know if it would be acceptable to just use
and if not, why not. :) |
@nigelmegitt @palemieux @skynavga @cconcolato Can i just check that the wording in the TTML spec is correctly?
The case for a single line is fine. The case for two lines (the most likely scenario) is fine too. I was under the (quite possibly mistaken) impression that in the case of 3+ horizontal lines, ruby would appear above the text except for the last line only, where the ruby would be shown below. Btw, the Netflix requirements at https://medium.com/netflix-techblog/implementing-japanese-subtitles-on-netflix-c165fbe61989 say that there should never be more than two lines (because ruby should never appear between lines). So it doesn't help clarify. |
@r12a for the 3+ case, we changed the spec to use after (below) for non-first lines; this was done to ensure we could map this to CSS using ::first-line; also, regarding the NFLX requirements regarding no more than two lines, that is the NFLX style convention, but does not necessarily apply outside NFLX; one should read that document as one input providing guidance rather than universal requirements; in any case, we need the spec to handle the case where more than two lines are created during layout, which is something the author cannot predict due to variations in actual fonts on the client; |
@fantasai @astearns yes, it looks like using As @skynavga pointed out, the TTML2 spec was changed after this issue was raised in a way that enabled exactly this hypothetical solution. I've confirmed this offline with @palemieux. The change needed is to allow Ruby Layout Module Level 1 explicitly excludes this currently, and the Pseudo-Elements Module Level 4 By the way, this is analogous to text-emphasis-position which does apply to |
OK, I've made the edits for this. There's a tangential follow-up for the CSSWG in #4642 but I think this issue itself is closed. |
https://lists.w3.org/Archives/Public/www-style/2014Dec/0211.html
https://lists.w3.org/Archives/Public/www-style/2015Jan/0126.html
TTML has requested a value to ruby-position (and text-emphasis-position) that would place the annotation above on all lines except the last one in the block. Names proposed include
outside
andauto
.The text was updated successfully, but these errors were encountered: