[Webkit-unassigned] [Bug 53707] Viewport Warning/Error Messages Are Now Inaccurate

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Mar 3 14:27:29 PST 2011


https://bugs.webkit.org/show_bug.cgi?id=53707





--- Comment #36 from Kenneth Rohde Christiansen <kenneth at webkit.org>  2011-03-03 14:27:29 PST ---
(In reply to comment #33)
> > In the above case it is not necessary as you are using fixed values.
> > But in the case of using device-width is it.
> 
> If the user is already using the "device-width" keyword, we don't need
> to provide a tip that they are using the keyword. The code change I'm
> adding would never be reached in that case, only when there is a
> numeric constant.

Good point, and I guess we could do with that, but when I think about it

<meta name="viewport" content="width=320, target-densitydpi=160">

should yield a warning to use device-width, but so should

<meta name="viewport" content="width=480, target-densitydpi=240">
and
<meta name="viewport" content="width=480, target-densitydpi=device-dpi">

for a device with dpi 240 and device-width 480.

It all comes down to how useful these warnings are. You could say that if someone knows how to use target-densitydpi, he surely also knows how to use device-width. It could even be that the user actually wanted 480 always and just wanted the scale to change to fit the 480 into the given view. I have seem many such cases.

With that in mind, we could even show the warning always when someone uses a real number value instead of the device-* defines.

> > <meta name="viewport" content="width=device-width, target-densitydpi=160">
> > 
> > on a 480 wide device substitutes device-width with 320, due to the higher dpi of 240, where as 
> >
> > <meta name="viewport" content="width=device-width, target-densitydpi=240">
> > 
> > substitutes device-width with 480.
> 
> Your descriptions sound backwards to the meta tags. Are they?

Sorry, what do you mean?

> I see what you're saying, but in that case my question above still applies.
> I'll rephrase it below with your examples (assuming they were backwards)
> with the description.
> 
> On a 480px wide device, are you suggesting that both of following should
> print a tip that the width constant could be device-width?
> 
>   <meta name="viewport" content="width=480, target-densitydpi=160">
>   <meta name="viewport" content="width=320, target-densitydpi=240">

Yes, if 160 and 240 were swapped: :-)

device-width with target-densitydpi=240 on a 480px wide device is == 480, hense

   <meta name="viewport" content="width=480, target-densitydpi=240">
   <meta name="viewport" content="width=320, target-densitydpi=160">

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list