|
|
Re: Slides from EclpseCon 2011 [message #932025 is a reply to message #926211] |
Wed, 03 October 2012 19:05   |
Kris Missing name Messages: 47 Registered: July 2009 |
Member |
|
|
Hi Holger,
thanks for the info on the examples from the talk. They helped me to
understand the vex editor a little better.
What I am still struggling with is the display of images. The inline
display (img height = line height) is OK, but the display of images that
shall have their original size - I don't get it to work.
Is there an xhtml example that shows how to display images non inline,
e.g. what you can see here:
http://wiki.eclipse.org/Vex/NewAndNoteworthy#1.0.0_M3_.282010-11-08.29
(the big image)?
In Bug 298912 the following is mentioned
(https://bugs.eclipse.org/bugs/show_bug.cgi?id=298912#c30):
"In block elements, Vex tries to show the image in its original size,
but scales it to the width of the containing element, if the image is
bigger."
I am not sure whether my tests have properly set a "block element" in
xhtml strict. E.g. what I tried is:
<?xml version='1.0'?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Test</title>
</head>
<body>
<p>Text Text Text</p>
<div>
<img src="eclipse-vex-page.png"></img>
</div>
<p/>
</body>
</html>
As style I am using the "XHTML plain" as part of vex editor. This css
has the definition:
div {
display: block;
}
So I think this is a proper interpretation for a block element in xhtml
with the used css. However the image displayed is limited to the line
height although it is far bigger in height an width as displayed.
What I also tried is giving the img tag in the xhtml in the style
attribute the "display: block" directly; unfortunately with no effect...
To cut the long story short - what must one do to display images in
xhtml as block element having its original size?
Thanks
Kris
Am 28.09.12 14:15, schrieb Holger Voormann:
> Hi Kris,
>
> Samples and snippets of Florian's Vex EclipseCon Europe 2011 talk (which
> are more important than the slides) are at GitHub: github.com/ftl/ece2011
>
> Yes, in XHTML the path of the image to show are specified by the src
> attribute of the img element. This is done via CSS:
> img {
> background-image: attr(src);
> height: attr(height);
> width: attr(width);
> }
> In CSS you could either directly specify the path of the (background)
> image (same image for all matching elements) or delegate to an attribute
> value (attr(...)).
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.02120 seconds