kmainwindow.cpp
287 int m = XParseGeometry( kapp->geometryArgument().latin1(), &x, &y, (unsigned int*)&w, (unsigned int*)&h);
758 group = (!::qstrcmp(toolbar->name(), "unnamed") ? TQString::number(n) : TQString(" ")+toolbar->name());
798 d->showStatusBarAction = KStdAction::showStatusbar(TQT_TQOBJECT(this), TQT_SLOT(setSettingsDirty()), actionCollection());
819 setName( config->readEntry(TQString::fromLatin1("ObjectName")).latin1()); // latin1 is right here
834 void KMainWindow::applyMainWindowSettings(KConfig *config, const TQString &configGroup,bool force)
873 group = (!::qstrcmp(toolbar->name(), "unnamed") ? TQString::number(n) : TQString(" ")+toolbar->name());
943 d->defaultWindowSize = TQRect(desk.width(), width(), desk.height(), height()); // store default values
void applySettings(KConfig *config, const TQString &configGroup, bool force)
Read the toolbar settings from group configGroup in config and apply them.
Definition: ktoolbar.cpp:1645
virtual void conserveMemory()
This function will attempt to give up some memory after the GUI is built.
Definition: kxmlguiclient.cpp:534
calls createGUI() once ToolBar, Keys and Statusbar have been taken care of.
Definition: kmainwindow.h:590
KAction * keyBindings(const TQObject *recvr, const char *slot, KActionCollection *parent, const char *name)
Display the configure key bindings dialog.
Definition: kstdaction.cpp:298
void setAutoSaveSettings(const TQString &groupName=TQString::fromLatin1("MainWindow"), bool saveWindowSize=true)
Call this to enable "auto-save" of toolbar/menubar/statusbar settings (and optionally window size)...
Definition: kmainwindow.cpp:1027
TQString locate(const char *type, const TQString &filename, const KInstance *instance=KGlobal::instance())
virtual void setXMLFile(const TQString &file, bool merge=false, bool setXMLDoc=true)
Sets the name of the rc file containing the XML for the part.
Definition: kxmlguiclient.cpp:165
virtual bool commitData(TQSessionManager &sm)
void setStandardToolBarMenuEnabled(bool enable)
Sets whether KMainWindow should provide a menu that allows showing/hiding the available toolbars ( us...
Definition: kmainwindow.cpp:769
virtual KActionCollection * actionCollection() const
Retrieves the entire action collection for the GUI client.
Definition: kxmlguiclient.cpp:107
A KXMLGUIClient can be used with KXMLGUIFactory to create a GUI from actions and an XML document...
Definition: kxmlguiclient.h:43
void setXMLGUIBuildDocument(const TQDomDocument &doc)
Definition: kxmlguiclient.cpp:540
KPopupMenu * helpMenu(const TQString &aboutAppText=TQString::null, bool showWhatsThis=true)
Retrieve the standard help menu.
Definition: kmainwindow.cpp:324
static const TQString classNameOfToplevel(int number)
Returns the className() of the number of the toplevel window which should be restored.
Definition: kmainwindow.cpp:364
void removeClient(KXMLGUIClient *client)
Removes the GUI described by the client, by unplugging all provided actions and removing all owned co...
Definition: kxmlguifactory.cpp:321
virtual void setPlainCaption(const TQString &caption)
Make a plain caption without any modifications.
Definition: kmainwindow.cpp:591
void applyMainWindowSettings(KConfig *config, const TQString &groupName, bool force)
Read settings for statusbar, menubar and toolbar from their respective groups in the config file and ...
Definition: kmainwindow.cpp:834
void addClient(KXMLGUIClient *client)
Creates the GUI described by the TQDomDocument of the client, using the client's actions, and merges it with the previously created GUI.
Definition: kxmlguifactory.cpp:224
TQPtrListIterator< KToolBar > toolBarIterator()
Definition: kmainwindow.cpp:1166
virtual void saveProperties(KConfig *)
Save your instance-specific properties.
Definition: kmainwindow.h:884
void writeEntry(const TQString &pKey, const TQString &pValue, bool bPersistent=true, bool bGlobal=false, bool bNLS=false)
void resetAutoSaveSettings()
Disable the auto-save-settings feature.
Definition: kmainwindow.cpp:1042
KMainWindow(TQWidget *parent=0, const char *name=0, WFlags f=(WFlags)(WType_TopLevel|WDestructiveClose))
Construct a main window.
Definition: kmainwindow.cpp:167
KXMLGUIFactory * factory() const
Retrieves a pointer to the KXMLGUIFactory this client is associated with (will return 0L if the clien...
Definition: kxmlguiclient.cpp:555
KPopupMenu * customHelpMenu(bool showWhatsThis=true)
Returns the help menu.
Definition: kmainwindow.cpp:341
kdbgstream kdDebug(int area=0)
virtual void sync()
virtual void finalizeGUI(KXMLGUIClient *client)
Definition: kmainwindow.cpp:1249
virtual void slotStateChanged(const TQString &newstate)
Apply a state change.
Definition: kmainwindow.cpp:610
void setGroup(const TQString &group)
KAccel * kaccel()
Returns the KAccel object of the most recently set widget.
Definition: kactioncollection.cpp:282
KDE_DEPRECATED type * setObject(type *obj, bool isArray=false)
virtual void stateChanged(const TQString &newstate, ReverseStateChange reverse=StateNoReverse)
Actions can collectively be assigned a "State".
Definition: kxmlguiclient.cpp:899
TQString group() const
TQString readEntry(const TQString &pKey, const TQString &aDefault=TQString::null) const
bool restore(int number, bool show=true)
Restore the session specified by number.
Definition: kmainwindow.cpp:411
KAction * configureToolbars(const TQObject *recvr, const char *slot, KActionCollection *parent, const char *name)
The Customize Toolbar dialog.
Definition: kstdaction.cpp:302
virtual void saveGlobalProperties(KConfig *sessionConfig)
Save your application-wide properties.
Definition: kmainwindow.cpp:674
void saveNewToolbarConfig()
Rebuilds the GUI after KEditToolbar changed the toolbar layout.
Definition: kmainwindow.cpp:439
virtual bool saveState(TQSessionManager &sm)
void saveAutoSaveSettings()
This slot should only be called in case you reimplement closeEvent() and if you are using the "auto-s...
Definition: kmainwindow.cpp:1059
void saveWindowSize(KConfig *config) const
For inherited classes Note that the group must be set before calling.
Definition: kmainwindow.cpp:902
unsigned long state() const
void saveSettings(KConfig *config, const TQString &configGroup)
Save the toolbar settings to group configGroup in config.
Definition: ktoolbar.cpp:1043
Abstract interface for a "GUI builder", used by the GUIFactory This interface is implemented by KMain...
Definition: kxmlguibuilder.h:39
KAction * toolBarMenuAction()
Returns a pointer to the mainwindows action responsible for the toolbars menu.
Definition: kmainwindow.cpp:264
virtual void setCaption(const TQString &caption)
Makes a KDE compliant caption.
Definition: kmainwindow.cpp:581
static TQPtrList< KMainWindow > * getMemberList()
List of members of KMainWindow class.
Definition: kmainwindow.cpp:1245
virtual bool queryExit()
Called before the very last window is closed, either by the user or indirectly by the session manager...
Definition: kmainwindow.cpp:664
static TQPtrList< KMainWindow > * memberList
List of members of KMainWindow class.
Definition: kmainwindow.h:393
virtual bool queryClose()
Called before the window is closed, either by the user or indirectly by the session manager...
Definition: kmainwindow.cpp:669
void setHelpMenuEnabled(bool showHelpMenu=true)
Enables the build of a standard help menu when calling createGUI().
Definition: kmainwindow.cpp:571
adds action to show/hide the toolbar(s) and adds action to configure the toolbar(s).
Definition: kmainwindow.h:561
void resetContainer(const TQString &containerName, bool useTagName=false)
Use this method to free all memory allocated by the KXMLGUIFactory for a specific container...
Definition: kxmlguifactory.cpp:413
KXMLGUIFactory, together with KXMLGUIClient objects, can be used to create a GUI of container widgets...
Definition: kxmlguifactory.h:62
virtual void setWidget(TQWidget *widget)
This sets the widget to which the keyboard shortcuts should be attached.
Definition: kactioncollection.cpp:152
bool isStandardToolBarMenuEnabled() const
Definition: kmainwindow.cpp:791
void parseGeometry(bool parsewidth)
parse the geometry from the geometry command line argument
Definition: kmainwindow.cpp:279
static KApplication * kApplication()
adds action to show/hide the statusbar if the statusbar exists.
Definition: kmainwindow.h:572
TQSize sizeForCentralWidgetSize(TQSize size) KDE_DEPRECATED
Definition: kmainwindow.cpp:1193
virtual TQDomDocument domDocument() const
Definition: kxmlguiclient.cpp:128
bool hasKey(const TQString &key) const
int readNumEntry(const TQString &pKey, int nDefault=0) const
virtual void readProperties(KConfig *)
Read your instance-specific properties.
Definition: kmainwindow.h:889
virtual void closeEvent(TQCloseEvent *)
Reimplemented to call the queryClose() and queryExit() handlers.
Definition: kmainwindow.cpp:634
void createStandardStatusBarAction()
Sets whether KMainWindow should provide a menu that allows showing/hiding of the statusbar ( using KT...
Definition: kmainwindow.cpp:796
void saveMainWindowSettings(KConfig *config, const TQString &groupName=TQString::null)
Save settings for statusbar, menubar and toolbar to their respective groups in the config file config...
Definition: kmainwindow.cpp:716
static WindowInfo windowInfo(WId win, unsigned long properties=0, unsigned long properties2=0)
void createGUI(const TQString &xmlfile=TQString::null, bool _conserveMemory=true)
Create a GUI given a local XML file.
Definition: kmainwindow.cpp:491
KPopupMenu * menu()
Returns a popup menu you can use in the menu bar or where you need it.
Definition: khelpmenu.cpp:112
KConfig * sessionConfig()
void restoreWindowSize(KConfig *config)
For inherited classes Note that the group must be set before calling, and that a -geometry on the com...
Definition: kmainwindow.cpp:934
kndbgstream & endl(kndbgstream &s)
KToolBar * toolBar(const char *name=0)
Returns a pointer to the toolbar with the specified name.
Definition: kmainwindow.cpp:1151
auto-saves (and loads) the toolbar/menubar/statusbar settings and window size using the default name...
Definition: kmainwindow.h:584
void revertToDefault(const TQString &key)
virtual void readGlobalProperties(KConfig *sessionConfig)
The counterpart of saveGlobalProperties().
Definition: kmainwindow.cpp:678
static void setIcons(WId win, const TQPixmap &icon, const TQPixmap &miniIcon)
static KConfig * config()
Definition: ktoolbarhandler.h:33
static void setState(WId win, unsigned long state)
virtual TQString xmlFile() const
This will return the name of the XML file as set by setXMLFile().
Definition: kxmlguiclient.cpp:133
KToggleAction * showStatusbar(const TQObject *recvr, const char *slot, KActionCollection *parent, const char *_name)
Show/Hide the statusbar.
Definition: kstdaction.cpp:270
void setupGUI(int options=ToolBar|Keys|StatusBar|Save|Create, const TQString &xmlfile=TQString::null)
Configures the current windows and its actions in the typical KDE fashion.
Definition: kmainwindow.cpp:445
bool hasDefault(const TQString &key) const