473,765 Members | 2,203 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

User selectable font size and IE6

Hi all,
I'm building some style sheets and trying to play the old game of
balancing designer pixel perfection and still allowing users to adjust
their font sizes. The compromise I've made with the designer is that
he'll accept allowing users to change font sizes it it "looks right"
with the default setting.
I'm using em to set the font size. So, anyway, here's the problem. At
0.96em we get the perfect font size. But, if the font is changed with
'view->text size->larger' it becomes gigantic, 'view->text
size->smaller' makes it microscopic. Of course Firefox does nice
gradual changes with ctl+ and ctl-

Any thoughts on how to make this work better?

Oct 4 '06 #1
40 2976
Paul Davis wrote:
Hi all,
I'm building some style sheets and trying to play the old game of
balancing designer pixel perfection and still allowing users to
adjust their font sizes. The compromise I've made with the designer
is that he'll accept allowing users to change font sizes it it "looks
right" with the default setting.
It sounds as if your designer doesn't care to allow visitors with less
than perfect eyesight to use your site.
I'm using em to set the font size. So, anyway, here's the problem. At
0.96em we get the perfect font size. But, if the font is changed with
'view->text size->larger' it becomes gigantic, 'view->text
size->smaller' makes it microscopic. Of course Firefox does nice
gradual changes with ctl+ and ctl-

Any thoughts on how to make this work better?
It has been written that IE has a problem/bug when font-sizing is done
using em units. Try: font-size: 96%; instead.

--
-bts
-Motorcycles defy gravity; cars just suck
Oct 4 '06 #2
Scripsit Paul Davis:
I'm using em to set the font size.
Why? It sounds you are trying to set the _overall_ font size. Setting it in
em units (or as a percentage) can only have two effects:
1) none (user-selected font size is used)
2) font size is set to a value that systematically differs from what the
user has chosen, i.e. no matter what the user has done, the dee-ziner has
decided it's wrong.
So, anyway, here's the problem.
Yes. So stop creating it.
At 0.96em we get the perfect font size.
For some very odd value for "perfect". It is very unlikely that there is
_any_ effect, unless, of course, there's something you haven't told us.
Typical user choices like 12pt or 14pt will be used, since reducing the
declared size by 4% has no effect on the actual size - there's most probably
no font that is just a very little smaller than 12pt or 14pt.
But, if the font is changed with
'view->text size->larger' it becomes gigantic, 'view->text
size->smaller' makes it microscopic.
For some odd values for "gigantic" or "microscopi c". Granted, the IE font
control is primitive and coarse, but why, oh why, do so many authors want to
deprive users of even that primitive tool or to make it work in
unpredictable ways?
Any thoughts on how to make this work better?
Remove all font-size declarations (except for headings).

--
Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/

Oct 4 '06 #3

Beauregard T. Shagnasty wrote:
Paul Davis wrote:
Hi all,
I'm building some style sheets and trying to play the old game of
balancing designer pixel perfection and still allowing users to
adjust their font sizes. The compromise I've made with the designer
is that he'll accept allowing users to change font sizes it it "looks
right" with the default setting.

It sounds as if your designer doesn't care to allow visitors with less
than perfect eyesight to use your site.
the trouble is its true. I haven't many who do.
You know its a sad day when the developer is fighting the designer to
make a site *more usable*
>
I'm using em to set the font size. So, anyway, here's the problem. At
0.96em we get the perfect font size. But, if the font is changed with
'view->text size->larger' it becomes gigantic, 'view->text
size->smaller' makes it microscopic. Of course Firefox does nice
gradual changes with ctl+ and ctl-

Any thoughts on how to make this work better?

It has been written that IE has a problem/bug when font-sizing is done
using em units. Try: font-size: 96%; instead.
That seems to work.
I Think I found a piece of the problem too.
The font size was being defined in the rule
* {
font-size: 0.96em;
font-family: Arial, Helvetica, sans-serif;
}
so, apparently the variation in font size gets magnified for each level
of tag nesting.
Doh !!!
Font size is now in the body definition, all is well.
>
--
-bts
-Motorcycles defy gravity; cars just suck
Oct 4 '06 #4
Paul Davis wrote:
Beauregard T. Shagnasty wrote:
>It sounds as if your designer doesn't care to allow visitors with
less than perfect eyesight to use your site.

the trouble is its true. I haven't many who do. You know its a sad day
when the developer is fighting the designer to make a site *more
usable*
There are many sad days. Most "deeziners" don't have a clue about
accessibility and usability. Every deziner I know has perfect eyesight.
>It has been written that IE has a problem/bug when font-sizing is done
using em units. Try: font-size: 96%; instead.

