Re: Dialog size in pixel

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



Note that those of us who are visually handicapped (read: anyone over the age of 40) find
it nearly impossible to live in a world where the font sizes are not under the end user's
control. In CE, in particular, the use of the FlySpeck 3 font is the way most programmers
deal with the lack of screen real estate.
joe

On Fri, 20 Jun 2008 09:34:41 -0700, Henryk Birecki <soaringpilot@xxxxxxxxxxxxx> wrote:

I also have many dialogs in a WinCE application. I think you "hit the
nail on the head with 'If user change de display settings "DPI" ' this
is exactly why dialogs are specified in font units rather than pixels.
If a user changes DPI, dialog size stays the same. You should scale
your bitmap according to the DPI settings. Do you expect DPI change
during program operation, while one of the dialogs is displayed?

As to relationship between pixels and font units, I just experimented
a bit to get it right for the font size I am using.

Cheers,
Henryk Birecki

Erakis <Erakis@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote:

Hi, I'm programming an application for Windows CE.

I have to draw/set a bitmap as background of my dialog.

This is like a skinned application. For that, I need to set the dialog size
to 340x234 "pixels" and not"Base unit" like resource do.

Also I will have to add others components on this dialog like
(Button,TextBox, Label, ListBox, etc...) at a specified position in pixels
sothat they fit on the background image.

If user change de display settings "DPI", the dialog size will changeand I
don't want that ! Because the position/dimension of bitmaps onmy dialog will
no longer fit.

Is someone have any clues/suggestion to help me with that problem ?

Regards,
Joseph M. Newcomer [MVP]
email: newcomer@xxxxxxxxxxxx
Web: http://www.flounder.com
MVP Tips: http://www.flounder.com/mvp_tips.htm
.



Relevant Pages

  • Re: Large Fonts
    ... The effects vary from one machine to the next of course, but generally in Windows all True Type fonts (including the Verdana 8 point he is using) are required to be "whole pixel" values, so that on most machines if you ask for 8 point Verdana you will actually get 8.25 points. ... Similar considerations also come into effect when you switch between "Windows small fonts setting" (96 dpi) and "Windows large fonts setting". ... So in the author's specific case he would quite probably see the effect he described (the size of the "container" or button or whatever expanding by a larger percentage than the size of the font which it contains). ... In my case the height of a Command Button increased by 25 per cent, as expected, when changing from 96 dpi to 120 dpi, but the height of the font increased by only 12 per cent, but at 9 points there was virtually no difference at all between the two, and at 10 point Verdana I had the opposite effect, where the height of the Command Button increased by 25 per cent but the height of the font increased by 33 per cent. ...
    (microsoft.public.vb.general.discussion)
  • Re: 120 DPI & HTML text woes
    ... setting of 120 DPI, everything else is great, but now standard ... and look in the various components where text size and font are ... As far as web browsers are concerned, ...
    (comp.infosystems.www.authoring.html)
  • Re: adjusting fonts to computers dpi settings
    ... After watching my app under 120 dpi I came to conclusion that if I summarily ... change the font to MS Serif and decrease font size to 6 ... How can I do that without accessing each control separetely? ... as Control Panel and the programs within it) or Windows ...
    (microsoft.public.vb.general.discussion)
  • Re: Font in OE
    ... Click the font size you want to use.]] ... [[Lists the available DPI sizes for the selected monitor. ... Increasing the DPI increases the size of everything on your screen. ... [[The Accessibility Wizard guides you through the process of customizing ...
    (microsoft.public.windowsxp.customize)
  • Re: Dialog size in pixel
    ... I also have many dialogs in a WinCE application. ... If a user changes DPI, ... If user change de display settings "DPI", the dialog size will changeand I ...
    (microsoft.public.vc.mfc)