473,320 Members | 2,052 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Layout tears apart when resizing text

Dear NG,

years have passed and I am still more designer than programmer. I
build a new version of my website which has a few nasty bugs,
especially on my startpage: Resizing text brakes the dotted lines
which I use as visual border on the left and right edge of the page
layout and thus produces an unwanted white gap above the enlarged
text. Viewing the page with IE shows this behaviour even without
changing the font size.

My Idea was to create a containing block (#cont-dyn) for the two
arrows and the text centered within them with a background image which
should repeat along the x-axis when the text is resize. It seems to me
that this background image is not rendered in the browsers.

Below is a link to the affected page:
http://tomasio.at/index.html

The corresponding CSS can be found here:
http://tomasio.at/stylesheet3.css

Any hints will be very appreciated.

kind regards,
--
tomasio
Nov 8 '06 #1
6 2246
On 2006-11-09, tomasio <da****@jan.etwrote:
Dear NG,

years have passed and I am still more designer than programmer. I
build a new version of my website which has a few nasty bugs,
especially on my startpage: Resizing text brakes the dotted lines
which I use as visual border on the left and right edge of the page
layout and thus produces an unwanted white gap above the enlarged
text.
My Idea was to create a containing block (#cont-dyn) for the two
arrows and the text centered within them with a background image which
should repeat along the x-axis when the text is resize. It seems to me
that this background image is not rendered in the browsers.
You're not seeing it because of margin-collapsing. The paragraph that
starts "Willkommen zur Homepage" has a top margin of 1.12em (assuming
the default stylesheet), and the margin therefore also gets bigger as
the text does (that's how em units work).

This margin "collapses" with the top margin of #cont-dyn since there is
no border or padding between them. In other words, after collapsing,
#cont-dyn has a top margin of 1.12em and the top edge of the p is
aligned with its top edge. That's why you can't see the background
image.

If you want to keep the margin on the paragraph and see your background
image, add "padding-top: 1px" to #cont-dyn. This will keep the p's
top margin contained inside #cont-dyn.

Alternatively you might prefer the effect of losing the top margin on
the p. If you set margin-top: 0 on .copy, you won't get such a big gap
when the text is resized and perhaps won't need #cont-dyn and the
background image at all.
Below is a link to the affected page:
http://tomasio.at/index.html

The corresponding CSS can be found here:
http://tomasio.at/stylesheet3.css
Nov 9 '06 #2
Ben C wrote:
On 2006-11-09, tomasio <da****@jan.etwrote:
>Dear NG,

Resizing text brakes the dotted lines
which I use as visual border on the left and right edge of the page
layout and thus produces an unwanted white gap above the enlarged
text.
>My Idea was to create a containing block (#cont-dyn)
with a background image which should repeat
along the x-axis [actually y-axis] when the text is resize[d].
It seems that this background image is not rendered in the browsers.

You're not seeing it because of margin-collapsing.

That's why you can't see the background image.
The images will be visible only after the background declarations are
removed from div.copy since they hide/overlay the background of
div#cont-dyn. Then the background image extends when the text is
resized. I have no idea why background images are provided for both, the
div.copy on the x-axis and the div#cont-dyn on the y-axis, but the
div.copy one is not needed. Additionally, there is I believe an attempt
by the OP to cure this with z-index: 1; applied to div#cont-dyn which
does nothing and is not needed.

Only once the above is taken care of will the background image be
viewable and an unwanted white gap is (not so-) evident on resizing the
text. You are right on with collapsing margins causing this unwanted
white gap to the background image extension on resizing and with either
of your cures it is eliminated.

It certainly would have been easier to actually see the problem right
away, but that fine, faint yellow was really hard to spot. Time to relax
my eyes now.

--
Gus
Nov 9 '06 #3
Hi Ben and Gus!

Thank you a lot for your helpful input. I finally managed to fix this
display bug and can leave the page online. have a luck on the fruits
of your advice: http://tomasio.at
Nov 11 '06 #4
On Sun, 12 Nov 2006 00:42:28 +0100, tomasio <da****@jan.etwrote:
>Hi Ben and Gus!

Thank you a lot for your helpful input. I finally managed to fix this
display bug and can leave the page online. have a luck on the fruits
of your advice: http://tomasio.at
hrhm.. I meant "have a _look_".
Nov 11 '06 #5
tomasio wrote:
On Sun, 12 Nov 2006 00:42:28 +0100, tomasio <da****@jan.etwrote:
>Hi Ben and Gus!

Thank you a lot for your helpful input. I finally managed to fix this
display bug and can leave the page online. have a luck on the fruits
of your advice: http://tomasio.at
hrhm.. I meant "have a _look_".
I still think that the faint yellow hurts my eyes, but in any case:
/* Des bringts. */

--
Gus
Nov 12 '06 #6
On Sun, 12 Nov 2006 00:08:18 -0500, Gus Richter
<gu********@netscape.netwrote:
>tomasio wrote:
>On Sun, 12 Nov 2006 00:42:28 +0100, tomasio <da****@jan.etwrote:
>>Hi Ben and Gus!

Thank you a lot for your helpful input. I finally managed to fix this
display bug and can leave the page online. have a luck on the fruits
of your advice: http://tomasio.at
hrhm.. I meant "have a _look_".

I still think that the faint yellow hurts my eyes, but in any case:
/* Des bringts. */
Danke, Gus!

In the meanwhile I put up the complete homepage. Maybe I will change
the yellow sometimes, too ; )
Nov 24 '06 #7

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

Similar topics

82
by: Peter Diedrich | last post by:
The site design is pretty simple: ============================================ | Head | ============================================ | | ...
8
by: kaeli | last post by:
I have had a little free time lately to revisit a problem I have with the 3 column layout plus a header and footer. See this example: http://glish.com/css/7.asp There is a header and 3...
20
by: Tammy | last post by:
What would be a good alternative to using frames? I need something that will section my webpage into two halves and can change both frames on a single click. Thanks in Advance, Tammy
5
by: Stephen Poley | last post by:
There are plenty of people around these groups who promote the idea of flexible page design. However, while employing relative units and not fixing column-widths is a big improvement on...
33
by: Dave (DreamIsle) | last post by:
Hello. I'm working on a layout that I need to be pixel specific. How can I get the font to stay precisely the height I need? Specifying line-height or font-size in px doesn't yield the results I...
14
by: Anoop | last post by:
Hi, I am new to this newsgroup and need help in the following questions. 1. I am workin' on a GUI application. Does C# provides Layout Managers the way Java does to design GUI? I know that it...
7
by: Trammel | last post by:
Im trying to do something which I hoped would be alot easier than it seems. Im trying to design the layout of the page in CSS to avoid table, etc but having problems making the bottom "fade"...
1
by: tomasio | last post by:
Dear Experts, I want to behave the text on my homepage like in this example: http://tomasio.at/temp/korrekt.gif The dashed lines on the left and right borders should continue seamlessly while...
5
by: Ed Sproull [MSFT] | last post by:
First I'm pretty new to ASP.NET and I'm having a simple problem. I have small website with a header, sidebar and the the content. I want my content to appear beside my sidebar which seems to be a...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you

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.