%PDF- %PDF-
Direktori : /usr/local/share/emacs/27.2/lisp/gnus/ |
Current File : //usr/local/share/emacs/27.2/lisp/gnus/gnus-html.elc |
;ELC ;;; Compiled ;;; in Emacs version 27.2 ;;; 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\300\304!\210\300\305!\210\300\306!\210\300\307!\210\300\310!\210\300\311!\210\312\313\314\315\316\317\320\301\321\322& \210\312\323\324\325\316\317\320\301\321\326& \210\312\327\330\331\316\317\320\301\321\332& \210\312\333\334\335\316\317\320\301\321\336& \207" [require gnus-art mm-url url url-cache xml browse-url mm-util help-fns url-queue custom-declare-variable gnus-html-image-cache-ttl (days-to-time 7) "Time used to determine if we should use images from the cache." :version "24.1" :group :type (list integer integer) gnus-html-image-automatic-caching t "Whether automatically cache retrieve images." boolean gnus-html-frame-width 70 "What width to use when rendering HTML." integer gnus-max-image-proportion 0.9 "How big pictures displayed are in relation to the window they're in.\nA value of 0.7 means that they are allowed to take up 70% of the\nwidth and height of the window. If they are larger than this,\nand Emacs supports it, then the images will be rescaled down to\nfit these criteria." float] 10) (defvar gnus-html-image-map (byte-code "\301 \302\303\304#\210\302\305\306#\210\302\307\310#\210)\207" [map make-sparse-keymap define-key "u" gnus-article-copy-string "i" gnus-html-insert-image "v" gnus-html-browse-url] 4)) (defvar gnus-html-displayed-image-map (byte-code "\301 \302\303\304#\210\302\305\306#\210\302\307\310#\210\302\311\312#\210\302\313\314#\210)\207" [map make-sparse-keymap define-key "a" gnus-html-show-alt-text "i" gnus-html-browse-image " " gnus-html-browse-url "u" gnus-article-copy-string [tab] button-forward] 4)) #@13 Encode URL. (defalias 'gnus-html-encode-url #[(url) "\301\302\"\207" [url browse-url-url-encode-chars "[)$ ]"] 3 (#$ . 2034)]) #@43 Check if URL is cached for more than TTL. (defalias 'gnus-html-cache-expired #[(url ttl) "\203 \304\305 !!?\207\306 !\211\203 \307\310\n\"\311\"\202 \312)\207" [url-standalone-mode url cache-time ttl file-exists-p url-cache-create-filename url-is-cached time-less-p time-add nil t] 5 (#$ . 2168)]) (defalias 'gnus-article-html #[(&optional handle) "p \204\n \306\307!\214``}\210\212 \211@\203\247 \310 @!\203\247 \311\312!r\nq\210\313\216\314 \210\315 @!\210\316\317 8 \211@;\203B \211@\262\202H \211A@@\262\"\210\320\211\fB\321 A@\322\"\211\203 \323\324\307#\211\203 \325=\204 \326\327 \"\330 \210\331 \210c\210\332ed\333\324\324\334\335\336\337\340\337\341\342\341\343\341\344\345\346\347-\"\350\346\347.\"\341\351\352\353&\210.*\354 *\207" [article-buffer handle #1=#:temp-buffer coding-system-for-read coding-system-for-write default-process-coding-system mm-dissect-buffer t buffer-name generate-new-buffer " *temp*" #[nil "\301!\205 \302!\207" [#1# buffer-name kill-buffer] 2] mm-disable-multibyte insert-buffer-substring mm-decode-content-transfer-encoding 2 utf-8 mail-content-type-get charset mm-charset-to-coding-system nil ascii decode-coding-string buffer-string erase-buffer mm-enable-multibyte call-process-region "w3m" "-halfdump" "-no-cookie" "-I" "UTF-8" "-O" "-o" "ext_halfdump=1" "display_ins_del=2" "pre_conv=1" "-t" format "%s" "-cols" "display_image=on" "-T" "text/html" gnus-html-wash-tags tab-width gnus-html-frame-width] 28]) (defalias 'gnus-html-pre-wash #[nil "eb\210\300\301\302\303#\203 \304\305\303\211#\210\202 eb\210\300\306\302\303#\205( \304\305\303\211#\210\202 \207" [re-search-forward " *<pre_int> *</pre_int> *\n" nil t replace-match "" "<a name[^\n>]+>"] 4]) #@60 Run through current buffer and replace img tags by images. (defalias 'gnus-html-wash-images #[nil "\306\211\211\211\211\211\211\211\211\211!?@A\307B!\203. rBq\210C\310 )\2024 C\310 eb\210\311\312\306\313#\205\234\314\315!@\316\224\211!`|\210\317\320\321 \313#\203[ \316\224\316\225|\210`\322\323@\"\2037 \324\325\326#\210\327\314\315@\"!\322\330@\"\205\202 \331\314\332@\"!\333! \334\335\336\337\340\303\341\305\n\257E\342\n\343\313\344D\345! \nF\257\f#\210\322\346\"\203<\347\350\316\225\"!\211E\205 ?\205 \351E\211E@\205\352E@!\205\353\354!FrFq\210\355\216\356 \210\357E@!\210\360\332E8E\211@;\203\372 \211@\262\202 \211A@@\262\"\210\361 +)\306\313#\211G\203,\362\363\364\365G\366 \"\367! {! |\210\370D!\363#\"\210\2028\371! \342\344D&\210*\2027 \204G\372\"\203V\371! \342\344D&\210\2027 \322\373@\"\205e\374\314\315@\"!\322\375@\"\205t\374\314\315@\"!HIH\203\204H\376V\203\230I\203\220I\376V\203\230\340! \n$\210*\2027 .\n\207" [blocked-images inhibit-images alt-text url images end nil buffer-live-p gnus-blocked-images re-search-forward "<img_alt \\([^>]*\\)>" t match-string 1 0 search-forward "</img_alt>" line-end-position string-match "src=\"\\([^\"]+\\)" gnus-message 8 "gnus-html-wash-tags: fetching image URL %s" gnus-html-encode-url "\\(alt\\|title\\)=\"\\([^\"]+\\)" xml-substitute-special 2 add-text-properties image-url image-displayer lambda (url start end) gnus-html-display-image start help-echo button keymap gnus-image "\\`cid:" mm-get-content-id substring gnus-create-image buffer-name generate-new-buffer " *temp*" #[nil "\301!\205 \302!\207" [#1=#:temp-buffer buffer-name kill-buffer] 2] mm-disable-multibyte insert-buffer-substring mm-decode-content-transfer-encoding buffer-string gnus-add-image cid gnus-put-image gnus-rescale-image gnus-html-maximum-image-size gnus-string-or-1 "*" make-text-button gnus-html-image-url-blocked-p "width=\"?\\([0-9]+\\)" string-to-number "height=\"?\\([0-9]+\\)" 4 string parameters tag gnus-summary-buffer gnus-inhibit-images gnus-html-image-map handle #1# image height width] 19 (#$ . 3912)]) #@84 Display image at URL on text from START to END. Use ALT-TEXT for the image string. (defalias 'gnus-html-display-image #[(url start end &optional alt-text) "\204 \305\306\307 \"\203] \310\311 \312\225\"!\211\205[ \313\n\211@\205W \314\n@!\205W \315\316!rq\210\317\216\320 \210\321\n@!\210\322\323\n8\n\211@;\203L \211@\262\202R \211A@@\262\"\210\324 +) #)\207\325 \f\"\203k \326p D\"\207\313\327 ! #\207" [alt-text url handle #1=#:temp-buffer gnus-html-image-cache-ttl "*" string-match "\\`cid:" mm-get-content-id substring 0 gnus-html-put-image buffer-name generate-new-buffer " *temp*" #[nil "\301!\205 \302!\207" [#1# buffer-name kill-buffer] 2] mm-disable-multibyte insert-buffer-substring mm-decode-content-transfer-encoding 2 buffer-string gnus-html-cache-expired gnus-html-schedule-image-fetching gnus-html-get-image-data] 6 (#$ . 6070)]) (defalias 'gnus-html-wash-tags #[nil "\306\211\211\211\211\211\211@\307 \210\310 \210eb\210\311\312\306\313#\203\357\314\315!@\314\316!\317\224 G\317V\203<