W3C home > Mailing lists > Public > www-style@w3.org > November 2012

Re: [css3-text] better way to do forced last-line justification

From: Kang-Hao (Kenny) Lu <kanghaol@oupeng.com>
Date: Fri, 30 Nov 2012 19:05:20 +0800
Message-ID: <50B892F0.8020602@oupeng.com>
To: "Tab Atkins Jr." <jackalmage@gmail.com>
CC: www-style list <www-style@w3.org>
(12/11/30 1:45), Tab Atkins Jr. wrote:
>> Yet the full set of combinations of text-align/text-align-last still
>> leaves lots of combinations for which I don't think there's a clear
>> use case.
> 
> We established early on that there are more use-cases.  Some country's
> poetic customs right-align the last line, for example.

But then there's 'text-align: start end' for this use case too. For this
use case, do we really want to give authors two ways to achieve the same
effect?

If I were asked to choose 'text-align: start end' or 'text-align: start;
text-align-last: end', I would go for the former because it's shorter.

Also, in IE10, 'text-align-last' doesn't apply if 'text-align' isn't
'justify'. Did IE folks express interest in changing this rather old (10
years+) behavior? On the other hand, Firefox shipped the currently
specced behavior (that 'text-align-last' always apply) for a while now,
so if there's backward-compat issue that might have been already caught.

> Yes, there are some silly combinations.  But supporting them all costs
> nothing over supporting the "good" ones that we already know have
> use-cases

The "cost" I have more concern with is the fact that 'text-align-last'
isn't a longhand for 'text-align', which violates the common
shorthand/longhand pattern[1] in CSS.

But now that 'text-align-last' is already widely deployed without being
a longhand, I guess the best we can do is to make it deprecated (like
what we do in HTML to make it "semantic") or kick it out indefinitely
(like 'display: run-in').

> , because the last line doesn't interact with the rest of the
> paragraph.  Once you can left, right, and center the last line, you
> can do so independently of what the rest of the paragraph is doing.

The current interaction is a bit messy. The spec says 'text-align-last'
wins unless 'text-align' is 'start end'

> So, since there might be use-cases for the odd combinations that we
> don't know, let's not create extra work for ourselves in disallowing
> some combos.

I see little work to do either way.


[1] http://lists.w3.org/Archives/Public/www-style/2012Apr/0155


Cheers,
Kenny
-- 
Web Specialist, Oupeng Browser, Beijing
Try Oupeng: http://www.oupeng.com/
Received on Friday, 30 November 2012 11:05:54 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:21:03 GMT