1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-11-29 07:58:28 +00:00

Fix behavior of text-scale-increase when text-scale-mode is disabled

Revision: emacs@sv.gnu.org/emacs--devo--0--patch-1257
This commit is contained in:
Miles Bader 2008-06-19 02:17:16 +00:00
parent 27129af9d7
commit dced1efdff
2 changed files with 7 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2008-06-19 Miles Bader <miles@gnu.org>
* face-remap.el (text-scale-increase): Start from zero if
text-scale-mode isn't enabled.
2008-06-19 Stefan Monnier <monnier@iro.umontreal.ca>
* faces.el (face-set-after-frame-default): Re-apply explicit `font'

View File

@ -234,7 +234,8 @@ Each step scales the height of the default face by the variable
height by the same amount). As a special case, an argument of 0
will remove any scaling currently active."
(interactive "p")
(setq text-scale-mode-amount (if (= inc 0) 0 (+ text-scale-mode-amount inc)))
(setq text-scale-mode-amount
(if (= inc 0) 0 (+ (if text-scale-mode text-scale-mode-amount 0) inc)))
(text-scale-mode (if (zerop text-scale-mode-amount) -1 1)))
;;;###autoload