From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: dalanicolai Newsgroups: gmane.emacs.devel Subject: Re: Request for review `image-roll.el` for Emacs core (or ELPA) Date: Tue, 19 Apr 2022 07:57:54 +0200 Message-ID: References: Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="0000000000007f19fc05dcfb8fb5" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="40832"; mail-complaints-to="usenet@ciao.gmane.io" To: Emacs Devel Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Apr 19 09:26:55 2022 Return-path: Envelope-to: ged-emacs-devel@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 1ngiGE-000ARm-Ch for ged-emacs-devel@m.gmane-mx.org; Tue, 19 Apr 2022 09:26:54 +0200 Original-Received: from localhost ([::1]:55808 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ngiGC-0003Sm-VH for ged-emacs-devel@m.gmane-mx.org; Tue, 19 Apr 2022 03:26:53 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:34824) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nggsL-0007dm-AK for emacs-devel@gnu.org; Tue, 19 Apr 2022 01:58:09 -0400 Original-Received: from mail-yw1-x112a.google.com ([2607:f8b0:4864:20::112a]:38488) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nggsJ-0005Qb-6U for emacs-devel@gnu.org; Tue, 19 Apr 2022 01:58:08 -0400 Original-Received: by mail-yw1-x112a.google.com with SMTP id 00721157ae682-2ec0bb4b715so161022747b3.5 for ; Mon, 18 Apr 2022 22:58:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=P3DHjB2FyuY/mfPYRm3fbolzXiwVhaMlN2JmrEbM2ZM=; b=LstgXKYp/kvOPF+649mjkG8aSJ07w/zv/M/gxE9uPpHBlch80sxzDMzwwRtGpLM4D5 wR2/PBrBuS0T4KbJhYeH/snsFrk/HVg28Mv/1Bfpn4yR9IRANbYwyKDZBaLhcGaANgyl edFMewt9zf0FX/JArIAyb0BcRilX5t4LQTRHjL+hxQ7rz742CE0yfVlBu5/ooTew21uA ja1MgJuJTbsSi1EspdpmfP5sgsTx4WpooOglAKTzh/Q3eQ9G6fbIPWe7ieYu/4OI4z4D 1CWybwBDEWt7Mp4w5uwpjleNEwPbFGoh21O46qc98HzCN0da6b+sEf1HMlNHjrv2+gr8 41hg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=P3DHjB2FyuY/mfPYRm3fbolzXiwVhaMlN2JmrEbM2ZM=; b=G6eb/wZ53Sge44vS49Sc7Y8waX6qJnuFBnuHSeFU3sLquxk9Eha+UAEM3hCRl/tvmj U23m4AbKNpxm+xOGYpXHyUITbM8MrSQrM+eC0f2BgirTHhsgdhu39qF8i6FFypC8sDWy UWobWN7pJItGwObPzR4eRXdMLi1oYoShGgzp8/ohWIVpSoqr4jvPnN+XPus9ZbVulBO2 XrF21n30rP1Rl10xCgXtJUxUbk35zL811ITEkceKsMbT502UumGO3QcrdHNMFpkozILz S3cUSctp+Se0ATj2PTCBzP3dmXnbALWP1etgRAV1sIWex7Jf2ZqX1J7jj3d75UZL/Ch4 AYxQ== X-Gm-Message-State: AOAM532h9vA/FiDcFvHWv4kaQ/l5tu5416kcMkemdsD/cv5D/JV0dOEU tmpG8aOSgfc+PDRDoUo4I9QYYsJ/3D/xR8dydYMUA6VN8+M= X-Google-Smtp-Source: ABdhPJwO2L8pshab4C11DpktLqvmyeyJgL6b8PxfAAW3MVBfgZhPWdY5uzQ6zuffXsYcIh8lof0xqMX8wAwXFRtjU5A= X-Received: by 2002:a81:25d2:0:b0:2ec:459d:ca2b with SMTP id l201-20020a8125d2000000b002ec459dca2bmr13842353ywl.489.1650347885925; Mon, 18 Apr 2022 22:58:05 -0700 (PDT) In-Reply-To: Received-SPF: pass client-ip=2607:f8b0:4864:20::112a; envelope-from=dalanicolai@gmail.com; helo=mail-yw1-x112a.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:288652 Archived-At: --0000000000007f19fc05dcfb8fb5 Content-Type: text/plain; charset="UTF-8" I guess a link to the image-roll package will be handy also (as you will find the repo is still called papyrus.el, but I am hoping you will help decide on the best name for it) On Mon, 18 Apr 2022 at 23:17, dalanicolai wrote: > (I should really switch to Emacs for mail, the above mail probably looks > terrible on the archive, anyway...) > > As a short comment, on pdf-scroll.el. That file contains only a few lines > of 'new' code. The major part of that > file contains copies of 'original' pdf-tools function, but with some minor > modifications. I will add comments > behind the lines containing modifications. > > On Mon, 18 Apr 2022 at 23:11, dalanicolai wrote: > >> I have written a 'scroll/image roll' package that could be considered an >> extension to image-mode. >> The package provides a 'displaying' mechanism for displaying >> images/documents as a single 'virtual scroll'. The main feature/advantage >> of the package is that it allows for the 'much requested' continuous >> scrolling. >> >> In the package I have extracted (and improved) the 'display engine' (or >> whatever to call it), from some earlier experiments of implementing >> continuous scroll into doc-view and pdf-tools. >> >> The current package can be used for displaying documents like books, but >> also for displaying a selection of images. I first thought of calling it >> papyrus.el (because scroll and bookroll, would clutter too much the Emacs >> namespaces), but finally I thought, as it can be used to show images on a >> toll, and can be considered an extension to image-mode, it would be better >> to call it image-roll.el (or maybe just roll), opinions and suggestions >> about the name are very welcome. >> >> For testing, he package contains a `papyrus-demo` function that can >> simply be called after loading the package (best after starting from emacs >> -Q). >> Additionally, as a final step, and as an example of how the package can >> be used, I have included an `image-roll-directory` function in the last >> section (of 38 lines only) in the file, to provide an example of how the >> package can be used to display all images within some directory on a 'roll'. >> This is only a minimal example; as this does not have my priority, I did >> not bother to make it 'fit/scale' the images. >> >> However, I have written also an extension for `pdf-tools`, that provides >> a toggle function so that users can toggle between the 'single' page >> displaying, or the `image-roll` displaying. That file can be found here >> . >> That file can simply be downloaded and loaded (after first setting the path >> to image-roll.el at the top of the file, of course this requires pdf-tools >> to be installed). >> >> I would be happy with any feedback, and info about if and how (what is >> required) this could be added to Emacs core. If you think this package is >> not a good candidate for core (after the required modifications), then I >> would also be happy if it could be added to ELPA (although the package on >> itself is not very interesting, it should get used by 'extensions' e.g. for >> pdf-tools, dired, doc-view, djvu.el etc.). >> > --0000000000007f19fc05dcfb8fb5 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
I guess a link to the image-roll package will be handy also (as you wi= ll find the repo is still called papyrus.el,
but I am hoping you = will help decide on the best name for it)

