Click to See Complete Forum and Search --> : text size
bluemojave
02-27-2003, 04:13 PM
Is there a way to block somebody from seeing enlarged text as set from their control panel on a web page? Specifically a code that would maintain the text size integrity regardless of their control panel settings? I've seen sites out there where this is the case, I just can't find the comand. Any help would be greatly appreciated! Thanks!
PeOfEo
02-27-2003, 04:27 PM
I dont think you can actually alter the text size and keep it the same reguardless of resolution and other settings. But however you can redirect depending on resolution using java script. You whould have to make a page for a couple different reolutions. Meaning make ur normal page then one with little text for 800 by 600 users and ones with big text for users with resolution that is higher then your normal page's resolution. Then you put the redirect scripts in your index so a user has the java script look at his resolution and then take him to where he needs to be. You might have to take into account other settings but I have not looked at my controll pannel lately.
Zach Elfers
02-28-2003, 11:03 PM
Use a pixel value. <span style="font-size:15px">This text will not change in size even if you specify large text</span>.
Stefan
03-01-2003, 03:30 PM
Originally posted by Zach Elfers
Use a pixel value. <span style="font-size:15px">This text will not change in size even if you specify large text</span>.
Zach forgot to mention that that is an IE/Win specific bug. Basilcy all other browsers will still be able to resize the text and so will very likely the next IE browser.
Your real solution is to NOT design a page that forces a specific font size. You have to realize that if someone changes their fontsize it's for a good reason. Trying to override a usersetting will verylikely piss offyour visitors and in this case might even make your site compleatly unreadable on their system.
BillHely
03-01-2003, 08:00 PM
Originally posted by bluemojave
Is there a way to block somebody from seeing enlarged text as set from their control panel on a web page? Specifically a code that would maintain the text size integrity regardless of their control panel settings? I've seen sites out there where this is the case, I just can't find the comand. Any help would be greatly appreciated! Thanks!
Blue, "font-size: NNpx" is standard CSS1 and is widely respected by browsers. See http://www.webreview.com/style/css1/charts/mastergrid.shtml. Even though that chart is not right up to date you can see that CSS' "font-size:" has wide acceptance.
In light of Stefan's comments, keep in mind that "page zooming" and "text resizing" are two different things.
Personally I use fixed font size (declared in pixels) a lot, because of the limited alternatives. So long as you are sensible about the fixed size you select and are aware of the trade-offs, I believe it is a perfectly acceptable technique for controlling your layout. You'll find a good treatment of this subject at http://www.alistapart.com/stories/fear4/ - although you may benefit more by starting with the first article of that series at http://www.alistapart.com/stories/fear/index.html.
Regards,
Stefan
03-02-2003, 11:03 AM
Originally posted by BillHely
Personally I use fixed font size (declared in pixels) a lot, because of the limited alternatives.
Just out of interest, why do you feel you can't use eg % as an alternative?
PeOfEo
03-02-2003, 02:13 PM
I personally prefer the % so things change for other resolutions
BillHely
03-02-2003, 05:11 PM
Originally posted by Stefan
Just out of interest, why do you feel you can't use eg % as an alternative?
Hi Stefan.
I rarely have the time to personally experiment with all of the possibilities all of the time (be it CSS or something else entirely) - so for me it is quicker and more efficient to search out the experience of others on a given topic, then experiment further if necessary.
Hence, in answer to your question, can I refer you to a follow-on page of one of the links I posted earlier: http://www.alistapart.com/stories/fear4/5.html.
Scroll down to the sub-heading: Percentage units.
One could argue personal preferences all day - there is no right or wrong when it come to that. But I do think the author of the above article is right in suggesting that PRECISE control can only be achieved with pixel sizing.
Regards,
Stefan
03-02-2003, 06:40 PM
Originally posted by BillHely
But I do think the author of the above article is right in suggesting that PRECISE control can only be achieved with pixel sizing.
Based on that quote I would say the author doesn't even knows what he's talking about.
"Precise control" is an textbook illusion that is not present in the web world. You have no knowledge of how big a text will be no matter what you try, if you cannot control/know the hardware they use.
Thus "precise" does not even exist in reality.
This leaves the only differences between using Pixel and % to be
* % follows the prefered user default in the browser. Pixel overrides the users preferences setting.
* IE is buggy with pixels, but not with % (this alone should be an overwhelming enough reason to not use pixels, since we are talking about 80% of the webbrowsers in actual use...)
So IMO % is not only a viable option to pixel but also a much better choise overall (for media screen).
BTW, when reading articles it's always a good idea to look at when it was written. Something written eg 3 years ago (2000) about CSS and browsersupport is very likely not accurate in todays world.
BillHely
03-02-2003, 08:16 PM
Originally posted by Stefan
Based on that quote I would say the author doesn't even knows what he's talking about.
"Precise control" is an textbook illusion that is not present in the web world. You have no knowledge of how big a text will be no matter what you try, if you cannot control/know the hardware they use. etc blah blah blah
I have neither the time for, nor any interest in, a discussion based in semantics or nit-picking.
However, any time you manage to engage Zeldman (http://www.happycog.com/people/zeldman/) in a discussion on "the author doesn't even knows what he's talking about", please let me know. I want to buy tickets.
Zeldman is right up there with Eric Meyer in the CSS-guru stakes. While taking every opinion of any expert as gospel is unwise, to suggest that a person of such obvious and recognized expertise "doesn't even knows what he's talking about" is asinine in the extreme.
Ever heard the old saw "Horses for courses"? There are no absolutes; use what best fits a given scenario. Even Meyer, who on occasion has expressed a preference for relative sizing, has frequently used fixed sizes when that option better fits the requirements of the task in hand.
Finally, fixed-size by pixel is very adequately supported by any recent versions of IE.
prairiegirl
03-02-2003, 10:52 PM
this is probably a big mistake, don't want to get in the middle of a boxing match, but I've been looking at Mr. Meyer's books and he seems to indicate that px is a very imprecise way to set text size. I've always used px. He uses em. I've never used em. I'm confused.
Anyway, I'm sort of interested why anyone would want to be sure a font stayed a certain size. Why wouldja? Other than for beauty, which is sort of moot if a user can't read the text...
Stefan
03-03-2003, 04:04 AM
Originally posted by BillHely
[B]I have neither the time for, nor any interest in, a discussion based in semantics or nit-picking.
If you have neighter the time nor even the interest, why do you recomend one method over another? In this case you even repetedly state you don't "have time" to even test with using anything else then pixels.
Yet you have absolutely no problem with presenting what you think is the best option even if you yourself state many times that your opininon is not based on firm grounds.
When I present MY opinion on what the best solution is (based on personal experience as well as a solid theoretical ground) you snap back at me.
Why are you allowed to share your uninformed opinion when I'm not allowed to share my informed opinion?
However, any time you manage to engage Zeldman (http://www.happycog.com/people/zeldman/) in a discussion on "the author doesn't even knows what he's talking about", please let me know. I want to buy tickets.
No problem, I'v been debating with Eric M too when I didn't agree with him either. However I'm not sure I would even have a difference of opinion with Zeldman currently. As I already said the article by him you refer to was written 3 years ago, at which time CSS support in browsers where appalingly bad relative today.
Eg Minor issues in IE 3 with % units today weighs VERY lightly on the scale vs IE/Win 5 & 6 being compeatly broken with fontscaling if you use pixels.
We are talking about something that might affect 0.1% of your visitors vs something that can affect 70%+ of your visitors.
Finally, fixed-size by pixel is very adequately supported by any recent versions of IE.
Actually, PX is broken BEYOND REPAIR in any recent versions of IE.
The fact that you are not even aware of this is a bit worrisome if you actually design webpages...
Stefan
03-03-2003, 04:14 AM
Originally posted by prairiegirl
I've been looking at Mr. Meyer's books and he seems to indicate that px is a very imprecise way to set text size. I've always used px. He uses em. I've never used em. I'm confused.
em (or ex) is pretty much the same thing as using % when it comes to fonts
1 em = 100%
1.5 em = 150%
etc
The benefit of em & ex vs % is in the area of specifying eg height and width with em or ex, making eg a box scale when you increase decreas fontsize.
For the actual fontsizes % & em is (almost) exactly the same (there are some browserbug as well as inheritance differences).
Anyway, I'm sort of interested why anyone would want to be sure a font stayed a certain size. Why wouldja?
Sure beats me. All I can see is cons and no pros when you compare it with a % based method :)
BillHely
03-03-2003, 07:12 PM
Originally posted by prairiegirl
this is probably a big mistake, don't want to get in the middle of a boxing match, but I've been looking at Mr. Meyer's books and he seems to indicate that px is a very imprecise way to set text size. I've always used px. He uses em. I've never used em. I'm confused.
No mistake PG :D This thread is just losing sight of its genesis. The initial question was: "Is there a way to block somebody from seeing enlarged text as set from their control panel on a web page? Specifically a code that would maintain the text size integrity regardless of their control panel settings? "
That question has now been adequately answered. I'm sure BlueMojave now has enough info to look up the various syntax options on his/her own. Whatever units s/he decides on s/he is going to discover both upsides and downsides. What s/he doesn't need obfuscating the issue is downsides that are not strictly accurate. Declaring what is or is not acceptable is not relevant to the question because, as I have already pointed out, there are no absolutes.
But back to px & em. I doubt very much that Meyers ever contended that use of px was an ”imprecise” way to set text size. He mostly does favour em for various reasons, but not because px is “imprecise”. There are too many variables and no absolutes – so in that context everything is “imprecise”. Meyer has stated his opposition to px as “because they can't be resized by the sight-impaired who use Internet Explorer, and will be a different real size on a display with a different resolution and/or size”. Fair enough. But it’s not sufficient reason to categorically state “Thou shalt not ever do this”. I don’t believe Meyer or Zeldman or any other real expert would ever do that.
Anyway, I'm sort of interested why anyone would want to be sure a font stayed a certain size. Why wouldja? Other than for beauty, which is sort of moot if a user can't read the text...
Well ... that's hardly the point is it? It is up to the individual developer to decide how s/he wants the page to appear. Despite bleats to the contrary from one-track minds, a designer "locking" a view is not heresy! Smart designers will carefully consider the pros and cons of doing so. Smart designers will also have a better idea of the likely makeup of their intended target audience than will some casual observer. A designer of an intranet site may well know every visitor and all of their equipment by personal contact.
Yes, as a general rule, developers bend over backwards to accommodate as many site visitors as possible. But is there an enterprising developer anywhere who hasn’t thrown that principle out the window occasionally in favour of giving the BEST experience to as many as possible, instead of a compromised experience to everyone?
You mentioned “Other than for beauty” --- by which I assume you are referring to “attractive” layout. Don’t knock “beauty” in that context! On a selling page every aspect has a bearing on success or failure; words, colors, images and positioning.
I suppose my position in a nutshell is that, as a developer, there is no such thing as something you should NEVER do --- so long as you appreciate both the upsides and the downsides and apply commonsense when you do decide to depart from the beaten track.
I often make px work quite well for my purposes and I can demonstrate that very easily. Take a look at the sales page at: http://www.zedatron.com/ezines/egrams/030227.htm and keep in mind the following:
I have put the CSS in-line and made it very verbose for easy reading, so no claims are made for “beautiful” or “optimised” code. It has a specific job to do for one particular page that has a short life cycle – that’s it! In fact such pages are designed to be sent out eMail to most of our subscriber list – the web page only exists for the relatively few people who prefer Text eMail.
The points I want to make are:
1. The whole page is locked with pixel sizing.
2. For the great majority of my subscriber list the layout appears EXACTLY as I want it – and nothing the viewer does can harm that to any significant degree. Even really big text zooms (tested in Mozilla 1.0 and Netscape 7.0) retain relative layout and are quite viewable if that’s the sort of sizes you need.
3. It remains very readable in all scenarios tested (see point 4 below) and on different monitors set at 640x480, 800x600 and 1024x768 – even for people who’s eyesight is no longer all that great (me).
4. Courtesy of Net Mechanic’s Browser Photo facility, the template has been tested in 16 different browser/resolution combinations, including different versions of IE, Netscape, AOL, Opera and Web TV. It remains eminently viewable in all except the latter, which at this point I have given no consideration to. And even the WebTV snapshot is close to perfect with the exception of a couple of parameters that the medium doesn’t recognize. We also test on Mozilla 1.0 and Netscape 7.0 in-house because Browser Photo doesn’t yet support them.
5. In cases where a browser doesn’t support a CSS feature, the view degrades gracefully. For example, where “first-line” and “first-letter” are supported the effect is really good; when not supported there simply is no effect --- loses a little in impact but no loss of readability.
6. I accept that I cannot possibly please all of the people all of the time – so I don’t waste time trying.
7. A web page that doesn’t either make money or provide sough-after information is utterly worthless. Far too many ”designers” and ”developers” don’t appreciate this. Designers/developers without at the very least a smidgin of business sense are not worth employing – either as employees or contractors.
Much of the above illustrates how completely wrong it is to assert that PX is broken in recent versions of IE. We use IE 5.5 and 6.0 in house to preview while developing, then take the pages to “Browser Photo” for fine tuning. PX does NOT break in IE 5.5 and 6.0.
Happy trails, PG. (trails ... prairie girl … get it? … Heh heh heh … Ahem!)
Stefan
03-04-2003, 02:49 AM
Originally posted by BillHely
Much of the above illustrates how completely wrong it is to assert that PX is broken in recent versions of IE. We use IE 5.5 and 6.0 in house to preview while developing, then take the pages to “Browser Photo” for fine tuning. PX does NOT break in IE 5.5 and 6.0.
No px is not broken if you are working with a flawed designmodel of "what I can comfortably read on my computer everybody else can also read comfortably on theirs".
Where the model fails is in what happens when the visitor have worse eyesight then your defined individual and/or is viewing the page on another hardware setup where foontsize is eg much smaller (for an extreemcase think eg of 15" LCD at 1600x1200 res).
And yes, choosing px instead of % (or em/ex) is always an option, but in most cases it's also a very bad choise (mostly due to the IE/Win bug that DOES break PX if you happen to not fit the "average user" mold).
Of cource everybody is allowed to choose for them selves what they want to use, even if it's a BAD choise.
However stating that you SHOULD use pixel and implying that there is NO viable options is ludicrous.
% will work just as well or better then px in next to all scenarios there is.