… | |
… | |
93 | #ifndef STDIN_FILENO |
93 | #ifndef STDIN_FILENO |
94 | # define STDIN_FILENO 0 |
94 | # define STDIN_FILENO 0 |
95 | # define STDOUT_FILENO 1 |
95 | # define STDOUT_FILENO 1 |
96 | # define STDERR_FILENO 2 |
96 | # define STDERR_FILENO 2 |
97 | #endif |
97 | #endif |
|
|
98 | |
|
|
99 | enum rxvt_privaction { IGNORE = 'i', SAVE = 's', RESTORE = 'r' };//TODO |
98 | |
100 | |
99 | /* |
101 | /* |
100 | ***************************************************************************** |
102 | ***************************************************************************** |
101 | * PROTOTYPES |
103 | * PROTOTYPES |
102 | ***************************************************************************** |
104 | ***************************************************************************** |
… | |
… | |
171 | typedef struct { |
173 | typedef struct { |
172 | short w, h, x, y; |
174 | short w, h, x, y; |
173 | Pixmap pixmap; |
175 | Pixmap pixmap; |
174 | } bgPixmap_t; |
176 | } bgPixmap_t; |
175 | #endif |
177 | #endif |
|
|
178 | |
|
|
179 | struct rxvt_ptytty { |
|
|
180 | int pty; // pty file descriptor; connected to rxvt |
|
|
181 | int tty; // tty file descriptor; connected to child |
|
|
182 | |
|
|
183 | virtual ~rxvt_ptytty () |
|
|
184 | { |
|
|
185 | // |
|
|
186 | } |
|
|
187 | |
|
|
188 | virtual bool get () = 0; |
|
|
189 | |
|
|
190 | virtual void login (int cmd_pid, bool login_shell, const char *hostname) = 0; |
|
|
191 | virtual void logout () = 0; |
|
|
192 | |
|
|
193 | void close_tty (); |
|
|
194 | |
|
|
195 | bool make_controlling_tty (); |
|
|
196 | void set_utf8_mode (bool on); |
|
|
197 | }; |
|
|
198 | |
|
|
199 | // a "factory" *g* |
|
|
200 | rxvt_ptytty *rxvt_new_ptytty (); |
176 | |
201 | |
177 | /* |
202 | /* |
178 | * the 'essential' information for reporting Mouse Events |
203 | * the 'essential' information for reporting Mouse Events |
179 | * pared down from XButtonEvent |
204 | * pared down from XButtonEvent |
180 | */ |
205 | */ |
… | |
… | |
1122 | const char *rs[NUM_RESOURCES]; |
1147 | const char *rs[NUM_RESOURCES]; |
1123 | /* command input buffering */ |
1148 | /* command input buffering */ |
1124 | char *cmdbuf_ptr, *cmdbuf_endp; |
1149 | char *cmdbuf_ptr, *cmdbuf_endp; |
1125 | char cmdbuf_base[CBUFSIZ]; |
1150 | char cmdbuf_base[CBUFSIZ]; |
1126 | |
1151 | |
1127 | rxvt_ptytty pty; |
1152 | rxvt_ptytty *pty; |
1128 | rxvt_session session; |
|
|
1129 | |
1153 | |
1130 | rxvt_salloc *talloc; // text line allocator |
1154 | rxvt_salloc *talloc; // text line allocator |
1131 | rxvt_salloc *ralloc; // rend line allocator |
1155 | rxvt_salloc *ralloc; // rend line allocator |
1132 | |
1156 | |
1133 | static vector<rxvt_term *> termlist; // a vector of all running rxvt_term's |
1157 | static vector<rxvt_term *> termlist; // a vector of all running rxvt_term's |