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

Re: New values for Float property

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Mon, 30 Nov 2009 08:46:10 -0600
Message-ID: <dd0fbad0911300646v1a4211y74878dd8ed8c9d59@mail.gmail.com>
To: Salar <salarsoftwares@gmail.com>
Cc: www-style <www-style@w3.org>
On Mon, Nov 30, 2009 at 8:34 AM, Salar <salarsoftwares@gmail.com> wrote:
> Hi,
>
> I would like to suggest new values for "float" style.
>
> Here are two new values:
> far: behaves like "right" when direction of element is "ltr", and behaves
> like "left" when direction of element is "rtl".
> near: behaves like "left" when direction of element is "ltr", and behaves
> like "right" when direction of element is "rtl".
> Note: "far" and "near" are just suggested names and can be different.
>
> Why these are important? Because currently in RTL languages to develop a
> multilingual website, changing elements position requires another stylesheet
> file (e.g. rtl.css) to implement right-to-left layout. The reason is because
> of float attribute which acts same in rtl and ltr directions.
> So adding these two values to float property will help developers a lot.
>
> If we continue this concept, such values or properties can be applied for
> these styles too:
> padding-left
> padding-right
> border-left
> border-right
> outline-left
> outline-right
> margin-left
> margin-right
> background-position
> and more if there is any...

Text-direction-independent values already exist for most or all of
those properties - rather than top/bottom/left/right you use
before/after/start/end.  I can see the logic in allowing the
left/right equivalents (I forget which pair it is - I think start/end
are for the text-direction and before/after are for the
block-direction) in float, especially when float is *actually* used
typographically, not just as a hacky page layout tool.

~TJ
Received on Monday, 30 November 2009 14:46:42 UTC

This archive was generated by hypermail 2.4.0 : Monday, 23 January 2023 02:13:41 UTC