Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > HTML > Hex Color Codes - Hex 6 <=> Hex 3

Reply
Thread Tools

Hex Color Codes - Hex 6 <=> Hex 3

 
 
Neredbojias
Guest
Posts: n/a
 
      08-18-2005
With neither quill nor qualm, Steve Pugh quothed:

> Neredbojias wrote:
> > With neither quill nor qualm, Kevin Scholl quothed:
> >
> > > > Or should I simply use basic rounding to change Hex6 to Hex3 (ie
> > > > #A1B7C9 becomes #ABD).
> > >
> > > Actually, #9BC would be closer.

> >
> > How do you figure that?

>
> ABD = AABBDD
> 9BC = 99BBCC
>
> A1 = 161, AA = 170, 99 = 153
> hence A1 is closer to 99 than AA
>
> C9 = 201, DD = 221, CC = 204
> hence C9 is closer to CC than DD
>
> So #9BC would be the closest Hex3 version of #A1B7C9
>
> Steve


Duh, yeah, I do that all the time. #abd is *not* #a0b0d0, it's #aabbdd.
I will write that in a complete sentence 500 times on notebook paper as
soon as I disconnect.

--
Neredbojias
Contrary to popular belief, it is believable.
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Changing font color from current font color to black color Kamaljeet Saini Ruby 0 02-13-2009 04:58 PM
How to use file I/o codes with form and controls codes Allen ASP .Net 1 12-03-2007 12:04 AM
Virtual Key Codes, Scan Codes and ASCII Codes in C gj_williams2000@yahoo.co.uk C Programming 2 08-20-2005 11:04 AM
RegEx replace of html codes to ascii codes Greg -- ASP .Net 4 08-09-2005 07:27 PM
hex(-5) => Futurewarning: ugh, can't we have a better hex than '-'[:n<0]+hex(abs(n)) ?? Bengt Richter Python 6 08-19-2003 07:33 AM



Advertisments