Re: [xslt] LibXSLT adding annoying whitespace



On Wed, Jun 13, 2001 at 12:14:19PM +0200, Raphael Hertzog wrote:
> Le Wed, Jun 13, 2001 at 12:57:03AM -0400, Daniel Veillard écrivait:
> > If you can tell me more about why this is different I may try to get
> > this fixed, but I really don't see why ! <br> has to be formated on a separate
> > block under the img and the anchor/img block has to be formated on another
> > one under the <br>, so I really don't see why and how the 2 extra lines
> > can impact the rendering in any way.
> 
> It is rendered differently because of spaces. 
> 
> <img><img> would cause 2 images to be more or less joined.
> However <img> <img> would not join images since there's a
> space between ...
> 
> <img><br><img> is exactly the same except that you work vertically instead
> of horizontally. If you put spaces, images will no more be joined.
> 
> I always found that annoying but it's done this way in all browsers.

  Okay right ... I also note that:

<html><body>
<img>
<br>
<a><img></a>
</body></html>

  generates the large gap, while

<html><body>
<img><br>
<a><img></a>
</body></html>

  keep the same rendering with a small gap as

<html><body>
<img><br><a><img></a>
</body></html>

 and

<html><body><img><br><a><img></a></body></html>

  so basically the key is to not add superfluous content after the <img>
tag. This seems confirmed (at least on netscape) by

<html><body>
<img><br>
<img><br>
<img>
</body></html>

  which keeps only a small gap between the images.
Could someone confirm this behaviour on IE (and Mozilla my setup is broken) ?

Daniel

-- 
Daniel Veillard      | Red Hat Network http://redhat.com/products/network/
veillard@redhat.com  | libxml Gnome XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]