-
-
Notifications
You must be signed in to change notification settings - Fork 52
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
wrong text justification at last line of page caused by consecutive ruby elements #985
wrong text justification at last line of page caused by consecutive ruby elements #985
Comments
この問題が起きる条件は、段落の最後の下端の位置がページエリアの下端の位置にぎりぎり入るか入らないか微妙な位置で、その段落内に連続した ruby 要素( Chromiumで最小文字サイズがあるためルビが大きめになってしまう問題を解決するためにrt要素にzoomプロパティでの縮小をするようにしていることが関係する。 Chromiumで、zoomプロパティで縮小が指定されている要素があると、
で返される rects 配列のうちその要素に対するrect の bottom が実際の要素のその要素の下端の位置よりも大きな値になる。 getRangeBox()の処理で、ruby要素など分割位置を決める処理で問題が起きる可能性がある要素を除外するようにしているが、ruby要素が2つ連続していると、この除外が働かない。次のところを直すとよさそうである: vivliostyle.js/packages/core/src/vivliostyle/layout.ts Lines 2169 to 2181 in 10e8b4b
|
|
https://github.com/vivliostyle/vivliostyle.js/releases/tag/v2.18.0 ### Features - **viewer:** add crop marks setting ([1d0834b](vivliostyle/vivliostyle.js@1d0834b)), closes [#993](vivliostyle/vivliostyle.js#993) - **viewer:** change "User Style" to "Custom Style" and treat it as an author stylesheet by default ([bdb26d4](vivliostyle/vivliostyle.js@bdb26d4)), closes [#991](vivliostyle/vivliostyle.js#991) - **viewer:** set bookMode=true as default ([5411264](vivliostyle/vivliostyle.js@5411264)), closes [#992](vivliostyle/vivliostyle.js#992) ### Bug Fixes - error with `<object>` tag ([9e9565f](vivliostyle/vivliostyle.js@9e9565f)), closes [#995](vivliostyle/vivliostyle.js#995) - errors on the Acid2 Browser Test ([849a604](vivliostyle/vivliostyle.js@849a604)) - failed some of the css-variables tests ([5d0f324](vivliostyle/vivliostyle.js@5d0f324)) - incorrect column-rule positioning in vertical writing mode ([3cc0e01](vivliostyle/vivliostyle.js@3cc0e01)), closes [#978](vivliostyle/vivliostyle.js#978) - unnecessary page break caused by ruby elements ([21eb17c](vivliostyle/vivliostyle.js@21eb17c)), closes [#987](vivliostyle/vivliostyle.js#987) - valid CSS rules ignored after parsing error with invalid or unsupported CSS rule ([5e76ed5](vivliostyle/vivliostyle.js@5e76ed5)), closes [#597](vivliostyle/vivliostyle.js#597) [#976](vivliostyle/vivliostyle.js#976) - **viewer:** problem on author/user stylesheet switch ("Set as user stylesheet" checkbox) ([2799a34](vivliostyle/vivliostyle.js@2799a34)) - **viewer:** tweak Reset Custom Style checkbox behavior ([9c96ccb](vivliostyle/vivliostyle.js@9c96ccb)) - **viewer:** unbound this error "Cannot set properties of undefined" ([2505458](vivliostyle/vivliostyle.js@2505458)) - wrong cascading on shorthand property with CSS variable ([2ee7927](vivliostyle/vivliostyle.js@2ee7927)), closes [#979](vivliostyle/vivliostyle.js#979) - wrong cascading with CSS !important ([fb1dae2](vivliostyle/vivliostyle.js@fb1dae2)), closes [#986](vivliostyle/vivliostyle.js#986) - wrong text justification at last line of page caused by consecutive ruby elements ([ad26952](vivliostyle/vivliostyle.js@ad26952)), closes [#985](vivliostyle/vivliostyle.js#985)
…ug fixes - https://github.com/vivliostyle/vivliostyle.js/releases/tag/v2.18.1 - https://github.com/vivliostyle/vivliostyle.js/releases/tag/v2.18.0 ### Features - **viewer:** add crop marks setting ([1d0834b](vivliostyle/vivliostyle.js@1d0834b)), closes [#993](vivliostyle/vivliostyle.js#993) - **viewer:** change "User Style" to "Custom Style" and treat it as an author stylesheet by default ([bdb26d4](vivliostyle/vivliostyle.js@bdb26d4)), closes [#991](vivliostyle/vivliostyle.js#991) - **viewer:** set bookMode=true as default ([5411264](vivliostyle/vivliostyle.js@5411264)), closes [#992](vivliostyle/vivliostyle.js#992) ### Bug Fixes - error with `<object>` tag ([9e9565f](vivliostyle/vivliostyle.js@9e9565f)), closes [#995](vivliostyle/vivliostyle.js#995) - errors on the Acid2 Browser Test ([849a604](vivliostyle/vivliostyle.js@849a604)) - failed some of the css-variables tests ([5d0f324](vivliostyle/vivliostyle.js@5d0f324)) - incorrect column-rule positioning in vertical writing mode ([3cc0e01](vivliostyle/vivliostyle.js@3cc0e01)), closes [#978](vivliostyle/vivliostyle.js#978) - unnecessary page break caused by ruby elements ([21eb17c](vivliostyle/vivliostyle.js@21eb17c)), closes [#987](vivliostyle/vivliostyle.js#987) - valid CSS rules ignored after parsing error with invalid or unsupported CSS rule ([5e76ed5](vivliostyle/vivliostyle.js@5e76ed5)), closes [#597](vivliostyle/vivliostyle.js#597) [#976](vivliostyle/vivliostyle.js#976) - wrong cascading on shorthand property with CSS variable ([2ee7927](vivliostyle/vivliostyle.js@2ee7927)), closes [#979](vivliostyle/vivliostyle.js#979) - wrong cascading with CSS !important ([fb1dae2](vivliostyle/vivliostyle.js@fb1dae2)), closes [#986](vivliostyle/vivliostyle.js#986) - wrong text justification at last line of page caused by consecutive ruby elements ([ad26952](vivliostyle/vivliostyle.js@ad26952)), closes [#985](vivliostyle/vivliostyle.js#985)
Test sample: https://gist.github.com/MurakamiShinyu/ea376875cc6943d22cc3b740e9843975
Test with Vivliostyle Viewer (v2.17.2):
https://vivliostyle.github.io/viewer/v2.17.2/#src=https://gist.githubusercontent.com/MurakamiShinyu/ea376875cc6943d22cc3b740e9843975/raw/page-last-line-bug.html
Result screenshot:
The text was updated successfully, but these errors were encountered: