allowing for size variations


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 12 of 12

Thread: allowing for size variations

  1. #1
    Taurus Guest

    allowing for size variations

    I made a CD of my program to test installation on another computer. The
    computer I installed it to has a different size monitor than the one where i
    created it. My labels were partially cut off and my graphics did not look
    good. I could make my graphics smaller I guess and my labels larger but then
    the labels would probably look too large on another person's computer.

    There must be some way to allow for this only I don't know how. Could
    someone tell me how you can make your program adjust to the size monitor it
    is being installed on?

    Rachel



  2. #2
    Patrick Marshall Guest

    Re: allowing for size variations


    Hi Rachel,

    Your forms are sized usually in "twips".
    Any monitor will show at least VGA (640
    x 480 pixels or 9600 x 7200 twips)

    From the VB help file:

    twip

    A screen-independent unit used to ensure that placement
    and proportion of screen elements in your screen application
    are the same on all display systems. A twip is a unit of
    screen measurement equal to 1/20 of a printer's point.
    There are approximately 1440 twips to a logical inch or
    567 twips to a logical centimeter (the length of a screen
    item measuring one inch or one centimeter when printed).

    Use the constants TwipsPerPixelX, and TwipsPerPixelY to
    convert horizontal and vertical pixels to twips.

    It is usual to size your forms to VGA so that they always
    fit the screen. Depending on your screen settings your
    form will either fill the screen (VGA) or will be smaller.
    The size of your MONITOR actually has nothing to do
    with the size of the form on the screen, it is strictly
    a matter of display area (e.g. 800 x 600, 1024 x 768 etc.).
    The fraction of screen width/height of your form will
    be constant for a given screen setting on any size
    monitor (e.g. your form will take up 3/4 of the screen
    width on any monitor set to 800 x 600, whether it
    is a 13" monitor or 25").

    Use small fonts when designing and choose font sizes
    which fit your controls.

    You can resize your form to fill the screen if you
    like (me.windowstate = vbmaximized).

    You can resize controls on your form if you like on
    the form resize, but you should limit this to controls
    such as grids or richText controls which are natural
    to have large viewing/editing areas. Controls such
    as command buttons are usually a fixed size.

    If you give a rough description of the controls
    on your form, I could show you an example of
    form resizing (it varies with control placement,
    so it's not easy to describe without specifics).

    <Patrick>

    "Taurus" <taurus@shentel.net> wrote:
    >I made a CD of my program to test installation on another computer. The
    >computer I installed it to has a different size monitor than the one where

    i
    >created it. My labels were partially cut off and my graphics did not look
    >good. I could make my graphics smaller I guess and my labels larger but

    then
    >the labels would probably look too large on another person's computer.
    >
    >There must be some way to allow for this only I don't know how. Could
    >someone tell me how you can make your program adjust to the size monitor

    it
    >is being installed on?
    >
    >Rachel
    >
    >



  3. #3
    Patrick Marshall Guest

    Re: allowing for size variations


    Hi Rachel,

    Just noticed that there is an ongoing thread on
    the same topic, see:

    http://news.devx.com/cgi-bin/dnewswe...em=14440&utag=

    <Patrick>

  4. #4
    Taurus Guest

    Re: allowing for size variations

    Thanks a lot Patrick. That article gave me a lot of info.

    RAchel
    <Patrick Marshall> wrote in message news:3959330c$1@news.devx.com...
    >
    > Hi Rachel,
    >
    > Just noticed that there is an ongoing thread on
    > the same topic, see:
    >
    >

    http://news.devx.com/cgi-bin/dnewswe....getting.start
    ed&item=14440&utag=
    >
    > <Patrick>




  5. #5
    Kathleen Dollard-Joeris Guest

    Re: allowing for size variations

    Taurus,

    If you don't get an answer you are happy with, let's discuss it further. I
    disagree with resizing things to fill the user's screen to the same
    proportion as the programmers. I would not allow any such program on my own
    computer.

    Users are different. They have different vision and select how they run
    their computers for their own convenience. It is a basic tenet of Windows
    that color and font size is in the users control.

    That does make us programmers work harder. But a lot of folks here have been
    doing it for a long time. The most important point is that if you design for
    the lowest resolution you will support (either 480x600 or 600x800). In many
    cases, no resizing work is then needed. Your program simply takes up less of
    the screen if your user has a higher resolution.

    --
    Kathleen
    (MS-MVP)
    Reply in the newsgroup so everyone can benefit
    --

    Taurus <taurus@shentel.net> wrote in message news:39595441@news.devx.com...
    > Thanks a lot Patrick. That article gave me a lot of info.
    >
    > RAchel
    > <Patrick Marshall> wrote in message news:3959330c$1@news.devx.com...
    > >
    > > Hi Rachel,
    > >
    > > Just noticed that there is an ongoing thread on
    > > the same topic, see:
    > >
    > >

    >

    http://news.devx.com/cgi-bin/dnewswe....getting.start
    > ed&item=14440&utag=
    > >
    > > <Patrick>

    >
    >




  6. #6
    Rick Rothstein Guest

    Re: allowing for size variations

    Actually designing for 640x480 also adequately supports 1024x768 resolutions
    too. The odds are great that if they are using that resolution, it is on a
    "large" monitor and the extra screen area tend to compensate for the
    "smallness" of your form at that resolution.

    Rick



    "Kathleen Dollard-Joeris" <kjoeris@noemailplease.com> wrote in message
    news:3959d85d$1@news.devx.com...
    > Taurus,
    >
    > If you don't get an answer you are happy with, let's discuss it further. I
    > disagree with resizing things to fill the user's screen to the same
    > proportion as the programmers. I would not allow any such program on my

    own
    > computer.
    >
    > Users are different. They have different vision and select how they run
    > their computers for their own convenience. It is a basic tenet of Windows
    > that color and font size is in the users control.
    >
    > That does make us programmers work harder. But a lot of folks here have

    been
    > doing it for a long time. The most important point is that if you design

    for
    > the lowest resolution you will support (either 480x600 or 600x800). In

    many
    > cases, no resizing work is then needed. Your program simply takes up less

    of
    > the screen if your user has a higher resolution.
    >
    > --
    > Kathleen
    > (MS-MVP)
    > Reply in the newsgroup so everyone can benefit
    > --
    >
    > Taurus <taurus@shentel.net> wrote in message

    news:39595441@news.devx.com...
    > > Thanks a lot Patrick. That article gave me a lot of info.
    > >
    > > RAchel
    > > <Patrick Marshall> wrote in message news:3959330c$1@news.devx.com...
    > > >
    > > > Hi Rachel,
    > > >
    > > > Just noticed that there is an ongoing thread on
    > > > the same topic, see:
    > > >
    > > >

    > >

    >

    http://news.devx.com/cgi-bin/dnewswe....getting.start
    > > ed&item=14440&utag=
    > > >
    > > > <Patrick>

    > >
    > >

    >
    >




  7. #7
    Taurus Guest

    Re: allowing for size variations

    This may be a stupid question but if my computer is set at 600 x 800, how
    would i design the program at the lower resolution? Would i change my
    computer settings just for the design of my project, then change it back
    later? I wasn't sure if it would work properly if i changed my resolution.
    Rachel


    Kathleen Dollard-Joeris <kjoeris@noemailplease.com> wrote in message
    news:3959d85d$1@news.devx.com...
    > Taurus,
    >
    > If you don't get an answer you are happy with, let's discuss it further. I
    > disagree with resizing things to fill the user's screen to the same
    > proportion as the programmers. I would not allow any such program on my

    own
    > computer.
    >
    > Users are different. They have different vision and select how they run
    > their computers for their own convenience. It is a basic tenet of Windows
    > that color and font size is in the users control.
    >
    > That does make us programmers work harder. But a lot of folks here have

    been
    > doing it for a long time. The most important point is that if you design

    for
    > the lowest resolution you will support (either 480x600 or 600x800). In

    many
    > cases, no resizing work is then needed. Your program simply takes up less

    of
    > the screen if your user has a higher resolution.
    >
    > --
    > Kathleen
    > (MS-MVP)
    > Reply in the newsgroup so everyone can benefit
    > --
    >
    > Taurus <taurus@shentel.net> wrote in message

    news:39595441@news.devx.com...
    > > Thanks a lot Patrick. That article gave me a lot of info.
    > >
    > > RAchel
    > > <Patrick Marshall> wrote in message news:3959330c$1@news.devx.com...
    > > >
    > > > Hi Rachel,
    > > >
    > > > Just noticed that there is an ongoing thread on
    > > > the same topic, see:
    > > >
    > > >

    > >

    >

    http://news.devx.com/cgi-bin/dnewswe....getting.start
    > > ed&item=14440&utag=
    > > >
    > > > <Patrick>

    > >
    > >

    >
    >




  8. #8
    Patrick Marshall Guest

    Re: allowing for size variations


    Hi Rachel,

    You can keep your screen resolution at 800 x 600,
    just make sure your form is smaller than
    9600 x 7200 twips in width x height (remember
    to allow for toolbars and menu lines, etc.)

    For testing purposes, I would do a final pass
    with your screen settings to 640 x 480 just
    to be sure, but you don't have to work that
    way continuously. Note that VGA is also
    only 16 color, so your app may have some
    strange dithered colors.

    BTW, I totally agree with Kathleen and Rick,
    I personally never resize controls to take over
    screen space (without the user selecting maximize).
    If a user has a larger monitor it is usually so
    (s)he can keep more applications side by side
    rather than having a single dominant app. While
    there are controls which allow you to automatically
    expand your app to fill the screen, I see no real
    need for this.

    <Patrick>


    "Taurus" <taurus@shentel.net> wrote:
    >This may be a stupid question but if my computer is set at 600 x 800, how
    >would i design the program at the lower resolution? Would i change my
    >computer settings just for the design of my project, then change it back
    >later? I wasn't sure if it would work properly if i changed my resolution.
    >Rachel



  9. #9
    Kathleen Dollard-Joeris Guest

    Re: allowing for size variations

    Rick,

    I am not sure I understand what you trying to say.

    --
    Kathleen
    (MS-MVP)
    Reply in the newsgroup so everyone can benefit
    --
    Rick Rothstein <rick_newsgroup@email.com> wrote in message
    news:3959ee5b@news.devx.com...
    > Actually designing for 640x480 also adequately supports 1024x768

    resolutions
    > too. The odds are great that if they are using that resolution, it is on a
    > "large" monitor and the extra screen area tend to compensate for the
    > "smallness" of your form at that resolution.
    >
    > Rick





  10. #10
    Kathleen Dollard-Joeris Guest

    Re: allowing for size variations

    Patrick,

    > While
    > there are controls which allow you to automatically
    > expand your app to fill the screen, I see no real
    > need for this.


    Except for one. Apps that are designed to be run on an overhead. And maybe a
    kiosk.

    I wonder if we should throw around resizing ideas again where the _use_
    resizes the form.

    --
    Kathleen
    (MS-MVP)
    Reply in the newsgroup so everyone can benefit
    --



  11. #11
    Rick Rothstein Guest

    Re: allowing for size variations

    Let's say you have a 15-inch monitor and it is set to 640x480. You design a
    program to nearly fill that screen. Now you decide that you would like to
    use 1024x768 resolution so you reset your display properties. When you next
    run your program, you find the text on your 640x480 project is hard to read
    because it is now much smaller on the screen at this new resolution (it no
    longer fills the whole display). Now, throw away that 15-inch monitor and
    replace it with a larger one, say 19-inches. Now when you view your program
    on this larger monitor, the *physical* size of your form is bigger than on
    the 15-inch monitor (due to the "larger" pixels on the larger monitor for
    the same fixed display setting). This larger displayed form is easier to
    read (you don't have to squint anymore); sort of like looking through a
    magnifying glass. The point I was trying to make is that people who use
    higher resolutions tend to be doing so on larger monitors; hence the above
    effect comes into play.

    Rick


    "Kathleen Dollard-Joeris" <kjoeris@noemailplease.com> wrote in message
    news:395b4c3f@news.devx.com...
    > Rick,
    >
    > I am not sure I understand what you trying to say.
    >
    > --
    > Kathleen
    > (MS-MVP)
    > Reply in the newsgroup so everyone can benefit
    > --
    > Rick Rothstein <rick_newsgroup@email.com> wrote in message
    > news:3959ee5b@news.devx.com...
    > > Actually designing for 640x480 also adequately supports 1024x768

    > resolutions
    > > too. The odds are great that if they are using that resolution, it is on

    a
    > > "large" monitor and the extra screen area tend to compensate for the
    > > "smallness" of your form at that resolution.
    > >
    > > Rick

    >
    >
    >




  12. #12
    Patrick Marshall Guest

    Re: allowing for size variations


    Hi Kathleen,

    You are right, I've written apps for a video kiosk
    where the keyboard was removed and the user
    would point and click on icons on a maximized
    screen with no means of exiting. I should have
    been more specific and said that I see no real
    need for an app that takes over the desktop in
    a "general" user scenario. I've never written
    an app to run on an overhead...I feel deprived.

    On the flip side, I've also written apps where
    the _users_ demanded so many features
    on a single form that I mandated an 800 x 600
    minimum size desktop. Since the app was
    central to the group's job function, they went
    along with this pretty readily. Obviously, in a
    controlled business environment, you can
    have some control over your users (at least
    in desktop size ;-)

    I'd be happy to throw around any ideas regarding
    user form resizing. I've got numerous examples
    (virtually all my non-fixed-sized forms have some
    resizing features), though they do tend to be
    rather specific to the form type and application
    to defy formulaic generalization.

    <Patrick>


    "Kathleen Dollard-Joeris" <kjoeris@noemailplease.com> wrote:
    >Patrick,
    >
    >> While
    >> there are controls which allow you to automatically
    >> expand your app to fill the screen, I see no real
    >> need for this.

    >
    >Except for one. Apps that are designed to be run on an overhead. And maybe

    a
    >kiosk.
    >
    >I wonder if we should throw around resizing ideas again where the _use_
    >resizes the form.
    >
    >--
    >Kathleen
    >(MS-MVP)
    >Reply in the newsgroup so everyone can benefit
    >--
    >
    >



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center