Using saved parent location: http://bzr.savannah.gnu.org/r/emacs/trunk/ Now on revision 101960. ------------------------------------------------------------ revno: 101960 committer: Chong Yidong branch nick: trunk timestamp: Thu 2010-10-14 01:57:58 -0400 message: Fix 2010-10-12 change to custom-theme-set-faces. * cus-face.el (custom-theme-set-faces): Call custom-push-theme only after checking the theme-face property. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-10-14 03:55:18 +0000 +++ lisp/ChangeLog 2010-10-14 05:57:58 +0000 @@ -1,5 +1,8 @@ 2010-10-14 Chong Yidong + * cus-face.el (custom-theme-set-faces): Call custom-push-theme + only after checking the theme-face property. + * faces.el (face-spec-reset-face): Reset all attributes in one single call to set-face-attribute. (face-spec-match-p): Make it a defsubst. === modified file 'lisp/cus-face.el' --- lisp/cus-face.el 2010-10-12 03:10:21 +0000 +++ lisp/cus-face.el 2010-10-14 05:57:58 +0000 @@ -328,15 +328,18 @@ ;; is aliased to. (if (get face 'face-alias) (setq face (get face 'face-alias))) - (custom-push-theme 'theme-face face theme 'set spec) - (unless custom--inhibit-theme-enable - ;; Now set the face spec. + (if custom--inhibit-theme-enable + ;; Just update theme settings. + (custom-push-theme 'theme-face face theme 'set spec) + ;; Update theme settings and set the face spec. (let ((now (nth 2 entry)) (comment (nth 3 entry)) (oldspec (get face 'theme-face))) (when (not (and oldspec (eq 'user (caar oldspec)))) (put face 'saved-face spec) (put face 'saved-face-comment comment)) + ;; Do this AFTER checking the `theme-face' property. + (custom-push-theme 'theme-face face theme 'set spec) (when (or now immediate) (put face 'force-face (if now 'rogue 'immediate))) (when (or now immediate (facep face)) ------------------------------------------------------------ revno: 101959 committer: Chong Yidong branch nick: trunk timestamp: Wed 2010-10-13 23:55:18 -0400 message: Define a cursor defface; minor face optimizations. * faces.el (face-spec-reset-face): Reset all attributes in one single call to set-face-attribute. (face-spec-match-p): Make it a defsubst. (frame-set-background-mode): New arg KEEP-FACE-SPECS. (x-create-frame-with-faces, tty-create-frame-with-faces) (tty-set-up-initial-frame-faces): Don't recompute face specs in frame-set-background-mode, since they are recomputed immediately afterwards in face-set-after-frame-default. (face-set-after-frame-default): Minor optimization. (cursor): Provide non-trivial defface spec. * custom.el (custom-theme-recalc-face): Simplify. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-10-14 03:14:38 +0000 +++ lisp/ChangeLog 2010-10-14 03:55:18 +0000 @@ -1,3 +1,18 @@ +2010-10-14 Chong Yidong + + * faces.el (face-spec-reset-face): Reset all attributes in one + single call to set-face-attribute. + (face-spec-match-p): Make it a defsubst. + (frame-set-background-mode): New arg KEEP-FACE-SPECS. + (x-create-frame-with-faces, tty-create-frame-with-faces) + (tty-set-up-initial-frame-faces): Don't recompute face specs in + frame-set-background-mode, since they are recomputed immediately + afterwards in face-set-after-frame-default. + (face-set-after-frame-default): Minor optimization. + (cursor): Provide non-trivial defface spec. + + * custom.el (custom-theme-recalc-face): Simplify. + 2010-10-14 Jay Belanger * calc/calc-alg.el (math-var): Renamed from `var'. === modified file 'lisp/custom.el' --- lisp/custom.el 2010-10-12 20:06:20 +0000 +++ lisp/custom.el 2010-10-14 03:55:18 +0000 @@ -1261,8 +1261,7 @@ ;; If the face spec specified by this theme is in the ;; saved-face property, reset that property. (when (equal (nth 3 s) (get symbol 'saved-face)) - (put symbol 'saved-face - (and val (cadr (car val))))) + (put symbol 'saved-face (and val (cadr (car val))))) (custom-theme-recalc-face symbol))))) (setq custom-enabled-themes (delq theme custom-enabled-themes))))) @@ -1293,7 +1292,9 @@ "Set FACE according to currently enabled custom themes." (if (get face 'face-alias) (setq face (get face 'face-alias))) - (face-spec-set face (get face 'face-override-spec))) + ;; Reset the faces for each frame. + (dolist (frame (frame-list)) + (face-spec-recalc face frame))) ;;; XEmacs compability functions === modified file 'lisp/faces.el' --- lisp/faces.el 2010-10-02 02:46:13 +0000 +++ lisp/faces.el 2010-10-14 03:55:18 +0000 @@ -1507,12 +1507,11 @@ (defun face-spec-reset-face (face &optional frame) "Reset all attributes of FACE on FRAME to unspecified." - (let ((attrs face-attribute-name-alist)) - (while attrs - (let ((attr-and-name (car attrs))) - (set-face-attribute face frame (car attr-and-name) 'unspecified)) - (setq attrs (cdr attrs))))) - + (let (reset-args) + (dolist (attr-and-name face-attribute-name-alist) + (push 'unspecified reset-args) + (push (car attr-and-name) reset-args)) + (apply 'set-face-attribute face frame reset-args))) (defun face-spec-set (face spec &optional for-defface) "Set FACE's face spec, which controls its appearance, to SPEC. @@ -1578,8 +1577,8 @@ (setq frame (selected-frame))) (let ((list face-attribute-name-alist) (match t)) - (while (and match (not (null list))) - (let* ((attr (car (car list))) + (while (and match list) + (let* ((attr (caar list)) (specified-value (if (plist-member attrs attr) (plist-get attrs attr) @@ -1589,7 +1588,7 @@ (setq list (cdr list)))) match)) -(defun face-spec-match-p (face spec &optional frame) +(defsubst face-spec-match-p (face spec &optional frame) "Return t if FACE, on FRAME, matches what SPEC says it should look like." (face-attr-match-p face (face-spec-choose spec frame) frame)) @@ -1837,10 +1836,13 @@ (defvar inhibit-frame-set-background-mode nil) -(defun frame-set-background-mode (frame) +(defun frame-set-background-mode (frame &optional keep-face-specs) "Set up display-dependent faces on FRAME. Display-dependent faces are those which have different definitions -according to the `background-mode' and `display-type' frame parameters." +according to the `background-mode' and `display-type' frame parameters. + +If optional arg KEEP-FACE-SPECS is non-nil, don't recalculate +face specs for the new background mode." (unless inhibit-frame-set-background-mode (let* ((bg-resource (and (window-system frame) @@ -1888,29 +1890,29 @@ (let ((locally-modified-faces nil) ;; Prevent face-spec-recalc from calling this function ;; again, resulting in a loop (bug#911). - (inhibit-frame-set-background-mode t)) - ;; Before modifying the frame parameters, collect a list of - ;; faces that don't match what their face-spec says they - ;; should look like. We then avoid changing these faces - ;; below. These are the faces whose attributes were - ;; modified on FRAME. We use a negative list on the - ;; assumption that most faces will be unmodified, so we can - ;; avoid consing in the common case. - (dolist (face (face-list)) - (and (not (get face 'face-override-spec)) - (not (face-spec-match-p face - (face-user-default-spec face) - (selected-frame))) - (push face locally-modified-faces))) - ;; Now change to the new frame parameters - (modify-frame-parameters frame - (list (cons 'background-mode bg-mode) - (cons 'display-type display-type))) - ;; For all named faces, choose face specs matching the new frame - ;; parameters, unless they have been locally modified. - (dolist (face (face-list)) - (unless (memq face locally-modified-faces) - (face-spec-recalc face frame)))))))) + (inhibit-frame-set-background-mode t) + (params (list (cons 'background-mode bg-mode) + (cons 'display-type display-type)))) + (if keep-face-specs + (modify-frame-parameters frame params) + ;; If we are recomputing face specs, first collect a list + ;; of faces that don't match their face-specs. These are + ;; the faces modified on FRAME, and we avoid changing them + ;; below. Use a negative list to avoid consing (we assume + ;; most faces are unmodified). + (dolist (face (face-list)) + (and (not (get face 'face-override-spec)) + (not (face-spec-match-p face + (face-user-default-spec face) + (selected-frame))) + (push face locally-modified-faces))) + ;; Now change to the new frame parameters + (modify-frame-parameters frame params) + ;; For all unmodified named faces, choose face specs + ;; matching the new frame parameters. + (dolist (face (face-list)) + (unless (memq face locally-modified-faces) + (face-spec-recalc face frame))))))))) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; @@ -1990,7 +1992,7 @@ (progn (x-setup-function-keys frame) (x-handle-reverse-video frame parameters) - (frame-set-background-mode frame) + (frame-set-background-mode frame t) (face-set-after-frame-default frame parameters) (if (null visibility-spec) (make-frame-visible frame) @@ -2006,20 +2008,21 @@ settings, X resources, and `face-new-frame-defaults'. Finally, apply any relevant face attributes found amongst the frame parameters in PARAMETERS." - (dolist (face (nreverse (face-list))) ;Why reverse? --Stef - (condition-case () - (progn - ;; Initialize faces from face spec and custom theme. - (face-spec-recalc face frame) - ;; X resouces for the default face are applied during - ;; x-create-frame. - (and (not (eq face 'default)) - (memq (window-system frame) '(x w32)) - (make-face-x-resource-internal face frame)) - ;; Apply attributes specified by face-new-frame-defaults - (internal-merge-in-global-face face frame)) - ;; Don't let invalid specs prevent frame creation. - (error nil))) + (let ((window-system-p (memq (window-system frame) '(x w32)))) + (dolist (face (nreverse (face-list))) ;Why reverse? --Stef + (condition-case () + (progn + ;; Initialize faces from face spec and custom theme. + (face-spec-recalc face frame) + ;; X resouces for the default face are applied during + ;; `x-create-frame'. + (and (not (eq face 'default)) window-system-p + (make-face-x-resource-internal face frame)) + ;; Apply attributes specified by face-new-frame-defaults + (internal-merge-in-global-face face frame)) + ;; Don't let invalid specs prevent frame creation. + (error nil)))) + ;; Apply attributes specified by frame parameters. (let ((face-params '((foreground-color default :foreground) (background-color default :background) @@ -2066,7 +2069,7 @@ (set-terminal-parameter frame 'terminal-initted t) (set-locale-environment nil frame) (tty-run-terminal-initialization frame)) - (frame-set-background-mode frame) + (frame-set-background-mode frame t) (face-set-after-frame-default frame parameters) (setq success t)) (unless success @@ -2122,7 +2125,7 @@ (defun tty-set-up-initial-frame-faces () (let ((frame (selected-frame))) - (frame-set-background-mode frame) + (frame-set-background-mode frame t) (face-set-after-frame-default frame))) @@ -2448,7 +2451,9 @@ :group 'frames :group 'basic-faces) -(defface cursor '((t nil)) +(defface cursor + '((((background light)) :background "black") + (((background dark)) :background "white")) "Basic face for the cursor color under X. Note: Other faces cannot inherit from the cursor face." :version "21.1" ------------------------------------------------------------ revno: 101958 committer: Jay Belanger branch nick: trunk timestamp: Wed 2010-10-13 22:14:38 -0500 message: calc-alg.el (math-var): Renamed from `var'. (math-is-polynomial, math-is-poly-rec): Replace `var' with `math-var'. calcalg2.el (math-var): Renamed from `var'. (calcFunc-table, math-scan-for-limits): Replace `var' with `math-var'. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-10-13 23:43:39 +0000 +++ lisp/ChangeLog 2010-10-14 03:14:38 +0000 @@ -1,3 +1,13 @@ +2010-10-14 Jay Belanger + + * calc/calc-alg.el (math-var): Renamed from `var'. + (math-is-polynomial, math-is-poly-rec): Replace `var' + with `math-var'. + + * calc/calcalg2.el (math-var): Renamed from `var'. + (calcFunc-table, math-scan-for-limits): Replace `var' + with `math-var'. + 2010-10-13 Glenn Morris * subr.el (last): Deal with dotted lists (reported in bug#7174). === modified file 'lisp/calc/calc-alg.el' --- lisp/calc/calc-alg.el 2010-01-13 08:35:10 +0000 +++ lisp/calc/calc-alg.el 2010-10-14 03:14:38 +0000 @@ -1659,11 +1659,11 @@ ;; math-is-poly-rec. (defvar math-is-poly-degree) (defvar math-is-poly-loose) -(defvar var) +(defvar math-var) -(defun math-is-polynomial (expr var &optional math-is-poly-degree math-is-poly-loose) +(defun math-is-polynomial (expr math-var &optional math-is-poly-degree math-is-poly-loose) (let* ((math-poly-base-variable (if math-is-poly-loose - (if (eq math-is-poly-loose 'gen) var '(var XXX XXX)) + (if (eq math-is-poly-loose 'gen) math-var '(var XXX XXX)) math-poly-base-variable)) (poly (math-is-poly-rec expr math-poly-neg-powers))) (and (or (null math-is-poly-degree) @@ -1672,11 +1672,11 @@ (defun math-is-poly-rec (expr negpow) (math-poly-simplify - (or (cond ((or (equal expr var) + (or (cond ((or (equal expr math-var) (eq (car-safe expr) '^)) (let ((pow 1) (expr expr)) - (or (equal expr var) + (or (equal expr math-var) (setq pow (nth 2 expr) expr (nth 1 expr))) (or (eq math-poly-mult-powers 1) @@ -1690,7 +1690,7 @@ (equal math-poly-mult-powers (nth 1 m)) (setq math-poly-mult-powers (nth 1 m))) - (or (equal expr var) + (or (equal expr math-var) (eq math-poly-mult-powers 1)) (car m))))) (if (consp pow) @@ -1698,7 +1698,7 @@ (setq pow (math-to-simple-fraction pow)) (and (eq (car-safe pow) 'frac) math-poly-frac-powers - (equal expr var) + (equal expr math-var) (setq math-poly-frac-powers (calcFunc-lcm math-poly-frac-powers (nth 2 pow)))))) @@ -1706,10 +1706,10 @@ (setq pow (math-mul pow math-poly-frac-powers))) (if (integerp pow) (if (and (= pow 1) - (equal expr var)) + (equal expr math-var)) (list 0 1) (if (natnump pow) - (let ((p1 (if (equal expr var) + (let ((p1 (if (equal expr math-var) (list 0 1) (math-is-poly-rec expr nil))) (n pow) @@ -1749,7 +1749,7 @@ math-is-poly-degree)) (math-poly-mul p1 p2)))))) ((eq (car expr) '/) - (and (or (not (math-poly-depends (nth 2 expr) var)) + (and (or (not (math-poly-depends (nth 2 expr) math-var)) (and negpow (math-is-poly-rec (nth 2 expr) nil) (setq math-poly-neg-powers @@ -1759,13 +1759,13 @@ (mapcar (function (lambda (x) (math-div x (nth 2 expr)))) p1)))) ((and (eq (car expr) 'calcFunc-exp) - (equal var '(var e var-e))) - (math-is-poly-rec (list '^ var (nth 1 expr)) negpow)) + (equal math-var '(var e var-e))) + (math-is-poly-rec (list '^ math-var (nth 1 expr)) negpow)) ((and (eq (car expr) 'calcFunc-sqrt) math-poly-frac-powers) (math-is-poly-rec (list '^ (nth 1 expr) '(frac 1 2)) negpow)) (t nil)) - (and (or (not (math-poly-depends expr var)) + (and (or (not (math-poly-depends expr math-var)) math-is-poly-loose) (not (eq (car expr) 'vec)) (list expr))))) === modified file 'lisp/calc/calcalg2.el' --- lisp/calc/calcalg2.el 2010-02-28 01:22:44 +0000 +++ lisp/calc/calcalg2.el 2010-10-14 03:14:38 +0000 @@ -1886,9 +1886,9 @@ ;; math-scan-for-limits. (defvar calc-low) (defvar calc-high) -(defvar var) +(defvar math-var) -(defun calcFunc-table (expr var &optional calc-low calc-high step) +(defun calcFunc-table (expr math-var &optional calc-low calc-high step) (or calc-low (setq calc-low '(neg (var inf var-inf)) calc-high '(var inf var-inf))) (or calc-high (setq calc-high calc-low calc-low 1)) @@ -1917,7 +1917,7 @@ (math-working-step-2 (1+ count)) (math-working-step 0)) (setq expr (math-evaluate-expr - (math-expr-subst expr var '(var DUMMY var-DUMMY)))) + (math-expr-subst expr math-var '(var DUMMY var-DUMMY)))) (while (>= count 0) (setq math-working-step (1+ math-working-step) var-DUMMY calc-low @@ -1940,7 +1940,7 @@ (calc-record-why 'integerp calc-high)) (calc-record-why 'integerp calc-low))) (append (list (or math-tabulate-function 'calcFunc-table) - expr var) + expr math-var) (and (not (and (equal calc-low '(neg (var inf var-inf))) (equal calc-high '(var inf var-inf)))) (list calc-low calc-high)) @@ -1950,11 +1950,11 @@ (cond ((Math-primp x)) ((and (eq (car x) 'calcFunc-subscr) (Math-vectorp (nth 1 x)) - (math-expr-contains (nth 2 x) var)) + (math-expr-contains (nth 2 x) math-var)) (let* ((calc-next-why nil) - (low-val (math-solve-for (nth 2 x) 1 var nil)) + (low-val (math-solve-for (nth 2 x) 1 math-var nil)) (high-val (math-solve-for (nth 2 x) (1- (length (nth 1 x))) - var nil)) + math-var nil)) temp) (and low-val (math-realp low-val) high-val (math-realp high-val)) ------------------------------------------------------------ revno: 101957 committer: Juanma Barranquero branch nick: trunk timestamp: Thu 2010-10-14 03:33:31 +0200 message: src/w32*.c: Make functions static. * src/w32fns.c (w32_wnd_proc, file_dialog_callback): * src/w32font.c (w32_generic_family): * src/w32inevt.c (key_event): * src/w32menu.c (fill_in_menu): * src/w32proc.c (reader_thread, w32_executable_type, compare_env) (merge_and_sort_env, int_from_hex, enum_locale_fn, enum_codepage_fn): * src/w32term.c (w32_read_socket): Make static. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2010-10-13 23:48:09 +0000 +++ src/ChangeLog 2010-10-14 01:33:31 +0000 @@ -1,3 +1,13 @@ +2010-10-14 Juanma Barranquero + + * w32fns.c (w32_wnd_proc, file_dialog_callback): + * w32font.c (w32_generic_family): + * w32inevt.c (key_event): + * w32menu.c (fill_in_menu): + * w32proc.c (reader_thread, w32_executable_type, compare_env) + (merge_and_sort_env, int_from_hex, enum_locale_fn, enum_codepage_fn): + * w32term.c (w32_read_socket): Make static. + 2010-10-13 Juanma Barranquero * image.c (DEF_IMGLIB_FN): Add argument to adapt to strict === modified file 'src/w32fns.c' --- src/w32fns.c 2010-09-24 03:35:55 +0000 +++ src/w32fns.c 2010-10-14 01:33:31 +0000 @@ -1900,7 +1900,7 @@ return cursor; } -extern LRESULT CALLBACK w32_wnd_proc (HWND, UINT, WPARAM, LPARAM); +static LRESULT CALLBACK w32_wnd_proc (HWND, UINT, WPARAM, LPARAM); static BOOL w32_init_class (HINSTANCE hinst) @@ -2672,7 +2672,7 @@ /* Main window procedure */ -LRESULT CALLBACK +static LRESULT CALLBACK w32_wnd_proc (HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) { struct frame *f; @@ -5903,7 +5903,7 @@ read-only when "Directories" is selected in the filter. This allows us to work around the fact that the standard Open File dialog does not support directories. */ -UINT CALLBACK +static UINT CALLBACK file_dialog_callback (HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) { if (msg == WM_NOTIFY) === modified file 'src/w32font.c' --- src/w32font.c 2010-08-06 00:16:24 +0000 +++ src/w32font.c 2010-10-14 01:33:31 +0000 @@ -1058,7 +1058,7 @@ /* Convert generic families to the family portion of lfPitchAndFamily. */ -BYTE +static BYTE w32_generic_family (Lisp_Object name) { /* Generic families. */ === modified file 'src/w32inevt.c' --- src/w32inevt.c 2010-10-01 13:56:33 +0000 +++ src/w32inevt.c 2010-10-14 01:33:31 +0000 @@ -288,7 +288,7 @@ /* return code -1 means that event_queue_ptr won't be incremented. In other word, this event makes two key codes. (by himi) */ -int +static int key_event (KEY_EVENT_RECORD *event, struct input_event *emacs_ev, int *isdead) { static int mod_key_state = 0; === modified file 'src/w32menu.c' --- src/w32menu.c 2010-08-19 15:53:08 +0000 +++ src/w32menu.c 2010-10-14 01:33:31 +0000 @@ -106,6 +106,7 @@ #endif static void utf8to16 (unsigned char *, int, WCHAR *); +static int fill_in_menu (HMENU, widget_value *); void w32_free_menu_strings (HWND); @@ -1568,7 +1569,7 @@ } /* Construct native Windows menu(bar) based on widget_value tree. */ -int +static int fill_in_menu (HMENU menu, widget_value *wv) { int items_added = 0; === modified file 'src/w32proc.c' --- src/w32proc.c 2010-09-20 00:18:18 +0000 +++ src/w32proc.c 2010-10-14 01:33:31 +0000 @@ -159,7 +159,7 @@ child_process child_procs[ MAX_CHILDREN ]; child_process *dead_child = NULL; -DWORD WINAPI reader_thread (void *arg); +static DWORD WINAPI reader_thread (void *arg); /* Find an unused process slot. */ child_process * @@ -279,7 +279,7 @@ is normally blocked until woken by select() to check for input by reading one char. When the read completes, char_avail is signaled to wake up the select emulator and the thread blocks itself again. */ -DWORD WINAPI +static DWORD WINAPI reader_thread (void *arg) { child_process *cp; @@ -608,7 +608,7 @@ # define IMAGE_OPTIONAL_HEADER32 IMAGE_OPTIONAL_HEADER #endif -void +static void w32_executable_type (char * filename, int * is_dos_app, int * is_cygnus_app, @@ -726,7 +726,7 @@ close_file_data (&executable); } -int +static int compare_env (const void *strp1, const void *strp2) { const char *str1 = *(const char **)strp1, *str2 = *(const char **)strp2; @@ -750,7 +750,7 @@ return 1; } -void +static void merge_and_sort_env (char **envp1, char **envp2, char **new_envp) { char **optr, **nptr; @@ -1999,7 +1999,7 @@ return make_number (GetThreadLocale ()); } -DWORD +static DWORD int_from_hex (char * s) { DWORD val = 0; @@ -2021,7 +2021,7 @@ function isn't given a context pointer. */ Lisp_Object Vw32_valid_locale_ids; -BOOL CALLBACK +static BOOL CALLBACK enum_locale_fn (LPTSTR localeNum) { DWORD id = int_from_hex (localeNum); @@ -2085,7 +2085,7 @@ function isn't given a context pointer. */ Lisp_Object Vw32_valid_codepages; -BOOL CALLBACK +static BOOL CALLBACK enum_codepage_fn (LPTSTR codepageNum) { DWORD id = atoi (codepageNum); === modified file 'src/w32term.c' --- src/w32term.c 2010-10-01 13:56:33 +0000 +++ src/w32term.c 2010-10-14 01:33:31 +0000 @@ -3954,7 +3954,7 @@ recursively with different messages by the system. */ -int +static int w32_read_socket (struct terminal *terminal, int expected, struct input_event *hold_quit) { ------------------------------------------------------------ revno: 101956 committer: Katsumi Yamaoka branch nick: trunk timestamp: Thu 2010-10-14 01:17:30 +0000 message: mm-decode.el (mm-shr): Bind shr-blocked-images to suppress compile warning. diff: === modified file 'lisp/gnus/mm-decode.el' --- lisp/gnus/mm-decode.el 2010-10-13 22:21:20 +0000 +++ lisp/gnus/mm-decode.el 2010-10-14 01:17:30 +0000 @@ -1686,6 +1686,7 @@ (declare-function libxml-parse-html-region "xml.c" (start end &optional base-url)) (declare-function shr-insert-document "shr" (dom)) +(defvar shr-blocked-images) (defun mm-shr (handle) ;; Require since we bind its variables. ------------------------------------------------------------ revno: 101955 committer: Juanma Barranquero branch nick: trunk timestamp: Thu 2010-10-14 01:48:09 +0200 message: src/image.c (DEF_IMGLIB_FN): Add argument to adapt to strict prototypes. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2010-10-13 23:08:58 +0000 +++ src/ChangeLog 2010-10-13 23:48:09 +0000 @@ -1,5 +1,10 @@ 2010-10-13 Juanma Barranquero + * image.c (DEF_IMGLIB_FN): Add argument to adapt to strict + prototypes; all callers changed. + +2010-10-13 Juanma Barranquero + * makefile.w32-in (TLIB2): Rename from TLIBW32. (OBJ2): New macro. (WIN32OBJ, FONTOBJ): Remove. === modified file 'src/image.c' --- src/image.c 2010-10-13 14:50:06 +0000 +++ src/image.c 2010-10-13 23:48:09 +0000 @@ -1910,7 +1910,7 @@ #ifdef HAVE_NTGUI /* Macro for defining functions that will be loaded from image DLLs. */ -#define DEF_IMGLIB_FN(func) int (FAR CDECL *fn_##func)() +#define DEF_IMGLIB_FN(func,args) int (FAR CDECL *fn_##func)args /* Macro for loading those image functions from the library. */ #define LOAD_IMGLIB_FN(lib,func) { \ @@ -3265,10 +3265,12 @@ /* XPM library details. */ -DEF_IMGLIB_FN (XpmFreeAttributes); -DEF_IMGLIB_FN (XpmCreateImageFromBuffer); -DEF_IMGLIB_FN (XpmReadFileToImage); -DEF_IMGLIB_FN (XImageFree); +DEF_IMGLIB_FN (XpmFreeAttributes, (XpmAttributes *)); +DEF_IMGLIB_FN (XpmCreateImageFromBuffer, (Display *, char *, xpm_XImage **, + xpm_XImage **, XpmAttributes *)); +DEF_IMGLIB_FN (XpmReadFileToImage, (Display *, char *, xpm_XImage **, + xpm_XImage **, XpmAttributes *)); +DEF_IMGLIB_FN (XImageFree, (xpm_XImage *)); static int init_xpm_functions (Lisp_Object libraries) @@ -5436,27 +5438,31 @@ #ifdef HAVE_NTGUI /* PNG library details. */ -DEF_IMGLIB_FN (png_get_io_ptr); -DEF_IMGLIB_FN (png_sig_cmp); -DEF_IMGLIB_FN (png_create_read_struct); -DEF_IMGLIB_FN (png_create_info_struct); -DEF_IMGLIB_FN (png_destroy_read_struct); -DEF_IMGLIB_FN (png_set_read_fn); -DEF_IMGLIB_FN (png_set_sig_bytes); -DEF_IMGLIB_FN (png_read_info); -DEF_IMGLIB_FN (png_get_IHDR); -DEF_IMGLIB_FN (png_get_valid); -DEF_IMGLIB_FN (png_set_strip_16); -DEF_IMGLIB_FN (png_set_expand); -DEF_IMGLIB_FN (png_set_gray_to_rgb); -DEF_IMGLIB_FN (png_set_background); -DEF_IMGLIB_FN (png_get_bKGD); -DEF_IMGLIB_FN (png_read_update_info); -DEF_IMGLIB_FN (png_get_channels); -DEF_IMGLIB_FN (png_get_rowbytes); -DEF_IMGLIB_FN (png_read_image); -DEF_IMGLIB_FN (png_read_end); -DEF_IMGLIB_FN (png_error); +DEF_IMGLIB_FN (png_get_io_ptr, (png_structp)); +DEF_IMGLIB_FN (png_sig_cmp, (png_bytep, png_size_t, png_size_t)); +DEF_IMGLIB_FN (png_create_read_struct, (png_const_charp, png_voidp, + png_error_ptr, png_error_ptr)); +DEF_IMGLIB_FN (png_create_info_struct, (png_structp)); +DEF_IMGLIB_FN (png_destroy_read_struct, (png_structpp, png_infopp, png_infopp)); +DEF_IMGLIB_FN (png_set_read_fn, (png_structp, png_voidp, png_rw_ptr)); +DEF_IMGLIB_FN (png_set_sig_bytes, (png_structp, int)); +DEF_IMGLIB_FN (png_read_info, (png_structp, png_infop)); +DEF_IMGLIB_FN (png_get_IHDR, (png_structp, png_infop, + png_uint_32 *, png_uint_32 *, + int *, int *, int *, int *, int *)); +DEF_IMGLIB_FN (png_get_valid, (png_structp, png_infop, png_uint_32)); +DEF_IMGLIB_FN (png_set_strip_16, (png_structp)); +DEF_IMGLIB_FN (png_set_expand, (png_structp)); +DEF_IMGLIB_FN (png_set_gray_to_rgb, (png_structp)); +DEF_IMGLIB_FN (png_set_background, (png_structp, png_color_16p, + int, int, double)); +DEF_IMGLIB_FN (png_get_bKGD, (png_structp, png_infop, png_color_16p *)); +DEF_IMGLIB_FN (png_read_update_info, (png_structp, png_infop)); +DEF_IMGLIB_FN (png_get_channels, (png_structp, png_infop)); +DEF_IMGLIB_FN (png_get_rowbytes, (png_structp, png_infop)); +DEF_IMGLIB_FN (png_read_image, (png_structp, png_bytepp)); +DEF_IMGLIB_FN (png_read_end, (png_structp, png_infop)); +DEF_IMGLIB_FN (png_error, (png_structp, png_const_charp)); static int init_png_functions (Lisp_Object libraries) @@ -6039,14 +6045,14 @@ #ifdef HAVE_NTGUI /* JPEG library details. */ -DEF_IMGLIB_FN (jpeg_CreateDecompress); -DEF_IMGLIB_FN (jpeg_start_decompress); -DEF_IMGLIB_FN (jpeg_finish_decompress); -DEF_IMGLIB_FN (jpeg_destroy_decompress); -DEF_IMGLIB_FN (jpeg_read_header); -DEF_IMGLIB_FN (jpeg_read_scanlines); -DEF_IMGLIB_FN (jpeg_std_error); -DEF_IMGLIB_FN (jpeg_resync_to_restart); +DEF_IMGLIB_FN (jpeg_CreateDecompress, (j_decompress_ptr, int, size_t)); +DEF_IMGLIB_FN (jpeg_start_decompress, (j_decompress_ptr)); +DEF_IMGLIB_FN (jpeg_finish_decompress, (j_decompress_ptr)); +DEF_IMGLIB_FN (jpeg_destroy_decompress, (j_decompress_ptr)); +DEF_IMGLIB_FN (jpeg_read_header, (j_decompress_ptr, boolean)); +DEF_IMGLIB_FN (jpeg_read_scanlines, (j_decompress_ptr, JSAMPARRAY, JDIMENSION)); +DEF_IMGLIB_FN (jpeg_std_error, (struct jpeg_error_mgr *)); +DEF_IMGLIB_FN (jpeg_resync_to_restart, (j_decompress_ptr, int)); static int init_jpeg_functions (Lisp_Object libraries) @@ -6572,14 +6578,17 @@ #ifdef HAVE_NTGUI /* TIFF library details. */ -DEF_IMGLIB_FN (TIFFSetErrorHandler); -DEF_IMGLIB_FN (TIFFSetWarningHandler); -DEF_IMGLIB_FN (TIFFOpen); -DEF_IMGLIB_FN (TIFFClientOpen); -DEF_IMGLIB_FN (TIFFGetField); -DEF_IMGLIB_FN (TIFFReadRGBAImage); -DEF_IMGLIB_FN (TIFFClose); -DEF_IMGLIB_FN (TIFFSetDirectory); +DEF_IMGLIB_FN (TIFFSetErrorHandler, (TIFFErrorHandler)); +DEF_IMGLIB_FN (TIFFSetWarningHandler, (TIFFErrorHandler)); +DEF_IMGLIB_FN (TIFFOpen, (const char *, const char *)); +DEF_IMGLIB_FN (TIFFClientOpen, (const char *, const char *, thandle_t, + TIFFReadWriteProc, TIFFReadWriteProc, + TIFFSeekProc, TIFFCloseProc, TIFFSizeProc, + TIFFMapFileProc, TIFFUnmapFileProc)); +DEF_IMGLIB_FN (TIFFGetField, (TIFF *, ttag_t, ...)); +DEF_IMGLIB_FN (TIFFReadRGBAImage, (TIFF *, uint32, uint32, uint32 *, int)); +DEF_IMGLIB_FN (TIFFClose, (TIFF *)); +DEF_IMGLIB_FN (TIFFSetDirectory, (TIFF *, tdir_t)); static int init_tiff_functions (Lisp_Object libraries) @@ -7021,10 +7030,10 @@ #ifdef HAVE_NTGUI /* GIF library details. */ -DEF_IMGLIB_FN (DGifCloseFile); -DEF_IMGLIB_FN (DGifSlurp); -DEF_IMGLIB_FN (DGifOpen); -DEF_IMGLIB_FN (DGifOpenFileName); +DEF_IMGLIB_FN (DGifCloseFile, (GifFileType *)); +DEF_IMGLIB_FN (DGifSlurp, (GifFileType *)); +DEF_IMGLIB_FN (DGifOpen, (void *, InputFunc)); +DEF_IMGLIB_FN (DGifOpenFileName, (const char *)); static int init_gif_functions (Lisp_Object libraries) ------------------------------------------------------------ revno: 101954 author: Glenn Morris committer: Juanma Barranquero branch nick: trunk timestamp: Thu 2010-10-14 01:43:39 +0200 message: lisp/subr.el (last): Deal with dotted lists (reported in bug#7174). diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-10-13 23:15:03 +0000 +++ lisp/ChangeLog 2010-10-13 23:43:39 +0000 @@ -1,3 +1,7 @@ +2010-10-13 Glenn Morris + + * subr.el (last): Deal with dotted lists (reported in bug#7174). + 2010-10-13 Stephen Berman * subr.el (last): Use `safe-length' instead of `length' (bug#7206). === modified file 'lisp/subr.el' --- lisp/subr.el 2010-10-13 23:15:03 +0000 +++ lisp/subr.el 2010-10-13 23:43:39 +0000 @@ -289,7 +289,7 @@ If N is non-nil, return the Nth-to-last link of LIST. If N is bigger than the length of LIST, return LIST." (if n - (and (> n 0) + (and (>= n 0) (let ((m (safe-length list))) (if (< n m) (nthcdr (- m n) list) list))) (and list ------------------------------------------------------------ revno: 101953 author: Stephen Berman committer: Juanma Barranquero branch nick: trunk timestamp: Thu 2010-10-14 01:15:03 +0200 message: lisp/subr.el (last): Use `safe-length' instead of `length' (bug#7206). diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-10-13 22:21:20 +0000 +++ lisp/ChangeLog 2010-10-13 23:15:03 +0000 @@ -1,3 +1,7 @@ +2010-10-13 Stephen Berman + + * subr.el (last): Use `safe-length' instead of `length' (bug#7206). + 2010-10-13 Lars Magne Ingebrigtsen * net/tls.el (tls-program): Remove spurious %s from openssl. === modified file 'lisp/subr.el' --- lisp/subr.el 2010-10-13 03:30:36 +0000 +++ lisp/subr.el 2010-10-13 23:15:03 +0000 @@ -290,10 +290,10 @@ If N is bigger than the length of LIST, return LIST." (if n (and (> n 0) - (let ((m (length list))) + (let ((m (safe-length list))) (if (< n m) (nthcdr (- m n) list) list))) (and list - (nthcdr (1- (length list)) list)))) + (nthcdr (1- (safe-length list)) list)))) (defun butlast (list &optional n) "Return a copy of LIST with the last N elements removed." ------------------------------------------------------------ revno: 101952 author: Lars Magne Ingebrigtsen committer: Katsumi Yamaoka branch nick: trunk timestamp: Wed 2010-10-13 23:12:47 +0000 message: nnimap.el (nnimap-close-server): Forget the nnimap data on close. diff: === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2010-10-13 22:21:20 +0000 +++ lisp/gnus/ChangeLog 2010-10-13 23:12:47 +0000 @@ -1,5 +1,8 @@ 2010-10-13 Lars Magne Ingebrigtsen + * nnimap.el (nnimap-close-server): Forget the nnimap data on close. + This should make server editing work better. + * shr.el (shr-find-fill-point): Don't inloop on indented text. * nnimap.el (nnimap-open-connection): Fix open-tls-stream call. === modified file 'lisp/gnus/nnimap.el' --- lisp/gnus/nnimap.el 2010-10-13 22:21:20 +0000 +++ lisp/gnus/nnimap.el 2010-10-13 23:12:47 +0000 @@ -434,6 +434,7 @@ (when (nnoo-change-server 'nnimap server nil) (ignore-errors (delete-process (get-buffer-process (nnimap-buffer)))) + (nnoo-close-server 'nnimap server) t)) (deffoo nnimap-request-close () ------------------------------------------------------------ revno: 101951 committer: Juanma Barranquero branch nick: trunk timestamp: Thu 2010-10-14 01:08:58 +0200 message: src/makefile.w32-in: Simplify OBJ macros. * makefile.w32-in (TLIB2): Rename from TLIBW32. (OBJ2): New macro. (WIN32OBJ, FONTOBJ): Remove. (OBJ1): Redistribute object files with OBJ2. (LIBS, $(TEMACS)): Use TLIB2. (make-buildobj-CMD, make-buildobj-SH): Use OBJ2. ($(TLIB2), TAGS, TAGS-LISP, TAGS-gmake): Depend on OBJ2. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2010-10-13 14:50:06 +0000 +++ src/ChangeLog 2010-10-13 23:08:58 +0000 @@ -1,5 +1,15 @@ 2010-10-13 Juanma Barranquero + * makefile.w32-in (TLIB2): Rename from TLIBW32. + (OBJ2): New macro. + (WIN32OBJ, FONTOBJ): Remove. + (OBJ1): Redistribute object files with OBJ2. + (LIBS, $(TEMACS)): Use TLIB2. + (make-buildobj-CMD, make-buildobj-SH): Use OBJ2. + ($(TLIB2), TAGS, TAGS-LISP, TAGS-gmake): Depend on OBJ2. + +2010-10-13 Juanma Barranquero + * emacs.c (Vdynamic_library_alist) (syms_of_emacs) : Move from image.c and rename. Doc fix. === modified file 'src/makefile.w32-in' --- src/makefile.w32-in 2010-10-03 12:36:19 +0000 +++ src/makefile.w32-in 2010-10-13 23:08:58 +0000 @@ -37,7 +37,7 @@ TEMACS_TMP = $(BLD)/temacs.bin TLIB0 = $(BLD)/temacs0.$(A) TLIB1 = $(BLD)/temacs1.$(A) -TLIBW32 = $(BLD)/temacw32.$(A) +TLIB2 = $(BLD)/temacs2.$(A) TOBJ = $(BLD)/firstfile.$(O) TRES = $(BLD)/emacs.res TLASTLIB = $(BLD)/lastfile.$(A) @@ -94,8 +94,9 @@ $(BLD)/scroll.$(O) \ $(BLD)/search.$(O) \ $(BLD)/sound.$(O) \ - $(BLD)/syntax.$(O) \ - $(BLD)/sysdep.$(O) \ + $(BLD)/syntax.$(O) + +OBJ2 = $(BLD)/sysdep.$(O) \ $(BLD)/term.$(O) \ $(BLD)/tparam.$(O) \ $(BLD)/undo.$(O) \ @@ -125,28 +126,27 @@ $(BLD)/fringe.$(O) \ $(BLD)/image.$(O) \ $(BLD)/terminal.$(O) \ - $(BLD)/menu.$(O) - -WIN32OBJ = $(BLD)/w32term.$(O) \ - $(BLD)/w32xfns.$(O) \ - $(BLD)/w32fns.$(O) \ - $(BLD)/xfaces.$(O) \ - $(BLD)/w32select.$(O) \ - $(BLD)/w32menu.$(O) \ - $(BLD)/w32reg.$(O) - -FONTOBJ = $(BLD)/w32font.$(O) $(BLD)/w32uniscribe.$(O) + $(BLD)/menu.$(O) \ + $(BLD)/w32term.$(O) \ + $(BLD)/w32xfns.$(O) \ + $(BLD)/w32fns.$(O) \ + $(BLD)/xfaces.$(O) \ + $(BLD)/w32select.$(O) \ + $(BLD)/w32menu.$(O) \ + $(BLD)/w32reg.$(O) \ + $(BLD)/w32font.$(O) \ + $(BLD)/w32uniscribe.$(O) LIBS = $(TLIB0) \ $(TLIB1) \ - $(TLIBW32) \ + $(TLIB2) \ $(TLASTLIB) \ $(WINMM) \ $(ADVAPI32) \ $(GDI32) \ $(COMDLG32) \ $(USER32) \ - $(MPR) \ + $(MPR) \ $(SHELL32) \ $(WINSPOOL) \ $(OLE32) \ @@ -174,7 +174,7 @@ # (it is the preload heap size in MB). # temacs: stamp_BLD $(TEMACS) -$(TEMACS): $(TLIB0) $(TLIB1) $(TLIBW32) $(TLASTLIB) $(TOBJ) $(TRES) \ +$(TEMACS): $(TLIB0) $(TLIB1) $(TLIB2) $(TLASTLIB) $(TOBJ) $(TRES) \ ../nt/$(BLD)/addsection.exe $(LINK) $(LINK_OUT)$(TEMACS_TMP) $(FULL_LINK_FLAGS) $(TOBJ) $(TRES) $(LIBS) "../nt/$(BLD)/addsection" "$(TEMACS_TMP)" "$(TEMACS)" EMHEAP 21 @@ -190,16 +190,14 @@ echo #define BUILDOBJ ^"\> buildobj.h echo $(OBJ0) \>> buildobj.h echo $(OBJ1) \>> buildobj.h - echo $(WIN32OBJ) \>> buildobj.h - echo $(FONTOBJ) \>> buildobj.h + echo $(OBJ2) \>> buildobj.h echo ^">> buildobj.h make-buildobj-SH: echo '#define BUILDOBJ $(DQUOTE)\' > buildobj.h echo $(OBJ0) '\' >> buildobj.h echo $(OBJ1) '\' >> buildobj.h - echo $(WIN32OBJ) '\' >> buildobj.h - echo $(FONTOBJ) '\' >> buildobj.h + echo $(OBJ2) '\' >> buildobj.h echo '$(DQUOTE)' >> buildobj.h bootstrap: bootstrap-emacs @@ -249,7 +247,7 @@ $(TLIB1): $(OBJ1) - $(DEL) $@ $(AR) $(AR_OUT)$@ $(ALL_DEPS) -$(TLIBW32): $(WIN32OBJ) $(FONTOBJ) +$(TLIB2): $(OBJ2) - $(DEL) $@ $(AR) $(AR_OUT)$@ $(ALL_DEPS) @@ -298,10 +296,10 @@ ## ## This works only with GNU Make. -TAGS: $(OBJ0) $(OBJ1) $(WIN32OBJ) $(FONTOBJ) +TAGS: $(OBJ0) $(OBJ1) $(OBJ2) $(MAKE) $(MFLAGS) TAGS-$(MAKETYPE) -TAGS-LISP: $(OBJ0) $(OBJ1) $(WIN32OBJ) $(FONTOBJ) +TAGS-LISP: $(OBJ0) $(OBJ1) $(OBJ2) $(MAKE) $(MFLAGS) TAGS-LISP-$(MAKETYPE) TAGS-gmake: @@ -311,8 +309,7 @@ ../lib-src/$(BLD)/etags.exe -a --regex=@../nt/emacs-src.tags \ $(patsubst $(BLD)%.$(O),$(CURDIR)%.c,$(OBJ1)) ../lib-src/$(BLD)/etags.exe -a --regex=@../nt/emacs-src.tags \ - $(patsubst $(BLD)%.$(O),$(CURDIR)%.c,$(WIN32OBJ)) \ - $(patsubst $(BLD)%.$(O),$(CURDIR)%.c,$(FONTOBJ)) \ + $(patsubst $(BLD)%.$(O),$(CURDIR)%.c,$(OBJ2)) \ $(CURDIR)/*.h TAGS-nmake: @@ -1752,4 +1749,4 @@ # Each object file depends on stamp_BLD, because in parallel builds we must # make sure $(BLD) exists before starting compilations. # -$(OBJ0) $(OBJ1) $(WIN32OBJ) $(FONTOBJ) $(BLD)/lastfile.$(O) $(BLD)/firstfile.$(O): stamp_BLD +$(OBJ0) $(OBJ1) $(OBJ2) $(BLD)/lastfile.$(O) $(BLD)/firstfile.$(O): stamp_BLD ------------------------------------------------------------ revno: 101950 author: Gnus developers committer: Katsumi Yamaoka branch nick: trunk timestamp: Wed 2010-10-13 22:21:20 +0000 message: Merge changes made in Gnus trunk. auth.texi (GnuPG and EasyPG Assistant Configuration): Fix syntax and trim sentence. shr.el (shr-current-column): Remove buggy and unnecessary function. auth.texi: Fix up pxref/xref. auth.texi (GnuPG and EasyPG Assistant Configuration): Fix up the @item syntax for in-Emacs makeinfo. gnus-spec.el (gnus-parse-simple-format): princ doesn't really insert anything in Emacs. mm-decode.el (mm-shr): Allow use from non-Gnus users. nnimap.el (nnimap-parse-flags): Be more strict when looking for FETCH responses. nnimap.el, tls.el: Rip the STARTTLS stuff out of tls.el again, and just bind it directly from nnimap. shr.el (shr-find-fill-point): Use a filling algorithm that should probably work for CJVK text, too. nnimap.el (nnimap-open-connection): Fix open-tls-stream call. nnimap.el (nnimap-parse-flags): Fix regexp. tls.el (tls-program): Remove spurious %s from openssl. shr.el (shr-find-fill-point): Don't inloop on indented text. diff: === modified file 'doc/misc/ChangeLog' --- doc/misc/ChangeLog 2010-10-12 01:49:05 +0000 +++ doc/misc/ChangeLog 2010-10-13 22:21:20 +0000 @@ -1,3 +1,13 @@ +2010-10-13 Lars Magne Ingebrigtsen + + * auth.texi (GnuPG and EasyPG Assistant Configuration): Fix up the + @item syntax for in-Emacs makeinfo. + +2010-10-13 Teodor Zlatanov + + * auth.texi (GnuPG and EasyPG Assistant Configuration): Fix syntax and + trim sentence. + 2010-10-12 Daiki Ueno * epa.texi (Caching Passphrases): === modified file 'doc/misc/auth.texi' --- doc/misc/auth.texi 2010-10-12 01:49:05 +0000 +++ doc/misc/auth.texi 2010-10-13 22:21:20 +0000 @@ -177,8 +177,8 @@ If you don't customize @code{auth-sources}, you'll have to live with the defaults: any host and any port are looked up in the netrc -file @code{~/.authinfo.gpg}, which is a GnuPG encrypted file. -@xref{GnuPG and EasyPG Assistant Configuration}. +file @code{~/.authinfo.gpg}, which is a GnuPG encrypted file +(@pxref{GnuPG and EasyPG Assistant Configuration}). The simplest working netrc line example is one without a port. @@ -271,9 +271,8 @@ reads @code{~/.authinfo.gpg}, which is a GnuPG encrypted file. In Emacs 23 or later there is an option @code{auto-encryption-mode} to -automatically decrypt @code{*.gpg} files. It is enabled by default so -there is no setting is needed. If you are using earlier versions of -Emacs, you will need: +automatically decrypt @code{*.gpg} files. It is enabled by default. +If you are using earlier versions of Emacs, you will need: @lisp (require 'epa-file) @@ -282,14 +281,17 @@ If you want your GnuPG passwords to be cached, set up @code{gpg-agent} or EasyPG Assitant -@pxref{Caching Passphrases, , Caching Passphrases, epa} +@xref{Caching Passphrases, , Caching Passphrases, epa} To quick start, here are some questions: @enumerate -@item Do you use GnuPG version 2 instead of GnuPG version 1? -@item Do you use symmetric encryption rather than public key encryption? -@item Do you want to use gpg-agent? +@item +Do you use GnuPG version 2 instead of GnuPG version 1? +@item +Do you use symmetric encryption rather than public key encryption? +@item +Do you want to use gpg-agent? @end enumerate Here are configurations depending on your answers: @@ -306,8 +308,8 @@ @item No @tab No @tab No @tab You can't, without gpg-agent. @end multitable -To set up gpg-agent, follow the instruction in GnuPG manual. -@pxref{Invoking GPG-AGENT, , Invoking GPG-AGENT, gnupg}. +To set up gpg-agent, follow the instruction in GnuPG manual +(@pxref{Invoking GPG-AGENT, , Invoking GPG-AGENT, gnupg}). To set up elisp passphrase cache, set @code{epa-file-cache-passphrase-for-symmetric-encryption}. === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-10-13 14:50:06 +0000 +++ lisp/ChangeLog 2010-10-13 22:21:20 +0000 @@ -1,3 +1,10 @@ +2010-10-13 Lars Magne Ingebrigtsen + + * net/tls.el (tls-program): Remove spurious %s from openssl. + (tls-starttls-switches): Remove starttls hack. + (open-tls-stream): Ditto. + (tls-find-starttls-argument): Ditto. + 2010-10-13 Juanma Barranquero * image.el (image-library-alist): Declare as obsolete alias. === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2010-10-13 11:55:48 +0000 +++ lisp/gnus/ChangeLog 2010-10-13 22:21:20 +0000 @@ -1,3 +1,30 @@ +2010-10-13 Lars Magne Ingebrigtsen + + * shr.el (shr-find-fill-point): Don't inloop on indented text. + + * nnimap.el (nnimap-open-connection): Fix open-tls-stream call. + (nnimap-parse-flags): Fix regexp. + + * shr.el (shr-find-fill-point): Use a filling algorithm that should + probably work for CJVK text, too. + + * nnimap.el (nnimap-extend-tls-programs): Removed. + (nnimap-open-connection): Bind STARTTLS to openssl explicitly. + +2010-10-13 Julien Danjou + + * nnimap.el (nnimap-parse-flags): Be more strict when looking for FETCH + responses. + +2010-10-13 Lars Magne Ingebrigtsen + + * mm-decode.el (mm-shr): Allow use from non-Gnus users. + + * gnus-spec.el (gnus-parse-simple-format): princ doesn't really insert + anything in Emacs. + + * shr.el (shr-current-column): Remove buggy and unnecessary function. + 2010-10-13 Julien Danjou * shr.el (shr-width): Make shr-width a defcustom with default to === modified file 'lisp/gnus/gnus-spec.el' --- lisp/gnus/gnus-spec.el 2010-10-11 23:29:33 +0000 +++ lisp/gnus/gnus-spec.el 2010-10-13 22:21:20 +0000 @@ -680,7 +680,7 @@ ((string= fstring "%d") (setq dontinsert t) (if insert - (list `(princ ,(car flist))) + `(insert (int-to-string ,(car flist))) (list `(int-to-string ,(car flist))))) ;; Just lots of chars and strings. ((string-match "\\`\\(%[cs]\\)+\\'" fstring) === modified file 'lisp/gnus/mm-decode.el' --- lisp/gnus/mm-decode.el 2010-10-11 23:29:33 +0000 +++ lisp/gnus/mm-decode.el 2010-10-13 22:21:20 +0000 @@ -1691,8 +1691,11 @@ ;; Require since we bind its variables. (require 'shr) (let ((article-buffer (current-buffer)) - (shr-blocked-images (with-current-buffer gnus-summary-buffer - gnus-blocked-images)) + (shr-blocked-images (if (and (boundp 'gnus-summary-buffer) + (buffer-name gnus-summary-buffer)) + (with-current-buffer gnus-summary-buffer + gnus-blocked-images) + shr-blocked-images)) (shr-content-function (lambda (id) (let ((handle (mm-get-content-id id))) (when handle === modified file 'lisp/gnus/nnimap.el' --- lisp/gnus/nnimap.el 2010-10-12 22:18:24 +0000 +++ lisp/gnus/nnimap.el 2010-10-13 22:21:20 +0000 @@ -318,11 +318,10 @@ (setq port (or nnimap-server-port "imap"))) '("imap")) ((eq nnimap-stream 'starttls) - (let ((tls-program (nnimap-extend-tls-programs))) + (let ((tls-program "openssl s_client %s -connect %h:%p -no_ssl2 -ign_eof -starttls imap")) (open-tls-stream "*nnimap*" (current-buffer) nnimap-address - (setq port (or nnimap-server-port "imap")) - 'starttls)) + (setq port (or nnimap-server-port "imap")))) '("imap")) ((memq nnimap-stream '(ssl tls)) (funcall (if (fboundp 'open-gnutls-stream) @@ -419,19 +418,6 @@ (nnimap-command "ENABLE QRESYNC")) (nnimap-process nnimap-object)))))))) -(defun nnimap-extend-tls-programs () - (let ((programs tls-program) - result) - (unless (consp programs) - (setq programs (list programs))) - (dolist (program programs) - (when (assoc (car (split-string program)) tls-starttls-switches) - (push (if (not (string-match "%s" program)) - (concat program " " "%s") - program) - result))) - (nreverse result))) - (defun nnimap-find-parameter (parameter elems) (let (result) (dolist (elem elems) @@ -1303,7 +1289,7 @@ (setq start end)) (setq start (point)) (goto-char end)) - (while (search-forward " FETCH " start t) + (while (re-search-forward "^\\* [0-9]+ FETCH " start t) (setq elems (read (current-buffer))) (push (cons (cadr (memq 'UID elems)) (cadr (memq 'FLAGS elems))) === modified file 'lisp/gnus/shr.el' --- lisp/gnus/shr.el 2010-10-13 11:55:48 +0000 +++ lisp/gnus/shr.el 2010-10-13 22:21:20 +0000 @@ -219,8 +219,8 @@ (unless shr-start (setq shr-start (point))) (insert elem) - (when (> (shr-current-column) shr-width) - (if (not (search-backward " " (line-beginning-position) t)) + (while (> (current-column) shr-width) + (if (not (shr-find-fill-point)) (insert "\n") (delete-char 1) (insert "\n") @@ -235,23 +235,16 @@ (defun shr-find-fill-point () (let ((found nil)) (while (and (not found) - (not (bolp))) - (when (or (eq (preceding-char) ? ) - (aref fill-find-break-point-function-table (preceding-char))) + (> (current-column) shr-indentation)) + (when (and (or (eq (preceding-char) ? ) + (aref fill-find-break-point-function-table + (preceding-char))) + (<= (current-column) shr-width)) (setq found (point))) (backward-char 1)) (or found (end-of-line)))) -(defun shr-current-column () - (let ((column 0)) - (save-excursion - (beginning-of-line) - (while (not (eolp)) - (incf column (char-width (following-char))) - (forward-char 1))) - column)) - (defun shr-ensure-newline () (unless (zerop (current-column)) (insert "\n"))) === modified file 'lisp/net/tls.el' --- lisp/net/tls.el 2010-10-01 12:56:44 +0000 +++ lisp/net/tls.el 2010-10-13 22:21:20 +0000 @@ -75,13 +75,9 @@ :type 'regexp :group 'tls) -(defvar tls-starttls-switches - '(("openssl" "-starttls imap")) - "Alist of programs and the switches necessary to get starttls behaviour.") - (defcustom tls-program '("gnutls-cli --insecure -p %p %h" "gnutls-cli --insecure -p %p %h --protocols ssl3" - "openssl s_client %s -connect %h:%p -no_ssl2 -ign_eof") + "openssl s_client -connect %h:%p -no_ssl2 -ign_eof") "List of strings containing commands to start TLS stream to a host. Each entry in the list is tried until a connection is successful. %h is replaced with server hostname, %p with port to connect to. @@ -203,7 +199,7 @@ (push (cons (match-string 1) (match-string 2)) vals)) (nreverse vals)))))) -(defun open-tls-stream (name buffer host port &optional starttlsp) +(defun open-tls-stream (name buffer host port) "Open a TLS connection for a port to a host. Returns a subprocess-object to represent the connection. Input and output work as for subprocesses; `delete-process' closes it. @@ -233,9 +229,6 @@ (format-spec cmd (format-spec-make - ?s (if starttlsp - (tls-find-starttls-argument cmd) - "") ?h host ?p (if (integerp port) (int-to-string port) @@ -307,11 +300,6 @@ (kill-buffer buffer)) done)) -(defun tls-find-starttls-argument (command) - (let ((command (car (split-string command)))) - (or (cadr (assoc command tls-starttls-switches)) - ""))) - (provide 'tls) ;;; tls.el ends here ------------------------------------------------------------ revno: 101949 committer: Juanma Barranquero branch nick: trunk timestamp: Wed 2010-10-13 16:50:06 +0200 message: Rename `image-library-alist' to `dynamic-library-alist'. * etc/NEWS: Mention `dynamic-library-alist'. * lisp/image.el (image-library-alist): Declare as obsolete alias. (image-type-available-p): Use `dynamic-library-alist'. * lisp/term/w32-win.el (dynamic-library-alist): Use instead of `image-library-alist'. * nt/INSTALL: Refer to `dynamic-library-alist'. * src/image.c (Vimage_library_alist) (syms_of_image) : Move to src/emacs.c and rename. (lookup_image_type): Use Vdynamic_library_alist. (Finit_image_library): Doc fix. * src/emacs.c (Vdynamic_library_alist) (syms_of_emacs) : Move from src/image.c and rename. Doc fix. * src/lisp.h (Vdynamic_library_alist): Declare extern. diff: === modified file 'etc/ChangeLog' --- etc/ChangeLog 2010-10-13 03:17:59 +0000 +++ etc/ChangeLog 2010-10-13 14:50:06 +0000 @@ -1,3 +1,7 @@ +2010-10-13 Juanma Barranquero + + * NEWS: Mention `dynamic-library-alist'. + 2010-10-13 Glenn Morris * NEXTSTEP: New file, extracted from ../nextstep/{AUTHORS,README}. === modified file 'etc/NEWS' --- etc/NEWS 2010-10-12 03:12:33 +0000 +++ etc/NEWS 2010-10-13 14:50:06 +0000 @@ -578,6 +578,11 @@ * Lisp changes in Emacs 24.1 +** `image-library-alist' is renamed to `dynamic-library-alist'. +The variable is now used to load all kind of supported dynamic libraries, +not just image libraries. The previous name is still available as an +obsolete alias. + ** New variable syntax-propertize-function to set syntax-table properties. Replaces font-lock-syntactic-keywords which are now obsolete. This allows syntax-table properties to be set independently from font-lock: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2010-10-13 03:30:36 +0000 +++ lisp/ChangeLog 2010-10-13 14:50:06 +0000 @@ -1,3 +1,11 @@ +2010-10-13 Juanma Barranquero + + * image.el (image-library-alist): Declare as obsolete alias. + (image-type-available-p): Use `dynamic-library-alist'. + + * term/w32-win.el (dynamic-library-alist): + Use instead of `image-library-alist'. + 2010-10-13 IRIE Shinsuke (tiny change) * subr.el (last): Make it faster. (Bug#7174) === modified file 'lisp/image.el' --- lisp/image.el 2010-10-11 04:49:59 +0000 +++ lisp/image.el 2010-10-13 14:50:06 +0000 @@ -330,14 +330,16 @@ type) -(defvar image-library-alist) +(define-obsolete-variable-alias + 'image-library-alist + 'dynamic-library-alist "24.1") ;;;###autoload (defun image-type-available-p (type) "Return non-nil if image type TYPE is available. Image types are symbols like `xbm' or `jpeg'." (and (fboundp 'init-image-library) - (init-image-library type image-library-alist))) + (init-image-library type dynamic-library-alist))) ;;;###autoload === modified file 'lisp/term/w32-win.el' --- lisp/term/w32-win.el 2010-01-13 08:35:10 +0000 +++ lisp/term/w32-win.el 2010-10-13 14:50:06 +0000 @@ -196,10 +196,10 @@ "Report an error when a suspend is attempted." (error "Suspending an Emacs running under W32 makes no sense")) -(defvar image-library-alist) +(defvar dynamic-library-alist) -;;; Set default known names for image libraries -(setq image-library-alist +;;; Set default known names for external libraries +(setq dynamic-library-alist '((xpm "libxpm.dll" "xpm4.dll" "libXpm-nox4.dll") (png "libpng12d.dll" "libpng12.dll" "libpng.dll" ;; these are libpng 1.2.8 from GTK+ === modified file 'nt/ChangeLog' --- nt/ChangeLog 2010-10-06 10:55:03 +0000 +++ nt/ChangeLog 2010-10-13 14:50:06 +0000 @@ -1,3 +1,7 @@ +2010-10-13 Juanma Barranquero + + * INSTALL: Refer to `dynamic-library-alist'. + 2010-10-06 Juanma Barranquero * INSTALL: Add note about problematic characters passed to configure. === modified file 'nt/INSTALL' --- nt/INSTALL 2010-10-06 10:55:03 +0000 +++ nt/INSTALL 2010-10-13 14:50:06 +0000 @@ -266,7 +266,7 @@ library is not an error; the associated image format will simply be unavailable. Note that once Emacs has determined that a library can not be found, there's no way to force it to try again, other than - restarting. See the variable `image-library-alist' to configure the + restarting. See the variable `dynamic-library-alist' to configure the expected names of the libraries. Some image libraries have dependencies on one another, or on zlib. === modified file 'src/ChangeLog' --- src/ChangeLog 2010-10-12 14:37:33 +0000 +++ src/ChangeLog 2010-10-13 14:50:06 +0000 @@ -1,3 +1,16 @@ +2010-10-13 Juanma Barranquero + + * emacs.c (Vdynamic_library_alist) + (syms_of_emacs) : Move from image.c and rename. + Doc fix. + + * lisp.h (Vdynamic_library_alist): Declare extern. + + * image.c (Vimage_library_alist) + (syms_of_image) : Move to emacs.c and rename. + (lookup_image_type): Use Vdynamic_library_alist. + (Finit_image_library): Doc fix. + 2010-10-12 Dan Nicolaescu * Makefile.in (lispsource, libsrc, etc, oldxmenudir, lwlibdir) === modified file 'src/emacs.c' --- src/emacs.c 2010-10-03 13:59:56 +0000 +++ src/emacs.c 2010-10-13 14:50:06 +0000 @@ -187,6 +187,9 @@ Lisp code. */ Lisp_Object Vemacs_copyright, Vemacs_version; +/* Alist of external libraries and files implementing them. */ +Lisp_Object Vdynamic_library_alist; + /* If non-zero, emacs should not attempt to use a window-specific code, but instead should use the virtual terminal under which it was started. */ int inhibit_window_system; @@ -2507,6 +2510,24 @@ doc: /* Version numbers of this version of Emacs. */); Vemacs_version = build_string (emacs_version); + DEFVAR_LISP ("dynamic-library-alist", &Vdynamic_library_alist, + doc: /* Alist of dynamic libraries vs external files implementing them. +Each element is a list (LIBRARY FILE...), where the car is a symbol +representing a supported external library, and the rest are strings giving +alternate filenames for that library. + +Emacs tries to load the library from the files in the order they appear on +the list; if none is loaded, the running session of Emacs won't have access +to that library. + +Note that image types `pbm' and `xbm' do not need entries in this variable +because they do not depend on external libraries and are always available. + +Also note that this is not a generic facility for accessing external +libraries; only those already known by Emacs will be loaded. */); + Vdynamic_library_alist = Qnil; + Fput (intern_c_string ("dynamic-library-alist"), Qrisky_local_variable, Qt); + /* Make sure IS_DAEMON starts up as false. */ daemon_pipe[1] = 0; } === modified file 'src/image.c' --- src/image.c 2010-10-01 12:25:21 +0000 +++ src/image.c 2010-10-13 14:50:06 +0000 @@ -567,10 +567,6 @@ Lisp_Object Vimage_types; -/* An alist of image types and libraries that implement the type. */ - -Lisp_Object Vimage_library_alist; - /* Cache for delayed-loading image types. */ static Lisp_Object Vimage_type_cache; @@ -645,7 +641,7 @@ struct image_type *type; /* We must initialize the image-type if it hasn't been already. */ - if (NILP (Finit_image_library (symbol, Vimage_library_alist))) + if (NILP (Finit_image_library (symbol, Vdynamic_library_alist))) return 0; /* unimplemented */ for (type = image_types; type; type = type->next) @@ -1923,10 +1919,11 @@ } /* Load a DLL implementing an image type. - The `image-library-alist' variable associates a symbol, - identifying an image type, to a list of possible filenames. + The argument LIBRARIES is usually the variable + `dynamic-library-alist', which associates a symbol, identifying + an external DLL library, to a list of possible filenames. The function returns NULL if no library could be loaded for - the given image type, or if the library was previously loaded; + the given symbol, or if the library was previously loaded; else the handle of the DLL. */ static HMODULE w32_delayed_load (Lisp_Object libraries, Lisp_Object type) @@ -8583,7 +8580,7 @@ Image types pbm and xbm are prebuilt; other types are loaded here. Libraries to load are specified in alist LIBRARIES (usually, the value -of `image-library-alist', which see). */) +of `dynamic-library-alist', which see). */) (Lisp_Object type, Lisp_Object libraries) { Lisp_Object tested; @@ -8659,20 +8656,6 @@ To check whether it is really supported, use `image-type-available-p'. */); Vimage_types = Qnil; - DEFVAR_LISP ("image-library-alist", &Vimage_library_alist, - doc: /* Alist of image types vs external libraries needed to display them. - -Each element is a list (IMAGE-TYPE LIBRARY...), where the car is a symbol -representing a supported image type, and the rest are strings giving -alternate filenames for the corresponding external libraries. - -Emacs tries to load the libraries in the order they appear on the -list; if none is loaded, the running session of Emacs won't -support the image type. Types 'pbm and 'xbm don't need to be -listed; they are always supported. */); - Vimage_library_alist = Qnil; - Fput (intern_c_string ("image-library-alist"), Qrisky_local_variable, Qt); - DEFVAR_LISP ("max-image-size", &Vmax_image_size, doc: /* Maximum size of images. Emacs will not load an image into memory if its pixel width or === modified file 'src/lisp.h' --- src/lisp.h 2010-09-29 09:06:53 +0000 +++ src/lisp.h 2010-10-13 14:50:06 +0000 @@ -3300,6 +3300,7 @@ extern Lisp_Object Vinstallation_directory; extern Lisp_Object empty_unibyte_string, empty_multibyte_string; extern Lisp_Object Qfile_name_handler_alist; +extern Lisp_Object Vdynamic_library_alist; extern void (*fatal_error_signal_hook) (void); EXFUN (Fkill_emacs, 1) NO_RETURN; #if HAVE_SETLOCALE ------------------------------------------------------------ revno: 101948 author: Julien Danjou committer: Katsumi Yamaoka branch nick: trunk timestamp: Wed 2010-10-13 11:55:48 +0000 message: shr: make shr-width a defcustom, use it in shr-tag-img. diff: === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2010-10-13 05:39:17 +0000 +++ lisp/gnus/ChangeLog 2010-10-13 11:55:48 +0000 @@ -1,3 +1,9 @@ +2010-10-13 Julien Danjou + + * shr.el (shr-width): Make shr-width a defcustom with default to + fill-column. + (shr-tag-img): Use shr-width rather than fill-column. + 2010-10-13 Katsumi Yamaoka * gnus-dired.el (gnus-dired-attach): Silence XEmacs 21.5 when compiling. === modified file 'lisp/gnus/shr.el' --- lisp/gnus/shr.el 2010-10-12 22:18:24 +0000 +++ lisp/gnus/shr.el 2010-10-13 11:55:48 +0000 @@ -68,14 +68,16 @@ :group 'shr :type 'char) +(defcustom shr-width fill-column + "Frame width to use for rendering." + :type 'integer + :group 'shr) + (defvar shr-content-function nil "If bound, this should be a function that will return the content. This is used for cid: URLs, and the function is called with the cid: URL as the argument.") -(defvar shr-width 70 - "Frame width to use for rendering.") - ;;; Internal variables. (defvar shr-folding-mode nil) @@ -404,7 +406,7 @@ (when width ;; Check that width is not larger than max width, otherwise ignore ;; align - (let ((max-width (* fill-column (frame-char-width))) + (let ((max-width (* shr-width (frame-char-width))) (width (string-to-number width))) (when (< width max-width) (let ((align (cdr (assq :align cont)))) ------------------------------------------------------------ revno: 101947 committer: Katsumi Yamaoka branch nick: trunk timestamp: Wed 2010-10-13 05:39:17 +0000 message: gnus-dired.el (gnus-dired-attach): Silence XEmacs 21.5 when compiling. diff: === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2010-10-13 02:19:11 +0000 +++ lisp/gnus/ChangeLog 2010-10-13 05:39:17 +0000 @@ -1,5 +1,7 @@ 2010-10-13 Katsumi Yamaoka + * gnus-dired.el (gnus-dired-attach): Silence XEmacs 21.5 when compiling. + * gnus-gravatar.el (gnus-gravatar-transform-address): Adjust avatars' position when (X-)Faces exist. (gnus-treat-from-gravatar, gnus-treat-mail-gravatar): Force displaying === modified file 'lisp/gnus/gnus-dired.el' --- lisp/gnus/gnus-dired.el 2010-09-30 08:39:23 +0000 +++ lisp/gnus/gnus-dired.el 2010-10-13 05:39:17 +0000 @@ -133,7 +133,9 @@ (mapcar ;; don't attach directories (lambda (f) (if (file-directory-p f) nil f)) - (nreverse (dired-map-over-marks (dired-get-filename) nil)))))) + (nreverse + (let ((arg nil)) ;; Silence XEmacs 21.5 when compiling. + (dired-map-over-marks (dired-get-filename) arg))))))) (let ((destination nil) (files-str nil) (bufs nil))