W3C home > Mailing lists > Public > www-style@w3.org > January 2013

[css3-values] Predefined constants in calc() notation

From: Jan Tojnar <jtojnar@gmail.com>
Date: Fri, 18 Jan 2013 00:44:36 +0100
Message-ID: <CAFGSp1tjcRjRxC9ao+3oRMCT2c5Z74W2s-Y-L3mNUr++p8Td-Q@mail.gmail.com>
To: www-style@w3.org
Hi,

I just made a beautiful rectangle using golden ratio but the following code
doesn’t really look nice:

calc(1.6180339887498948482*10em)

I know I can define a custom variable and use it instead but prefefined
constants (PHI, PI…) and functions (sqrt) would be better – compare:

calc(phi*10em)


Also sorry if this was already requested, I could’t find it anywhere.

Jan Tojnar
Received on Friday, 18 January 2013 05:58:45 GMT

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