1 |
;;; url-vars.el --- Variables for Uniform Resource Locator tool |
;;; url-vars.el --- Variables for Uniform Resource Locator tool |
2 |
|
|
3 |
|
;; Copyright (c) 1996,1997,1998,1999,2001,2004 Free Software Foundation, Inc. |
4 |
|
|
5 |
;; Keywords: comm, data, processes, hypermedia |
;; Keywords: comm, data, processes, hypermedia |
6 |
|
|
7 |
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
;; This file is part of GNU Emacs. |
8 |
;;; Copyright (c) 1996,1997,1998,1999,2001,2004 Free Software Foundation, Inc. |
|
9 |
;;; |
;; GNU Emacs is free software; you can redistribute it and/or modify |
10 |
;;; This file is part of GNU Emacs. |
;; it under the terms of the GNU General Public License as published by |
11 |
;;; |
;; the Free Software Foundation; either version 2, or (at your option) |
12 |
;;; GNU Emacs is free software; you can redistribute it and/or modify |
;; any later version. |
13 |
;;; it under the terms of the GNU General Public License as published by |
|
14 |
;;; the Free Software Foundation; either version 2, or (at your option) |
;; GNU Emacs is distributed in the hope that it will be useful, |
15 |
;;; any later version. |
;; but WITHOUT ANY WARRANTY; without even the implied warranty of |
16 |
;;; |
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
17 |
;;; GNU Emacs is distributed in the hope that it will be useful, |
;; GNU General Public License for more details. |
18 |
;;; but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
19 |
;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
;; You should have received a copy of the GNU General Public License |
20 |
;;; GNU General Public License for more details. |
;; along with GNU Emacs; see the file COPYING. If not, write to the |
21 |
;;; |
;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
22 |
;;; You should have received a copy of the GNU General Public License |
;; Boston, MA 02111-1307, USA. |
23 |
;;; along with GNU Emacs; see the file COPYING. If not, write to the |
|
24 |
;;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
;;; Code: |
|
;;; Boston, MA 02111-1307, USA. |
|
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|
25 |
|
|
26 |
(require 'mm-util) |
(require 'mm-util) |
27 |
|
|
192 |
(string :tag "Proxy"))) |
(string :tag "Proxy"))) |
193 |
:group 'url) |
:group 'url) |
194 |
|
|
|
(defcustom url-passwd-entry-func nil |
|
|
"*Symbol indicating which function to call to read in a password. |
|
|
It will be set up depending on whether you are running EFS or ange-ftp |
|
|
at startup if it is nil. This function should accept the prompt |
|
|
string as its first argument, and the default value as its second |
|
|
argument." |
|
|
:type '(choice (const :tag "Guess" :value nil) |
|
|
(const :tag "Use Ange-FTP" :value ange-ftp-read-passwd) |
|
|
(const :tag "Use EFS" :value efs-read-passwd) |
|
|
(const :tag "Use Password Package" :value read-passwd) |
|
|
(function :tag "Other")) |
|
|
:group 'url-hairy) |
|
|
|
|
195 |
(defcustom url-standalone-mode nil |
(defcustom url-standalone-mode nil |
196 |
"*Rely solely on the cache?" |
"*Rely solely on the cache?" |
197 |
:type 'boolean |
:type 'boolean |
228 |
(defvar url-mime-encoding-string nil |
(defvar url-mime-encoding-string nil |
229 |
"*String to send in the Accept-encoding: field in HTTP requests.") |
"*String to send in the Accept-encoding: field in HTTP requests.") |
230 |
|
|
|
;; `mm-mime-mule-charset-alist' in Gnus 5.8/9 contains elements whose |
|
|
;; cars aren't valid MIME charsets/coding systems, at least in Emacs. |
|
|
;; This gets it correct by construction in Emacs. Fixme: DTRT for |
|
|
;; XEmacs -- its `coding-system-list' doesn't have the BASE-ONLY arg. |
|
|
(when (and (not (featurep 'xemacs)) |
|
|
(fboundp 'coding-system-list)) |
|
|
(setq mm-mime-mule-charset-alist |
|
|
(apply |
|
|
'nconc |
|
|
(mapcar |
|
|
(lambda (cs) |
|
|
(when (and (coding-system-get cs 'mime-charset) |
|
|
(not (eq t (coding-system-get cs 'safe-charsets)))) |
|
|
(list (cons (coding-system-get cs 'mime-charset) |
|
|
(delq 'ascii |
|
|
(coding-system-get cs 'safe-charsets)))))) |
|
|
(coding-system-list 'base-only))))) |
|
|
|
|
231 |
;; Perhaps the first few should actually be given decreasing `q's and |
;; Perhaps the first few should actually be given decreasing `q's and |
232 |
;; the list should be trimmed significantly. |
;; the list should be trimmed significantly. |
233 |
;; Fixme: do something sane if we don't have `sort-coding-systems' |
;; Fixme: do something sane if we don't have `sort-coding-systems' |
351 |
|
|
352 |
(defvar url-setup-done nil "Has setup configuration been done?") |
(defvar url-setup-done nil "Has setup configuration been done?") |
353 |
|
|
354 |
(defconst weekday-alist |
(defconst url-weekday-alist |
355 |
'(("Sunday" . 0) ("Monday" . 1) ("Tuesday" . 2) ("Wednesday" . 3) |
'(("Sunday" . 0) ("Monday" . 1) ("Tuesday" . 2) ("Wednesday" . 3) |
356 |
("Thursday" . 4) ("Friday" . 5) ("Saturday" . 6) |
("Thursday" . 4) ("Friday" . 5) ("Saturday" . 6) |
357 |
("Tues" . 2) ("Thurs" . 4) |
("Tues" . 2) ("Thurs" . 4) |
358 |
("Sun" . 0) ("Mon" . 1) ("Tue" . 2) ("Wed" . 3) |
("Sun" . 0) ("Mon" . 1) ("Tue" . 2) ("Wed" . 3) |
359 |
("Thu" . 4) ("Fri" . 5) ("Sat" . 6))) |
("Thu" . 4) ("Fri" . 5) ("Sat" . 6))) |
360 |
|
|
361 |
(defconst monthabbrev-alist |
(defconst url-monthabbrev-alist |
362 |
'(("Jan" . 1) ("Feb" . 2) ("Mar" . 3) ("Apr" . 4) ("May" . 5) ("Jun" . 6) |
'(("Jan" . 1) ("Feb" . 2) ("Mar" . 3) ("Apr" . 4) ("May" . 5) ("Jun" . 6) |
363 |
("Jul" . 7) ("Aug" . 8) ("Sep" . 9) ("Oct" . 10) ("Nov" . 11) |
("Jul" . 7) ("Aug" . 8) ("Sep" . 9) ("Oct" . 10) ("Nov" . 11) |
364 |
("Dec" . 12))) |
("Dec" . 12))) |
395 |
(defun url-vars-unload-hook () |
(defun url-vars-unload-hook () |
396 |
(remove-hook 'set-language-environment-hook 'url-set-mime-charset-string)) |
(remove-hook 'set-language-environment-hook 'url-set-mime-charset-string)) |
397 |
|
|
398 |
|
(add-hook 'url-vars-unload-hook 'url-vars-unload-hook) |
399 |
|
|
400 |
(provide 'url-vars) |
(provide 'url-vars) |
401 |
|
|
402 |
;;; arch-tag: 29205e5f-c5ce-433c-8d5d-38cbaed64b49 |
;;; arch-tag: 29205e5f-c5ce-433c-8d5d-38cbaed64b49 |