[TYPO3-content-rendering] CSS problem in CSS-styled IMGTEXT

JoH info at cybercraft.de
Tue Mar 14 12:19:31 CET 2006


> in current TYPO3 4.0 RC1 we have a problem with margins in Images and
> Text with Images rendering with my css-styled-imgtext solution.
>
> Currently I simply apply the same margins to the *right* of all
> pictures if they are to be placed to the left (in-text or
> stand-alone) and to the *left* if they are to be placed to the right.
> If placed centered currently I simply place the same margins to the
> *right*. There are several problems with that:
>
> 1) the centered version is never 100% centered, only if you have no
> margins in between images
> 2) there is no way to specify a different textMargin, because the
> "margin-right" that is applied to images (in-text-left) will also
> separate the images from the text.
> 3) you can never create a block of images that really spans across the
> whole content width (there will always be a margin to left or right)
>
> The only solution I can think of is to tag the last (or first) image
> on each row of images with a special CSS-class and reset the margin
> on that images to zero. Then I could also apply specific textMargin
> around the whole image block in case the imageblock is in-text, so
> that we can specify this separately
> (styles.content.imgtext.textMargin).
>
> What do you think? Other ideas?

Use tables ;-)

No, just kidding. In fact there is no other option than assigning a
different class to the first (or last) item in one row.
Additionally you should think about assigning different classes to the first
(or last) item in a column for cases where "no Rows" is selected.

Joey

-- 
Wenn man keine Ahnung hat: Einfach mal Fresse halten!
(If you have no clues: simply shut your knob sometimes!)
Dieter Nuhr, German comedian
openBC: http://www.cybercraft.de





More information about the TYPO3-project-content-rendering mailing list