diff options
| author | Karoly Lorentey | 2004-01-11 21:59:40 +0000 |
|---|---|---|
| committer | Karoly Lorentey | 2004-01-11 21:59:40 +0000 |
| commit | 2246281fb0e2ab610d14efa7166a9ceb02597643 (patch) | |
| tree | 09416af10eec00f4d43af0dd569cc90cda408ce6 /README.multi-tty | |
| parent | c0707982ab8a080139a45b35fc7906415ba2f1bc (diff) | |
| download | emacs-2246281fb0e2ab610d14efa7166a9ceb02597643.tar.gz emacs-2246281fb0e2ab610d14efa7166a9ceb02597643.zip | |
Support for opening X frames from a tty session.
lisp/cus-face.el (custom-declare-face): Handle multiple concurrent
display methods correctly.
lisp/faces.el (x-create-frame-with-faces): Set the window-system frame
parameter instead of frame-creation-function.
(tty-create-frame-with-faces): Ditto.
lisp/frame.el (frame-creation-function): Removed.
(frame-creation-function-alist): New variable.
(frame-initialize): Use initial-window-system instead of window-system.
Add window-system parameter to initial-frame-alist.
Removed tty initialization, it was moved to frame-creation-function-alist.
(frame-notice-user-settings): Use initial-window-system instead of window-system.
(make-frame-on-display): Make sure term/x-win is loaded. Added
window-system parameter for make-frame.
(make-frame-on-tty): Removed unnecessary autoload declaration. Added
window-system parameter for make-frame.
(make-frame): Use frame-creation-function-alist to determine the
function to use depending on the specified window system.
(select-frame-by-name): Use the window-system function instead of the
variable.
lisp/startup.el (window-system): New variable (previously built-in,
now frame-local).
(normal-top-level, command-line): Use initial-window-system instead
of window-system.
lisp/loadup.el: Load startup.el before faces.el, for the
window-system variable.
lisp/term/x-win.el: Check for the x-create-frame function instead of
window-system to see if X is available. Don't exit Emacs if the
display can not be opened when X is not the initial display method.
Set up frame-creation-function-alist instead of
frame-creation-function. Provide the x-win feature.
src/dispnew.c (Vwindow_system): Renamed to Vinitial_window_system.
(init_display, syms_of_display): Updated to use Vinitial_window_system
instead of Vwindow_system.
src/emacs.c (shut_down_emacs): Updated to use Vinitial_window_system
instead of Vwindow_system.
src/keyboard.c (Fset_input_mode): Call reset_all_sys_modes, not
reset_sys_modes. Ditto for init_all_sys_modes. Process the quit
parameter correctly.
src/sysdep.c (init_sys_modes, reset_sys_modes): Unconditionally set up
the terminal. We don't get called if there is nothing to do anymore.
(sys_select): Use Vinitial_window_system, not Vwindow_system.
src/window.h (Vwindow_system): Renamed to Vinitial_window_system.
src/xfns.c (Fx_create_frame): Don't check_x. We initialize it anyway.
(x_display_info_for_name, Fx_open_connection): Don't look at
Vinitial_window_system.
git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-54
Diffstat (limited to 'README.multi-tty')
| -rw-r--r-- | README.multi-tty | 92 |
1 files changed, 57 insertions, 35 deletions
diff --git a/README.multi-tty b/README.multi-tty index 816f0090377..42e1867d98e 100644 --- a/README.multi-tty +++ b/README.multi-tty | |||
| @@ -2,9 +2,9 @@ | |||
| 2 | GOAL | 2 | GOAL |
| 3 | ---- | 3 | ---- |
| 4 | 4 | ||
| 5 | The ultimate goal of this branch is to implement support for opening | 5 | The goal of this branch is to implement support for opening multiple, |
| 6 | multiple, different tty devices and simultaneous X and tty frames from | 6 | different tty devices and simultaneous X and tty frames from a single |
| 7 | a single Emacs session. | 7 | Emacs session. |
| 8 | 8 | ||
| 9 | Some use cases: | 9 | Some use cases: |
| 10 | 10 | ||
| @@ -27,7 +27,7 @@ WHO IS DOING IT | |||
| 27 | 27 | ||
| 28 | I'm Károly Lőrentey. My address: lorentey@elte.hu. | 28 | I'm Károly Lőrentey. My address: lorentey@elte.hu. |
| 29 | 29 | ||
| 30 | Patches or suggestions are welcome! | 30 | Comments, bug reports, suggestions and patches are welcome! |
| 31 | 31 | ||
| 32 | Retrieving the latest version of the branch: | 32 | Retrieving the latest version of the branch: |
| 33 | 33 | ||
| @@ -46,9 +46,13 @@ STATUS | |||
| 46 | ------ | 46 | ------ |
| 47 | 47 | ||
| 48 | Multi-tty support is stable, I think most of the problems were fixed. | 48 | Multi-tty support is stable, I think most of the problems were fixed. |
| 49 | (It still needs testing on other architectures, though.) Please let | 49 | (It still needs testing on other architectures, though.) Simultaneous |
| 50 | me know if you find any bugs in it. Emacsclient has been extended to | 50 | X and tty frame support works fine, although there are some small |
| 51 | support opening a new terminal frame. | 51 | issues. Emacsclient has been extended to support opening a new |
| 52 | terminal frame. | ||
| 53 | |||
| 54 | |||
| 55 | Please let me know if you find any bugs in this branch. | ||
| 52 | 56 | ||
| 53 | To try it out, compile and run the multi-tty branch with the following | 57 | To try it out, compile and run the multi-tty branch with the following |
| 54 | commands: | 58 | commands: |
| @@ -57,7 +61,7 @@ commands: | |||
| 57 | cd +build | 61 | cd +build |
| 58 | ../configure | 62 | ../configure |
| 59 | make bootstrap | 63 | make bootstrap |
| 60 | src/emacs -nw | 64 | src/emacs -nw # You can also try without -nw |
| 61 | M-x server-start | 65 | M-x server-start |
| 62 | 66 | ||
| 63 | and then (from a shell prompt on another terminal) start emacsclient | 67 | and then (from a shell prompt on another terminal) start emacsclient |
| @@ -77,7 +81,7 @@ all terminals should be restored to their previous states. | |||
| 77 | 81 | ||
| 78 | This is work in progress, and probably full of bugs. You should | 82 | This is work in progress, and probably full of bugs. You should |
| 79 | always run emacs from gdb, so that you'll have a live instance to | 83 | always run emacs from gdb, so that you'll have a live instance to |
| 80 | debug if something goes wrong. Please send me your reports. | 84 | debug if something goes wrong. Please send me your bug reports. |
| 81 | 85 | ||
| 82 | Problems: | 86 | Problems: |
| 83 | 87 | ||
| @@ -85,39 +89,48 @@ Problems: | |||
| 85 | devices. Also, there is no way to suspend emacsclient. This | 89 | devices. Also, there is no way to suspend emacsclient. This |
| 86 | will be fixed. | 90 | will be fixed. |
| 87 | 91 | ||
| 88 | * X support is (I hope) working, but at the moment there are | ||
| 89 | problems with simultaneous X and tty devices, so don't do | ||
| 90 | that - start a separate Emacs with -nw and run the server | ||
| 91 | there. | ||
| 92 | |||
| 93 | * Mac, Windows and DOS support is broken, probably doesn't | 92 | * Mac, Windows and DOS support is broken, probably doesn't |
| 94 | even compile -- this will be solved later. | 93 | even compile -- this will be solved later. |
| 95 | 94 | ||
| 96 | * Only tested on my GNU/Linux box. | 95 | * Only tested on my GNU/Linux box and on Solaris 8. |
| 97 | 96 | ||
| 98 | NEWS | 97 | NEWS |
| 99 | ---- | 98 | ---- |
| 100 | 99 | ||
| 101 | For the NEWS file: | 100 | For the NEWS file: |
| 102 | 101 | ||
| 103 | ** Support for multiple terminal devices has been added. You can | 102 | ** Support for multiple terminal devices has been added. |
| 104 | specify a terminal device (`tty' parameter) and a terminal type | ||
| 105 | (`tty-type' parameter) to `make-terminal-frame'. `tty' must be a | ||
| 106 | terminal device created by the updated emacsclient, or there will | ||
| 107 | be problems with terminal input and window resizes. | ||
| 108 | 103 | ||
| 109 | You can test for the presence of multiple terminal support by | 104 | *** You can specify a terminal device (`tty' parameter) and a terminal |
| 110 | testing for the `multi-tty' feature. | 105 | type (`tty-type' parameter) to `make-terminal-frame'. |
| 111 | 106 | ||
| 112 | ** A make-frame-on-tty function has been added to make it easier to | 107 | *** You can test for the presence of multiple terminal support by |
| 113 | create frames on new terminals. | 108 | testing for the `multi-tty' feature. |
| 114 | 109 | ||
| 115 | ** New functions: frame-tty-name, frame-tty-type for accessing | 110 | *** Emacsclient has been extended to support opening a new terminal |
| 116 | terminal parameters, and delete-tty for closing the terminal | 111 | frame (see -t option). |
| 117 | device. | 112 | |
| 113 | *** A make-frame-on-tty function has been added to make it easier to | ||
| 114 | create frames on new terminals. | ||
| 115 | |||
| 116 | *** New functions: frame-tty-name, frame-tty-type for accessing | ||
| 117 | terminal parameters, and delete-tty for closing the terminal | ||
| 118 | device. | ||
| 119 | |||
| 120 | *** talk.el has been extended for multiple tty support. | ||
| 121 | |||
| 122 | |||
| 123 | ** Support for simultaneous graphical and terminal frames has been | ||
| 124 | added. | ||
| 125 | |||
| 126 | *** The function `make-frame-on-display' now works during a terminal | ||
| 127 | session, and `make-frame-on-tty' works during a graphical session. | ||
| 128 | |||
| 129 | *** The `window-system' variable has been made frame-local. | ||
| 130 | |||
| 131 | *** The new `initial-window-system' variable contains the | ||
| 132 | `window-system' value for the first frame. | ||
| 118 | 133 | ||
| 119 | ** Emacsclient has been extended to support opening a new terminal | ||
| 120 | frame. | ||
| 121 | 134 | ||
| 122 | CHANGELOG | 135 | CHANGELOG |
| 123 | --------- | 136 | --------- |
| @@ -127,11 +140,13 @@ See arch logs. | |||
| 127 | THINGS TO DO | 140 | THINGS TO DO |
| 128 | ------------ | 141 | ------------ |
| 129 | 142 | ||
| 130 | ** Fix color handling during X+tty combo sessions. (It seems that tty | 143 | ** Fix color handling during tty+X combo sessions. (It seems that tty |
| 131 | sessions automatically convert the face colors to terminal colors | 144 | sessions automatically convert the face colors to terminal colors |
| 132 | when the face is loaded. This conversion must happen instead on | 145 | when the face is loaded. This conversion must happen instead on |
| 133 | the fly in write_glyphs, which might be problematic, as color | 146 | the fly in write_glyphs, which might be problematic, as color |
| 134 | approximation is currently done in lisp (term/tty-colors.el).) | 147 | approximation is currently done in lisp (term/tty-colors.el).) |
| 148 | (Update: hm, colors seem to work fine if I start emacs with -nw and | ||
| 149 | then create an X frame. Maybe it's just a small buglet somewhere.) | ||
| 135 | 150 | ||
| 136 | ** Fix interactive use of temacs. There are face-related SEGVs, most | 151 | ** Fix interactive use of temacs. There are face-related SEGVs, most |
| 137 | likely because of changes in realize_default_face, realize_face. | 152 | likely because of changes in realize_default_face, realize_face. |
| @@ -139,17 +154,12 @@ THINGS TO DO | |||
| 139 | ** Very strange bug: visible-bell does not work on secondary | 154 | ** Very strange bug: visible-bell does not work on secondary |
| 140 | terminals. This might be something xterm (konsole) specific. | 155 | terminals. This might be something xterm (konsole) specific. |
| 141 | 156 | ||
| 142 | ** Allow opening an X session after -nw. | ||
| 143 | |||
| 144 | ** Find out the best way to support suspending Emacs with multiple | 157 | ** Find out the best way to support suspending Emacs with multiple |
| 145 | ttys. My guess: disable it on the controlling tty, but from other | 158 | ttys. My guess: disable it on the controlling tty, but from other |
| 146 | ttys pass it on to emacsclient somehow. (It is (I hope) trivial to | 159 | ttys pass it on to emacsclient somehow. (It is (I hope) trivial to |
| 147 | extend emacsclient to handle suspend/resume. A `kill -STOP' almost | 160 | extend emacsclient to handle suspend/resume. A `kill -STOP' almost |
| 148 | works right now.) | 161 | works right now.) |
| 149 | 162 | ||
| 150 | ** Exiting Emacs while there are emacsclient frames doesn't restore the | ||
| 151 | ttys to their default states. | ||
| 152 | |||
| 153 | ** Move baud_rate to struct display. | 163 | ** Move baud_rate to struct display. |
| 154 | 164 | ||
| 155 | ** Implement support for starting an interactive Emacs session without | 165 | ** Implement support for starting an interactive Emacs session without |
| @@ -187,6 +197,8 @@ THINGS TO DO | |||
| 187 | single_kboard mode, and is not easily solvable. The best thing to | 197 | single_kboard mode, and is not easily solvable. The best thing to |
| 188 | do is to simply refuse to create a tty frame of type `eterm'. | 198 | do is to simply refuse to create a tty frame of type `eterm'. |
| 189 | 199 | ||
| 200 | ** Maybe standard-display-table should be display-local. | ||
| 201 | |||
| 190 | DIARY OF CHANGES | 202 | DIARY OF CHANGES |
| 191 | ---------------- | 203 | ---------------- |
| 192 | 204 | ||
| @@ -545,4 +557,14 @@ DIARY OF CHANGES | |||
| 545 | Note that the above strace output seems to be an unrelated but | 557 | Note that the above strace output seems to be an unrelated but |
| 546 | similar bug. I think that is now fixed.) | 558 | similar bug. I think that is now fixed.) |
| 547 | 559 | ||
| 560 | -- Exiting Emacs while there are emacsclient frames doesn't restore the | ||
| 561 | ttys to their default states. | ||
| 562 | |||
| 563 | (This seems to be fixed by some previous change.) | ||
| 564 | |||
| 565 | -- Allow opening an X session after -nw. | ||
| 566 | |||
| 567 | (Done.) | ||
| 568 | |||
| 569 | |||
| 548 | ;;; arch-tag: 8da1619e-2e79-41a8-9ac9-a0485daad17d | 570 | ;;; arch-tag: 8da1619e-2e79-41a8-9ac9-a0485daad17d |