2

I'm curious about something. If I set my Chrome Extension popup window width as such:

html,body{
    padding: 0;
    margin: 14px 12px;
    width: 600px;
    overflow-x: hidden;
}

It looks good on my screen, but if I hardcode the width to 600 pixels, what would happen if someone runs it on an operating system with higher DPI setting? Will it look smaller? And if so, how to overcome this?

PS. Unfortunately my screen setup doesn't allow to test it.

EDIT: I just thought of something. Can I use ems to define the size like this? width: 24em;

c00000fd
  • 20,994
  • 29
  • 177
  • 400

1 Answers1

1

No, chrome simply blurs to fit high DPI settings.

And there is no javascript or css capability in detecting DPI. Read this for more information:

How to access screen display’s DPI settings via javascript?

Community
  • 1
  • 1
Marc Guiselin
  • 3,442
  • 2
  • 25
  • 37
  • Wow. I didn't expect it from Google. I just had a chance to test it on the system with 150% DPI and indeed Chrome simply blurs its "default" layout. Even IE is doing it right. I'm sure Google will fix it pretty soon. Is there any news that they'd do it? – c00000fd Aug 29 '14 at 19:38
  • Can we "code ahead" in case they implement support for higher DPIs? – c00000fd Aug 29 '14 at 19:44
  • I dont know if they will fix it. they said that high DPI support will go away. Answering your second question: Not that i know of. – Marc Guiselin Sep 02 '14 at 13:34