473,715 Members | 2,193 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Re: Style problem (DIV sizing)

On 2008-11-16, Hannah <hu************ @usenet.kitty.s ub.orgwrote:
Hi!

On this page:
http://www.lifesong.de/veranstaltungen.html
firefox 2 shows the page (especially the boxes) as I want them to
display (let the width scale according to viewport size, let the
"background " image scale accordingly, let the text wrap freely and the
height adjust).

However, konqueror (3.5.9) misdisplays the page: The DIVs are about 2 to
3 times as high as in firefox, the "background " images of the DIVs are
stretched vertically and cover the text of some of the DIVs towards the
bottom. Am I wrong or is konqueror wrong? And if the latter, how can I
workaround it, i.e. force konqueror to have an even top/bottom padding
around the text (using the interor div.padding) instead of such an
uneven one?
I think Konqueror is wrong. You've asked for the images to be 100% of
their containers, which should work even though the containers have auto
heights because the images are absolutely positioned.

Konqueror is treating the height: 100% like height: auto and preserving
the aspect ratio of the image (it's quite a tall thin image) leading to
the problem.

I can't see a solution that doesn't involve a compromise. Easiest is
just to put overflow: hidden on the containers
(div.veranstalt ungentoenederse ele etc.) The only difference with Firefox
will be that the images will have their proper aspect ratio and be
cropped rather than being scaled to fit. But it looks OK and at least
they won't cover over things up.

In CSS3 I hear you will be able to do scaled background images. Jam
tomorrow.
Nov 16 '08 #1
1 2667
On 2008-11-16, Hannah <hu************ @usenet.kitty.s ub.orgwrote:
Hi!

Ben C <sp******@spam. eggswrote:
>>On 2008-11-16, Hannah <hu************ @usenet.kitty.s ub.orgwrote:
>>On this page:
http://www.lifesong.de/veranstaltungen.html
firefox 2 shows the page (especially the boxes) as I want them to
display (let the width scale according to viewport size, let the
"background " image scale accordingly, let the text wrap freely and the
height adjust).
>>However, konqueror (3.5.9) misdisplays the page: The DIVs are about 2 to
3 times as high as in firefox, the "background " images of the DIVs are
stretched vertically and cover the text of some of the DIVs towards the
bottom. Am I wrong or is konqueror wrong? And if the latter, how can I
workaround it, i.e. force konqueror to have an even top/bottom padding
around the text (using the interor div.padding) instead of such an
uneven one?
>>I think Konqueror is wrong. You've asked for the images to be 100% of
their containers, which should work even though the containers have auto
heights because the images are absolutely positioned.
>>Konqueror is treating the height: 100% like height: auto and preserving
the aspect ratio of the image (it's quite a tall thin image) leading to
the problem.

I'm not sure, frankly. If I look at the second image,
"pfingstros en-scaled.jpg", in an image viewer, and compare that with the
konqueror result, it seems that konqueror stretches the image
vertically.
You're right it is. It's not ignoring 100% but treating it as 100% of
the _wrong thing_. It's making it 100% of #main or even of the whole
viewport, and then cropping it.

Remove the height: 100% altogether and it should look better (and then
it will also look the same in Firefox).
Nov 17 '08 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

34
11058
by: Mark Moore | last post by:
It looks like there's a pretty serious CSS bug in IE6 (v6.0.2800.1106). The HTML below is validated STRICT HTML 4.01 and renders as I would expect in Opera, FrontPage, and Netscape. For some reason, there's an annoying vertical gap between adjacent rules that doesn't go away. This looks like IE6 is incorrectly setting the margin to some arbitrary value. Does anyone know if this is a known bug at MS? If you know of one, post the...
5
35082
by: Chris Stromberger | last post by:
I have a div with a width of 40em (is em cool to use for width?). The situation below applies even if width is auto or 80% or something. Inside the div I am displaying some code with <pre> tags. If the code has a very long line (wider than the div), then what's supposed to happen? IE and Mozilla do two very different things. IE expands the div to encompass the line (creating horizontal scrollbars in the browser window if nec). Mozilla...
1
7579
by: Chris Pudney | last post by:
G'day, I am using CSS to construct bar charts from nested DIVs. In general this works fine. However, in certain circumstances I need to display multiple charts inline. To get consistent results on IE and Moz I wrap each chart in a <TABLE style="display: inline">. Unfortunately, IE ignores the top-margin and left-margin properties of a few of the charts, which end up in the top left corner of the page. The charts that get this treatment...
19
6005
by: Lauren Quantrell | last post by:
In Windows XP display Properties/Appearance users can chose between: Windows XP Style or Windows Classic Style. Is there a way in VBA to determine the user's selection? The reason: Toolbars size taller in XP than in Classic so I need to size all those nifty windows sizing commands depending on the user's preference.
12
2767
by: deko | last post by:
I'm trying to get a 1px border around the content section of this page: http://www.clearpointsystems.com As you will see, I have a header/nav bar (looks correct), but the border around the content is not centered and does not resize properly as the browser window is resized. The goal is a 1px border around the content (div id="page") with about 30px (or 2%) margin all around and the border/content should resize as the browser
6
13777
by: rongchaua | last post by:
Hi all, I want to change the style of a button. But I don't know how to do it. For example, I have already a button OK on form. I want to add these styles to this button (WS_CHILD || WS_VISIBLE || WS_CLIPSIBLINGS || WS_TABSTOP || BS_FLAT). What should I do now? All help will be appreciated. rca.
3
1918
by: Michellevt | last post by:
Hi I am working on a project (for college) and wondered if anyone can help me with my problem. In the project we are not allowed to make use of any "style" attributes but "class" attributes instead. The following is the java script that i am using and i am having trouble in using a class instead of a style tag because simply replacing the style=\"position:absolute;\" tag with class=\"posiAbs\" where in the external css ".posiAbs...
1
541
by: dorayme | last post by:
In article <gfq3no$r1d$1@oxygen.pond.sub.org>, hu47121+nospam@usenet.kitty.sub.org (Hannah) wrote: Surely you don't really want this to look like this in FF or any browser: <http://dorayme.890m.com/pics/unhappyscrollbars.png> There is so little point in scrollbars coming up for a not very wide left side menu. A sign that the design is wrong.
0
1326
by: dorayme | last post by:
In article <gfvfdd$7vj$1@oxygen.pond.sub.org>, hu47121+nospam@usenet.kitty.sub.org (Hannah) wrote: Just to tell you that this latest one loads very fast on my machine now and much easier to read. Well done. Maybe you might consider a point I raised earlier about not needing extra div for your navigation UL. Since then, you might have even added yet another wrapper!
0
8817
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8715
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9322
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9193
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9092
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9037
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7963
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
4734
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3170
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.