Forum Moderators: open

Message Too Old, No Replies

Locking font size

         

hptschupp

4:04 am on Feb 26, 2006 (gmt 0)

10+ Year Member



Is there a html code to lock the font size to a set value so the user CANNOT force resize fonts on his browswer?

willybfriendly

4:19 am on Feb 26, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Why? It would make the site inaccessible to any number of people. Not a good idea.

To answer your question though, no, I am not aware of any such tag.

BTW, welcome to WebmasterWorld!

WBF

DrDoc

6:38 am on Feb 26, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



It cannot be done.

Browsers are specifically built to be able to override rogue attempts like that ;)

Wlauzon

8:27 pm on Feb 26, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Why would you want to?

If I go to your site and you have it set to a 12 px size, and I am running at high rez, the letters will be the size of a pinhead.

hptschupp

2:55 am on Feb 27, 2006 (gmt 0)

10+ Year Member



Well, thanks for the input so far. It's just a general question since I made some observations I couldn't fully explain so far.

Mi wife uses a computer with IE using increased fonts.

On most web pages fonts show up bigger than normal.

However, I run a Forum

<snip>

Interesting is, that when I watch the Forum on her
computer, the fonts don't change and display in it's original size=2px.

Does it have to do with the CSS which dictates the font size?

Or is it, when I define the font size="2px" it forces
the font size in IE to this size as opposed when defining the font size="2"?

[edited by: encyclo at 3:25 am (utc) on Feb. 27, 2006]
[edit reason] No links please: see TOS [webmasterworld.com] [/edit]

daosmith

6:30 am on Feb 27, 2006 (gmt 0)

10+ Year Member



Internet Explorer only allows user-controlled font resizing when the fonts sizes are specified in relative units (ems, "small") rather than absolute units (px, pt): this is really a reflection on the inadequacy of IE, however. Firefox/Mozilla and Opera, and I imagine most other browsers, allow users to resize the fonts regardless of what units are used.

tedster

6:43 am on Feb 27, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Do you mean 12px possibly? A 2px font would be minute and illegible on screen, because it takes 8 pixels just to draw all the letter parts of the lower case forms -- including ascenders and descenders. But 2px just gives you a maximum of two "dots" in height -- not enough room for the screen to draw much of anything.

The old style html attribute <font size=2> is a relatve size that is not related to pixels, but rather a position on a relative scale of 1 to 7.