Implemented suspending of emacsclient frames.
[bpt/emacs.git] / README.multi-tty
1 -*- coding: utf-8; mode: text; -*-
2 GOAL
3 ----
4
5 The goal of this branch is to implement support for opening multiple,
6 different tty devices and simultaneous X and tty frames from a single
7 Emacs session.
8
9 Some use cases:
10 Emacs is notoriously slow at startup, so most people use another
11 editor or emacsclient for quick editing jobs from the console.
12 Unfortunately, emacsclient was very awkward to use, because it did not
13 support opening a new Emacs frame on the current virtual console.
14 Now, with multi-tty support, it can do that. (Emacsclient starts up
15 faster than vi!)
16
17 Some Gnus users (including me) run Gnus in an X frame in its own Emacs
18 instance, which they typically leave running for weeks. It would be
19 nice if they could connect to this instance from a remote ssh session
20 and check their messages without opening a remote X frame or resorting
21 to gnus-slave.
22
23 WHO IS DOING IT
24 ---------------
25
26 I'm Károly Lőrentey. My address: lorentey@elte.hu.
27
28 Comments, bug reports, suggestions and patches are welcome!
29
30 Retrieving the latest version of the branch:
31
32 tla register-archive lorentey@elte.hu--2004 http://lorentey.web.elte.hu/arch/2004/
33 tla get lorentey@elte.hu--2004/emacs--multi-tty <directory>
34
35 (I use a recent arch development snapshot, but any of the released
36 versions of arch will do fine, I think.)
37
38 If you don't have arch, the branch has a homepage from which you can
39 download conventional patches against Emacs CVS HEAD:
40
41 http://lorentey.web.elte.hu/project/emacs.html
42
43 If you want to be notified of new revisions, sign up to the
44 multi-tty@listbox.elte.hu mailing list by visiting the
45 below homepage and following its instructions.
46
47 https://listbox.elte.hu/mailman/listinfo/multi-tty
48
49 Please note that the multi-tty mailing list is read-only, and is
50 reserved for automatic commit messages. Discussion about the branch
51 and bug reports should be sent directly to me (lorentey@elte.hu), or
52 to the emacs-devel@gnu.org mailing list. (I hope to merge my branch
53 into CVS HEAD reasonably soon, so I don't want to set up an elaborate
54 development infrastructure for the multi-tty branch.)
55
56 STATUS
57 ------
58
59 The branch is now very stable and almost full-featured. I hope the
60 major problems were fixed. (It still needs testing on other
61 architectures, though.) Both multiple tty device support and
62 simultaneous X and tty frame support works fine. Emacsclient has been
63 extended to support opening new tty and X frames. It has been changed
64 open new Emacs frames by default.
65
66 Please let me know if you find any bugs in this branch.
67
68 HOW TO COMPILE AND TEST
69 -----------------------
70
71 To try out the multi-tty branch, compile and run the multi-tty branch
72 with the following commands:
73
74 mkdir +build
75 cd +build
76 ../configure <your favourite options>
77 make bootstrap
78 src/emacs -nw # You can also try without -nw
79 M-x server-start
80
81 and then (from a shell prompt on another terminal) start emacsclient
82 with
83 lib-src/emacsclient /optional/file/names...
84 or
85 lib-src/emacsclient -t /optional/file/names...
86
87 You'll hopefully have two fully working, independent frames on
88 separate terminals. The new frame is closed automatically when you
89 have finished editing the specified files (C-x #), but delete-frame
90 (C-x 5 0) also works. Of course, you can create frames on more than
91 two tty devices.
92
93 Creating new frames on the same tty with C-x 5 2 works, and they
94 behave the same way as in previous Emacs versions. If you exit emacs,
95 all terminals should be restored to their previous states.
96
97 This is work in progress, and probably full of bugs. You should
98 always run emacs from gdb, so that you'll have a live instance to
99 debug if something goes wrong. Please send me your bug reports.
100
101 I think the best way to use the new Emacs is to have it running inside
102 a disconnected GNU screen session, and always use emacsclient for
103 normal work. This way not a single keystroke of your work will be
104 lost if the display device that you are using crashes, or the network
105 connection times out, or whatever. As long as the server that runs
106 your Emacs remains up, all your buffers remain exactly as they were
107 before the crash, and you can continue working as if nothing had
108 happened. (I had an extremely unstable X server for some time while I
109 was developing these patches, and running Emacs this way has saved me
110 a number of M-x recover-session invocations.)
111
112 (I am thinking about introducing a --daemon option to get rid of the
113 above screen dependency.)
114
115 Problems:
116
117 * Suspending Emacs is disabled if there are multiple tty
118 devices. Also, there is no way to suspend emacsclient. This
119 will be fixed.
120
121 * Mac, Windows and DOS support is broken, probably doesn't
122 even compile -- this will be solved later.
123
124 * Only tested on my GNU/Linux box and on Solaris 8.
125
126 NEWS
127 ----
128
129 For the NEWS file:
130
131 ** Support for multiple terminal devices has been added.
132
133 *** You can specify a terminal device (`tty' parameter) and a terminal
134 type (`tty-type' parameter) to `make-terminal-frame'.
135
136 *** You can test for the presence of multiple terminal support by
137 testing for the `multi-tty' feature.
138
139 *** Emacsclient has been extended to support opening a new terminal
140 frame. Its behaviour has been changed to open a new Emacs frame by
141 default. Use the -c option to get the old behavior of opening
142 files in the currently selected Emacs frame.
143
144 *** A make-frame-on-tty function has been added to make it easier to
145 create frames on new terminals.
146
147 *** New functions: frame-tty-name, frame-tty-type for accessing
148 terminal parameters, and delete-tty for closing the terminal
149 device.
150
151 *** talk.el has been extended for multiple tty support.
152
153
154 ** Support for simultaneous graphical and terminal frames has been
155 added.
156
157 *** The function `make-frame-on-display' now works during a terminal
158 session, and `make-frame-on-tty' works during a graphical session.
159
160 *** The `window-system' variable has been made frame-local.
161
162 *** The new `initial-window-system' variable contains the
163 `window-system' value for the first frame.
164
165 THANKS
166 ------
167
168 The following is an (incomplete) list of people who have contributed
169 to the project by testing, bug reports, and suggestions. Thanks!
170
171 Robert J. Chassel <bob at rattlesnake dot com>
172 Romain Francoise <romain at orebokech dot com>
173 Ami Fischman <ami at fischman dot org>
174 Istvan Marko <mi-mtty ar kismala dot com>
175 Dan Nicolaescu <dann at ics dot uci dot edu>
176 Mark Plaksin <happy at mcplaksin dot org>
177
178 Richard Stallman was kind enough to review my patches.
179
180 CHANGELOG
181 ---------
182
183 See arch logs.
184
185 THINGS TO DO
186 ------------
187
188 ** There is a flicker during the startup of `emacs -nw'; it's as if
189 the terminal is initialized, reset and then initialialized again.
190 Debug this. (Hint: narrow_foreground_group is called twice during
191 startup.)
192
193 ** Dan Nicolaescu suggests that -nw should be added as an alias for -t
194 in emacsclient. Good idea. (Alas, implementing this is not
195 trivial, getopt_long does not seem to support two-letter ``short''
196 options.)
197
198 ** Mark Plaksin suggests that emacsclient should accept the same
199 X-related command-line arguments as Emacs. Most of the X-related
200 argument-handling is done in Lisp, so this should be quite easy to
201 implement.
202
203 ** Make `struct display' accessible to Lisp programs. Accessor functions:
204
205 (displayp OBJECT): Returns t if OBJECT is a display.
206
207 (selected-display): Returns the display object of the selected frame.
208
209 (frame-display FRAME): Returns the display object of FRAME.
210
211 (display-frames DISPLAY): Returns a list of frames on DISPLAY.
212
213 (display-type DISPLAY): Returns the type of DISPLAY, as a
214 symbol. (See `framep'.)
215
216 (display-device DISPLAY): Returns the name of the device that
217 DISPLAY uses, as a string. (E.g: "/dev/pts/16", or
218 ":0.0")
219
220 See next issue why this is necessary.
221
222 ** The following needs to be supported:
223
224 $ emacsclient -t
225 C-z
226 $ bg
227 $ emacsclient -t
228 (This fails now.)
229
230 The cleanest way to solve this is to allow multiple displays on the
231 same terminal device; each new emacsclient process should create
232 its own display. As displays are currently identified by their
233 device names, this is not possible until struct display becomes
234 accessible as a Lisp-level object.
235
236 ** Add an elaborate mechanism for display-local variables. (There are
237 already a few of these; search for `terminal-local' in the Elisp
238 manual.)
239
240 ** Very strange bug: visible-bell does not work on secondary
241 terminals in xterm and konsole. The screen does flicker a bit,
242 but it's so quick it isn't noticable.
243
244 ** Clean up the frame-local variable system. I think it's ugly and
245 error-prone. But maybe I just haven't yet fully understood it.
246
247 ** Move baud_rate to struct display.
248
249 ** Implement support for starting an interactive Emacs session without
250 an initial frame. (The user would connect to it and open frames
251 later, with emacsclient.)
252
253 ** Fix Mac support (I can't do this myself). Note that the current
254 state of Mac-specific source files in the multi-tty tree are not
255 useful; before starting work on Mac support, revert to pristine,
256 pre-multi-tty versions.
257
258 ** Fix W32 support (I can't do this myself). Note that the current
259 state of W32-specific source files in the multi-tty tree are not
260 useful; before starting work on W32 support, revert to pristine,
261 pre-multi-tty versions.
262
263 ** Fix DOS support (I can't do this myself). Note that the current
264 state of DOS-specific source files in the multi-tty tree are not
265 useful; before starting work on DOS support, revert to pristine,
266 pre-multi-tty versions.
267
268 ** Do a grep on XXX and ?? for more issues.
269
270 ** Understand Emacs's low-level input system (it seems complicated) :-)
271 What does interrupt_input do? I tried to disable it for raw
272 secondary tty support, but it does not seem to do anything useful.
273 (Update: Look again. X unconditionally enables this, maybe that's
274 why raw terminal support is broken again. I really do need to
275 understand input.)
276
277 ** Maybe standard-display-table should be display-local.
278
279 DIARY OF CHANGES
280 ----------------
281
282 (ex-TODO items with explanations.)
283
284 -- Introduce a new struct for terminal devices.
285
286 (Done, see struct tty_output. The list of members is not yet
287 complete.)
288
289 -- Change the bootstrap procedure to initialize tty_list.
290
291 (Done, but needs review.)
292
293 -- Change make-terminal-frame to support specifying another tty.
294
295 (Done, new frame parameters: `tty' and `tty-type'.)
296
297 -- Implement support for reading from multiple terminals.
298
299 (Done, read_avail_input tries to read from each terminal, until one
300 succeeds. MULTI_KBOARD is not used. Secondary terminals don't send
301 SIGIO!)
302
303 (Update: They do, now.)
304
305 (Update2: After enabling X, they don't.)
306
307 -- other-frame should cycle through the frames on the `current'
308 terminal only.
309
310 (Done, by trivially modifiying next_frame and prev_frame.)
311
312 -- Support different terminal sizes.
313
314 (Done, no problem.)
315
316 -- Make sure terminal resizes are handled gracefully. (Could be
317 problematic.)
318
319 (Done. We don't get automatic SIGWINCH for additional ttys,
320 though.)
321
322 -- Extend emacsclient to automatically open a new tty when it connects
323 to Emacs.
324
325 (Done. It's an ugly hack, needs more work.)
326
327 -- Redisplay must refresh the topmost frame on *all* terminals, not
328 just the initial terminal.
329
330 (Done, but introduced an ugly redisplay problems. Ugh.)
331
332 -- Fix redisplay problems.
333
334 (Done; it turned out that the entire Wcm structure must be moved
335 inside tty_output. Why didn't I catch this earlier?)
336
337 -- Provide a way for emacsclient to tell Emacs that the tty has been
338 resized.
339
340 (Done, simply forward the SIGWINCH signal.)
341
342 -- Each keypress should automatically select the frame corresponding
343 to the terminal that it was coming from. This means that Emacs
344 must know from which terminal the last keyboard event came from.
345
346 (Done, it was quite simple, the input event system already
347 supported multiple frames.)
348
349 -- Fix SIGIO issue with secondary terminals.
350
351 (Done, emacsclient signals Emacs after writing to the proxy pseudo
352 terminal. Note that this means that multi-tty does not work with
353 raw ttys!)
354
355 (Update: This is bullshit. There is a read_input_waiting function,
356 extend that somehow.)
357
358 (Update of update: The first update was not right either, extending
359 read_input_waiting was not necessary. Secondary ttys do seem to
360 send signals on input.)
361
362 (Update^3: Not any more.)
363
364 -- Make make-terminal-frame look up the `tty' and `tty-type' frame
365 parameters from the currently selected terminal before the global
366 default.
367
368 (Done.)
369
370 -- Put all cached terminal escape sequences into struct tty_output.
371 Currently, they are still stored in global variables, so we don't
372 really support multiple terminal types.
373
374 (Done. It was not fun.)
375
376 -- Implement sane error handling after initialization. (Currently
377 emacs exits if you specify a bad terminal type.) The helpful error
378 messages must still be provided when Emacs starts.
379
380 (Done.)
381
382 -- Implement terminal deletion, i.e., deleting local frames, closing
383 the tty device and restoring its previous state without exiting
384 Emacs.
385
386 (Done, but at the moment only called when an error happens during
387 initialization. There is a memory corruption error around this
388 somewhere.) (Update: now it is fully enabled.)
389
390 -- Implement automatic deletion of terminals when the last frame on
391 that terminal is closed.
392
393 (Done.)
394
395 -- Restore tty screen after closing the terminal.
396
397 (Done, we do the same as Emacs 21.2 for all terminals.)
398
399 -- 'TERM=dumb src/emacs' does not restore the terminal state.
400
401 (Done.)
402
403 -- C-g should work on secondary terminals.
404
405 (Done, but the binding is not configurable.)
406
407 -- Deal with SIGHUP in Emacs and in emacsclient. (After this, the
408 server-frames may be removed from server.el.)
409
410 (Done, nothing to do. It seems that Emacs does not receive SIGHUP
411 from secondary ttys, which is actually a good thing.) (Update: I
412 think it would be a bad idea to remove server-frames.)
413
414 -- Change emacsclient/server.el to support the -t argument better,
415 i.e. automatically close the socket when the frame is closed.
416
417 (Seems to be working OK.)
418
419 -- Fix mysterious memory corruption error with tty deletion. To
420 trigger it, try the following shell command:
421
422 while true; do TERM=no-such-terminal-definition emacsclient -h; done
423
424 Emacs usually dumps core after a few dozen iterations. (The bug
425 seems to be related to the xfreeing or bzeroing of
426 tty_output.Wcm. Maybe there are outside references to struct Wcm?
427 Why were these vars collected into a struct before multi-tty
428 support?)
429
430 (Done. Whew. It turned out that the problem had nothing to do
431 with hypothetical external references to Wcm, or any other
432 tty_output component; it was simply that delete_tty closed the
433 filehandles of secondary ttys twice, resulting in fclose doubly
434 freeing memory. Utterly trivial matter. I love the C's memory
435 management, it puts hair on your chest.)
436
437 -- Support raw secondary terminals. (Note that SIGIO works only on
438 the controlling terminal.) Hint: extend read_input_waiting for
439 multiple ttys and hopefully this will be fixed.
440
441 (Done, it seems to have been working already for some time. It
442 seems F_SETOWN does work, after all. Not sure what made it fail
443 earlier, but it seems to be fixed (there were several changes
444 around request_sigio, maybe one of them did it).
445 read_input_waiting is only used in sys_select, don't change
446 it.) (Update: After adding X support, it's broken again.)
447
448 -- Find out why does Emacs abort when it wants to close its
449 controlling tty. Hint: chan_process[] array. Hey, maybe
450 noninterrupt-IO would work, too? Update: no, there is no process
451 for stdin/out.
452
453 (Done. Added add/delete_keyboard_wait_descriptor to
454 term_init/delete_tty. The hint was right, in a way.)
455
456 -- Issue with SIGIO: it needs to be disabled during redisplay. See if
457 fcntl kernel behaviour could be emulated by emacsclient.
458
459 (Done. Simply disabled the SIGIO emulation hack in emacsclient.)
460 (Update: it was added back.)
461
462 -- server.el: There are issues with saving files in buffers of closed
463 clients. Try editing a file with emacsclient -f, and (without
464 saving it) do a delete-frame. The frame is closed without
465 question, and a surprising confirmation prompt appears in another
466 frame.
467
468 (Done. delete-frame now asks for confirmation if it still has
469 pending buffers, and modified buffers don't seem to be deleted.)
470
471 -- emacsclient.el, server.el: Handle eval or file open errors when
472 doing -t.
473
474 (Done.)
475
476 -- Make parts of struct tty_output accessible from Lisp. The device
477 name and the type is sufficient.
478
479 (Done, see frame-tty-name and frame-tty-type.)
480
481 -- Export delete_tty to the Lisp environment, for emacsclient.
482
483 (Done, see delete-tty.)
484
485 -- Get rid of the accessor macros in termchar.h, or define macros for
486 all members.
487
488 (Done.)
489
490 -- Move device-specific parameters (like costs) commonly used by
491 device backends to a common, device-dependent structure.
492
493 (Done. See struct display_method in termhooks.h.)
494
495 -- Fix X support.
496
497 (Done. Well, it seems to be working.)
498
499 -- Allow simultaneous X and tty frames. (Handling input could be
500 tricky. Or maybe not.)
501
502 (Done. Allowed, that is. It is currently extremely unstable, to
503 the point of being unusable. The rif variable causes constant
504 core dumps. Handling input is indeed tricky.)
505
506 -- Rewrite multi-tty input in terms of MULTI_KBOARD.
507
508 (Done. In fact, there was no need to rewrite anything, I just
509 added a kboard member to tty_display_info, and initialized the
510 frame's kboard from there.)
511
512 -- Fix rif issue with X-tty combo sessions. IMHO the best thing to do
513 is to get rid of that global variable (and use the value value in
514 display_method, which is guaranteed to be correct).
515
516 (Done, did exactly that. Core dumps during combo sessions became
517 much rarer. In fact, I have not yet met a single one.)
518
519 -- Add multi-tty support to talk.el.
520
521 (Done.)
522
523 -- Clean up the source of emacsclient. It is a mess.
524
525 (Done, eliminated stupid proxy-pty kludge.)
526
527 -- Fix faces on tty frames during X-tty combo sessions. There is an
528 init_frame_faces call in init_sys_modes, see if there is a problem
529 with it.
530
531 (Done, there was a stupid mistake in
532 Ftty_supports_face_attributes_p. Colors are broken, though.)
533
534 -- C-x 5 2, C-x 5 o, C-x 5 0 on an emacsclient frame unexpectedly
535 exits emacsclient. This is a result of trying to be clever with
536 delete-frame-functions.
537
538 (Fixed, added delete-tty-after-functions, and changed server.el to
539 use it.)
540
541 -- Something with (maybe) multi-keyboard support broke function keys
542 and arrows on ttys during X+tty combo sessions. Debug this.
543
544 (I can't reproduce it, maybe the terminal type was wrong.)
545
546 -- Fix input from raw ttys (again).
547
548 (Now it seems to work all right.)
549
550 -- During an X-tty combo session, a (message "Hello") from a tty frame
551 goes to the X frame. Fix this.
552
553 (Done. There was a safeguard against writing to the initial
554 terminal frame during bootstrap which prevented echo_area_display
555 from working correctly on a tty frame during a combo session.)
556
557 -- If there are no frames on its controlling terminal, Emacs should
558 exit if the uses presses C-c there.
559
560 (Done, as far as possible. See the SIGTERM comment in
561 interrupt_signal on why this seems to be impossible to solve this
562 in general.)
563
564 -- During an X session, Emacs seems to read from stdin. Also, Emacs
565 fails to start without a controlling tty.
566
567 (Fixed by replacing the troublesome termcap display with a dummy
568 bootstrap display during bootstrap.
569
570 -- Do tty output through struct display, like graphical display
571 backends.
572
573 (Done.)
574
575 -- Define an output_initial value for output_method for the initial
576 frame that is dumped with Emacs. Checking for this frame (e.g. in
577 cmd_error_internal) is ugly.
578
579 (Done, broking interactive temacs.)
580
581 -- The command `emacsclient -t -e '(delete-frame)'' fails to exit.
582
583 (Fixed.)
584
585 -- frame-creation-function should always create a frame that is on the
586 same display as the selected frame. Maybe frame-creation-function
587 should simply be removed and make-frame changed to do the right
588 thing.
589
590 (Done, with a nice hack. frame-creation-function is now frame-local.)
591
592 -- Fix C-g on raw ttys.
593
594 (Done. I disabled the interrupt/quit keys on all secondary
595 terminals, so Emacs sees C-g as normal input. This looks like an
596 overkill, because emacsclient has extra code to pass SIGINT to
597 Emacs, so C-g should remain the interrupt/quit key on emacsclient
598 frames. See the next entry why implementing this distinction would
599 be a bad idea.)
600
601 -- Make sure C-g goes to the right frame with ttys. This is hard, as
602 SIGINT doesn't have a tty parameter. :-(
603
604 (Done, the previous change fixes this as a pleasant side effect.)
605
606 -- I have seen a case when Emacs with multiple ttys fell into a loop
607 eating 100% of CPU time. Strace showed this loop:
608
609 getpid() = 30284
610 kill(30284, SIGIO) = 0
611 --- SIGIO (I/O possible) @ 0 (0) ---
612 ioctl(6, FIONREAD, [0]) = -1 EIO (Input/output error)
613 ioctl(5, FIONREAD, [0]) = -1 EIO (Input/output error)
614 ioctl(0, FIONREAD, [0]) = 0
615 sigreturn() = ? (mask now [])
616 gettimeofday({1072842297, 747760}, NULL) = 0
617 gettimeofday({1072842297, 747806}, NULL) = 0
618 select(9, [0 3 5 6], NULL, NULL, {0, 0}) = 2 (in [5 6], left {0, 0})
619 select(9, [0 3 5 6], NULL, NULL, {0, 0}) = 2 (in [5 6], left {0, 0})
620 gettimeofday({1072842297, 748245}, NULL) = 0
621
622 I have seen something similar with a single X frame, but have not
623 been able to reproduce it for debugging.
624
625 Update: This may have been caused by checking for nread != 0
626 instead of nread > 0 after calling read_socket_hook in
627 read_avail_input.
628
629 (Fixed. This was caused by unconditionally including stdin in
630 input_wait_mask in init_process. The select call in
631 wait_reading_process_input always returned immediately, indicating
632 that there is pending input from stdin, which nobody read.
633
634 Note that the above strace output seems to be an unrelated but
635 similar bug. I think that is now fixed.)
636
637 -- Exiting Emacs while there are emacsclient frames doesn't restore the
638 ttys to their default states.
639
640 (This seems to be fixed by some previous change.)
641
642 -- Allow opening an X session after -nw.
643
644 (Done.)
645
646 -- Fix color handling during tty+X combo sessions. (It seems that tty
647 sessions automatically convert the face colors to terminal colors
648 when the face is loaded. This conversion must happen instead on
649 the fly in write_glyphs, which might be problematic, as color
650 approximation is currently done in lisp (term/tty-colors.el).)
651 (Update: hm, colors seem to work fine if I start emacs with -nw and
652 then create an X frame. Maybe it's just a small buglet somewhere.)
653
654 (Seems to be fixed. The problem was in startup.el, it did not
655 initialize tty colors when the initial window system was
656 graphical.)
657
658 -- emacs -nw --eval '(y-or-n-p "Foobar")' segfaults. (Reported by
659 Romain Francoise)
660
661 (Fixed, there was a keyboard initialization problem.)
662
663 -- Fix interactive use of temacs. There are face-related SEGVs, most
664 likely because of changes in realize_default_face, realize_face.
665
666 (Fixed.)
667
668 -- Don't exit Emacs when the last X connection fails during a
669 multi-display session.
670
671 (Fixed.)
672
673
674 -- Dan Nicolaescu noticed that starting emacsclient on the same
675 terminal device that is the controlling tty of the Emacs process
676 gives unexpected results.
677
678 (Fixed.)
679
680 -- Istvan Marko reported that Emacs hang on ttys if it was started
681 from a shell script.
682
683 (Fixed. There was a bug in the multi-tty version of
684 narrow_foreground_group. tcsetpgrp blocks if it is called from a
685 process that is not in the same process group as the tty.)
686
687 -- emacsclient -t from an Emacs term buffer does not work, complains
688 about face problems. This can even lock up Emacs (if the recursive
689 frame sets single_kboard). Update: the face problems are caused by
690 bugs in term.el, not in multi-tty. The lockup is caused by
691 single_kboard mode, and is not easily solvable. The best thing to
692 do is to simply refuse to create a tty frame of type `eterm'.
693
694 (Fixed, changed emacsclient to check for TERM=eterm. The face
695 complaints seem to be caused by bugs in term.el; they are not
696 related to multi-tty.)
697
698 -- Find out the best way to support suspending Emacs with multiple
699 ttys. My guess: disable it on the controlling tty, but from other
700 ttys pass it on to emacsclient somehow. (It is (I hope) trivial to
701 extend emacsclient to handle suspend/resume. A `kill -STOP' almost
702 works right now.)
703
704 (Done. I needed to play with signal handling and the server
705 protocol a bit to make emacsclient behave as a normal UNIX program
706 wrt foreground/background process groups.)
707
708
709 ;;; arch-tag: 8da1619e-2e79-41a8-9ac9-a0485daad17d