1 Apr 2010 15:07
Gtk tabs in emacs, new branch.
Jan Djärv <jan.h.d <at> swipnet.se>
2010-04-01 13:07:27 GMT
2010-04-01 13:07:27 GMT
Hello.
I've published a new branch (I hope, it is the first time I do this) that adds
Gtk+ tabs to Emacs, it is at bzr.savannah.gnu.org/srv/bzr/emacs/gtk-tabs.
Tabs isn't visible internally, it looks like just one frame at the lisp level.
Window configurations are used when switching between tabs. I think this
may cause flicker on slower machines. Making Emacs use Gtk+ double buffering
here would help. I may violate running Lisp from C restrictions here, but I
am not sure. Tabs most likely introduces new frame sizing errors.
The TODO file talks about tabs on each window. To make this happen, at least
for Gtk+, each window needs to be its own widget, instead of one widget per
frame as we have now. This is a bigger task.
You can drag tabs to reorder them, drop them on another frame to move it there
and drop on the root window to create a new frame.
The tabs themselves should be smaller IMHO, but the x to delete a tab makes
them larger than the text.
Lisp code is in native-tabs.el. Keybindings are:
(global-set-key "\C-x7\C-f" 'find-file-new-tab)
(global-set-key "\C-x70" 'tab-delete)
(global-set-key "\C-x71" 'tab-delete-other)
(global-set-key "\C-x72" 'tab-new)
(global-set-key "\C-x7f" 'find-file-new-tab)
(global-set-key "\C-x7o" 'tab-next)
(global-set-key "\C-x7n" 'tab-next)
(Continue reading)
Perhaps we need something like 'M-x tabs-mode' (by default possibly! 
but `split-window' is a
socially well-established function. Saved window configurations will
hardly ever get used that much. And we'll already have a hard time to
maintain compatibility, for example, when you want to restore a
configuration saved by Emacs 27 in an Emacs 29 session (or vice-versa).
>> That said, the *entire* coordinate information of a particular window in
>> an EWC would consist of (1) whether it is a horizontal or a vertical
>> combination and (2) the proportional space - either a float or the
>> fraction of "some largest integer" - occupied by the window wrt to its
>> parent window.
So if we could hook into this in some way, for example by providing a
window parameter that tells `set-window-configuration(-from-sexp)' what
to do if the buffer no longer exists, that might not be a bad idea.
RSS Feed