Mercurial > emacs
changeset 109415:5922ae6fb6dc
Merge from mainline.
author | Katsumi Yamaoka <yamaoka@jpl.org> |
---|---|
date | Tue, 22 Jun 2010 22:50:34 +0000 |
parents | 51f725b66eac (current diff) 3cf8b3dca100 (diff) |
children | c3ebf31421b2 |
files | |
diffstat | 21 files changed, 312 insertions(+), 176 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/ChangeLog Tue Jun 22 00:22:23 2010 +0000 +++ b/lisp/ChangeLog Tue Jun 22 22:50:34 2010 +0000 @@ -1,3 +1,16 @@ +2010-06-22 Glenn Morris <rgm@gnu.org> + + * textmodes/texinfmt.el (texinfo-format-region) + (texinfo-raise-lower-sections, texinfo-format-separate-node) + (texinfo-itemize-item, texinfo-multitable-item, texinfo-alias) + (texinfo-format-option, texinfo-noindent): + Use line-beginning-position and line-end-position. + + * calc/calc-aent.el, calc/calc-ext.el, calc/calc-lang.el: + * calc/calc-store.el, calc/calc-units.el, calc/calc.el: + * calc/calccomp.el: Add explicit utf-8 coding cookies to files with + utf-8 characters. + 2010-06-21 Karl Fogel <kfogel@red-bean.com> * simple.el (compose-mail): Fix doc string to refer to
--- a/lisp/calc/calc-aent.el Tue Jun 22 00:22:23 2010 +0000 +++ b/lisp/calc/calc-aent.el Tue Jun 22 22:50:34 2010 +0000 @@ -1,7 +1,7 @@ ;;; calc-aent.el --- algebraic entry functions for Calc -;; Copyright (C) 1990, 1991, 1992, 1993, 2001, 2002, 2003, 2004, -;; 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. +;; Copyright (C) 1990, 1991, 1992, 1993, 2001, 2002, 2003, 2004, 2005, +;; 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. ;; Author: Dave Gillespie <daveg@synaptics.com> ;; Maintainer: Jay Belanger <jay.p.belanger@gmail.com> @@ -609,9 +609,9 @@ (setq math-exp-str (math-remove-percentsigns math-exp-str))) (if calc-language-input-filter (setq math-exp-str (funcall calc-language-input-filter math-exp-str))) - (while (setq math-exp-token + (while (setq math-exp-token (string-match "\\.\\.\\([^.]\\|.[^.]\\)" math-exp-str)) - (setq math-exp-str + (setq math-exp-str (concat (substring math-exp-str 0 math-exp-token) "\\dots" (substring math-exp-str (+ math-exp-token 2))))) (math-build-parse-table) @@ -712,7 +712,7 @@ (math-read-token))) ((and (memq ch calc-user-token-chars) (let ((case-fold-search nil)) - (eq (string-match + (eq (string-match calc-user-tokens math-exp-str math-exp-pos) math-exp-pos))) (setq math-exp-token 'punc @@ -722,7 +722,7 @@ (and (>= ch ?A) (<= ch ?Z)) (and (>= ch ?α) (<= ch ?ω)) (and (>= ch ?Α) (<= ch ?Ω))) - (string-match + (string-match (cond ((and (memq calc-language calc-lang-allow-underscores) (memq calc-language calc-lang-allow-percentsigns)) @@ -745,7 +745,7 @@ (eq (string-match "_\\.?[0-9]" math-exp-str math-exp-pos) math-exp-pos) (or (eq math-exp-pos 0) - (and (not (memq calc-language + (and (not (memq calc-language calc-lang-allow-underscores)) (eq (string-match "[^])}\"a-zA-Zα-ωΑ-Ω0-9'$]_" math-exp-str (1- math-exp-pos)) @@ -757,7 +757,7 @@ (setq math-exp-token 'number math-expr-data (math-match-substring math-exp-str 0) math-exp-pos (match-end 0))) - ((and (setq adfn + ((and (setq adfn (assq ch (get calc-language 'math-lang-read-symbol))) (eval (nth 1 adfn))) (eval (nth 2 adfn))) @@ -810,8 +810,8 @@ (defun math-read-expr-level (exp-prec &optional exp-term) (let* ((math-expr-opers (math-expr-ops)) - (x (math-read-factor)) - (first t) + (x (math-read-factor)) + (first t) op op2) (while (and (or (and calc-user-parse-table (setq op (calc-check-user-syntax x exp-prec)) @@ -832,8 +832,8 @@ (memq math-exp-token '(symbol number dollar hash)) (equal math-expr-data "(") (and (equal math-expr-data "[") - (not (equal - (get calc-language + (not (equal + (get calc-language 'math-function-open) "[")) (not (and math-exp-keep-spaces (eq (car-safe x) 'vec))))) @@ -1141,8 +1141,8 @@ (eq math-exp-token 'end))) (throw 'syntax "Expected `)'")) (math-read-token) - (if (and (memq calc-language - calc-lang-parens-are-subscripts) + (if (and (memq calc-language + calc-lang-parens-are-subscripts) args (require 'calc-ext) (let ((calc-matrix-mode 'scalar)) @@ -1184,7 +1184,7 @@ (substring (symbol-name (cdr v)) 4)) (cdr v)))))) - (while (and (memq calc-language + (while (and (memq calc-language calc-lang-brackets-are-subscripts) (equal math-expr-data "[")) (math-read-token) @@ -1284,6 +1284,7 @@ (provide 'calc-aent) ;; Local variables: +;; coding: utf-8 ;; generated-autoload-file: "calc-loaddefs.el" ;; End:
--- a/lisp/calc/calc-ext.el Tue Jun 22 00:22:23 2010 +0000 +++ b/lisp/calc/calc-ext.el Tue Jun 22 22:50:34 2010 +0000 @@ -1,7 +1,7 @@ ;;; calc-ext.el --- various extension functions for Calc -;; Copyright (C) 1990, 1991, 1992, 1993, 2001, 2002, 2003, 2004, -;; 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. +;; Copyright (C) 1990, 1991, 1992, 1993, 2001, 2002, 2003, 2004, 2005, +;; 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. ;; Author: David Gillespie <daveg@synaptics.com> ;; Maintainer: Jay Belanger <jay.p.belanger@gmail.com> @@ -960,7 +960,7 @@ ("calc-yank" calc-alg-edit calc-clean-newlines calc-do-grab-rectangle calc-do-grab-region calc-finish-stack-edit -calc-copy-to-register calc-insert-register +calc-copy-to-register calc-insert-register calc-append-to-register calc-prepend-to-register calc-force-refresh calc-locate-cursor-element calc-show-edit-buffer) @@ -989,7 +989,7 @@ calc-round calc-scale-float calc-sign calc-trunc calc-xpon-part) ("calc-bin" calc-and calc-binary-radix calc-clip calc-twos-complement-mode -calc-decimal-radix calc-diff calc-hex-radix calc-leading-zeros +calc-decimal-radix calc-diff calc-hex-radix calc-leading-zeros calc-lshift-arith calc-lshift-binary calc-not calc-octal-radix calc-or calc-radix calc-rotate-binary calc-rshift-arith calc-rshift-binary calc-word-size calc-xor) @@ -1415,7 +1415,7 @@ (with-current-buffer calc-main-buffer calc-option-flag) calc-option-flag)) - (msg + (msg (cond ((and opt-flag hyp-flag) "Option Inverse Hyperbolic...") (hyp-flag "Inverse Hyperbolic...") @@ -1505,8 +1505,8 @@ (with-current-buffer calc-main-buffer calc-option-flag) calc-option-flag)) - (msg - (cond + (msg + (cond ((and opt-flag inv-flag) "Option Inverse Hyperbolic...") (opt-flag "Option Hyperbolic...") (inv-flag "Inverse Hyperbolic...") @@ -1537,8 +1537,8 @@ (with-current-buffer calc-main-buffer calc-hyperbolic-flag) calc-hyperbolic-flag)) - (msg - (cond + (msg + (cond ((and hyp-flag inv-flag) "Option Inverse Hyperbolic...") (hyp-flag "Option Hyperbolic...") (inv-flag "Option Inverse...") @@ -1702,8 +1702,8 @@ (defun calc-execute-extended-command (n) (interactive "P") (let* ((prompt (concat (calc-num-prefix-name n) "M-x ")) - (cmd (intern - (completing-read prompt obarray 'commandp t "calc-" + (cmd (intern + (completing-read prompt obarray 'commandp t "calc-" 'calc-extended-command-history)))) (setq prefix-arg n) (command-execute cmd))) @@ -3500,5 +3500,9 @@ (provide 'calc-ext) +;; Local variables: +;; coding: utf-8 +;; End: + ;; arch-tag: 1814ba7f-a390-49dc-9e25-a5adc205e97e ;;; calc-ext.el ends here
--- a/lisp/calc/calc-lang.el Tue Jun 22 00:22:23 2010 +0000 +++ b/lisp/calc/calc-lang.el Tue Jun 22 22:50:34 2010 +0000 @@ -1,7 +1,7 @@ ;;; calc-lang.el --- calc language functions -;; Copyright (C) 1990, 1991, 1992, 1993, 2001, 2002, 2003, 2004, -;; 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. +;; Copyright (C) 1990, 1991, 1992, 1993, 2001, 2002, 2003, 2004, 2005, +;; 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. ;; Author: David Gillespie <daveg@synaptics.com> ;; Maintainer: Jay Belanger <jay.p.belanger@gmail.com> @@ -335,7 +335,7 @@ (add-to-list 'calc-lang-allow-underscores 'fortran) (add-to-list 'calc-lang-parens-are-subscripts 'fortran) -;; The next few variables are local to math-read-exprs in calc-aent.el +;; The next few variables are local to math-read-exprs in calc-aent.el ;; and math-read-expr in calc-ext.el, but are set in functions they call. (defvar math-exp-token) @@ -379,12 +379,12 @@ ((= n 1) (message "TeX language mode with \\hbox{func}(\\hbox{var})")) ((> n 1) - (message + (message "TeX language mode with \\hbox{func}(\\hbox{var}) and multiline matrices")) ((= n -1) (message "TeX language mode with \\func(\\hbox{var})")) ((< n -1) - (message + (message "TeX language mode with \\func(\\hbox{var}) and multiline matrices"))))) (defun calc-latex-language (n) @@ -399,12 +399,12 @@ ((= n 1) (message "LaTeX language mode with \\text{func}(\\text{var})")) ((> n 1) - (message + (message "LaTeX language mode with \\text{func}(\\text{var}) and multiline matrices")) ((= n -1) (message "LaTeX language mode with \\func(\\text{var})")) ((< n -1) - (message + (message "LaTeX language mode with \\func(\\text{var}) and multiline matrices"))))) (put 'tex 'math-lang-name "TeX") @@ -498,7 +498,7 @@ (intv . math-compose-tex-intv))) (put 'tex 'math-variable-table - '( + '( ;; The Greek letters ( \\alpha . var-alpha ) ( \\beta . var-beta ) @@ -630,7 +630,7 @@ (defun math-compose-tex-matrix (a &optional ltx) (if (cdr a) - (cons (append (math-compose-vector (cdr (car a)) " & " 0) + (cons (append (math-compose-vector (cdr (car a)) " & " 0) (if ltx '(" \\\\ ") '(" \\cr "))) (math-compose-tex-matrix (cdr a) ltx)) (list (math-compose-vector (cdr (car a)) " & " 0)))) @@ -722,7 +722,7 @@ (setq left "{" right "}")) (t (setq left calc-function-open right calc-function-close))) - (list 'horiz func + (list 'horiz func left (math-compose-vector (cdr a) ", " 0) right))) @@ -866,7 +866,7 @@ (and right (setq math-exp-str (copy-sequence math-exp-str)) (aset math-exp-str right ?\])))))))))) - + (defun math-latex-parse-frac (f val) (let (numer denom) (setq numer (car (math-read-expr-list))) @@ -988,7 +988,7 @@ (cdr (math-transpose a))) '("}"))))) -(put 'eqn 'math-var-formatter +(put 'eqn 'math-var-formatter (function (lambda (a prec) (let (v) @@ -1011,7 +1011,7 @@ (intern (substring (symbol-name (nth 2 a)) 0 -1)))) prec) (symbol-name (nth 1 a)))))))) - + (defconst math-eqn-special-funcs '( calcFunc-log calcFunc-ln calcFunc-exp @@ -1022,7 +1022,7 @@ calcFunc-arcsin calcFunc-arccos calcFunc-arctan calcFunc-arcsinh calcFunc-arccosh calcFunc-arctanh)) -(put 'eqn 'math-func-formatter +(put 'eqn 'math-func-formatter (function (lambda (func a) (let (left right) @@ -1035,8 +1035,8 @@ (not (math-tex-expr-is-flat (nth 1 a)))) (setq left "{left ( " right " right )}")) - - ((and + + ((and (memq (car a) math-eqn-special-funcs) (= (length a) 2) (or (Math-realp (nth 1 a)) @@ -1069,7 +1069,7 @@ ("above" punc ","))) (put 'eqn 'math-lang-adjust-words - (function + (function (lambda () (let ((code (assoc math-expr-data math-eqn-ignore-words))) (cond ((null code)) @@ -1189,21 +1189,21 @@ ( Gamma . var-gamma))) (put 'yacas 'math-parse-table - '((("Deriv(" 0 ")" 0) + '((("Deriv(" 0 ")" 0) calcFunc-deriv (var ArgB var-ArgB) (var ArgA var-ArgA)) - (("D(" 0 ")" 0) + (("D(" 0 ")" 0) calcFunc-deriv (var ArgB var-ArgB) (var ArgA var-ArgA)) - (("Integrate(" 0 ")" 0) + (("Integrate(" 0 ")" 0) calcFunc-integ (var ArgB var-ArgB)(var ArgA var-ArgA)) - (("Integrate(" 0 "," 0 "," 0 ")" 0) - calcFunc-integ (var ArgD var-ArgD) (var ArgA var-ArgA) + (("Integrate(" 0 "," 0 "," 0 ")" 0) + calcFunc-integ (var ArgD var-ArgD) (var ArgA var-ArgA) (var ArgB var-ArgB) (var ArgC var-ArgC)) - (("Subst(" 0 "," 0 ")" 0) - calcFunc-subst (var ArgC var-ArgC) (var ArgA var-ArgA) + (("Subst(" 0 "," 0 ")" 0) + calcFunc-subst (var ArgC var-ArgC) (var ArgA var-ArgA) (var ArgB var-ArgB)) - (("Taylor(" 0 "," 0 "," 0 ")" 0) - calcFunc-taylor (var ArgD var-ArgD) - (calcFunc-eq (var ArgA var-ArgA) (var ArgB var-ArgB)) + (("Taylor(" 0 "," 0 "," 0 ")" 0) + calcFunc-taylor (var ArgD var-ArgD) + (calcFunc-eq (var ArgA var-ArgA) (var ArgB var-ArgB)) (var ArgC var-ArgC)))) (put 'yacas 'math-oper-table @@ -1356,7 +1356,7 @@ (math-compose-expr (nth 2 a) -1) (if (not (nth 3 a)) ")" - (concat + (concat "," (math-compose-expr (nth 3 a) -1) "," @@ -1393,7 +1393,7 @@ '(("+" + 100 100) ("-" - 100 134) ("*" * 120 120) - ("." * 130 129) + ("." * 130 129) ("/" / 120 120) ("u-" neg -1 180) ("u+" ident -1 180) @@ -1494,9 +1494,9 @@ (nth 3 args)))) (put 'maxima 'math-parse-table - '((("if" 0 "then" 0 "else" 0) - calcFunc-if - (var ArgA var-ArgA) + '((("if" 0 "then" 0 "else" 0) + calcFunc-if + (var ArgA var-ArgA) (var ArgB var-ArgB) (var ArgC var-ArgC)))) @@ -1572,7 +1572,7 @@ (lambda (a) (list 'horiz "matrix(" - (math-compose-vector (cdr a) + (math-compose-vector (cdr a) (concat math-comp-comma " ") math-comp-vector-prec) ")")))) @@ -1734,7 +1734,7 @@ (nth 0 args)))) (put 'giac 'math-parse-table - '((("set" 0) + '((("set" 0) calcFunc-rdup (var ArgA var-ArgA)))) @@ -1748,7 +1748,7 @@ "Compose the arguments to a Calc function in reverse order. This is used for various language modes which have functions in reverse order to Calc's." - (list 'horiz (nth 1 fn) + (list 'horiz (nth 1 fn) "(" (math-compose-expr (nth 2 a) 0) "," @@ -1770,7 +1770,7 @@ (list 'horiz (math-compose-expr (nth 1 a) 1000) "[" - (math-compose-expr + (math-compose-expr (calc-normalize (list '- (nth 2 a) 1)) 0) "]"))))) @@ -2001,7 +2001,7 @@ (list 'horiz "matrix(" math-comp-left-bracket - (math-compose-vector (cdr a) + (math-compose-vector (cdr a) (concat math-comp-comma " ") math-comp-vector-prec) math-comp-right-bracket @@ -2044,9 +2044,9 @@ (defvar math-read-big-baseline) (defvar math-read-big-h2) -;; The variables math-rb-h1, math-rb-h2, math-rb-v1 and math-rb-v2 -;; are local to math-read-big-rec, but are used by math-read-big-char, -;; math-read-big-emptyp and math-read-big-balance which are called by +;; The variables math-rb-h1, math-rb-h2, math-rb-v1 and math-rb-v2 +;; are local to math-read-big-rec, but are used by math-read-big-char, +;; math-read-big-emptyp and math-read-big-balance which are called by ;; math-read-big-rec. ;; math-rb-h2 is also local to math-read-big-bigp in calc-ext.el, ;; which calls math-read-big-balance. @@ -2055,40 +2055,40 @@ (defvar math-rb-v1) (defvar math-rb-v2) -(defun math-read-big-rec (math-rb-h1 math-rb-v1 math-rb-h2 math-rb-v2 +(defun math-read-big-rec (math-rb-h1 math-rb-v1 math-rb-h2 math-rb-v2 &optional baseline prec short) (or prec (setq prec 0)) ;; Clip whitespace above or below. - (while (and (< math-rb-v1 math-rb-v2) + (while (and (< math-rb-v1 math-rb-v2) (math-read-big-emptyp math-rb-h1 math-rb-v1 math-rb-h2 (1+ math-rb-v1))) (setq math-rb-v1 (1+ math-rb-v1))) - (while (and (< math-rb-v1 math-rb-v2) + (while (and (< math-rb-v1 math-rb-v2) (math-read-big-emptyp math-rb-h1 (1- math-rb-v2) math-rb-h2 math-rb-v2)) (setq math-rb-v2 (1- math-rb-v2))) ;; If formula is a single line high, normal parser can handle it. (if (<= math-rb-v2 (1+ math-rb-v1)) (if (or (<= math-rb-v2 math-rb-v1) - (> math-rb-h1 (length (setq math-rb-v2 + (> math-rb-h1 (length (setq math-rb-v2 (nth math-rb-v1 math-read-big-lines))))) (math-read-big-error math-rb-h1 math-rb-v1) (setq math-read-big-baseline math-rb-v1 math-read-big-h2 math-rb-h2 math-rb-v2 (nth math-rb-v1 math-read-big-lines) - math-rb-h2 (math-read-expr - (substring math-rb-v2 math-rb-h1 + math-rb-h2 (math-read-expr + (substring math-rb-v2 math-rb-h1 (min math-rb-h2 (length math-rb-v2))))) (if (eq (car-safe math-rb-h2) 'error) - (math-read-big-error (+ math-rb-h1 (nth 1 math-rb-h2)) + (math-read-big-error (+ math-rb-h1 (nth 1 math-rb-h2)) math-rb-v1 (nth 2 math-rb-h2)) math-rb-h2)) ;; Clip whitespace at left or right. - (while (and (< math-rb-h1 math-rb-h2) + (while (and (< math-rb-h1 math-rb-h2) (math-read-big-emptyp math-rb-h1 math-rb-v1 (1+ math-rb-h1) math-rb-v2)) (setq math-rb-h1 (1+ math-rb-h1))) - (while (and (< math-rb-h1 math-rb-h2) + (while (and (< math-rb-h1 math-rb-h2) (math-read-big-emptyp (1- math-rb-h2) math-rb-v1 math-rb-h2 math-rb-v2)) (setq math-rb-h2 (1- math-rb-h2))) @@ -2107,7 +2107,7 @@ (/= (aref line math-rb-h1) ?\ ) (if (and (= (aref line math-rb-h1) ?\-) ;; Make sure it's not a minus sign. - (or (and (< (1+ math-rb-h1) len) + (or (and (< (1+ math-rb-h1) len) (= (aref line (1+ math-rb-h1)) ?\-)) (/= (math-read-big-char math-rb-h1 (1- v)) ?\ ) (/= (math-read-big-char math-rb-h1 (1+ v)) ?\ ))) @@ -2166,7 +2166,7 @@ ;; Binomial coefficient. ((and (= other-char ?\() (= (math-read-big-char (1+ math-rb-h1) v) ?\ ) - (= (string-match "( *)" (nth v math-read-big-lines) + (= (string-match "( *)" (nth v math-read-big-lines) math-rb-h1) math-rb-h1)) (setq h (match-end 0)) (math-read-big-emptyp math-rb-h1 math-rb-v1 (1+ math-rb-h1) v nil t) @@ -2180,7 +2180,7 @@ ;; Minus sign. ((= other-char ?\-) - (setq p (list 'neg (math-read-big-rec (1+ math-rb-h1) math-rb-v1 + (setq p (list 'neg (math-read-big-rec (1+ math-rb-h1) math-rb-v1 math-rb-h2 math-rb-v2 v 250 t)) v math-read-big-baseline h math-read-big-h2)) @@ -2199,10 +2199,10 @@ (if (= sep ?\]) (math-read-big-error (1- h) v "Expected `)'")) (if (= sep ?\)) - (setq p (math-read-big-rec + (setq p (math-read-big-rec (1+ math-rb-h1) math-rb-v1 (1- h) math-rb-v2 v)) (setq hmid (math-read-big-balance h v "(") - p (list p + p (list p (math-read-big-rec h math-rb-v1 (1- hmid) math-rb-v2 v)) h hmid) (cond ((= sep ?\.) @@ -2347,7 +2347,7 @@ (math-read-big-emptyp math-rb-h1 math-rb-v1 h v nil t) (math-read-big-emptyp math-rb-h1 (1+ v) h math-rb-v2 nil t))) - ;; Now left term is bounded by math-rb-h1, math-rb-v1, h, math-rb-v2; + ;; Now left term is bounded by math-rb-h1, math-rb-v1, h, math-rb-v2; ;; baseline = v. (if baseline (or (= v baseline) @@ -2389,12 +2389,12 @@ (cond ((eq (nth 3 widest) -1) (setq p (list (nth 1 widest) p))) ((equal (car widest) "?") - (let ((y (math-read-big-rec h math-rb-v1 math-rb-h2 + (let ((y (math-read-big-rec h math-rb-v1 math-rb-h2 math-rb-v2 baseline nil t))) (or (= (math-read-big-char math-read-big-h2 baseline) ?\:) (math-read-big-error math-read-big-h2 baseline "Expected `:'")) (setq p (list (nth 1 widest) p y - (math-read-big-rec + (math-read-big-rec (1+ math-read-big-h2) math-rb-v1 math-rb-h2 math-rb-v2 baseline (nth 3 widest) t)) h math-read-big-h2))) @@ -2483,5 +2483,9 @@ (provide 'calc-lang) +;; Local variables: +;; coding: utf-8 +;; End: + ;; arch-tag: 483bfe15-f290-4fef-bb7d-ce65be687f2e ;;; calc-lang.el ends here
--- a/lisp/calc/calc-store.el Tue Jun 22 00:22:23 2010 +0000 +++ b/lisp/calc/calc-store.el Tue Jun 22 22:50:34 2010 +0000 @@ -1,7 +1,7 @@ ;;; calc-store.el --- value storage functions for Calc -;; Copyright (C) 1990, 1991, 1992, 1993, 2001, 2002, 2003, 2004, -;; 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. +;; Copyright (C) 1990, 1991, 1992, 1993, 2001, 2002, 2003, 2004, 2005, +;; 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. ;; Author: David Gillespie <daveg@synaptics.com> ;; Maintainer: Jay Belanger <jay.p.belanger@gmail.com> @@ -197,8 +197,8 @@ (minibuffer-completion-predicate (lambda (x) (boundp (intern (concat "var-" x))))) (minibuffer-completion-confirm t)) - (read-from-minibuffer - prompt nil calc-var-name-map nil + (read-from-minibuffer + prompt nil calc-var-name-map nil 'calc-read-var-name-history))))) (setq calc-aborted-prefix "") (and (not (equal var "var-")) @@ -677,5 +677,9 @@ (provide 'calc-store) +;; Local variables: +;; coding: utf-8 +;; End: + ;; arch-tag: 2fbfec82-a521-42ca-bcd8-4f254ae6313e ;;; calc-store.el ends here
--- a/lisp/calc/calc-units.el Tue Jun 22 00:22:23 2010 +0000 +++ b/lisp/calc/calc-units.el Tue Jun 22 22:50:34 2010 +0000 @@ -1,7 +1,7 @@ ;;; calc-units.el --- unit conversion functions for Calc -;; Copyright (C) 1990, 1991, 1992, 1993, 2001, 2002, 2003, 2004, -;; 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. +;; Copyright (C) 1990, 1991, 1992, 1993, 2001, 2002, 2003, 2004, 2005, +;; 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. ;; Author: David Gillespie <daveg@synaptics.com> ;; Maintainer: Jay Belanger <jay.p.belanger@gmail.com> @@ -323,7 +323,7 @@ ( ?c (^ 10 -2) "Centi" ) ( ?m (^ 10 -3) "Milli" ) ( ?u (^ 10 -6) "Micro" ) - ( ?μ (^ 10 -6) "Micro" ) + ( ?μ (^ 10 -6) "Micro" ) ( ?n (^ 10 -9) "Nano" ) ( ?p (^ 10 -12) "Pico" ) ( ?f (^ 10 -15) "Femto" ) @@ -1548,5 +1548,9 @@ (provide 'calc-units) +;; Local variables: +;; coding: utf-8 +;; End: + ;; arch-tag: e993314f-3adc-4191-be61-4ef8874881c4 ;;; calc-units.el ends here
--- a/lisp/calc/calc.el Tue Jun 22 00:22:23 2010 +0000 +++ b/lisp/calc/calc.el Tue Jun 22 22:50:34 2010 +0000 @@ -419,7 +419,7 @@ :group 'calc :type 'boolean) -(defcustom calc-undo-length +(defcustom calc-undo-length 100 "The number of undo steps that will be preserved when Calc is quit." :group 'calc @@ -1233,7 +1233,7 @@ ;; Eventually, prompt user with a list of buffers using embedded mode. (when (and info-list - (yes-or-no-p + (yes-or-no-p (concat "This Calc stack is being used for embedded mode. Kill anyway?"))) (while info-list (with-current-buffer (car (car info-list)) @@ -3409,7 +3409,7 @@ (Math-lessp a math-half-2-word-size)) (and (Math-integer-negp a) (require 'calc-ext) - (let ((comparison + (let ((comparison (math-compare (Math-integer-neg a) math-half-2-word-size))) (or (= comparison 0) (= comparison -1)))))) @@ -3553,7 +3553,7 @@ (math-normalize (save-match-data (cond - + ;; Integers (most common case) ((string-match "\\` *\\([0-9]+\\) *\\'" s) (let ((digs (math-match-substring s 1))) @@ -3565,22 +3565,22 @@ (if (<= (length digs) (* 2 math-bignum-digit-length)) (string-to-number digs) (cons 'bigpos (math-read-bignum digs)))))) - + ;; Clean up the string if necessary ((string-match "\\`\\(.*\\)[ \t\n]+\\([^\001]*\\)\\'" s) (math-read-number (concat (math-match-substring s 1) (math-match-substring s 2)))) - + ;; Plus and minus signs ((string-match "^[-_+]\\(.*\\)$" s) (let ((val (math-read-number (math-match-substring s 1)))) (and val (if (eq (aref s 0) ?+) val (math-neg val))))) - + ;; Forms that require extensions module ((string-match "[^-+0-9eE.]" s) (require 'calc-ext) (math-read-number-fancy s)) - + ;; Decimal point ((string-match "^\\([0-9]*\\)\\.\\([0-9]*\\)$" s) (let ((int (math-match-substring s 1)) @@ -3593,7 +3593,7 @@ (list 'float (math-add (math-scale-int int flen) frac) (- flen))))))) - + ;; "e" notation ((string-match "^\\(.*\\)[eE]\\([-+]?[0-9]+\\)$" s) (let ((mant (math-match-substring s 1)) @@ -3604,7 +3604,7 @@ (and mant exp (Math-realp mant) (> exp -4000000) (< exp 4000000) (let ((mant (math-float mant))) (list 'float (nth 1 mant) (+ (nth 2 mant) exp))))))) - + ;; Syntax error! (t nil))))) @@ -3797,7 +3797,7 @@ (setq unread-command-event nil) (setq unread-command-events nil))) -(defcalcmodevar math-2-word-size +(defcalcmodevar math-2-word-size (math-read-number-simple "4294967296") "Two to the power of `calc-word-size'.") @@ -3814,5 +3814,9 @@ (provide 'calc) +;; Local variables: +;; coding: utf-8 +;; End: + ;; arch-tag: 0c3b170c-4ce6-4eaf-8d9b-5834d1fe938f ;;; calc.el ends here
--- a/lisp/calc/calccomp.el Tue Jun 22 00:22:23 2010 +0000 +++ b/lisp/calc/calccomp.el Tue Jun 22 22:50:34 2010 +0000 @@ -1,7 +1,7 @@ ;;; calccomp.el --- composition functions for Calc -;; Copyright (C) 1990, 1991, 1992, 1993, 2001, 2002, 2003, 2004, -;; 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. +;; Copyright (C) 1990, 1991, 1992, 1993, 2001, 2002, 2003, 2004, 2005, +;; 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. ;; Author: David Gillespie <daveg@synaptics.com> ;; Maintainer: Jay Belanger <jay.p.belanger@gmail.com> @@ -50,19 +50,19 @@ ;;; ;;; (tag X C) Composition C corresponds to sub-expression X -;; math-comp-just and math-comp-comma-spc are local to -;; math-compose-expr, but are used by math-compose-matrix, which is +;; math-comp-just and math-comp-comma-spc are local to +;; math-compose-expr, but are used by math-compose-matrix, which is ;; called by math-compose-expr (defvar math-comp-just) (defvar math-comp-comma-spc) -;; math-comp-vector-prec is local to math-compose-expr, but is used by -;; math-compose-matrix and math-compose-rows, which are called by +;; math-comp-vector-prec is local to math-compose-expr, but is used by +;; math-compose-matrix and math-compose-rows, which are called by ;; math-compose-expr. (defvar math-comp-vector-prec) -;; math-comp-left-bracket, math-comp-right-bracket and math-comp-comma are -;; local to math-compose-expr, but are used by math-compose-rows, which is +;; math-comp-left-bracket, math-comp-right-bracket and math-comp-comma are +;; local to math-compose-expr, but are used by math-compose-rows, which is ;; called by math-compose-expr. (defvar math-comp-left-bracket) (defvar math-comp-right-bracket) @@ -100,7 +100,7 @@ (list 'tag a (math-compose-expr a prec)))) ((and (not (consp a)) (not (integerp a))) (concat "'" (prin1-to-string a))) - ((setq spfn (assq (car-safe a) + ((setq spfn (assq (car-safe a) (get calc-language 'math-special-function-table))) (setq spfn (cdr spfn)) (if (consp spfn) @@ -111,12 +111,12 @@ (and (nth 1 calc-frac-format) (Math-integerp a))) (if (and calc-language - (not (memq calc-language + (not (memq calc-language '(flat big unform)))) (let ((aa (math-adjust-fraction a)) (calc-frac-format nil)) (math-compose-expr (list '/ - (if (memq calc-language + (if (memq calc-language calc-lang-slash-idiv) (math-float (nth 1 aa)) (nth 1 aa)) @@ -281,22 +281,22 @@ (cdr a) (if full rows 3) t))))) (if (or calc-full-vectors (< (length a) 7)) - (if (and + (if (and (setq spfn (get calc-language 'math-matrix-formatter)) (math-matrixp a)) (funcall spfn a) (list 'horiz math-comp-left-bracket - (math-compose-vector (cdr a) + (math-compose-vector (cdr a) (concat math-comp-comma " ") math-comp-vector-prec) math-comp-right-bracket)) (list 'horiz math-comp-left-bracket (math-compose-vector (list (nth 1 a) (nth 2 a) (nth 3 a)) - (concat math-comp-comma " ") + (concat math-comp-comma " ") math-comp-vector-prec) - math-comp-comma + math-comp-comma (if (setq spfn (get calc-language 'math-dots)) (concat " " spfn) " ...") @@ -869,7 +869,7 @@ math-comp-vector-prec) (if (= col cols) "" - (concat + (concat math-comp-comma-spc " "))))) a))) res))) @@ -880,7 +880,7 @@ (if (<= count 0) (if (< count 0) (math-compose-rows (cdr a) -1 nil) - (cons (concat + (cons (concat (let ((mdots (get calc-language 'math-dots))) (if mdots (concat " " mdots) @@ -1119,7 +1119,7 @@ (if (memq prec '(196 201)) ")" ""))))) ;; The variables math-svo-c, math-svo-wid and math-svo-off are local -;; to math-stack-value-offset in calc.el, but are used by +;; to math-stack-value-offset in calc.el, but are used by ;; math-stack-value-offset-fancy, which is called by math-stack-value-offset.. (defvar math-svo-c) (defvar math-svo-wid) @@ -1195,11 +1195,11 @@ ;;; of the formula. ;; The variables math-comp-full-width, math-comp-highlight, math-comp-word, -;; math-comp-level, math-comp-margin and math-comp-buf are local to -;; math-comp-to-string-flat, but are used by math-comp-to-string-flat-term, +;; math-comp-level, math-comp-margin and math-comp-buf are local to +;; math-comp-to-string-flat, but are used by math-comp-to-string-flat-term, ;; which is called by math-comp-to-string-flat. -;; math-comp-highlight and math-comp-buf are also local to -;; math-comp-simplify-term and math-comp-simplify respectively, but are used +;; math-comp-highlight and math-comp-buf are also local to +;; math-comp-simplify-term and math-comp-simplify respectively, but are used ;; by math-comp-add-string. (defvar math-comp-full-width) (defvar math-comp-highlight) @@ -1244,7 +1244,7 @@ (cond ((not (consp c)) (if math-comp-highlight (setq c (math-comp-highlight-string c))) - (setq math-comp-word (if (= (length math-comp-word) 0) c + (setq math-comp-word (if (= (length math-comp-word) 0) c (concat math-comp-word c)) math-comp-pos (+ math-comp-pos (length c)))) @@ -1347,8 +1347,8 @@ ;; The variable math-comp-sel-tag is local to calc-find-selected-part -;; in calc-sel.el, but is used by math-comp-sel-flat-term and -;; math-comp-add-string-sel, which are called (indirectly) by +;; in calc-sel.el, but is used by math-comp-sel-flat-term and +;; math-comp-add-string-sel, which are called (indirectly) by ;; calc-find-selected-part. (defvar math-comp-sel-tag) @@ -1668,5 +1668,9 @@ (provide 'calccomp) +;; Local variables: +;; coding: utf-8 +;; End: + ;; arch-tag: 7c45d10a-a286-4dab-af49-7ae8989fbf78 ;;; calccomp.el ends here
--- a/lisp/gnus/ChangeLog Tue Jun 22 00:22:23 2010 +0000 +++ b/lisp/gnus/ChangeLog Tue Jun 22 22:50:34 2010 +0000 @@ -1,3 +1,8 @@ +2010-06-22 Mark A. Hershberger <mah@everybody.org> + + * mm-url.el (mm-url-encode-multipart-form-data): New function to handle + the *other* type of HTML form submission. + 2010-06-15 Michael Albinus <michael.albinus@gmx.de> * auth-source.el (auth-source-pick): If choice does not contain a
--- a/lisp/gnus/mm-url.el Tue Jun 22 00:22:23 2010 +0000 +++ b/lisp/gnus/mm-url.el Tue Jun 22 22:50:34 2010 +0000 @@ -418,6 +418,48 @@ (mm-url-form-encode-xwfu (cdr data)))) pairs "&")) +(defun mm-url-encode-multipart-form-data (pairs &optional boundary) + "Return PAIRS encoded in multipart/form-data." + ;; RFC1867 + + ;; Get a good boundary + (unless boundary + (setq boundary (mml-compute-boundary '()))) + + (concat + + ;; Start with the boundary + "--" boundary "\r\n" + + ;; Create name value pairs + (mapconcat + 'identity + ;; Delete any returned items that are empty + (delq nil + (mapcar (lambda (data) + (when (car data) + ;; For each pair + (concat + + ;; Encode the name + "Content-Disposition: form-data; name=\"" + (car data) "\"\r\n" + "Content-Type: text/plain; charset=utf-8\r\n" + "Content-Transfer-Encoding: binary\r\n\r\n" + + (cond ((stringp (cdr data)) + (cdr data)) + ((integerp (cdr data)) + (int-to-string (cdr data)))) + + "\r\n"))) + pairs)) + ;; use the boundary as a separator + (concat "--" boundary "\r\n")) + + ;; put a boundary at the end. + "--" boundary "--\r\n")) + (defun mm-url-fetch-form (url pairs) "Fetch a form from URL with PAIRS as the data using the POST method." (mm-url-load-url)
--- a/lisp/org/ChangeLog Tue Jun 22 00:22:23 2010 +0000 +++ b/lisp/org/ChangeLog Tue Jun 22 22:50:34 2010 +0000 @@ -1,3 +1,8 @@ +2010-06-22 Glenn Morris <rgm@gnu.org> + + * org-entities.el: Add explicit utf-8 coding cookie to file with + utf-8 characters. + 2010-05-26 Stefan Monnier <monnier@iro.umontreal.ca> * org.el (org-file-complete-link): Avoid (expand-file-name ".").
--- a/lisp/org/org-entities.el Tue Jun 22 00:22:23 2010 +0000 +++ b/lisp/org/org-entities.el Tue Jun 22 22:50:34 2010 +0000 @@ -488,6 +488,9 @@ (provide 'org-entities) -;; arch-tag: e6bd163f-7419-4009-9c93-a74623016424 +;; Local variables: +;; coding: utf-8 +;; End: +;; arch-tag: e6bd163f-7419-4009-9c93-a74623016424 ;;; org-entities.el ends here
--- a/lisp/textmodes/texinfmt.el Tue Jun 22 00:22:23 2010 +0000 +++ b/lisp/textmodes/texinfmt.el Tue Jun 22 22:50:34 2010 +0000 @@ -1,8 +1,8 @@ ;;; texinfmt.el --- format Texinfo files into Info files -;; Copyright (C) 1985, 1986, 1988, 1990, 1991, 1992, 1993, -;; 1994, 1995, 1996, 1997, 1998, 2000, 2001, 2002, 2003, -;; 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. +;; Copyright (C) 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995, +;; 1996, 1997, 1998, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, +;; 2008, 2009, 2010 Free Software Foundation, Inc. ;; Maintainer: Robert J. Chassell <bug-texinfo@gnu.org> ;; Keywords: maint, tex, docs @@ -224,7 +224,7 @@ (save-restriction (widen) (goto-char (point-min)) - (let ((search-end (save-excursion (forward-line 100) (point)))) + (let ((search-end (line-beginning-position 101))) (if (or ;; Either copy header text. (and @@ -285,7 +285,7 @@ (let ((filename (concat input-directory (texinfo-parse-line-arg)))) (re-search-backward "^@include") - (delete-region (point) (save-excursion (forward-line 1) (point))) + (delete-region (point) (line-beginning-position 2)) (message "Reading included file: %s" filename) (save-excursion (save-restriction @@ -323,8 +323,7 @@ ;; Insert Info region title text. (goto-char (point-min)) - (if (search-forward - "@setfilename" (save-excursion (forward-line 100) (point)) t) + (if (search-forward "@setfilename" (line-beginning-position 101) t) (progn (setq texinfo-command-end (point)) (beginning-of-line) @@ -772,13 +771,13 @@ ((eq type '@raisesections) (setq level (1+ level)) (delete-region - (point) (save-excursion (forward-line 1) (point)))) + (point) (line-beginning-position 2))) ;; 2. Decrement level ((eq type '@lowersections) (setq level (1- level)) (delete-region - (point) (save-excursion (forward-line 1) (point)))) + (point) (line-beginning-position 2))) ;; Now handle structuring commands ((cond @@ -1505,9 +1504,7 @@ (progn (goto-char node-name-beginning) ; skip over node command (skip-chars-forward " \t") ; and over spaces (point)) - (if (search-forward - "," - (save-excursion (end-of-line) (point)) t) ; bound search + (if (search-forward "," (line-end-position) t) ; bound search (1- (point)) (end-of-line) (point)))))) (texinfo-discard-command) ; remove or insert whitespace, as needed @@ -1692,7 +1689,7 @@ (put 'itemize 'texinfo-item 'texinfo-itemize-item) (defun texinfo-itemize-item () ;; (texinfo-discard-line) ; Did not handle text on same line as @item. - (delete-region (1+ (point)) (save-excursion (beginning-of-line) (point))) + (delete-region (1+ (point)) (line-beginning-position)) (if (looking-at "[ \t]*[^ \t\n]+") ;; Text on same line as @item command. (insert "\b " (nth 1 (car texinfo-stack)) " \n") @@ -2132,10 +2129,10 @@ (narrow-to-region start end) ;; Remove whitespace before and after entry. (skip-chars-forward " ") - (delete-region (point) (save-excursion (beginning-of-line) (point))) + (delete-region (point) (line-beginning-position)) (goto-char (point-max)) (skip-chars-backward " ") - (delete-region (point) (save-excursion (end-of-line) (point))) + (delete-region (point) (line-end-position)) ;; Temporarily set texinfo-stack to nil so texinfo-format-scan ;; does not see an unterminated @multitable. (let (texinfo-stack) ; nil @@ -2409,16 +2406,14 @@ (let ((start (1- (point))) args) (skip-chars-forward " ") - (save-excursion (end-of-line) (setq texinfo-command-end (point))) + (setq texinfo-command-end (line-end-position)) (if (not (looking-at "\\([^=]+\\)=\\(.*\\)")) (error "Invalid alias command") (push (cons (match-string-no-properties 1) (match-string-no-properties 2)) texinfo-alias-list) - (texinfo-discard-command)) - ) - ) + (texinfo-discard-command)))) ;;; @var, @code and the like @@ -2455,7 +2450,7 @@ "Insert ` ... ' around arg unless inside a table; in that case, no quotes." ;; `looking-at-backward' not available in v. 18.57, 20.2 (if (not (search-backward "" ; searched-for character is a control-H - (save-excursion (beginning-of-line) (point)) + (line-beginning-position) t)) (insert "`" (texinfo-parse-arg-discard) "'") (insert (texinfo-parse-arg-discard))) @@ -2840,8 +2835,7 @@ (defun texinfo-noindent () (save-excursion (forward-paragraph 1) - (if (search-backward "@refill" - (save-excursion (forward-line -1) (point)) t) + (if (search-backward "@refill" (line-beginning-position 0) t) () ; leave @noindent command so @refill command knows not to indent ;; else (texinfo-discard-line))))
--- a/lisp/url/ChangeLog Tue Jun 22 00:22:23 2010 +0000 +++ b/lisp/url/ChangeLog Tue Jun 22 22:50:34 2010 +0000 @@ -1,3 +1,9 @@ +2010-06-22 Mark A. Hershberger <mah@everybody.org> + + * url-parse.el (url-user-for-url, url-password-for-url): + Convenience functions that get usernames and passwords for urls + from auth-source functions. + 2010-06-12 Štěpán Němec <stepnem@gmail.com> (tiny change) * url-vars.el (url-privacy-level): Fix doc typo. (Bug#6406)
--- a/lisp/url/url-parse.el Tue Jun 22 00:22:23 2010 +0000 +++ b/lisp/url/url-parse.el Tue Jun 22 22:50:34 2010 +0000 @@ -25,6 +25,7 @@ ;;; Code: (require 'url-vars) +(require 'auth-source) (eval-when-compile (require 'cl)) (autoload 'url-scheme-get-property "url-methods") @@ -174,6 +175,25 @@ (url-parse-make-urlobj prot user pass host port file refs attr full))))))) +(defmacro url-bit-for-url (method lookfor url) + `(let* ((urlobj (url-generic-parse-url url)) + (bit (funcall ,method urlobj)) + (methods (list 'url-recreate-url + 'url-host))) + (while (and (not bit) (> (length methods) 0)) + (setq bit + (auth-source-user-or-password + ,lookfor (funcall (pop methods) urlobj) (url-type urlobj)))) + bit)) + +(defun url-user-for-url (url) + "Attempt to use .authinfo to find a user for this URL." + (url-bit-for-url 'url-user "login" url)) + +(defun url-password-for-url (url) + "Attempt to use .authinfo to find a password for this URL." + (url-bit-for-url 'url-password "password" url)) + (provide 'url-parse) ;; arch-tag: f338325f-71ab-4bee-93cc-78fb9a03d403
--- a/src/ChangeLog Tue Jun 22 00:22:23 2010 +0000 +++ b/src/ChangeLog Tue Jun 22 22:50:34 2010 +0000 @@ -1,3 +1,20 @@ +2010-06-22 Jan Djärv <jan.h.d@swipnet.se> + + * xterm.c (x_scroll_bar_create): Remove call to xg_show_scroll_bar. + + * gtkutil.h (xg_show_scroll_bar): : Remove. + + * gtkutil.c (xg_update_scrollbar_pos): Show/hide scroll bar as needed + if height is less than scroll bar min size. + (xg_show_scroll_bar): Remove, show moved to xg_update_scrollbar_pos. + + * xfns.c (x_default_font_parameter): Try to open font from system + before using it (bug#6478). Rename got_from_gconf to got_from_system. + +2010-06-22 Keith Packard <keithp@keithp.com> (tiny change) + + * font.c (font_parse_fcname): Allow . for sizes like 7.5 (bug#6437). + 2010-06-20 Eli Zaretskii <eliz@gnu.org> * xdisp.c (try_scrolling): When scroll-conservatively is set to
--- a/src/font.c Tue Jun 22 00:22:23 2010 +0000 +++ b/src/font.c Tue Jun 22 22:50:34 2010 +0000 @@ -1544,7 +1544,7 @@ int size_found = 1; for (q = p + 1; *q && *q != ' '; q++) - if (! isdigit (*q)) + if (! isdigit (*q) && *q != '.') { size_found = 0; break;
--- a/src/gtkutil.c Tue Jun 22 00:22:23 2010 +0000 +++ b/src/gtkutil.c Tue Jun 22 22:50:34 2010 +0000 @@ -3174,17 +3174,6 @@ bar->x_window = scroll_id; } -/* Make the scroll bar represented by SCROLLBAR_ID visible. */ - -void -xg_show_scroll_bar (scrollbar_id) - int scrollbar_id; -{ - GtkWidget *w = xg_get_widget_from_map (scrollbar_id); - if (w) - gtk_widget_show_all (gtk_widget_get_parent (w)); -} - /* Remove the scroll bar represented by SCROLLBAR_ID from the frame F. */ void @@ -3243,10 +3232,23 @@ /* Move and resize to new values. */ gtk_fixed_move (GTK_FIXED (wfixed), wparent, left, top); - gtk_widget_set_size_request (wscroll, width, height); + gint msl; + gtk_widget_style_get (wscroll, "min-slider-length", &msl, NULL); + if (msl > height) + { + /* No room. Hide scroll bar as some themes output a warning if + the height is less than the min size. */ + gtk_widget_hide (wparent); + gtk_widget_hide (wscroll); + } + else + { + gtk_widget_show_all (wparent); + gtk_widget_set_size_request (wscroll, width, height); + } gtk_widget_queue_draw (wfixed); gdk_window_process_all_updates (); - if (oldx != -1) + if (oldx != -1 && oldw > 0 && oldh > 0) { /* Clear under old scroll bar position. This must be done after the gtk_widget_queue_draw and gdk_window_process_all_updates
--- a/src/gtkutil.h Tue Jun 22 00:22:23 2010 +0000 +++ b/src/gtkutil.h Tue Jun 22 22:50:34 2010 +0000 @@ -163,7 +163,6 @@ GCallback scroll_callback, GCallback end_callback, char *scroll_bar_name)); -extern void xg_show_scroll_bar P_ ((int scrollbar_id)); extern void xg_remove_scroll_bar P_ ((FRAME_PTR f, int scrollbar_id)); extern void xg_update_scrollbar_pos P_ ((FRAME_PTR f,
--- a/src/xfns.c Tue Jun 22 00:22:23 2010 +0000 +++ b/src/xfns.c Tue Jun 22 22:50:34 2010 +0000 @@ -3064,8 +3064,8 @@ struct x_display_info *dpyinfo = FRAME_X_DISPLAY_INFO (f); Lisp_Object font_param = x_get_arg (dpyinfo, parms, Qfont, NULL, NULL, RES_TYPE_STRING); - Lisp_Object font; - int got_from_gconf = 0; + Lisp_Object font = Qnil; + int got_from_system = 0; if (EQ (font_param, Qunbound)) font_param = Qnil; @@ -3075,14 +3075,20 @@ regardless of font-use-system-font because .emacs may not have been read yet. */ const char *system_font = xsettings_get_system_font (); - if (system_font) font_param = make_string (system_font, - strlen (system_font)); + if (system_font) + { + char *name = xstrdup (system_font); + font = font_open_by_name (f, name); + got_from_system = ! NILP (font); + free (name); + } } - - font = !NILP (font_param) ? font_param - : x_get_arg (dpyinfo, parms, Qfont, "font", "Font", RES_TYPE_STRING); - - if (! STRINGP (font)) + + if (NILP (font)) + font = !NILP (font_param) ? font_param + : x_get_arg (dpyinfo, parms, Qfont, "font", "Font", RES_TYPE_STRING); + + if (! FONTP (font) && ! STRINGP (font)) { char *names[] = { @@ -3120,8 +3126,8 @@ } x_default_parameter (f, parms, Qfont, font, - got_from_gconf ? NULL : "font", - got_from_gconf ? NULL : "Font", + got_from_system ? NULL : "font", + got_from_system ? NULL : "Font", RES_TYPE_STRING); }
--- a/src/xterm.c Tue Jun 22 00:22:23 2010 +0000 +++ b/src/xterm.c Tue Jun 22 22:50:34 2010 +0000 @@ -4998,7 +4998,6 @@ left + VERTICAL_SCROLL_BAR_WIDTH_TRIM, width - VERTICAL_SCROLL_BAR_WIDTH_TRIM * 2, max (height, 1)); - xg_show_scroll_bar (bar->x_window); #else /* not USE_GTK */ Widget scroll_bar = SCROLL_BAR_X_WIDGET (FRAME_X_DISPLAY (f), bar); XtConfigureWidget (scroll_bar,