org.kde.koala

Class KMdiMainFrm

public class KMdiMainFrm extends DockMainWindow

\short Base class for all your special main frames. It contains the child frame area (QMainWindow's central widget) and a child view taskbar for switching the MDI views. Most methods are functions for later overriding. Basically, this class provides functionality for docking/undocking view windows and manages the taskbar. Usually a developer will only need to know about this class and \ref KMdiChildView. \par General usage Your program mainwidget should inherit KMdiMainFrm. Then usually you'll just need addWindow() and removeWindowFromMdi() to control the views.
		public class MyMainWindow implements KMdiMainFrm
		{ .... }
 
to define your main window class and
		MyMainWindow mainframe;
		qApp.setMainWidget(&mainframe);
		mainframe.addWindow(view1); // put it under MDI control
		mainframe.addWindow(view2);
 
when you wish to use your main window class. The above example also adds a few windows to the frame. KMdiMainFrm will provide the "Window" menu needed in common MDI applications. Just insert it in your main menu:
 		if ( !isFakingSDIApplication() )
 		{
 			menuBar().insertItem( i18n( "&Window" ), windowMenu() );
 		}
 
To synchronize the positions of the MDI control buttons inserted in your mainmenu:
 		void B_MainModuleWidget.initMenuBar()
 		{
 			setMenuForSDIModeSysButtons( menuBar() );
 		}
 		...
		void B_MainModuleWidget.resizeEvent ( QResizeEvent e )
		{
			KMdiMainFrm.resizeEvent( e );
			setSysButtonsAtMenuPosition();
		}
 
\par Dynamic mode switching Dynamic switching of the MDI mode can be done via the following functions: - switchToChildframeMode() - switchToToplevelMode() - switchToTabPageMode() - switchToIDEAlMode() The MDI mode can be gotten using mdiMode(). If you need to fake the look of an SDI application use fakeSDIApplication() to fake it and isFakingSDIApplication() to query whether or not an SDI interface is being faked. You can dynamically change the shape of the attached MDI views using setFrameDecorOfAttachedViews(). Additionally, here's a hint how to restore the mainframe's settings from config file:
    // restore MDI mode (toplevel, childframe, tabpage)
    int mdiMode = config.readIntEntry( "mainmodule session", "MDI mode", KMdi.ChildframeMode);
    switch (mdiMode) {
    case KMdi.ToplevelMode:
       {
          int childFrmModeHt = config.readIntEntry( "mainmodule session", "Childframe mode height", desktop().height() - 50);
          mainframe.resize( m_pMdiMainFrm.width(), childFrmModeHt);
          mainframe.switchToToplevelMode();
       }
       break;
    case KMdi.ChildframeMode:
       break;
    case KMdi.TabPageMode:
       {
          int childFrmModeHt = m_pCfgFileManager.readIntEntry( "mainmodule session", "Childframe mode height", desktop().height() - 50);
          mainframe.resize( m_pMdiMainFrm.width(), childFrmModeHt);
          mainframe.switchToTabPageMode();
       }
       break;
    default:
       break;
    }
    // restore a possible maximized Childframe mode
    boolean maxChildFrmMode = config.readBoolEntry( "mainmodule session", "maximized childframes", true);
    mainframe.setEnableMaximizedChildFrmMode(maxChildFrmMode);
 
The maximized-Childframe mode means that currently all views are maximized in Childframe mode's application desktop. \par Managing views This class provides placing algorithms in Childframe mode. The following is a list of the window placement functions - tilePragma() - Tile the windows and allow them to overlap - tileAnodine() - Tile the windows but don't allow them to overlap - tileVertically() - Tile the windows vertically - cascadeWindows() - cascade windows - cascadeMaximized() - cascade windows and maximize their viewing area - expandVertical() - expand all the windows to use the most amount of vertical space - expandHorizontal() - expand all the windows to use the most amount of horizontal space activateView(KMdiChildView) and activateView(int index) set the appropriate MDI child view as the active one. It will be raised, will get an active MDI frame and will get the focus. Call activeView() to find out what the current MDI view is. Use detachWindow() and attachWindow() for docking the MDI views to desktop and back. Connect accels of your program with activatePrevWin(), activateNextWin() and activateView(int index). Note: KMdiChildViews can be added in 2 meanings: Either as a normal child view (usually containing user document views) or as a tool-view (usually containing status, info or control widgets). The tool-views can be added as floating dockwidgets or as stay-on-top desktop windows in tool style. Also, pay attention to the fact that when you click on the close button of MDI views that their close event should be redirected to closeWindow(). Otherwise the mainframe class will not get noticed about the deleted view and a dangling pointer will remain in the MDI control. The closeWindow() or the removeWindowFromMdi() method is for that issue. The difference is closeWindow() deletes the view object. So if your application wants to control that by itself, call removeWindowFromMdi() and call delete by yourself. See also KMdiChildView.closeEvent() for that issue. Here's an example how you can suggest things for the adding of views to the MDI control via flags:
		m_mapOfMdiWidgets.insert( pWnd, mh );
		unsigned int mdiFlags = KMdi.StandardAdd;
 		if ( !show )
			mdiFlags |= KMdi.Hide;
 		if ( !attach )
			mdiFlags |= KMdi.Detach;
 		if ( minimize )
			mdiFlags |= KMdi.Minimize;
 		if ( bToolWindow)
			mdiFlags |= KMdi.ToolWindow;
		if ( m_pMdiMainFrm.isFakingSDIApplication() )
		{
			if ( attach ) //fake an SDI app
				mdiFlags |= KMdi.Maximize;
		}
		else
		{
			m_pMdiMainFrm.addWindow( pWnd, QPoint(20, 20), KMdi.AddWindowFlags(mdiFlags));
			return;
		}
		m_pMdiMainFrm.addWindow( pWnd, KMdi.AddWindowFlags(mdiFlags));
 
See KMdiMainFrmSignals for signals emitted by KMdiMainFrm

UNKNOWN: \short Base class for all your special main frames.

Field Summary
static intAnyView
static intDocumentView
static intToolView
Constructor Summary
protected KMdiMainFrm(Class dummy)
KMdiMainFrm(QWidget parentWidget, String name, int mdiMode, int flags)
KMdiMainFrm(QWidget parentWidget, String name, int mdiMode)
KMdiMainFrm(QWidget parentWidget, String name)
KMdiMainFrm(QWidget parentWidget)
Method Summary
voidactivateFirstWin()
Activates the view first viewed concerning to the access time.
voidactivateLastWin()
Activates the view last viewed concerning to the access time.
voidactivateNextWin()
Activates the next open view
voidactivatePrevWin()
Activates the previous open view
voidactivateView(int index)
Activates the view with the tab page index (TabPage mode only)
protected voidactivateView(KMdiChildView pWnd)
Sets the focus to this MDI view, raises it, activates its taskbar button and updates the system buttons in the main menubar when in maximized (Maximize mode).
KMdiChildViewactiveWindow()
Returns the focused attached MDI view.
KMdiToolViewAccessoraddToolWindow(QWidget pWnd, int pos, QWidget pTargetWnd, int percent, String tabToolTip, String tabCaption)
Usually called from addWindow() when adding a tool view window.
KMdiToolViewAccessoraddToolWindow(QWidget pWnd, int pos, QWidget pTargetWnd, int percent, String tabToolTip)
KMdiToolViewAccessoraddToolWindow(QWidget pWnd, int pos, QWidget pTargetWnd, int percent)
KMdiToolViewAccessoraddToolWindow(QWidget pWnd, int pos, QWidget pTargetWnd)
KMdiToolViewAccessoraddToolWindow(QWidget pWnd, int pos)
KMdiToolViewAccessoraddToolWindow(QWidget pWnd)
voidaddWindow(KMdiChildView pWnd, int flags)
Adds a KMdiChildView to the MDI system.
voidaddWindow(KMdiChildView pWnd)
voidaddWindow(KMdiChildView pWnd, int flags, int index)
Adds a KMdiChildView to the MDI system.
voidaddWindow(KMdiChildView pWnd, QPoint pos, int flags)
Adds a KMdiChildView to the MDI system.
voidaddWindow(KMdiChildView pWnd, QPoint pos)
voidaddWindow(KMdiChildView pWnd, QRect rectNormal, int flags)
Adds a KMdiChildView to the MDI system.
voidaddWindow(KMdiChildView pWnd, QRect rectNormal)
voidapplyOptions()
Called in the constructor (forces a resize of all MDI views)
voidattachWindow(KMdiChildView pWnd, boolean bShow, boolean bAutomaticResize)
Makes a main frame controlled undocked KMdiChildView docked.
voidattachWindow(KMdiChildView pWnd, boolean bShow)
voidattachWindow(KMdiChildView pWnd)
protected voidblockClearingOfWindowMenu(boolean bBlocked)
prevents fillWindowMenu() from m_pWindowMenu.clear().
voidcascadeMaximized()
Cascades the windows resizing them to the maximum available size.
voidcascadeWindows()
Cascades the windows without resizing them.
intchildFrameModeHeight()
Returns the Childframe mode height of this.
voidchildWindowCloseRequest(KMdiChildView pWnd)
Someone wants that the MDI view to be closed.
StringclassName()
voidcloseActiveView()
Closes the view of the active (topchild) window
voidcloseAllViews()
Close all views
protected voidcloseViewButtonPressed()
internally used to handle click on view close button (TabPage mode, only)
voidcloseWindow(KMdiChildView pWnd, boolean layoutTaskBar)
Removes a KMdiChildView from the MDI system and from the main frame`s control.
voidcloseWindow(KMdiChildView pWnd)
protected voidcreateMdiManager()
Creates the MDI view area and connects some signals and slots with the KMdiMainFrm widget.
protected voidcreateTaskBar()
Creates a new MDI taskbar (showing the MDI views as taskbar entries) and shows it.
KMdiToolViewAccessorcreateToolWindow()
Using this method you have to use the setWidget method of the access object, and it is very recommendet, that you use the widgetContainer() method for the parent of your newly created widget
KMdiChildViewcreateWrapper(QWidget view, String name, String shortName)
addWindow demands a KMdiChildView.
QSizedefaultChildFrmSize()
Returns the default size for a newly added KMdiChildView.
voiddeleteToolWindow(QWidget pWnd)
voiddeleteToolWindow(KMdiToolViewAccessor accessor)
voiddetachWindow(KMdiChildView pWnd, boolean bShow)
Makes a docked KMdiChildView undocked.
voiddetachWindow(KMdiChildView pWnd)
voiddispose()
Delete the wrapped C++ instance ahead of finalize()
protected voiddockMenuItemActivated(int id)
Usually called when the user clicks an MDI view item in the sub-popup menu "Docking" of the "Window" menu.
protected voiddragEndTimeOut()
The timer for main widget moving has elapsed . send drag end to all concerned views.
booleanevent(QEvent e)
Catches certain Qt events and processes it here.
booleaneventFilter(QObject arg1, QEvent e)
voidexpandHorizontal()
Maximizes only in horizontal direction.
voidexpandVertical()
Maximizes only in vertical direction.
voidfakeSDIApplication()
An SDI application user interface is faked:
  • an opened view is always maximized
  • buttons for maximized childframe mode aren't inserted in the main menubar
  • taskbar and windowmenu are not created/updated
  • @short An SDI application user interface is faked:
    voidfillWindowMenu()
    Update of the window menu contents.
    protected voidfinalize()
    Deletes the wrapped C++ instance
    KMdiChildViewfindWindow(String caption)
    Returns the KMdiChildView belonging to the given caption string.
    voidfinishChildframeMode()
    voidfinishIDEAlMode(boolean full)
    voidfinishIDEAlMode()
    voidfinishTabPageMode()
    voidfinishToplevelMode()
    static intframeDecorOfAttachedViews()
    voidhideViewTaskBar()
    Hides the view taskbar.
    voidiconifyAllViews()
    Iconfiy all views
    protected voididealToolViewsToStandardTabs(String[] widgetNames, int pos, int sizee)
    booleanisDisposed()
    Has the wrapped C++ instance been deleted?
    booleanisFakingSDIApplication()
    booleanisInMaximizedChildFrmMode()
    Returns whether the application's MDI views are in maximized state or not.
    booleanisViewTaskBarOn()
    intmdiMode()
    Returns the MDI mode.
    QMetaObjectmetaObject()
    voidnextToolViewInDock()
    protected voidpopupWindowMenu(QPoint p)
    Popups the "Window" menu.
    protected ArrayListprepareIdealToTabs(KDockWidget container)
    voidprevToolViewInDock()
    voidremoveWindowFromMdi(KMdiChildView pWnd)
    Removes a KMdiChildView from the MDI system and from the main frame`s control.
    protected voidresizeEvent(QResizeEvent arg1)
    voidsetBackgroundColor(QColor c)
    Sets a background color for the MDI view area widget.
    voidsetBackgroundPixmap(QPixmap pm)
    Sets a background pixmap for the MDI view area widget.
    voidsetDefaultChildFrmSize(QSize sz)
    Sets a size that is used as the default size for a newly to the MDI system added KMdiChildView .
    voidsetEnableMaximizedChildFrmMode(boolean bEnable)
    If in Childframe mode, we can switch between maximized or restored shown MDI views
    voidsetManagedDockPositionModeEnabled(boolean enabled)
    voidsetMenuForSDIModeSysButtons(KMenuBar menuBar)
    Tells the MDI system a QMenu where it can insert buttons for the system menu, undock, minimize, restore actions.
    voidsetMenuForSDIModeSysButtons()
    voidsetMinimumSize(int minw, int minh)
    Do nothing when in Toplevel mode
    voidsetStandardMDIMenuEnabled(boolean showModeMenu)
    Control whether or not the standard MDI menu is displayed when a context menu is displayed
    voidsetStandardMDIMenuEnabled()
    voidsetSwitching(boolean switching)
    We're switching something.
    voidsetSysButtonsAtMenuPosition()
    If there's a main menubar given, it will create the 4 maximize mode buttons there (undock, minimize, restore, close).
    protected voidsetTabWidgetVisibility(int arg1)
    Set tabwidget visibility @short Set tabwidget visibility
    voidsetToolviewStyle(int flags)
    Sets the appearance of the toolview tabs.
    voidsetUndockPositioningOffset(QPoint offset)
    Sets an offset value that is used on detachWindow() .
    voidshowViewTaskBar()
    Shows the view taskbar.
    voidslot_toggleTaskBar()
    Switches the KMdiTaskBar on and off.
    booleanswitching()
    protected voidswitchOffMaximizeModeForMenu(KMdiChildFrm oldChild)
    Turns the system buttons for maximize mode (SDI mode) off, and disconnects them
    voidswitchToChildframeMode()
    Docks all view windows (Windows-like)
    voidswitchToIDEAlMode()
    Docks all view windows.
    voidswitchToTabPageMode()
    Docks all view windows (Windows-like)
    voidswitchToToplevelMode()
    Undocks all view windows (unix-like)
    protected KTabWidgettabWidget()
    Returns the tabwidget used in IDEAl and Tabbed modes.
    protected inttabWidgetVisibility()
    Get tabwidget visibility @short Get tabwidget visibility
    protected voidtaskbarButtonRightClicked(KMdiChildView pWnd)
    Activates the MDI view (see activateView() ) and popups the taskBar popup menu (see taskBarPopup() ).
    inttaskBarHeight()
    Returns the height of the taskbar.
    QPopupMenutaskBarPopup(KMdiChildView pWnd, boolean bIncludeWindowPopup)
    Returns a popup menu filled according to the MDI view state.
    QPopupMenutaskBarPopup(KMdiChildView pWnd)
    voidtileAnodine()
    Tile Anodine
    voidtilePragma()
    Tile Pragma
    voidtileVertically()
    Tile Vertically
    protected voidupdateSysButtonConnections(KMdiChildFrm oldChild, KMdiChildFrm newChild)
    Reconnects the system buttons form maximize mode (SDI mode) with the new child frame
    booleanwindowExists(KMdiChildView pWnd, int as)
    Returns whether this MDI child view is under MDI control (using addWindow() ) or not.
    QPopupMenuwindowMenu()
    Returns a popup menu that contains the MDI controlled view list.
    protected voidwindowMenuItemActivated(int id)
    Usually called when the user clicks an MDI view item in the "Window" menu.
    QPopupMenuwindowPopup(KMdiChildView pWnd, boolean bIncludeTaskbarPopup)
    Returns a popup menu with only a title "Window".
    QPopupMenuwindowPopup(KMdiChildView pWnd)

    Field Detail

    AnyView

    public static final int AnyView

    DocumentView

    public static final int DocumentView

    ToolView

    public static final int ToolView

    Constructor Detail

    KMdiMainFrm

    protected KMdiMainFrm(Class dummy)

    KMdiMainFrm

    public KMdiMainFrm(QWidget parentWidget, String name, int mdiMode, int flags)

    KMdiMainFrm

    public KMdiMainFrm(QWidget parentWidget, String name, int mdiMode)

    KMdiMainFrm

    public KMdiMainFrm(QWidget parentWidget, String name)

    KMdiMainFrm

    public KMdiMainFrm(QWidget parentWidget)

    Method Detail

    activateFirstWin

    public void activateFirstWin()
    Activates the view first viewed concerning to the access time.

    UNKNOWN: Activates the view first viewed concerning to the access time.

    activateLastWin

    public void activateLastWin()
    Activates the view last viewed concerning to the access time.

    UNKNOWN: Activates the view last viewed concerning to the access time.

    activateNextWin

    public void activateNextWin()
    Activates the next open view

    UNKNOWN: Activates the next open view

    activatePrevWin

    public void activatePrevWin()
    Activates the previous open view

    UNKNOWN: Activates the previous open view

    activateView

    public void activateView(int index)
    Activates the view with the tab page index (TabPage mode only)

    UNKNOWN: Activates the view with the tab page index (TabPage mode only)

    activateView

    protected void activateView(KMdiChildView pWnd)
    Sets the focus to this MDI view, raises it, activates its taskbar button and updates the system buttons in the main menubar when in maximized (Maximize mode).

    UNKNOWN: Sets the focus to this MDI view, raises it, activates its taskbar button and updates the system buttons in the main menubar when in maximized (Maximize mode).

    activeWindow

    public KMdiChildView activeWindow()
    Returns the focused attached MDI view.

    UNKNOWN: Returns the focused attached MDI view.

    addToolWindow

    public KMdiToolViewAccessor addToolWindow(QWidget pWnd, int pos, QWidget pTargetWnd, int percent, String tabToolTip, String tabCaption)
    Usually called from addWindow() when adding a tool view window. It reparents the given widget as toplevel and stay-on-top on the application's main widget.

    UNKNOWN: Usually called from addWindow() when adding a tool view window.

    addToolWindow

    public KMdiToolViewAccessor addToolWindow(QWidget pWnd, int pos, QWidget pTargetWnd, int percent, String tabToolTip)

    addToolWindow

    public KMdiToolViewAccessor addToolWindow(QWidget pWnd, int pos, QWidget pTargetWnd, int percent)

    addToolWindow

    public KMdiToolViewAccessor addToolWindow(QWidget pWnd, int pos, QWidget pTargetWnd)

    addToolWindow

    public KMdiToolViewAccessor addToolWindow(QWidget pWnd, int pos)

    addToolWindow

    public KMdiToolViewAccessor addToolWindow(QWidget pWnd)

    addWindow

    public void addWindow(KMdiChildView pWnd, int flags)
    Adds a KMdiChildView to the MDI system. The main frame takes control of it. \param pWnd the parent view. \param flags the flags for the view such as:
  • whether
  • the view should be attached or detached.
  • whether
  • the view should be shown or hidden
  • whether
  • the view should be maximized, minimized or restored (normalized)
  • whether
  • the view should be added as tool view (stay-on-top and toplevel) or added as document-type view.

    UNKNOWN: Adds a KMdiChildView to the MDI system.

    addWindow

    public void addWindow(KMdiChildView pWnd)

    addWindow

    public void addWindow(KMdiChildView pWnd, int flags, int index)
    Adds a KMdiChildView to the MDI system. The main frame takes control of it. \param pWnd the parent view. \param flags You can specify here whether:
  • the
  • view should be attached or detached.
  • shown
  • or hidden
  • maximized
  • , minimized or restored (normalized)
  • added
  • as tool view (stay-on-top and toplevel) or added as document-type view. \param index the index of the tab we should insert the new tab after. If index == -1 then the tab will just be appended to the end. Using this parameter in childview mode has no effect. \since 3.3

    UNKNOWN: Adds a KMdiChildView to the MDI system.

    addWindow

    public void addWindow(KMdiChildView pWnd, QPoint pos, int flags)
    Adds a KMdiChildView to the MDI system. The main frame takes control of it. \param pWnd the parent view. \param pos move the child view to the specified position \param flags the flags for the view such as:
  • whether
  • the view should be attached or detached.
  • whether
  • the view should be shown or hidden
  • whether
  • the view should be maximized, minimized or restored (normalized)
  • whether
  • the view should be added as tool view (stay-on-top and toplevel) or added as document-type view.

    UNKNOWN: Adds a KMdiChildView to the MDI system.

    addWindow

    public void addWindow(KMdiChildView pWnd, QPoint pos)

    addWindow

    public void addWindow(KMdiChildView pWnd, QRect rectNormal, int flags)
    Adds a KMdiChildView to the MDI system. The main frame takes control of it. \param pWnd the parent view. \param rectNormal Sets the geometry for this child view \param flags the flags for the view such as:
  • whether
  • the view should be attached or detached.
  • whether
  • the view should be shown or hidden
  • whether
  • the view should be maximized, minimized or restored (normalized)
  • whether
  • the view should be added as tool view (stay-on-top and toplevel) or added as document-type view.

    UNKNOWN: Adds a KMdiChildView to the MDI system.

    addWindow

    public void addWindow(KMdiChildView pWnd, QRect rectNormal)

    applyOptions

    public void applyOptions()
    Called in the constructor (forces a resize of all MDI views)

    UNKNOWN: Called in the constructor (forces a resize of all MDI views)

    attachWindow

    public void attachWindow(KMdiChildView pWnd, boolean bShow, boolean bAutomaticResize)
    Makes a main frame controlled undocked KMdiChildView docked. Doesn't work on KMdiChildView which aren't added to the MDI system. Use addWindow() for that.

    UNKNOWN: Makes a main frame controlled undocked KMdiChildView docked.

    attachWindow

    public void attachWindow(KMdiChildView pWnd, boolean bShow)

    attachWindow

    public void attachWindow(KMdiChildView pWnd)

    blockClearingOfWindowMenu

    protected void blockClearingOfWindowMenu(boolean bBlocked)
    prevents fillWindowMenu() from m_pWindowMenu.clear(). You have to care for it by yourself. This is useful if you want to add some actions in your overridden fillWindowMenu() method.

    UNKNOWN: prevents fillWindowMenu() from m_pWindowMenu.clear().

    cascadeMaximized

    public void cascadeMaximized()
    Cascades the windows resizing them to the maximum available size.

    UNKNOWN: Cascades the windows resizing them to the maximum available size.

    cascadeWindows

    public void cascadeWindows()
    Cascades the windows without resizing them.

    UNKNOWN: Cascades the windows without resizing them.

    childFrameModeHeight

    public int childFrameModeHeight()
    Returns the Childframe mode height of this. Makes only sense when in Toplevel mode.

    UNKNOWN: Returns the Childframe mode height of this.

    childWindowCloseRequest

    public void childWindowCloseRequest(KMdiChildView pWnd)
    Someone wants that the MDI view to be closed. This method sends a KMdiViewCloseEvent to itself to break the function call stack. See also event() .

    UNKNOWN: Someone wants that the MDI view to be closed.

    className

    public String className()

    closeActiveView

    public void closeActiveView()
    Closes the view of the active (topchild) window

    UNKNOWN: Closes the view of the active (topchild) window

    closeAllViews

    public void closeAllViews()
    Close all views

    UNKNOWN: Close all views

    closeViewButtonPressed

    protected void closeViewButtonPressed()
    internally used to handle click on view close button (TabPage mode, only)

    UNKNOWN: internally used to handle click on view close button (TabPage mode, only)

    closeWindow

    public void closeWindow(KMdiChildView pWnd, boolean layoutTaskBar)
    Removes a KMdiChildView from the MDI system and from the main frame`s control. Note: The view will be deleted!

    UNKNOWN: Removes a KMdiChildView from the MDI system and from the main frame`s control.

    closeWindow

    public void closeWindow(KMdiChildView pWnd)

    createMdiManager

    protected void createMdiManager()
    Creates the MDI view area and connects some signals and slots with the KMdiMainFrm widget.

    UNKNOWN: Creates the MDI view area and connects some signals and slots with the KMdiMainFrm widget.

    createTaskBar

    protected void createTaskBar()
    Creates a new MDI taskbar (showing the MDI views as taskbar entries) and shows it.

    UNKNOWN: Creates a new MDI taskbar (showing the MDI views as taskbar entries) and shows it.

    createToolWindow

    public KMdiToolViewAccessor createToolWindow()
    Using this method you have to use the setWidget method of the access object, and it is very recommendet, that you use the widgetContainer() method for the parent of your newly created widget

    UNKNOWN: Using this method you have to use the setWidget method of the access object, and it is very recommendet, that you use the widgetContainer() method for the parent of your newly created widget

    createWrapper

    public KMdiChildView createWrapper(QWidget view, String name, String shortName)
    addWindow demands a KMdiChildView. This method wraps every QWidget in such an object and this way you can put every widget under MDI control.

    UNKNOWN: addWindow demands a KMdiChildView.

    defaultChildFrmSize

    public QSize defaultChildFrmSize()
    Returns the default size for a newly added KMdiChildView. See setDefaultChildFrmSize() .

    UNKNOWN: Returns the default size for a newly added KMdiChildView.

    deleteToolWindow

    public void deleteToolWindow(QWidget pWnd)

    deleteToolWindow

    public void deleteToolWindow(KMdiToolViewAccessor accessor)

    detachWindow

    public void detachWindow(KMdiChildView pWnd, boolean bShow)
    Makes a docked KMdiChildView undocked. The view window still remains under the main frame's MDI control.

    UNKNOWN: Makes a docked KMdiChildView undocked.

    detachWindow

    public void detachWindow(KMdiChildView pWnd)

    dispose

    public void dispose()
    Delete the wrapped C++ instance ahead of finalize()

    dockMenuItemActivated

    protected void dockMenuItemActivated(int id)
    Usually called when the user clicks an MDI view item in the sub-popup menu "Docking" of the "Window" menu.

    UNKNOWN: Usually called when the user clicks an MDI view item in the sub-popup menu "Docking" of the "Window" menu.

    dragEndTimeOut

    protected void dragEndTimeOut()
    The timer for main widget moving has elapsed . send drag end to all concerned views.

    UNKNOWN: The timer for main widget moving has elapsed . send drag end to all concerned views.

    event

    public boolean event(QEvent e)
    Catches certain Qt events and processes it here. Currently, here this catches only the KMdiViewCloseEvent (a KMdi user event) which is sent from itself in childWindowCloseRequest() right after a KMdiChildView.closeEvent() . The reason for this event to itself is simple: It just wants to break the function call stack. It continues the processing with calling closeWindow() . You see, a close() is translated to a closeWindow() . It is necessary that the main frame has to start an MDI view close action because it must remove the MDI view from MDI control, additionally. This method calls QMainWindow.event , additionally.

    UNKNOWN: Catches certain Qt events and processes it here.

    eventFilter

    public boolean eventFilter(QObject arg1, QEvent e)

    expandHorizontal

    public void expandHorizontal()
    Maximizes only in horizontal direction.

    UNKNOWN: Maximizes only in horizontal direction.

    expandVertical

    public void expandVertical()
    Maximizes only in vertical direction.

    UNKNOWN: Maximizes only in vertical direction.

    fakeSDIApplication

    public void fakeSDIApplication()
    An SDI application user interface is faked:
  • an opened view is always maximized
  • buttons for maximized childframe mode aren't inserted in the main menubar
  • taskbar and windowmenu are not created/updated
  • @short An SDI application user interface is faked:

    fillWindowMenu

    public void fillWindowMenu()
    Update of the window menu contents.

    UNKNOWN: Update of the window menu contents.

    finalize

    protected void finalize()
    Deletes the wrapped C++ instance

    findWindow

    public KMdiChildView findWindow(String caption)
    Returns the KMdiChildView belonging to the given caption string.

    UNKNOWN: Returns the KMdiChildView belonging to the given caption string.

    finishChildframeMode

    public void finishChildframeMode()

    finishIDEAlMode

    public void finishIDEAlMode(boolean full)

    finishIDEAlMode

    public void finishIDEAlMode()

    finishTabPageMode

    public void finishTabPageMode()

    finishToplevelMode

    public void finishToplevelMode()

    frameDecorOfAttachedViews

    public static int frameDecorOfAttachedViews()

    Returns: the decoration of the window frame of docked (attached) MDI views

    UNKNOWN:

    hideViewTaskBar

    public void hideViewTaskBar()
    Hides the view taskbar. This should be connected with your "View" menu.

    UNKNOWN: Hides the view taskbar.

    iconifyAllViews

    public void iconifyAllViews()
    Iconfiy all views

    UNKNOWN: Iconfiy all views

    idealToolViewsToStandardTabs

    protected void idealToolViewsToStandardTabs(String[] widgetNames, int pos, int sizee)

    isDisposed

    public boolean isDisposed()
    Has the wrapped C++ instance been deleted?

    isFakingSDIApplication

    public boolean isFakingSDIApplication()

    Returns: if we are faking an SDI application (fakeSDIApplication())

    UNKNOWN:

    isInMaximizedChildFrmMode

    public boolean isInMaximizedChildFrmMode()
    Returns whether the application's MDI views are in maximized state or not.

    UNKNOWN: Returns whether the application's MDI views are in maximized state or not.

    isViewTaskBarOn

    public boolean isViewTaskBarOn()

    Returns: if the view taskbar should be shown if there are MDI views

    UNKNOWN:

    mdiMode

    public int mdiMode()
    Returns the MDI mode. This can be one of the enumerations KMdi.MdiMode.

    UNKNOWN: Returns the MDI mode.

    metaObject

    public QMetaObject metaObject()

    nextToolViewInDock

    public void nextToolViewInDock()

    popupWindowMenu

    protected void popupWindowMenu(QPoint p)
    Popups the "Window" menu. See also windowPopup() .

    UNKNOWN: Popups the "Window" menu.

    prepareIdealToTabs

    protected ArrayList prepareIdealToTabs(KDockWidget container)

    prevToolViewInDock

    public void prevToolViewInDock()

    removeWindowFromMdi

    public void removeWindowFromMdi(KMdiChildView pWnd)
    Removes a KMdiChildView from the MDI system and from the main frame`s control. The caller is responsible for deleting the view. If the view is not deleted it will be reparented to 0

    UNKNOWN: Removes a KMdiChildView from the MDI system and from the main frame`s control.

    resizeEvent

    protected void resizeEvent(QResizeEvent arg1)

    setBackgroundColor

    public void setBackgroundColor(QColor c)
    Sets a background color for the MDI view area widget.

    UNKNOWN: Sets a background color for the MDI view area widget.

    setBackgroundPixmap

    public void setBackgroundPixmap(QPixmap pm)
    Sets a background pixmap for the MDI view area widget.

    UNKNOWN: Sets a background pixmap for the MDI view area widget.

    setDefaultChildFrmSize

    public void setDefaultChildFrmSize(QSize sz)
    Sets a size that is used as the default size for a newly to the MDI system added KMdiChildView . By default this size is 600x400. So all non-resized added MDI views appear in that size.

    UNKNOWN: Sets a size that is used as the default size for a newly to the MDI system added KMdiChildView .

    setEnableMaximizedChildFrmMode

    public void setEnableMaximizedChildFrmMode(boolean bEnable)
    If in Childframe mode, we can switch between maximized or restored shown MDI views

    UNKNOWN: If in Childframe mode, we can switch between maximized or restored shown MDI views

    setManagedDockPositionModeEnabled

    public void setManagedDockPositionModeEnabled(boolean enabled)

    setMenuForSDIModeSysButtons

    public void setMenuForSDIModeSysButtons(KMenuBar menuBar)
    Tells the MDI system a QMenu where it can insert buttons for the system menu, undock, minimize, restore actions. If no such menu is given, KMdi simply overlays the buttons at the upper right-hand side of the main widget.

    UNKNOWN: Tells the MDI system a QMenu where it can insert buttons for the system menu, undock, minimize, restore actions.

    setMenuForSDIModeSysButtons

    public void setMenuForSDIModeSysButtons()

    setMinimumSize

    public void setMinimumSize(int minw, int minh)
    Do nothing when in Toplevel mode

    UNKNOWN: Do nothing when in Toplevel mode

    setStandardMDIMenuEnabled

    public void setStandardMDIMenuEnabled(boolean showModeMenu)
    Control whether or not the standard MDI menu is displayed when a context menu is displayed

    UNKNOWN: Control whether or not the standard MDI menu is displayed when a context menu is displayed

    setStandardMDIMenuEnabled

    public void setStandardMDIMenuEnabled()

    setSwitching

    public void setSwitching(boolean switching)
    We're switching something. @short We're switching something.

    setSysButtonsAtMenuPosition

    public void setSysButtonsAtMenuPosition()
    If there's a main menubar given, it will create the 4 maximize mode buttons there (undock, minimize, restore, close).

    UNKNOWN: If there's a main menubar given, it will create the 4 maximize mode buttons there (undock, minimize, restore, close).

    setTabWidgetVisibility

    protected void setTabWidgetVisibility(int arg1)
    Set tabwidget visibility @short Set tabwidget visibility

    setToolviewStyle

    public void setToolviewStyle(int flags)
    Sets the appearance of the toolview tabs.

    Parameters: flags See KMdi.ToolviewStyle.

    UNKNOWN: Sets the appearance of the toolview tabs.

    setUndockPositioningOffset

    public void setUndockPositioningOffset(QPoint offset)
    Sets an offset value that is used on detachWindow() . The undocked window is visually moved on the desktop by this offset.

    UNKNOWN: Sets an offset value that is used on detachWindow() .

    showViewTaskBar

    public void showViewTaskBar()
    Shows the view taskbar. This should be connected with your "View" menu.

    UNKNOWN: Shows the view taskbar.

    slot_toggleTaskBar

    public void slot_toggleTaskBar()
    Switches the KMdiTaskBar on and off.

    UNKNOWN: Switches the KMdiTaskBar on and off.

    switching

    public boolean switching()

    switchOffMaximizeModeForMenu

    protected void switchOffMaximizeModeForMenu(KMdiChildFrm oldChild)
    Turns the system buttons for maximize mode (SDI mode) off, and disconnects them

    UNKNOWN: Turns the system buttons for maximize mode (SDI mode) off, and disconnects them

    switchToChildframeMode

    public void switchToChildframeMode()
    Docks all view windows (Windows-like)

    UNKNOWN: Docks all view windows (Windows-like)

    switchToIDEAlMode

    public void switchToIDEAlMode()
    Docks all view windows. Toolviews use dockcontainers

    UNKNOWN: Docks all view windows.

    switchToTabPageMode

    public void switchToTabPageMode()
    Docks all view windows (Windows-like)

    UNKNOWN: Docks all view windows (Windows-like)

    switchToToplevelMode

    public void switchToToplevelMode()
    Undocks all view windows (unix-like)

    UNKNOWN: Undocks all view windows (unix-like)

    tabWidget

    protected KTabWidget tabWidget()
    Returns the tabwidget used in IDEAl and Tabbed modes. Returns 0 in other modes. @short Returns the tabwidget used in IDEAl and Tabbed modes.

    tabWidgetVisibility

    protected int tabWidgetVisibility()
    Get tabwidget visibility @short Get tabwidget visibility

    taskbarButtonRightClicked

    protected void taskbarButtonRightClicked(KMdiChildView pWnd)
    Activates the MDI view (see activateView() ) and popups the taskBar popup menu (see taskBarPopup() ).

    UNKNOWN: Activates the MDI view (see activateView() ) and popups the taskBar popup menu (see taskBarPopup() ).

    taskBarHeight

    public int taskBarHeight()
    Returns the height of the taskbar.

    UNKNOWN: Returns the height of the taskbar.

    taskBarPopup

    public QPopupMenu taskBarPopup(KMdiChildView pWnd, boolean bIncludeWindowPopup)
    Returns a popup menu filled according to the MDI view state. You can override this method to insert additional entries there. The popup menu is usually popuped when the user clicks with the right mouse button on a taskbar entry. The default entries are: Undock/Dock, Restore/Maximize/Minimize, Close and an empty sub-popup ( windowPopup() ) menu called Operations.

    UNKNOWN: Returns a popup menu filled according to the MDI view state.

    taskBarPopup

    public QPopupMenu taskBarPopup(KMdiChildView pWnd)

    tileAnodine

    public void tileAnodine()
    Tile Anodine

    UNKNOWN: Tile Anodine

    tilePragma

    public void tilePragma()
    Tile Pragma

    UNKNOWN: Tile Pragma

    tileVertically

    public void tileVertically()
    Tile Vertically

    UNKNOWN: Tile Vertically

    updateSysButtonConnections

    protected void updateSysButtonConnections(KMdiChildFrm oldChild, KMdiChildFrm newChild)
    Reconnects the system buttons form maximize mode (SDI mode) with the new child frame

    UNKNOWN: Reconnects the system buttons form maximize mode (SDI mode) with the new child frame

    windowExists

    public boolean windowExists(KMdiChildView pWnd, int as)
    Returns whether this MDI child view is under MDI control (using addWindow() ) or not.

    UNKNOWN: Returns whether this MDI child view is under MDI control (using addWindow() ) or not.

    windowMenu

    public QPopupMenu windowMenu()
    Returns a popup menu that contains the MDI controlled view list. Additionally, this menu provides some placing actions for these views. Usually, you insert this popup menu in your main menubar as "Window" menu.

    UNKNOWN: Returns a popup menu that contains the MDI controlled view list.

    windowMenuItemActivated

    protected void windowMenuItemActivated(int id)
    Usually called when the user clicks an MDI view item in the "Window" menu.

    UNKNOWN: Usually called when the user clicks an MDI view item in the "Window" menu.

    windowPopup

    public QPopupMenu windowPopup(KMdiChildView pWnd, boolean bIncludeTaskbarPopup)
    Returns a popup menu with only a title "Window". You can fill it with own operations entries on the MDI view. This popup menu is inserted as last menu item in taskBarPopup() .

    UNKNOWN: Returns a popup menu with only a title "Window".

    windowPopup

    public QPopupMenu windowPopup(KMdiChildView pWnd)