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.
10 #include <qtextedit.h>
12 class QSocketNotifier
;
16 * This class is cortesy Judin Max <novaprint@mtu-net.ru>.
18 * The master side of the TTY is the emulator.
20 * The slave side is where a client process can write output and can read
21 * input. For this purpose, it must open the file (terminal device) whose
22 * name is returned by @ref slaveTTY for both reading and writing. To
23 * establish the stdin, stdout, and stderr channels the file descriptor
24 * obtained by this must be dup'd to file descriptors 0, 1, and 2, resp.
26 class STTY
: public QObject
33 QString
slaveTTY(){ return m_slavetty
; };
36 void outReceived(int);
39 void output(char* buffer
, int charlen
);
44 QSocketNotifier
* m_outNotifier
;
49 class TTYWindow
: public QTextEdit
53 TTYWindow(QWidget
* parent
, const char* name
);
61 virtual QPopupMenu
* createPopupMenu(const QPoint
& pos
);
62 int m_hPos
; //!< tracks horizontal cursor position
65 void slotAppend(char* buffer
, int count
);