473,396 Members | 1,722 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

What's with three letter colours now?

as opposed to six letter colours?

I'm seeing body {color: #fff; background: #000;} and stuff lately.
Is this a new form of abbreviation?

BB
--
www.kruse.co.uk SE*@kruse.demon.co.uk
home of SEO that's shiny!
--
Jul 21 '05 #1
12 16051
* Big Bill wrote in comp.infosystems.www.authoring.stylesheets:
I'm seeing body {color: #fff; background: #000;} and stuff lately.
Is this a new form of abbreviation?


http://www.w3.org/TR/CSS1#color-units
http://www.w3.org/TR/CSS2/syndata.html#color-units
http://www.w3.org/TR/CSS21/syndata.html#color-units
http://www.w3.org/TR/css3-color/#numerical
--
Björn Höhrmann · mailto:bj****@hoehrmann.de · http://bjoern.hoehrmann.de
Weinh. Str. 22 · Telefon: +49(0)621/4309674 · http://www.bjoernsworld.de
68309 Mannheim · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/
Jul 21 '05 #2
Big Bill wrote:
as opposed to six letter colours?

I'm seeing body {color: #fff; background: #000;} and stuff lately.
Is this a new form of abbreviation?


New? Hasn't it always been part of the css specification?
Jul 21 '05 #3
Paul wrote:
Big Bill wrote:
as opposed to six letter colours?

I'm seeing body {color: #fff; background: #000;} and stuff lately. Is
this a new form of abbreviation?


New? Hasn't it always been part of the css specification?


Part of the HTML spec too. But beware: some old browsers can't handle
the 3-digit colours.

Jul 21 '05 #4
* C A Upsdell wrote in comp.infosystems.www.authoring.stylesheets:
I'm seeing body {color: #fff; background: #000;} and stuff lately. Is
this a new form of abbreviation?


New? Hasn't it always been part of the css specification?


Part of the HTML spec too. But beware: some old browsers can't handle
the 3-digit colours.


Which HTML spec (and according to which section in that spec?)
--
Björn Höhrmann · mailto:bj****@hoehrmann.de · http://bjoern.hoehrmann.de
Weinh. Str. 22 · Telefon: +49(0)621/4309674 · http://www.bjoernsworld.de
68309 Mannheim · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/
Jul 21 '05 #5
Bjoern Hoehrmann wrote:
* C A Upsdell wrote in comp.infosystems.www.authoring.stylesheets:
I'm seeing body {color: #fff; background: #000;} and stuff lately. Is
this a new form of abbreviation?

New? Hasn't it always been part of the css specification?


Part of the HTML spec too. But beware: some old browsers can't handle
the 3-digit colours.

Which HTML spec (and according to which section in that spec?)


Y'know, I took a look at both the HTML 4.01 and CSS 2 specs. The HTML
spec says nothing about the length of a hex colour code; the CSS spec
says that the code can be either 3 or 6 digits. So I'm not sure what
this means: does this mean that the HTML spec can take colour codes of
indefinite length: I could find nothing in the spec to either affirm or
refute this.

Jul 21 '05 #6
"Big Bill" wrote in comp.infosystems.www.authoring.stylesheets:
as opposed to six letter colours?

I'm seeing body {color: #fff; background: #000;} and stuff lately.
Is this a new form of abbreviation?


Yes, it was introduced only about ten years ago. :-)

--
Stan Brown, Oak Road Systems, Tompkins County, New York, USA
http://OakRoadSystems.com/
HTML 4.01 spec: http://www.w3.org/TR/html401/
validator: http://validator.w3.org/
CSS 2.1 spec: http://www.w3.org/TR/CSS21/
validator: http://jigsaw.w3.org/css-validator/
Why We Won't Help You:
http://diveintomark.org/archives/200..._wont_help_you
Jul 21 '05 #7
"C A Upsdell" wrote in comp.infosystems.www.authoring.stylesheets:
But beware: some old browsers can't handle
the 3-digit colours.


Which?

--
Stan Brown, Oak Road Systems, Tompkins County, New York, USA
http://OakRoadSystems.com/
HTML 4.01 spec: http://www.w3.org/TR/html401/
validator: http://validator.w3.org/
CSS 2.1 spec: http://www.w3.org/TR/CSS21/
validator: http://jigsaw.w3.org/css-validator/
Why We Won't Help You:
http://diveintomark.org/archives/200..._wont_help_you
Jul 21 '05 #8
* C A Upsdell wrote in comp.infosystems.www.authoring.stylesheets:
Part of the HTML spec too. But beware: some old browsers can't handle
the 3-digit colours.


Which HTML spec (and according to which section in that spec?)


Y'know, I took a look at both the HTML 4.01 and CSS 2 specs. The HTML
spec says nothing about the length of a hex colour code; the CSS spec
says that the code can be either 3 or 6 digits. So I'm not sure what
this means: does this mean that the HTML spec can take colour codes of
indefinite length: I could find nothing in the spec to either affirm or
refute this.


It means it is not defined... Please write to ww*************@w3.org to
report errors in the HTML/XHTML specifications.
--
Björn Höhrmann · mailto:bj****@hoehrmann.de · http://bjoern.hoehrmann.de
Weinh. Str. 22 · Telefon: +49(0)621/4309674 · http://www.bjoernsworld.de
68309 Mannheim · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/
Jul 21 '05 #9
C A Upsdell > wrote:
<snip>

