Click to See Complete Forum and Search --> : c# gui scaling


poymode
August 24th, 2009, 10:21 AM
Hi,

I'm new to C# and I am currently making some sales tracking system. I have a big problem with its user interface.

You see, I have this Form and I put controls in it, specifically a TabControl.
My Form's size is at 1024x768. My TabControl's size is near the Form's width but leaving margins on both sides. Its height doesn't matter at the moment. Now, when I run my program it shows up a 1024x768 user interface, looking clean and good. When I maximize it, the User interface maximizes but the TabControl remains the same thus making a bigger margin on the right side.

I have read about scaling and but It isn't clear to me.

Please help. =)

BigEd781
August 24th, 2009, 11:54 AM
Use the Dock and Anchor properties. If you want the tab control to resize horizontally and from the bottom down, set the anchor to left, right, bottom.

rliq
August 24th, 2009, 07:02 PM
The other alternative is... Design your App for a certain size and remove the Maximise button. Eg: Windows Calculator.

BigEd781
August 24th, 2009, 07:07 PM
The other alternative is... Design your App for a certain size and remove the Maximise button. Eg: Windows Calculator.

That is a very lazy solution...

If it makes sense to resize the window, users should be able to.

rliq
August 24th, 2009, 08:47 PM
I agree, but it is not always applicable to all applications.

BigEd781
August 25th, 2009, 02:34 AM
That's true. Many of the manufacturing utilities that I write do not have sizable dialogs.

poymode
August 25th, 2009, 05:30 AM
Cheers to BigEd781 and everyone.

Anchoring is pretty flexible. =)