GNU bug report logs -
#41410
Patch: Add function ffap-other-tab
Previous Next
Reported by: ej32u <at> protonmail.com
Date: Tue, 19 May 2020 21:47:01 UTC
Severity: wishlist
Tags: fixed, patch
Fixed in version 28.1
Done: Noam Postavsky <npostavs <at> gmail.com>
Bug is archived. No further changes may be made.
Full log
Message #18 received at 41410 <at> debbugs.gnu.org (full text, mbox):
>> Attached is a patch to add a function to open files at point in another
>> tab. It is basically the same as the function ffap-other-window.
>>
>> +(defun ffap-other-tab (filename)
>> + "Like `ffap', but put buffer in another tab.
>> +Only intended for interactive use."
>> + (interactive (list (ffap-prompter nil " other tab")))
>> + (pcase (save-window-excursion (find-file-at-point filename))
>> + ((or (and (pred bufferp) b) `(,(and (pred bufferp) b) . ,_))
>> + (switch-to-buffer-other-tab b))))
>> +
>> (defun ffap--toggle-read-only (buffer-or-list)
>> (dolist (buffer (if (listp buffer-or-list)
>> buffer-or-list
>> @@ -2013,6 +2023,7 @@ ffap-bindings
>>
>> (global-set-key [remap find-file-other-window] 'ffap-other-window)
>> (global-set-key [remap find-file-other-frame] 'ffap-other-frame)
>> + (global-set-key [remap find-file-other-tab] 'ffap-other-tab)
>> (global-set-key [remap find-file-read-only-other-window] 'ffap-read-only-other-window)
>> (global-set-key [remap find-file-read-only-other-frame] 'ffap-read-only-other-frame)
>
> Thanks, this is a useful addition. Please push it to master.
Maybe someone could check if this requires papers and
could push it to master when I'm away from computer.
This bug report was last modified 4 years and 364 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.