From 7895927f81a08a4e898161c5e04d037738a5dd8f Mon Sep 17 00:00:00 2001 From: Bill Wohler Date: Sun, 3 Jul 2011 17:27:22 -0700 Subject: [PATCH] * mh-compat.el (mh-window-full-height-p): Add compatibility function for XEmacs. * mh-show.el (mh-show-msg): Use it, and avoid compiler warning on XEmacs. --- lisp/mh-e/ChangeLog | 10 ++++++++-- lisp/mh-e/mh-compat.el | 16 +++++++++++++--- 2 files changed, 21 insertions(+), 5 deletions(-) diff --git a/lisp/mh-e/ChangeLog b/lisp/mh-e/ChangeLog index 3b6214b579a..f52a799653d 100644 --- a/lisp/mh-e/ChangeLog +++ b/lisp/mh-e/ChangeLog @@ -1,5 +1,10 @@ 2011-07-04 Bill Wohler + * mh-compat.el (mh-window-full-height-p): Add compatibility + function for XEmacs. + * mh-show.el (mh-show-msg): Use it, and avoid compiler warning on + XEmacs. + * mh-letter.el (mh-letter-mode-map, mh-letter-complete) (mh-complete-word): Remove FIXME comments since these functions are still needed in other Emacsen. However, they can probably @@ -9,8 +14,9 @@ 2011-07-03 Bill Wohler * mh-compat.el (mh-test-completion): Add compatibility function - for systems without test-completion. - * mh-alias.el (mh-alias-letter-expand-alias): Use it + for XEmacs. + * mh-alias.el (mh-alias-letter-expand-alias): Use it, and avoid + compiler warning on XEmacs. * mh-utils.el: * mh-mime.el: Shush XEmacs compiler in mh-do-in-xemacs block. diff --git a/lisp/mh-e/mh-compat.el b/lisp/mh-e/mh-compat.el index ff30c15fec4..ae2cbff408f 100644 --- a/lisp/mh-e/mh-compat.el +++ b/lisp/mh-e/mh-compat.el @@ -122,6 +122,16 @@ introduced in Emacs 22." "XEmacs does not have `font-lock-add-keywords'. This function returns nil on that system.") +(defun-mh mh-window-full-height-p + window-full-height-p (&optional WINDOW) + "Return non-nil if WINDOW is not the result of a vertical split. +This function is defined in XEmacs as it lacks +`window-full-height-p'. The values of the functions +`window-height' and `frame-height' are compared instead. The +argument WINDOW is ignored." + (= (1+ (window-height)) + (frame-height))) + (defun-mh mh-image-load-path-for-library image-load-path-for-library (library image &optional path no-error) "Return a suitable search path for images used by LIBRARY. @@ -262,9 +272,9 @@ The arguments FIXEDCASE, SUBEXP, and START, used by (defun-mh mh-test-completion test-completion (string collection &optional predicate) - "XEmacs does not have `test-completion'. -This function returns nil on that system." - nil) + "Return non-nil if STRING is a valid completion. +XEmacs does not have `test-completion'. This function returns nil +on that system." nil) ;; Copy of constant from url-util.el in Emacs 22; needed by Emacs 21. (if (not (boundp 'url-unreserved-chars)) -- 2.39.2