1. 序論
`overflow^p0`CSS1$r では、指定された~sizeを伴う要素の内側に収まり切らないほど内容を配置することは、一般に 著作時の~errorとされていた。 そのような内容は、要素の境界の外側まで拡幅し,およそ 他の要素と重合することになる。 ◎ In CSS Level 1 [CSS1], placing more content than would fit inside an element with a specified size was generally an authoring error. Doing so caused the content to extend outside the bounds of the element, which would likely cause that content to overlap with other elements.
`CSS21$r では、 `overflow$p ~propが導入された。 作者は,~overflowに対し~scrollさせるよう指定できるようになり、最早 著作時の~errorでなくなった。 同時に,~overflowに対し切取るよう指定できるようにもなった — これは、作者が~overflowした内容を示したくないときに役立つ。 ◎ CSS Level 2 [CSS21] introduced the overflow property, which allows authors to have overflow be handled by scrolling, which means it is no longer an authoring error. It also allows authors to specify that overflow is handled by clipping, which makes sense when the author’s intent is that the content not be shown.
この仕様は、長い間~de-factoであった `overflow-x$p, `overflow-y$p ~propを導入し, `clip$v 値を追加し, ~overflowの取扱いを より全部的に定義する。 ◎ This specification introduces the long-standing de-facto overflow-x and overflow-y properties, adds a clip value, and defines overflow handling more fully.
[Something something `max-lines$p.]
2. ~overflowの種別
~CSSにおける用語 `~overflow@ ( `overflow^en )は、~boxの内容が~boxのいずれかの辺(すなわち,その `内容~辺$, `~padding辺$, `~border辺$, `~margin辺$ )の外側へ拡幅することを指す。 この用語は、[ この~overflowを生じさせた要素や特色機能 / その種の特色機能により占められる領域(†矩形とは限らない) ]として — あるいは より一般的には,その領域を囲む最小の矩形として — 解釈されることもある。 ~boxの~overflowは、[ ~box自身, および[ ~boxの子孫のうち,その`包含塊の連鎖$が 当の~boxを含むもの ]すべて ]の[ ~layout, ~styling ]に基づいて算出される。 ◎ CSS uses the term overflow to describe the contents of a box that extend outside one of that box’s edges (i.e., its content edge, padding edge, border edge, or margin edge). The term might be interpreted as elements or features that cause this overflow, the non-rectangular region occupied by these features, or, more commonly, as the minimal rectangle that bounds that region. A box’s overflow is computed based on the layout and styling of the box itself and of all descendants whose containing block chain includes the box.
【 この仕様の “矩形” には、論の対象にされている~boxの辺に平行であることも 含意されている。 したがって, “矩形でない” は、~boxの辺に平行でない長方形も含む。 】
ほとんどの事例では、~boxに対する`~overflow$は,[ ~box自身の境界と各種~propに加え,~boxの各 子~boxの`~overflow$ ]から算出できるが、常に可能とは限らない。 例えば、 `transform-style$p が `preserve-3d^v にされた子孫があれば,それらも精査され~MUST。 `CSS3-TRANSFORMS$r ◎ In most cases, overflow can be computed for any box from the bounds and properties of that box itself, plus the overflow of each of its children. However, this is not always the case; for example, when transform-style: preserve-3d [CSS3-TRANSFORMS] is used on some of the children, any of their descendants with transform-style: preserve-3d must also be examined.
~overflowには、~UAにより異なる目的で利用される,次の 2 つの種別がある: ◎ There are two different types of overflow, which are used for different purposes by the UA:
- `~ink~overflow$ ◎ ink overflow
- `~scroll可能な~overflow$ ◎ scrollable overflow
2.1. ~ink~overflow
~boxの `~ink~overflow@ は、~boxの~border~boxの外側に視覚的~効果を作成させるような,~boxや, ~boxの内容の一部である。 ~ink~overflowは、~layoutに影響しない — あるいは,影響するとしても`~scroll可能な~overflow領域$を拡幅するにとどまる — ように定義された塗り効果であり、次のものが挙げられる: `~box影$, `~border画像$, `~text装飾$, ~em~boxの外側まで張り出している~glyph, `外形線$, 等々。 ◎ The ink overflow of a box is the part of that box and its contents that creates a visual effect outside of the box’s border box. Ink overflow is the overflow of painting effects defined to not affect layout or otherwise extend the scrollable overflow region, such as box shadows, border images, text decoration, overhanging glyphs (with negative side bearings, or with ascenders/descenders extending outside the em box), outlines, etc.
~CSSにおける一部の効果は,視覚的にどこまで覆うかを定義しないので(例: `text-shadow$p や `box-shadow$p によるボカシは理論的に無限になる)、`~ink~overflow$による拡幅量は,定義されない。 ◎ Since some effects in CSS (for example, the blurs in text-shadow [CSS-TEXT-3] and box-shadow [CSS-BACKGROUNDS-3], which are theoretically infinite) do not define what visual extent they cover, the extent of the ink overflow is undefined.
`~ink~overflow領域@ は、~boxとその内容の`~ink~overflow$が占める区画(矩形とは限らない)である。 `~ink~overflow矩形@ は、[ ~boxの辺に平行かつ `~ink~overflow領域$を包含する ]ような,最小の矩形である。 それは、変形 `CSS3-TRANSFORMS$r に因り,~box以外の座標系では矩形になるとは限らないことに注意。 ◎ The ink overflow region is the non-rectangular area occupied by the ink overflow of a box and its contents, and the ink overflow rectangle is the minimal rectangle whose axes are aligned to the box’s axes and that contains the ink overflow region. Note that the ink overflow rectangle is a rectangle in the box’s coordinate system, but might be non-rectangular in other coordinate systems due to transforms. [CSS3-TRANSFORMS]
2.2. ~scroll可能な~overflow
~box — 以下、この節を通して %B と記す — の `~scroll可能な~overflow@ は、~scroll法の仕組みが供される必要があるような, %B の~padding辺の外側まで拡幅するモノの集合である。 ◎ The scrollable overflow of a box is the set of things extending outside of that box’s padding edge for which a scrolling mechanism needs to be provided.
%B の `~scroll可能な~overflow領域@ は、`~scroll可能な~overflow$が占める領域である(矩形とは限らない)。 `~scroll可能な~overflow矩形@ は、[ %B の辺に平行かつ `~scroll可能な~overflow領域$を包含する ]ような,最小の矩形である。 ◎ The scrollable overflow region is the non-rectangular region occupied by the scrollable overflow, and the scrollable overflow rectangle is the minimal rectangle whose axes are aligned to the box’s axes and that contains the scrollable overflow region.
%B の`~scroll可能な~overflow領域$は、次の和集合である: ◎ The scrollable overflow region is the union of:
-
%B の自前の[ `内容~区画$, `~padding区画$ ] ◎ the box’s own content and padding areas
~scroll法の~modelは、~paddingに関して実装~間で食い違っている… ◎ There’s disagreement on the scrolling model. 2.1 apparently defined that you scrolled the *content* area; the content would overflow the content-box, and you would union that overflow with the content box to find the scrollable area. In particular, this means that the content would be offset by the start-sides padding, but if it overflowed, it would go right to the edge on the end sides. This is what Firefox and IE do. ◎ At least some authors (and spec authors) instead have the mental model that the padding box is what’s scrollable, so when you scroll to the end of the overflow, there’s the right/bottom padding. Chrome/WebKit do this for the block axis, at least. They’re somewhat inconsistent for the inline axis; there’s something weird about how they handle lineboxes.
【 以下、この部分の原文による論理が訳者には はっきりしないので,和訳は省略する。 結論から言うと、次に示すような~padding付きの~scroll~boxの挙動は,[ Firefox, IE ]と[ Chrome, WebKit ]とで異なる: 】
おそらく、塊-軸~paddingは,尊守するに~web互換である。 `行内-軸$~paddingがどうなるかは不明瞭である。 もっと実験する必要がある。 ◎ It seems that the block-axis padding is probably web-compatible to honor. It’s unclear that the inline-axis padding will be. Further experimentation is needed.
- %B に直に包含されている,すべての行l~box。 ◎ all line boxes directly contained by the box
-
%B を包含塊とするような,すべての~boxの~border~box — ただし、~border~box全体が %B の[ `塊-始端$/`行内-始端$ ]~padding辺の外側に位置するものは除く。 ここで、変形を伴う~boxに対しては,[ その `~3D描画~文脈$を確立した要素の平面 ]上に投影した結果を織り込むとする。 `CSS3-TRANSFORMS$r ◎ the border boxes of all boxes for which it is the containing block and whose border boxes are positioned not wholly outside its block-start or inline-start padding edges, accounting for transforms by projecting each box onto the plane of the element that establishes its 3D rendering context. [CSS3-TRANSFORMS]
変形に対するこの取扱いの記述は、正確0に足るか? ◎ Is this description of handling transforms sufficiently accurate?
-
前項に該当する~boxのうち,[ 自身の `overflow$p が `visible$v である(すなわち,~box自身は~overflowを切取っていない)], かつ[ その`~scroll可能な~overflow$が(例: `clip$p ~propや `contain$p ~propにより)すでに切取られていない ]ものすべての,`~scroll可能な~overflow領域$(上述の変形も織り込んだ上で)。 ◎ the scrollable overflow regions of all of the above boxes (accounting for transforms as described above), provided they themselves have overflow: visible (i.e. do not themselves trap the overflow) and that scrollable overflow is not already clipped (e.g. by the clip property or the contain property).
`overflow$p `clip^v は`~scroll可能な~overflow$も切取るべきか? あるいは塗-時の演算を純粋に~~保つべきか? — 後者は、~scroll可能な~overflowは,可視でない間でも~scroll可能になることを意味する。 ◎ should overflow: clip also clip the scrollable overflow or should it remain a pure paint-time operation, which would mean that scrollable overflow, while invisible, would still be scrollable.
注記: 各種 `mask-*^p ~prop `CSS-MASKING-1$r は、`~scroll可能な~overflow領域$には影響しない。 ◎ Note: The mask-* properties [CSS-MASKING-1] do not affect the scrollable overflow region.
`clip$p や `clip-path$p を[ 尊守する/無視する ]ことの互換性について評価する必要がある。 ◎ Need to evaluate compat of honoring or ignoring clip and clip-path.
-
任意選択で、[ `~scroll容器$である %B の終端~側の~paddingに対応する,終端~側~padding ]を追加する — 容器が終端まで~scrollされたときに、 %B の~flow内にある内容の終端~辺が, %B の`内容~区画$の終端~辺に一致するように。 ◎ Optionally, additional padding on the end-edge sides, corresponding to the end-side padding of the scroll container, such that the end edges of its in-flow content coincide with the end edges of its content area when scrolled to the end.
~scroll可能な層に終端~側~paddingを含めることが~web互換なのかどうか,まだ明瞭でないので、 この条項は究明-中にある。 Chrome / Safari は、`塊-軸$において そのような~paddingを含む ように見受けられるが、`行内-軸$における挙動は, 明瞭 でない 。 <~CSSissue/129> ◎ It’s not yet clear if including the end-side padding in the scrollable layer is Web-compatible, so this clause is under investigation. It appears that Chrome and Safari include such padding in the block axis; and the behavior in the inline axis is not clear. <https://github.com/w3c/csswg-drafts/issues/129>
~UAは、 %B を包含塊とするような~boxに,追加の`~margin区画$を含ませてもよい。 どのような条件の下でこれを含ませるかは、この~levelでは定義されない。 もっと試験と究明が必要なので、この草案では先送りされている。 ◎ The UA may additionally include the margin areas of boxes for which it is the containing block. The conditions under which such margin areas are included is undefined in this level. This needs further testing and investigation; is therefore deferred in this draft.
注記: ~boxの`~scroll可能な~overflow矩形$は,常に~boxの辺に平行になるが、変形 `CSS3-TRANSFORMS$r に因り,~box以外の座標系では矩形になるとは限らないことに注意。 このことは、実際には不要なときでも,~scrollbarが現れ得ることを意味する。 ◎ Note: The scrollable overflow rectangle is always a rectangle in the box’s own coordinate system, but might be non-rectangular in other coordinate systems due to transforms [CSS3-TRANSFORMS]. This means scrollbars can sometimes appear when not actually necessary.
3. ~scroll可能な~overflow/切抜き~overflow: `overflow-x^p, `overflow-y^p, `overflow^p ~prop
これらの~propは、次を指定する:
- ~boxの内容が、~boxの~padding辺で(`~ink~overflow$も含めて)切取られるかどうか。
- 切取られた場合に、~boxは `~scroll容器@ になるかどうか — すなわち,利用者は、~boxの`~scroll可能な~overflow領域$内の切取られた部位を,~viewの中へ~scrollできるようになるかどうか。
`~scroll容器$の可視域(それを通して `~scroll可能な~overflow領域$を~viewできる~~領域)は、 `~scrollport@ と呼ばれ、容器の~padding~boxに一致する。
◎ These properties specify whether a box’s content (including any ink overflow) is clipped to its padding edge, and if so, whether it is a scroll container that allows the user to scroll clipped parts of its scrollable overflow region into view. The visual viewport of the scroll container (through which the scrollable overflow region can be viewed) coincides with its padding box, and is called the scrollport.`overflow-x$p ~propは、横~方向における`~overflow$(すなわち,~boxの[ 左端/右端 ]側を~overflowするとき)の取扱いを指定する。 `overflow-y$p ~propは、縦~方向における`~overflow$(すなわち,~boxの[ 上端/下端 ]側を~overflowするとき)の取扱いを指定する。 ◎ The overflow-x property specifies the handling of overflow in the horizontal direction (i.e., overflow from the left and right sides of the box), and the overflow-y property specifies the handling of overflow in the vertical direction (i.e., overflow from the top and bottom sides of the box).
◎名 `overflow@p ◎値 [ `visible$v | `hidden$v | `clip$v | `scroll$v | `auto$v ]{1,2} ◎初 個々の~propを見よ ◎適 `塊~容器$, `~flex容器$, `格子~容器$ ◎ block containers [CSS21], flex containers [CSS3-FLEXBOX], and grid containers [CSS3-GRID-LAYOUT] ◎継 されない ◎百 受容しない ◎算 個々の~propを見よ ◎順 文法に従う ◎ア 離散的 ◎表終`overflow$p ~propは、指定された 2 個の値を順に[ `overflow-x$p, `overflow-y$p ]の指定値に設定する,略式~propである。 2 個目の値が省略された場合、 1 個目の値から複製される。 ◎ The overflow property is a shorthand property that sets the specified values of overflow-x and overflow-y in that order. If the second value is omitted, it is copied from the first.
各種 値の意味は: ◎ Values have the following meanings:
- `visible@v
- ~overflowに対する特別な取扱いはない。 すなわち、~boxの内容は,~boxの外側に位置されれば そこにも描画される。 ~boxは`~scroll容器$にはならない。 ◎ There is no special handling of overflow, that is, the box’s content is rendered outside the box if positioned there. The box is not a scroll container.
- `hidden@v
-
次を指示する:
- ~boxの内容は、~padding~boxで切取られる。
- ~UAは、[ 切抜き領域の外側にある内容を~viewするための,~scroll用~UI ]を供したり,[ 利用者が,~touch~screen上を~dragしたり~mouseの~scroll用~wheelを用いて直に~scrollできる ]ようにしては~MUST_NOT。
- 内容は,依然として~program的に — 例えば `CSSOM-VIEW$r にて定義される仕組みを利用して — ~scrollでき~MUST。 したがって、~boxは`~scroll容器$になる。
- `clip@v
-
次を指示する:
- ~boxの内容は、~padding~boxで切取られる。
- ~UAは、[ 切抜き領域の外側にある内容を~viewするための,~scroll用~UI ]を供するべきでない。
- どのような仕組みでも,内容は~scrollできない。 したがって、~boxは`~scroll容器$にならない。
-
`hidden$v 違って,この値は、要素に新たな整形~文脈を確立させることはない。 ◎ Unlike hidden, this value does not cause the element to establish a new formatting context.
注記: ~boxに整形~文脈も確立させたいと求める作者は、この値に加えて `display$p を利用できる。 ◎ Note: Authors who also want the box to establish a formatting context may use display: flow-root together with overflow: clip.
- `scroll@v
-
次を指示する:
- ~boxの内容は、~padding~boxで切取られる。
- ~boxの内容を~viewの中へ~scrollできる。 したがって、~boxは`~scroll容器$になる。
- 加えて,~UAが[ 利用者~向けの~scroll法の仕組みを,~screen上に可視にする(~scrollbarや~pan用のそれなど) ]場合、その仕組みは~overflowがあるかどうかにかかわらず,表示されるべきである。 これにより、動的環境において ~scrollbarが現れたり消えたりする問題を避けれる。 ◎ Furthermore, if the user agent uses a scrolling mechanism that is visible on the screen (such as a scroll bar or a panner), that mechanism should be displayed whether or not any of its content is clipped. This avoids any problem with scrollbars appearing and disappearing in a dynamic environment.
- 目的の媒体が `print$v であるときは、~overflowしている内容は印刷されてもよい — どこに印刷するかは定義されていない。 ◎ When the target medium is print, overflowing content may be printed; it is not defined where it may be printed.
- `auto@v
- ~boxに`~scroll可能な~overflow$があるときは, `scroll$v の様にふるまい、他のときは `hidden$v の様にふるまう。 したがって,~UAが利用している~scroll法の仕組みが~screen上で可視ならば(~scrollbarや~pan用のそれなど)、その仕組みは~overflowがある場合に限り,表示される。 ◎ Like scroll when the box has scrollable overflow; like hidden otherwise. Thus, if the user agent uses a scrolling mechanism that is visible on the screen (such as a scroll bar or a panner), that mechanism will only be displayed if there is overflow.
`塊~box$は、その[ `overflow-x$p, `overflow-y$p ]の両者とも算出値は `visible$v でも `clip$v でもない場合には,を自身の内容~用に`独立な整形~文脈を確立する$。 ◎ If the computed value of overflow on a block box is neither visible nor clip nor a combination thereof, it establishes an independent formatting context for its contents.
3.1. 印刷その他の静的~媒体における~overflow
静的~媒体(印刷など)では~scrollはアリでないので、作者は,[
そのような媒体でも内容を~access可能にする
]よう注意深くなるべきである。
例えば,
@media print, (update: none) { … }
を用いて~layoutを調整して、関連する内容はすべて同時的に可視になるようにするなど。
◎
Since scrolling is not possible in static media (such as print) authors should be careful to make content accessible in such media, for example by using @media print, (update: none) { … } to adjust layout such that all relevant content is simultaneously visible.
対話的でない媒体における`~scroll容器$に対しては、その `overflow$p 値が[ `auto$v / `scroll$v ]ならば( `hidden$v は~~除外される)、~UAは,~scrollbarや省略符などを表示して ~scroll可能な~overflowを指示しても~MAY。 ◎ On scroll containers in non-interactive media with an overflow value of auto or scroll (but not hidden) UAs may display an indication of any scrollable overflow, such as by displaying scrollbars or an ellipsis.
注記: 頁d媒体であっても,対話的になるものはある — 例えば電子本~readerの頁~内容など。 ◎ Note: Not all paged media is non-interactive for example, e-book readers page content, but are interactive.
3.2. ~scrollbarと~layout
~scrollbarが要素の~boxの辺に配置される事例においては、それは 内縁~border辺と外縁~padding辺の合間に挿入されるべきである。 ~scrollbarが~~占める空間は,~scrollbarを伴う要素が形成する包含塊から差し引かれる(寸法から減算される)べきである。 ◎ In the case of a scrollbar being placed on an edge of the element’s box, it should be inserted between the inner border edge and the outer padding edge. Any space taken up by the scrollbars should be taken out of (subtracted from the dimensions of) the containing block formed by the element with the scrollbars.
`CSS3-BOX$r から例を取込む。 ◎ import examples from [CSS3-BOX].
3.3. ~scroll法の原点, 方向, 制約
`初期~scroll位置@ とは、初期~時における — すなわち,利用者や~programによる~scroll~~操作に先立つ — ~boxの~border~boxに~~相対的な,~boxの`~scroll可能な~overflow領域$の位置であり、既定では,~boxの`書字mode$に依存して,~boxの`~padding辺$の[ `塊-始端$ / `行内-始端$ ]辺になる。 この既定は、 `CSS-ALIGN-3$r の[ `align-content$p, `justify-content$p ]~propを利用して変更することもできる — その仕様の ~overflowと~scroll位置 節を見よ。 ◎ The initial scroll position, that is, the initial position of the box’s scrollable overflow region with respect to its border box, prior to any user or programmatic scrolling that changes it, is dependent on the box’s writing mode, and is by default the block-start/inline-start edge of the box’s padding edge. However, the align-content and justify-content properties [CSS-ALIGN-3] can be used to change this, see CSS Box Alignment 3 §5.3 Overflow and Scroll Positions.
~web互換性をとるための拘束に因り(これは、旧来の~bugにつけ込んで,視覚系~browserに対しては こっそり内容を隠しながら, 検索engineや発話~出力に対してはそうしなかった,作者たちに~~起因するものである)、~UAは,`~scroll容器$の`~scroll可能な~overflow領域$を,その~boxの[ `塊-始端$, `行内-始端$ ]側で切取ることが要求される(したがって,それらの側には`~scroll可能な~overflow$はなかったかのように挙動することになる)。 ◎ Due to Web-compatibility constraints (caused by authors exploiting legacy bugs to surreptitiously hide content from visual readers but not search engines and/or speech output), UAs must clip the scrollable overflow region of scroll containers on the block-start and inline-start sides of the box (thereby behaving as if they had no scrollable overflow on that side).
表示域は、これらの計算に`原則的な書字mode$を利用する。 ◎ The viewport uses the principal writing mode for these calculations.
3.4. `overflow^p 値の表示域への伝播
~UAは、根~要素~上に設定されている `overflow-*$p 値を,表示域に適用し~MUST。 ただし,[ 根~要素は `HTML$r `html$e 要素である( ~HTML用の~XML構文 も含む) ]~AND[ 根~要素~上の `overflow-*$p 値は両~軸とも `visible$v ]~AND[ `~HTML~body要素$ %body は在る ]ならば、代わりに %body 上の `overflow-*^p 値を表示域に適用し~MUST。 この場合の %body 上の `overflow$p の使用値は, `visible$v にされ~MUST。 ◎ UAs must apply the overflow-* values set on the root element to the viewport. However, when the root element is an [HTML] html element (including XML syntax for HTML) whose overflow value is visible (in both axes), and that element has a body element as a child, user agents must instead apply the overflow-* values of the first such child element to the viewport. The element from which the value is propagated must then have a used overflow value of visible.
値[ `visible$v / `clip$v ]は、表示域に適用される場合には[ `auto$v / `hidden$v ]として解釈され~MUST。 ◎ If visible is applied to the viewport, it must be interpreted as auto. If clip is applied to the viewport, it must be interpreted as hidden.
3.5. ~flowに相対的な~prop: `overflow-block^p, `overflow-inline^p
次に挙げる~propは、 ~flowに相対的な~box~model~prop に定義されるものと同じ処理~modelに則って処理される: ◎ The following properties are processed according to the same processing model as the Flow-Relative box model properties defined in CSS Logical Properties 1 §3 Flow-Relative Box Model Properties.
◎名 `overflow-inline@p, `overflow-block@p ◎値 `overflow$tp ◎初 `auto^v ◎適 `overflow-x$p / `overflow-y$p と同じ ◎ Same as overflow-x and overflow-y ◎継 されない ◎百 受容しない ◎算 `overflow-x$p / `overflow-y$p と同じ ◎ Same as overflow-x and overflow-y ◎順 文法に従う ◎ア 離散的 ◎表終これらの~propは、[ `overflow-x$p / `overflow-y$p ]~propに対応する。 その対応関係は、要素の `writing-mode$p に依存する。 ◎ These properties correspond to the overflow-x and overflow-y properties. The mapping depends on the element’s writing-mode.
4. ~overflow時の省略符: `text-overflow^p ~prop
【 省略符 — ellipsis (印刷用語でいう三点リーダなど)。 】
◎名 `text-overflow@p ◎値 `clip$v | `ellipsis$v ◎初 `clip^v ◎適 `塊~容器$ ◎継 されない ◎百 受容しない ◎算 指定値 ◎順 文法に従う ◎ア 離散的 ◎表終この~propは、[ `行内~内容$が[ その`塊~容器$要素の行l~boxの終端~辺を,`行内~次元$において~overflowする ], かつ その塊の `overflow$p は `visible$v でない ]ときの描画を指定する。 ◎ This property specifies rendering when inline content overflows its end line box edge in the inline progression direction of its block container element ("the block") that has overflow other than visible.
~textは、例えば折返しが禁則されるとき(例えば, `white-space^p に対する `nowrap^v や, 一行分を超える長さの 単独の単語に因り),~overflowし得る。 各種 値の意味は: ◎ Text can overflow for example when it is prevented from wrapping (e.g. due to white-space: nowrap or a single word is too long to fit). Values have the following meanings:
- `clip@v (単に切取る)
- `行内~内容$がその`塊~容器$要素を~overflowする部分は、切取る。 文字~並びは、部分的に描画されても~MAY。 ◎ Clip inline content that overflows its block container element. Characters may be only partially rendered.
- `ellipsis@v (~UA の既定の省略符)
- ellipsis 文字( U+2026 )を描画して,`行内~内容$が切取られたことを表現する。 実装は、[[ 言語/用字系/書字mode ]に より適切な省略符 ], あるいは[ ellipsis 文字を可用にできないときは 3 個の~dot "..." ]で代用してよい。 ◎ Render an ellipsis character (U+2026) to represent clipped inline content. Implementations may substitute a more language, script, or writing-mode appropriate ellipsis character, or three dots "..." if the ellipsis character is unavailable.
- 【 以下に現れる語 `省略符@ ( ellipsis )は、~UAがこの値に対し実際に描画する文字(たち)を指す( U+2026 に限られない)。 】
読み易くするため、この~prop定義においては,用語 “文字” が利用される — 実装の目的においては、 “書記素~cluster” `UAX29$r を意味する。 ◎ The term "character" is used in this property definition for better readability and means "grapheme cluster" [UAX29] for implementation purposes.
`ellipsis$v 値に対しては、実装は,行lの終端~辺の所の[ 文字/`不可分な行内level$要素 ]を,`省略符$を収めるに必要な分だけ隠した上で、隠されずに残った行内~内容の終端~辺に,`省略符$を配置し~MUST。 ただし、行l上の最初の[ 文字/`不可分な行内level$要素 ]まで隠れることになる場合は、省略化せず `clip$v と同じふるまいにし~MUST。 ◎ For the ellipsis value implementations must hide characters and atomic inline-level elements at the end edge of the line as necessary to fit the ellipsis, and place the ellipsis immediately adjacent to the end edge of the remaining inline content. The first character or atomic inline-level element on a line must be clipped rather than ellipsed.
双向~省略符の例
双向~状況において,省略符~用の部屋を作るとき どの文字が隠されるかを、次に例示する — それらは、視覚的に行lの終端~辺に来る: ◎ These examples demonstrate which characters get hidden to make room for the ellipsis in a bidi situation: those visually at the end edge of the line.
見本~CSS: ◎ Sample CSS:
div { font-family: monospace; white-space: pre; overflow: hidden; width: 9ch; text-overflow: ellipsis; }
見本~HTML片と,基準~描画, 現~browserによる描画: ◎ Sample HTML fragments, renderings, and your browser: ◎ HTML|Reference rendering|Your Browser
~HTML | 基準~描画 | 現~browser |
---|---|---|
`<div>שלום 123456</div>^c |
123456 ם…
| |
`<div dir=rtl>שלום 123456</div>^c |
…456 שלום
|
省略化の詳細
- 省略化が影響するのは、描画のみであり,~layoutにも~pointer~eventの配送-法にも影響しては~MUST_NOT。 ~UAは、省略符~上の~pointer~eventも — `text-overflow$p が `none^v であったときと同じく — ~textが省かれた要素へ向けて配送するべきである。 ◎ Ellipsing only affects rendering and must not affect layout nor dispatching of pointer events: The UA should dispatch any pointer event on the ellipsis to the elided element, as if text-overflow had been none.
- 省略符は、塊に則って~styleされ,基底線に整列される。 ◎ The ellipsis is styled and baseline-aligned according to the block.
- 省略化が生じるのは、相対的~位置決めや 他の~graphic的な変形nの後とする。 ◎ Ellipsing occurs after relative positioning and other graphical transformations.
- 省略符~用の空間が足りない場合、省略符~自身の描画を切取る( `clip$v 値が指定されていたときに,行l上の中立的~文字†が切取られる所と同じ側で)。 【†中立的( neutral ):ハイフンなど,双向性に関して中立的な文字( Unicode 仕様に規定される)。】 ◎ If there is insufficient space for the ellipsis, then clip the rendering of the ellipsis itself (on the same side that neutral characters on the line would have otherwise been clipped with the text-overflow:clip value).
利用者による省略符との対話
- 利用者が内容と対話する所(例: 編集-/選択-/~scrollするような所)では、~UAは `text-overflow$p に対する `ellipsis$v を `clip$v として扱ってよい。 ◎ When the user is interacting with content (e.g. editing, selecting, scrolling), the user agent may treat text-overflow: ellipsis as text-overflow: clip.
- `省略符$を選択する際には、省略化された~textが選択されるべきである。 省略化された~textすべてが選択された場合、~UAは,省略符の選択を示すべきである。 省略化された~textが部分的に選択された場合の挙動は、~UAに委ねられる。 ◎ Selecting the ellipsis should select the ellipsed text. If all of the ellipsed text is selected, UAs should show selection of the ellipsis. Behavior of partially-selected ellipsed text is up to the UA.
以下の各~例に、[ 内容~textが~overflowするような,`塊~容器$要素 ]に対する `text-overflow$p の設定を例示する。 ◎ text-overflow examples ◎ These examples demonstrate setting the text-overflow of a block container element that has text which overflows its dimensions:
`div^e 用の見本~CSS: ◎ sample CSS for a div:
div { font-family: Helvetica, sans-serif; line-height: 1.1; width: 3.1em; padding: 0.2em; border: solid .1em black; margin:1em 0; overflow: hidden; }
◎ sample HTML fragments, renderings, and your browser:
見本~HTML素片 | 描画~見本 ◎ sample rendering | 利用中の~browserによる呈示 ◎ your browser |
---|---|---|
<div style="overflow:visible;"> CSS IS AWESOME, YES </div> | `cssisawesome^dgm |
|
<div style="text-overflow:clip;"> CSS IS AWESOME, YES </div> | `cssisaweso^dgm |
|
<div style="text-overflow:ellipsis;"> CSS IS AWESOME, YES </div> | `cssisaw^dgm |
|
<div style="text-overflow:ellipsis;"> NESTED <p style="margin:1em 0;">PARAGRAPH</p> WON’T ELLIPSE. </div> | `nes^dgm |
PARAGRAPH WON’T ELLIPSE. |
注記: 省略符が行lのどちら側に配置されるかは、塊の `direction$p に依存する。 例えば、塊の `overflow$p が `hidden^v にされていて, 右横書き ( `direction$p は `rtl^v )の場合、行内~内容を 左端 側で切取るので、 `text-overflow$p による省略符を 左端上に配置して,切取られた内容を表現することになる。 ◎ Note: the side of the line that the ellipsis is placed depends on the direction of the block. E.g. an overflow hidden right-to-left (direction: rtl) block clips inline content on the left side, thus would place a text-overflow ellipsis on the left to represent that clipped content.
省略符と~scroll用~UIとの相互作用
この節は、 `text-overflow$p は `clip$v 以外に指定され, かつ `overflow$p は `scroll^v にされた要素に適用される。 ◎ This section applies to elements with text-overflow other than text-overflow:clip (non-clip text-overflow) and overflow:scroll.
要素~上の `text-overflow$p が `clip^v でない, かつ `overflow$p は`行内~次元$において `scroll^v にされていて,~browserが~scroll用の仕組みを供するとき(例: 要素~上の~scrollbarや, ~swipe-scroll用の~touch~UI, 等々)、実装において より良い利用者~体験を供する追加の詳細がある: ◎ When an element with non-clip text-overflow has overflow of scroll in the inline progression dimension of the text, and the browser provides a mechanism for scrolling (e.g. a scrollbar on the element, or a touch interface to swipe-scroll, etc.), there are additional implementation details that provide a better user experience:
要素が~scrollされるとき(例: 利用者により, または~DOM操作により),要素の更なる内容が示される。 `text-overflow$p の値は、そのふるまいに影響するべきでない: `text-overflow$p が `clip^v 以外に設定された場合、実装は,~viewの中に更なる内容が~scrollされるに伴い、追加の内容が何であれ,それを収めるように示すべきである — [ `clip^v であったなら切取られるような内容, および `省略符$に必要な分 ]のみ切り落として、また,内容の~~終端まで表示できる程 十分に要素が~scrollされたときは,`省略符$を表示する代わりに その部分の内容を表示するべきである。 ◎ When an element is scrolled (e.g. by the user, DOM manipulation), more of the element’s content is shown. The value of text-overflow should not affect whether more of the element’s content is shown or not. If a non-clip text-overflow is set, then as more content is scrolled into view, implementations should show whatever additional content fits, only truncating content which would otherwise be clipped (or is necessary to make room for the ellipsis/string), until the element is scrolled far enough to display the edge of the content at which point that content should be displayed rather than an ellipsis/string.
次の例は、上述の挙動を例示するために, `overflow$p が `scroll^v にされた要素~上で `text-overflow$p を利用する。 ◎ This example uses text-overflow on an element with overflow scroll to demonstrate the above described behavior.
見本~CSS: ◎ sample CSS:
div.crawlbar { text-overflow: ellipsis; height: 2.5em; overflow: scroll; white-space: nowrap; width: 15em; border:1em solid black; }
見本~HTML素片: ◎ sample HTML fragment:
<div class="crawlbar"> CSS is awesome, especially when you can scroll to see extra text instead of just having it overlap other text by default. </div>
見本~CSS /~HTMLの例示: ◎ demonstration of sample CSS and HTML:
内容が~scrollされている間、実装は,`省略符$の描画を調整してよい(例:行lの辺ではなく,~boxの辺に整列するなど)。 ◎ While the content is being scrolled, implementations may adjust their rendering of ellipses (e.g. align to the box edge rather than line edge).
5. 可視になる行l数の制限-法: `line-clamp^p 略式~prop
◎名 `line-clamp@p ◎値 `none^v | `integer$t `block-overflow$tp? ◎初 `none^v ◎適 個々の~propを見よ ◎継 個々の~propを見よ ◎百 受容しない ◎算 個々の~propを見よ ◎順 文法に従う ◎ア 個々の~propを見よ ◎表終`line-clamp$p ~propは、[ `max-lines$p, `block-overflow$p, `continue$p ]~prop用の`略式~prop$である。 ◎ The line-clamp property is a shorthand for the max-lines, block-overflow, and continue properties.
この~propは、塊~容器の内容を指定された行l数に制限できるようにする。 残りの内容は外へ断片化され、描画されなくなる/計測されなくなる。 また,任意選択で、最後の行l~boxの中へ内容を挿入して,[ 切落された/中断された ]内容の継続性を指示できるようにする。 ◎ It allows limiting the contents of a block container to the specified number of lines; remaining content is fragmented away and neither rendered nor measured. Optionally, it also allows inserting content into the last line box to indicate the continuity of truncated/interrupted content.
各種~下位propは、指定された値に応じて次の表に与える値に設定される: ◎ The values have the following meaning:
`none@v | `integer$t | |
---|---|---|
`max-lines$p | `none^v | 指定された `integer$t |
`continue$p | `auto^v | `discard^v |
`block-overflow$p | `clip^v | 指定された値を成す 2 個目の成分が在れば それ / 無ければ `ellipsis^v |
この仕組みがどう演算するかの詳細は、対応する各種~下位propを見よ。 ◎ See the corresponding longhand properties for details about how this mechanism operates.
注記: 試験的な実装には,この略式とその下位propにより定義される全部的な挙動に従うことが奨励されるが、今の所,作者には略式~propのみが公開される。 これは、もっと調製の余地を残しておくためである — 特に、下位propやその値は改称され得る。 ◎ Note: For the time being, experiemental implementations are encouraged to follow the full behavior defined by this shorthand and its longhands, but to only expose the shorthand to authors. This is in order to facilitate further tweaking, and in particular potential renaming, of the longhand properties and their values.
次の例では、各~記事の頭部にある段落は、短くされた~menu内に挙げられ, “… (続きを読む)” で終端する 5 行lの中に収まるよう切落される: ◎ In this example, the lead paragraph of each article is listed in a shortened menu, truncated to fit within 10 lines that end with “… (continued on next page)”:
li { line-clamp: 5 "…(続きを読む)"; } strong { display: block; text-transform: uppercase; }
<li><a href="arch-effect">アンチアーティキュレーテッドバイラテラルスペキュレイティブクラスタスレッディンググリッドコンピューティングボッタクリアーキテクチャには、リレーショナルディストリビューテッドシンジケーションフィードバックシナジーコテンパンエフェクトがあります。</a></li>
見本~描画: ◎ Sample rendering:
旧来の内容との互換性を得るため、 `line-clamp$p を~supportする~UAは, `-webkit-line-clamp@p も別名として~supportし~MUST。 ◎ For compatibility with legacy content, UAs that support line-clamp must also support -webkit-line-clamp as an alias.
複雑な互換性の拘束に因り、素朴な `-webkit-^p による別名でも働けるかどうかは,明白でない。 より複雑な何かが必要になるかもしれない。 issues#2847 ◎ It is not obvious that a naive -webkit- alias can work, due to complicated compatibility constraints. Something more complicated might be needed. <https://github.com/w3c/csswg-drafts/issues/2847>
6. 設定した行l数~後に分断を強制する: `max-lines^p ~prop
◎名 `max-lines@p ◎値 `none$v | `integer$t ◎初 `none^v ◎適 `塊~容器$のうち,`領域~分断$を捉える`断片化~容器$であるもの ◎ block containers which are also fragmentation containers that capture region breaks ◎継 されない ◎百 受容しない ◎算 指定値 ◎順 文法に従う ◎ア `整数として$ ◎表終この~propによる効果は、[ `領域~分断$を捉える`断片化~容器$ ]でないものに対しては,無い。 ◎ This property has no effect on boxes that are not fragmentation containers that capture region breaks.
他の塊~容器に対しては, `max-lines$p の指定値 %N が `none@v でないならば、`~flow内$にある`行l~box$のうち %N 個目の子孫の後に,`領域~分断$が強制される。 ここでは、同じ`塊~整形~文脈$内にある行l~boxのみが数えられる — `独立な整形~文脈を確立する$ものを成す内容は、数えることなく飛ばされる。 ◎ Otherwise, if the value of max-lines is not none, a region break is forced after its Nth descendant in-flow line box, where N is the specified value of max-lines. Only lines boxes in the same Block Formatting Context are counted: the contents of descendants that establish independent formatting contexts are skipped over while counting line boxes.
存在する`行l~box$の個数 ~LT %N の場合、 `max-lines$p による`領域~分断$は導入されない。 ◎ If fewer than N line boxes exist, then max-lines introduces no region break.
注記: このことは、 `max-lines$p は,`複柱~容器$に適用されるときには効果が無いことを含意する — それが包含する行l~boxは,どれも`独立な整形~文脈$の中に入子にされるので。 ◎ Note: This implies that max-lines has no effect when applied to multi-column containers, since any line box they contain are nested into independent formatting contexts.
受容するのは正~整数に限られる。 0 以下の整数は無効になり、当の宣言は`無視され$~MUST。 ◎ Only positive integers are accepted. Zero or negative integers are invalid and must cause the declaration to be ignored.
注記: [ `widows$p / `orphans$p / `break-inside$p ]~propは、[ `max-lines$p ~propにより導入される,強制d`領域~分断$ ]の位置には影響しない。 ◎ Note: The widows, orphans, and break-inside properties do not affect the position of the forced region break introduced by the max-lines property.
注記: “領域~分断( `region break^en )” と命名されているが、これは `CSS-REGIONS-1$r に依存するものではない。 この “領域” は、強制d分断を次の 3 種に分類するために限り利用される ⇒# “頁~分断” (頁を分断する), “柱~分断”(複柱を分断する), “`領域~分断@” (~CSSに起因する他の種類の断片化~容器を分断する) ◎ Note: Despite the “region break” name, this is not a dependency on [CSS-REGIONS-1]. The word “region” is only used as a classifier for forced breaks: they can be “page breaks” (break pages), “column breaks” (breaks multicol), or “region breaks” (break any other kind of css-induced fragmentainers).
`CSS-REGIONS-1$r も `CSS-OVERFLOW-4^r の §断片化 も~supportしない実装にとっては、その種類の分断に出くわすことはなく,これは追加になる。 しかしながら,この追加が `CSS-REGIONS-1^r の機能性を持ち出す必要を孕むことはない。 必要になるのは、次ですべてになる: ◎ If an implementation supports neither [CSS-REGIONS-1] nor CSS Overflow Module Level 4 §fragmentation, then it will have had no occasion yet to run into that kind of breaks, and this will be an addition. However the addition does not involve bringing over any of the [CSS-REGIONS-1] functionality. All that is needed is:
- 断片化-可能である。 ◎ be able to fragment
- 強制d分断の目的において、これらの断片化~容器を “第三の類” (すなわち、頁でも複柱でもない)に分類する。 ◎ classify these fragmentation containers as "category3" (i.e. not pages nor multicol) for the purpose of forced breaks.
7. ~overflowの断片化: `continue$p ~prop
`continue$p ~propは、~boxを`断片化~容器$に転化して( `CSS-BREAK-3$r を見よ),`断片化~分断$の後にある内容は破棄され~MUSTものと指定する能を,作者に与える。 ◎ The continue property gives authors the ability to turn a box into a fragmentation container (see [CSS-BREAK-3]) and to specify that content after the fragmentation break must be discarded.
◎名 `continue@p ◎値 `auto$v | `discard$v ◎初 `auto$v ◎適 `塊~容器$ ◎継 されない ◎百 受容しない ◎算 指定値 ◎順 文法に従う ◎ア 離散的 ◎表終この~propは、 `CSS-REGIONS-1$r の `region-fragment^p ~propを一般化して,それを置換することが意味されている。 この仕様において安定的に足るものになったときは、 `region-fragment^p は `CSS-REGIONS-1^r 仕様から除去されるべきである。 ◎ This property is meant to generalize and replace the region-fragment property from [CSS-REGIONS-1]. Once it is sufficiently stable in this specification, region-fragment should be removed from the regions specification in favor of this.
- `auto@v
- ~boxに収まり切らずに超過した内容は、通例の規則に則って取扱われる — 特に ⇒ ~boxが`断片化~文脈$における`断片化~容器$であって,その文脈を成す最後の`断片化~容器$にならない場合†、`断片化~分断$より後に残っている`断片化d~flow$は,次に来る`断片化~容器$に~flowされる。 (†最後とされていても,必要に応じて自動的に~~追加の断片化~容器を生成するもの — 例えば,領域~連鎖~内の最後の領域 `CSS-REGIONS-1$r — は含まれる。) ◎ If the box has more content than can fit, the excess content is handled according to the usual rules: • If the box is not a fragmentation container or if it is the last fragmentation container in a fragmentation context which does not automatically generate more as needed (for example the last region in a region chain, see [CSS-REGIONS-1]), content that doesn’t fit into the box overflows, as specified by the overflow property. • Otherwise (i.e. the box is a non-last fragmentation container), the remainer of the fragmented flow after the fragmentation break (if any) is flowed to the next fragmentation container in the fragmentation context.\
- いずれにせよ,~boxを囲う辺の外側へ拡張する内容をどう取扱うかは、 `overflow$p ~propが統治し続ける。 ◎ The overflow property continues to govern how to handle the contents of a box that extend outside one of that box’s edges
- `discard@v
- ~boxは、`領域~分断$を捉える`断片化~容器$になる。 `CSS-BREAK-3$r ◎ The box becomes a fragmentation container that captures region breaks, if it is not already. [CSS-BREAK-3]
-
[ 最初の強制d`領域~分断$†, 最初の`非強制~分断$ ]の位置のうち,先に来る方は、`断片化~容器$の終端として扱われる(† `max-lines$p のみならず,[ `break-before$p / `break-after$p ]~propなどの別の仕組みにより課されたものも含む)。 この`断片化~分断$より後にある残りの`断片化d~flow$は、当の`断片化~文脈$において後続する`断片化~容器$に~lay-outされ, `display$p が `none^v にされたときと同様に破棄される — すなわち: ◎ The position of the first forced region break (whether imposed by max-lines or by another mechanism, such as the break-before/break-after properties) or the position of the first unforced break, which ever comes sooner, is treated as the end of the fragmentation container, and the rest of the fragmented flow is laid out in the next fragmentation container in the fragmentation context. The remaining content after the fragmentation break is discarded, similar to if it were display: none:
- 描画されない。 ◎ It is neither rendered,\
- `塊-軸$における[ `最小-内容~size$ / `最大-内容~size$ / `自動的~size$ ]を見出す目的においては,~boxの内容からは~~除外される(計測されない)。 ◎ nor measured as part of the box’s contents for the purpose of finding its min-content, max-content, or automatic block sizes
- 利用者との対話は許容されない。 ◎ It does not allow user interaction
- `有位置の要素$のうち,その静的~位置が破棄された内容~内にあるものも、描画されない。 ◎ Positioned elements whose static position is in the discarded content are not rendered
しかしながら,内在的~sizeは すべての`断片化~容器$にわたって計算されるので、この内容は[ ~boxの`行内-軸$における[ `最小-内容~size$ / `最大-内容~size$ ]を見出す目的 ]においては,織り込まれる( ~sizeが一様でない断片化~容器への分断-法 `CSS-BREAK-3$r を見よ)。 ◎ However, since intrinsic sizes are calculated across all fragmentation containers, this content is taken into account for the purpose of finding the box’s min-content and max-content inline sizes (see CSS Fragmentation 3 §5.1 Breaking into Varying-size Fragmentainers).
- `複柱~容器$に対しては、`~overflow柱$を破棄する効果になる。 ◎ The effect on multi-column containers is to discard any overflow column.
- 注記: 並行する断片化~flowの事例では、[ ~box木において`断片化~分断$より後に生じる内容 ]も依然として描画され得る — それが、この`断片化~容器$の終端を表現している位置より上に~lay-outされるならば。 ◎ Note: In the case of parallel fragmentation flows, content occuring after the fragmentation break in the box tree could still be rendered, if it is laid out above the position representing the end of this fragmentation container.
ある記事に — 下に図示するように — 行内~方向に~overflowしている長い行lがあり,末尾には`断片化~方向$に収まり切らない行lたち(図の赤色)があるとする:
[ `continue$p, `overflow$p ]~propの組合せに基づいて,異なる描画がアリになる:
`continue$p | `discard$v | `auto$v | `discard$v | `auto$v |
---|---|---|---|---|
`overflow$p | `visible^v | `visible^v | `hidden^v | `hidden^v |
描画 | `continue-discard-visible^dgm | `continue-auto-visible^dgm | `continue-discard-hidden^dgm | `continue-auto-hidden^dgm |
8. 塊-軸~overflowの指示-法: `block-overflow^p ~prop
◎名 `block-overflow@p ◎値 `clip$v | `ellipsis$v | `string$t ◎初 `clip$v ◎適 `塊~容器$ ◎継 される ◎百 受容しない ◎算 指定値 ◎順 文法に従う ◎ア 離散的 ◎表終この~propは、(強制dか非強制かを問わず)`領域~分断$より前にある最後の行l~boxの中へ — [ 切落された/中断された ]内容の継続性を指示するため — 内容を挿入できるようにする。 影響するのは,`塊~容器$自身に直に包含されている行l~boxに限られるが、継承されるので,上書きされない限り 子孫の行l~boxにも効果がある。 当の~boxが`領域~分断$の直前に行l~boxを包含しない場合、この~propによる効果は無い。 ◎ This property allows inserting content into the last line box before a (forced or unforced) region break to indicate the continuity of truncated/interrupted content. It only affects line boxes contained directly by the block container itself, but as it inherits, will have an effect on descendants’ line boxes unless overridden. If the box contains no line box immediately preceding a region break, then this property has no effect.
これは、他の型の断片化~分断(例:頁 / 柱)にも適用されるべきか? ◎ Should this apply to other types of fragmentation breaks (e.g. pages, columns)?
挿入される内容は、 `塊~overflow省略符@ と呼ばれる。 各種 値の意味は: ◎ The inserted content is called the block overflow ellipsis. Values have the following meanings:
- `clip@v
- 描画は影響されない。 ◎ The rendering is unaffected.
- `ellipsis@v
- [ U+2026 ( `ellipsis^en, “~~省略符” ), または ~typographic的により適切な等価なもの ]を,影響される行l~boxの終端に`塊~overflow省略符$として描画する。 ~UAは、[ `内容~言語$/書記体系/`書字mode$ ]の規約を利用して,省略符を表す最も適切な文字列を決定するべきである。 ◎ Render an ellipsis character (U+2026)—or a more typographically-appropriate equivalent—as the block overflow ellipsis at the end of the affected line box. UAs should use the conventions of the content language, writing system, and writing mode to determine the most appropriate ellipsis string.
- `string$t
- `塊~overflow省略符$として指定された文字列を,影響される行l~boxの終端に描画する。 ~UAは、この文字列が無為に長い場合には,切落して~MAY。 ◎ Render the specified string as the block overflow ellipsis at the end of the affected line box. The UA may truncate this string if it is absurdly long.
`block-overflow$p は `clip$v でないときには、`塊~overflow省略符$ — 以下,この節を通して単に %省略符 と記す — は,[ 匿名~行内~box %~box に包装された上で,行l~boxの終端に[ 当の`塊~容器$の`根~行内~box$の直の子 ]として配置される ] — 行l~box内の他の内容に可用な空間は減らした上で。 %~box は、その `unicode-bidi$p に `plaintext^v があてがわれた上で,行l~box内の`自動折返し機会$ `CSS-TEXT-3$r のうち[ %省略符 全体が当の行lに収まることになる ]ような最後のものの直後に配置される(その結果、 %省略符 は,当の行l~box内容の全体を成し得る)。 この目的においては、 `overflow-wrap$p により追加される`自動折返し機会$は無視される。 配置した後には、~textの整列と両端揃えが生じ,挿入された %省略符 と 行lの残りの内容とを一緒に計測する。 ◎ When block-overflow is not clip, the block overflow ellipsis string is wrapped in an anonymous inline and placed at the end of the line box as a direct child of the block container’s root inline box, reducing the space in the line box available to the other contents of the line. This inline is assigned unicode-bidi: plaintext and is placed in the line box after the last soft wrap opportunity [CSS-TEXT-3] that would still allow the entire block overflow ellipsis to fit on the line. (This can result in the entire contents of the line box being replaced.) For this purpose, soft wrap opportunities added by overflow-wrap are ignored. Text alignment and justification occurs after placement, and measures the inserted block overflow ellipsis together with the rest of the line’s content.
次の`断片化~容器$が無いため,分断より後にある残りの内容は破棄されることになる場合、~UAは — `text-overflow$p に対するときと同じように — 行lを成す内容を視覚的に置換して~MAY。 次の`断片化~容器$が在って,後続の内容を受取ることになる場合、 %省略符 により置換された内容は その`断片化~容器$へ押出され、 %省略符 は,当の行lを成す`~flow内$にある内容の一部を成していたかのように挿入され, ~lay-outされ~MUST。 その結果、行lの中や行lにより影響0される~layoutは変化する — それらの~~連鎖を分断する手段は~UAに委ねられる。 ◎ If there is no next fragmentation container and thus the remainder of the content after the break would be discarded, then the UA may visually replace the contents of the line, as it does for text-overflow. If, however, there is a next fragmentation container that would receive subsequent content, then the content replaced by the block overflow ellipsis must be pushed to the next fragmentation container and the block overflow ellipsis inserted and laid out exactly as if it were part of the in-flow contents of the line. This can result in changes to layout within or impacted by the line. The means of breaking any resulting cycles is up to the UA.
%省略符 が行l内に収まるには長過ぎる場合の結果は、定義されない。 (~UAは、例えば, %省略符 を分断-不能な文字列として扱っても,あるいは %省略符 を複数~行lに — 先に来る行lたちの内容も置換するように — ~lay-outしても~MAY。) ◎ If the block overflow ellipsis is too long to fit in the line, the result is undefined. (The UA may, for example, treat the block overflow ellipsis as an unbreakable string, or it may lay out the string across more than one line, replacing content in earlier lines as well.)
%省略符 は、~eventを捕捉しない — どの~pointer~eventも,その奥にあるものか, %省略符 により視覚的に置換されたものへ配送される。 ◎ The block overflow ellipsis does not capture events: pointer events are dispatched to whatever is underneath or otherwise visually replaced by it.
%省略符 による~boxの内在的~sizeに対する効果は無い — ~boxの[ `最小-内容~size$, `最大-内容~size$ ]は、 `block-overflow$p は `clip$v であったかのように計算される。 ◎ It also has no effect on the intrinsic size of the box: its min-content and max-content sizes are calculated exactly as if block-overflow were clip.
注記: 将来の仕様は、この特色機能を拡張し得る。 例えば, `ellipsis^pe 疑似要素を供して,当の~textを~styleできるようにしたり、塊の子~要素の選択を許容する行内levelあるいは塊level指示子として利用するために(その事例では、~eventを捕捉できる)。 ◎ Note: Future specifications may extend this feature, for example by providing an ::ellipsis pseudo-element to style the text, or by allowing the selection of a child element of the block to use as either an inline-level or block-level indicator (in which case, it can capture events).
9. ~privacyと~security上の考慮点
この仕様は、新たな~privacyや~security上の懸念を導入するものではない。 ◎ This specification introduces no new privacy or security concerns.
謝辞
とりわけ、次の方々からの~feedbackに:
Thanks especially to the feedback from Rossen Atanassov, Bert Bos, Tantek Çelik, John Daggett, Daniel Glazman, Vincent Hardy, Håkon Wium Lie, Peter Linss, Robert O’Callahan, Florian Rivoal, Alan Stearns, Steve Zilles, and all the rest of the www-style community.