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:48 2024 ;;; from file /builddir/build/BUILD/emacs-24.3/lisp/erc/erc-stamp.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\303\304\305\306\307\301%\210\310\311\312\313\307\304\314\315&\210\310\316\317\320\307\304\314\321&\210\310\322\323\324\307\304\314\325&\210\310\326\327\330\307\304\314\331&\210\310\332\333\334\307\304\314\335&\210\310\336\337\340\307\304\314\341&\210\310\342\305\343\307\304\314\344&\210\310\345\305\346\307\304\314\344&\210\310\347\350\351\307\304\314\352&\210\310\353\354\355\307\304\314\344&\210\356\357\360\361\307\362%\210\310\363\305\364\365\366\367\370\307\304\314\344&\207" [require erc erc-compat custom-declare-group erc-stamp nil "For long conversation on IRC it is sometimes quite\nuseful to have individual messages timestamp. This\ngroup provides settings related to the format and display\nof timestamp information in `erc-mode' buffer.\n\nFor timestamping to be activated, you just need to load `erc-stamp'\nin your init file or interactively using `load-library'." :group custom-declare-variable erc-timestamp-format "[%H:%M]" "If set to a string, messages will be timestamped.\nThis string is processed using `format-time-string'.\nGood examples are \"%T\" and \"%H:%M\".\n\nIf nil, timestamping is turned off." :type (choice (const nil) (string)) erc-timestamp-format-left "\n[%a %b %e %Y]\n" "If set to a string, messages will be timestamped.\nThis string is processed using `format-time-string'.\nGood examples are \"%T\" and \"%H:%M\".\n\nThis timestamp is used for timestamps on the left side of the\nscreen when `erc-insert-timestamp-function' is set to\n`erc-insert-timestamp-left-and-right'.\n\nIf nil, timestamping is turned off." (choice (const nil) (string)) erc-timestamp-format-right " [%H:%M]" "If set to a string, messages will be timestamped.\nThis string is processed using `format-time-string'.\nGood examples are \"%T\" and \"%H:%M\".\n\nThis timestamp is used for timestamps on the right side of the\nscreen when `erc-insert-timestamp-function' is set to\n`erc-insert-timestamp-left-and-right'.\n\nIf nil, timestamping is turned off." (choice (const nil) (string)) erc-insert-timestamp-function 'erc-insert-timestamp-left-and-right "Function to use to insert timestamps.\n\nIt takes a single argument STRING which is the final string\nwhich all text-properties already appended. This function only cares about\ninserting this string at the right position. Narrowing is in effect\nwhile it is called, so (point-min) and (point-max) determine the region to\noperate on.\n\nYou will probably want to set\n`erc-insert-away-timestamp-function' to the same value." (choice (const :tag "Both sides" erc-insert-timestamp-left-and-right) (const :tag "Right" erc-insert-timestamp-right) (const :tag "Left" erc-insert-timestamp-left) function) erc-away-timestamp-format "<%H:%M>" "Timestamp format used when marked as being away.\n\nIf nil, timestamping is turned off when away unless `erc-timestamp-format'\nis set.\n\nIf `erc-timestamp-format' is set, this will not be used." (choice (const nil) (string)) erc-insert-away-timestamp-function 'erc-insert-timestamp-left-and-right "Function to use to insert the away timestamp.\n\nSee `erc-insert-timestamp-function' for details." (choice (const :tag "Both sides" erc-insert-timestamp-left-and-right) (const :tag "Right" erc-insert-timestamp-right) (const :tag "Left" erc-insert-timestamp-left) function) erc-hide-timestamps "If non-nil, timestamps will be invisible.\n\nThis is useful for logging, because, although timestamps will be\nhidden, they will still be present in the logs." boolean erc-echo-timestamps "If non-nil, print timestamp in the minibuffer when point is moved.\nUsing this variable, you can turn off normal timestamping,\nand simply move point to an irc message to see its timestamp\nprinted in the minibuffer." erc-echo-timestamp-format "Timestamped %A, %H:%M:%S" "Format string to be used when `erc-echo-timestamps' is non-nil.\nThis string specifies the format of the timestamp being echoed in\nthe minibuffer." string erc-timestamp-intangible t "Whether the timestamps should be intangible, i.e. prevent the point\nfrom entering them and instead jump over them." custom-declare-face erc-timestamp-face ((t :weight bold :foreground "green")) "ERC timestamp face." erc-faces erc-stamp-mode "Non-nil if Erc-Stamp mode is enabled.\nSee the command `erc-stamp-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-stamp-mode'." :set custom-set-minor-mode :initialize custom-initialize-default] 12) #@229 Toggle ERC stamp mode. With a prefix argument ARG, enable stamp if ARG is positive, and disable it otherwise. If called from Lisp, enable the mode if ARG is omitted or nil. This mode timestamps messages in the channel buffers. (defalias 'erc-stamp-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-stamp-mode current-message toggle prefix-numeric-value 0 erc-stamp-enable erc-stamp-disable run-hooks erc-stamp-mode-hook erc-stamp-mode-on-hook erc-stamp-mode-off-hook called-interactively-p any customize-mark-as-set message "Erc-Stamp mode %sabled" "en" "dis" force-mode-line-update] 4 (#$ . 5137) (list (or current-prefix-arg 'toggle))]) (byte-code "\301\302\303\304\300!\205\n \303\211%\207" [erc-stamp-mode-map add-minor-mode erc-stamp-mode nil boundp] 6) #@24 Enable ERC stamp mode. (defalias 'erc-stamp-enable #[nil "\301\302\303\"\210\304\305\306\307\"\210\305\310\311\304#\210\305\312\311\304#\207" [erc-stamp-mode add-to-list erc-modules stamp t add-hook erc-mode-hook erc-munge-invisibility-spec erc-insert-modify-hook erc-add-timestamp erc-send-modify-hook] 4 (#$ . 6123) nil]) #@25 Disable ERC stamp mode. (defalias 'erc-stamp-disable #[nil "\302\303\"\304\305\306\307\"\210\305\310\311\"\210\305\312\311\"\207" [erc-modules erc-stamp-mode delq stamp nil remove-hook erc-mode-hook erc-munge-invisibility-spec erc-insert-modify-hook erc-add-timestamp erc-send-modify-hook] 3 (#$ . 6454) nil]) (byte-code "\300\301\302\"\210\303\302\304\305#\210\303\306\304\305#\210\303\307\304\305#\207" [defalias erc-timestamp-mode erc-stamp-mode put definition-name stamp erc-stamp-enable erc-stamp-disable] 4) #@141 Add timestamp and text-properties to message. This function is meant to be called from `erc-insert-modify-hook' or `erc-send-modify-hook'. (defalias 'erc-add-timestamp #[nil "\305`\306\"?\205I \307 \310 !\203 \311\n\"!\210\202 \312\313!\210\310!\2039 \f\2039 \314 \2039 \n\2049 \311\f\"!\210\315ed\316D#\210\315ed\317\320D#)\207" [ct erc-insert-timestamp-function erc-timestamp-format erc-insert-away-timestamp-function erc-away-timestamp-format get-text-property invisible current-time fboundp erc-format-timestamp error "Timestamp function unbound" erc-away-time add-text-properties timestamp point-entered erc-echo-timestamp] 5 (#$ . 6978)]) #@42 Last timestamp inserted into the buffer. (defvar erc-timestamp-last-inserted nil (#$ . 7639)) (make-variable-buffer-local 'erc-timestamp-last-inserted) #@150 Last timestamp inserted into the left side of the buffer. This is used when `erc-insert-timestamp-function' is set to `erc-timestamp-left-and-right' (defvar erc-timestamp-last-inserted-left nil (#$ . 7798)) (make-variable-buffer-local 'erc-timestamp-last-inserted-left) #@151 Last timestamp inserted into the right side of the buffer. This is used when `erc-insert-timestamp-function' is set to `erc-timestamp-left-and-right' (defvar erc-timestamp-last-inserted-right nil (#$ . 8075)) (byte-code "\300\301!\210\302\303\304\305\306\307\310\311&\210\302\312\313\314\306\307\310\315&\210\302\316\317\320\306\307\310\311&\207" [make-variable-buffer-local erc-timestamp-last-inserted-right custom-declare-variable erc-timestamp-only-if-changed-flag t "Insert timestamp only if its value changed since last insertion.\nIf `erc-insert-timestamp-function' is `erc-insert-timestamp-left', a\nstring of spaces which is the same size as the timestamp is added to\nthe beginning of the line in its place. If you use\n`erc-insert-timestamp-right', nothing gets inserted in place of the\ntimestamp." :group erc-stamp :type boolean erc-timestamp-right-column nil "If non-nil, the column at which the timestamp is inserted,\nif the timestamp is to be printed to the right. If nil,\n`erc-insert-timestamp-right' will use other means to determine\nthe correct column." (choice (integer :tag "Column number") (const :tag "Unspecified" nil)) erc-timestamp-use-align-to (and (not (featurep 'xemacs)) (>= emacs-major-version 22) (eq window-system 'x)) "If non-nil, use the :align-to display property to align the stamp.\nThis gives better results when variable-width characters (like\nAsian language characters and math symbols) precede a timestamp.\nUnfortunately, it only works in Emacs 22 and when using the X\nWindow System.\n\nA side effect of enabling this is that there will only be one\nspace before a right timestamp in any saved logs."] 8) #@49 Insert timestamps at the beginning of the line. (defalias 'erc-insert-timestamp-left #[(string) "eb\210\205\n \n\230 G\203 \306\f\307\"\202 \204! \310\311\f\312\313 %\210\310\311\f\314\315 %\210 c+\207" [erc-timestamp-only-if-changed-flag string erc-timestamp-last-inserted ignore-p len s make-string 32 erc-put-text-property 0 field erc-timestamp invisible timestamp] 6 (#$ . 9737)]) #@138 Insert STRING at the POSth column. If `erc-timestamp-use-align-to' is t, use the :align-to display property to get to the POSth column. (defalias 'erc-insert-aligned #[(string pos) "\204\n j\210\202 \303c\210\304`S`\305\306\307 E$\210\nc\207" [erc-timestamp-use-align-to pos string " " put-text-property display space :align-to] 7 (#$ . 10141)]) #@834 Insert timestamp on the right side of the screen. STRING is the timestamp to insert. The function is a possible value for `erc-insert-timestamp-function'. If `erc-timestamp-only-if-changed-flag' is nil, a timestamp is always printed. If this variable is non-nil, a timestamp is only printed if it is different from the last. If `erc-timestamp-right-column' is set, its value will be used as the column at which the timestamp is to be printed. If it is nil, and `erc-fill-mode' is active, then the timestamp will be printed just before `erc-fill-column'. Otherwise, if the current buffer is shown in a window, that window's width is used. If the buffer is not shown, and `fill-column' is set, then the timestamp will be printed just `fill-column'. As a last resort, the timestamp will be printed just before the window-width. (defalias 'erc-insert-timestamp-right #[(string) "\205 \n\230?\205\253 db\210\306u\210\307p!\310 ! \203# \202T \311\312!\203A \n\203A \311\313!\203A \203A \fZT\202T \203N \fZT\202T \314\315 \f\316#`i\317\320`\321 ZZ\322\245!\\\211W\203 \323 \"\210\202\214 \324 \210j\210` c\210\325`\326\327$\210\325`\330\331$\210 \205\251 \325`T\332\331$.\207" [erc-timestamp-only-if-changed-flag string erc-timestamp-last-inserted current-window str-width erc-timestamp-right-column -1 get-buffer-window string-width boundp erc-fill-mode erc-fill-column - window-width 1 nil ceiling point-at-bol 1.6 erc-insert-aligned newline erc-put-text-property field erc-timestamp rear-nonsticky t intangible fill-column pos from col indent erc-timestamp-intangible] 6 (#$ . 10498)]) #@235 This is another function that can be assigned to `erc-insert-timestamp-function'. If the date is changed, it will print a blank line, the date, and another blank line. If the time is changed, it will then print it off to the right. (defalias 'erc-insert-timestamp-left-and-right #[(string) "\306 \307 \"\307\"\n \230\204$ eb\210\310\311\nG\312\313\n%\210\nc\210\n\314\315\f!\210\f\211-\207" [ct erc-timestamp-format-left ts-left erc-timestamp-format-right ts-right erc-timestamp-last-inserted-left current-time erc-format-timestamp erc-put-text-property 0 field erc-timestamp t erc-insert-timestamp-right erc-timestamp-last-inserted-right erc-timestamp-last-inserted erc-timestamp-only-if-changed-flag] 6 (#$ . 12143)]) #@96 Return TIME formatted as string according to FORMAT. Return the empty string if FORMAT is nil. (defalias 'erc-format-timestamp #[(time format) "\2038 \305 \"\306\307\nG\310\311\n%\210\306\307\nG\312\313\n%\210\306\307\nG\314\313\n%\210\2035 \f\2045 \306\307\nG\315\316\n%\210\n)\207\317\207" [format time ts erc-timestamp-intangible erc-hide-timestamps format-time-string erc-put-text-property 0 face erc-timestamp-face invisible timestamp isearch-open-invisible intangible t ""] 6 (#$ . 12886)]) (defalias 'erc-munge-invisibility-spec #[nil "\203 <\203 \302 B\202 \303\302D\211\207 <\203! \304\302 \"\202# \303C\211\207" [erc-hide-timestamps buffer-invisibility-spec timestamp t remove] 3]) #@42 Hide timestamp information from display. (defalias 'erc-hide-timestamps #[nil "\301\302 \207" [erc-hide-timestamps t erc-munge-invisibility-spec] 1 (#$ . 13595) nil]) #@147 Show timestamp information on display. This function only works if `erc-timestamp-format' was previously set, and timestamping is already active. (defalias 'erc-show-timestamps #[nil "\301\302 \207" [erc-hide-timestamps nil erc-munge-invisibility-spec] 1 (#$ . 13770) nil]) #@209 Hide or show timestamps in ERC buffers. Note that timestamps can only be shown for a message using this function if `erc-timestamp-format' was set and timestamping was enabled when the message was inserted. (defalias 'erc-toggle-timestamps #[nil "\203 \301\202 \302\303\304\305 \"\207" [erc-hide-timestamps nil t mapc #[(buffer) "rq\210\301 )\207" [buffer erc-munge-invisibility-spec] 1] erc-buffer-list] 3 (#$ . 14052) nil]) #@145 Print timestamp text-property of an IRC message. Argument BEFORE is where point was before it got moved and NOW is position of point currently. (defalias 'erc-echo-timestamp #[(before now) "\205 \304 \305\"\211\205 \306\307\310\n\"\")\207" [erc-echo-timestamps now stamp erc-echo-timestamp-format get-text-property timestamp message "%s" format-time-string] 6 (#$ . 14492)]) (provide 'erc-stamp)