%PDF- %PDF-
Direktori : /usr/local/share/emacs/27.2/lisp/ |
Current File : //usr/local/share/emacs/27.2/lisp/tab-line.elc |
;ELC ;;; Compiled ;;; in Emacs version 27.2 ;;; with all optimizations. ;;; This file contains utf-8 non-ASCII characters, ;;; and so cannot be loaded into Emacs 22 or earlier. (and (boundp 'emacs-version) (< (aref emacs-version (1- (length emacs-version))) ?A) (string-lessp emacs-version "23") (error "`%s' was compiled for Emacs 23 or later" #$)) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (byte-code "\300\301!\210\302\303\304\305\306\307\310\311&\210\302\312\313\314\306\303\306\315\310\311& \210\316\317\320\321\310\311\306\312&\210\316\322\323\324\310\311\306\312&\210\316\325\326\327\310\311\306\312&\210\316\330\331\332\310\311\306\312&\210\316\333\334\335\310\311\306\312&\207" [require seq custom-declare-group tab-line nil "Window-local tabs." :group convenience :version "27.1" tab-line-faces ((tab-line custom-face)) "Faces used in the tab line." faces custom-declare-face tab-line-tab ((default :inherit tab-line) (((class color) (min-colors 88)) :box (:line-width 1 :style released-button)) (t :inverse-video nil)) "Tab line face for selected tab." tab-line-tab-inactive ((default :inherit tab-line-tab) (((class color) (min-colors 88)) :background "grey75") (t :inverse-video t)) "Tab line face for non-selected tab." tab-line-tab-current ((default :inherit tab-line-tab) (((class color) (min-colors 88)) :background "grey85")) "Tab line face for tab with current buffer in selected window." tab-line-highlight ((default :inherit tab-line-tab)) "Tab line face for highlighting." tab-line-close-highlight ((t :foreground "red")) "Tab line face for highlighting of the close button."] 10) #@47 Local keymap for `tab-line-mode' window tabs. (defvar tab-line-tab-map (byte-code "\300 \301\302\303#\210\301\304\305#\210\301\306\303#\210\211\207" [make-sparse-keymap define-key [tab-line mouse-1] tab-line-select-tab [tab-line mouse-2] tab-line-close-tab " "] 5) (#$ . 1625)) #@50 Local keymap to add `tab-line-mode' window tabs. (defvar tab-line-add-map (byte-code "\300 \301\302\303#\210\301\304\303#\210\301\305\303#\210\211\207" [make-sparse-keymap define-key [tab-line mouse-1] tab-line-new-tab [tab-line mouse-2] " "] 5) (#$ . 1912)) #@52 Local keymap to close `tab-line-mode' window tabs. (defvar tab-line-tab-close-map (byte-code "\300 \301\302\303#\210\301\304\303#\210\211\207" [make-sparse-keymap define-key [tab-line mouse-1] tab-line-close-tab [tab-line mouse-2]] 5) (#$ . 2180)) #@65 Local keymap to scroll `tab-line-mode' window tabs to the left. (defvar tab-line-left-map (byte-code "\300 \301\302\303#\210\301\304\303#\210\301\305\306#\210\211\207" [make-sparse-keymap define-key [tab-line mouse-1] tab-line-hscroll-left [tab-line mouse-2] " " tab-line-new-tab] 5) (#$ . 2436)) #@66 Local keymap to scroll `tab-line-mode' window tabs to the right. (defvar tab-line-right-map (byte-code "\300 \301\302\303#\210\301\304\303#\210\301\305\306#\210\211\207" [make-sparse-keymap define-key [tab-line mouse-1] tab-line-hscroll-right [tab-line mouse-2] " " tab-line-new-tab] 5) (#$ . 2742)) (byte-code "\300\301\302\303\304DD\305\306\307\310\311\312\313& \210\300\314\302\303\315DD\316\306\317\320\321\322\323\310\311\312\313& \207" [custom-declare-variable tab-line-new-tab-choice funcall function #[0 "\300\207" [t] 1] "Defines what to show in a new tab.\nIf t, display a selection menu with all available buffers.\nIf the value is a function, call it with no arguments." :type (choice (const :tag "Buffer menu" t) (function :tag "Function")) :group tab-line :version "27.1" tab-line-new-button-show #[0 "\300\207" [t] 1] "If non-nil, show the \"New tab\" button in the tab line." boolean :initialize custom-initialize-default :set #[514 "\300\"\210\301 \207" [set-default force-mode-line-update] 5 "\n\n(fn SYM VAL)"]] 14) #@32 Button for creating a new tab. (defvar tab-line-new-button (propertize " + " 'display '(image :type xpm :file "tabs/new.xpm" :margin (2 . 0) :ascent center) 'keymap tab-line-add-map 'mouse-face 'tab-line-highlight 'help-echo "Click to add tab") (#$ . 3788)) (byte-code "\300\301\302\303\304DD\305\306\307\310\311\312\313\314\315\316\317& \207" [custom-declare-variable tab-line-close-button-show funcall function #[0 "\300\207" [t] 1] "Defines where to show the close tab button.\nIf t, show the close tab button on all tabs.\nIf `selected', show it only on the selected tab.\nIf `non-selected', show it only on non-selected tab.\nIf nil, don't show it at all." :type (choice (const :tag "On all tabs" t) (const :tag "On selected tab" selected) (const :tag "On non-selected tabs" non-selected) (const :tag "None" nil)) :initialize custom-initialize-default :set #[514 "\300\"\210\301 \207" [set-default force-mode-line-update] 5 "\n\n(fn SYM VAL)"] :group tab-line :version "27.1"] 14) #@37 Button for closing the clicked tab. (defvar tab-line-close-button (propertize " x" 'display '(image :type xpm :file "tabs/close.xpm" :margin (2 . 0) :ascent center) 'keymap tab-line-tab-close-map 'mouse-face 'tab-line-close-highlight 'help-echo "Click to close tab") (#$ . 4782)) #@48 Button for scrolling horizontally to the left. (defvar tab-line-left-button (propertize " <" 'display '(image :type xpm :file "tabs/left-arrow.xpm" :margin (2 . 0) :ascent center) 'keymap tab-line-left-map 'mouse-face 'tab-line-highlight 'help-echo "Click to scroll left") (#$ . 5068)) #@49 Button for scrolling horizontally to the right. (defvar tab-line-right-button (propertize "> " 'display '(image :type xpm :file "tabs/right-arrow.xpm" :margin (2 . 0) :ascent center) 'keymap tab-line-right-map 'mouse-face 'tab-line-highlight 'help-echo "Click to scroll right") (#$ . 5360)) #@28 String that delimits tabs. (defvar tab-line-separator nil (#$ . 5657)) (byte-code "\300\301\302\303\304DD\305\306\307\310\311\312\313\314\315\316\317& \207" [custom-declare-variable tab-line-tab-name-function funcall function #[0 "\300\207" [tab-line-tab-name-buffer] 1] "Function to get a tab name.\nFunction gets two arguments: tab to get name for and a list of tabs\nto display. By default, use function `tab-line-tab-name'." :type (choice (const :tag "Buffer name" tab-line-tab-name-buffer) (const :tag "Truncated buffer name" tab-line-tab-name-truncated-buffer) (function :tag "Function")) :initialize custom-initialize-default :set #[514 "\300\"\210\301 \207" [set-default force-mode-line-update] 5 "\n\n(fn SYM VAL)"] :group tab-line :version "27.1"] 14) #@233 Generate tab name from BUFFER. Reduce tab width proportionally to space taken by other tabs. This function can be overridden by changing the default value of the variable `tab-line-tab-name-function'. (fn BUFFER &optional BUFFERS) (defalias 'tab-line-tab-name-buffer #[513 "\300!\207" [buffer-name] 4 (#$ . 6429)]) (byte-code "\300\301\302\303\304DD\305\306\307\310\311\312\313& \207" [custom-declare-variable tab-line-tab-name-truncated-max funcall function #[0 "\300\207" [20] 1] "Maximum length of the tab name from the current buffer.\nEffective when `tab-line-tab-name-function' is customized\nto `tab-line-tab-name-truncated-buffer'." :type integer :group tab-line :version "27.1"] 10) (defvar tab-line-tab-name-ellipsis (byte-code "\300\301!\203 \302\207\303\207" [char-displayable-p 8230 "…" "..."] 2)) #@196 Generate tab name from BUFFER. Truncate it to the length specified by `tab-line-tab-name-truncated-max'. Append ellipsis `tab-line-tab-name-ellipsis' in this case. (fn BUFFER &optional BUFFERS) (defalias 'tab-line-tab-name-truncated-buffer #[513 "\302!\211GW\203 \211\202 \303\304\305\211 %\306#\207" [tab-line-tab-name-truncated-max tab-line-tab-name-ellipsis buffer-name propertize truncate-string-to-width nil help-echo] 10 (#$ . 7252)]) (byte-code "\300\301\302\303\304DD\305\306\307\310\311\312\313\314\315\316\317& \207" [custom-declare-variable tab-line-tabs-function funcall function #[0 "\300\207" [tab-line-tabs-window-buffers] 1] "Function to get a list of tabs to display in the tab line.\nThis function should return either a list of buffers whose names will\nbe displayed, or just a list of strings to display in the tab line.\nBy default, use function `tab-line-tabs-window-buffers' that\nreturns a list of buffers associated with the selected window.\nWhen `tab-line-tabs-mode-buffers', return a list of buffers\nwith the same major mode as the current buffer." :type (choice (const :tag "Window buffers" tab-line-tabs-window-buffers) (const :tag "Same mode buffers" tab-line-tabs-mode-buffers) (const :tag "Grouped buffers" tab-line-tabs-buffer-groups) (function :tag "Function")) :initialize custom-initialize-default :set #[514 "\300\"\210\301 \207" [set-default force-mode-line-update] 5 "\n\n(fn SYM VAL)"] :group tab-line :version "27.1"] 14) #@124 Function to return a global list of buffers. Used only for `tab-line-tabs-mode-buffers' and `tab-line-tabs-buffer-groups'. (defvar tab-line-tabs-buffer-list-function 'tab-line-tabs-buffer-list (#$ . 8734)) (defalias 'tab-line-tabs-buffer-list #[0 "\300\301\302\303pC\304\305\306 \"\307 #!\"\207" [seq-filter #[257 "\300!\205 \301!\302H\303U?\207" [buffer-live-p buffer-name 0 32] 3 "\n\n(fn B)"] seq-uniq append mapcar car window-prev-buffers buffer-list] 8]) #@72 Return a list of buffers with the same major mode with current buffer. (defalias 'tab-line-tabs-mode-buffers #[0 "\302\303\304\305\306\307\310\311\312 !\313\"\314\315% \"#\207" [major-mode tab-line-tabs-buffer-list-function seq-sort-by buffer-name string< seq-filter make-byte-code 257 "r\211q\210\301\300!)\207" vconcat vector [derived-mode-p] 3 "\n\n(fn B)"] 11 (#$ . 9203)]) #@157 Function to put a buffer to the group. Takes a buffer as arg and should return a group name as string. When the return value is nil, filter out the buffer. (defvar tab-line-tabs-buffer-group-function nil (#$ . 9591)) #@36 Function to sort buffers in group. (defvar tab-line-tabs-buffer-group-sort-function nil (#$ . 9814)) #@31 Function to sort group names. (defvar tab-line-tabs-buffer-groups-sort-function 'string< (#$ . 9921)) #@179 How to group various major modes together in the tab line. Each element has the form (REGEXP . GROUPNAME). If the major mode's name string matches REGEXP, use GROUPNAME instead. (defvar tab-line-tabs-buffer-groups mouse-buffer-menu-mode-groups (#$ . 10030)) #@25 (fn &optional BUFFER) (defalias 'tab-line-tabs-buffer-group-name #[256 "\303!\203\n !\207\211\203 r\211q\210\304 !)\202 \304 !\305\306\307\310\311\312!\313\"\314\315%\n\"A\2061 \211\207" [tab-line-tabs-buffer-group-function mode-name tab-line-tabs-buffer-groups functionp format-mode-line seq-find make-byte-code 257 "\211@\300\302\303\304#)\207" vconcat vector [inhibit-changing-match-data nil t string-match] 8 "\n\n(fn GROUP)"] 9 (#$ . 10294)]) (defalias 'tab-line-tabs-buffer-groups #[0 "\303\304\305\"\203, \306 \307\304\310\311\312\313\"\"\"\"\303\304\314\"\310\315\316\317\320\321!\322\"\323\324%\"\207\303\304\314\"\325p!\206<