Mercurial > octave
annotate libqterminal/QTerminal.h @ 15648:d49e99269c0b
Renamed SessionView in TerminalView and correct proxy focus for QTerminal.
author | Jacob Dawid <jacob.dawid@googlemail.com> |
---|---|
date | Fri, 27 Jan 2012 23:44:07 +0100 |
parents | a044a259c423 |
children | c22fa57226b2 |
rev | line source |
---|---|
15631 | 1 /* Copyright (C) 2008 e_k (e_k@users.sourceforge.net) |
15647
a044a259c423
Renamed SessionModel in TerminalModel.
Jacob Dawid <jacob.dawid@googlemail.com>
parents:
15646
diff
changeset
|
2 Copyright (C) 2012 Jacob Dawid <jacob.dawid@googlemail.com> |
a044a259c423
Renamed SessionModel in TerminalModel.
Jacob Dawid <jacob.dawid@googlemail.com>
parents:
15646
diff
changeset
|
3 |
15631 | 4 This library is free software; you can redistribute it and/or |
5 modify it under the terms of the GNU Library General Public | |
6 License as published by the Free Software Foundation; either | |
7 version 2 of the License, or (at your option) any later version. | |
8 | |
9 This library is distributed in the hope that it will be useful, | |
10 but WITHOUT ANY WARRANTY; without even the implied warranty of | |
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
12 Library General Public License for more details. | |
13 | |
14 You should have received a copy of the GNU Library General Public License | |
15 along with this library; see the file COPYING.LIB. If not, write to | |
16 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | |
17 Boston, MA 02110-1301, USA. | |
18 */ | |
19 | |
20 | |
15633
36110925f67b
Simplified code.
Jacob Dawid <jacob.dawid@googlemail.com>
parents:
15631
diff
changeset
|
21 #ifndef Q_TERMINAL |
36110925f67b
Simplified code.
Jacob Dawid <jacob.dawid@googlemail.com>
parents:
15631
diff
changeset
|
22 #define Q_TERMINAL |
15631 | 23 |
24 #include <QtGui> | |
15647
a044a259c423
Renamed SessionModel in TerminalModel.
Jacob Dawid <jacob.dawid@googlemail.com>
parents:
15646
diff
changeset
|
25 #include "TerminalModel.h" |
15648
d49e99269c0b
Renamed SessionView in TerminalView and correct proxy focus for QTerminal.
Jacob Dawid <jacob.dawid@googlemail.com>
parents:
15647
diff
changeset
|
26 #include "TerminalView.h" |
15631 | 27 |
28 class QTerminal : public QWidget | |
29 { | |
30 Q_OBJECT | |
31 public: | |
15633
36110925f67b
Simplified code.
Jacob Dawid <jacob.dawid@googlemail.com>
parents:
15631
diff
changeset
|
32 QTerminal(QWidget *parent = 0); |
15631 | 33 ~QTerminal(); |
34 | |
15633
36110925f67b
Simplified code.
Jacob Dawid <jacob.dawid@googlemail.com>
parents:
15631
diff
changeset
|
35 void setTerminalFont(QFont &font); |
15631 | 36 void setArgs(QStringList &args); |
37 void setTextCodec(QTextCodec *codec); | |
38 void setSize(int h, int v); | |
15633
36110925f67b
Simplified code.
Jacob Dawid <jacob.dawid@googlemail.com>
parents:
15631
diff
changeset
|
39 void setHistorySize(int lines); |
15631 | 40 void setReadOnly(bool); |
41 | |
42 signals: | |
43 void finished(); | |
44 | |
45 public slots: | |
46 void copyClipboard(); | |
47 void pasteClipboard(); | |
48 | |
15646
f570d3baa6fb
Removed unused code.
Jacob Dawid <jacob.dawid@googlemail.com>
parents:
15639
diff
changeset
|
49 protected: |
f570d3baa6fb
Removed unused code.
Jacob Dawid <jacob.dawid@googlemail.com>
parents:
15639
diff
changeset
|
50 void focusInEvent(QFocusEvent *focusEvent); |
15631 | 51 virtual void resizeEvent(QResizeEvent *); |
52 | |
53 protected slots: | |
54 void sessionFinished(); | |
55 | |
56 private: | |
15633
36110925f67b
Simplified code.
Jacob Dawid <jacob.dawid@googlemail.com>
parents:
15631
diff
changeset
|
57 void init(); |
15648
d49e99269c0b
Renamed SessionView in TerminalView and correct proxy focus for QTerminal.
Jacob Dawid <jacob.dawid@googlemail.com>
parents:
15647
diff
changeset
|
58 TerminalView *m_sessionView; |
15647
a044a259c423
Renamed SessionModel in TerminalModel.
Jacob Dawid <jacob.dawid@googlemail.com>
parents:
15646
diff
changeset
|
59 TerminalModel *m_sessionModel; |
15631 | 60 }; |
61 | |
15633
36110925f67b
Simplified code.
Jacob Dawid <jacob.dawid@googlemail.com>
parents:
15631
diff
changeset
|
62 #endif // Q_TERMINAL |