mdi

How to get minimize/restore/close rectangle?

梦想与她 提交于 2020-01-07 03:03:39
问题 I want to draw some text in the end of menu bar like this But when the child window is maximized in the MDI project it looks like this I need to fix this output. I want to check if the active child is maximized and if it is I want to get minimize/restore/close rectangle to get them total width. How can I get active child window and how can I get it's rectangle of buttons? 回答1: // in yourMainWindow.cpp ... auto child = mdiArea->addSubWindow(yourWidget); connect(child, &QMdiSubWindow:

Running each child form as a separate thread in a MDI container

谁都会走 提交于 2020-01-04 17:53:08
问题 Is it possible to run each child form of a MDI form on a separate thread? If so, can you please give some codes and example how to setup this? Thanks! 回答1: I can't tell from the question wether you are aware of the exotic nature of the solution you are proposing. I apologize if this answer completely misses the mark. I assume that you want responsiveness in your application. That you don't want other forms to "hang" while one form is doing work. However, having a different GUI thread per form

Delphi: Maximized Child Form in MDI Application

泪湿孤枕 提交于 2020-01-04 05:20:13
问题 How can I maximize a child window that fits only the client area but not an entire parent window? I don't want that the child window disappears under a main menu or other controls of the parent window. I have this code procedure WMSIZE(var Msg: TMessage); message WM_SIZE; procedure TForm2.WMSIZE(var Msg: TMessage); begin inherited; if Msg.WParam = SIZE_MAXIMIZED then begin ShowWindow(Handle, SW_RESTORE); Left := 0; Top := 0; Width := Form1.ClientWidth - 4; // The BORDER Height := Form1

Looking for a Visual Studio toolbox style navigation for desktop applications

↘锁芯ラ 提交于 2020-01-01 19:51:11
问题 I'm working on a project that uses an MDI application with a navigation panel on the side. Currently it is a ListView. However, I would like to redesign it to be similar to the toolbox in visual studio 2008. If this is something that would require overriding the default paint method, it would also help if you could provide some good references on how to work with the paint method as I do not currently have any experience using it. Thanks in advance. 回答1: You want to be using a ToolBox control

Why aren't my MDI child forms showing a shadow?

做~自己de王妃 提交于 2019-12-30 11:03:39
问题 In my application when I make a form as a child form of my main MDI parent form, the child form stops showing Windows 7 default shadow effect behind forms. How do I get child forms shadow to show? Form obj = Application.OpenForms["My_form"]; if (obj != null) { obj.Focus(); } else { My_form c = new My_form(); c.MdiParent = this; c.Show(); } 回答1: This is normal, entirely by design. MDI child windows are not top-level windows, but rather a special type of child window that is designed to be

Move one form to another winforms - C#

主宰稳场 提交于 2019-12-30 06:49:31
问题 I have 2 winforms Form 1 and Form 2. I have button1 in form1, when i click on button1 from form1 i display form2. Form2 ins = new Form2(); ins.MdiParent = this.MdiParent; this.Hide(); ins.ShowDialog(); I hide the form1 to display form2 when button1 is clicked. This creates a flicking effect and i need to remove this flicking. How do i open/redirect to another form (i am supposed to show only one form at a time and am not supposed to show any top menu like (if i use MDIParent form). Just one

How to avoid visual artifacts when hosting WPF user controls within a WinForms MDI app?

荒凉一梦 提交于 2019-12-30 01:27:05
问题 When hosting WPF user controls within a WinForms MDI app there is a drawing issue when you have multiple forms that overlap each other that causes very distinct visual artifacts. These artifacts are mostly visible after dragging one child form over another one that also hosts WPF content or by allowing the edges of the child form to be clipped by the main MDI parent when dragging it around. After the drag and drop of the child form is completed the artifacts stay around generally but I've

How Do I Insert Items From An Edit Control In A Double Linked List

喜你入骨 提交于 2019-12-25 06:39:03
问题 I need to insert some data from an edit control in a double linked list. How can i make this? The datatype of the edit control is CString and all are named like m_... for example m_anrede and so on... My struct looks like this: typedef struct adr{ char anrede [5]; char vorname [51]; char nachname [51]; char plz [8]; char ort [60]; char strasse [51]; char land [24]; char festnetz [14]; char mobil [14]; char mail [101]; char geburtsdatum [11]; char kategorie [31]; char startnummer [5]; char

C++ MFC MDI change child window variables on creation

喜夏-厌秋 提交于 2019-12-24 20:28:38
问题 I have an MDI application where a dialog is called when the OnFileNew() function (processed by the theApp object) is called. This dialog allows the user to set values to some variables that then need to be passed on to the CChildFrame object that is created when the ->CreateNewChild() function is called. How do I pass these variables onto the CChildFrame object that is created by the ->CreateNewChild() function? EDIT: In response to an answer I got, here are the results for using ->Create()

mdiparent click

我与影子孤独终老i 提交于 2019-12-24 20:17:58
问题 The click ,double click on mdi parent of the .net MDI form does not work is it a bug? 回答1: Well, that's not much to go on without knowing exactly what you click on. The gray background of the parent is a separate control, an MdiClient, not the form. You'd register a click event for it with code like this: public Form1() { InitializeComponent(); foreach (var ctl in this.Controls) { if (ctl is MdiClient) { (ctl as MdiClient).Click += Client_Click; break; } } } private void Client_Click(object