That seems to work.
I Think I found a piece of the problem too.
The font size was being defined in the rule
* {
font-size: 0.96em;
font-family: Arial, Helvetica, sans-serif;
}
so, apparently the variation in font size gets magnified for each level
of tag nesting.
Doh !!!
Font size is now in the body definition, all is well.
Ah yes. Glad you found the problem.

--
-bts
-Motorcycles defy gravity; cars just suck
Oct 4 '06 #5

Jukka K. Korpela wrote:
Scripsit Paul Davis:
I'm using em to set the font size.

Why? It sounds you are trying to set the _overall_ font size. Setting it in
em units (or as a percentage) can only have two effects:
1) none (user-selected font size is used)
2) font size is set to a value that systematically differs from what the
user has chosen, i.e. no matter what the user has done, the dee-ziner has
decided it's wrong.
Re-read the post, the goal is to ensure users can change it.
It doesn't matter if the designer is wrong. The business owners decided
to go with the design, they decided to pay me to implement.
>
So, anyway, here's the problem.

Yes. So stop creating it.
At 0.96em we get the perfect font size.

For some very odd value for "perfect". It is very unlikely that there is
_any_ effect, unless, of course, there's something you haven't told us.
Typical user choices like 12pt or 14pt will be used, since reducing the
declared size by 4% has no effect on the actual size - there's most probably
no font that is just a very little smaller than 12pt or 14pt.
But, if the font is changed with
'view->text size->larger' it becomes gigantic, 'view->text
size->smaller' makes it microscopic.

For some odd values for "gigantic" or "microscopi c". Granted, the IE font
control is primitive and coarse, but why, oh why, do so many authors want to
deprive users of even that primitive tool or to make it work in
unpredictable ways?
Any thoughts on how to make this work better?

Remove all font-size declarations (except for headings).
Great idea, with a small problem.
Not being independently wealthy, I need to earn a paycheck to feed my
family. My job as a developer is to take a designer's idea and turn it
into reality. If I don't do that, management will hire someone who
will.
I am not a designer, I don't claim to be and I'm not artistic enough to
do it even if I wanted to. I write code.
While your suggestions are nice from a purity standpoint (although it
suggests that we should all use gopher browsers) It doesn't help from
an employment standpoint.
>
--
Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/
Oct 4 '06 #6
Paul Davis wrote:
Beauregard T. Shagnasty wrote:
[snip]
>It has been written that IE has a problem/bug when font-sizing is done
using em units. Try: font-size: 96%; instead.
[snip]
The font size was being defined in the rule
* {
font-size: 0.96em;
font-family: Arial, Helvetica, sans-serif;
}
so, apparently the variation in font size gets magnified for each level
of tag nesting.
The effect of that rule is that the computed font size for each element
does gradually get smaller the deeper the element is within the document
tree, but that isn't why MSIE fouls up text resizing so badly.

When em length font sizes are applied to an element and a descendant
without a non-em length font-size declaration applied to an ancestor,
MSIE grossly miscalculates the computed font size for the descendant.

I demonstrated this to someone else earlier this year (the text was from
another example):

<http://mwinter.webhop. info/dd/john-scheuer/font-size.html>

If a non-em length font-size declaration was included in the rule for
the body element or the html element, or if the 1em value in the
#em-length rule was changed to 100%, the problem would disappear.

Mike
Oct 4 '06 #7
Scripsit Paul Davis:
Re-read the post, the goal is to ensure users can change it.
You cannot ensure it and you cannot prevent it. You can just make it more
difficult, and that seems to be what you have originally decided to do.

Regarding reading, you seem to have quoted almost my entire message, for no
good reason since you don't comment all of it, and you haven't apparently
read it comprehensively .
It doesn't matter if the designer is wrong.
It matters to me, and to the user, and ultimately to the site owner too.
The business owners
decided to go with the design, they decided to pay me to implement.
Fine. Are you suggesting that you made an agreement on doing something that
shouldn't be done _and_ you don't have an idea of how to do that? Do you
expect us to help you with that for free? Anyway, it's pointless since we
don't even know what you really agreed to do, so we can't decide whether
it's even possible or not.
My job as a developer is to take a designer's idea and turn it
into reality.
Even if you haven't even understood the idea and don't know how to implement
it? If someone pays you for that, shouldn't you get a subcontractor now?
(Please don't contact me for that. You would most probably have to pay me
much more than you get.)

--
Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/

Oct 4 '06 #8

Paul Davis wrote:
I'm building some style sheets and trying to play the old game of
balancing designer pixel perfection and still allowing users to adjust
I suggest balancing the dezyner outside a high window.
I'm using em to set the font size. So, anyway, here's the problem. At
0.96em we get the perfect font size
At 1em your users get their perfect font size.
Any thoughts on how to make this work better?
I used to think breaking the dezyner's fingers was the way to go, but
now I favour poking them in the eyes -- just enough to reduce their
vision until they appreciate the problem.
BODY TEXT GOES AT 1EM

NOTHING GOES LESS THAN 60% / 0.6em

If you want the text to fit the hole, size the hole in ems too

Set your heights in ems. Probably the widths too. Keep your widths in
pixels if you're having to work around lots of fixed size images. The
text in ems will wrap to fit better than the images will fit a box
sized in ems. Avoid mixing units in adjacent boxes though -- stick to
one or the other (or at least test carefully). Mixing units for
horizontal and vertical is OK. Mixing units between parents and
children is OK.

If you absolutely _must_ keep some font sizes fixed (small breadcrumbs
and flyspeck-3 are reasonable) then size the text in pixels, size the
container height in pixels, and hope they don't view it in Firefox.

Oct 4 '06 #9
Jukka K. Korpela wrote:
Scripsit Paul Davis:
>But, if the font is changed with
'view->text size->larger' it becomes gigantic, 'view->text
size->smaller' makes it microscopic.

For some odd values for "gigantic" or "microscopi c".
Not 'odd' at all, at least not the way you usually infer that means.
Windows IE has a well-known bug scaling font sizes set in em units. Any
browser View->Text Size setting other than "Medium" truly does end up
gigantic or microscopic. That bug has been mentioned in this and other
newsgroups many times. I'm surprised you aren't aware of it.

--
Berg
Oct 4 '06 #10

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

Similar topics

11
5002
by: trinitypete | last post by:
Hi all, I have a user control that uses control literal to build a heading with a link, and a div containing links below. As the link heading is hit, I want to change the style of the div, making it visible or not. Yep you guessed it, expanding tree type functionality. The header has an onclick event onclick='Doexpandcollapse
1
1663
by: Tebogo Tefo via .NET 247 | last post by:
Hi I have a user control that contains three dropdownlists that I populate according to what was selected in the other dropdownlist (i.e. populate dropdownlist2 after selecting a value in dropdownlist1) The App works fine if I don't add the user control that I created and all events on the page work and thus the App is perfect. But as soon as I add my user control (Here used as the TopNav for my page) all
8
3026
by: fernandezr | last post by:
I would like to use a user control as a template inside a repeater. Some of the fields in the control should be hidden depending on whether or not there is data. I'm still a ASP .Net newbie so the way I'm going about doing this might be a little off. I'd appreciate some help. Below is the code I have thus far but I'm not sure how to reference the user control within the foreach loop. <asp:Panel ID="pnlRosterProfile" runat="Server" />
2
1841
by: underground | last post by:
Hi, everyone I've been trying to figure out a way for a user to update there information. I'm using sections to identify the specific user..Here is the form <? include("include/session.php"); ?> <? $username="xxxxxx"; $password="xxxxxxx"; $database="xxxxx";
15
2292
by: bb nicole | last post by:
The company profile showed blank after user login and click the company profile button. Supposed the company profile should not be blank and will show the company information which call from database. I use the session in login page. Thus, in the begining of companyProfile's coding, i put session_start();. What is the problem of my php code?? Thanks.. <?php ob_start(); session_start(); include_once("database.php"); if($_GET ==...
1
3250
by: kang jia | last post by:
hi when user entered particulars in signuppage and click" signup" button, i will direct them to do_signup.php. if say the NRIC is dupicate in datebase, i will redirect them back to signup page again to re-signup, however, i would like to remain all the correct infromation, and let users re-entered their NRIC. how can i do this. can i use Session, but it seems cant work. any one can help me? my code in signup page is like this: ...
82
10063
by: happyse27 | last post by:
Hi All, I modified the user registration script, but not sure how to make it check for each variable in terms of preventing junk registration and invalid characters? Two codes below : a) html b) perl script (print and inserting into database) Cheers... Andrew
9
4243
by: happyse27 | last post by:
Hi All, In perl script(item b below) where we check if html registration form are filled in properly without blank with the necessary fields, how to prompt users that the field are incomplete or blank and then go back to main page(item a below user registration html page) always, something like goggle or msn login page function... Thanks and Best Rgds, Andrew a) script called from user registration html...
0
9568
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
10156
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
10007
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
9951
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
9832
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
8831
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
6649
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5275
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
3
2805
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.