Update my email address.
[kdbg.git] / kdbg / dbgmainwnd.h
blob0c72b0ce2fc6a90fa07d26ae6f03ce0fe8961776
1 // $Id$
3 // Copyright by Johannes Sixt
4 // This file is under GPL, the GNU General Public Licence
6 #ifndef DBGMAINWND_H
7 #define DBGMAINWND_H
9 #include <qtimer.h>
10 #include <kdockwidget.h>
11 #include "mainwndbase.h"
12 #include "regwnd.h"
14 class KRecentFilesAction;
15 class WinStack;
16 class QListBox;
17 class QCString;
18 class ExprWnd;
19 class BreakpointTable;
20 class ThreadList;
21 class MemoryWindow;
22 struct DbgAddr;
24 class DebuggerMainWnd : public KDockMainWindow, public DebuggerMainWndBase
26 Q_OBJECT
27 public:
28 DebuggerMainWnd(const char* name);
29 ~DebuggerMainWnd();
31 bool debugProgram(const QString& exe, QCString lang);
33 protected:
34 // session properties
35 virtual void saveProperties(KConfig*);
36 virtual void readProperties(KConfig*);
37 // settings
38 void saveSettings(KConfig*);
39 void restoreSettings(KConfig*);
41 // statusbar texts
42 void updateLineStatus(int lineNo); /* zero-based line number */
44 void initToolbar();
45 void initKAction();
47 // view windows
48 WinStack* m_filesWindow;
49 QListBox* m_btWindow;
50 ExprWnd* m_localVariables;
51 WatchWindow* m_watches;
52 RegisterView* m_registers;
53 BreakpointTable* m_bpTable;
54 TTYWindow* m_ttyWindow;
55 ThreadList* m_threads;
56 MemoryWindow* m_memoryWindow;
58 QTimer m_backTimer;
60 // recent execs in File menu
61 KRecentFilesAction* m_recentExecAction;
63 protected:
64 virtual void closeEvent(QCloseEvent* e);
65 virtual TTYWindow* ttyWindow();
66 virtual QString createOutputWindow();
68 KDockWidget* dockParent(QWidget* w);
69 bool isDockVisible(QWidget* w);
70 bool canChangeDockVisibility(QWidget* w);
71 void dockUpdateHelper(QString action, QWidget* w);
72 void fixDockConfig(KConfig* c, bool upgrade);
74 QString makeSourceFilter();
76 // to avoid flicker when the status bar is updated,
77 // we store the last string that we put there
78 QString m_lastActiveStatusText;
79 bool m_animRunning;
81 signals:
82 void setTabWidth(int tabWidth);
84 public slots:
85 virtual void updateUI();
86 virtual void updateLineItems();
87 void slotFileChanged();
88 void slotLineChanged();
89 void slotAddWatch();
90 void slotAddWatch(const QString& text);
91 void slotNewFileLoaded();
92 void slotNewStatusMsg();
93 void slotDebuggerStarting();
94 void slotToggleBreak(const QString&, int, const DbgAddr&, bool);
95 void slotEnaDisBreak(const QString&, int, const DbgAddr&);
96 void slotTermEmuExited();
97 void slotProgramStopped();
98 void slotBackTimer();
99 void slotRecentExec(const KURL& url);
100 void slotLocalsPopup(QListViewItem*, const QPoint& pt);
101 void slotLocalsToWatch();
102 void slotEditValue();
104 void slotFileOpen();
105 void slotFileQuit();
106 void slotFileExe();
107 void slotFileCore();
108 void slotFileGlobalSettings();
109 void slotFileProgSettings();
110 void slotViewToolbar();
111 void slotViewStatusbar();
112 void slotExecUntil();
113 void slotExecAttach();
114 void slotExecArgs();
115 void intoBackground();
116 void slotConfigureKeys();
119 #endif // DBGMAINWND_H