;ELC ;;; Compiled ;;; in Emacs version 28.0.50 ;;; with all optimizations. (byte-code "\300\301!\210\300\302!\210\303\304\305\306\307\310\311\312&\210\313\314\315\316\317DD\320\321\322\307\304&\210\313\323\315\316\324DD\325\321\322\307\304&\210\313\326\315\316\327DD\330\321\331\307\304&\210\313\332\315\316\333DD\334\321\335\307\304&\210\313\336\315\316\337DD\340\321\322\307\304&\207" [require cl-lib ring custom-declare-group winds nil "A window configuration switcher for multiple workspaces" :group convenience :prefix "winds-" custom-declare-variable winds-default-ws funcall function #[0 "\300\207" [1] 1] "Default selected workspace." :type integer winds-default-cfg #[0 "\300\207" [1] 1] "Default selected window config slot." winds-display-status-msg #[0 "\300\207" [t] 1] "Whether to display a status message upon switching window config." boolean winds-init-cfg-hook #[0 "\300C\207" [#[514 "\300 \210\301\302!\207" [delete-other-windows switch-to-buffer "*scratch*"] 4 "\n\n(fn W C)"]] 1] "Hook called to create a new layout upon opening a new window config slot.\n\nThe hook receives two parameters: the window-id and cfg-id of the new slot\nSet to `nil` to not run any initialization" hook winds-history-size #[0 "\300\207" [200] 1] "Size of window config history saved for each slot."] 8) #@70 compiler-macro for inlining `winds--ring-p'. (fn CL-WHOLE-ARG CL-X) (defalias 'winds--ring-p--cmacro #[514 "\300\301\302\303\211\211&\207" [cl--defsubst-expand (cl-x) (cl-block winds--ring-p (and (memq (type-of cl-x) cl-struct-winds--ring-tags) t)) nil] 9 (#$ . 1322)]) (put 'winds--ring-p 'compiler-macro 'winds--ring-p--cmacro) #@13 (fn CL-X) (defalias 'winds--ring-p #[257 "\301!>\205 \302\207" [cl-struct-winds--ring-tags type-of t] 3 (#$ . 1662)]) (byte-code "\300\301\302\303#\304\305\306\301#\207" [function-put winds--ring-p side-effect-free error-free put winds--ring cl-deftype-satisfies] 5) #@73 compiler-macro for inlining `winds--ring-rwnd'. (fn CL-WHOLE-ARG CL-X) (defalias 'winds--ring-rwnd--cmacro #[514 "\300\301\302\303\211\211&\207" [cl--defsubst-expand (cl-x) (cl-block winds--ring-rwnd (progn (or (winds--ring-p cl-x) (signal 'wrong-type-argument (list 'winds--ring cl-x))) (aref cl-x 1))) nil] 9 (#$ . 1940)]) (put 'winds--ring-rwnd 'compiler-macro 'winds--ring-rwnd--cmacro) #@61 Access slot "rwnd" of `winds--ring' struct CL-X. (fn CL-X) (defalias 'winds--ring-rwnd #[257 "\301!>\204\302\303\304D\"\210\211\305H\207" [cl-struct-winds--ring-tags type-of signal wrong-type-argument winds--ring 1] 5 (#$ . 2341)]) (byte-code "\300\301\302\303#\300\207" [function-put winds--ring-rwnd side-effect-free t] 4) #@72 compiler-macro for inlining `winds--ring-fwd'. (fn CL-WHOLE-ARG CL-X) (defalias 'winds--ring-fwd--cmacro #[514 "\300\301\302\303\211\211&\207" [cl--defsubst-expand (cl-x) (cl-block winds--ring-fwd (progn (or (winds--ring-p cl-x) (signal 'wrong-type-argument (list 'winds--ring cl-x))) (aref cl-x 2))) nil] 9 (#$ . 2678)]) (put 'winds--ring-fwd 'compiler-macro 'winds--ring-fwd--cmacro) #@60 Access slot "fwd" of `winds--ring' struct CL-X. (fn CL-X) (defalias 'winds--ring-fwd #[257 "\301!>\204\302\303\304D\"\210\211\305H\207" [cl-struct-winds--ring-tags type-of signal wrong-type-argument winds--ring 2] 5 (#$ . 3074)]) (byte-code "\300\301\302\303#\304\305\306\"\207" [function-put winds--ring-fwd side-effect-free t defalias copy-winds--ring copy-sequence] 4) #@74 Constructor for objects of type `winds--ring'. (fn &optional (SIZE 10)) (defalias 'make-winds--ring #[128 "\211\203 \211A\262\242\202\300\301!\301!\203\"\302\303\304GTD\"\210\305\306#\207" [10 make-ring signal wrong-number-of-arguments make-winds--ring record winds--ring] 8 (#$ . 3458)]) (byte-code "\300\301\302\303#\304\305\306\307\310\311\312\313\305\303& \207" [function-put make-winds--ring side-effect-free t cl-struct-define winds--ring "A rewindable ring." cl-structure-object record nil ((cl-tag-slot) (rwnd) (fwd)) cl-struct-winds--ring-tags] 11) #@42 Clear the RING's fwd history. (fn RING) (defalias 'winds--ring-clear-forward #[257 "\301!>\204\302\303\304D\"\210\211\305H\306!?\2053\301!>\204(\302\303\304D\"\210\211\305\307\310!!I\262\207" [cl-struct-winds--ring-tags type-of signal wrong-type-argument winds--ring 2 ring-empty-p make-ring ring-size] 8 (#$ . 4036)]) #@121 Insert ITEM into RING, clearing it's fwd history unless KEEP-FORWARD is non-nil. (fn RING ITEM &optional KEEP-FORWARD) (defalias 'winds--ring-insert #[770 "\211\204\301!\210\302\303!>\204\304\305\306D\"\210\307H\"\207" [cl-struct-winds--ring-tags winds--ring-clear-forward ring-insert type-of signal wrong-type-argument winds--ring 1] 8 (#$ . 4377)]) #@59 Remove INDEX item from RING's rwnd hist. (fn RING INDEX) (defalias 'winds--ring-remove #[514 "\301\302!>\204\303\304\305D\"\210\306H\"\207" [cl-struct-winds--ring-tags ring-remove type-of signal wrong-type-argument winds--ring 1] 7 (#$ . 4746)]) #@68 Replace top element in RING's rwnd hist with ITEM. (fn RING ITEM) (defalias 'winds--ring-replace #[514 "\300\301\"\210\302\303#\207" [winds--ring-remove 0 winds--ring-insert t] 6 (#$ . 5006)]) #@104 Replace top element in RING's rwnd hist with ITEM or insert if it is completely empty. (fn RING ITEM) (defalias 'winds--ring-replace-or-insert #[514 "\300!\203 \301\"\207\302\"\207" [winds--ring-total-empty-p winds--ring-insert winds--ring-replace] 5 (#$ . 5210)]) #@40 Rewind RING by one element. (fn RING) (defalias 'winds--ring-rewind #[257 "\301!>\204\302\303\304D\"\210\211\305H\301!>\204!\302\303\304D\"\210\306H\307!\305U\2030\310\311!\207\312\313\"\314\"\207" [cl-struct-winds--ring-tags type-of signal wrong-type-argument winds--ring 1 2 ring-length error "Rewind ring already at oldest element" ring-remove 0 ring-insert] 7 (#$ . 5488)]) #@46 Fast-forward RING by one element. (fn RING) (defalias 'winds--ring-forward #[257 "\301!>\204\302\303\304D\"\210\211\305H\301!>\204!\302\303\304D\"\210\306H\307!\203.\310\311!\207\312\313\"\314\"\207" [cl-struct-winds--ring-tags type-of signal wrong-type-argument winds--ring 1 2 ring-empty-p error "Forward ring empty" ring-remove 0 ring-insert] 7 (#$ . 5888)]) #@70 Retrieve element at INDEX from RING's rwnd history. (fn RING INDEX) (defalias 'winds--ring-ref #[514 "\301\302!>\204\303\304\305D\"\210\306H\"\207" [cl-struct-winds--ring-tags ring-ref type-of signal wrong-type-argument winds--ring 1] 7 (#$ . 6272)]) #@59 Check whether the RING's fwd history is empty. (fn RING) (defalias 'winds--ring-fwd-empty-p #[257 "\301\302!>\204\303\304\305D\"\210\306H!\207" [cl-struct-winds--ring-tags ring-empty-p type-of signal wrong-type-argument winds--ring 2] 6 (#$ . 6537)]) #@60 Check whether the RING's rwnd history is empty. (fn RING) (defalias 'winds--ring-rwnd-empty-p #[257 "\301\302!>\204\303\304\305D\"\210\306H!\207" [cl-struct-winds--ring-tags ring-empty-p type-of signal wrong-type-argument winds--ring 1] 6 (#$ . 6801)]) #@69 Check whether the RING's rwnd and fwd history are empty. (fn RING) (defalias 'winds--ring-total-empty-p #[257 "\300!\205 \301!\207" [winds--ring-rwnd-empty-p winds--ring-fwd-empty-p] 3 (#$ . 7067)]) #@47 Get the RING's fwd history length. (fn RING) (defalias 'winds--ring-fwd-length #[257 "\301\302!>\204\303\304\305D\"\210\306H!\207" [cl-struct-winds--ring-tags ring-length type-of signal wrong-type-argument winds--ring 2] 6 (#$ . 7276)]) #@48 Get the RING's rwnd history length. (fn RING) (defalias 'winds--ring-rwnd-length #[257 "\301\302!>\204\303\304\305D\"\210\306H!\207" [cl-struct-winds--ring-tags ring-length type-of signal wrong-type-argument winds--ring 1] 6 (#$ . 7526)]) #@49 Get the RING's total history length. (fn RING) (defalias 'winds--ring-total-length #[257 "\300!\301!\\\207" [winds--ring-fwd-length winds--ring-rwnd-length] 4 (#$ . 7778)]) #@84 Utility macro to get nested attributes in an ALIST by PATH. (fn ALIST &rest PATH) (defalias 'winds--alist-get '(macro . #[385 "\211G\300Y\203\301\302@EABB\207\302@E\207" [2 winds--alist-get alist-get] 6 (#$ . 7960)])) #@70 Utility macro get winds FRAME state via PATH. (fn FRAME &rest PATH) (defalias 'winds--state-get '(macro . #[385 "\211\203\f\300\301DBB\207\302\303BB\207" [winds--alist-get winds--state-get frame-parameter ('winds--state)] 5 (#$ . 8192)])) #@74 compiler-macro for inlining `winds-workspace-p'. (fn CL-WHOLE-ARG CL-X) (defalias 'winds-workspace-p--cmacro #[514 "\300\301\302\303\211\211&\207" [cl--defsubst-expand (cl-x) (cl-block winds-workspace-p (and (vectorp cl-x) (>= (length cl-x) 2) (memq (aref cl-x 0) cl-struct-winds-workspace-tags) t)) nil] 9 (#$ . 8442)]) (put 'winds-workspace-p 'compiler-macro 'winds-workspace-p--cmacro) #@13 (fn CL-X) (defalias 'winds-workspace-p #[257 "\301!\205\211G\302Y\205\211\303H>\205\304\207" [cl-struct-winds-workspace-tags vectorp 2 0 t] 3 (#$ . 8841)]) (byte-code "\300\301\302\303#\304\305\306\301#\207" [function-put winds-workspace-p side-effect-free error-free put winds-workspace cl-deftype-satisfies] 5) #@77 compiler-macro for inlining `winds-workspace-cfgs'. (fn CL-WHOLE-ARG CL-X) (defalias 'winds-workspace-cfgs--cmacro #[514 "\300\301\302\303\211\211&\207" [cl--defsubst-expand (cl-x) (cl-block winds-workspace-cfgs (progn (or (and (memq (aref cl-x 0) cl-struct-winds-workspace-tags)) (signal 'wrong-type-argument (list 'winds-workspace cl-x))) (aref cl-x 1))) nil] 9 (#$ . 9170)]) (put 'winds-workspace-cfgs 'compiler-macro 'winds-workspace-cfgs--cmacro) #@65 Access slot "cfgs" of `winds-workspace' struct CL-X. (fn CL-X) (defalias 'winds-workspace-cfgs #[257 "\211\301H>\204\302\303\304D\"\210\211\305H\207" [cl-struct-winds-workspace-tags 0 signal wrong-type-argument winds-workspace 1] 5 (#$ . 9632)]) (byte-code "\300\301\302\303#\304\305\306\"\207" [function-put winds-workspace-cfgs side-effect-free t defalias copy-winds-workspace copy-sequence] 4) #@88 compiler-macro for inlining `make-winds-workspace'. (fn CL-WHOLE &cl-quote &key CFGS) (defalias 'make-winds-workspace--cmacro #[385 "\300\301\"A@\211\2031\211@\302>\203\211AA\262\202\303>A@\203(\304\262\202\305\306@\"\210\202\210\307\310\311\304\304&\207" [plist-member :cfgs (:cfgs :allow-other-keys) :allow-other-keys nil error "Keyword argument %s not one of (:cfgs)" cl--defsubst-expand (cfgs) (cl-block make-winds-workspace (vector 'winds-workspace cfgs))] 10 (#$ . 10040)]) (put 'make-winds-workspace 'compiler-macro 'make-winds-workspace--cmacro) #@68 Constructor for objects of type `winds-workspace'. (fn &key CFGS) (defalias 'make-winds-workspace #[128 "\300\301\"A@\211\2031\211@\302>\203\211AA\262\202\303>A@\203(\304\262\202\305\306@\"\210\202\210\307\310\"\207" [plist-member :cfgs (:cfgs :allow-other-keys) :allow-other-keys nil error "Keyword argument %s not one of (:cfgs)" vector winds-workspace] 6 (#$ . 10622)]) (byte-code "\300\301\302\303#\304\305\306\211\307\303\310\311\305\306& \207" [function-put make-winds-workspace side-effect-free t cl-struct-define winds-workspace nil vector ((cl-tag-slot) (cfgs)) cl-struct-winds-workspace-tags] 11) (defvar winds-*workspaces* nil) (defvar winds--*record-history* t) #@94 Get the currently selected workspace id in FRAME or the current frame. (fn &optional FRAME) (defalias 'winds-get-cur-ws #[256 "\301\302\303\304\"\"\206 \207" [winds-default-ws alist-get :cur-ws frame-parameter winds--state] 6 (#$ . 11320)]) #@178 Get the currently selected window config slot id in FRAME in workspace WSID. FRAME defaults to current frame. WSID defaults to current workspace id. (fn &optional FRAME WSID) (defalias 'winds-get-cur-cfg #[512 "\211\204\301 \262\302\303\302\302\304\305\306\"\"\"\"\206\207" [winds-default-cfg winds-get-cur-ws alist-get :cur-cfg :workspaces frame-parameter winds--state] 11 (#$ . 11572)]) #@210 Get the previously selected window config slot in FRAME in workspace WSID. FRAME defaults to current frame. WSID defaults to current workspace id. Returns nil if no last-cfg found. (fn &optional FRAME WSID) (defalias 'winds-get-last-cfg #[512 "\211\204 \300!\262\301\302\301\301\303\304\305\"\"\"\"\207" [winds-get-cur-ws alist-get :last-cfg :workspaces frame-parameter winds--state] 11 (#$ . 11979)]) #@144 Get the previously selected workspace slot in FRAME. FRAME defaults to current frame. Returns nil if no last-cfg found. (fn &optional FRAME) (defalias 'winds-get-last-ws #[256 "\300\301\302\303\"\"\207" [alist-get :last-ws frame-parameter winds--state] 6 (#$ . 12396)]) #@144 Get the previously selected (ws cfg) pair in FRAME. FRAME defaults to current frame. Returns nil if no last-cfg found. (fn &optional FRAME) (defalias 'winds-get-last-pos #[256 "\300\301\302\303\"\"\207" [alist-get :last-pos frame-parameter winds--state] 6 (#$ . 12676)]) #@228 Get the previously selected window config slot in FRAME in workspace WSID. FRAME defaults to current frame. WSID defaults to current workspace id. Returns `(winds-get-cur-cfg)' if no last-cfg found. (fn &optional FRAME WSID) (defalias 'winds-get-last-or-cur-cfg #[512 "\300\"\206 \301\"\207" [winds-get-last-cfg winds-get-cur-cfg] 5 (#$ . 12958)]) #@50 Get or create workspace in slot WSID. (fn WSID) (defalias 'winds--get-or-create-ws #[257 "\301\"\211\204'\302\303\304\"\262\236\203\241\266\207B\211\262B\266\207" [winds-*workspaces* alist-get vector winds-workspace nil] 6 (#$ . 13319)]) #@70 Save the current window config to the current slot if slot is empty. (defalias 'winds--save-cfg-if-empty #[0 "\301 \302 \303!\211\304H>\204\305\306\307D\"\210\211\310H\311\"?\205(\312\313\314$\207" [cl-struct-winds-workspace-tags winds-get-cur-ws winds-get-cur-cfg winds--get-or-create-ws 0 signal wrong-type-argument winds-workspace 1 alist-get winds-save-cfg :ws :cfg] 9 (#$ . 13583)]) #@39 Get the current set of workspace ids. (defalias 'winds--get-wsids #[0 "\301\211:\203@\262\211@C\244\262A\262\202\302 \303\"\203%\210\207\211B\207" [winds-*workspaces* nil winds-get-cur-ws memql] 7 (#$ . 13988)]) #@85 Get the current set of window config ids. (fn &optional (WSID (winds-get-cur-ws))) (defalias 'winds--get-cfgids #[128 "\211\203 \211A\262\242\202\301 \203\302\303\304GTD\"\210\305!\211\306H>\204.\302\307\310D\"\210\211\311H\312\211:\203J@\262\211@C\244\262A\262\2023\301 =\203a\313 \314\"\203\\\210\207\211B\266\202\207" [cl-struct-winds-workspace-tags winds-get-cur-ws signal wrong-number-of-arguments winds--get-cfgids winds--get-or-create-ws 0 wrong-type-argument winds-workspace 1 nil winds-get-cur-cfg memql] 10 (#$ . 14222)]) (defalias 'winds--before-config-change #[0 "\205^\301 \302U?\303\304\305\306\"\236\203\241\266\202.\303B\211\262\304\305\306\"B\307\305\306#\266\211?\205\\\310\304\305\306\"\236\311\305\312\"\203H\241\210\202Z\310B\211\262\304\305\306\"B\307\305\306#\266\262\262\207" [winds--*record-history* minibuffer-depth 0 :maybe-old-minibuf-open-p frame-parameter nil winds--state set-frame-parameter :maybe-old-window-config window-state-get t] 8]) #@71 Save the window config to the current active cfg slot's history ring. (defalias 'winds--on-config-change #[0 "\203p\302\303\304\305\306\"\"\203p\302\307\304\305\306\"\"\204p\310 \311 \312!\211\313H >\204.\314\315\316D\"\210\211\317H\302\"\320\302\303\304\305\306\"\"\"\210\303\304\305\306\"\236\211\203R\211\305\241\266\202c\303C\211\262\304\305\306\"B\321\305\306#\266\322\305\"\210\323 \210\324!\266\325\211\207" [winds--*record-history* cl-struct-winds-workspace-tags alist-get :maybe-old-window-config frame-parameter nil winds--state :maybe-old-minibuf-open-p winds-get-cur-ws winds-get-cur-cfg winds--get-or-create-ws 0 signal wrong-type-argument winds-workspace 1 winds--ring-replace-or-insert set-frame-parameter winds--ring-insert winds-save-cfg winds--ring-clear-forward t] 12 (#$ . 15255)]) (byte-code "\300\301\302\303\304DD\305\306\307\310\311\312\313& \207" [custom-declare-variable winds-mode funcall function #[0 "\300\207" [nil] 1] "Non-nil if Winds mode is enabled.\nSee the `winds-mode' command\nfor a description of this minor mode.\nSetting this variable directly does not take effect;\neither customize it (see the info node `Easy Customization')\nor call the function `winds-mode'." :set custom-set-minor-mode :initialize custom-initialize-default :type boolean] 10) #@615 Toggle winds.el window config and workspace manager. This is a minor mode. If called interactively, toggle the `Winds mode' mode. If the prefix argument is positive, enable the mode, and if it is zero or negative, disable the mode. If called from Lisp, toggle the mode if ARG is `toggle'. Enable the mode if ARG is nil, omitted, or is a positive number. Disable the mode if ARG is a negative number. To check whether the minor mode is enabled in the current buffer, evaluate `(default-value 'winds-mode)'. The mode's hook is called both when the mode is enabled and when it is disabled. (fn &optional ARG) (defalias 'winds-mode #[256 "\302 \303\301\304=\203\305\301!?\202!\247\203 \306W\203 \307\202!\310\"\210\311\300!\2038\312\301\"\305\301!\2038\301B \203?\313 \210 \203K\314\315\316\"\210\202U\311\317!\203U\320\310!\210\321\322\305\301!\203a\323\202b\324\"\210\325\326!\203\212\327\301!\210\302 \203z\211\302 \232\203\212\330\331\305\301!\203\206\332\202\207\333\334#\210\210\335 \210\305\301!\207" [global-minor-modes winds-mode current-message set-default toggle default-value 1 nil t boundp delq winds-save-cfg eval-after-load desktop #[0 "\300 \207" [winds-enable-desktop-save] 1] desktop-save-mode winds-enable-desktop-save run-hooks winds-mode-hook winds-mode-on-hook winds-mode-off-hook called-interactively-p any customize-mark-as-set message "Winds mode %sabled%s" "en" "dis" "" force-mode-line-update] 6 (#$ . 16572) (byte-code "\203\n\301!\202 \302C\207" [current-prefix-arg prefix-numeric-value toggle] 2)]) (defvar winds-mode-hook nil) (byte-code "\301\302N\204\f\303\301\302\304#\210\303\301\305\306#\210\303\301\307\310C#\210\311\312\310\313\300!\205#\310\211%\210\314\315\316\317\320DD\321\322\323\324\325\326\327& \207" [winds-mode-map winds-mode-hook variable-documentation put "Hook run after entering or leaving `winds-mode'.\nNo problems result if this variable is not bound.\n`add-hook' automatically binds it. (This is true for all hook variables.)" custom-type hook standard-value nil add-minor-mode winds-mode boundp custom-declare-variable winds-history-mode funcall function #[0 "\300\207" [nil] 1] "Non-nil if Winds-History mode is enabled.\nSee the `winds-history-mode' command\nfor a description of this minor mode.\nSetting this variable directly does not take effect;\neither customize it (see the info node `Easy Customization')\nor call the function `winds-history-mode'." :set custom-set-minor-mode :initialize custom-initialize-default :type boolean] 10) #@786 Toggle winds.el history mode. This is a minor mode. If called interactively, toggle the `Winds-History mode' mode. If the prefix argument is positive, enable the mode, and if it is zero or negative, disable the mode. If called from Lisp, toggle the mode if ARG is `toggle'. Enable the mode if ARG is nil, omitted, or is a positive number. Disable the mode if ARG is a negative number. To check whether the minor mode is enabled in the current buffer, evaluate `(default-value 'winds-history-mode)'. The mode's hook is called both when the mode is enabled and when it is disabled. Saves history of window config changes within a window-config slot in winds.el. Use this global minor mode to replace `winner-mode` and have a more relevant history ring saved. (fn &optional ARG) (defalias 'winds-history-mode #[256 "\302 \303\301\304=\203\305\301!?\202!\247\203 \306W\203 \307\202!\310\"\210\311\300!\2038\312\301\"\305\301!\2038\301B \203I\313\314\315\"\210\313\316\317\"\210\202S\320\314\315\"\210\320\316\317\"\210\321\322\305\301!\203_\323\202`\324\"\210\325\326!\203\210\327\301!\210\302 \203x\211\302 \232\203\210\330\331\305\301!\203\204\332\202\205\333\334#\210\210\335 \210\305\301!\207" [global-minor-modes winds-history-mode current-message set-default toggle default-value 1 nil t boundp delq add-hook pre-command-hook winds--before-config-change window-configuration-change-hook winds--on-config-change remove-hook run-hooks winds-history-mode-hook winds-history-mode-on-hook winds-history-mode-off-hook called-interactively-p any customize-mark-as-set message "Winds-History mode %sabled%s" "en" "dis" "" force-mode-line-update] 6 (#$ . 19117) (byte-code "\203\n\301!\202 \302C\207" [current-prefix-arg prefix-numeric-value toggle] 2)]) (defvar winds-history-mode-hook nil) (byte-code "\301\302N\204\f\303\301\302\304#\210\303\301\305\306#\210\303\301\307\310C#\210\311\312\310\313\300!\205#\310\211%\207" [winds-history-mode-map winds-history-mode-hook variable-documentation put "Hook run after entering or leaving `winds-history-mode'.\nNo problems result if this variable is not bound.\n`add-hook' automatically binds it. (This is true for all hook variables.)" custom-type hook standard-value nil add-minor-mode winds-history-mode boundp] 6) #@239 Enable or disable (if DISABLE) saving of winds workspaces with desktop.el. NOTE: This function loads feature `desktop' if not loaded already. You should probably put this in a `with-eval-after-load' clause. (fn &optional DISABLE) (defalias 'winds-enable-desktop-save #[256 "\301\302!\210\211\203-\303\211:\203&@\262\304=\204B\262A\262\202 \211\237\266\203\211\207\304>\2035\207\304B\211\207" [desktop-globals-to-save require desktop nil winds-*workspaces*] 6 (#$ . 21423) nil]) #@78 Display a status message in the echo area with the current ws id and cfg id. (defalias 'winds-display-status-msg #[0 "\301\302 \303\"\301\304 \303\"\305\306\307\"\305\310\311\"\305\306\311\"\307\311F\307\311F\312\313\314#\"\312\313\315#\"\316\317\"\316\317\"\320\321\322#P\320\323\322 #P\324\325\326#)\207" [message-log-max sort winds--get-wsids < winds--get-cfgids face-attribute mode-line-inactive :background mode-line :foreground mapcar make-closure #[257 "\211\302 =\203\303\304\305\"\306\300#\207\303\304\305\"\306\301#\207" [V0 V1 winds-get-cur-ws propertize format "%s " face] 5 "\n\n(fn ID)"] #[257 "\211\302 =\203\303\304\305\"\306\300#\207\303\304\305\"\306\301#\207" [V0 V1 winds-get-cur-cfg propertize format " %s" face] 5 "\n\n(fn ID)"] cl-reduce concat propertize "W " face " C" nil message "%s|%s"] 17 (#$ . 21936) nil]) #@427 Save current window configuration into workspace WS, config CFG. WS defaults to current workspace CFG defaults to current cfg if WS is current or to `winds-default-cfg' Call interactively to be prompted for a workspace and window config to save to. Call interactively with a prefix argument to save to the current window config slot in the current workspace. (fn &key ((:ws WSID) (winds-get-cur-ws)) ((:cfg CFGID) nil)) (defalias 'winds-save-cfg #[128 "\303\304\"\206 \305\306 DA@\303\307\"A@\211\203>\211@\310>\203'\211AA\262\202\311>A@\2035\305\262\202\312\313@\"\210\202\210\211\204R\306 =\203O\314 \202P\262\315!\316\317H >\204f\320\321\322D\"\210\323H\"\203\212\316\317H >\204~\320\321\322D\"\210\323H\"\324\325\305\326\"\"\207\211\317H >\204\231\320\321\322D\"\210\211\323H\236\327\n!\203\256\241\266\202\276\323B\211\262\323HBI\266\330\304\307$\207" [winds-default-cfg cl-struct-winds-workspace-tags winds-history-size plist-member :ws nil winds-get-cur-ws :cfg (:ws :cfg :allow-other-keys) :allow-other-keys error "Keyword argument %s not one of (:ws :cfg)" winds-get-cur-cfg winds--get-or-create-ws alist-get 0 signal wrong-type-argument winds-workspace 1 winds--ring-replace-or-insert window-state-get t make-winds--ring winds-save-cfg] 12 (#$ . 22810) (byte-code "?\205\"\301\302\303\304\211\305\304\306\307\310 \"&\311\302\312\304\211\305\304\306\307\313 \"&F\207" [current-prefix-arg :ws read-from-minibuffer "Workspace to save window config to (blank for current): " nil t format "%s" winds-get-cur-ws :cfg "Window config slot to save to (blank for current): " winds-get-cur-cfg] 12)]) #@328 Switch to another workspace and/or window config slot. Call interactively to be prompted for a workspace and window config to swtich to. Call interactively with a prefix argument to go to the last selected window config slot in the current workspace. (fn &key ((:ws WSID) (winds-get-cur-ws)) ((:cfg CFGID) nil) (DO-SAVE t)) (defalias 'winds-goto #[128 "\303\304\"\206 \305\306 DA@\303\307\"A@\303\310\"\206\311A@\211\203H\211@\312>\2031\211AA\262\202\313>A@\203?\305\262\202\314\315@\"\210\202\210\204S\316\305\"\262\211\203Z\317 \210\306 \320 =\204\211\321\322\305\323\"\236\203w\241\266\202\211\321B\211\262\322\305\323\"B\324\305\323#\266\325\322\305\323\"\236A\236\326A\236\203\244\241\266\202\341\326B\211\262AB\203\271\241\266\202\341B\211\262AB\203\317\241\266\202\341\325B\211\262\322\305\323\"B\324\305\323#\266\327\322\305\323\"\236B\203\366\241\266\202\327B\211\262\322\305\323\"B\324\305\323#\266\330\322\305\323\"\236\203\241\266\202-\330B\211\262\322\305\323\"B\324\305\323#\266\325\322\305\323\"\236A\236\331A\236\203H\241\266\202\205\331B\211\262AB\203]\241\266\202\205B\211\262AB\203s\241\266\202\205\325B\211\262\322\305\323\"B\324\305\323#\266\332!\211\333H>\204\227\334\335\336D\"\210\211\337H\340\"\211\203\266\341\333\"\305\342\343 \344#\210\345 \266\202\312\305\346\347#\210\317\304\307$\266\n\205\320\302 \207" [cl-struct-winds-workspace-tags winds--*record-history* winds-display-status-msg plist-member :ws nil winds-get-cur-ws :cfg :do-save (nil t) (:ws :cfg :do-save :allow-other-keys) :allow-other-keys error "Keyword argument %s not one of (:ws :cfg :do-save)" winds-get-last-or-cur-cfg winds-save-cfg winds-get-cur-cfg :last-ws frame-parameter winds--state set-frame-parameter :workspaces :last-cfg :last-pos :cur-ws :cur-cfg winds--get-or-create-ws 0 signal wrong-type-argument winds-workspace 1 alist-get winds--ring-ref window-state-put frame-root-window safe redisplay run-hook-with-args winds-init-cfg-hook] 17 (#$ . 24482) (byte-code "?\205\301\302\303\304\211\305\304\306\307\310 \"&\311\302\312\304\211\305\304\313&F\207" [current-prefix-arg :ws read-from-minibuffer "Workspace to switch to (blank for current): " nil t format "%s" winds-get-cur-ws :cfg "Window config slot to switch to (blank for last selected): " "nil"] 10)]) #@47 Go to the previously selected workspace slot. (defalias 'winds-last #[0 "\300\301\302 \"\207" [winds-goto :ws winds-get-last-ws] 3 (#$ . 26919) nil]) #@76 Go to the previously selected window config slot in the current workspace. (defalias 'winds-cfg-last #[0 "\300\301\302 \"\207" [winds-goto :cfg winds-get-last-cfg] 3 (#$ . 27075) nil]) #@65 Go to the previously selected window config slot and workspace. (defalias 'winds-pos-last #[0 "\300 \301\302@\303A$\207" [winds-get-last-pos winds-goto :ws :cfg] 6 (#$ . 27266) nil]) #@28 Go to next workspace slot. (defalias 'winds-next #[0 "\300 \210\301\302 \303\"\304\305 \"T\211GU\203\306\307!\210\310\262\311\3128\"\207" [winds--save-cfg-if-empty sort winds--get-wsids < cl-position winds-get-cur-ws message "Already on last workspace. Wrapping back to first." 0 winds-goto :ws] 6 (#$ . 27457) nil]) #@32 Go to previous workspace slot. (defalias 'winds-prev #[0 "\300 \210\301\302 \303\"\304\305 \"T\211GU\203\306\307!\210\310\262\311\3128\"\207" [winds--save-cfg-if-empty sort winds--get-wsids > cl-position winds-get-cur-ws message "Already on first workspace. Wrapping back to last." 0 winds-goto :ws] 6 (#$ . 27787) nil]) #@32 Go to next window config slot. (defalias 'winds-cfg-next #[0 "\300 \210\301\302 \303\"\304\305 \"T\211GU\203\306\307!\210\310\262\311\3128\"\207" [winds--save-cfg-if-empty sort winds--get-cfgids < cl-position winds-get-cur-cfg message "Already on last window config. Wrapping back to first." 0 winds-goto :cfg] 6 (#$ . 28121) nil]) #@36 Go to previous window config slot. (defalias 'winds-cfg-prev #[0 "\300 \210\301\302 \303\"\304\305 \"T\211GU\203\306\307!\210\310\262\311\3128\"\207" [winds--save-cfg-if-empty sort winds--get-cfgids > cl-position winds-get-cur-cfg message "Already on first window config. Wrapping back to last." 0 winds-goto :cfg] 6 (#$ . 28466) nil]) #@205 Close workspace slot WSID. Close workspace slot WSID and switch to nearest slot or `winds-default-ws' if none open. If interactive, you are prompted for an id or blank to close current ws. (fn WSID) (defalias 'winds-close #[257 "\302\303 \304\"\305\"\2033\236\211\203\306\"\210\307 =\2057\310\311\312\"\"@\313\314\206/ \315\316$\207\317\320\"\207" [winds-*workspaces* winds-default-ws sort winds--get-wsids < memql delq winds-get-cur-ws cl-remove-if make-closure #[257 "\300=\207" [V0] 3 "\n\n(fn E)"] winds-goto :ws :do-save nil message "Workspace %s does not exist!"] 8 (#$ . 28816) (byte-code "\300\301\302\211\303\302\304\305\306 \"&C\207" [read-from-minibuffer "Workspace to close (blank for current): " nil t format "%s" winds-get-cur-ws] 9)]) #@217 Close window config slot CFGID. Close window config slot CFGID and switch to nearest slot or `winds-default-cfg' if none open. If interactive, you are prompted for an id or blank to close current cfg (fn CFGID) (defalias 'winds-cfg-close #[257 "\302\303 \304\"\305\306 !\307\"\203O\211\310H>\204\311\312\313D\"\210\211\314H\236\211\2033\314\315\314H\"I\210\266\316 =\205S\317\320\321\"\"@\322\323\206K \324\325$\207\326\327\"\207" [cl-struct-winds-workspace-tags winds-default-cfg sort winds--get-cfgids < winds--get-or-create-ws winds-get-cur-ws memql 0 signal wrong-type-argument winds-workspace 1 delq winds-get-cur-cfg cl-remove-if make-closure #[257 "\300=\207" [V0] 3 "\n\n(fn E)"] winds-goto :cfg :do-save nil message "Window config %s does not exist!"] 11 (#$ . 29597) (byte-code "\300\301\302\211\303\302\304\305\306 \"&C\207" [read-from-minibuffer "Window config to close (blank for current): " nil t format "%s" winds-get-cur-cfg] 9)]) #@138 Go back or forward in the window config history for the current slot. Go forward in the history if REDO is non-nil (fn &optional REDO) (defalias 'winds-history-undo #[256 "\302 \303 \304!\211\305H>\204\306\307\310D\"\210\211\311H\312\"\203;\313!\2034\314\315\316!\317!#\210\202T\320!\210\202T\316!\311U\203P\314\321\316!\317!#\210\202T\322!\210\323\324\325\305\"\326 \327#\210\330 \210\316!\317!\203v\331\332\333#!\207\331\332\334#!\207" [cl-struct-winds-workspace-tags winds--*record-history* winds-get-cur-ws winds-get-cur-cfg winds--get-or-create-ws 0 signal wrong-type-argument winds-workspace 1 alist-get winds--ring-fwd-empty-p user-error "Already at latest position in history: (%d/%d)" winds--ring-rwnd-length winds--ring-total-length winds--ring-forward "Already at first position in history: (%d/%d)" winds--ring-rewind nil window-state-put winds--ring-ref frame-root-window safe redisplay message format "Redo! (%d/%d)" "Undo! (%d/%d)"] 13 (#$ . 30579) nil]) #@62 Go forward in the window config history for the current slot (defalias 'winds-history-redo #[0 "\300\301!\207" [winds-history-undo t] 2 (#$ . 31590) nil]) (provide 'winds)