开发者

C# Toolstrip Causes Supporting Form to Grow

开发者 https://www.devze.com 2023-03-26 00:28 出处:网络
I\'ve rewritten a toolbar that sits at the top of the user\'s screen. It works, but for some reason, though the app consists of just a form with a Fill-Docked ToolStrip, I cannot get it to stay at the

I've rewritten a toolbar that sits at the top of the user's screen. It works, but for some reason, though the app consists of just a form with a Fill-Docked ToolStrip, I cannot get it to stay at the size I specify. It's supposed to be the size of the Windows titlebar, as designed in Visual Studio, but as soon as I run it, it's grown in height by five or six pixels. Everything is set rigidly, the Form and ToolStri开发者_高级运维p are set to AutoSize=FALSE and I've specified the size in pixels the form should be. I cannot work out what is resizing the form at runtime; the ToolStrip is Docked on Fill mode so it should not cause the form to grow. It all looks perfect in the GUI builder, and I copied most of the configuration from the old VB.Net toolbar it will replace. Can anyone help?


Just a wild guess, but have you tried changing the AutoScaleMode property of the Form to something other than Font?


Haven't found an answer but I'll make sure this is closed. I turned the form transparent and it accomplished what I needed. Still unsure why the form expanded when run.

0

精彩评论

暂无评论...
验证码 换一张
取 消