;ELC   
;;; Compiled
;;; in Emacs version 29.4
;;; with all optimizations.



(byte-code "\300\301!\210\302\303\304\305\306\301%\210\307\310\311\312\313DD\314\315\316%\210\307\317\311\312\320DD\321\322\323\324\325\315\326\306\303&\207" [require erc custom-declare-group erc-truncate nil "Truncate buffers when they reach a certain size." :group custom-declare-variable erc-max-buffer-size funcall function #[0 "\300\207" [30000] 1 #1=""] "Maximum size in chars of each ERC buffer.\nUsed only when auto-truncation is enabled.\n(see `erc-truncate-buffer' and `erc-insert-post-hook')." :type integer erc-truncate-mode #[0 "\300\207" [nil] 1 #1#] "Non-nil if Erc-Truncate mode is enabled.\nSee the `erc-truncate-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 `erc-truncate-mode'." :set custom-set-minor-mode :initialize custom-initialize-default boolean] 12)#@406 Toggle ERC truncate mode.
With a prefix argument ARG, enable truncate if ARG is positive,
and disable it otherwise.  If called from Lisp, enable the mode
if ARG is omitted or nil.
Truncate a query buffer if it gets too large.
This prevents the query buffer from getting too large, which can
bring any grown Emacs to its knees after a few days worth of
tracking heavy-traffic channels.

(fn &optional ARG)
(defalias 'erc-truncate-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 \301B	\203B \313 \210\202E \314 \210\315\316\305\301!\203Q \317\202R \320\"\210\321\322!\203{ \323\301!\210\302 \203j \211\302 \232\203{ \324\325\326\305\301!\203w \327\202x \330\331$\210\210\332 \210\305\301!\207" [global-minor-modes erc-truncate-mode current-message set-default toggle default-value 1 nil t boundp delq erc-truncate-enable erc-truncate-disable run-hooks erc-truncate-mode-hook erc-truncate-mode-on-hook erc-truncate-mode-off-hook called-interactively-p any customize-mark-as-set message "%s %sabled%s" "Erc-Truncate mode" "en" "dis" "" force-mode-line-update] 7 (#$ . 1006) (byte-code "\203\n \301!\202 \302C\207" [current-prefix-arg prefix-numeric-value toggle] 2)])
(defvar erc-truncate-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" [erc-truncate-mode-map erc-truncate-mode-hook variable-documentation put "Hook run after entering or leaving `erc-truncate-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 erc-truncate-mode boundp] 6)#@27 Enable ERC truncate mode.
(defalias 'erc-truncate-enable #[0 "\302>\203 \210\202 \302B\303\304\305\306\"\207" [erc-modules erc-truncate-mode truncate t add-hook erc-insert-post-hook erc-truncate-buffer] 3 (#$ . 2779) nil])#@28 Disable ERC truncate mode.
(defalias 'erc-truncate-disable #[0 "\302\303\"\304\305\306\307\"\207" [erc-modules erc-truncate-mode delq truncate nil remove-hook erc-insert-post-hook erc-truncate-buffer] 3 (#$ . 3014) nil])
(byte-code "\300\301\302\303#\210\300\301\304\303#\210\300\305\304\303#\210\300\306\304\303#\207" [put erc-truncate-mode erc-module truncate definition-name erc-truncate-enable erc-truncate-disable] 4)#@198 Truncates the buffer to the size SIZE.
If BUFFER is not provided, the current buffer is assumed.  The deleted
region is logged if `erc-logging-enabled' returns non-nil.

(fn SIZE &optional BUFFER)
(defalias 'erc-truncate-buffer-to-size #[513 "\211\204\n p\262\202 \303!\204 \304\305\"\210\306!\307\\V\205S r\211q\210\214~\210Z\211b\210\310 \210`\262\311\301!\203E 	\203E \312!\203E \313 \210\314 \210\315e|)\266\316 *\207" [erc-insert-marker erc-enable-logging inhibit-read-only get-buffer error "erc-truncate-buffer-to-size: %S is not a buffer" buffer-size 512 beginning-of-line boundp erc-logging-enabled erc-save-buffer-in-logs buffer-disable-undo t buffer-enable-undo] 5 (#$ . 3446)])#@112 Truncates the current buffer to `erc-max-buffer-size'.
Meant to be used in hooks, like `erc-insert-post-hook'.
(defalias 'erc-truncate-buffer #[0 "\301!\207" [erc-max-buffer-size erc-truncate-buffer-to-size] 2 (#$ . 4155) nil])
(provide 'erc-truncate)
