HighDots Forums  

Re: Image display and white space

Cascading Style Sheets Layout/presentation on the WWW (comp.infosystems.www.authoring.stylesheets)


Discuss Re: Image display and white space in the Cascading Style Sheets forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Tony T
 
Posts: n/a

Default Re: Image display and white space - 08-17-2003 , 07:40 AM







"Evertjan." <exjxw.hannivoort (AT) interxnl (DOT) net> wrote

Quote:
Tony T wrote on 17 aug 2003 in
comp.infosystems.www.authoring.stylesheets:

Is there any way other than using absolute or relative positioning (or
tables) for each image that will reliably render a grid of images
without any gaps on all - or at least most - browsers and platforms?

What about float and clear in css ?

I can't see quite how this could work, but I'm prepared to try if you can
suggest a way!

T
---
replace "from" with "to" for email address






Reply With Quote
  #2  
Old   
Tony T
 
Posts: n/a

Default Re: Image display and white space - 08-17-2003 , 12:25 PM







"Evertjan." <exjxw.hannivoort (AT) interxnl (DOT) net> wrote


Quote:
.grid img {
float:left;
border: 0px;
padding: 0px;
margin :0px;
}
/style
base href="http://rnetworks2002.users.btopenworld.com/csstest/"
/head><body
div class="grid"
img src="red.gif" width=100 height=100 alt="red"
img src="green.gif" width=100 height=100 alt="green"
br style="clear:left;"
img src="blue.gif" width=100 height=100 alt="blue"
img src="yellow.gif" width=100 height=100 alt="yellow"
br style="clear:left;"
/div

Yes, this does it better - see
http://rnetworks2002.users.btopenwor...est/grid2.html

NN4.5 loses two of the squares, but I can live with a workaround for NN4 if
I have to.

---
Tony T
Replace 'from' with 'to' (twice) for e-mail







Reply With Quote
  #3  
Old   
Evertjan.
 
Posts: n/a

Default Re: Image display and white space - 08-17-2003 , 12:46 PM



Tony T wrote on 17 aug 2003 in
comp.infosystems.www.authoring.stylesheets:

Quote:
div class="grid"
img src="red.gif" width=100 height=100 alt="red"
img src="green.gif" width=100 height=100 alt="green"
br style="clear:left;"
img src="blue.gif" width=100 height=100 alt="blue"
img src="yellow.gif" width=100 height=100 alt="yellow"
br style="clear:left;"
/div


Yes, this does it better - see
http://rnetworks2002.users.btopenwor...est/grid2.html

NN4.5 loses two of the squares, but I can live with a workaround for
NN4 if I have to.

You need the second <br style="clear:left;"> to be able to have text under
the img-es

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)


Reply With Quote
  #4  
Old   
Andrew Thompson
 
Posts: n/a

Default Re: Image display and white space - 08-17-2003 , 12:52 PM



"Tony T" <fromny.turfromn (AT) btinternet (DOT) com> wrote

Quote:
"Evertjan." <exjxw.hannivoort (AT) interxnl (DOT) net> wrote in message
news:Xns93DA98F90F376eejj99 (AT) 194 (DOT) 109.133.29...

snip Evertjan's solution>....
http://rnetworks2002.users.btopenwor...est/grid2.html

NN4.5 loses two of the squares, but I can live with a workaround for NN4
if
I have to.
That now works on both IE 6 and Moz, but
breaks on NN 4.8 (loses 2 squares), whereas
the 4.01 transitional form at my site worked
for NN 4.8.

The subtleties of browser versions..

--
Andrew Thompson
http://www.lensescapes.com/
http://www.physci.org/
http://www.1point1c.org/




Reply With Quote
  #5  
Old   
Tony T
 
Posts: n/a

Default Re: Image display and white space - 08-17-2003 , 02:18 PM



I had a brainwave ....

here's the original but with the img {margin} set to img {margin: -2px;}

http://rnetworks2002.users.btopenwor...negmargin.html

Seems to work quite well except in NN4.5
--
Tony T
Replace 'from' with 'to' (twice) for e-mail





Reply With Quote
  #6  
Old   
Andrew Thompson
 
Posts: n/a

Default Re: Image display and white space - 08-17-2003 , 08:35 PM



"Tony T" <fromny.turfromn (AT) btinternet (DOT) com> wrote

Quote:
I had a brainwave ....

here's the original but with the img {margin} set to img {margin: -2px;}

http://rnetworks2002.users.btopenwor...negmargin.html
But not 4.8..

Red
Green

Blue
Yellow

All down the left column!

--
Andrew Thompson
http://www.lensescapes.com/
http://www.physci.org/
http://www.1point1c.org/




Reply With Quote
Reply




Thread Tools
Display Modes

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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.