Y'know, I took a look at both the HTML 4.01 and CSS 2 specs. The HTML
spec says nothing about the length of a hex colour code; the CSS spec
says that the code can be either 3 or 6 digits.
http://www.w3.org/TR/1999/REC-html40...tml#type-color

So I'm not sure what this means: does this mean that the HTML spec can take colour codes of
indefinite length: I could find nothing in the spec to either affirm or
refute this.


"A color value may either be a hexadecimal number (prefixed by a hash
mark) or one of the following sixteen color names."

So if 3-digit codes work in html, it is a browser "feature". Since the
color attribute is being deprecated this discussion is irrelevant.

Paul
Jul 21 '05 #10
On Wed, 29 Dec 2004 20:37:36 -0500, Stan Brown
<th************@fastmail.fm> wrote:
"Big Bill" wrote in comp.infosystems.www.authoring.stylesheets:
as opposed to six letter colours?

I'm seeing body {color: #fff; background: #000;} and stuff lately.
Is this a new form of abbreviation?


Yes, it was introduced only about ten years ago. :-)


Well I can't keep up with everything!
I ask as only a day or so ago I saw it for the firest time and as luck
would have it saw it twice.

BB
--
www.kruse.co.uk SE*@kruse.demon.co.uk
home of SEO that's shiny!
--
Jul 21 '05 #11
On Thu, 30 Dec 2004 03:03:49 +0100, Bjoern Hoehrmann
<bj****@hoehrmann.de> wrote:
* C A Upsdell wrote in comp.infosystems.www.authoring.stylesheets:
Part of the HTML spec too. But beware: some old browsers can't handle
the 3-digit colours. Which HTML spec (and according to which section in that spec?)
Y'know, I took a look at both the HTML 4.01 and CSS 2 specs. The HTML
spec says nothing about the length of a hex colour code; the CSS spec
says that the code can be either 3 or 6 digits. So I'm not sure what
this means:...
It means it is not defined... Please write to ww*************@w3.org to
report errors in the HTML/XHTML specifications.


And since when is a "color" information of interest in a markup
language?

--
Rex
Jul 21 '05 #12
JRS: In article <ud********************************@4ax.com>, dated
Wed, 29 Dec 2004 23:34:32, seen in news:comp.infosystems.www.authoring.s
tylesheets, Big Bill <kr***@cityscape.co.uk> posted :
Subject: What's with three letter colours now? as opposed to six letter colours?

I'm seeing body {color: #fff; background: #000;} and stuff lately.
Is this a new form of abbreviation?

(1) The body of a News article should be related to, but not dependent
on, the Subject line.

(2) I note that others have, while being keen to score points, not
provided an explanation. So see

Cascading Style Sheets, level 1
W3C Recommendation 17 Dec 1996
http://www.w3.org/pub/WWW/TR/REC-CSS1

which includes :-

6.3 Color units

...

The format of an RGB value in hexadecimal notation is a '#' immediately
followed by either three or six hexadecimal characters. The three-digit
RGB notation (#rgb) is converted into six-digit form (#rrggbb) by
replicating digits, not by adding zeros. For example, #fb0 expands to
#ffbb00. This makes sure that white (#ffffff) can be specified with the
short notation (#fff) and removes any dependencies on the color depth of
the display.

--
© John Stockton, Surrey, UK. ?@merlyn.demon.co.uk Turnpike v4.00 IE 4 ©
<URL:http://www.jibbering.com/faq/> JL/RC: FAQ of news:comp.lang.javascript
<URL:http://www.merlyn.demon.co.uk/js-index.htm> jscr maths, dates, sources.
<URL:http://www.merlyn.demon.co.uk/> TP/BP/Delphi/jscr/&c, FAQ items, links.
Jul 21 '05 #13

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

86
by: Michael Kalina | last post by:
Because when I asked for comments on my site-design (Remember? My site, your opinion!) some of you told me never to change anything on font-sizes! What do you guys think of that:...
4
by: Els | last post by:
Hi, I would like an opinion on the following: I have a page which is made up of background-images with transparent linked images in front of it, which on hover show text in CSS popups. Due to...
6
by: Fungii | last post by:
Hello, I have a stylesheet that sets p:first-letter to a certain size and colour. I was playing around with Javascript to change paragraph stylesheets using an array like this: var paras =...
8
by: Doug Laidlaw | last post by:
I tried to grab an image from a Web page the other day. It turned out that the page was made up of three horizontal bands, and part of the image was in each. One band was a JPEG, another was a...
4
by: Tim Marshall | last post by:
The report indicated in the send object command below has various colours in it which show nicely when the report is previewed and printed. However, when sent as an attachment to users without...
4
by: Harro de Jong | last post by:
(absolute beginner here, sorry if this seems basic) Section 7.10 of 'How to Think Like a Computer Scientist' contains this discussion of string.find and other string functions: (quote) We can...
4
by: Michael Meckelein | last post by:
Hello, Wondering, if C# (framework 2.0) does not support parsing DateTime timezones in three letter acronyms. I would like to parse date strings like "2005 Nov 01 11:58:47.490 CST -6:00" but...
31
by: anon856525 | last post by:
Hello I am seeking the best way (speed and portability) to program mode 13h (320 x 200 256 colors), and mode X. I am using Borland's Turbo C ver 3.0 for MS DOS. With Borland product, I can...
5
by: Jameson | last post by:
Hi, I have a list of known colours, generated using: Dim colorNames As New System.Collections.Generic.List(Of String) For Each known As KnownColor In .GetValues(GetType(KnownColor)) Dim...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.