mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2024-11-28 07:45:00 +00:00
Use frame-width' instead of
screen-width',
`frame-height' instead of `screen-height', and, `executing-kbd-macro' instead of `executing-macro'.
This commit is contained in:
parent
26f6427dc8
commit
8f66f4797a
@ -1,5 +1,5 @@
|
||||
;; Calculator for GNU Emacs, part II [calc-graph.el]
|
||||
;; Copyright (C) 1990, 1991, 1992, 1993 Free Software Foundation, Inc.
|
||||
;; Copyright (C) 1990, 1991, 1992, 1993, 2001 Free Software Foundation, Inc.
|
||||
;; Written by Dave Gillespie, daveg@synaptics.com.
|
||||
|
||||
;; This file is part of GNU Emacs.
|
||||
@ -352,11 +352,11 @@
|
||||
"dumb" "postscript")))))
|
||||
(if (equal device "dumb")
|
||||
(setq device (format "dumb %d %d"
|
||||
(1- (screen-width)) (1- (screen-height)))))
|
||||
(1- (frame-width)) (1- (frame-height)))))
|
||||
(if (equal device "big")
|
||||
(setq device (format "dumb %d %d"
|
||||
(* 4 (- (screen-width) 3))
|
||||
(* 4 (- (screen-height) 3)))))
|
||||
(* 4 (- (frame-width) 3))
|
||||
(* 4 (- (frame-height) 3)))))
|
||||
(if (stringp output)
|
||||
(if (or (equal output "auto")
|
||||
(and (equal output "tty") (setq tty-output t)))
|
||||
@ -1370,7 +1370,7 @@ This \"dumb\" driver will be present in Gnuplot 3.0."
|
||||
(set-window-buffer win buf)
|
||||
(if (eq major-mode 'calc-mode)
|
||||
(if (or need
|
||||
(< (window-height) (1- (screen-height))))
|
||||
(< (window-height) (1- (frame-height))))
|
||||
(display-buffer buf))
|
||||
(switch-to-buffer buf)))))
|
||||
(save-excursion
|
||||
|
@ -1,5 +1,5 @@
|
||||
;; Calculator for GNU Emacs, part I [calc-misc.el]
|
||||
;; Copyright (C) 1990, 1991, 1992, 1993 Free Software Foundation, Inc.
|
||||
;; Copyright (C) 1990, 1991, 1992, 1993, 2001 Free Software Foundation, Inc.
|
||||
;; Written by Dave Gillespie, daveg@synaptics.com.
|
||||
|
||||
;; This file is part of GNU Emacs.
|
||||
@ -108,8 +108,8 @@ Calc user interface as before (either M-# C or M-# K; initially M-# C)."
|
||||
(if cwin
|
||||
(setq calc-full-mode
|
||||
(if kwin
|
||||
(and twin (eq (window-width twin) (screen-width)))
|
||||
(eq (window-height cwin) (1- (screen-height))))))
|
||||
(and twin (eq (window-width twin) (frame-width)))
|
||||
(eq (window-height cwin) (1- (frame-height))))))
|
||||
(setq calc-full-mode (if arg
|
||||
(> (prefix-numeric-value arg) 0)
|
||||
(not calc-full-mode)))
|
||||
@ -759,7 +759,7 @@ loaded and the keystroke automatically re-typed."
|
||||
|
||||
|
||||
(defun math-do-working (msg arg)
|
||||
(or executing-macro
|
||||
(or executing-kbd-macro
|
||||
(progn
|
||||
(calc-set-command-flag 'clear-message)
|
||||
(if math-working-step
|
||||
|
@ -1,5 +1,5 @@
|
||||
;; Calculator for GNU Emacs, part II [calc-prog.el]
|
||||
;; Copyright (C) 1990, 1991, 1992, 1993 Free Software Foundation, Inc.
|
||||
;; Copyright (C) 1990, 1991, 1992, 1993, 2001 Free Software Foundation, Inc.
|
||||
;; Written by Dave Gillespie, daveg@synaptics.com.
|
||||
|
||||
;; This file is part of GNU Emacs.
|
||||
@ -666,7 +666,7 @@
|
||||
(symbolp (cdr def))
|
||||
(eq major-mode 'calc-mode))
|
||||
(progn
|
||||
(if (and (< (window-width) (screen-width))
|
||||
(if (and (< (window-width) (frame-width))
|
||||
calc-display-trail)
|
||||
(let ((win (get-buffer-window (calc-trail-buffer))))
|
||||
(if win
|
||||
@ -722,7 +722,7 @@
|
||||
(if (>= (prog2 (forward-char -1)
|
||||
(current-column)
|
||||
(forward-char 1))
|
||||
(screen-width))
|
||||
(frame-width))
|
||||
(fill-region top (point))))
|
||||
(insert "Press C-q to quote control characters like RET"
|
||||
" and TAB.\n"
|
||||
@ -743,7 +743,7 @@
|
||||
(calc-edit-mode (list 'calc-finish-formula-edit
|
||||
(list 'quote func)))
|
||||
(insert (math-showing-full-precision
|
||||
(math-format-nice-expr defn (screen-width)))
|
||||
(math-format-nice-expr defn (frame-width)))
|
||||
"\n"))
|
||||
(calc-show-edit-buffer))
|
||||
(error "That command's definition cannot be edited"))))))
|
||||
@ -1241,7 +1241,7 @@
|
||||
(open last-command-char)
|
||||
(counter initial)
|
||||
ch)
|
||||
(or executing-macro
|
||||
(or executing-kbd-macro
|
||||
(message "Reading loop body..."))
|
||||
(while (>= count 0)
|
||||
(setq ch (read-char))
|
||||
@ -1265,10 +1265,10 @@
|
||||
(setq body (concat body (char-to-string ch)))))
|
||||
(if (/= ch (cdr (assq open '( (?\< . ?\>) (?\( . ?\)) (?\{ . ?\}) ))))
|
||||
(error "Mismatched Z%c and Z%c in keyboard macro" open ch))
|
||||
(or executing-macro
|
||||
(or executing-kbd-macro
|
||||
(message "Looping..."))
|
||||
(setq body (concat (substring body 0 -2) "Z]"))
|
||||
(and (not executing-macro)
|
||||
(and (not executing-kbd-macro)
|
||||
(= rpt-count 1000000)
|
||||
(null parts)
|
||||
(null counter)
|
||||
@ -1300,7 +1300,7 @@
|
||||
(calc-pop-stack 1)
|
||||
(setq counter (calcFunc-add counter step)))
|
||||
(setq rpt-count (1- rpt-count))))))))
|
||||
(or executing-macro
|
||||
(or executing-kbd-macro
|
||||
(message "Looping...done")))
|
||||
)
|
||||
|
||||
@ -1358,7 +1358,7 @@
|
||||
(count 0)
|
||||
(body "")
|
||||
ch)
|
||||
(if (or executing-macro defining-kbd-macro)
|
||||
(if (or executing-kbd-macro defining-kbd-macro)
|
||||
(progn
|
||||
(if defining-kbd-macro
|
||||
(message "Reading body..."))
|
||||
@ -1400,7 +1400,7 @@
|
||||
(defun calc-kbd-report (msg)
|
||||
(interactive "sMessage: ")
|
||||
(calc-wrapper
|
||||
(let ((executing-macro nil)
|
||||
(let ((executing-kbd-macro nil)
|
||||
(defining-kbd-macro nil))
|
||||
(math-working msg (calc-top-n 1))))
|
||||
)
|
||||
@ -1408,7 +1408,7 @@
|
||||
(defun calc-kbd-query (msg)
|
||||
(interactive "sPrompt: ")
|
||||
(calc-wrapper
|
||||
(let ((executing-macro nil)
|
||||
(let ((executing-kbd-macro nil)
|
||||
(defining-kbd-macro nil))
|
||||
(calc-alg-entry nil (and (not (equal msg "")) msg))))
|
||||
)
|
||||
|
@ -1,5 +1,5 @@
|
||||
;; Calculator for GNU Emacs, part II [calc-sel.el]
|
||||
;; Copyright (C) 1990, 1991, 1992, 1993 Free Software Foundation, Inc.
|
||||
;; Copyright (C) 1990, 1991, 1992, 1993, 2001 Free Software Foundation, Inc.
|
||||
;; Written by Dave Gillespie, daveg@synaptics.com.
|
||||
|
||||
;; This file is part of GNU Emacs.
|
||||
@ -672,7 +672,7 @@
|
||||
(sel (or (calc-auto-selection entry) expr))
|
||||
alg)
|
||||
(let ((str (math-showing-full-precision
|
||||
(math-format-nice-expr sel (screen-width)))))
|
||||
(math-format-nice-expr sel (frame-width)))))
|
||||
(calc-edit-mode (list 'calc-finish-selection-edit
|
||||
num (list 'quote sel) reselect))
|
||||
(insert str "\n"))))
|
||||
|
@ -1,5 +1,5 @@
|
||||
;; Calculator for GNU Emacs, part II [calc-yank.el]
|
||||
;; Copyright (C) 1990, 1991, 1992, 1993 Free Software Foundation, Inc.
|
||||
;; Copyright (C) 1990, 1991, 1992, 1993, 2001 Free Software Foundation, Inc.
|
||||
;; Written by Dave Gillespie, daveg@synaptics.com.
|
||||
|
||||
;; This file is part of GNU Emacs.
|
||||
@ -410,7 +410,7 @@
|
||||
(function
|
||||
(lambda (x)
|
||||
(if (math-vectorp x) (setq allow-ret t))
|
||||
(math-format-nice-expr x (screen-width)))))
|
||||
(math-format-nice-expr x (frame-width)))))
|
||||
(if (> n 0)
|
||||
(calc-top-list n)
|
||||
(calc-top-list 1 (- n)))))))
|
||||
@ -488,7 +488,7 @@ To cancel the edit, simply kill the *Calc Edit* buffer."
|
||||
(select-window (get-buffer-window (aref calc-embedded-info 1))))
|
||||
(switch-to-buffer (get-buffer-create "*Calc Edit*")))
|
||||
(setq calc-return-buffer buf)
|
||||
(if (and (< (window-width) (screen-width))
|
||||
(if (and (< (window-width) (frame-width))
|
||||
calc-display-trail)
|
||||
(let ((win (get-buffer-window (calc-trail-buffer))))
|
||||
(if win
|
||||
|
Loading…
Reference in New Issue
Block a user