Closed r12a closed 6 years ago
@r12a Can an example of type style ad type colouring be provided? I cannot picture the scenario John has in mind.
@r12a I believe our intent is that fillLineGap only affects background painting, and since background is painted behind the text, it would be an error for it to obscure any parts of letters or symbols. Bear in mind also that the only values are true
and false
, so the actual background colour that applies is separately defined via the tts:backgroundColor
attribute.
The Working Group just discussed What fillLineGap does/ affects #254
.
The Working Group just discussed What fillLineGap does/ affects #254
, and agreed to the following resolutions:
RESOLUTION: Add a note to say: Note: The application of fillLineGap does not result in hiding any character glyphs that would be visible without fillLineGap. Therefore after application of fillLineGap all parts of all character glyphs with a background colour behind them continue to have that background colour applied.
Reading that resolution again, it doesn't quite say what we meant. Consider the example in https://www.w3.org/TR/ttml-imsc1.1/#itts-fillLineGap : if the <p>
had a background colour (say red for the sake of contrast), and one of the glyphs in the word "lazy" extended partially beyond the yellow background, then on the left hand image those parts of the glyph beyond that yellow background would be drawn over a red background, but on the right hand image, they would be drawn over a yellow background.
Therefore after application of fillLineGap the parts of the character glyphs with a red background colour behind them would no longer have that background colour applied, hence the proposed note is false in that case.
The intent of what we agreed is correct, but the detail is wrong. I think the note needs to say:
Note: The application of fillLineGap does not result in hiding any character glyphs that would be visible without fillLineGap. After application of fillLineGap all parts of all character glyphs with the most locally applied background colour behind them continue to have that background colour applied; any parts of any character glyphs that extend beyond the background area when fillLineGap is set to false are instead drawn with the most locally applied background colour behind them when fillLineGap is set to true, within the constraints of the line area. Any parts of any character glyphs that extend beyond the line area may not have a background drawn behind them at all, regardless of the value of fillLineGap.
Observation: this is quite complicated.
@nigelmegitt The case you described is one where the glyph extends beyond the area where the span background is applied, right? Isn't this an edge case, i.e. won't the author try to avoid the scenario?
Observation: this is quite complicated.
What about simply noting that fillLineGap extends the background of the content area, which always appears behind the glyphs?
@palemieux Right, yes. It may be an edge case, but it is not one the author can avoid deterministically, since the content rectangle is undefined.
Are you suggesting exact wording of "extends the background of the content area"? I think the content area is defined not to have a background - rather there's a background area and a content area and a padding area and the background is traditionally painted in a rectangle the same size and position as the padding area.
I'd be very happy if someone could suggest alternate wording though!
Are you suggesting exact wording of "extends the background of the content area"?
Using the XSL nomenclature, it would probably need to say: "fillLineGap extends the bakground color applied to the padding-rectangle, which appears behind the glyphs."
[ed.: on a related topic, it is probably not a good idea to allow borders on span if fillLineGap is used.]
I think this is possible wrong, but need to double check the language in XSL-FO regarding line stacking. In my mental model, the correct language is "extends to the before and after edge of the line area.
On Mon, Nov 20, 2017 at 10:48 AM, Pierre-Anthony Lemieux < notifications@github.com> wrote:
Are you suggesting exact wording of "extends the background of the content area"?
Using the XSL nomenclature, it would probably need to say: "fillLineGap extends the bakground color applied to the padding-rectangle, which appears behind the glyphs."
[ed.: on a related topic, it is probably not a good idea to allow borders on span if fillLineGap is used.]
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/w3c/imsc/issues/254#issuecomment-345773631, or mute the thread https://github.com/notifications/unsubscribe-auth/AAXCb_Jl7WM-gfiEwNv0zPQTmELhPiyEks5s4btrgaJpZM4PZI9g .
@skynavga "extends to the before and after edge of the line area", yes. The commenter wanted to make sure that the background that was being extended was already the one behind the glyphs. What is this background called?
The current language found under TTML2 10.2.17 is exactly correct:
If a background color applies to an inline area child of a line area, then if the value of this attribute is true, that background area is, for rendering purposes, extended in the block progression dimension so as to be coincident with the before and after edges of the line area; otherwise, if the value of this attribute is false, then that background area is not extended, but remains bounded by the inline area's border rectangle.
Note:
In other words, when this attribute's value is true, background colors rendered on inline areas of adjacent lines abut one another rather than leaving a visible gap in the block progression dimension, i.e., they fill any line gap (also known as leading).
If a computed value of the property associated with this attribute is not supported, then a presentation processor must use the value false.
On Mon, Nov 20, 2017 at 9:56 PM, Pierre-Anthony Lemieux < notifications@github.com> wrote:
@skynavga https://github.com/skynavga "extends to the before and after edge of the line area", yes. The commenter wanted to make sure that the background that was being extended was already the one behind the glyphs. What is this background called?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/w3c/imsc/issues/254#issuecomment-345916860, or mute the thread https://github.com/notifications/unsubscribe-auth/AAXCb4Ks6v97O_cwAYNxBNOnYwCgiV-6ks5s4lfggaJpZM4PZI9g .
See TTML2 10.2.17
If a background color applies to an inline area child of a line area, then if the value of this attribute is true, that background area is, for rendering purposes, extended in the block progression dimension so as to be coincident with the before and after edges of the line area; otherwise, if the value of this attribute is false, then that background area is not extended, but remains bounded by the inline area's border rectangle.
Note:
In other words, when this attribute's value is true, background colors rendered on inline areas of adjacent lines abut one another rather than leaving a visible gap in the block progression dimension, i.e., they fill any line gap (also known as leading).
If a computed value of the property associated with this attribute is not supported, then a presentation processor https://w3c.github.io/ttml2/spec/ttml2.html#terms-presentation-processormust use the value false.
On Mon, Nov 20, 2017 at 10:59 PM, Glenn Adams glenn@skynav.com wrote:
The current language found under TTML2
On Mon, Nov 20, 2017 at 9:56 PM, Pierre-Anthony Lemieux < notifications@github.com> wrote:
@skynavga https://github.com/skynavga "extends to the before and after edge of the line area", yes. The commenter wanted to make sure that the background that was being extended was already the one behind the glyphs. What is this background called?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/w3c/imsc/issues/254#issuecomment-345916860, or mute the thread https://github.com/notifications/unsubscribe-auth/AAXCb4Ks6v97O_cwAYNxBNOnYwCgiV-6ks5s4lfggaJpZM4PZI9g .
Is the word "extended" applicable only because the line stacking strategy means it is impossible for either the line area before or after edge to be within the content rectangle? I think we need to just say that the background painting area's before and after edges are set to be coincident with the line area's before and after edges, and not use the word "extend".
As a data point, imscJS currently emulates fillLineGap by extending (if needed) the padding rectangle such that its before and after edges are coincident with those of the containing line area.
@nigelmegitt The scenario you describe is a) as commented an edge case, b) it is also a scenario that is actually out out of scope of the requirements scenario and c) it represents in it-self more an error condition than a common use case.
Can you give an example where you experience this behaviour? That would be very useful. Even if we find a case: does this really matter given the purpose of fill-linegap?
Requirements scenario of fill line gap: background color is applied to either span or p but not to both.
The behaviour that a glyph extends the content rectangle, so that the "content rectangle background color" does not apply, is an undesired behaviour. It is debatable if this is more a problem of the font or the styling model (XSL-FO/CSS).
Because of a+b+c I would like to not deal with this use case in the informative note. Any attempt to deal with it will confuse more than it helps.
Thanks for the comment @tairt . I believe this scenario is not such an edge case, or at least it is easy to construct. You just need a <p tts:backgroundColor="red">
with a descendant <span>
with a different background colour, and character content that, in the chosen font, generates glyphs that go above or below the font table's ascender and descender values.
The specification does not describe the requirements; they are effectively opaque to a reader of the specification document, so even though you're right that fillLineGap
originated from those requirements, there are no constraints to prevent the scenario I describe above from happening. Therefore handling this permutation has now fallen within the set of requirements we have to consider. (unless we prohibit the possibility by adding a specification constraint)
I do not believe that glyphs extending outside the content rectangle is a problem either of the font or the styling model, rather that it is a known and permitted possibility, albeit one whose use is relatively rare, especially in latin script layout.
I will object to adding wording, even informatively, that we know is in some situations incorrect, even if those situations are edge cases. We need to find a way to phrase it so that this doesn't happen, for example by removing those edge cases from the scope of the informative text, or by rewording to be more precise.
@nigelmegitt Please provide an actual test case, otherwise it is not clear what you are even objecting to.
As agreed on yesterday's call, I've requested further information, at https://github.com/w3c/i18n-activity/issues/399#issuecomment-352059650 - by the way, there's extra context in there that helps explain the origins, but which we didn't spot in this issue here.
The Working Group just discussed What fillLineGap does/ affects imsc#254
, and agreed to the following resolutions:
SUMMARY: Closing due to lack of information
The Working Group just discussed What fillLineGap does/ affects #254
.
6.7.6 itts:fillLineGap https://www.w3.org/TR/ttml-imsc1.0.1/#itts-fillLineGap
[From John Klensin. Discussed by the i18n WG] Editorial (I think) It might be helpful if this document were to prominently state/ clarify just what fillLineGap does/ affects. Even if it is just about colouring between lines, I can imagine that, with some choices of type style ad type colouring, poor choices for this value might cause parts of letters of symbols to become effective invisible. If that can't occur, it would be helpful for the document to say so. Conversely, if it can, some cautionary words may be appropriate.