From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#9258: 24.0.50; image-next-line doesnt allow omitting arg Date: Sun, 07 Aug 2011 13:59:13 -0400 Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1312740015 26174 80.91.229.12 (7 Aug 2011 18:00:15 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sun, 7 Aug 2011 18:00:15 +0000 (UTC) Cc: 9258@debbugs.gnu.org To: joakim@verona.se Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Aug 07 20:00:10 2011 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Qq7dy-0001jG-Cf for geb-bug-gnu-emacs@m.gmane.org; Sun, 07 Aug 2011 20:00:10 +0200 Original-Received: from localhost ([::1]:39143 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qq7dx-0002AQ-Na for geb-bug-gnu-emacs@m.gmane.org; Sun, 07 Aug 2011 14:00:09 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:52240) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qq7du-00028s-Al for bug-gnu-emacs@gnu.org; Sun, 07 Aug 2011 14:00:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Qq7dt-0004ho-Bn for bug-gnu-emacs@gnu.org; Sun, 07 Aug 2011 14:00:06 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:41627) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qq7dt-0004hU-AG for bug-gnu-emacs@gnu.org; Sun, 07 Aug 2011 14:00:05 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1Qq7eo-0007Nm-0A; Sun, 07 Aug 2011 14:01:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 07 Aug 2011 18:01:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 9258 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 9258-submit@debbugs.gnu.org id=B9258.131274002827423 (code B ref 9258); Sun, 07 Aug 2011 18:01:01 +0000 Original-Received: (at 9258) by debbugs.gnu.org; 7 Aug 2011 18:00:28 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Qq7eF-00077z-GD for submit@debbugs.gnu.org; Sun, 07 Aug 2011 14:00:27 -0400 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.181] helo=ironport2-out.pppoe.ca) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Qq7e1-0006r4-7t for 9258@debbugs.gnu.org; Sun, 07 Aug 2011 14:00:26 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: As8HAJXRPk5FxKeo/2dsb2JhbABCmC6PBniBQAEBBAFWIwULCzQSFBgNVYdPuGWGRgSfVYQx X-IronPort-AV: E=Sophos;i="4.67,333,1309752000"; d="scan'208";a="129417722" Original-Received: from 69-196-167-168.dsl.teksavvy.com (HELO ceviche.home) ([69.196.167.168]) by ironport2-out.pppoe.ca with ESMTP/TLS/ADH-AES256-SHA; 07 Aug 2011 13:59:14 -0400 Original-Received: by ceviche.home (Postfix, from userid 20848) id B72EE66386; Sun, 7 Aug 2011 13:59:13 -0400 (EDT) In-Reply-To: (joakim@verona.se's message of "Sun, 07 Aug 2011 00:13:06 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Sun, 07 Aug 2011 14:01:02 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 1) X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:49940 Archived-At: > (defun image-next-line (&optional n) > "Scroll image in current window upward by N lines. > Stop if the bottom edge of the image is reached." > (interactive "p") > (cond ((= n 0) nil) > ((< n 0) > (image-set-window-vscroll (max 0 (+ (window-vscroll) n)))) > (t > (let* ((image (image-get-display-property)) > (edges (window-inside-edges)) > (win-height (- (nth 3 edges) (nth 1 edges))) > (img-height (ceiling (cdr (image-display-size image))))) > (image-set-window-vscroll (min (max 0 (- img-height win-height)) > (+ n (window-vscroll)))))))) > declaration says n is optional but nil will fail on the numeric tests. > so, either n isn't optional or the cond rearanged. Please just make it mandatory. Stefan