-
HTML and Style Sheets
It's a slow day at work, so I'm playing with stuff that I don't know much about. I'm reading in a bitmap stored with indexed color, writing out the color palette, and then I want to write a table of pixels that should look like the picture.
The problem I'm running into is that I've defined the style sheet as follows:
Code:
td { width:20px; height:20px }
.color0 { background-color:rgb(0,0,0) } //etc
Each td has a class attribute that defines the background color for that cell. Of course, I can't define the td tag to have a width of 20px in some places and 1px in other places. I can't really define the width in the color either. So I tried something like this:
Code:
.colorcell { width:20px; height:20px }
.pixelcell { width:1px; height:1px }
.color0 { background-color:rgb(0,0,0) } //etc
However, I don't think you can give cells two classes. Anyone know how to get around this problem?
-
I'm not quite sure with what you want to accomplish. Can you upload the picture? How 'bout having 20 1px's (if it's relevant at all)?