简体   繁体   English

C#中的MDI子窗体问题

[英]MDI child form problem in C#

When I maximize 1 MDI child form, all MDI child forms would be maximized too. 当我最大化1个MDI子表单时,所有MDI子表单也将最大化。 Is it possible to have 1 form maximized and another one not? 是否可以使1个表单最大化而另一个表单不是?

Thanks in advance. 提前致谢。

最大化的MDI儿童形式应该占据整个儿童区域,因此其他儿童的状态实际上并不重要,因为它们不可见。

If you want to see a maximized window with another smaller window in front of it, I think some kind of user interface with docking and floating panels would be a better choice. 如果你想看到一个最大化的窗口,前面有另一个较小的窗口,我认为某种用户界面有对接和浮动面板将是更好的选择。 Something like the way it works in Visual Studio. 类似于它在Visual Studio中的工作方式。

Creating custom MDI/Non-MDI functionality is very time consuming and frustrating work, and the end result can be confusing to users who are used to standard MDI. 创建自定义MDI /非MDI功能非常耗时且令人沮丧,最终结果可能会让习惯于标准MDI的用户感到困惑。

Not possible. 不可能。 Only thing you can do is to set the window in front non MDI and taskbar = no 您唯一能做的就是将窗口设置在非MDI前面,任务栏=否

是的,您可以这样做 - 使用API​​调用SetParent而不是设置.MDIParent。

The Maximized Form will need to be an MDI Child called with Child1.Show() . 最大化的表格将需要是一个使用Child1.Show()调用的MDI子项。

The non-Maximized Form will need to NOT be an MDI Child called with Form1.Show(this) or Form1.ShowDialog(this) . 非最大化表单不需要是使用Form1.Show(this)Form1.ShowDialog(this)调用的MDI子项。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM