Dpi Awareness in branch 2062

Having problems with building or using CEF's C/C++ APIs? This forum is here to help. Please do not post bug reports or feature requests here.

Dpi Awareness in branch 2062

Postby dam4rus » Wed Sep 03, 2014 5:11 am

Hi! I have a question regarding Chromium 37/Branch 2062. Since our application is DPI-Aware and we define our own dpi scaling options, we want to ignore the Windows' DPI setting. But, this Chromium version is DPI aware itself and sets a zoom multiplier, based on the Windows DPI setting, but our application also sets a zoom multiplier by our own dpi scaling option. So, can i somehow disable this automatic zoom multiplication in Chromium or i should just simply set our own multiplier based on the Windows' settings? I would like it better, if there is a switch for this behaviour.
dam4rus
Techie
 
Posts: 20
Joined: Thu Jul 25, 2013 4:01 am

Re: Dpi Awareness in branch 2062

Postby Czarek » Wed Sep 03, 2014 5:36 am

Try `--high-dpi-support=1 --force-device-scale-factor=1` command-line flags.
Maintainer of the CEF Python, PHP Desktop and CEF C API projects. My LinkedIn.
User avatar
Czarek
Virtuoso
 
Posts: 1927
Joined: Sun Nov 06, 2011 2:12 am

Re: Dpi Awareness in branch 2062

Postby dam4rus » Wed Sep 03, 2014 7:17 am

Czarek wrote:Try `--high-dpi-support=1 --force-device-scale-factor=1` command-line flags.


Thank for the tip! setting force-device-scale-factor to 1.0 in the browser app's OnBeforeCommandLineProcessing solved the problem.

Interesting thing i found: --high-dpi-support flag has been removed from Chromium's command line parameters. After taking a peek at it's code i found out, that it's stored in the registry under HKEY_CURRENT_USER\Software\Google\Chrome\Profile. If i set the high-dpi-support value to 0, Chromium didn't scaled on it's own, it applied to both CEF and Chrome. Maybe someone will find this useful in the future.
dam4rus
Techie
 
Posts: 20
Joined: Thu Jul 25, 2013 4:01 am


Return to Support Forum

Who is online

Users browsing this forum: No registered users and 105 guests