403Webshell
Server IP : 217.160.0.212  /  Your IP : 216.73.216.76
Web Server : Apache
System : Linux www 6.18.52-i1-ampere #1203 SMP Mon Sep 14 18:29:59 CEST 2026 aarch64
User : sws1073854427 ( 1073854427)
PHP Version : 8.4.23
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /usr/share/emacs/28.2/lisp/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/share/emacs/28.2/lisp//scroll-bar.elc
;ELC
;;; Compiled
;;; in Emacs version 28.2
;;; with all optimizations.



(require 'mouse)
#@271 Given a scroll bar event EVENT, return the scroll bar position as a ratio.
The value is a cons cell (PORTION . WHOLE) containing two integers
whose ratio gives the event's vertical position in the scroll bar, with 0
referring to the top and 1 to the bottom.

(fn EVENT)
(defalias 'scroll-bar-event-ratio #[257 "\3008\207" [2] 3 (#$ . 102)])
#@394 Given a pair (NUM . DENOM) and WHOLE, return (/ (* NUM WHOLE) DENOM).
This is handy for scaling a position on a scroll bar into real units,
like buffer positions.  If SCROLL-BAR-POS is the (PORTION . WHOLE) pair
from a scroll bar event, then (scroll-bar-scale SCROLL-BAR-POS
(buffer-size)) is the position in the current buffer corresponding to
that scroll bar position.

(fn NUM-DENOM WHOLE)
(defalias 'scroll-bar-scale #[514 "\300@_A\"\207" [truncate] 5 (#$ . 451)])
#@129 Return the width, measured in columns, of the vertical scrollbar on SIDE.
SIDE must be the symbol `left' or `right'.

(fn SIDE)
(defalias 'scroll-bar-columns #[257 "\300 \3018A@\302>\204\303\304\"\207=\203\211\2064\305\306\307\"=\2033\310\305\306\311\"\206/\312\313 \"\207\314\207" [window-scroll-bars 2 (left right) error "`left' or `right' expected instead of %S" frame-parameter nil vertical-scroll-bars ceiling scroll-bar-width 14 frame-char-width 0] 8 (#$ . 930)])
#@68 Return the height, measured in lines, of the horizontal scrollbar.
(defalias 'scroll-bar-lines #[0 "\300 \3018\3028\203
\207\303\304\305\"\203!\306\303\304\307\"\206\310\311 \"\207\312\207" [window-scroll-bars 5 4 frame-parameter nil horizontal-scroll-bars ceiling scroll-bar-height 14 frame-char-width 0] 7 (#$ . 1420)])
(defvar previous-scroll-bar-mode nil)
#@125 Non-nil means `set-scroll-bar-mode' should really do something.
This is nil while loading `scroll-bar.el', and t afterward.
(defvar scroll-bar-mode-explicit nil (#$ . 1794))
#@144 Set the scroll bar mode to VALUE and put the new value into effect.
See the `scroll-bar-mode' variable for possible values to use.

(fn VALUE)
(defalias 'set-scroll-bar-mode #[257 "\203\211\n\205\303\304BC!\207" [scroll-bar-mode previous-scroll-bar-mode scroll-bar-mode-explicit modify-all-frames-parameters vertical-scroll-bars] 4 (#$ . 1975)])
(byte-code "\301\302\303\304\305DD\306\307\310\311\312\313\314\315\316&\210\317\301\207" [scroll-bar-mode-explicit custom-declare-variable scroll-bar-mode funcall function #[0 "\207" [default-frame-scroll-bars] 1 ""] "Specify whether to have vertical scroll bars, and on which side.\nPossible values are nil (no scroll bars), `left' (scroll bars on left)\nand `right' (scroll bars on right).\nTo set this variable in a Lisp program, use `set-scroll-bar-mode'\nto make it take real effect.\nSetting the variable with a customization buffer also takes effect." :type (choice (const :tag "none (nil)" nil) (const left) (const right)) :group frames :initialize custom-initialize-default :set #[514 "\300!\207" [set-scroll-bar-mode] 4 "\n\n(fn SYM VAL)"] t] 12)
(defalias 'get-scroll-bar-mode #[0 "\207" [scroll-bar-mode] 1])
(byte-code "\300\301\302\303#\300\207" [function-put get-scroll-bar-mode gv-expander #[385 "\300\301\302$\207" [gv--defsetter get-scroll-bar-mode #[385 "\300\301C\"B\207" [set-scroll-bar-mode append] 6 "\n\n(fn VAL &rest ARGS)"]] 7 "\n\n(fn DO &rest ARGS)"]] 4)
#@710 Toggle vertical scroll bars on all frames (Scroll Bar mode).

This is a minor mode.  If called interactively, toggle the `Scroll-Bar
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 `(get-scroll-bar-mode)'.

The mode's hook is called both when the mode is enabled and when it is
disabled.

This command applies to all frames that exist and frames to be
created in the future.

(fn &optional ARG)
(defalias 'scroll-bar-mode #[256 "\303 \304=\203\305 ?\202\247\203\306W\203\307\202\310\311\205(\206(	!\266\312\302!\203?\313\314\n\"\305 \203?\314\nB\315\316\305 \203J\317\202K\320\"\210\321\322!\203n\303 \203_\211\303 \232\203n\323\324\305 \203j\325\202k\326\327#\210\210\330 \210\305 \207" [previous-scroll-bar-mode default-frame-scroll-bars local-minor-modes current-message toggle get-scroll-bar-mode 1 nil t set-scroll-bar-mode boundp delq scroll-bar-mode run-hooks scroll-bar-mode-hook scroll-bar-mode-on-hook scroll-bar-mode-off-hook called-interactively-p any message "Scroll-Bar mode %sabled%s" "en" "dis" " in current buffer" force-mode-line-update] 6 (#$ . 3429) (byte-code "\203\n\301!\202\302C\207" [current-prefix-arg prefix-numeric-value toggle] 2)])
(defvar scroll-bar-mode-hook nil)
(byte-code "\300\301N\204\f\302\300\301\303#\210\302\300\304\305#\210\302\300\306\307C#\207" [scroll-bar-mode-hook variable-documentation put "Hook run after entering or leaving `scroll-bar-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] 4)
#@74 Return non-nil when horizontal scroll bars are available on this system.
(defalias 'horizontal-scroll-bars-available-p #[0 "\301 \205\f\302\300!\205\f\207" [x-toolkit-scroll-bars display-graphic-p boundp] 2 (#$ . 5345)])
(byte-code "\300\301\302\303\304DD\305\306\307\310\311\312\313\314\315&\207" [custom-declare-variable horizontal-scroll-bar-mode funcall function #[0 "\300\207" [nil] 1 ""] "Non-nil if Horizontal-Scroll-Bar mode is enabled.\nSee the `horizontal-scroll-bar-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 `horizontal-scroll-bar-mode'." :set custom-set-minor-mode :initialize custom-initialize-default :type boolean :group frames] 12)
#@758 Toggle horizontal scroll bars on all frames (Horizontal Scroll Bar mode).

This is a minor mode.  If called interactively, toggle the
`Horizontal-Scroll-Bar 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 \='horizontal-scroll-bar-mode)'.

The mode's hook is called both when the mode is enabled and when it is
disabled.

This command applies to all frames that exist and frames to be
created in the future.

(fn &optional ARG)
(defalias 'horizontal-scroll-bar-mode #[256 "\303 \304\301\305=\203\306\301!?\202!\247\203 \307W\203 \310\202!\311\"\210\312\300!\2038\313\301\"\306\301!\2038\301B	\203J\314 \204J\310\315\316!\210\202i\317 \211\203_\211@\320\321	#\210A\266\202\202L\210\321	B\322\321\n\"B\323\324\306\301!\203u\325\202v\326\"\210\327\330!\203\236\331\301!\210\303 \203\216\211\303 \232\203\236\315\332\306\301!\203\232\333\202\233\334\335#\210\210\336 \210\306\301!\207" [global-minor-modes horizontal-scroll-bar-mode default-frame-alist current-message set-default toggle default-value 1 nil t boundp delq horizontal-scroll-bars-available-p message "Horizontal scroll bars are not implemented on this system" frame-list set-frame-parameter horizontal-scroll-bars assq-delete-all run-hooks horizontal-scroll-bar-mode-hook horizontal-scroll-bar-mode-on-hook horizontal-scroll-bar-mode-off-hook called-interactively-p any customize-mark-as-set "Horizontal-Scroll-Bar mode %sabled%s" "en" "dis" "" force-mode-line-update] 8 (#$ . 6153) (byte-code "\203\n\301!\202\302C\207" [current-prefix-arg prefix-numeric-value toggle] 2)])
(defvar horizontal-scroll-bar-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" [horizontal-scroll-bar-mode-map horizontal-scroll-bar-mode-hook variable-documentation put "Hook run after entering or leaving `horizontal-scroll-bar-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 horizontal-scroll-bar-mode boundp] 6)
#@283 Toggle whether or not the selected frame has vertical scroll bars.
With ARG, turn vertical scroll bars on if and only if ARG is positive.
The variable `scroll-bar-mode' controls which side the scroll bars are on
when they are turned on; if it is nil, they go on the left.

(fn ARG)
(defalias 'toggle-scroll-bar #[257 "\211\204\302\303\304\"\203\305\202\306\262\202\307!\262\310\311 \304\312V\205)\206)	BC\"\207" [scroll-bar-mode default-frame-scroll-bars frame-parameter nil vertical-scroll-bars -1 1 prefix-numeric-value modify-frame-parameters selected-frame 0] 6 (#$ . 8615) "P"])
#@151 Toggle whether or not the selected frame has horizontal scroll bars.
With ARG, turn vertical scroll bars on if and only if ARG is positive.

(fn ARG)
(defalias 'toggle-horizontal-scroll-bar #[257 "\211\204\300\301\302\"\203\303\202\304\262\202\305!\262\306\307 \302\310V\205%\311BC\"\207" [frame-parameter nil horizontal-scroll-bars -1 1 prefix-numeric-value modify-frame-parameters selected-frame 0 bottom] 6 (#$ . 9221) "P"])
#@130 Set the window start according to where the scroll bar is dragged.
EVENT should be a scroll bar click or drag event.

(fn EVENT)
(defalias 'scroll-bar-set-window-start #[257 "\300!\211@\3018r\302!q\210\212e\303deZ\"\\b\210\304 \210\305`\"*\207" [event-end 2 window-buffer scroll-bar-scale beginning-of-line set-window-start] 9 (#$ . 9669) "e"])
#@64 Calculate new window start for drag event.

(fn PORTION-WHOLE)
(defalias 'scroll-bar-drag-position #[257 "\212e\300deZ\"\\b\210\301 \210`)\207" [scroll-bar-scale beginning-of-line] 6 (#$ . 10025)])
#@200 Set the window start according to where the scroll bar is dragged.
Only change window start if the new start is substantially different.
EVENT should be a scroll bar click or drag event.

(fn EVENT)
(defalias 'scroll-bar-maybe-set-window-start #[257 "\300!\211@\3018\211@TAB\302\211\303!r\304!q\210\305!\262\305!T]\262\211Y\2043\211W\203;\306\"\202@\306\")\207" [event-end 2 nil window-start window-buffer scroll-bar-drag-position set-window-start] 11 (#$ . 10231) "e"])
#@14 

(fn EVENT)
(defalias 'scroll-bar-drag-1 #[257 "\301!\211@\3028\204!\211@\247\203!\211A\247\203!\211@AU?\205<\212r\303!q\210e\304deZ\"\\b\210\305\306\"\210\307`\"*\207" [scroll-bar-adjust-thumb-portion event-start 2 window-buffer scroll-bar-scale vertical-motion 0 set-window-start] 9 (#$ . 10730)])
#@145 Scroll the window by dragging the scroll bar slider.
If you click outside the slider, the window scrolls to bring the slider there.

(fn EVENT)
(defalias 'scroll-bar-drag #[257 "\211C\302C\303\304\242!\211@\302r\305!q\210	\262)\306 r\307\310\"\216\311\312\"\210\206)`\262*\210\313\242!\210\314\307\315#!\210\316\303!\210r\305!q\210\211\211*\207" [echo-keystrokes point-before-scroll nil 0 event-end window-buffer internal--before-save-selected-window make-closure #[0 "\301\300!\207" [V0 internal--after-save-selected-window] 2] select-window mark-for-redisplay scroll-bar-drag-1 internal--track-mouse #[0 "\301\242?\205/\300\302 \240\210\300\242\242\303=\203\300\302 \240\210\300\242\242\304=\203(\305\300\242!\210\202\301\306\240\210\202\207" [V0 V1 read-event mouse-movement scroll-bar-movement scroll-bar-drag-1 t] 2] sit-for] 11 (#$ . 11050) "e"])
#@14 

(fn EVENT)
(defalias 'scroll-bar-horizontal-drag-1 #[257 "\300!\211@\3018\302\303!!\304\305!!\306=\203\"\307@S\\\245\"\207\307A@ZS\\\245\"\207" [event-start 2 frame-char-width window-frame current-bidi-paragraph-direction window-buffer left-to-right set-window-hscroll] 9 (#$ . 11933)])
#@158 Scroll the window horizontally by dragging the scroll bar slider.
If you click outside the slider, the window scrolls to bring the slider there.

(fn EVENT)
(defalias 'scroll-bar-horizontal-drag #[257 "\211C\302C\303\304\242!\211@\302r\305!q\210	\262)\306 r\307\310\"\216\311\312\"\210\206)`\262*\210\313\242!\210\314\307\315#!\210\316\303!\210r\305!q\210\211\211*\207" [echo-keystrokes point-before-scroll nil 0 event-end window-buffer internal--before-save-selected-window make-closure #[0 "\301\300!\207" [V0 internal--after-save-selected-window] 2] select-window mark-for-redisplay scroll-bar-horizontal-drag-1 internal--track-mouse #[0 "\301\242?\205/\300\302 \240\210\300\242\242\303=\203\300\302 \240\210\300\242\242\304=\203(\305\300\242!\210\202\301\306\240\210\202\207" [V0 V1 read-event mouse-movement scroll-bar-movement scroll-bar-horizontal-drag-1 t] 2] sit-for] 11 (#$ . 12243) "e"])
#@124 Scroll the window's top line down to the location of the scroll bar click.
EVENT should be a scroll bar click.

(fn EVENT)
(defalias 'scroll-bar-scroll-down #[257 "\301!\211@\302Cr\303!q\210\211\240\210)\304\305#\216\306 r\304\307\"\216\3108\311\312\"\210\211\242\206/`\240\210\313\314\315 S\"!\266\316\317!*\262)\207" [point-before-scroll event-end nil window-buffer make-closure #[0 "r\303\300!q\210\301\242\211)\207" [V0 V1 point-before-scroll window-buffer] 2] internal--before-save-selected-window #[0 "\301\300!\207" [V0 internal--after-save-selected-window] 2] 2 select-window mark-for-redisplay scroll-down scroll-bar-scale window-height sit-for 0] 10 (#$ . 13173) "e"])
#@120 Scroll the line next to the scroll bar click to the top of the window.
EVENT should be a scroll bar click.

(fn EVENT)
(defalias 'scroll-bar-scroll-up #[257 "\301!\211@\302Cr\303!q\210\211\240\210)\304\305#\216\306 r\304\307\"\216\3108\311\312\"\210\211\242\206/`\240\210\313\314\315 S\"!\266\316\317!*\262)\207" [point-before-scroll event-end nil window-buffer make-closure #[0 "r\303\300!q\210\301\242\211)\207" [V0 V1 point-before-scroll window-buffer] 2] internal--before-save-selected-window #[0 "\301\300!\207" [V0 internal--after-save-selected-window] 2] 2 select-window mark-for-redisplay scroll-up scroll-bar-scale window-height sit-for 0] 10 (#$ . 13873) "e"])
#@56 Handle event EVENT on vertical scroll bar.

(fn EVENT)
(defalias 'scroll-bar-toolkit-scroll #[257 "\301!\211@\3028\303\304=\206\233r\305!q\210\262)\306 r\307\310\"\216\311\312\"\210\206+`\262\313\267\202\213\314\315!\210\202\213\314\303!\210\202\213\3168\317\320 S\"\314\321U\204U\202a@\321W\203`\322\202a\323!\266\202\213\314\322!\210\202\213\314\323!\210\202\213\324e\"\210\202\213db\210\325 \210\202\213\326!\210*\210\327\321!\210r\305!q\210\211\211)\207" [point-before-scroll event-end 4 nil end-scroll window-buffer internal--before-save-selected-window make-closure #[0 "\301\300!\207" [V0 internal--after-save-selected-window] 2] select-window mark-for-redisplay #s(hash-table size 8 test eq rehash-size 1.5 rehash-threshold 0.8125 purecopy t data (above-handle 51 below-handle 58 ratio 65 up 103 down 110 top 117 bottom 125 handle 134)) scroll-up - 2 scroll-bar-scale window-height 0 -1 1 set-window-start recenter scroll-bar-drag-1 sit-for] 11 (#$ . 14564) "e"])
#@58 Handle event EVENT on horizontal scroll bar.

(fn EVENT)
(defalias 'scroll-bar-toolkit-horizontal-scroll #[257 "\301!\211@\3028\303\304!!\305=\203\306\202\307\310\311=\206\311r\304!q\210\262)\312 r\313\314\"\216\315\316\"\210\206:`\262\317\267\202\271\320\302_!\210\202\271\321\302_!\210\202\271\3228\323\324 S\"\320\325U\204i\202u@\325W\203t\307\202u\306_!\266\202\271\320\306_!\210\202\271\321\306_!\210\202\271\306=\203\233\326 \202\235\327 b\210\202\271\306=\203\255\327 \202\257\326 b\210\202\271\330!\210*\210\331\325!\210r\304!q\210\211\211)\207" [point-before-scroll event-end 4 current-bidi-paragraph-direction window-buffer left-to-right 1 -1 nil end-scroll internal--before-save-selected-window make-closure #[0 "\301\300!\207" [V0 internal--after-save-selected-window] 2] select-window mark-for-redisplay #s(hash-table size 8 test eq rehash-size 1.5 rehash-threshold 0.8125 purecopy t data (before-handle 66 after-handle 75 ratio 84 left 126 right 135 leftmost 144 rightmost 162 horizontal-handle 180)) scroll-right scroll-left 2 scroll-bar-scale window-width 0 line-beginning-position line-end-position scroll-bar-horizontal-drag-1 sit-for] 12 (#$ . 15578) "e"])
(byte-code "\301\300!\203\203\302\303\304\"\210\302\305\306\"\210\2020\302\307\310\"\210\302\311\310\"\210\302\312\313\"\210\302\314\315\"\210\302\316\315\"\210\317\320!\207" [x-toolkit-scroll-bars boundp global-set-key [vertical-scroll-bar mouse-1] scroll-bar-toolkit-scroll [horizontal-scroll-bar mouse-1] scroll-bar-toolkit-horizontal-scroll [vertical-scroll-bar mouse-1] scroll-bar-scroll-up [vertical-scroll-bar drag-mouse-1] [vertical-scroll-bar down-mouse-2] scroll-bar-drag [vertical-scroll-bar mouse-3] scroll-bar-scroll-down [vertical-scroll-bar drag-mouse-3] provide scroll-bar] 3)

Youez - 2016 - github.com/yon3zu
LinuXploit