Board index » delphi » What makes scrollbars appear?

What makes scrollbars appear?

Probably an easy one but I don't understand.

For an application I amd developing and runnning on my computer
I have a form which does not show scrollbars on the right and
bottom edges of the form. But, when I run it on different
computers, scrollbars may appear on some computers (1024X768)
even if the form itself is smaller than 640X480. Why? I use D4.

Jacques

 

Re:What makes scrollbars appear?


It is possible that others are using large fonts which might make some
labels or text expand. Thus the form would need scrollbars. If you don't
want the form to scroll, set the AutoScroll property to false

--

Woody
Atheism is a non-prophet organization.

Re:What makes scrollbars appear?


Quote
> For an application I amd developing and runnning on my computer
> I have a form which does not show scrollbars on the right and
> bottom edges of the form. But, when I run it on different
> computers, scrollbars may appear on some computers (1024X768)
> even if the form itself is smaller than 640X480. Why? I use D4.

This is a small fonts vs. large fonts issue. A form will sprout
scrollbars if its AutoScroll property is True (the default) and at
least one control on it is at least partially outside the forms client
area, even if only by one pixel. This can happen if you display a form
designed in a small font video mode on a PC running large font
videomode. Controls that have AutoSize = true (the default for Tedits)
will grow higher on large font modes since the same font point size
translates to a larger font height in pixels. You will not have these
kind of problem if you design in large font mode and set the forms
Scaled property to false.

Peter Below (TeamB)  100113.1...@compuserve.com)
No e-mail responses, please, unless explicitly requested!

Re:What makes scrollbars appear?


Quote
Peter Below (TeamB) wrote:
> You will not have these
> kind of problem if you design in large font mode and set the forms
> Scaled property to false.

Or, set Scaled to false and change the font to a scalable font. The
default font only comes in certain sizes which prevents it from staying
the same size (in pixels) if the Display Font Size is different on your
user's machine than on yours (i.e., Large Fonts on theirs while Small
Fonts on yours).

--
David Marcus

Other Threads