This is an old revision of the document!


Justification Keywords for Alignment

Spec:
css3-align, css3-flexbox
Owner:
fantasai
Status:
Open, Urgent
Added:
2012-05-16
Action:
Pick proposal A, B, or C
Issue:
http://lists.w3.org/Archives/Public/www-style/2012May/0554.html

Background

There are three possible behaviors for distributing items evenly along an axis:

Edges flush

 |[item]<-------->[item]<-------->[item]|

Equal spacing

 |<--->[item]<--->[item]<--->[item]<--->|

Equal margins

 |<-->[item]<---->[item]<---->[item]<-->|

Note: In Flexbox, you can get the equal-margins effect with auto margins, but only if you want the minimum spacing to be zero. Which might be sufficient for this level, but would be a candidate for future extension.

Related prior art:

  • text-justify: distribute; /* edges flush */
  • ruby-align: distribute-letter; /* edges flush */
  • ruby-align: distribute-space; /* equal margins */
  • background-repeat: space; /* edges flush */

Problem Statement

Flexbox currently uses justify to mean “edges flush” and distribute to mean “equal margins”. This has two problems:

  • It's unclear from the names which is which.
  • The distribute value of text-justify means “edges flush”, which is inconsistent.

We need keywords that clearly and unambiguously specify each of the behaviors (or at least two, really, since only two are wanted).

Proposal(s)

Proposal 0 (current spec)
justify vs. distribute
Proposal A
distribute vs. distribute-space
Proposal B
distribute-flush vs. distribute-space
Proposal C
distribute vs. space
 
topics/justification-keywords.1337278832.txt.gz · Last modified: 2014/12/09 15:48 (external edit)
Recent changes RSS feed Valid XHTML 1.0 Valid CSS Driven by DokuWiki