Server IP : 111.118.215.189 / Your IP : 18.117.158.174 Web Server : Apache System : Linux md-in-83.webhostbox.net 4.19.286-203.ELK.el7.x86_64 #1 SMP Wed Jun 14 04:33:55 CDT 2023 x86_64 User : a1673wkz ( 2475) PHP Version : 8.2.25 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON Directory (0755) : /usr/share/emacs/24.3/lisp/erc/ |
[ Home ] | [ C0mmand ] | [ Upload File ] |
---|
;ELC ;;; Compiled by mockbuild@buildfarm06-new.corp.cloudlinux.com on Fri Oct 11 10:08:34 2024 ;;; from file /builddir/build/BUILD/emacs-24.3/lisp/erc/erc-button.el ;;; in Emacs version 24.3.1 ;;; with all optimizations. ;;; This file uses dynamic docstrings, first added in Emacs 19.29. ;;; This file does not contain utf-8 non-ASCII characters, ;;; and so can be loaded in Emacs versions earlier than 23. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (byte-code "\300\301!\210\300\302!\210\300\303!\210\304\305\306\307\310\301%\210\311\312\306\313\314\315\316\317\310\305\320\321&\207" [require erc wid-edit erc-fill custom-declare-group erc-button nil "Define how text can be turned into clickable buttons." :group custom-declare-variable erc-button-mode "Non-nil if Erc-Button mode is enabled.\nSee the command `erc-button-mode' for 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 `erc-button-mode'." :set custom-set-minor-mode :initialize custom-initialize-default :type boolean] 12) #@244 Toggle ERC button mode. With a prefix argument ARG, enable button if ARG is positive, and disable it otherwise. If called from Lisp, enable the mode if ARG is omitted or nil. This mode buttonizes all messages according to `erc-button-alist'. (defalias 'erc-button-mode #[(&optional arg) "\303 \304=\203 \n?\202 \305 !\306V\211\203 \307 \210\202! \310 \210\311\312\n\203+ \313\202, \314\"\210\315\316!\203Q \317\302!\210\303 \203D \303 \232\203Q \320\321\n\203N \322\202O \323\"\210)\324 \210\n\207" [#1=#:last-message arg erc-button-mode current-message toggle prefix-numeric-value 0 erc-button-enable erc-button-disable run-hooks erc-button-mode-hook erc-button-mode-on-hook erc-button-mode-off-hook called-interactively-p any customize-mark-as-set message "Erc-Button mode %sabled" "en" "dis" force-mode-line-update] 4 (#$ . 1219) (list (or current-prefix-arg 'toggle))]) (byte-code "\301\302\303\304\300!\205\n \303\211%\207" [erc-button-mode-map add-minor-mode erc-button-mode nil boundp] 6) #@25 Enable ERC button mode. (defalias 'erc-button-enable #[nil "\301\302\303\"\210\304\305\306\307\310#\210\305\311\307\310#\210\305\312\313\"\210\305\314\315\"\207" [erc-button-mode add-to-list erc-modules button t add-hook erc-insert-modify-hook erc-button-add-buttons append erc-send-modify-hook erc-complete-functions erc-button-next-function erc-mode-hook erc-button-setup] 4 (#$ . 2230) nil]) #@26 Disable ERC button mode. (defalias 'erc-button-disable #[nil "\302\303\"\304\305\306\307\"\210\305\310\307\"\210\305\311\312\"\210\305\313\314\"\210\304\207" [erc-modules erc-button-mode delq button nil remove-hook erc-insert-modify-hook erc-button-add-buttons erc-send-modify-hook erc-complete-functions erc-button-next-function erc-mode-hook erc-button-setup] 3 (#$ . 2632) nil]) (byte-code "\300\301\302\303#\210\300\304\302\303#\210\300\305\302\303#\210\306\307\310\311\312\313%\210\314\315\316\317\320\321\312\313&\210\314\322\323\324\320\321\312\313&\210\314\325\326\327\320\321\312\313&\210\314\330\331\332\312\307\320\333&\210\314\334\335\336\312\307\320\337&\210\314\340\341\342\312\307\320\343&\210\314\344\345\346\312\307\320\347&\210\314\350\351\352\312\307\320\347&\210\314\353\354\355\312\307\356\357\320\360& \210\314\361\362\363\312\307\320\347&\210\314\364\365\366\312\307\320\347&\207" [put erc-button-mode definition-name button erc-button-enable erc-button-disable custom-declare-face erc-button ((t :weight bold)) "ERC button face." :group erc-faces custom-declare-variable erc-button-face 'erc-button "Face used for highlighting buttons in ERC buffers.\n\nA button is a piece of text that you can activate by pressing\n`RET' or `mouse-2' above it. See also `erc-button-keymap'." :type face erc-button-nickname-face 'erc-nick-default-face "Face used for ERC nickname buttons." erc-button-mouse-face 'highlight "Face used for mouse highlighting in ERC buffers.\n\nButtons will be displayed in this face when the mouse cursor is\nabove them." erc-button-url-regexp (concat "\\(www\\.\\|\\(s?https?\\|" "ftp\\|file\\|gopher\\|news\\|telnet\\|wais\\|mailto\\):\\)" "\\(//[-a-zA-Z0-9_.]+:[0-9]*\\)?" "[-a-zA-Z0-9_=!?#$@~`%&*+\\/:;.,()]+[-a-zA-Z0-9_=#$@~`%&*+\\/()]") "Regular expression that matches URLs." regexp erc-button-wrap-long-urls nil "If non-nil, \"long\" URLs matching `erc-button-url-regexp' will be wrapped.\n\nIf this variable is a number, consider URLs longer than its value to\nbe \"long\". If t, URLs will be considered \"long\" if they are\nlonger than `erc-fill-column'." (choice integer boolean) erc-button-buttonize-nicks t "Flag indicating whether nicks should be buttonized or not." boolean erc-button-rfc-url "http://www.faqs.org/rfcs/rfc%s.html" "URL used to browse rfc references.\n%s is replaced by the number." string erc-button-google-url "http://www.google.com/search?q=%s" "URL used to browse Google search references.\n%s is replaced by the search string." erc-button-alist '(('nicknames 0 erc-button-buttonize-nicks erc-nick-popup 0) (erc-button-url-regexp 0 t browse-url 0) ("<URL: *\\([^<> ]+\\) *>" 0 t browse-url 1) ("[`]\\([a-zA-Z][-a-zA-Z_0-9]+\\)[']" 1 t erc-button-describe-symbol 1) ("\\bInfo:[\"]\\([^\"]+\\)[\"]" 0 t Info-goto-node 1) ("\\b\\(Ward\\|Wiki\\|WardsWiki\\|TheWiki\\):\\([A-Z][a-z]+\\([A-Z][a-z]+\\)+\\)" 0 t (lambda (page) (browse-url (concat "http://c2.com/cgi-bin/wiki?" page))) 2) ("EmacsWiki:\\([A-Z][a-z]+\\([A-Z][a-z]+\\)+\\)" 0 t erc-browse-emacswiki 1) ("Lisp:\\([a-zA-Z.+-]+\\)" 0 t erc-browse-emacswiki-lisp 1) ("\\bGoogle:\\([^ \n \f]+\\)" 0 t (lambda (keywords) (browse-url (format erc-button-google-url keywords))) 1) ("\\brfc[#: ]?\\([0-9]+\\)" 0 t (lambda (num) (browse-url (format erc-button-rfc-url num))) 1) ("\\s-\\(@\\([0-9][0-9][0-9]\\)\\)" 1 t erc-button-beats-to-time 2)) "Alist of regexps matching buttons in ERC buffers.\nEach entry has the form (REGEXP BUTTON FORM CALLBACK PAR...), where\n\nREGEXP is the string matching text around the button or a symbol\n indicating a variable holding that string, or a list of\n strings, or an alist with the strings in the car. Note that\n entries in lists or alists are considered to be nicks or other\n complete words. Therefore they are enclosed in \\< and \\>\n while searching. REGEXP can also be the quoted symbol\n 'nicknames, which matches the nickname of any user on the\n current server.\n\nBUTTON is the number of the regexp grouping actually matching the\n button, This is ignored if REGEXP is 'nicknames.\n\nFORM is a lisp expression which must eval to true for the button to\n be added,\n\nCALLBACK is the function to call when the user push this button.\n CALLBACK can also be a symbol. Its variable value will be used\n as the callback function.\n\nPAR is a number of a regexp grouping whose text will be passed to\n CALLBACK. There can be several PAR arguments. If REGEXP is\n 'nicknames, these are ignored, and CALLBACK will be called with\n the nickname matched as the argument." :version "24.3" (repeat (list :tag "Button" (choice :tag "Matches" regexp (variable :tag "Variable containing regexp") (const :tag "Nicknames" 'nicknames)) (integer :tag "Number of the regexp section that matches") (choice :tag "When to buttonize" (const :tag "Always" t) (sexp :tag "Only when this evaluates to non-nil")) (function :tag "Function to call when button is pressed") (repeat :tag "Sections of regexp to send to the function" :inline t (integer :tag "Regexp section number")))) erc-emacswiki-url "http://www.emacswiki.org/cgi-bin/wiki.pl?" "URL of the EmacsWiki Homepage." erc-emacswiki-lisp-url "http://www.emacswiki.org/elisp/" "URL of the EmacsWiki ELisp area."] 10) #@31 Local keymap for ERC buttons. (defvar erc-button-keymap (byte-code "\302 \303\304\305#\210\303\306\307#\210\303\310\311#\210\303\312\313#\210\303\314\315#\210\316 \"\210)\207" [map erc-mode-map make-sparse-keymap define-key " " erc-button-press-button [mouse-2] erc-button-click-button " " erc-button-next [backtab] erc-button-previous [follow-link] mouse-face set-keymap-parent] 4) (#$ . 7894)) #@125 Syntax table used when buttonizing messages. This syntax table should make all the valid nick characters word constituents. (defvar erc-button-syntax-table (byte-code "\301 \302\303\304#\210\302\305\304#\210\302\306\304#\210\302\307\304#\210\302\310\304#\210\302\311\304#\210\302\312\304#\210\302\313\304#\210\302\314\304#\210\302\315\304#\210\302\316\304#\210\302\317\304#\210\302\320\304#\210)\207" [table make-syntax-table modify-syntax-entry 40 "w" 41 91 93 123 125 96 39 94 45 95 124 92] 4) (#$ . 8305)) #@99 Internal variable used to keep track of whether we've added the global-level ERC button keys yet. (defvar erc-button-keys-added nil (#$ . 8835)) #@67 Add ERC mode-level button movement keys. This is only done once. (defalias 'erc-button-setup #[nil "?\205 \302 \303\304#\210\305\211\207" [erc-button-keys-added erc-mode-map define-key [backtab] erc-button-previous t] 4 (#$ . 8986)]) #@154 Find external references in the current buffer and make buttons of them. "External references" are things like URLs, as specified by `erc-button-alist'. (defalias 'erc-button-add-buttons #[nil "\212\306 p\307\216\310\n!\210\311\312\211\311\211\211\313 \210\311\211\205\342 @\211@\314\232\203A \315!\210\202\330 @;\203N @\206Z \316@!\205Z @J\211;\203i \317 \"\210\202\330 <\203\234 @;\203\234 \311\211\203\230 @\317\320\321!\322Q\"\210A\211\204~ *\202\330 <\203\330 @<\203\330 \211@@);\203\330 \311\211\203\327 @\317\320\321@!\322Q\"\210A\211\204\274 *A\211\204- \311. \207" [#1=#:buffer #2=#:table erc-button-syntax-table erc-button-alist data regexp syntax-table ((byte-code "rq\210\302 !\210)\302\207" [#1# #2# set-syntax-table] 2)) set-syntax-table nil t erc-button-remove-old-buttons 'nicknames erc-button-add-nickname-buttons boundp erc-button-add-buttons-1 "\\<" regexp-quote "\\>" entry alist inhibit-field-text-motion inhibit-point-motion-hooks buffer-read-only --dolist-tail-- r x elem] 8 (#$ . 9231) nil]) #@59 Search through the buffer for nicknames, and add buttons. (defalias 'erc-button-add-nickname-buttons #[(entry) "\3068\3078\310\211\211\311=\204 \312\f!\205n eb\210\313v\205n \314\301!\315\n@\nA\"\316 \203N \317 \320!\205J rq\210\321\322 !\")*\204` \203 \321\322 !\")\203 \323\n@\nA\311 C%\210\202 ,\207" [entry word bounds fun form nick 2 3 nil t eval 1 bounds-of-thing-at-point buffer-substring-no-properties erc-server-buffer-p erc-server-buffer buffer-live-p gethash erc-downcase erc-button-add-button #1=#:buffer erc-server-users erc-channel-users] 7 (#$ . 10337)]) #@65 Search through the buffer for matches to ENTRY and add buttons. (defalias 'erc-button-add-buttons-1 #[(regexp entry) "eb\210\306\307\310#\205@ A@\224 A@\225\311 8\312 8\313\314\315 \233\"\f\310=\2041 \316\f!\203<