annotate README.multi-tty @ 53238:7a619020ecd2

Small change in README.multi-tty git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-14
author Karoly Lorentey <lorentey@elte.hu>
date Sat, 27 Dec 2003 14:24:02 +0000
parents 4f33c6fc9a1f
children db645482d6bc
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
53226
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
1 -*- coding: utf-8; -*-
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
2 GOAL
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
3 ----
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
4
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
5 The ultimate goal of this branch is to implement support for opening
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
6 multiple, different tty devices and simultaneous X and tty frames from
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
7 a single Emacs session.
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
8
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
9 WHO IS DOING IT
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
10 ---------------
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
11
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
12 I'm Károly Lőrentey. My address: lorentey@elte.hu.
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
13
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
14 Patches or suggestions are welcome!
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
15
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
16 Retrieving the latest version of the branch:
53228
c5b253fd2504 Added a pointer to my archive to README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53226
diff changeset
17
c5b253fd2504 Added a pointer to my archive to README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53226
diff changeset
18 tla register-archive lorentey@elte.hu--2004 http://lorentey.web.elte.hu/arch/2004/
c5b253fd2504 Added a pointer to my archive to README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53226
diff changeset
19 tla get lorentey@elte.hu--2004/emacs--multi-tty--0 <directory>
c5b253fd2504 Added a pointer to my archive to README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53226
diff changeset
20
c5b253fd2504 Added a pointer to my archive to README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53226
diff changeset
21 (I use tla 1.1.)
c5b253fd2504 Added a pointer to my archive to README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53226
diff changeset
22
53226
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
23
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
24 STATUS
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
25 ------
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
26
53234
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
27 Basic multi-tty support is there; there are some rough edges, but it
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
28 already seems to be usable. Emacsclient has been extended to support
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
29 opening a new terminal frame.
53226
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
30
53235
1bf332eccca1 Added compilation instructions to README.multi-tty.
Karoly Lorentey <lorentey@elte.hu>
parents: 53234
diff changeset
31 To try it out, compile Emacs with the following commands
1bf332eccca1 Added compilation instructions to README.multi-tty.
Karoly Lorentey <lorentey@elte.hu>
parents: 53234
diff changeset
32
1bf332eccca1 Added compilation instructions to README.multi-tty.
Karoly Lorentey <lorentey@elte.hu>
parents: 53234
diff changeset
33 mkdir +build
1bf332eccca1 Added compilation instructions to README.multi-tty.
Karoly Lorentey <lorentey@elte.hu>
parents: 53234
diff changeset
34 cd +build
1bf332eccca1 Added compilation instructions to README.multi-tty.
Karoly Lorentey <lorentey@elte.hu>
parents: 53234
diff changeset
35 ../configure --with-x-toolkit=no --without-x
1bf332eccca1 Added compilation instructions to README.multi-tty.
Karoly Lorentey <lorentey@elte.hu>
parents: 53234
diff changeset
36 make bootstrap
1bf332eccca1 Added compilation instructions to README.multi-tty.
Karoly Lorentey <lorentey@elte.hu>
parents: 53234
diff changeset
37
1bf332eccca1 Added compilation instructions to README.multi-tty.
Karoly Lorentey <lorentey@elte.hu>
parents: 53234
diff changeset
38 then start up the emacs server (src/emacs, M-x server-start), and then
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
39 (from a shell prompt on another terminal) start emacsclient with
53226
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
40
53235
1bf332eccca1 Added compilation instructions to README.multi-tty.
Karoly Lorentey <lorentey@elte.hu>
parents: 53234
diff changeset
41 lib-src/emacsclient -h
53229
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
42
53234
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
43 You'll hopefully have two fully working frames on separate terminals.
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
44 If you exit emacs, both terminals should be restored to their previous
53237
4f33c6fc9a1f README.multi-tty updates.
Karoly Lorentey <lorentey@elte.hu>
parents: 53236
diff changeset
45 states. You can close the newly opened frame and return to the shell
53238
7a619020ecd2 Small change in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53237
diff changeset
46 without exiting Emacs by pressing C-x 5 0, i.e., delete-frame.
53234
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
47
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
48 X, Mac, Windows and DOS support is broken, probably doesn't even
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
49 compile -- this will be solved later.
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
50
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
51 Tested under GNU/Linux only.
53226
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
52
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
53 NEWS
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
54 ----
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
55
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
56 For the NEWS file:
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
57
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
58 ** Support for multiple terminal devices has been added. You can
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
59 specify a terminal device (`tty' parameter) and a terminal type
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
60 (`tty-type' parameter) to `make-terminal-frame'. `tty' must be a
53234
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
61 terminal device created by the updated emacsclient, or there will
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
62 be problems with terminal input and window resizes. (The kernel
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
63 notifies processes about pending input or terminal resizes only on
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
64 the controlling terminal, so we need emacsclient to sit on the real
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
65 terminal device, create SIGIO signals upon terminal input, and
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
66 forward SIGWINCH signals to us.)
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
67
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
68 You can test for the presence of multiple terminal support by
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
69 testing for the `multi-tty' feature.
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
70
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
71 ** A make-frame-on-tty function has been added to make it easier to
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
72 create frames on new terminals.
53226
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
73
53229
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
74 ** Emacsclient has been extended to support opening a new terminal
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
75 frame.
53226
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
76
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
77 CHANGELOG
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
78 ---------
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
79
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
80 See arch logs.
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
81
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
82
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
83 DIARY OF CHANGES
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
84 ----------------
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
85
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
86 (ex-TODO items with explanations.)
53226
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
87
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
88 -- Introduce a new abstraction for terminal devices.
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
89
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
90 (Done, see struct tty_output. The abstraction is not yet
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
91 complete.)
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
92
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
93 -- Change the bootstrap procedure to initialize tty_list.
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
94
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
95 (Done, but needs review.)
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
96
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
97 -- Change make-terminal-frame to support specifying another tty.
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
98
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
99 (Done, new frame parameters: `tty' and `tty-type'.)
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
100
53229
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
101 -- Implement support for reading from multiple terminals.
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
102
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
103 (Done, read_avail_input tries to read from each terminal, until one
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
104 succeeds. MULTIKBOARD is not used. Secondary terminals don't send
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
105 SIGIO!)
53229
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
106
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
107 -- other-frame should cycle through the frames on the `current'
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
108 terminal only.
53229
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
109
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
110 (Done, by trivially modifiying next_frame and prev_frame.)
53229
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
111
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
112 -- Support different terminal sizes.
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
113
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
114 (Done, no problem.)
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
115
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
116 -- Make sure terminal resizes are handled gracefully. (Could be
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
117 problematic.)
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
118
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
119 (Done. We don't get automatic SIGWINCH for additional ttys,
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
120 though.)
53229
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
121
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
122 -- Extend emacsclient to automatically open a new tty when it connects
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
123 to Emacs.
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
124
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
125 (Done. It's an ugly hack, needs more work.)
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
126
53234
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
127 -- Redisplay must refresh the topmost frame on *all* terminals, not
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
128 just the initial terminal.
53229
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
129
53234
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
130 (Done, but introduced an ugly redisplay problems. Ugh.)
53229
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
131
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
132 -- Fix redisplay problems.
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
133
53234
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
134 (Done; it turned out that the entire Wcm structure must be moved
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
135 inside tty_output. Why didn't I catch this earlier?)
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
136
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
137 -- Provide a way for emacsclient to tell Emacs that the tty has been
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
138 resized.
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
139
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
140 (Done, simply forward the SIGWINCH signal.)
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
141
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
142 -- Each keypress should automatically select the frame corresponding
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
143 to the terminal that it was coming from. This means that Emacs
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
144 must know from which terminal the last keyboard event came from.
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
145
53234
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
146 (Done, it was quite simple, the input event system already
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
147 supported multiple frames.)
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
148
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
149 -- Fix SIGIO issue with secondary terminals.
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
150
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
151 (Done, emacsclient signals Emacs after writing to the proxy pseudo
53234
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
152 terminal. Note that this means that multi-tty does not work with
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
153 raw ttys!)
53233
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
154
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
155 -- Make make-terminal-frame look up the `tty' and `tty-type' frame
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
156 parameters from the currently selected terminal before the global
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
157 default.
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
158
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
159 (Done.)
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
160
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
161 -- Put all cached terminal escape sequences into struct tty_output.
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
162 Currently, they are still stored in global variables, so we don't
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
163 really support multiple terminal types.
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
164
53234
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
165 (Done. It was not fun.)
53233
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
166
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
167 -- Implement sane error handling after initialization. (Currently
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
168 emacs exits if you specify a bad terminal type.) The helpful error
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
169 messages must still be provided when Emacs starts.
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
170
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
171 (Done.)
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
172
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
173 -- Implement terminal deletion, i.e., deleting local frames, closing
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
174 the tty device and restoring its previous state without exiting
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
175 Emacs.
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
176
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
177 (Done, but at the moment only called when an error happens during
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
178 initialization. There is a memory corruption error around this
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
179 somewhere.)
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
180
53236
e77dcb66ec84 Implemented automatic deletion of terminals.
Karoly Lorentey <lorentey@elte.hu>
parents: 53235
diff changeset
181 -- Implement automatic deletion of terminals when the last frame on
e77dcb66ec84 Implemented automatic deletion of terminals.
Karoly Lorentey <lorentey@elte.hu>
parents: 53235
diff changeset
182 that terminal is closed.
e77dcb66ec84 Implemented automatic deletion of terminals.
Karoly Lorentey <lorentey@elte.hu>
parents: 53235
diff changeset
183
e77dcb66ec84 Implemented automatic deletion of terminals.
Karoly Lorentey <lorentey@elte.hu>
parents: 53235
diff changeset
184 (Done.)
e77dcb66ec84 Implemented automatic deletion of terminals.
Karoly Lorentey <lorentey@elte.hu>
parents: 53235
diff changeset
185
53233
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
186
53226
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
187 THINGS TO DO
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
188 ------------
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
189
53233
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
190 ** Fix mysterious memory corruption error with tty deletion. To
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
191 trigger it, try the following shell command:
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
192
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
193 while true; do TERM=no-such-terminal-definition emacsclient -h; done
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
194
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
195 Emacs usually dumps core after a few dozen iterations. (The bug
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
196 seems to be related to the xfree()ing or bzero()ing of
53234
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
197 tty_output.Wcm or some other tty_output part. Maybe there are
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
198 outside references to struct Wcm? Why were these vars collected
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
199 into a struct before multi-tty support?)
53233
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
200
53234
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
201 The bug does not seem to happen if the error occurs before terminal
53233
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
202 initialization or if I comment out all xfree()s in delete_frame.
53234
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
203 Update: yes it does, although it is much rarer. Or maybe it's
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
204 another bug.
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
205
53236
e77dcb66ec84 Implemented automatic deletion of terminals.
Karoly Lorentey <lorentey@elte.hu>
parents: 53235
diff changeset
206 ** Change emacsclient/server.el to support the -h argument better,
e77dcb66ec84 Implemented automatic deletion of terminals.
Karoly Lorentey <lorentey@elte.hu>
parents: 53235
diff changeset
207 i.e. automatically close the socket when the frame is closed.
53229
33c3c7c16e13 lib-src/emacsclient.c: Implemented --here option (open a new Emacs tty). Needs more work.
Karoly Lorentey <lorentey@elte.hu>
parents: 53228
diff changeset
208
53236
e77dcb66ec84 Implemented automatic deletion of terminals.
Karoly Lorentey <lorentey@elte.hu>
parents: 53235
diff changeset
209 ** Export delete_tty to the Lisp environment, for emacsclient.
e77dcb66ec84 Implemented automatic deletion of terminals.
Karoly Lorentey <lorentey@elte.hu>
parents: 53235
diff changeset
210
53237
4f33c6fc9a1f README.multi-tty updates.
Karoly Lorentey <lorentey@elte.hu>
parents: 53236
diff changeset
211 ** Restore tty screen after closing the terminal.
4f33c6fc9a1f README.multi-tty updates.
Karoly Lorentey <lorentey@elte.hu>
parents: 53236
diff changeset
212
4f33c6fc9a1f README.multi-tty updates.
Karoly Lorentey <lorentey@elte.hu>
parents: 53236
diff changeset
213 ** 'TERM=dumb src/emacs' does not restore the terminal state.
4f33c6fc9a1f README.multi-tty updates.
Karoly Lorentey <lorentey@elte.hu>
parents: 53236
diff changeset
214
53236
e77dcb66ec84 Implemented automatic deletion of terminals.
Karoly Lorentey <lorentey@elte.hu>
parents: 53235
diff changeset
215 ** C-g should work on secondary terminals.
53226
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
216
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
217 ** Make parts of struct tty_output accessible from Lisp. The device
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
218 name and the type is sufficient.
53226
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
219
53237
4f33c6fc9a1f README.multi-tty updates.
Karoly Lorentey <lorentey@elte.hu>
parents: 53236
diff changeset
220 ** Find out why does Emacs abort when it wants to close its
4f33c6fc9a1f README.multi-tty updates.
Karoly Lorentey <lorentey@elte.hu>
parents: 53236
diff changeset
221 controlling tty.
4f33c6fc9a1f README.multi-tty updates.
Karoly Lorentey <lorentey@elte.hu>
parents: 53236
diff changeset
222
53226
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
223 ** Implement support for starting an interactive Emacs session without
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
224 an initial frame. (The user would connect to it and open frames
53233
fe9b37bee5f7 Fully eliminated global tty state variables.
Karoly Lorentey <lorentey@elte.hu>
parents: 53232
diff changeset
225 later, with emacsclient.) Not necessarily a good idea.
53226
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
226
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
227 ** Support raw secondary terminals. (This one is tricky, SIGIO works
53234
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
228 only on the controlling terminal. The emacsclient solution works
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
229 nicely, so this is not that important anyway.)
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
230
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
231 ** What does interrupt_input do? I tried to disable it for raw
53234
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
232 secondary tty support, but it does not seem to do anything useful.
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
233
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
234 ** Move optimalization parameters (costs) from union output_data to
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
235 a backend-neutral per-device structure.
f3b94bd26d21 Cosmetic changes in README.multi-tty
Karoly Lorentey <lorentey@elte.hu>
parents: 53233
diff changeset
236
53237
4f33c6fc9a1f README.multi-tty updates.
Karoly Lorentey <lorentey@elte.hu>
parents: 53236
diff changeset
237 ** Find out the best way to support suspending Emacs with multiple
4f33c6fc9a1f README.multi-tty updates.
Karoly Lorentey <lorentey@elte.hu>
parents: 53236
diff changeset
238 ttys.
4f33c6fc9a1f README.multi-tty updates.
Karoly Lorentey <lorentey@elte.hu>
parents: 53236
diff changeset
239
4f33c6fc9a1f README.multi-tty updates.
Karoly Lorentey <lorentey@elte.hu>
parents: 53236
diff changeset
240 ** Do tty output through term_hooks, like all other display backends.
53232
22aaf1e5fbe6 Full support for multiple terminal I/O (with some rough edges).
Karoly Lorentey <lorentey@elte.hu>
parents: 53229
diff changeset
241
53226
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
242 ** Fix X support.
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
243
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
244 ** Allow simultaneous X and tty frames.
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
245
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
246 ** Fix Mac support (I can't do this myself).
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
247
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
248 ** Fix W32 support (I can't do this myself).
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
249
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
250 ** Fix DOS support (I can't do this myself).
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
251
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
252
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
253
dd3018b4785b Implemented multiple tty support.
Karoly Lorentey <lorentey@elte.hu>
parents:
diff changeset
254 ;;; arch-tag: 8da1619e-2e79-41a8-9ac9-a0485daad17d