Merge branch 'maint'
[kdbg.git] / kdbg / prefdebugger.cpp
blobf47dd53adaa19501e4343fa5a73c53c4167071e3
1 /*
2 * Copyright Johannes Sixt
3 * This file is licensed under the GNU General Public License Version 2.
4 * See the file COPYING in the toplevel directory of the source directory.
5 */
7 #include <klocale.h> /* i18n */
8 #include <qlayout.h>
9 #include "prefdebugger.h"
11 PrefDebugger::PrefDebugger(QWidget* parent) :
12 QWidget(parent, "debugger"),
13 m_grid(this, 5, 2, 10),
14 m_defaultHint(this, "default_hint"),
15 m_debuggerCCppLabel(this, "debugger_label"),
16 m_debuggerCCpp(this, "debugger"),
17 m_terminalHint(this, "terminal_hint"),
18 m_terminalLabel(this, "terminal_label"),
19 m_terminal(this, "terminal")
21 m_defaultHint.setText(i18n("To revert to the default settings, clear the entries."));
22 m_defaultHint.setMinimumHeight(m_defaultHint.sizeHint().height());
23 m_grid.addWidget(&m_defaultHint, 0, 1);
25 m_debuggerCCppLabel.setText(i18n("How to invoke &GDB:"));
26 m_debuggerCCppLabel.setMinimumSize(m_debuggerCCppLabel.sizeHint());
27 m_debuggerCCppLabel.setBuddy(&m_debuggerCCpp);
28 m_debuggerCCpp.setMinimumSize(m_debuggerCCpp.sizeHint());
29 m_grid.addWidget(&m_debuggerCCppLabel, 1, 0);
30 m_grid.addWidget(&m_debuggerCCpp, 1, 1);
32 m_terminalHint.setText(i18n("%T will be replaced with a title string,\n"
33 "%C will be replaced by a Bourne shell script that\n"
34 "keeps the terminal window open."));
35 m_terminalHint.setMinimumHeight(m_terminalHint.sizeHint().height());
36 m_grid.addWidget(&m_terminalHint, 2, 1);
38 m_terminalLabel.setText(i18n("&Terminal for program output:"));
39 m_terminalLabel.setMinimumSize(m_terminalLabel.sizeHint());
40 m_terminalLabel.setBuddy(&m_terminal);
41 m_terminal.setMinimumSize(m_terminal.sizeHint());
42 m_grid.addWidget(&m_terminalLabel, 3, 0);
43 m_grid.addWidget(&m_terminal, 3, 1);
45 m_grid.setColStretch(1, 10);
46 // last (empty) row gets all the vertical stretch
47 m_grid.setRowStretch(4, 10);