mirror of
https://github.com/servo/servo.git
synced 2025-06-06 16:45:39 +00:00
Support text-align: start
and end
This commit is contained in:
parent
5b0c6c9d31
commit
81e8f18662
5 changed files with 59 additions and 4 deletions
|
@ -908,12 +908,12 @@ impl InlineFlow {
|
|||
text_align::T::justify if !is_last_line && text_justify != text_justify::T::none => {
|
||||
InlineFlow::justify_inline_fragments(fragments, line, slack_inline_size)
|
||||
}
|
||||
text_align::T::left | text_align::T::justify => {}
|
||||
text_align::T::left | text_align::T::justify | text_align::T::start => {}
|
||||
text_align::T::center => {
|
||||
inline_start_position_for_fragment = inline_start_position_for_fragment +
|
||||
slack_inline_size.scale_by(0.5)
|
||||
}
|
||||
text_align::T::right => {
|
||||
text_align::T::right | text_align::T::end => {
|
||||
inline_start_position_for_fragment = inline_start_position_for_fragment +
|
||||
slack_inline_size
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue