Feb 11, 2019 04:46 PM
(This post was last modified: Feb 11, 2019 04:47 PM by Anon Scripter.)
Hi. When i first started coding, i had trouble with make an auto-resizer for the forums. But now, since i have 6 years of experience, it was hella easy to make, so im releasing it! :)
(Dont forget to vouch 🤝 )
The good stuff:
This goes under SizeChanged:
Declare this in global form:
How to use:
Put this in Form_Load:
Enjoy! 👍 - Anon Scripter
(Dont forget to vouch 🤝 )
The good stuff:
This goes under SizeChanged:
Code
int nextH = (this.Height - current.Height);
int nextW = (this.Width - current.Width);
foreach(Control c in controls.Keys)
{
if (controls[c]) // If you want the height to be resized also (Very nifty)
{
c.Height += nextH;
}
c.Width += nextW;
}
current = this.Size;
this.Text = string.Format("YourForm ({0}, {1})", this.Width, this.Height); //display the width and height (Not needed, just nifty for working on minimumsize)Code
Size current = new Size();
Dictionary<Control, bool> controls = new Dictionary<Control, bool>();Put this in Form_Load:
Code
current = this.Size;
controls.Add(this.YourControlWithHeightResize, true);
controls.Add(this.YourControlNoHeightResize, false);

