High-DPI-aware and form resizing

Started by David Kenny, March 01, 2012, 10:00:50 PM

Previous topic - Next topic

David Kenny

I've seen Jose mention the need for it, but I haven't heard you address it yet Paul.  I'm guessing that the current resizing routines are going to need to be reworked (and you may have already done so).

Do you have plans to give FF programmers easy access to the High-DPI info that the FF engine will gather as it interrogates the system it is running on?  If one is doing his own resizing routines, for instance, it wouldn't make sense to duplicate the effort of pulling that info from the OS twice.

Thanks, 
David

Paul Squires

You will be able to easily get any DPI info you need because all you need to do is obtain a reference to any of the pWindow objects that are created (Jose has a couple of functions that return the pWindow). This gives you access to every method in Jose's cWindow class. You can then inquire about the DPI setting and use methods to ScaleX or ScaleY values as you would need.

FireFly and cWindow will take care of all of mundane hard stuff. If you need to implement your own resizing routines then getting high DPI info and manipulating it is very easy. Trust me. Jose has made this extremely easy.   :)
Paul Squires
PlanetSquires Software

José Roca

The function CWindow_GetObjectFromWindowHandle allows to get a reference to the CWindow class passing the handle of the form or the handle of any of his child controls.