On Mon, 18 Apr 2022 at 2= 3:17, dalanicolai <dalanicolai@= gmail.com> wrote:
(I should really switch to Emacs for mail,= the above mail probably looks terrible on the archive, anyway...)

As a short comment, on pdf-scroll.el. That file contains o= nly a few lines of 'new' code. The major part of that
fil= e contains copies of 'original' pdf-tools function, but with some m= inor modifications. I will add comments
behind the lines containi= ng modifications.

On Mon, 18 Apr 2022 at 23:11, dalanicolai <dalanicolai@gmail.= com> wrote:
I have written a 'scroll/image roll' packa= ge that could be considered an extension to image-mode.
The packa= ge provides a 'displaying' mechanism for displaying images/document= s as a single 'virtual scroll'. The main feature/advantage of the p= ackage is that it allows for the 'much requested' continuous scroll= ing.

In the package I have extracted (and improved= ) the 'display engine' (or whatever to call it), from some earlier = experiments of implementing continuous scroll into doc-view and pdf-tools.<= /div>

The current package can be used for displaying doc= uments like books, but also for displaying a selection of images. I first t= hought of calling it papyrus.el (because scroll and bookroll, would clutter= too much the Emacs namespaces), but finally I thought, as it can be used t= o show images on a toll, and can be considered an extension to image-mode, = it would be better to call it image-roll.el (or maybe just roll), opinions = and suggestions about the name are very welcome.

F= or testing, he package contains a `papyrus-demo` function that can simply b= e called after loading the package (best after starting from emacs -Q).
=C2=A0Additionally, as a final step, and as an example of how the pa= ckage can be used, I have included an `image-roll-directory` function in th= e last section (of 38 lines only) in the file, to provide an example of how= the package can be used to display all images within some directory on a &= #39;roll'.
This is only a minimal example; as this does not h= ave my priority, I did not bother to make it 'fit/scale' the images= .

However, I have written also an extension fo= r `pdf-tools`, that provides a toggle function so that users can toggle bet= ween the 'single' page displaying, or the `image-roll` displaying. = That file can be found here. That f= ile can simply be downloaded and loaded (after first setting the path to im= age-roll.el at the top of the file, of course this requires pdf-tools to be= installed).

I would be happy with any feedback, a= nd info about if and how (what is required) this could be added to Emacs co= re. If you think this package is not a good candidate for core (after the r= equired modifications), then I would also be happy if it could be added to = ELPA (although the package on itself is not very interesting, it should get= used by 'extensions' e.g. for pdf-tools, dired, doc-view, djvu.el = etc.).
--0000000000007f19fc05dcfb8fb5--