summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
Diffstat (limited to 'lisp')
-rw-r--r--lisp/ChangeLog19
-rw-r--r--lisp/emacs-lisp/syntax.el2
-rw-r--r--lisp/image.el48
-rw-r--r--lisp/progmodes/f90.el12
-rw-r--r--lisp/progmodes/fortran.el1
5 files changed, 46 insertions, 36 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 08a3e4b3f3e..c14655699e7 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,22 @@
+2011-06-12 Glenn Morris <rgm@gnu.org>
+
+ * progmodes/fortran.el (fortran-mode-syntax-table):
+ * progmodes/f90.el (f90-mode-syntax-table):
+ Set % to punctuation. (Bug#8820)
+ (f90-find-tag-default): Remove, no longer needed.
+
+2011-06-12 Daniel Colascione <dan.colascione@gmail.com>
+
+ * emacs-lisp/syntax.el (syntax-ppss): Clarify which items are invalid.
+
+2011-06-11 Chong Yidong <cyd@stupidchicken.com>
+
+ * image.el (image-animated-p): Return animation delay in seconds.
+ Avoid bit manipulation in Lisp; use `delay' entry in the metadata.
+ (image-animate-timeout): Remove DELAY argument. Don't assume
+ every subimage has the same delay; get it from image-animated-p.
+ (image-animate): Caller changed.
+
2011-06-11 Michael Albinus <michael.albinus@gmx.de>
* net/tramp.el (tramp-debug-message): Add `tramp-with-progress-reporter'
diff --git a/lisp/emacs-lisp/syntax.el b/lisp/emacs-lisp/syntax.el
index c012e48b590..7ba7b13af44 100644
--- a/lisp/emacs-lisp/syntax.el
+++ b/lisp/emacs-lisp/syntax.el
@@ -399,7 +399,7 @@ point (where the PPSS is equivalent to nil).")
(defun syntax-ppss (&optional pos)
"Parse-Partial-Sexp State at POS, defaulting to point.
The returned value is the same as `parse-partial-sexp' except that
-the 2nd and 6th values of the returned state cannot be relied upon.
+values 2 and 6 values of the returned state cannot be relied upon.
Point is at POS when this function returns."
;; Default values.
(unless pos (setq pos (point)))
diff --git a/lisp/image.el b/lisp/image.el
index e076c2d09f1..91c0f3c9292 100644
--- a/lisp/image.el
+++ b/lisp/image.el
@@ -597,20 +597,16 @@ Example:
"Return non-nil if image can be animated.
Actually, the return value is a cons (NIMAGES . DELAY), where
NIMAGES is the number of sub-images in the animated image and
-DELAY is the delay in 100ths of a second until the next sub-image
-shall be displayed."
+DELAY is the delay in second until the next sub-image shall be
+displayed."
(cond
((eq (plist-get (cdr image) :type) 'gif)
(let* ((metadata (image-metadata image))
(images (plist-get metadata 'count))
- (extdata (plist-get metadata 'extension-data))
- (anim (plist-get extdata #xF9))
- (tmo (and (integerp images) (> images 1)
- (stringp anim) (>= (length anim) 4)
- (+ (aref anim 1) (* (aref anim 2) 256)))))
- (when tmo
- (if (eq tmo 0) (setq tmo 10))
- (cons images tmo))))))
+ (delay (plist-get metadata 'delay)))
+ (when (and images (> images 1) (numberp delay))
+ (if (< delay 0) (setq delay 0.1))
+ (cons images delay))))))
(defun image-animate (image &optional index limit)
"Start animating IMAGE.
@@ -620,15 +616,14 @@ With optional INDEX, begin animating from that animation frame.
LIMIT specifies how long to animate the image. If omitted or
nil, play the animation until the end. If t, loop forever. If a
number, play until that number of seconds has elapsed."
- (let ((anim (image-animated-p image))
- delay timer)
- (when anim
+ (let ((animation (image-animated-p image))
+ timer)
+ (when animation
(if (setq timer (image-animate-timer image))
(cancel-timer timer))
- (setq delay (max (* (cdr anim) 0.01) 0.025))
- (run-with-timer 0.2 nil #'image-animate-timeout
- image (or index 0) (car anim)
- delay 0 limit))))
+ (run-with-timer 0.2 nil 'image-animate-timeout
+ image (or index 0) (car animation)
+ 0 limit))))
(defun image-animate-timer (image)
"Return the animation timer for image IMAGE."
@@ -643,7 +638,7 @@ number, play until that number of seconds has elapsed."
(setq timer nil)))
timer))
-(defun image-animate-timeout (image n count delay time-elapsed limit)
+(defun image-animate-timeout (image n count time-elapsed limit)
"Display animation frame N of IMAGE.
N=0 refers to the initial animation frame.
COUNT is the total number of frames in the animation.
@@ -653,10 +648,16 @@ TIME-ELAPSED is the total time that has elapsed since
LIMIT determines when to stop. If t, loop forever. If nil, stop
after displaying the last animation frame. Otherwise, stop
after LIMIT seconds have elapsed."
- (let (done)
- (plist-put (cdr image) :index n)
- (force-window-update)
- (setq n (1+ n))
+ (plist-put (cdr image) :index n)
+ (force-window-update)
+ (setq n (1+ n))
+ (let* ((time (float-time))
+ (animation (image-animated-p image))
+ ;; Subtract off the time we took to load the image from the
+ ;; stated delay time.
+ (delay (max (+ (cdr animation) time (- (float-time)))
+ 0.01))
+ done)
(if (>= n count)
(if limit
(setq n 0)
@@ -666,8 +667,7 @@ LIMIT determines when to stop. If t, loop forever. If nil, stop
(setq done (>= time-elapsed limit)))
(unless done
(run-with-timer delay nil 'image-animate-timeout
- image n count delay
- time-elapsed limit))))
+ image n count time-elapsed limit))))
(defcustom imagemagick-types-inhibit
diff --git a/lisp/progmodes/f90.el b/lisp/progmodes/f90.el
index 28f5d329fd5..849b9c0c3f7 100644
--- a/lisp/progmodes/f90.el
+++ b/lisp/progmodes/f90.el
@@ -629,6 +629,7 @@ Can be overridden by the value of `font-lock-maximum-decoration'.")
(modify-syntax-entry ?= "." table)
(modify-syntax-entry ?* "." table)
(modify-syntax-entry ?/ "." table)
+ (modify-syntax-entry ?% "." table) ; bug#8820
;; I think that the f95 standard leaves the behavior of \
;; unspecified, but that f2k will require it to be non-special.
;; Use `f90-backslash-not-special' to change.
@@ -2199,17 +2200,6 @@ CHANGE-WORD should be one of 'upcase-word, 'downcase-word, 'capitalize-word."
(save-excursion
(nth 1 (f90-beginning-of-subprogram))))
-(defun f90-find-tag-default ()
- "Function to use for `find-tag-default-function' property in F90 mode."
- (let ((tag (find-tag-default)))
- (or (and tag
- ;; See bug#7919. TODO I imagine there are other cases...?
- (string-match "%\\([^%]+\\)\\'" tag)
- (match-string-no-properties 1 tag))
- tag)))
-
-(put 'f90-mode 'find-tag-default-function 'f90-find-tag-default)
-
(defun f90-backslash-not-special (&optional all)
"Make the backslash character (\\) be non-special in the current buffer.
With optional argument ALL, change the default for all present
diff --git a/lisp/progmodes/fortran.el b/lisp/progmodes/fortran.el
index f03d2013467..d30b9673d09 100644
--- a/lisp/progmodes/fortran.el
+++ b/lisp/progmodes/fortran.el
@@ -600,6 +600,7 @@ Used in the Fortran entry in `hs-special-modes-alist'.")
(modify-syntax-entry ?= "." table)
(modify-syntax-entry ?* "." table)
(modify-syntax-entry ?/ "." table)
+ (modify-syntax-entry ?% "." table) ; bug#8820
(modify-syntax-entry ?\' "\"" table)
(modify-syntax-entry ?\" "\"" table)
;; Consistent with GNU Fortran's default -- see the manual.