From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Lars Ingebrigtsen Newsgroups: gmane.emacs.bugs Subject: bug#42824: 26.3; Feature request: implement 'smooth scroll' in djvu.el package Date: Mon, 26 Oct 2020 22:42:57 +0100 Message-ID: <87d014u0im.fsf@gnus.org> References: <8916ad6c75c76829bc0b43d6abc88f70e79ee816.camel@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="12838"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: dalanicolai@gmail.com, 42824@debbugs.gnu.org To: Roland Winkler Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Oct 26 22:59:45 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kXAWm-0003Fo-CC for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 26 Oct 2020 22:59:44 +0100 Original-Received: from localhost ([::1]:56390 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kXAWl-0002Qa-CW for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 26 Oct 2020 17:59:43 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:33834) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kXAHb-0004Mb-9I for bug-gnu-emacs@gnu.org; Mon, 26 Oct 2020 17:44:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:58427) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kXAHa-0002Ra-HV for bug-gnu-emacs@gnu.org; Mon, 26 Oct 2020 17:44:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kXAHa-00031R-Ft for bug-gnu-emacs@gnu.org; Mon, 26 Oct 2020 17:44:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Lars Ingebrigtsen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 26 Oct 2020 21:44:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 42824 X-GNU-PR-Package: emacs Original-Received: via spool by 42824-submit@debbugs.gnu.org id=B42824.160374858811534 (code B ref 42824); Mon, 26 Oct 2020 21:44:02 +0000 Original-Received: (at 42824) by debbugs.gnu.org; 26 Oct 2020 21:43:08 +0000 Original-Received: from localhost ([127.0.0.1]:41740 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kXAGi-0002zy-49 for submit@debbugs.gnu.org; Mon, 26 Oct 2020 17:43:08 -0400 Original-Received: from quimby.gnus.org ([95.216.78.240]:48060) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kXAGg-0002zj-VV for 42824@debbugs.gnu.org; Mon, 26 Oct 2020 17:43:07 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=DdBjN4YSkDJ2j1GRuR11Ew4bnFi1vywGX1wN1VH2kE0=; b=hmt0lsoLp+vtFUn97/opHOyf0D nsVwPZ/Pu0dwld3z4viVVV4+CTtnXnCHL14HP8Qs5mY1CynwCx8pNFzXmciVWC6ci2DcgJR946MlH 8zD1hd4VQrzt84FkTkkaETRse01B9vHYpU7fPV6sHxz6ma1YvG5VVvaq6Uwo8ANRCRtc=; Original-Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kXAGY-0006HX-Cf; Mon, 26 Oct 2020 22:43:01 +0100 X-Now-Playing: Prince's _Sign 'O' the Times (1)_: "Housequake" In-Reply-To: <8916ad6c75c76829bc0b43d6abc88f70e79ee816.camel@gmail.com> (dalanicolai@gmail.com's message of "Wed, 12 Aug 2020 10:38:52 +0200") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:191676 Archived-At: Roland, could you take a look at this suggestion -- I've not used djvu.el myself, so I'm not sure whether this would make sense or not: dalanicolai@gmail.com writes: > The djvu.el pacakge is a beautiful package but unfortunately it is not > designed for reading djvu documents (The comments in the file say it is > meant to be used with DjView). Probably for that reason there is no > smooth scroll over pages implemented (at least I am not aware of that > functionality), i.e. you can scroll smoothly over a > single page but you can only do a full page jump to a next or previous > page. > This means that when you are at the bottom/top of a page and jump to > the > next/previous page then you end up at the bottom/top of that page, > which is annoying. Anyway, smooth scrolling can be implemented with > only > a view simple lines. So I would like to propose to add the following > lines to djvu.el: > > (defun djvu-scroll-up-or-next-page () > (interactive) > (scroll-up-line 5) > (when (= (window-vscroll) 0) > (djvu-next-page 1))) > > (defun djvu-scroll-down-or-previous-page () > (interactive) > (if (not (= (window-vscroll) 0)) > (scroll-down-line 5) > (djvu-prev-page 1) > (scroll-up-command)))) > > By adding these lines emacs can be perfectly used as a djvu reader > (although it does not show annotations). -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no