Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
Thread: % vs. px for tags and objects
12-18-2010, 07:35 PM #1
- Join Date
- Jul 2009
- Iowa City, IA
- Thanked 5 Times in 5 Posts
% vs. px for tags and objects
every webpage that I look at seems to position html tags by using px's. length, width, and others all use this measurement.
my question is: how does this sort of design perform if viewed by computers of extreme different monitor sizes? for instance, I have a desktop that uses a 40" TV for a monitor, and a small netbook that has a screen probably 8" in size. But these websites that I can go to, which is anything really, all look the same and the objects on the page are always proportionally sized. Why is that?
You would think that measuring tags and objects in px's would get you a horizonal and vertical scrollbar on the netbook at the very least, wouldn't it?
Wouldn't it make more sense to position and/or measure tags using %? That way, it's always proportionate on the screen, regardless of the size.
Or does the 'position' attribute in CSS have something to do with it as well?
thanks so much!
12-18-2010, 11:04 PM #2
- Join Date
- Jan 2006
- Halle (Saale), Germany
- Thanked 1,008 Times in 981 Posts
It may be that pixels are displayed in different size on the TV monitor and on the netbook. E. g. if both devices have the same resolution (let’s say 1280×800 px which is 16:10 format) the page is looking much larger on the TV monitor but relatively the dimensions are the same. And pixel density also has an effect: while typical pixel density is either 72 or 96 pixels per inch (PPI) on regular computer screens, Apple’s iPhone, for example, squishes 326 pixels into one inch to be able to display “the whole internet” on the screen.
You can also use percent units. But that’s not as pixel precise and therefore not an option for most designers as they are usually very picky and design websites on their fixed size Photoshop canvas with many graphics and details that don’t scale very well.