From unknown Sat Jun 21 10:29:10 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#13887 <13887@debbugs.gnu.org> To: bug#13887 <13887@debbugs.gnu.org> Subject: Status: 24.3; doc-view will render blurry images when image-magick is available Reply-To: bug#13887 <13887@debbugs.gnu.org> Date: Sat, 21 Jun 2025 17:29:10 +0000 retitle 13887 24.3; doc-view will render blurry images when image-magick is= available reassign 13887 emacs submitter 13887 E Sabof severity 13887 normal tag 13887 moreinfo thanks From debbugs-submit-bounces@debbugs.gnu.org Tue Mar 05 22:41:28 2013 Received: (at submit) by debbugs.gnu.org; 6 Mar 2013 03:41:29 +0000 Received: from localhost ([127.0.0.1]:33439 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UD5EO-0007cm-2S for submit@debbugs.gnu.org; Tue, 05 Mar 2013 22:41:28 -0500 Received: from eggs.gnu.org ([208.118.235.92]:39409) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UD5EK-0007cW-Fo for submit@debbugs.gnu.org; Tue, 05 Mar 2013 22:41:25 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UD5Dp-0007Lu-6W for submit@debbugs.gnu.org; Tue, 05 Mar 2013 22:40:55 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,FREEMAIL_FROM, HTML_MESSAGE,RCVD_IN_DNSWL_LOW,T_DKIM_INVALID autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:60050) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UD5Dp-0007Lq-3N for submit@debbugs.gnu.org; Tue, 05 Mar 2013 22:40:53 -0500 Received: from eggs.gnu.org ([208.118.235.92]:50758) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UD5Dm-0003gv-Bn for bug-gnu-emacs@gnu.org; Tue, 05 Mar 2013 22:40:53 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UD5Dj-0007KQ-JM for bug-gnu-emacs@gnu.org; Tue, 05 Mar 2013 22:40:50 -0500 Received: from mail-qe0-f49.google.com ([209.85.128.49]:36731) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UD5Dj-0007KK-Dq for bug-gnu-emacs@gnu.org; Tue, 05 Mar 2013 22:40:47 -0500 Received: by mail-qe0-f49.google.com with SMTP id 1so5088350qec.36 for ; Tue, 05 Mar 2013 19:40:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:date:message-id:subject:from:to :content-type; bh=sebaRipIvWgw+HbhcnvK48AMd4WSObxNQSzLyx5siRw=; b=CX95QEZ1KAME+sagyDRMgSClXRUPTvjdQmAzdEMwVwVmUF9scrWxIQBexynb8S+46D JrNgeJRZDL2mL6AZ2S7XvG6HBW8s4B1p0il3RHU2YxJclrZJC4kSI9RwcHrO5sTX4d7B RWamRPcw09T48PoTf5nVnfEQ+Wq8dpx+rG8rJ6LxM1GKVl9h8xSjXIm0wxjxuFhUgZGn MUYdP2HGmGY7eRGgFJnqSfAzpicWvLKfxeXnfvYIrn8fZ2wVD3s96LAfNyVrCt9OSqms 7aAuUA9sAhsribhTEYZ3HEBXOy4eEwsDoGsS+2yI/QBN94ud12AWjZQBqVIxbK2AlhaR 7sHg== MIME-Version: 1.0 X-Received: by 10.224.33.208 with SMTP id i16mr43459421qad.45.1362541246779; Tue, 05 Mar 2013 19:40:46 -0800 (PST) Received: by 10.49.70.233 with HTTP; Tue, 5 Mar 2013 19:40:46 -0800 (PST) Date: Wed, 6 Mar 2013 03:40:46 +0000 Message-ID: Subject: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: bug-gnu-emacs@gnu.org Content-Type: multipart/alternative; boundary=20cf3074d57401998404d7395b25 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 208.118.235.17 X-Spam-Score: -3.4 (---) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -4.2 (----) --20cf3074d57401998404d7395b25 Content-Type: text/plain; charset=ISO-8859-1 It tries to up-scale the available bitmap - leading to a loss of quality, instead of re-rendering the page from vector data. --20cf3074d57401998404d7395b25 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
It tries to up-scale the available bitmap - leading to a l= oss of=A0quality,=A0instead of re-rendering the page from vector data. --20cf3074d57401998404d7395b25-- From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 06 03:06:32 2013 Received: (at 13887) by debbugs.gnu.org; 6 Mar 2013 08:06:32 +0000 Received: from localhost ([127.0.0.1]:33586 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UD9Mt-0006Jo-Vz for submit@debbugs.gnu.org; Wed, 06 Mar 2013 03:06:32 -0500 Received: from deliver.uni-koblenz.de ([141.26.64.15]:34128) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UD9Mr-0006Jf-IN for 13887@debbugs.gnu.org; Wed, 06 Mar 2013 03:06:31 -0500 Received: from localhost (localhost [127.0.0.1]) by deliver.uni-koblenz.de (Postfix) with ESMTP id 1118A1A884F; Wed, 6 Mar 2013 09:06:04 +0100 (CET) X-Virus-Scanned: amavisd-new at uni-koblenz.de Received: from deliver.uni-koblenz.de ([127.0.0.1]) by localhost (deliver.uni-koblenz.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id OukWZjQvN4G4; Wed, 6 Mar 2013 09:06:03 +0100 (CET) X-CHKRCPT: Envelopesender noch tsdh@gnu.org Received: from thinkpad.tsdh.de (tsdh.uni-koblenz.de [141.26.67.142]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by deliver.uni-koblenz.de (Postfix) with ESMTPSA id BB59D1A884C; Wed, 6 Mar 2013 09:06:03 +0100 (CET) From: Tassilo Horn To: E Sabof Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available References: Date: Wed, 06 Mar 2013 09:05:59 +0100 In-Reply-To: (E. Sabof's message of "Wed, 6 Mar 2013 03:40:46 +0000") Message-ID: <8762153qc8.fsf@thinkpad.tsdh.de> User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.8 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.5 (---) E Sabof writes: > It tries to up-scale the available bitmap - leading to a loss of > quality, instead of re-rendering the page from vector data. You mean, it up-scales when you hit +? That's a feature, because up-scaling is much faster than reconverting. To make use of the feature, you should set `doc-view-resolution' to some reasonably high value. I use this (setq doc-view-resolution 200) and it works very well. Bye, Tassilo From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 06 07:14:09 2013 Received: (at 13887) by debbugs.gnu.org; 6 Mar 2013 12:14:09 +0000 Received: from localhost ([127.0.0.1]:33770 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDDEW-0003po-Nl for submit@debbugs.gnu.org; Wed, 06 Mar 2013 07:14:09 -0500 Received: from mail-qa0-f54.google.com ([209.85.216.54]:51545) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDDET-0003pA-HZ for 13887@debbugs.gnu.org; Wed, 06 Mar 2013 07:14:06 -0500 Received: by mail-qa0-f54.google.com with SMTP id hg5so2462913qab.6 for <13887@debbugs.gnu.org>; Wed, 06 Mar 2013 04:13:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=m59yJcwLa2b/Up+qcOZGZiRLWkWgite5N41arWkv6gE=; b=oSp3d002xPPgPDu7mRNGhqM14nPPuvWxaakYwScEO8b7VgfQpn3LQOdM/fub9Xo4Yy FL4H5q+h+OhlshdWKKvncUCoZz1TXSskxMbunW4CC5mXHs96CGDflIvwqegpNp4sha2K CJe5s68PBGKzUTQCzCxBA4do16CK3gM4NvTmiQZESXK/9c9JBSgGf5IDSksyisq1h+hi LM71Ltpf9JeKrJhIczkvyw2yv56VXqmRu0kTJU4clBQxeYOKqh5PV1t3Vl9ze8FGxCPe xwlh4lh7klc0+QjTw93HEWWKymZvshM5laZssDSOLsohsIKlI9vXDtoNhadS8ZquS7Qd Vvxg== MIME-Version: 1.0 X-Received: by 10.49.74.10 with SMTP id p10mr46715156qev.35.1362572014274; Wed, 06 Mar 2013 04:13:34 -0800 (PST) Received: by 10.49.70.233 with HTTP; Wed, 6 Mar 2013 04:13:34 -0800 (PST) In-Reply-To: <8762153qc8.fsf@thinkpad.tsdh.de> References: <8762153qc8.fsf@thinkpad.tsdh.de> Date: Wed, 6 Mar 2013 12:13:34 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Tassilo Horn Content-Type: multipart/alternative; boundary=047d7bdc1272e451a904d740840e X-Spam-Score: 0.1 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.2 (-) --047d7bdc1272e451a904d740840e Content-Type: text/plain; charset=ISO-8859-1 I've tried it, indeed it works much better. Might it be possible to store the the "native" size, and raise the resolution automatically when the zoom exceeds it? On a side note, might it be also possible to horizontally center the image? There is a pretty straight-forward way to do it, used in the about-emacs screen. Evgeni On Wed, Mar 6, 2013 at 8:05 AM, Tassilo Horn wrote: > E Sabof writes: > > > It tries to up-scale the available bitmap - leading to a loss of > > quality, instead of re-rendering the page from vector data. > > You mean, it up-scales when you hit +? That's a feature, because > up-scaling is much faster than reconverting. To make use of the > feature, you should set `doc-view-resolution' to some reasonably high > value. I use this > > (setq doc-view-resolution 200) > > and it works very well. > > Bye, > Tassilo > --047d7bdc1272e451a904d740840e Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
I've tried it, indeed it works much better. Might it b= e possible to store the the "native" size, and=A0raise=A0the reso= lution automatically when the zoom exceeds it?

On = a side note, might it be also possible to horizontally center the image? Th= ere is a pretty straight-forward way to do it, used in the about-emacs scre= en.

Evgeni


On Wed, Mar 6, 2013 at 8:05 AM, Tassil= o Horn <tsdh@gnu.org> wrote:
E Sabof <esabof@gmail.com> writes:

> It tries to up-scale the available bitmap - leading to a loss of
> quality, instead of re-rendering the page from vector data.

You mean, it up-scales when you hit +? =A0That's a feature, because
up-scaling is much faster than reconverting. =A0To make use of the
feature, you should set `doc-view-resolution' to some reasonably high value. =A0I use this

=A0 (setq doc-view-resolution 200)

and it works very well.

Bye,
Tassilo

--047d7bdc1272e451a904d740840e-- From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 06 08:01:48 2013 Received: (at 13887) by debbugs.gnu.org; 6 Mar 2013 13:01:48 +0000 Received: from localhost ([127.0.0.1]:33813 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDDyc-0005s0-Gx for submit@debbugs.gnu.org; Wed, 06 Mar 2013 08:01:48 -0500 Received: from deliver.uni-koblenz.de ([141.26.64.15]:33296) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDDyZ-0005rr-LK for 13887@debbugs.gnu.org; Wed, 06 Mar 2013 08:01:45 -0500 Received: from localhost (localhost [127.0.0.1]) by deliver.uni-koblenz.de (Postfix) with ESMTP id 1271E1A841A; Wed, 6 Mar 2013 14:01:17 +0100 (CET) X-Virus-Scanned: amavisd-new at uni-koblenz.de Received: from deliver.uni-koblenz.de ([127.0.0.1]) by localhost (deliver.uni-koblenz.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 521Jdmo7d_YK; Wed, 6 Mar 2013 14:01:16 +0100 (CET) X-CHKRCPT: Envelopesender noch tsdh@gnu.org Received: from thinkpad.tsdh.de (tsdh.uni-koblenz.de [141.26.67.142]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by deliver.uni-koblenz.de (Postfix) with ESMTPSA id B8C221A841F; Wed, 6 Mar 2013 14:01:16 +0100 (CET) From: Tassilo Horn To: E Sabof Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available References: <8762153qc8.fsf@thinkpad.tsdh.de> Date: Wed, 06 Mar 2013 14:01:13 +0100 In-Reply-To: (E. Sabof's message of "Wed, 6 Mar 2013 12:13:34 +0000") Message-ID: <8762143co6.fsf@thinkpad.tsdh.de> User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.8 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.5 (---) E Sabof writes: > I've tried it, indeed it works much better. Might it be possible to > store the the "native" size, and raise the resolution automatically > when the zoom exceeds it? Well, the resolution should be increased and the doc reconverted when the up-scaled image becomes blurry. But how should emacs know when you think it becomes blurry? > On a side note, might it be also possible to horizontally center the > image? There is a pretty straight-forward way to do it, used in the > about-emacs screen. I guess this could be done somehow. But do you want to center to make the contents a bit larger and not to see the margins? If so, then slicing to the bounding box (`s b') followed by fitting to width (`W') may be the better approach. Bye, Tassilo From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 06 09:19:57 2013 Received: (at 13887) by debbugs.gnu.org; 6 Mar 2013 14:19:57 +0000 Received: from localhost ([127.0.0.1]:33855 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDFCF-0007hU-VE for submit@debbugs.gnu.org; Wed, 06 Mar 2013 09:19:56 -0500 Received: from mail-qa0-f41.google.com ([209.85.216.41]:52444) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDFCC-0007hF-6n for 13887@debbugs.gnu.org; Wed, 06 Mar 2013 09:19:53 -0500 Received: by mail-qa0-f41.google.com with SMTP id bs12so2561248qab.0 for <13887@debbugs.gnu.org>; Wed, 06 Mar 2013 06:19:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=4XwxdLnhiQXPIf08vtTi7Jw+Fj4cCIYXroiuioQMYQI=; b=BX/iumcoASpKTrnVYMLbs3Vb22HF07W94qtww5qmeZKq3jouXXsNhAGjWQfC3rOPB6 o3hkQnhfJjxbHh5XHMZSdJxbR1Ik7EGuVIK0pmMa40fIUQXLGQrmrphG5GK3SmMKwPfp /MJXPFRxJD/k9Rg5gmAJiC6VwS9eY266H1GGJ5PGMsWbsAbAfh83HwS+Zz/YUTkWUIFt jb3rXDGr4sNJGIEfZ+WaZ7bANnBLykFmoWdLms5ajw2ykxWd8ffyVORlyLfePgpoBq/y h32KNF0XvyHbgxJHgqRcyRp1hMhakfD+lbp3XAC84Kev+OXNPcNfB/SmtwGa3elIpTX0 hY+A== MIME-Version: 1.0 X-Received: by 10.224.27.136 with SMTP id i8mr45828829qac.63.1362579560162; Wed, 06 Mar 2013 06:19:20 -0800 (PST) Received: by 10.49.70.233 with HTTP; Wed, 6 Mar 2013 06:19:19 -0800 (PST) In-Reply-To: <8762143co6.fsf@thinkpad.tsdh.de> References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> Date: Wed, 6 Mar 2013 14:19:19 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Tassilo Horn Content-Type: multipart/alternative; boundary=bcaec51b1593a9bc4b04d742466f X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --bcaec51b1593a9bc4b04d742466f Content-Type: text/plain; charset=ISO-8859-1 This function gives the native pixel dimensions of an image: (defun es-image-file-pixel-dimensions (file) (let* ((type (image-type file nil nil)) (spec (list 'image :type type :file file))) (image-size spec t))) When (> (getf (cdr (doc-view-current-image)) :width) (car (es-image-file-pixel-dimensions (getf (cdr (doc-view-current-image)) :file)))) there is quality loss. What I don't want to see is margins having a different width - for the same reasons you wouldn't put a photograph in a frame in the top left corner. Ideally I'd also center vertically (should the image be shorter than the window) and add a window-configuration-change-hook (or there might be an appropriate display-spec), so it's always centered. Unfortunately no image-viewer that currently comes with emacs (image-mode ,doc-view-mode ,image-dired-display-image-mode) does this. Evgeni On Wed, Mar 6, 2013 at 1:01 PM, Tassilo Horn wrote: > E Sabof writes: > > > I've tried it, indeed it works much better. Might it be possible to > > store the the "native" size, and raise the resolution automatically > > when the zoom exceeds it? > > Well, the resolution should be increased and the doc reconverted when > the up-scaled image becomes blurry. But how should emacs know when you > think it becomes blurry? > > > On a side note, might it be also possible to horizontally center the > > image? There is a pretty straight-forward way to do it, used in the > > about-emacs screen. > > I guess this could be done somehow. But do you want to center to make > the contents a bit larger and not to see the margins? If so, then > slicing to the bounding box (`s b') followed by fitting to width (`W') > may be the better approach. > > Bye, > Tassilo > --bcaec51b1593a9bc4b04d742466f Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
This function gives the native pixel dimensions of an imag= e:

(defun es-image-file-pixel-dimensions (file)
=A0 (let* ((type (image-type file nil nil))
=A0 =A0 =A0 = =A0 =A0(spec (list 'image :type type :file file)))
=A0 =A0 (image-size spec t)))

Whe= n

(> (getf (cdr (doc-view-curr= ent-image)) :width)
=A0 =A0(car (es-image-file-pixel-dimensions= =A0
=A0 =A0 =A0 =A0 =A0(getf (cdr (doc-view-current-image)) :file))))

there is quality loss.
What I don't want to see is margins having a differen= t width - for the same reasons you wouldn't put a photograph in a frame= in the top left corner. Ideally I'd also center=A0vertically (should t= he image be=A0shorter=A0than the window) and add a window-configuration-cha= nge-hook (or there might be an=A0appropriate=A0display-spec), so it's a= lways centered. Unfortunately no image-viewer that currently comes with ema= cs (image-mode ,doc-view-mode ,image-dired-display-image-mode) does this.

Evgeni


On Wed, Mar 6, 2013 at 1:01 PM, Tassil= o Horn <tsdh@gnu.org> wrote:
E Sabof <esabof@gmail.com> writes:

> I've tried it, indeed it works much better. Might it be possible t= o
> store the the "native" size, and raise the resolution automa= tically
> when the zoom exceeds it?

Well, the resolution should be increased and the doc reconverted when=
the up-scaled image becomes blurry. =A0But how should emacs know when you think it becomes blurry?

> On a side note, might it be also possible to horizontally center the > image? =A0There is a pretty straight-forward way to do it, used in the=
> about-emacs screen.

I guess this could be done somehow. =A0But do you want to center to m= ake
the contents a bit larger and not to see the margins? =A0If so, then
slicing to the bounding box (`s b') followed by fitting to width (`W= 9;)
may be the better approach.

Bye,
Tassilo

--bcaec51b1593a9bc4b04d742466f-- From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 06 13:17:10 2013 Received: (at 13887) by debbugs.gnu.org; 6 Mar 2013 18:17:10 +0000 Received: from localhost ([127.0.0.1]:34641 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDItq-000543-7t for submit@debbugs.gnu.org; Wed, 06 Mar 2013 13:17:10 -0500 Received: from ironport2-out.teksavvy.com ([206.248.154.182]:18973) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDIto-00053s-VZ for 13887@debbugs.gnu.org; Wed, 06 Mar 2013 13:17:09 -0500 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av4EABK/CFFFpYG1/2dsb2JhbABEvw4Xc4IeAQEEAVYjBQsLNBIUGA0kiB4GwS2RCgOIYZwZgV6DFQ X-IPAS-Result: Av4EABK/CFFFpYG1/2dsb2JhbABEvw4Xc4IeAQEEAVYjBQsLNBIUGA0kiB4GwS2RCgOIYZwZgV6DFQ X-IronPort-AV: E=Sophos;i="4.84,565,1355115600"; d="scan'208";a="3185391" Received: from 69-165-129-181.dsl.teksavvy.com (HELO pastel.home) ([69.165.129.181]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 06 Mar 2013 13:16:34 -0500 Received: by pastel.home (Postfix, from userid 20848) id 8A6046785F; Wed, 6 Mar 2013 13:16:33 -0500 (EST) From: Stefan Monnier To: E Sabof Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available Message-ID: References: Date: Wed, 06 Mar 2013 13:16:33 -0500 In-Reply-To: (E. Sabof's message of "Wed, 6 Mar 2013 03:40:46 +0000") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) > It tries to up-scale the available bitmap - leading to a loss > of quality, instead of re-rendering the page from vector data. In Emacs's trunk you can set doc-view-scale-internally to nil. Stefan From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 06 14:43:53 2013 Received: (at 13887) by debbugs.gnu.org; 6 Mar 2013 19:43:53 +0000 Received: from localhost ([127.0.0.1]:34769 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDKFj-0007Aw-JU for submit@debbugs.gnu.org; Wed, 06 Mar 2013 14:43:53 -0500 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:55978) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDKFe-0007Al-Ht for 13887@debbugs.gnu.org; Wed, 06 Mar 2013 14:43:50 -0500 Received: from compute3.internal (compute3.nyi.mail.srv.osa [10.202.2.43]) by gateway1.nyi.mail.srv.osa (Postfix) with ESMTP id B2B6B20798; Wed, 6 Mar 2013 14:43:18 -0500 (EST) Received: from frontend1.nyi.mail.srv.osa ([10.202.2.160]) by compute3.internal (MEProxy); Wed, 06 Mar 2013 14:43:18 -0500 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=from:to:cc:subject:references:date :in-reply-to:message-id:mime-version:content-type; s=smtpout; bh=3Vxz9nBE/fFgRwGZ5SL8PzX5NsY=; b=Ga9VT0Vt3/Cm5/CnROS3ycUjAgZ4 Fa3cukD1f85c5DrpUoWalR7BzItrGvov0cMJPBKDs/YS5LAtD7g04pqHxB/3J6QW 7Y6oPP3YL+iaGAPzA4Usyca3X8/NfG+IfpQ/O/lwkQ5O3VkxbuPiGujb1VHq+J7u zuPUwOVjUbyDWn0= X-Sasl-enc: hLXM2gXY5mQQ//f/mqJ4NOQ6zceIVbkYcdVKfWuQPP4Q 1362598998 Received: from thinkpad.tsdh.de (unknown [91.67.10.84]) by mail.messagingengine.com (Postfix) with ESMTPA id 1B583C80E8D; Wed, 6 Mar 2013 14:43:18 -0500 (EST) From: Tassilo Horn To: E Sabof Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> Date: Wed, 06 Mar 2013 20:43:16 +0100 In-Reply-To: (E. Sabof's message of "Wed, 6 Mar 2013 14:19:19 +0000") Message-ID: <877glkgvqj.fsf@thinkpad.tsdh.de> User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) E Sabof writes: > This function gives the native pixel dimensions of an image: > > (defun es-image-file-pixel-dimensions (file) > (let* ((type (image-type file nil nil)) > (spec (list 'image :type type :file file))) > (image-size spec t))) > > When > > (> (getf (cdr (doc-view-current-image)) :width) > (car (es-image-file-pixel-dimensions > (getf (cdr (doc-view-current-image)) :file)))) > > there is quality loss. Hm, ok. Maybe I'll give it a whirl. > What I don't want to see is margins having a different width - for the > same reasons you wouldn't put a photograph in a frame in the top left > corner. Could you test-drive this patch. It implements horizontal centering of the image. --8<---------------cut here---------------start------------->8--- === modified file 'lisp/doc-view.el' --- lisp/doc-view.el 2013-02-28 04:02:36 +0000 +++ lisp/doc-view.el 2013-03-06 19:35:43 +0000 @@ -1250,23 +1250,34 @@ (when doc-view-pending-cache-flush (clear-image-cache) (setq doc-view-pending-cache-flush nil)) - (let ((ol (doc-view-current-overlay)) - (image (if (and file (file-readable-p file)) - (if (not (and doc-view-scale-internally - (fboundp 'imagemagick-types))) - (apply 'create-image file doc-view--image-type nil args) - (unless (member :width args) - (setq args `(,@args :width ,doc-view-image-width))) - (apply 'create-image file 'imagemagick nil args)))) - (slice (doc-view-current-slice))) + (let* ((ol (doc-view-current-overlay)) + (image (if (and file (file-readable-p file)) + (if (not (and doc-view-scale-internally + (fboundp 'imagemagick-types))) + (apply 'create-image file doc-view--image-type nil args) + (unless (member :width args) + (setq args `(,@args :width ,doc-view-image-width))) + (apply 'create-image file 'imagemagick nil args)))) + (slice (doc-view-current-slice)) + (img-width (car (image-size image))) + (displayed-img-width (if slice + (* (/ (float (nth 2 slice)) + (car (image-size image 'pixels))) + img-width) + img-width)) + (window-width (window-width (selected-window)))) (setf (doc-view-current-image) image) (move-overlay ol (point-min) (point-max)) + (when (> window-width displayed-img-width) + (overlay-put ol 'before-string + (propertize " " 'display + `(space :align-to (+ center (-0.5 . ,displayed-img-width)))))) (overlay-put ol 'display (cond (image (if slice (list (cons 'slice slice) image) - image)) + image)) ;; We're trying to display a page that doesn't exist. (doc-view-current-converter-processes ;; Maybe the page doesn't exist *yet*. --8<---------------cut here---------------end--------------->8--- > Ideally I'd also center vertically (should the image be shorter than > the window) I think vertical centering is a bit more tricky since there's nothing like :align-to or vertically stretchable spaces... Bye, Tassilo From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 07 10:18:36 2013 Received: (at 13887) by debbugs.gnu.org; 7 Mar 2013 15:18:36 +0000 Received: from localhost ([127.0.0.1]:36696 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDcaZ-0003I0-QM for submit@debbugs.gnu.org; Thu, 07 Mar 2013 10:18:36 -0500 Received: from mail-qc0-f180.google.com ([209.85.216.180]:49231) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDcaW-0003Hm-Ab for 13887@debbugs.gnu.org; Thu, 07 Mar 2013 10:18:34 -0500 Received: by mail-qc0-f180.google.com with SMTP id v28so183334qcm.11 for <13887@debbugs.gnu.org>; Thu, 07 Mar 2013 07:17:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=rXvTgf+9KEYsLptkHtKNsMBSMAVSyVEBYavY2I93ti4=; b=Pp5H7DiyvIGBrUEKrEmi050j49qwUMlvVF0YfqP9vcyrj3plnInJAJS/NC+RCA2Xzy v3k2oV+wiTAqkTNwHPrkMFFFEJ51u2PLDFIUWWecLCwXJbhqiq/kORs4e4zlk0wPwaXt oEqPX8sMhY4Nos56pWwqGfiY48ToCdQcMTvXiDlU+5IAG8Al/bZCtw5GtDBLDprWdm4f LhyQJtbbVczPwVl4sD8L3/vgloTHkiQiz6Sw3eOk0uzE4khnk+sa9Z9aIGrZumaSqK0v mOmpiUjF3v7YfQKmdx0yXGI+vplOQ2m2nAwD33jkCg/d2hwGR8YL+lM/X5mHRL3HAbf8 HdSg== MIME-Version: 1.0 X-Received: by 10.224.108.4 with SMTP id d4mr30235075qap.83.1362669474206; Thu, 07 Mar 2013 07:17:54 -0800 (PST) Received: by 10.49.70.233 with HTTP; Thu, 7 Mar 2013 07:17:54 -0800 (PST) In-Reply-To: <877glkgvqj.fsf@thinkpad.tsdh.de> References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> Date: Thu, 7 Mar 2013 15:17:54 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Tassilo Horn Content-Type: multipart/alternative; boundary=20cf3074b16af4e40e04d757359f X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --20cf3074b16af4e40e04d757359f Content-Type: text/plain; charset=ISO-8859-1 I had a look at it, there are some issues with zooming. It doesn't work when I open a document that is larger than the window, and sometimes in other cases. On Wed, Mar 6, 2013 at 7:43 PM, Tassilo Horn wrote: > E Sabof writes: > > > This function gives the native pixel dimensions of an image: > > > > (defun es-image-file-pixel-dimensions (file) > > (let* ((type (image-type file nil nil)) > > (spec (list 'image :type type :file file))) > > (image-size spec t))) > > > > When > > > > (> (getf (cdr (doc-view-current-image)) :width) > > (car (es-image-file-pixel-dimensions > > (getf (cdr (doc-view-current-image)) :file)))) > > > > there is quality loss. > > Hm, ok. Maybe I'll give it a whirl. > > > What I don't want to see is margins having a different width - for the > > same reasons you wouldn't put a photograph in a frame in the top left > > corner. > > Could you test-drive this patch. It implements horizontal centering of > the image. > > --8<---------------cut here---------------start------------->8--- > === modified file 'lisp/doc-view.el' > --- lisp/doc-view.el 2013-02-28 04:02:36 +0000 > +++ lisp/doc-view.el 2013-03-06 19:35:43 +0000 > @@ -1250,23 +1250,34 @@ > (when doc-view-pending-cache-flush > (clear-image-cache) > (setq doc-view-pending-cache-flush nil)) > - (let ((ol (doc-view-current-overlay)) > - (image (if (and file (file-readable-p file)) > - (if (not (and doc-view-scale-internally > - (fboundp 'imagemagick-types))) > - (apply 'create-image file doc-view--image-type nil > args) > - (unless (member :width args) > - (setq args `(,@args :width ,doc-view-image-width))) > - (apply 'create-image file 'imagemagick nil args)))) > - (slice (doc-view-current-slice))) > + (let* ((ol (doc-view-current-overlay)) > + (image (if (and file (file-readable-p file)) > + (if (not (and doc-view-scale-internally > + (fboundp 'imagemagick-types))) > + (apply 'create-image file doc-view--image-type nil > args) > + (unless (member :width args) > + (setq args `(,@args :width ,doc-view-image-width))) > + (apply 'create-image file 'imagemagick nil args)))) > + (slice (doc-view-current-slice)) > + (img-width (car (image-size image))) > + (displayed-img-width (if slice > + (* (/ (float (nth 2 slice)) > + (car (image-size image 'pixels))) > + img-width) > + img-width)) > + (window-width (window-width (selected-window)))) > (setf (doc-view-current-image) image) > (move-overlay ol (point-min) (point-max)) > + (when (> window-width displayed-img-width) > + (overlay-put ol 'before-string > + (propertize " " 'display > + `(space :align-to (+ center (-0.5 . > ,displayed-img-width)))))) > (overlay-put ol 'display > (cond > (image > (if slice > (list (cons 'slice slice) image) > - image)) > + image)) > ;; We're trying to display a page that doesn't exist. > (doc-view-current-converter-processes > ;; Maybe the page doesn't exist *yet*. > --8<---------------cut here---------------end--------------->8--- > > > Ideally I'd also center vertically (should the image be shorter than > > the window) > > I think vertical centering is a bit more tricky since there's nothing > like :align-to or vertically stretchable spaces... > > Bye, > Tassilo > --20cf3074b16af4e40e04d757359f Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
I had a look at it, there are some issues with zooming. It= doesn't work when I open a document that is larger than the window, an= d sometimes in other cases.


On Wed, Mar 6, 2013 at 7:43 PM, Tassilo Horn <tsdh@gnu.org> wrot= e:
E Sabof <esabof@gm= ail.com> writes:

> This function gives the native pixel dimensions of an image:
>
> (defun es-image-file-pixel-dimensions (file)
> =A0 (let* ((type (image-type file nil nil))
> =A0 =A0 =A0 =A0 =A0(spec (list 'image :type type :file file)))
> =A0 =A0 (image-size spec t)))
>
> When
>
> (> (getf (cdr (doc-view-current-image)) :width)
> =A0 =A0(car (es-image-file-pixel-dimensions
> =A0 =A0 =A0 =A0 =A0(getf (cdr (doc-view-current-image)) :file))))
>
> there is quality loss.

Hm, ok. =A0Maybe I'll give it a whirl.

> What I don't want to see is margins having a different width - for= the
> same reasons you wouldn't put a photograph in a frame in the top l= eft
> corner.

Could you test-drive this patch. =A0It implements horizontal centerin= g of
the image.

--8<---------------cut here---------------start------------->8---
=3D=3D=3D modified file 'lisp/doc-view.el'
--- lisp/doc-view.el =A0 =A02013-02-28 04:02:36 +0000
+++ lisp/doc-view.el =A0 =A02013-03-06 19:35:43 +0000
@@ -1250,23 +1250,34 @@
=A0 =A0(when doc-view-pending-cache-flush
=A0 =A0 =A0(clear-image-cache)
=A0 =A0 =A0(setq doc-view-pending-cache-flush nil))
- =A0(let ((ol (doc-view-current-overlay))
- =A0 =A0 =A0 =A0(image (if (and file (file-readable-p file))
- =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(if (not (and doc-view-scale-internall= y
- =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (fboundp = 'imagemagick-types)))
- =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(apply 'create-image file = doc-view--image-type nil args)
- =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(unless (member :width args)
- =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(setq args `(,@args :width ,do= c-view-image-width)))
- =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(apply 'create-image file '= ;imagemagick nil args))))
- =A0 =A0 =A0 =A0(slice (doc-view-current-slice)))
+ =A0(let* ((ol (doc-view-current-overlay))
+ =A0 =A0 =A0 =A0(image (if (and file (file-readable-p file))
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (if (not (and doc-view-scale-internal= ly
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (fboundp = 'imagemagick-types)))
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (apply 'create-image file= doc-view--image-type nil args)
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (unless (member :width args)
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (setq args `(,@args :width ,d= oc-view-image-width)))
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (apply 'create-image file = 9;imagemagick nil args))))
+ =A0 =A0 =A0 =A0(slice (doc-view-current-slice))
+ =A0 =A0 =A0 =A0(img-width (car (image-size image)))
+ =A0 =A0 =A0 =A0(displayed-img-width (if slice
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (* (/ (fl= oat (nth 2 slice))
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 (car (image-size image 'pixels)))
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0im= g-width)
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 img-width)) + =A0 =A0 =A0 =A0(window-width (window-width (selected-window))))
=A0 =A0 =A0(setf (doc-view-current-image) image)
=A0 =A0 =A0(move-overlay ol (point-min) (point-max))
+ =A0 =A0(when (> window-width displayed-img-width)
+ =A0 =A0 =A0(overlay-put ol 'before-string
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(propertize " " 'display=
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0`(space :align= -to (+ center (-0.5 . ,displayed-img-width))))))
=A0 =A0 =A0(overlay-put ol 'display
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (cond
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(image
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (if slice
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (list (cons 'slice slic= e) image)
- =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 image))
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0image))
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0;; We're trying to display a pag= e that doesn't exist.
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(doc-view-current-converter-processe= s
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 ;; Maybe the page doesn't exist= *yet*.
--8<---------------cut here---------------end--------------->8---

> =A0Ideally I'd also center vertically (should the image be shorter= than
> the window)

I think vertical centering is a bit more tricky since there's not= hing
like :align-to or vertically stretchable spaces...

Bye,
Tassilo

--20cf3074b16af4e40e04d757359f-- From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 07 10:56:36 2013 Received: (at 13887) by debbugs.gnu.org; 7 Mar 2013 15:56:36 +0000 Received: from localhost ([127.0.0.1]:36730 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDdBK-0004AD-Pg for submit@debbugs.gnu.org; Thu, 07 Mar 2013 10:56:36 -0500 Received: from deliver.uni-koblenz.de ([141.26.64.15]:33264) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDdBG-0004A1-V8 for 13887@debbugs.gnu.org; Thu, 07 Mar 2013 10:56:32 -0500 Received: from localhost (localhost [127.0.0.1]) by deliver.uni-koblenz.de (Postfix) with ESMTP id D8B2E1A84A6; Thu, 7 Mar 2013 16:55:57 +0100 (CET) X-Virus-Scanned: amavisd-new at uni-koblenz.de Received: from deliver.uni-koblenz.de ([127.0.0.1]) by localhost (deliver.uni-koblenz.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id aEJdGFAWcWY6; Thu, 7 Mar 2013 16:55:57 +0100 (CET) X-CHKRCPT: Envelopesender noch tsdh@gnu.org Received: from thinkpad.tsdh.de (tsdh.uni-koblenz.de [141.26.67.142]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by deliver.uni-koblenz.de (Postfix) with ESMTPSA id 6743A1A84A5; Thu, 7 Mar 2013 16:55:57 +0100 (CET) From: Tassilo Horn To: E Sabof Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> Date: Thu, 07 Mar 2013 16:55:52 +0100 In-Reply-To: (E. Sabof's message of "Thu, 7 Mar 2013 15:17:54 +0000") Message-ID: <87txonw6ev.fsf@thinkpad.tsdh.de> User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.1 (--) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.5 (---) E Sabof writes: > I had a look at it, there are some issues with zooming. It doesn't > work when I open a document that is larger than the window, Does that mean that you'd like to set the hscoll when the window is smaller than the images so that the center of the image is displayed at the center of the window? Hm, this could at least be done once when initially opening some document. When switching pages, the current hscroll is preserved and I consider that a good thing. It shouldn't re-center then. > and sometimes in other cases. I know there were some issues/errors when the image of a page isn't there already. That should be fixed by this version of the patch. --8<---------------cut here---------------start------------->8--- === modified file 'lisp/doc-view.el' --- lisp/doc-view.el 2013-02-28 04:02:36 +0000 +++ lisp/doc-view.el 2013-03-07 08:14:09 +0000 @@ -1250,7 +1250,7 @@ (when doc-view-pending-cache-flush (clear-image-cache) (setq doc-view-pending-cache-flush nil)) - (let ((ol (doc-view-current-overlay)) + (let* ((ol (doc-view-current-overlay)) (image (if (and file (file-readable-p file)) (if (not (and doc-view-scale-internally (fboundp 'imagemagick-types))) @@ -1258,9 +1258,20 @@ (unless (member :width args) (setq args `(,@args :width ,doc-view-image-width))) (apply 'create-image file 'imagemagick nil args)))) - (slice (doc-view-current-slice))) + (slice (doc-view-current-slice)) + (img-width (and image (car (image-size image)))) + (displayed-img-width (if (and image slice) + (* (/ (float (nth 2 slice)) + (car (image-size image 'pixels))) + img-width) + img-width)) + (window-width (window-width (selected-window)))) (setf (doc-view-current-image) image) (move-overlay ol (point-min) (point-max)) + (when (and image (> window-width displayed-img-width)) + (overlay-put ol 'before-string + (propertize " " 'display + `(space :align-to (+ center (-0.5 . ,displayed-img-width)))))) (overlay-put ol 'display (cond (image --8<---------------cut here---------------end--------------->8--- Bye, Tassilo From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 07 11:16:40 2013 Received: (at 13887) by debbugs.gnu.org; 7 Mar 2013 16:16:40 +0000 Received: from localhost ([127.0.0.1]:36756 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDdUk-0004c2-0J for submit@debbugs.gnu.org; Thu, 07 Mar 2013 11:16:39 -0500 Received: from mail-qe0-f42.google.com ([209.85.128.42]:59920) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDdUg-0004bh-9F for 13887@debbugs.gnu.org; Thu, 07 Mar 2013 11:16:36 -0500 Received: by mail-qe0-f42.google.com with SMTP id f6so379432qej.29 for <13887@debbugs.gnu.org>; Thu, 07 Mar 2013 08:15:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=XqqvVNIs+pO41alazNef7Mb1xzJihjuFvAmkvroDiT8=; b=zvBsWuqu3FL+tnzs7/6/6BG7Dmd0aXbDT/lFa537DfGSvOtdi9FtQlN8QwKy5hT4OS 7CpSGYBnprRTg2dQFD43ieLPGGBfQkbR9SnaMx0QaX3/1RFzwANxCucRtqC2hN91ObvE ZS+KT8lDBfhO2mp2Q0dlftsikJ+8rPFdBschXYcgeuxiiX5AXhB+Uibs1vV/gQKRW3V1 u3WFjFBZHoK9WNDm3bHBfoFV3BciY3LDy/Bn4mIdZDK0v3VTHd8zsNcMRHGBcR8DA6mv k1wEyMqTuiN2GQWAChR08B8MtcVRMnTZB7h4uKDkFbLJAuYHMXxzjlZ7TyI69BQ0XKlC JfvQ== MIME-Version: 1.0 X-Received: by 10.224.117.66 with SMTP id p2mr8199872qaq.45.1362672955791; Thu, 07 Mar 2013 08:15:55 -0800 (PST) Received: by 10.49.70.233 with HTTP; Thu, 7 Mar 2013 08:15:55 -0800 (PST) In-Reply-To: <87txonw6ev.fsf@thinkpad.tsdh.de> References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> Date: Thu, 7 Mar 2013 16:15:55 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Tassilo Horn Content-Type: multipart/alternative; boundary=20cf3074b47279a09a04d75805aa X-Spam-Score: -2.6 (--) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --20cf3074b47279a09a04d75805aa Content-Type: text/plain; charset=ISO-8859-1 I mean pressing + or - moves the page horizontally, instead of changing the size. I think the way it opens the document is ok. I'll have a look at the patch and let you know. Evgeni On Thu, Mar 7, 2013 at 3:55 PM, Tassilo Horn wrote: > E Sabof writes: > > > I had a look at it, there are some issues with zooming. It doesn't > > work when I open a document that is larger than the window, > > Does that mean that you'd like to set the hscoll when the window is > smaller than the images so that the center of the image is displayed at > the center of the window? > > Hm, this could at least be done once when initially opening some > document. When switching pages, the current hscroll is preserved and I > consider that a good thing. It shouldn't re-center then. > > > and sometimes in other cases. > > I know there were some issues/errors when the image of a page isn't > there already. That should be fixed by this version of the patch. > > --8<---------------cut here---------------start------------->8--- > === modified file 'lisp/doc-view.el' > --- lisp/doc-view.el 2013-02-28 04:02:36 +0000 > +++ lisp/doc-view.el 2013-03-07 08:14:09 +0000 > @@ -1250,7 +1250,7 @@ > (when doc-view-pending-cache-flush > (clear-image-cache) > (setq doc-view-pending-cache-flush nil)) > - (let ((ol (doc-view-current-overlay)) > + (let* ((ol (doc-view-current-overlay)) > (image (if (and file (file-readable-p file)) > (if (not (and doc-view-scale-internally > (fboundp 'imagemagick-types))) > @@ -1258,9 +1258,20 @@ > (unless (member :width args) > (setq args `(,@args :width ,doc-view-image-width))) > (apply 'create-image file 'imagemagick nil args)))) > - (slice (doc-view-current-slice))) > + (slice (doc-view-current-slice)) > + (img-width (and image (car (image-size image)))) > + (displayed-img-width (if (and image slice) > + (* (/ (float (nth 2 slice)) > + (car (image-size image 'pixels))) > + img-width) > + img-width)) > + (window-width (window-width (selected-window)))) > (setf (doc-view-current-image) image) > (move-overlay ol (point-min) (point-max)) > + (when (and image (> window-width displayed-img-width)) > + (overlay-put ol 'before-string > + (propertize " " 'display > + `(space :align-to (+ center (-0.5 . > ,displayed-img-width)))))) > (overlay-put ol 'display > (cond > (image > --8<---------------cut here---------------end--------------->8--- > > Bye, > Tassilo > --20cf3074b47279a09a04d75805aa Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
I mean pressing + or - moves the page horizontally, instea= d of changing the size. I think the way it opens the document is ok.
I'll have a look at the patch and let you know.

Evgeni


On Thu, Mar 7, 2013 at 3:55 PM, Tassil= o Horn <tsdh@gnu.org> wrote:
E Sabof <esabof@gmail.com> writes:

> I had a look at it, there are some issues with zooming. It doesn't=
> work when I open a document that is larger than the window,

Does that mean that you'd like to set the hscoll when the window = is
smaller than the images so that the center of the image is displayed at
the center of the window?

Hm, this could at least be done once when initially opening some
document. =A0When switching pages, the current hscroll is preserved and I consider that a good thing. =A0It shouldn't re-center then.

> and sometimes in other cases.

I know there were some issues/errors when the image of a page isn'= ;t
there already. =A0That should be fixed by this version of the patch.

--8<---------------cut here---------------start------------->8---
=3D=3D=3D modified file 'lisp/doc-view.el'
--- lisp/doc-view.el =A0 =A02013-02-28 04:02:36 +0000
+++ lisp/doc-view.el =A0 =A02013-03-07 08:14:09 +0000
@@ -1250,7 +1250,7 @@
=A0 =A0(when doc-view-pending-cache-flush
=A0 =A0 =A0(clear-image-cache)
=A0 =A0 =A0(setq doc-view-pending-cache-flush nil))
- =A0(let ((ol (doc-view-current-overlay))
+ =A0(let* ((ol (doc-view-current-overlay))
=A0 =A0 =A0 =A0 =A0(image (if (and file (file-readable-p = file))
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(if (not (and doc-view-scale-i= nternally
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (fbound= p 'imagemagick-types)))
@@ -1258,9 +1258,20 @@
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(unless (member :width args)
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(setq args= `(,@args :width ,doc-view-image-width)))
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(apply &= #39;create-image file 'imagemagick nil args))))
- =A0 =A0 =A0 =A0(slice (doc-view-current-slice)))
+ =A0 =A0 =A0 =A0(slice (doc-view-current-slice))
+ =A0 =A0 =A0 =A0(img-width (and image (car (image-size image))))
+ =A0 =A0 =A0 =A0(displayed-img-width (if (and image slice)
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0= =A0 =A0 (* (/ (float (nth 2 slice))
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 (car (image-size image 'pixels)))
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0im= g-width)
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 img-width)) + =A0 =A0 =A0 =A0(window-width (window-width (selected-window))))
=A0 =A0 =A0(setf (doc-view-current-image) image)
=A0 =A0 =A0(move-overlay ol (point-min) (point-max))
+ =A0 =A0(when (and image (> window-width displayed-img-width))
+ =A0 =A0 =A0(overlay-put ol 'before-string
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(propertize " " 'display=
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0`(space :align= -to (+ center (-0.5 . ,displayed-img-width))))))
=A0 =A0 =A0(overlay-put ol 'display
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (cond
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(image
--8<---------------cut here---------------end--------------->8-= --

Bye,
Tassilo

--20cf3074b47279a09a04d75805aa-- From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 07 17:58:41 2013 Received: (at 13887) by debbugs.gnu.org; 7 Mar 2013 22:58:41 +0000 Received: from localhost ([127.0.0.1]:37334 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDjlo-000793-Tx for submit@debbugs.gnu.org; Thu, 07 Mar 2013 17:58:41 -0500 Received: from mail-qc0-f182.google.com ([209.85.216.182]:49003) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDjll-00078q-Lt for 13887@debbugs.gnu.org; Thu, 07 Mar 2013 17:58:38 -0500 Received: by mail-qc0-f182.google.com with SMTP id k19so342363qcs.41 for <13887@debbugs.gnu.org>; Thu, 07 Mar 2013 14:57:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=ria/GsUdCs3/0i/ELy1CQICBMaS03nWNvrAUUCW++q0=; b=VY7IVc27Pf8aUHKBztOANcUER4UKqgPcKW1KfFXXVeaCByIg6Apk9Laocgi3gSNE4t /Mlde/NHFljlipkOpM2YYWCwEAaqNzsxo3UMRVDdQKxMQx/gFR3uxsmqelJLSrC83KyE pbBQBIXV0dK0i1K56+bYunBMzDe5TByz5DjVB09r/WNvUtaAPXJQnLPReFYRxSPGsFYe GWrEeZIabr5SA/yjuw5uAR+lED8otxXYrKqhr7yqUt0Vtmz41QpmFrFj89vg4Lh1ZQF7 yZtX5B7p5b8HARRyK7FobFGCQm+2YoGksGSyXhviBSV14SpjZBjAweyaxw+qtDHHiOlo P2YA== MIME-Version: 1.0 X-Received: by 10.49.132.72 with SMTP id os8mr10087577qeb.52.1362697078304; Thu, 07 Mar 2013 14:57:58 -0800 (PST) Received: by 10.49.70.233 with HTTP; Thu, 7 Mar 2013 14:57:58 -0800 (PST) In-Reply-To: References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> Date: Thu, 7 Mar 2013 22:57:58 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Tassilo Horn Content-Type: multipart/alternative; boundary=047d7bdca91a49f5ac04d75da397 X-Spam-Score: -2.6 (--) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --047d7bdca91a49f5ac04d75da397 Content-Type: text/plain; charset=ISO-8859-1 Couldn't tell the difference to be honest. Evgeni On Thu, Mar 7, 2013 at 4:15 PM, E Sabof wrote: > I mean pressing + or - moves the page horizontally, instead of changing > the size. I think the way it opens the document is ok. > > I'll have a look at the patch and let you know. > > Evgeni > > > On Thu, Mar 7, 2013 at 3:55 PM, Tassilo Horn wrote: > >> E Sabof writes: >> >> > I had a look at it, there are some issues with zooming. It doesn't >> > work when I open a document that is larger than the window, >> >> Does that mean that you'd like to set the hscoll when the window is >> smaller than the images so that the center of the image is displayed at >> the center of the window? >> >> Hm, this could at least be done once when initially opening some >> document. When switching pages, the current hscroll is preserved and I >> consider that a good thing. It shouldn't re-center then. >> >> > and sometimes in other cases. >> >> I know there were some issues/errors when the image of a page isn't >> there already. That should be fixed by this version of the patch. >> >> --8<---------------cut here---------------start------------->8--- >> === modified file 'lisp/doc-view.el' >> --- lisp/doc-view.el 2013-02-28 04:02:36 +0000 >> +++ lisp/doc-view.el 2013-03-07 08:14:09 +0000 >> @@ -1250,7 +1250,7 @@ >> (when doc-view-pending-cache-flush >> (clear-image-cache) >> (setq doc-view-pending-cache-flush nil)) >> - (let ((ol (doc-view-current-overlay)) >> + (let* ((ol (doc-view-current-overlay)) >> (image (if (and file (file-readable-p file)) >> (if (not (and doc-view-scale-internally >> (fboundp 'imagemagick-types))) >> @@ -1258,9 +1258,20 @@ >> (unless (member :width args) >> (setq args `(,@args :width ,doc-view-image-width))) >> (apply 'create-image file 'imagemagick nil args)))) >> - (slice (doc-view-current-slice))) >> + (slice (doc-view-current-slice)) >> + (img-width (and image (car (image-size image)))) >> + (displayed-img-width (if (and image slice) >> + (* (/ (float (nth 2 slice)) >> + (car (image-size image 'pixels))) >> + img-width) >> + img-width)) >> + (window-width (window-width (selected-window)))) >> (setf (doc-view-current-image) image) >> (move-overlay ol (point-min) (point-max)) >> + (when (and image (> window-width displayed-img-width)) >> + (overlay-put ol 'before-string >> + (propertize " " 'display >> + `(space :align-to (+ center (-0.5 . >> ,displayed-img-width)))))) >> (overlay-put ol 'display >> (cond >> (image >> --8<---------------cut here---------------end--------------->8--- >> >> Bye, >> Tassilo >> > > --047d7bdca91a49f5ac04d75da397 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Couldn't tell the difference to be honest.

Evgeni


On Thu, Mar 7, 2013 at 4:15 PM, E Sabof <esabof@gmail.com> wr= ote:
I mean pressing + or - moves the page horizontally, instea= d of changing the size. I think the way it opens the document is ok.
I'll have a look at the patch and let you know.

Evgeni


On Thu, Ma= r 7, 2013 at 3:55 PM, Tassilo Horn <tsdh@gnu.org> wrote:
E Sabof <esabof@gmail.com> writes:

> I had a look at it, there are some issues with zooming. It doesn't=
> work when I open a document that is larger than the window,

Does that mean that you'd like to set the hscoll when the window = is
smaller than the images so that the center of the image is displayed at
the center of the window?

Hm, this could at least be done once when initially opening some
document. =A0When switching pages, the current hscroll is preserved and I consider that a good thing. =A0It shouldn't re-center then.

> and sometimes in other cases.

I know there were some issues/errors when the image of a page isn'= ;t
there already. =A0That should be fixed by this version of the patch.

--8<---------------cut here---------------start------------->8---
=3D=3D=3D modified file 'lisp/doc-view.el'
--- lisp/doc-view.el =A0 =A02013-02-28 04:02:36 +0000
+++ lisp/doc-view.el =A0 =A02013-03-07 08:14:09 +0000
@@ -1250,7 +1250,7 @@
=A0 =A0(when doc-view-pending-cache-flush
=A0 =A0 =A0(clear-image-cache)
=A0 =A0 =A0(setq doc-view-pending-cache-flush nil))
- =A0(let ((ol (doc-view-current-overlay))
+ =A0(let* ((ol (doc-view-current-overlay))
=A0 =A0 =A0 =A0 =A0(image (if (and file (file-readable-p file))
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(if (not (and doc-view-scale-i= nternally
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (fbound= p 'imagemagick-types)))
@@ -1258,9 +1258,20 @@
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(unless (member :width args)
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(setq args `(,@args :wi= dth ,doc-view-image-width)))
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(apply 'create-im= age file 'imagemagick nil args))))
- =A0 =A0 =A0 =A0(slice (doc-view-current-slice)))
+ =A0 =A0 =A0 =A0(slice (doc-view-current-slice))
+ =A0 =A0 =A0 =A0(img-width (and image (car (image-size image))))
+ =A0 =A0 =A0 =A0(displayed-img-width (if (and image slice)
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (* (= / (float (nth 2 slice))
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 (car (image-size image 'pixels)))
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0im= g-width)
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 img-width)) + =A0 =A0 =A0 =A0(window-width (window-width (selected-window))))
=A0 =A0 =A0(setf (doc-view-current-image) image)
=A0 =A0 =A0(move-overlay ol (point-min) (point-max))
+ =A0 =A0(when (and image (> window-width displayed-img-width))
+ =A0 =A0 =A0(overlay-put ol 'before-string
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(propertize " " 'display=
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0`(space :align= -to (+ center (-0.5 . ,displayed-img-width))))))
=A0 =A0 =A0(overlay-put ol 'display
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (cond
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(image
--8<---------------cut here---------------end--------------->8-= --

Bye,
Tassilo


--047d7bdca91a49f5ac04d75da397-- From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 08 02:58:16 2013 Received: (at 13887) by debbugs.gnu.org; 8 Mar 2013 07:58:16 +0000 Received: from localhost ([127.0.0.1]:38037 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDsBz-0005IF-Ft for submit@debbugs.gnu.org; Fri, 08 Mar 2013 02:58:16 -0500 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:37595) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDsBw-0005I7-Ac for 13887@debbugs.gnu.org; Fri, 08 Mar 2013 02:58:13 -0500 Received: from compute1.internal (compute1.nyi.mail.srv.osa [10.202.2.41]) by gateway1.nyi.mail.srv.osa (Postfix) with ESMTP id B7D5B20A7A; Fri, 8 Mar 2013 02:57:35 -0500 (EST) Received: from frontend2.nyi.mail.srv.osa ([10.202.2.161]) by compute1.internal (MEProxy); Fri, 08 Mar 2013 02:57:35 -0500 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=from:to:cc:subject:references:date :in-reply-to:message-id:mime-version:content-type; s=smtpout; bh=F71Nlp0+xYx5W0KjQRNKmY/Mmus=; b=LdxL7qGbb0szgw7WonkIiRjFBNf3 wMudgPWzQ3FFAPUpeFqvwOOPjeH5HwBTYV3ZnFwONnwihPL9RkDVhCRiS0288Ozi dZqWHuRYAPPcDw2tFvahyuKCLeDRSpWcS8We/o9zrwPVrHq6sc877KRUpFlp2ify UV7Dj5f4KVZhUZI= X-Sasl-enc: btpX+a18j7MNZTamxLjYcahgEUTdaN0Lv+vzHshu0gQu 1362729455 Received: from thinkpad.tsdh.de (unknown [91.67.10.84]) by mail.messagingengine.com (Postfix) with ESMTPA id 27E6D2010FF; Fri, 8 Mar 2013 02:57:35 -0500 (EST) From: Tassilo Horn To: E Sabof Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> Date: Fri, 08 Mar 2013 08:57:29 +0100 In-Reply-To: (E. Sabof's message of "Thu, 7 Mar 2013 22:57:58 +0000") Message-ID: <87sj46493q.fsf@thinkpad.tsdh.de> User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) E Sabof writes: >> I mean pressing + or - moves the page horizontally, instead of >> changing the size. I think the way it opens the document is ok. Strange, I can't reproduce that here. Do you have a recipe? > Couldn't tell the difference to be honest. The difference between what? The old and the new patch? Bye, Tassilo From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 09 02:25:56 2013 Received: (at 13887) by debbugs.gnu.org; 9 Mar 2013 07:25:56 +0000 Received: from localhost ([127.0.0.1]:40683 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UEEAG-0000Nj-3l for submit@debbugs.gnu.org; Sat, 09 Mar 2013 02:25:56 -0500 Received: from mail-qa0-f48.google.com ([209.85.216.48]:57611) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UEEAC-0000NV-3F for 13887@debbugs.gnu.org; Sat, 09 Mar 2013 02:25:54 -0500 Received: by mail-qa0-f48.google.com with SMTP id j8so190023qah.0 for <13887@debbugs.gnu.org>; Fri, 08 Mar 2013 23:25:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:content-type; bh=m9ZpMq6/5028PpcnXE4XvqF9h1pxlxfbC/jsqFdJafw=; b=kHpWlJbQv6+/9MiptFNApfQDaff9NhT9+ji9hdVhBbv/Lo54Wi5GcoRTkG+6tI2n1f KFvKW+orqka3DCyf7INSInpkzmK5ySMxyCrxqX4BUKneBBmEWg2wsP7vxZ6Us7qF7FhG P0anQwlUPcQP8q4amw0xDGk3NXIqqRApgQqZQT0Vo9ynuq+bNdeBUjkbnit5PFKpQOvC KhLYo5pKVgBoKn0WV5Sr2vj8/a14HlSrqePl1ZIq1ktrhQ6qN6Go1fdcLmR5xLaQZDrV TRuQFC7Pt0vDvJENKvtIA6XkFpYfUIZVd+ICMT54Jy4QqWv0LDhSr+iODeCQ7mVh5Sn3 VJpw== MIME-Version: 1.0 X-Received: by 10.224.108.4 with SMTP id d4mr7705316qap.83.1362813905027; Fri, 08 Mar 2013 23:25:05 -0800 (PST) Received: by 10.49.70.233 with HTTP; Fri, 8 Mar 2013 23:25:04 -0800 (PST) In-Reply-To: References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> Date: Sat, 9 Mar 2013 07:25:04 +0000 Message-ID: Subject: Fwd: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: 13887@debbugs.gnu.org Content-Type: multipart/alternative; boundary=20cf3074b16ab51f2804d778d639 X-Spam-Score: 0.1 (/) X-Debbugs-Envelope-To: 13887 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --20cf3074b16ab51f2804d778d639 Content-Type: text/plain; charset=ISO-8859-1 ---------- Forwarded message ---------- From: E Sabof Date: Sat, Mar 9, 2013 at 7:21 AM Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available To: Tassilo Horn Strange, I can't reproduce that here. Do you have a recipe? > Can't really give you a recipe - re-sizing just seems very fragile. A possible source might be this: running M-: (overlays-at 1) usually returns 2 overlays. This is also true for the stable version. The difference between what? The old and the new patch? > Yes Evgeni --20cf3074b16ab51f2804d778d639 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable


---------- Forwarded me= ssage ----------
From: E Sabof <esabof@gmail.com>=
Date: Sat, Mar 9, 2013 at 7:21 AM
Subject: Re: bug#13887: 24.3; doc-view= will render blurry images when image-magick is available
To: Tassilo Ho= rn <tsdh@gnu.org>


Strange, I can't reproduce tha= t here. =A0Do you have a recipe?
=A0
Can't really give you a=A0recipe=A0-=A0re-sizing=A0= just seems very fragile. A possible source might be this: running M-: (over= lays-at 1) usually returns 2=A0overlays. This is also true for the stable v= ersion.

The difference between what? =A0The old and= the new patch?
=A0
Yes=A0

Evgen= i

--20cf3074b16ab51f2804d778d639-- From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 09 02:27:20 2013 Received: (at 13887) by debbugs.gnu.org; 9 Mar 2013 07:27:20 +0000 Received: from localhost ([127.0.0.1]:40687 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UEEBZ-0000Px-Pi for submit@debbugs.gnu.org; Sat, 09 Mar 2013 02:27:19 -0500 Received: from mail-qa0-f45.google.com ([209.85.216.45]:49819) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UEEBX-0000Pi-BF for 13887@debbugs.gnu.org; Sat, 09 Mar 2013 02:27:16 -0500 Received: by mail-qa0-f45.google.com with SMTP id g10so184618qah.18 for <13887@debbugs.gnu.org>; Fri, 08 Mar 2013 23:26:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:content-type; bh=61RVDDVs0R54DLuF5KZLhXbD7oAp52gfRblXdc1hOfk=; b=HGsPJJ0A/71BLAcmDlOgbojLkW6vsRkws3JS6J8Ukas//+cVn4Y5DzNmuf08jHByK3 3mMZoF+qE4GM3+NcBp4tS6covAU4c8VSNQqv12FbSMrN2S4ir2kffLD4QymfYjCjfDX3 gPcFE4v6yZZtf3DGuEUEnaT5hoBEj4ss5PkSdJKLSBOkL8owPS9nBg5Qu9lTqvSo/FlS UWiPhsw4wyHYD/rCU9sP33QjoiWGnvWrCpwOmRNgLQ2xCwBWDVl/iZl0lymCGLoY8Ay0 jMJcbliTBaXAAmnxA0Rwai2bnsHvYXf6544fHgEF4wmXvTcxjSzGVuj/bDLWa1Jo5VmW MwOw== MIME-Version: 1.0 X-Received: by 10.229.104.10 with SMTP id m10mr1639942qco.137.1362813988479; Fri, 08 Mar 2013 23:26:28 -0800 (PST) Received: by 10.49.70.233 with HTTP; Fri, 8 Mar 2013 23:26:28 -0800 (PST) In-Reply-To: References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> Date: Sat, 9 Mar 2013 07:26:28 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: 13887@debbugs.gnu.org, Tassilo Horn Content-Type: multipart/alternative; boundary=001517511db8ae12a804d778db22 X-Spam-Score: 0.1 (/) X-Debbugs-Envelope-To: 13887 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --001517511db8ae12a804d778db22 Content-Type: text/plain; charset=ISO-8859-1 A relevant point might be that I usually start doc-view from "dired-find-file" Evgeni --001517511db8ae12a804d778db22 Content-Type: text/html; charset=ISO-8859-1
A relevant point might be that I usually start doc-view from "dired-find-file"

Evgeni
--001517511db8ae12a804d778db22-- From debbugs-submit-bounces@debbugs.gnu.org Mon Mar 11 05:12:27 2013 Received: (at 13887) by debbugs.gnu.org; 11 Mar 2013 09:12:27 +0000 Received: from localhost ([127.0.0.1]:45321 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UEymR-0007Tj-Bv for submit@debbugs.gnu.org; Mon, 11 Mar 2013 05:12:27 -0400 Received: from deliver.uni-koblenz.de ([141.26.64.15]:48608) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UEymN-0007Tb-UO for 13887@debbugs.gnu.org; Mon, 11 Mar 2013 05:12:26 -0400 Received: from localhost (localhost [127.0.0.1]) by deliver.uni-koblenz.de (Postfix) with ESMTP id C200F1A8799; Mon, 11 Mar 2013 10:11:29 +0100 (CET) X-Virus-Scanned: amavisd-new at uni-koblenz.de Received: from deliver.uni-koblenz.de ([127.0.0.1]) by localhost (deliver.uni-koblenz.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id FV99Xj6nF_Kg; Mon, 11 Mar 2013 10:11:29 +0100 (CET) X-CHKRCPT: Envelopesender noch tsdh@gnu.org Received: from thinkpad.tsdh.de (tsdh.uni-koblenz.de [141.26.67.142]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by deliver.uni-koblenz.de (Postfix) with ESMTPSA id 4B4CB1A8798; Mon, 11 Mar 2013 10:11:29 +0100 (CET) From: Tassilo Horn To: E Sabof , Stefan Monnier Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> Date: Mon, 11 Mar 2013 10:11:28 +0100 In-Reply-To: (E. Sabof's message of "Sat, 9 Mar 2013 07:26:28 +0000") Message-ID: <877gle1etb.fsf@thinkpad.tsdh.de> User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -3.5 (---) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.5 (---) E Sabof writes: > A relevant point might be that I usually start doc-view from > "dired-find-file" No, that seems unrelated. >>> [Image seems to be moved only when zooming with my centering patch.] >> >> Strange, I can't reproduce that here. Do you have a recipe? > > Can't really give you a recipe - re-sizing just seems very fragile. A > possible source might be this: running M-: (overlays-at 1) usually > returns 2 overlays. This is also true for the stable version. Hm, indeed. I can reproduce that with emacs -Q. Sometimes I have 2 overlays, sometimes even three. Right now, using emacs-bzr-version "eliz@gnu.org-20130305181225-20nu9zkyby8jw21e", $ emacs -Q some.pdf will show some.pdf, and (overlays-at 1) returns 2 overlays. Also, when switching pages, the mode-line indicator is updated but I still see the old page. It won't refresh at all. Ditto for zooming or anything that would change the display. Aha, now I know how to reproduce that (also with the emacs with my customizations and the centering patch). Somehow, `doc-view-new-window-function' is run way too often (I've commented in the (message ...) in its first line to see). When opening some document, it's run twice. When the document is shown, M-x will also run it again. Ditto for M-: (i) id 1UF63c-0002uB-81 for submit@debbugs.gnu.org; Mon, 11 Mar 2013 12:58:40 -0400 Received: from mtaout22.012.net.il ([80.179.55.172]:42064) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UF63Z-0002tx-Vp for 13887@debbugs.gnu.org; Mon, 11 Mar 2013 12:58:39 -0400 Received: from conversion-daemon.a-mtaout22.012.net.il by a-mtaout22.012.net.il (HyperSendmail v2007.08) id <0MJI00E009RU2F00@a-mtaout22.012.net.il> for 13887@debbugs.gnu.org; Mon, 11 Mar 2013 18:57:35 +0200 (IST) Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout22.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MJI00D629RYM1D0@a-mtaout22.012.net.il>; Mon, 11 Mar 2013 18:57:34 +0200 (IST) Date: Mon, 11 Mar 2013 18:57:28 +0200 From: Eli Zaretskii Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available In-reply-to: <877gle1etb.fsf@thinkpad.tsdh.de> X-012-Sender: halo1@inter.net.il To: Tassilo Horn Message-id: <838v5tx4av.fsf@gnu.org> References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> X-Spam-Score: -1.2 (-) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, esabof@gmail.com, monnier@iro.umontreal.ca X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list Reply-To: Eli Zaretskii List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.2 (-) > From: Tassilo Horn > Date: Mon, 11 Mar 2013 10:11:28 +0100 > Cc: 13887@debbugs.gnu.org > > Aha, now I know how to reproduce that (also with the emacs with my > customizations and the centering patch). Somehow, > `doc-view-new-window-function' is run way too often (I've commented in > the (message ...) in its first line to see). When opening some > document, it's run twice. When the document is shown, M-x will > also run it again. Ditto for M-: (i) id 1UF7M4-0005ku-9r for submit@debbugs.gnu.org; Mon, 11 Mar 2013 14:21:48 -0400 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:40506) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UF7M1-0005km-H0 for 13887@debbugs.gnu.org; Mon, 11 Mar 2013 14:21:46 -0400 Received: from compute5.internal (compute5.nyi.mail.srv.osa [10.202.2.45]) by gateway1.nyi.mail.srv.osa (Postfix) with ESMTP id 92B4520E81; Mon, 11 Mar 2013 14:20:49 -0400 (EDT) Received: from frontend1.nyi.mail.srv.osa ([10.202.2.160]) by compute5.internal (MEProxy); Mon, 11 Mar 2013 14:20:49 -0400 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=from:to:cc:subject:references:date :in-reply-to:message-id:mime-version:content-type; s=smtpout; bh=tF3I76d0S9lrNHxBW1s1pAuJuI8=; b=ppG1LtEeMz1C7k0qFXB4VTMRByQz NFTWS1CAobgXjm88YBZ4zJHk370xXyH7UX1RMX4AxozgKXq4NleI8jh/pZs72v1j GxB5e+q9hCtKs0/FFJ2zQ2MFKy6sqhfcNYiZ8v8KKexgB8CIsWhyckkIGqvYWbCE 4/cnBRWtVfLoZL4= X-Sasl-enc: IfafEej2cYq/zGD487EhRIGTRdPXjUdIm56UyAn/X6aA 1363026049 Received: from thinkpad.tsdh.de (unknown [91.67.10.84]) by mail.messagingengine.com (Postfix) with ESMTPA id CBCA5C80E90; Mon, 11 Mar 2013 14:20:48 -0400 (EDT) From: Tassilo Horn To: Eli Zaretskii Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> Date: Mon, 11 Mar 2013 19:20:47 +0100 In-Reply-To: <838v5tx4av.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 11 Mar 2013 18:57:28 +0200") Message-ID: <87txohx0g0.fsf@thinkpad.tsdh.de> User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, esabof@gmail.com, monnier@iro.umontreal.ca X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) Eli Zaretskii writes: >> Aha, now I know how to reproduce that (also with the emacs with my >> customizations and the centering patch). Somehow, >> `doc-view-new-window-function' is run way too often (I've commented >> in the (message ...) in its first line to see). When opening some >> document, it's run twice. When the document is shown, M-x will >> also run it again. Ditto for M-: (i > doc-view-new-window-function seems to be run from a > window-configuration-change-hook, right? No, from `image-mode-new-window-functions'. The functions in there are run by `image-mode-winprops' if (and only if) there are no winprops set for the image and the current window. Basically, this should only ever happen when there's a new window showing the buffer with the image. Bye, Tassilo From debbugs-submit-bounces@debbugs.gnu.org Mon Mar 11 14:47:23 2013 Received: (at 13887) by debbugs.gnu.org; 11 Mar 2013 18:47:23 +0000 Received: from localhost ([127.0.0.1]:46738 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UF7ko-0006NN-WC for submit@debbugs.gnu.org; Mon, 11 Mar 2013 14:47:23 -0400 Received: from mtaout21.012.net.il ([80.179.55.169]:57827) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UF7kl-0006N9-Gx for 13887@debbugs.gnu.org; Mon, 11 Mar 2013 14:47:21 -0400 Received: from conversion-daemon.a-mtaout21.012.net.il by a-mtaout21.012.net.il (HyperSendmail v2007.08) id <0MJI00E00ES9EG00@a-mtaout21.012.net.il> for 13887@debbugs.gnu.org; Mon, 11 Mar 2013 20:45:45 +0200 (IST) Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout21.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MJI00EG7ES9AD80@a-mtaout21.012.net.il>; Mon, 11 Mar 2013 20:45:45 +0200 (IST) Date: Mon, 11 Mar 2013 20:45:39 +0200 From: Eli Zaretskii Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available In-reply-to: <87txohx0g0.fsf@thinkpad.tsdh.de> X-012-Sender: halo1@inter.net.il To: Tassilo Horn Message-id: <831ubllqr0.fsf@gnu.org> References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> X-Spam-Score: -1.2 (-) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, esabof@gmail.com, monnier@iro.umontreal.ca X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list Reply-To: Eli Zaretskii List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.2 (-) > From: Tassilo Horn > Cc: esabof@gmail.com, monnier@iro.umontreal.ca, 13887@debbugs.gnu.org > Date: Mon, 11 Mar 2013 19:20:47 +0100 > > > doc-view-new-window-function seems to be run from a > > window-configuration-change-hook, right? > > No, from `image-mode-new-window-functions'. The functions in there are > run by `image-mode-winprops' if (and only if) there are no winprops set > for the image and the current window. Maybe I'm missing something, but in image-mode.el: . image-mode-winprops is called by image-mode-reapply-winprops . image-mode-reapply-winprops is added by image-mode-setup-winprops to window-configuration-change-hook Doesn't that mean what I said? > Basically, this should only ever happen when there's a new window > showing the buffer with the image. How's that ensured? Can you walk us through the relevant code? From debbugs-submit-bounces@debbugs.gnu.org Mon Mar 11 16:28:20 2013 Received: (at 13887) by debbugs.gnu.org; 11 Mar 2013 20:28:20 +0000 Received: from localhost ([127.0.0.1]:46845 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UF9KU-0000CY-W9 for submit@debbugs.gnu.org; Mon, 11 Mar 2013 16:28:19 -0400 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:52145) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UF9KR-0000CO-GG for 13887@debbugs.gnu.org; Mon, 11 Mar 2013 16:28:16 -0400 Received: from compute1.internal (compute1.nyi.mail.srv.osa [10.202.2.41]) by gateway1.nyi.mail.srv.osa (Postfix) with ESMTP id E7B6520E4D; Mon, 11 Mar 2013 16:27:18 -0400 (EDT) Received: from frontend2.nyi.mail.srv.osa ([10.202.2.161]) by compute1.internal (MEProxy); Mon, 11 Mar 2013 16:27:18 -0400 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=from:to:cc:subject:references:date :in-reply-to:message-id:mime-version:content-type; s=smtpout; bh=LopOLboUdVPsSX/3R5qWvrQrl3A=; b=IYf1wOhu8KYUiszEO4t9rsm5NRI+ rPY0QiRfjXZkdtg7a+3YNMm15KV6vwm7eCD84c7sqBWFkfksz3PmlrkL9mPHM3au qRezvbNcqdhf7ratOKpVugafd8d/wOpO1qXcigNNV/7f+3TkryTnrhneyK8viPcN oEqEFUI+874TPew= X-Sasl-enc: ceWn6FgvZE27SOQtr5ktILkZus9E9o2TQVNM5Vd/V+jH 1363033638 Received: from thinkpad.tsdh.de (unknown [91.67.10.84]) by mail.messagingengine.com (Postfix) with ESMTPA id 1D5AC20114F; Mon, 11 Mar 2013 16:27:17 -0400 (EDT) From: Tassilo Horn To: Eli Zaretskii Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> Date: Mon, 11 Mar 2013 21:27:16 +0100 In-Reply-To: <831ubllqr0.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 11 Mar 2013 20:45:39 +0200") Message-ID: <87zjy9vg0r.fsf@thinkpad.tsdh.de> User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, esabof@gmail.com, monnier@iro.umontreal.ca X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) Eli Zaretskii writes: >> From: Tassilo Horn >> Cc: esabof@gmail.com, monnier@iro.umontreal.ca, 13887@debbugs.gnu.org >> Date: Mon, 11 Mar 2013 19:20:47 +0100 >> >> > doc-view-new-window-function seems to be run from a >> > window-configuration-change-hook, right? >> >> No, from `image-mode-new-window-functions'. The functions in there >> are run by `image-mode-winprops' if (and only if) there are no >> winprops set for the image and the current window. > > Maybe I'm missing something, but in image-mode.el: > > . image-mode-winprops is called by image-mode-reapply-winprops > > . image-mode-reapply-winprops is added by image-mode-setup-winprops > to window-configuration-change-hook > > Doesn't that mean what I said? Nearly, except that `image-mode-new-window-functions' are only run when they don't have an entry in `image-mode-winprops-alist'. >> Basically, this should only ever happen when there's a new window >> showing the buffer with the image. > > How's that ensured? Can you walk us through the relevant code? That's line 72 in image-mode.el: (let ((winprops (assq window image-mode-winprops-alist))) ;; For new windows, set defaults from the latest. (unless winprops (setq winprops (cons window (copy-alist (cdar image-mode-winprops-alist)))) (run-hook-with-args 'image-mode-new-window-functions winprops)) However, whenever the doc-view window is split (e.g., when a completion buffer pops up), the doc-view buffer is indeed shown in a new window. That's why `doc-view-new-window-function' is run more often than I expected originally. That also explains why there are often multiple overlays in the doc-view buffer. There's one overlay per window that has shown the buffer at least once. This allows that you can have 2 windows displaying the same doc-view buffer: one showing page X, and in the other you can switch to other pages without changing the other window. So the multiple overlays thingy is actually intended. But somewhere the logic goes wonky and we're acting on the wrong overlay. Bye, Tassilo From debbugs-submit-bounces@debbugs.gnu.org Mon Mar 11 17:00:18 2013 Received: (at 13887) by debbugs.gnu.org; 11 Mar 2013 21:00:18 +0000 Received: from localhost ([127.0.0.1]:46899 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UF9pR-0000z3-Jf for submit@debbugs.gnu.org; Mon, 11 Mar 2013 17:00:18 -0400 Received: from mtaout20.012.net.il ([80.179.55.166]:55730) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UF9pO-0000yl-L8 for 13887@debbugs.gnu.org; Mon, 11 Mar 2013 17:00:15 -0400 Received: from conversion-daemon.a-mtaout20.012.net.il by a-mtaout20.012.net.il (HyperSendmail v2007.08) id <0MJI00M00KW6VS00@a-mtaout20.012.net.il> for 13887@debbugs.gnu.org; Mon, 11 Mar 2013 22:59:11 +0200 (IST) Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout20.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MJI00LLMKYNTTX0@a-mtaout20.012.net.il>; Mon, 11 Mar 2013 22:59:11 +0200 (IST) Date: Mon, 11 Mar 2013 22:59:05 +0200 From: Eli Zaretskii Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available In-reply-to: <87zjy9vg0r.fsf@thinkpad.tsdh.de> X-012-Sender: halo1@inter.net.il To: Tassilo Horn Message-id: <83y5dtk606.fsf@gnu.org> References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> X-Spam-Score: -1.2 (-) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, esabof@gmail.com, monnier@iro.umontreal.ca X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list Reply-To: Eli Zaretskii List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.2 (-) > From: Tassilo Horn > Cc: esabof@gmail.com, monnier@iro.umontreal.ca, 13887@debbugs.gnu.org > Date: Mon, 11 Mar 2013 21:27:16 +0100 > > So the multiple overlays thingy is actually intended. But somewhere the > logic goes wonky and we're acting on the wrong overlay. What is the "right" overlay? From debbugs-submit-bounces@debbugs.gnu.org Mon Mar 11 18:09:52 2013 Received: (at 13887) by debbugs.gnu.org; 11 Mar 2013 22:09:52 +0000 Received: from localhost ([127.0.0.1]:47005 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFAul-0003Tg-En for submit@debbugs.gnu.org; Mon, 11 Mar 2013 18:09:51 -0400 Received: from mail-qa0-f45.google.com ([209.85.216.45]:39600) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFAui-0003TH-5x for 13887@debbugs.gnu.org; Mon, 11 Mar 2013 18:09:49 -0400 Received: by mail-qa0-f45.google.com with SMTP id g10so1270537qah.11 for <13887@debbugs.gnu.org>; Mon, 11 Mar 2013 15:08:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=YHCk6053zZ3M1DuOnWzjCilbiuewxqiiisT5wCcTxv0=; b=TdkwkbWjF5ysMbs/IGK+1MCLJ2eLiIutt4Eox0L64dWjYe9P/tLQTA/Unkh3xiF+he ghqTFu2Vne3127zhKd1FKOGX4ljTcFNRZUCUdP1CT1v7h8y6QrynqWoREbwJyCWKAbs+ YkTVfQttvG3iyuir/7v2cgnFvcLDixVHLZeEu2JFsqoWVasRYZs/YopPyJzLvDChjyJa MLOypcfs3uv5ur45e9nuCErWCGBqn7To10muqfIzFsX75bPrRVHfT0RU4zmnCcm6GATW UNDCeLFEonk2EvxVGo14G4ylmgwMt52tfIjBVmrWD9Kjiw7ntI7RyzhK36jUvwtxCr5b lkmw== MIME-Version: 1.0 X-Received: by 10.49.117.106 with SMTP id kd10mr10694739qeb.25.1363039726527; Mon, 11 Mar 2013 15:08:46 -0700 (PDT) Received: by 10.49.70.233 with HTTP; Mon, 11 Mar 2013 15:08:46 -0700 (PDT) In-Reply-To: <83y5dtk606.fsf@gnu.org> References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> Date: Mon, 11 Mar 2013 22:08:46 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Eli Zaretskii Content-Type: multipart/alternative; boundary=047d7b6da42cb6ed6d04d7ad6a4e X-Spam-Score: -1.2 (-) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Stefan Monnier , Tassilo Horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --047d7b6da42cb6ed6d04d7ad6a4e Content-Type: text/plain; charset=ISO-8859-1 Apparently overlays have a "window" property, which when set, will display the overlay only in the relevant window. I've noticed however that sometimes it gets set to t. On Mon, Mar 11, 2013 at 8:59 PM, Eli Zaretskii wrote: > > From: Tassilo Horn > > Cc: esabof@gmail.com, monnier@iro.umontreal.ca, 13887@debbugs.gnu.org > > Date: Mon, 11 Mar 2013 21:27:16 +0100 > > > > So the multiple overlays thingy is actually intended. But somewhere the > > logic goes wonky and we're acting on the wrong overlay. > > What is the "right" overlay? > --047d7b6da42cb6ed6d04d7ad6a4e Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Apparently overlays have a "window" property, wh= ich when set, will display the overlay only in the relevant window.=A0
=
I've noticed however that sometimes it gets set to= t.


On Mon,= Mar 11, 2013 at 8:59 PM, Eli Zaretskii <eliz@gnu.org> wrote:
=
> Date: Mon, 11 Mar 2013 21:27:16 +0100
>
> So the multiple overlays thingy is actually intended. =A0But somewhere= the
> logic goes wonky and we're acting on the wrong overlay.

What is the "right" overlay?

--047d7b6da42cb6ed6d04d7ad6a4e-- From debbugs-submit-bounces@debbugs.gnu.org Mon Mar 11 19:42:26 2013 Received: (at 13887) by debbugs.gnu.org; 11 Mar 2013 23:42:26 +0000 Received: from localhost ([127.0.0.1]:47060 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFCMM-0005bH-4O for submit@debbugs.gnu.org; Mon, 11 Mar 2013 19:42:26 -0400 Received: from mail-qc0-f171.google.com ([209.85.216.171]:43228) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFCMJ-0005b2-Il for 13887@debbugs.gnu.org; Mon, 11 Mar 2013 19:42:24 -0400 Received: by mail-qc0-f171.google.com with SMTP id d1so1763606qca.2 for <13887@debbugs.gnu.org>; Mon, 11 Mar 2013 16:41:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=fj0SQpXp6R4q/dX3HAbbs0ZUL5eXDcuxMy1fQ2+c9OM=; b=SjuiR2WkwbPpasjRWudQ1Ct7kmXhIm02BhVXxSleii+N0Hj9X1Hon/cMvghowf+kc5 Ncb+9mZx48HUZucgziSE9ko0zscyWh7OR9QnVQNlp8H8gjx5o5bxOypKmQWJTM4UaTYS exmYZDEhqjvN6PXksOZJf6kd8RuNpy/m3t/mGecM4ADkwkpe1QMyZD+M+sPTDVUzLi3T 6dbdzUNj4NSG6j3syP/kg63VRQpvvxp56Rb0cZWmII1saDy/GwnmSYLlhSXu3ixUOAxg y5a6i3kbDspy7oZqEThzqjw6cxPNiAv+rhOtSwsGTuijbC/TtI64ci1jYhwZPFUC04Ya OFSg== MIME-Version: 1.0 X-Received: by 10.49.95.138 with SMTP id dk10mr22357567qeb.43.1363045281263; Mon, 11 Mar 2013 16:41:21 -0700 (PDT) Received: by 10.49.70.233 with HTTP; Mon, 11 Mar 2013 16:41:21 -0700 (PDT) In-Reply-To: References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> Date: Mon, 11 Mar 2013 23:41:21 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Eli Zaretskii Content-Type: multipart/alternative; boundary=047d7b67743ccd755a04d7aeb547 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Stefan Monnier , Tassilo Horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --047d7b67743ccd755a04d7aeb547 Content-Type: text/plain; charset=ISO-8859-1 The overlay with t value has precedence over other overlays. If the problem occurs, I can run the following function, and it will get fixed in existing windows. However if I create a new window, it will show only text. If I press + in that window, a new overlay will be created. Perhaps the t overlay was meant to be the default, and someone misunderstood it's effect. (defun 13887-fix-helper1 () (interactive) (let* ((ovs (overlays-at (point))) (ov-t (find-if (lambda (ov) (eq (overlay-get ov 'window) t)) ovs))) (when ov-t (delete-overlay ov-t)))) Here is one more helper function which might be useful. (defun 13887-own-overlay-present-p () (interactive) (let* ((ovs (overlays-at (point)))) (find-if (lambda (ov) (eq (overlay-get ov 'window) (selected-window))) ovs))) --047d7b67743ccd755a04d7aeb547 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
The overlay with t value = has precedence over other overlays. If the problem occurs, I can run the fo= llowing function, and it will get fixed in existing windows. However if I c= reate a new window, it will show only text. If I press + in that window, a = new overlay will be created. Perhaps the t overlay was meant to be the defa= ult, and someone misunderstood it's effect.

(defun 13887-fix-helper1 ()
=A0 (int= eractive)
=A0 (let* ((ovs (overlays-at (point)))
=A0 =A0 =A0 =A0 =A0(ov-t (find-if (lambda (ov) (eq (= overlay-get ov 'window) t))
=A0 =A0 =A0= =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 ovs)))
=A0 =A0 (when ov-t (delete-overlay ov-t))))

Here= is one more helper function which might be useful.

(defun 13887-own-overlay-present-p ()<= /div>
=A0 (interactive)
=A0 (let* ((ovs (overlays-at (point))))
=A0 =A0 (find-if (lambda (ov) (eq (overlay-get ov 'window)
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 (selected-window)))
=A0 =A0 =A0= =A0 =A0 =A0 =A0ovs)))
--047d7b67743ccd755a04d7aeb547-- From debbugs-submit-bounces@debbugs.gnu.org Mon Mar 11 21:01:18 2013 Received: (at 13887) by debbugs.gnu.org; 12 Mar 2013 01:01:18 +0000 Received: from localhost ([127.0.0.1]:47082 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFDaf-0007Xi-Ts for submit@debbugs.gnu.org; Mon, 11 Mar 2013 21:01:18 -0400 Received: from mail-qe0-f53.google.com ([209.85.128.53]:64566) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFDab-0007XT-Qn for 13887@debbugs.gnu.org; Mon, 11 Mar 2013 21:01:15 -0400 Received: by mail-qe0-f53.google.com with SMTP id cz11so2630490qeb.26 for <13887@debbugs.gnu.org>; Mon, 11 Mar 2013 18:00:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=bDHQ9SB4jOLNBPAd+j/K1ymVIkMq7P0oGv2Oq3l+ukU=; b=fRZnjT58WW5U2lj5eO+lrQYG6nmgoco+tZXcnqh7p6FXX3ecHlQHRS2BvsZ9IUspAx eSSAOij+UKYS2pQP0j4zxb6/9dwWyspfkYMg9JgBEU5odjkFIsDx32I7uiQ0ohhuZcq1 CpwCAdLBQ/s89pwCyDRKT9OLYiSjl5ntd5vVnMHjDRmWTOIsKvbaifvH02KDbV+PdUP5 /+Ot9uYoMOWqPGvv2Eq3AlbSO5Lvr0DtS+YjYCUd0NAifpmrp7boMUnjs0mxQCRxZTQy zQXjiAhlek8LwHc90/gGWe8RgmXTJa8DWNAm4QgKvuj/yFsgd/O7zxB52z0qYQPiwuuV F8NQ== MIME-Version: 1.0 X-Received: by 10.224.117.66 with SMTP id p2mr14208335qaq.45.1363050011293; Mon, 11 Mar 2013 18:00:11 -0700 (PDT) Received: by 10.49.70.233 with HTTP; Mon, 11 Mar 2013 18:00:11 -0700 (PDT) In-Reply-To: References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> Date: Tue, 12 Mar 2013 01:00:11 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Eli Zaretskii Content-Type: multipart/alternative; boundary=20cf3074b472bc02eb04d7afcf21 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Stefan Monnier , Tassilo Horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --20cf3074b472bc02eb04d7afcf21 Content-Type: text/plain; charset=ISO-8859-1 Further evidence suggests that the "t taking precedence" version is wrong. It's more probable the the precedence is determined by the order of overlays in some C data-structure. On Mon, Mar 11, 2013 at 11:41 PM, E Sabof wrote: > The overlay with t value has precedence over other overlays. If the > problem occurs, I can run the following function, and it will get fixed in > existing windows. However if I create a new window, it will show only text. > If I press + in that window, a new overlay will be created. Perhaps the t > overlay was meant to be the default, and someone misunderstood it's effect. > > (defun 13887-fix-helper1 () > (interactive) > (let* ((ovs (overlays-at (point))) > (ov-t (find-if (lambda (ov) (eq (overlay-get ov 'window) t)) > ovs))) > (when ov-t (delete-overlay ov-t)))) > > Here is one more helper function which might be useful. > > (defun 13887-own-overlay-present-p () > (interactive) > (let* ((ovs (overlays-at (point)))) > (find-if (lambda (ov) (eq (overlay-get ov 'window) > (selected-window))) > ovs))) > --20cf3074b472bc02eb04d7afcf21 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Further evidence suggests that the "t taking=A0preced= ence"=A0version is wrong. It's more probable the the precedence is= determined by the order of overlays in some C data-structure.


On Mon, Mar 11, 2013 at 11:41 PM, E Sabo= f <esabof@gmail.com> wrote:
The overlay with t value has pr= ecedence over other overlays. If the problem occurs, I can run the followin= g function, and it will get fixed in existing windows. However if I create = a new window, it will show only text. If I press + in that window, a new ov= erlay will be created. Perhaps the t overlay was meant to be the default, a= nd someone misunderstood it's effect.

(def= un 13887-fix-helper1 ()
=A0 (interactive)
=A0 (let* ((ovs (overlays-at (point)))
=A0 =A0 =A0 =A0 =A0(ov-t (find-if (lambda (ov) (eq (= overlay-get ov 'window) t))
=A0 =A0 =A0= =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 ovs)))
=A0 =A0 (when ov-t (delete-overlay ov-t))))

Here is on= e more helper function which might be useful.

(defun 13887-own-overlay-present-p ()<= /div>
=A0 (interactive)
=A0 (let* ((ovs (overlays-at (point))))
=A0 =A0 (find-if (lambda (ov) (eq (overlay-get ov 'window)
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 (selected-window)))
=A0 =A0 =A0= =A0 =A0 =A0 =A0ovs)))

--20cf3074b472bc02eb04d7afcf21-- From debbugs-submit-bounces@debbugs.gnu.org Tue Mar 12 04:11:02 2013 Received: (at 13887) by debbugs.gnu.org; 12 Mar 2013 08:11:02 +0000 Received: from localhost ([127.0.0.1]:47638 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFKIW-00030T-4T for submit@debbugs.gnu.org; Tue, 12 Mar 2013 04:11:00 -0400 Received: from deliver.uni-koblenz.de ([141.26.64.15]:52357) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFKIR-00030J-Oz for 13887@debbugs.gnu.org; Tue, 12 Mar 2013 04:10:58 -0400 Received: from localhost (localhost [127.0.0.1]) by deliver.uni-koblenz.de (Postfix) with ESMTP id 267A91A89F7; Tue, 12 Mar 2013 09:09:56 +0100 (CET) X-Virus-Scanned: amavisd-new at uni-koblenz.de Received: from deliver.uni-koblenz.de ([127.0.0.1]) by localhost (deliver.uni-koblenz.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id njl30FF79tQ0; Tue, 12 Mar 2013 09:09:55 +0100 (CET) X-CHKRCPT: Envelopesender noch tsdh@gnu.org Received: from thinkpad.tsdh.de (tsdh.uni-koblenz.de [141.26.67.142]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by deliver.uni-koblenz.de (Postfix) with ESMTPSA id 987631A89FC; Tue, 12 Mar 2013 09:09:55 +0100 (CET) From: Tassilo Horn To: E Sabof Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available References: <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> Date: Tue, 12 Mar 2013 09:09:54 +0100 In-Reply-To: (E. Sabof's message of "Tue, 12 Mar 2013 01:00:11 +0000") Message-ID: <877gldyr71.fsf@thinkpad.tsdh.de> User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -3.5 (---) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Eli Zaretskii , Stefan Monnier X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.5 (---) Eli Zaretskii writes: > What is the "right" overlay? There should be exactly one overlay in the doc-view buffer whose window property is the currently selected window, and that window has this overlay accociated in `image-mode-winprops-alist'. E Sabof writes: > Further evidence suggests that the "t taking precedence" version is > wrong. It's more probable the the precedence is determined by the > order of overlays in some C data-structure. I think the buffer-local value of `image-mode-winprops-alist' should always look like: --8<---------------cut here---------------start------------->8--- ((# (overlay . #) (image image :type imagemagick :file "/tmp/docview1000/IncPat.pdf-982c2eddc6c753dafecbffecb17d5993/page-12.png" :width 685) (info . #("Page 12 of 13.\n" 0 14 (face bold))) (page . 12) (slice)) (t (page . 1) (overlay . #))) --8<---------------cut here---------------end--------------->8--- That is, there's one entry for any window that shows this doc-view buffer, plus one t-entry with a deleted overlay. The order of entries is by recency of window activations (or creations?), I think. t is always the last. When `doc-view-new-window-function' is called for the very first time for a new doc-view buffer (i.e., you opened a new document), (car winprops) is t. I that case, a new overlay is created, doc-view and window properties are added (both t), it's associated in winprops (the t-entry), and then it's deleted so that its not shown (because at this point in time the image to be shown might not exist). This entry acts as default if there are no other entries. Thereafter, it's immediately called again with a concrete window in (car winprops). Don't ask me from where. I'm edebugging `doc-view-new-window-function', but this call doesn't drop me in the edebugger as the previous one did. I just see the message New window # for buf foo.pdf in the echo area. With the second and any subsequent call of `doc-view-new-window-function' for a given doc-view buffer, the overlay of the top-entry in `image-mode-winprops-alist' is copied. That way, the new window shows the same page with the same zoom level/slice as the most recent other window showing the document. Yesterday, when things were messed up, I know that `image-mode-winprops-alist' looked like that: --8<---------------cut here---------------start------------->8--- ((# ...) (t (page . 1) (overlay . #))) --8<---------------cut here---------------end--------------->8--- That is, the t-entry had an overlay that hasn't been deleted. I don't know how I could reach that state (I just quickly switched pages, zoomed, sliced, split window), but that seems wrong and might be the culprit because some other window in might already use that. Bye, Tassilo From debbugs-submit-bounces@debbugs.gnu.org Tue Mar 12 12:52:33 2013 Received: (at 13887) by debbugs.gnu.org; 12 Mar 2013 16:52:33 +0000 Received: from localhost ([127.0.0.1]:49108 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFSRC-0008CZ-2m for submit@debbugs.gnu.org; Tue, 12 Mar 2013 12:52:32 -0400 Received: from mtaout20.012.net.il ([80.179.55.166]:36697) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFSR9-0008CI-NZ for 13887@debbugs.gnu.org; Tue, 12 Mar 2013 12:52:28 -0400 Received: from conversion-daemon.a-mtaout20.012.net.il by a-mtaout20.012.net.il (HyperSendmail v2007.08) id <0MJK00D003C3J100@a-mtaout20.012.net.il> for 13887@debbugs.gnu.org; Tue, 12 Mar 2013 18:50:50 +0200 (IST) Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout20.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MJK00CKZ44OO0O0@a-mtaout20.012.net.il>; Tue, 12 Mar 2013 18:50:49 +0200 (IST) Date: Tue, 12 Mar 2013 18:50:45 +0200 From: Eli Zaretskii Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available In-reply-to: <877gldyr71.fsf@thinkpad.tsdh.de> X-012-Sender: halo1@inter.net.il To: Tassilo Horn Message-id: <83mwu8k1ei.fsf@gnu.org> References: <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <877gldyr71.fsf@thinkpad.tsdh.de> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, esabof@gmail.com, monnier@iro.umontreal.ca X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list Reply-To: Eli Zaretskii List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.2 (-) > From: Tassilo Horn > Cc: Eli Zaretskii , Stefan Monnier , 13887@debbugs.gnu.org > Date: Tue, 12 Mar 2013 09:09:54 +0100 > > Yesterday, when things were messed up, I know that > `image-mode-winprops-alist' looked like that: > > --8<---------------cut here---------------start------------->8--- > ((# > ...) > (t > (page . 1) > (overlay . #))) > --8<---------------cut here---------------end--------------->8--- > > That is, the t-entry had an overlay that hasn't been deleted. I don't > know how I could reach that state (I just quickly switched pages, > zoomed, sliced, split window), but that seems wrong and might be the > culprit because some other window in might already use that. So is there still some issue with handling overlays or with display in general? You see, I chimed in because you seemed to indicate there's some problems with how overlays are handled in this context. But now it sounds like the problem is some fragile logic in doc-view.el proper, right? From debbugs-submit-bounces@debbugs.gnu.org Tue Mar 12 12:53:50 2013 Received: (at 13887) by debbugs.gnu.org; 12 Mar 2013 16:53:50 +0000 Received: from localhost ([127.0.0.1]:49113 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFSSS-0008Ec-Th for submit@debbugs.gnu.org; Tue, 12 Mar 2013 12:53:49 -0400 Received: from mtaout22.012.net.il ([80.179.55.172]:47194) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFSSQ-0008EM-6I for 13887@debbugs.gnu.org; Tue, 12 Mar 2013 12:53:46 -0400 Received: from conversion-daemon.a-mtaout22.012.net.il by a-mtaout22.012.net.il (HyperSendmail v2007.08) id <0MJK007004628D00@a-mtaout22.012.net.il> for 13887@debbugs.gnu.org; Tue, 12 Mar 2013 18:52:38 +0200 (IST) Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout22.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MJK007UL47Q2A50@a-mtaout22.012.net.il>; Tue, 12 Mar 2013 18:52:38 +0200 (IST) Date: Tue, 12 Mar 2013 18:52:34 +0200 From: Eli Zaretskii Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available In-reply-to: X-012-Sender: halo1@inter.net.il To: E Sabof Message-id: <83li9sk1bh.fsf@gnu.org> References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, monnier@iro.umontreal.ca, tsdh@gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list Reply-To: Eli Zaretskii List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.2 (-) > Date: Tue, 12 Mar 2013 01:00:11 +0000 > From: E Sabof > Cc: Tassilo Horn , Stefan Monnier , 13887@debbugs.gnu.org > > Further evidence suggests that the "t taking precedence" version is wrong. > It's more probable the the precedence is determined by the order of > overlays in some C data-structure. What do you mean by "precedence"? AFAIK, there's no precedence in handling overlays, unless they have non-nil 'priority' property, in which case all the overlays at a given position are sorted according to priority before displaying them. From debbugs-submit-bounces@debbugs.gnu.org Tue Mar 12 13:47:53 2013 Received: (at 13887) by debbugs.gnu.org; 12 Mar 2013 17:47:53 +0000 Received: from localhost ([127.0.0.1]:49149 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFTIk-00013L-Vs for submit@debbugs.gnu.org; Tue, 12 Mar 2013 13:47:52 -0400 Received: from mail-qa0-f53.google.com ([209.85.216.53]:53340) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFTIi-000138-CI for 13887@debbugs.gnu.org; Tue, 12 Mar 2013 13:47:49 -0400 Received: by mail-qa0-f53.google.com with SMTP id z4so153619qan.12 for <13887@debbugs.gnu.org>; Tue, 12 Mar 2013 10:46:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=wkwu+7pm8ysByqqK/MA45xwTQyCdsEMa27eQMxI8uEU=; b=MJdM/oEBAUfPCO6FkBkt93KLscca8y/ZCwUw+9MJpA2reFLDr80zuMRZIvhm4XRCfq 51//Zxs4elSmINAf07sCdz1M04uiPPSNzusMOagw7eFi0PmyCyVZai6JuGy2NeVkBlj6 dMGdJWfUsyKio5CI48g6nI4jBxKhCWz990epeMzbMwzhkn0t04QYBAez8FU5vmUUjg3J K+H0JjeUBdpDnRDiHDHh8xoUdGa+9qK2xDA1y5y1l4IHO6amO8KZJ2jG6H0vSLeTNYDG 74nJ2S5cZihDzuE3cHj246NM7t/aK9L78r3AphF1iL4SafBOhp69MKKzxOwsK1zviFSK Xo8A== MIME-Version: 1.0 X-Received: by 10.224.27.136 with SMTP id i8mr23966824qac.63.1363110402039; Tue, 12 Mar 2013 10:46:42 -0700 (PDT) Received: by 10.49.70.233 with HTTP; Tue, 12 Mar 2013 10:46:41 -0700 (PDT) In-Reply-To: <83li9sk1bh.fsf@gnu.org> References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> Date: Tue, 12 Mar 2013 17:46:41 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Eli Zaretskii Content-Type: multipart/alternative; boundary=bcaec51b15934da63704d7bddfcd X-Spam-Score: -2.6 (--) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Stefan Monnier , Tassilo Horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --bcaec51b15934da63704d7bddfcd Content-Type: text/plain; charset=ISO-8859-1 I mean which overlay will be visible, everything else being equal On Tue, Mar 12, 2013 at 4:52 PM, Eli Zaretskii wrote: > > Date: Tue, 12 Mar 2013 01:00:11 +0000 > > From: E Sabof > > Cc: Tassilo Horn , Stefan Monnier < > monnier@iro.umontreal.ca>, 13887@debbugs.gnu.org > > > > Further evidence suggests that the "t taking precedence" version is > wrong. > > It's more probable the the precedence is determined by the order of > > overlays in some C data-structure. > > What do you mean by "precedence"? AFAIK, there's no precedence in > handling overlays, unless they have non-nil 'priority' property, in > which case all the overlays at a given position are sorted according > to priority before displaying them. > --bcaec51b15934da63704d7bddfcd Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
I mean which overlay will be visible, everything else bein= g equal

On Tue= , Mar 12, 2013 at 4:52 PM, Eli Zaretskii <eliz@gnu.org> wrote:
> Date: Tue, 12 Mar 2013 01:00:11 +0000 > From: E Sabof <esabof@gmail.com>
> Cc: Tassilo Horn <tsdh@gnu.org>, Stefan Monnier <monnier@iro.umontreal.ca>, 13887@debbugs.gnu.org
>
> Further evidence suggests that the "t taking precedence" ver= sion is wrong.
> It's more probable the the precedence is determined by the order o= f
> overlays in some C data-structure.

What do you mean by "precedence"? =A0AFAIK, there's no = precedence in
handling overlays, unless they have non-nil 'priority' property, in=
which case all the overlays at a given position are sorted according
to priority before displaying them.

--bcaec51b15934da63704d7bddfcd-- From debbugs-submit-bounces@debbugs.gnu.org Tue Mar 12 14:01:42 2013 Received: (at 13887) by debbugs.gnu.org; 12 Mar 2013 18:01:42 +0000 Received: from localhost ([127.0.0.1]:49164 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFTW7-0001OZ-3b for submit@debbugs.gnu.org; Tue, 12 Mar 2013 14:01:40 -0400 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:50114) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFTW3-0001OO-Kv for 13887@debbugs.gnu.org; Tue, 12 Mar 2013 14:01:36 -0400 Received: from compute3.internal (compute3.nyi.mail.srv.osa [10.202.2.43]) by gateway1.nyi.mail.srv.osa (Postfix) with ESMTP id 074E3207F6; Tue, 12 Mar 2013 14:00:34 -0400 (EDT) Received: from frontend2.nyi.mail.srv.osa ([10.202.2.161]) by compute3.internal (MEProxy); Tue, 12 Mar 2013 14:00:34 -0400 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=from:to:cc:subject:references:date :in-reply-to:message-id:mime-version:content-type; s=smtpout; bh=7S8z0N8CgkbIwM9B0GdGAY7DAd0=; b=HDYi2kod3kdAhCb+m6sCxqmlGsjz 9csx+dvPme3IExJmwOsYrAjbVkqKfk63w8IjMs6dZcVz3xUUNYt8M3tqM3LcOWAO iURTHOO7CVaW5xS/4pVhe/p1GDNGDfgbo2FTM9Dk79ZXAiXAM2n18GUmGKMdQ4lW vFOlotuNnQQDyGY= X-Sasl-enc: y0QVJNT4ZXnF+3nMzaW6xDpbeyYwiva0J5xl4vhiYLHf 1363111233 Received: from thinkpad.tsdh.de (unknown [91.67.10.84]) by mail.messagingengine.com (Postfix) with ESMTPA id 37606201180; Tue, 12 Mar 2013 14:00:33 -0400 (EDT) From: Tassilo Horn To: Eli Zaretskii Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available References: <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <877gldyr71.fsf@thinkpad.tsdh.de> <83mwu8k1ei.fsf@gnu.org> Date: Tue, 12 Mar 2013 19:00:30 +0100 In-Reply-To: <83mwu8k1ei.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 12 Mar 2013 18:50:45 +0200") Message-ID: <87sj40pkg1.fsf@thinkpad.tsdh.de> User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, esabof@gmail.com, monnier@iro.umontreal.ca X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) Eli Zaretskii writes: >> Yesterday, when things were messed up, I know that >> `image-mode-winprops-alist' looked like that: >> >> --8<---------------cut here---------------start------------->8--- >> ((# >> ...) >> (t >> (page . 1) >> (overlay . #))) >> --8<---------------cut here---------------end--------------->8--- >> >> That is, the t-entry had an overlay that hasn't been deleted. I don't >> know how I could reach that state (I just quickly switched pages, >> zoomed, sliced, split window), but that seems wrong and might be the >> culprit because some other window in might already use that. > > So is there still some issue with handling overlays or with display in > general? No, I don't think so. > You see, I chimed in because you seemed to indicate there's some > problems with how overlays are handled in this context. But now it > sounds like the problem is some fragile logic in doc-view.el proper, > right? Yes, doc-view or (less likely) image-mode. That's why I've Cc-ed Stefan who invented that logic. Bye, Tassilo From debbugs-submit-bounces@debbugs.gnu.org Tue Mar 12 17:13:08 2013 Received: (at 13887) by debbugs.gnu.org; 12 Mar 2013 21:13:08 +0000 Received: from localhost ([127.0.0.1]:49469 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFWVQ-0006td-G6 for submit@debbugs.gnu.org; Tue, 12 Mar 2013 17:13:08 -0400 Received: from mtaout20.012.net.il ([80.179.55.166]:43257) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFWVO-0006t3-Gl for 13887@debbugs.gnu.org; Tue, 12 Mar 2013 17:13:07 -0400 Received: from conversion-daemon.a-mtaout20.012.net.il by a-mtaout20.012.net.il (HyperSendmail v2007.08) id <0MJK00G00G458W00@a-mtaout20.012.net.il> for 13887@debbugs.gnu.org; Tue, 12 Mar 2013 23:11:48 +0200 (IST) Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout20.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MJK00GLKG7O7230@a-mtaout20.012.net.il>; Tue, 12 Mar 2013 23:11:48 +0200 (IST) Date: Tue, 12 Mar 2013 23:11:45 +0200 From: Eli Zaretskii Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available In-reply-to: X-012-Sender: halo1@inter.net.il To: E Sabof Message-id: <83hakgjpbi.fsf@gnu.org> References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, monnier@iro.umontreal.ca, tsdh@gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list Reply-To: Eli Zaretskii List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.2 (-) > Date: Tue, 12 Mar 2013 17:46:41 +0000 > From: E Sabof > Cc: Tassilo Horn , Stefan Monnier , 13887@debbugs.gnu.org > > I mean which overlay will be visible, everything else being equal They all will be visible. From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 13 23:29:44 2013 Received: (at 13887) by debbugs.gnu.org; 14 Mar 2013 03:29:44 +0000 Received: from localhost ([127.0.0.1]:52300 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFyrQ-0002ep-3U for submit@debbugs.gnu.org; Wed, 13 Mar 2013 23:29:44 -0400 Received: from mail-qe0-f45.google.com ([209.85.128.45]:44501) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFyrO-0002ed-DO for 13887@debbugs.gnu.org; Wed, 13 Mar 2013 23:29:43 -0400 Received: by mail-qe0-f45.google.com with SMTP id b4so1045339qen.32 for <13887@debbugs.gnu.org>; Wed, 13 Mar 2013 20:28:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=5m/1TXESdC1/CdQ3lBa21D+r9rJxqsq/DdY3T1t51OU=; b=FnvJDG5L+t56c5MQcsAHUQoDdsFi3YC8c3d220Lh9TyUFcZkmk3fZpBUzQruw33yPJ K/QLAvQHpwyhWnvuVx42WUB/XXuuhVe+hqS33FN7T1O/6+VHVyujlycIpChzqN86VrjC 4TtDhAXkijuc4W8rwa9I/PycnP5DGOTlHGwo5roQYgdvFx/SshWkPNQhzB537HuC/wTH 3NsqB8Sy5sPnyUou6VNYxYUpqB7pCemF3HPuk65GLs4X2k354BxENW+KF933KuNimrE+ qSarUSb4CwtSeZ2bt7X/W6QDB7jDkLTE0G+JqNYXEmGM32nA3UPt/uUhyIhw60uTkrXp 7I6g== MIME-Version: 1.0 X-Received: by 10.49.84.6 with SMTP id u6mr1136664qey.35.1363231707747; Wed, 13 Mar 2013 20:28:27 -0700 (PDT) Received: by 10.49.70.233 with HTTP; Wed, 13 Mar 2013 20:28:27 -0700 (PDT) In-Reply-To: <83hakgjpbi.fsf@gnu.org> References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> Date: Thu, 14 Mar 2013 03:28:27 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Eli Zaretskii Content-Type: multipart/alternative; boundary=047d7bdc0934afe2b704d7da1d4e X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Stefan Monnier , Tassilo Horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --047d7bdc0934afe2b704d7da1d4e Content-Type: text/plain; charset=ISO-8859-1 Here is what I found: The first time (doc-view-insert-image) is called, the doc-view buffer isn't selected, and (doc-view-current-overlay) returns the t overlay. The "fake" overlay gets "resurrected" when (doc-view-insert-image) calls (move-overlay) on it. Adding (defun doc-view-initiate-display () ;; Switch to image display if possible. (if (doc-view-mode-p doc-view-doc-type) (progn + (unless (eq (window-buffer) (current-buffer)) + (set-window-buffer (selected-window) (current-buffer))) prevents the t "window" from being set. The second problem was that after splitting, new windows wouldn't have overlays. What looked suspicious was that (image-mode-winprops) always ran with the initial window. Changing the definition of image-get-display-property from (defun image-get-display-property () (get-char-property (point-min) 'display ;; There might be different images for different displays. (if (eq (window-buffer) (current-buffer)) (selected-window)))) to (defun image-get-display-property () (or (get-char-property (point-min) 'display (selected-window)) (get-char-property (point-min) 'display))) has fixed it. I'm not sure it's the right (only?) place to fix, since by the time it gets called, (eq (window-buffer) (current-buffer)) should be true. Evgeni --047d7bdc0934afe2b704d7da1d4e Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Here is what I found:

The first time (d= oc-view-insert-image) is called, the doc-view buffer isn't selected, an= d (doc-view-current-overlay) returns the t overlay.=A0

The "fake" overlay gets "resurrected" when (doc-vie= w-insert-image) calls (move-overlay) on it.=A0

Adding

(defun doc-view-initiate-display= ()
=A0 ;; Switch to image display if possible.
=A0 (if (doc-vie= w-mode-p doc-view-doc-type)
=A0 =A0 =A0 (progn
+ =A0 = =A0 =A0 =A0(unless (eq (window-buffer) (current-buffer))
+ =A0 = =A0 =A0 =A0 =A0(set-window-buffer (selected-window) (current-buffer)))

prevents the t "window" from bein= g set.

The second problem was that afte= r splitting, new windows wouldn't have overlays. What looked suspicious= was that (image-mode-winprops) always ran with the initial window. Changin= g the definition of image-get-display-property from

(defun image-get-display-property ()
=A0 (get-char-property (point-min) 'display
=A0 =A0 = =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0;; There might be different images for d= ifferent displays.
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(if (eq (window-buffer) (cu= rrent-buffer))
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0(selected-window))))

to
<= br>
(defun image-get-display-property ()
=A0 (or (get-char-property (point-min) 'display (selected-window))=
=A0 =A0 =A0 (get-char-property (point-min) 'display)))
=

has fixed it. I'm not sure it's the= right (only?) place to fix, since by the time it gets called, (eq (window-= buffer) (current-buffer)) should be true.

Evgeni


--047d7bdc0934afe2b704d7da1d4e-- From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 13 23:58:11 2013 Received: (at 13887) by debbugs.gnu.org; 14 Mar 2013 03:58:11 +0000 Received: from localhost ([127.0.0.1]:52333 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFzIw-0003K5-Gx for submit@debbugs.gnu.org; Wed, 13 Mar 2013 23:58:10 -0400 Received: from mail-qe0-f41.google.com ([209.85.128.41]:47049) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UFzIv-0003Ju-OI for 13887@debbugs.gnu.org; Wed, 13 Mar 2013 23:58:10 -0400 Received: by mail-qe0-f41.google.com with SMTP id 6so1057519qeb.14 for <13887@debbugs.gnu.org>; Wed, 13 Mar 2013 20:56:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=54CmFWgI62Ae/9HU5UK71HokC5uoTnlFW47SjUdi5FE=; b=mYTuBfoFOqVf249zoHWHDqZfhGd9XrfzEOxB73d3HeofdYYPujuoGMO9gCWsgiTw63 DnqyOPBY/bBaWMdXY8I3+k6NvOMlPOVrUAKBIHiZrSjwGEGk9RfD6UnOotQSrX+KLPzP CsXmIRmckL8MJw3C286K9B2y5oS7ksRnK7w5+Lg/5qTIf7j0Nnq+fCSMn5HxCSpAqMEM Z8xJPCp5UkNLtIzgTcQxGfBSDprPAJOHKDQfBBHVypftm/v+TOu7YPV/BPB7QsWLwBVD PFXIdfK91k9vGquHJThSbCHZjWb7OZ76EIudc97T0pIZBtdaLXa6VJ7aPKuZ0yLWNmd3 0J1A== MIME-Version: 1.0 X-Received: by 10.224.27.136 with SMTP id i8mr1849736qac.63.1363233414523; Wed, 13 Mar 2013 20:56:54 -0700 (PDT) Received: by 10.49.70.233 with HTTP; Wed, 13 Mar 2013 20:56:54 -0700 (PDT) In-Reply-To: References: <8762153qc8.fsf@thinkpad.tsdh.de> <8762143co6.fsf@thinkpad.tsdh.de> <877glkgvqj.fsf@thinkpad.tsdh.de> <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> Date: Thu, 14 Mar 2013 03:56:54 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Eli Zaretskii Content-Type: multipart/alternative; boundary=bcaec51b15936b4ac604d7da83b0 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Stefan Monnier , Tassilo Horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --bcaec51b15936b4ac604d7da83b0 Content-Type: text/plain; charset=ISO-8859-1 However with these fixes, docview is no longer converts properly. It only works if the images are cached. --bcaec51b15936b4ac604d7da83b0 Content-Type: text/html; charset=ISO-8859-1
However with these fixes, docview is no longer converts properly. It only works if the images are cached.
--bcaec51b15936b4ac604d7da83b0-- From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 14 03:25:33 2013 Received: (at 13887) by debbugs.gnu.org; 14 Mar 2013 07:25:33 +0000 Received: from localhost ([127.0.0.1]:52623 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UG2Xc-0008Bd-M6 for submit@debbugs.gnu.org; Thu, 14 Mar 2013 03:25:33 -0400 Received: from deliver.uni-koblenz.de ([141.26.64.15]:51506) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UG2XZ-0008BU-3k for 13887@debbugs.gnu.org; Thu, 14 Mar 2013 03:25:30 -0400 Received: from localhost (localhost [127.0.0.1]) by deliver.uni-koblenz.de (Postfix) with ESMTP id 3EA1A1A85A1; Thu, 14 Mar 2013 08:24:18 +0100 (CET) X-Virus-Scanned: amavisd-new at uni-koblenz.de Received: from deliver.uni-koblenz.de ([127.0.0.1]) by localhost (deliver.uni-koblenz.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 2IfBSSnmyi9T; Thu, 14 Mar 2013 08:24:17 +0100 (CET) X-CHKRCPT: Envelopesender noch tsdh@gnu.org Received: from thinkpad.tsdh.de (tsdh.uni-koblenz.de [141.26.67.142]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by deliver.uni-koblenz.de (Postfix) with ESMTPSA id C22AA1A85A0; Thu, 14 Mar 2013 08:24:17 +0100 (CET) From: Tassilo Horn To: E Sabof Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available References: <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> Date: Thu, 14 Mar 2013 08:24:17 +0100 In-Reply-To: (E. Sabof's message of "Thu, 14 Mar 2013 03:28:27 +0000") Message-ID: <87ip4ue95q.fsf@thinkpad.tsdh.de> User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -3.5 (---) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Eli Zaretskii , Stefan Monnier X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.5 (---) E Sabof writes: > The first time (doc-view-insert-image) is called, the doc-view buffer > isn't selected, and (doc-view-current-overlay) returns the t overlay. > > The "fake" overlay gets "resurrected" when (doc-view-insert-image) > calls (move-overlay) on it. Thanks Evgeni, I think that brought me on track. Could you please test-drive this patch (which also contains the centering stuff) and check if the issue is fixed by it? It seems it is for me, but I only did some very brief testing. --8<---------------cut here---------------start------------->8--- === modified file 'lisp/doc-view.el' --- lisp/doc-view.el 2013-02-28 04:02:36 +0000 +++ lisp/doc-view.el 2013-03-14 07:21:18 +0000 @@ -1250,17 +1250,33 @@ (when doc-view-pending-cache-flush (clear-image-cache) (setq doc-view-pending-cache-flush nil)) - (let ((ol (doc-view-current-overlay)) - (image (if (and file (file-readable-p file)) + (let ((ol (doc-view-current-overlay))) + ;; ol might be a deleted (see `doc-view-new-window-function'), in + ;; which case we don't want to modify it. + (when (overlay-buffer ol) + (let* ((image (if (and file (file-readable-p file)) (if (not (and doc-view-scale-internally (fboundp 'imagemagick-types))) (apply 'create-image file doc-view--image-type nil args) (unless (member :width args) (setq args `(,@args :width ,doc-view-image-width))) (apply 'create-image file 'imagemagick nil args)))) - (slice (doc-view-current-slice))) + (slice (doc-view-current-slice)) + (img-width (and image (car (image-size image)))) + (displayed-img-width (if (and image slice) + (* (/ (float (nth 2 slice)) + (car (image-size image 'pixels))) + img-width) + img-width)) + (window-width (window-width (selected-window)))) (setf (doc-view-current-image) image) (move-overlay ol (point-min) (point-max)) + ;; In case the window is wider than the image, center the image + ;; horizontally. + (overlay-put ol 'before-string + (when (and image (> window-width displayed-img-width)) + (propertize " " 'display + `(space :align-to (+ center (-0.5 . ,displayed-img-width)))))) (overlay-put ol 'display (cond (image @@ -1287,7 +1303,7 @@ (vscroll (image-mode-window-get 'vscroll win))) ;; Reset scroll settings, in case they were changed. (if hscroll (set-window-hscroll win hscroll)) - (if vscroll (set-window-vscroll win vscroll))))))) + (if vscroll (set-window-vscroll win vscroll))))))))) (defun doc-view-sort (a b) "Return non-nil if A should be sorted before B. --8<---------------cut here---------------end--------------->8--- Bye, Tassilo From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 14 09:27:43 2013 Received: (at 13887) by debbugs.gnu.org; 14 Mar 2013 13:27:43 +0000 Received: from localhost ([127.0.0.1]:53185 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UG8C6-0000kl-Lp for submit@debbugs.gnu.org; Thu, 14 Mar 2013 09:27:43 -0400 Received: from ironport2-out.teksavvy.com ([206.248.154.182]:42704) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UG8C3-0000kY-Sp for 13887@debbugs.gnu.org; Thu, 14 Mar 2013 09:27:40 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av4EABK/CFHO+KL9/2dsb2JhbABEvw4Xc4IfAQVWIxALNBIUGA0kiCTBLZEKA6R6gV6DEw X-IPAS-Result: Av4EABK/CFHO+KL9/2dsb2JhbABEvw4Xc4IfAQVWIxALNBIUGA0kiCTBLZEKA6R6gV6DEw X-IronPort-AV: E=Sophos;i="4.84,565,1355115600"; d="scan'208";a="4896227" Received: from 206-248-162-253.dsl.teksavvy.com (HELO pastel.home) ([206.248.162.253]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 14 Mar 2013 09:26:21 -0400 Received: by pastel.home (Postfix, from userid 20848) id 6BC5967A4D; Thu, 14 Mar 2013 09:26:22 -0400 (EDT) From: Stefan Monnier To: E Sabof Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available Message-ID: References: <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> Date: Thu, 14 Mar 2013 09:26:22 -0400 In-Reply-To: (E. Sabof's message of "Thu, 14 Mar 2013 03:28:27 +0000") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Eli Zaretskii , Tassilo Horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) > + (unless (eq (window-buffer) (current-buffer)) > + (set-window-buffer (selected-window) (current-buffer))) This can't be the right fix: doc-view.el is just a major-mode that controls how a particular buffer is displayed, and not which buffer to display in which window. [ I see Tassilo has a better patch already, so I'll let him take care of it, but I just wanted to point out "the obvious". ] Stefan From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 14 11:25:10 2013 Received: (at 13887) by debbugs.gnu.org; 14 Mar 2013 15:25:10 +0000 Received: from localhost ([127.0.0.1]:54229 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGA1h-0003uA-8H for submit@debbugs.gnu.org; Thu, 14 Mar 2013 11:25:10 -0400 Received: from mail-qe0-f46.google.com ([209.85.128.46]:59403) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGA1a-0003tY-Jp for 13887@debbugs.gnu.org; Thu, 14 Mar 2013 11:25:04 -0400 Received: by mail-qe0-f46.google.com with SMTP id a11so1337317qen.33 for <13887@debbugs.gnu.org>; Thu, 14 Mar 2013 08:23:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=RWLnrbVDjTQG2qluhyxnQcfNJj9wCfBf3Bq5v0HPNeo=; b=YJKJPPNxpKG6ZMvXkdUNLn4IMRrpj7bvqpd1cC239NYFB4dxZdqSsXTtY74YcZWtz6 JMOTCO0+eUfCtwU0hya7BsokW6jFw0eG5ehruPTs4R9Wy3PpKW7QtQGG3dRy7+HqvHHj g4owwuzCD9Sicy87qeY7afvdRGGGbIfXCDteK91zH3P+CHQa0Sb1PMFqh46CNGuqZZJr BzRx9j3nueXuaQISQtbNKke2QwXyMnt0Lyc4M7UNwLallPm3TMBQdEwA47w7vNyUvVMp WWJLD2vjdFAm/JDUJkSsGcELjTJ10FpqL28VkKp8qaWUGEk5XecBPnZ9dSoqhDi2skik r5tQ== MIME-Version: 1.0 X-Received: by 10.224.199.70 with SMTP id er6mr3560200qab.19.1363274621563; Thu, 14 Mar 2013 08:23:41 -0700 (PDT) Received: by 10.49.70.233 with HTTP; Thu, 14 Mar 2013 08:23:41 -0700 (PDT) In-Reply-To: <87ip4ue95q.fsf@thinkpad.tsdh.de> References: <87txonw6ev.fsf@thinkpad.tsdh.de> <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> <87ip4ue95q.fsf@thinkpad.tsdh.de> Date: Thu, 14 Mar 2013 15:23:41 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Tassilo Horn Content-Type: multipart/alternative; boundary=20cf30050e8a8cb95104d7e41bd6 X-Spam-Score: -2.6 (--) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Eli Zaretskii , Stefan Monnier X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --20cf30050e8a8cb95104d7e41bd6 Content-Type: text/plain; charset=ISO-8859-1 With this patch I don't get an overlay in the initial window, and sometimes after splitting. Redefining image-get-display-property as in my previous patch fixes the splitting problem. Evgeni On Thu, Mar 14, 2013 at 7:24 AM, Tassilo Horn wrote: > E Sabof writes: > > > The first time (doc-view-insert-image) is called, the doc-view buffer > > isn't selected, and (doc-view-current-overlay) returns the t overlay. > > > > The "fake" overlay gets "resurrected" when (doc-view-insert-image) > > calls (move-overlay) on it. > > Thanks Evgeni, I think that brought me on track. Could you please > test-drive this patch (which also contains the centering stuff) and > check if the issue is fixed by it? It seems it is for me, but I only > did some very brief testing. > > --8<---------------cut here---------------start------------->8--- > === modified file 'lisp/doc-view.el' > --- lisp/doc-view.el 2013-02-28 04:02:36 +0000 > +++ lisp/doc-view.el 2013-03-14 07:21:18 +0000 > @@ -1250,17 +1250,33 @@ > (when doc-view-pending-cache-flush > (clear-image-cache) > (setq doc-view-pending-cache-flush nil)) > - (let ((ol (doc-view-current-overlay)) > - (image (if (and file (file-readable-p file)) > + (let ((ol (doc-view-current-overlay))) > + ;; ol might be a deleted (see `doc-view-new-window-function'), in > + ;; which case we don't want to modify it. > + (when (overlay-buffer ol) > + (let* ((image (if (and file (file-readable-p file)) > (if (not (and doc-view-scale-internally > (fboundp 'imagemagick-types))) > (apply 'create-image file doc-view--image-type nil > args) > (unless (member :width args) > (setq args `(,@args :width ,doc-view-image-width))) > (apply 'create-image file 'imagemagick nil args)))) > - (slice (doc-view-current-slice))) > + (slice (doc-view-current-slice)) > + (img-width (and image (car (image-size image)))) > + (displayed-img-width (if (and image slice) > + (* (/ (float (nth 2 slice)) > + (car (image-size image > 'pixels))) > + img-width) > + img-width)) > + (window-width (window-width (selected-window)))) > (setf (doc-view-current-image) image) > (move-overlay ol (point-min) (point-max)) > + ;; In case the window is wider than the image, center the image > + ;; horizontally. > + (overlay-put ol 'before-string > + (when (and image (> window-width displayed-img-width)) > + (propertize " " 'display > + `(space :align-to (+ center (-0.5 . > ,displayed-img-width)))))) > (overlay-put ol 'display > (cond > (image > @@ -1287,7 +1303,7 @@ > (vscroll (image-mode-window-get 'vscroll win))) > ;; Reset scroll settings, in case they were changed. > (if hscroll (set-window-hscroll win hscroll)) > - (if vscroll (set-window-vscroll win vscroll))))))) > + (if vscroll (set-window-vscroll win vscroll))))))))) > > (defun doc-view-sort (a b) > "Return non-nil if A should be sorted before B. > --8<---------------cut here---------------end--------------->8--- > > Bye, > Tassilo > --20cf30050e8a8cb95104d7e41bd6 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
With=A0this patch I don't get an overlay in the initia= l window, and sometimes after splitting. Redefining=A0image-get-display-pr= operty as in my previous patch fixes the splitting problem.

Evgeni


On Thu, Mar 14, 2013 at 7:24 AM, Tassilo= Horn <tsdh@gnu.org> wrote:
E Sabof <esabof@gm= ail.com> writes:

> The first time (doc-view-insert-image) is called, the doc-view buffer<= br> > isn't selected, and (doc-view-current-overlay) returns the t overl= ay.
>
> The "fake" overlay gets "resurrected" when (doc-vi= ew-insert-image)
> calls (move-overlay) on it.

Thanks Evgeni, I think that brought me on track. =A0Could you please<= br> test-drive this patch (which also contains the centering stuff) and
check if the issue is fixed by it? =A0It seems it is for me, but I only
did some very brief testing.

--8<---------------cut here---------------start------------->8---
=3D=3D=3D modified file 'lisp/doc-view.el'
--- lisp/doc-view.el =A0 =A02013-02-28 04:02:36 +0000
+++ lisp/doc-view.el =A0 =A02013-03-14 07:21:18 +0000
@@ -1250,17 +1250,33 @@
=A0 =A0(when doc-view-pending-cache-flush
=A0 =A0 =A0(clear-image-cache)
=A0 =A0 =A0(setq doc-view-pending-cache-flush nil))
- =A0(let ((ol (doc-view-current-overlay))
- =A0 =A0 =A0 =A0(image (if (and file (file-readable-p file))
+ =A0(let ((ol (doc-view-current-overlay)))
+ =A0 =A0;; ol might be a deleted (see `doc-view-new-window-function'),= in
+ =A0 =A0;; which case we don't want to modify it.
+ =A0 =A0(when (overlay-buffer ol)
+ =A0 =A0 =A0(let* ((image (if (and file (file-readable-p file))
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(if (not (and doc-= view-scale-internally
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (fbound= p 'imagemagick-types)))
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(app= ly 'create-image file doc-view--image-type nil args)
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(unless = (member :width args)
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(setq args `(,@args :width ,= doc-view-image-width)))
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(apply 'create-image file &#= 39;imagemagick nil args))))
- =A0 =A0 =A0 =A0(slice (doc-view-current-slice)))
+ =A0 =A0 =A0 =A0 =A0 =A0(slice (doc-view-current-slice))
+ =A0 =A0 =A0 =A0 =A0 =A0(img-width (and image (car (image-size image)))) + =A0 =A0 =A0 =A0 =A0 =A0(displayed-img-width (if (and image slice)
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (= * (/ (float (nth 2 slice))
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 (car (image-size image 'pixels)))
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0img-width)
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 img-w= idth))
+ =A0 =A0 =A0 =A0 =A0 =A0(window-width (window-width (selected-window)))) =A0 =A0 =A0(setf (doc-view-current-image) image)
=A0 =A0 =A0(move-overlay ol (point-min) (point-max))
+ =A0 =A0 =A0 ;; In case the window is wider than the image, center t= he image
+ =A0 =A0 =A0 ;; horizontally.
+ =A0 =A0 =A0 (overlay-put ol 'before-string
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(when (and image (> window-widt= h displayed-img-width))
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(propertize " " '= ;display
+ =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0`(spac= e :align-to (+ center (-0.5 . ,displayed-img-width))))))
=A0 =A0 =A0(overlay-put ol 'display
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 (cond
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(image
@@ -1287,7 +1303,7 @@
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(vscroll (image-mode-window-get 'vscroll= win)))
=A0 =A0 =A0 =A0 =A0 =A0;; Reset scroll settings, in case they were changed.=
=A0 =A0 =A0 =A0 =A0 =A0(if hscroll (set-window-hscroll win hscroll))
- =A0 =A0 =A0 =A0 =A0(if vscroll (set-window-vscroll win vscroll)))))))
+ =A0 =A0 =A0 =A0 =A0 =A0 (if vscroll (set-window-vscroll win vscroll))))))= )))

=A0(defun doc-view-sort (a b)
=A0 =A0"Return non-nil if A should be sorted before B.
--8<---------------cut here-----= ----------end--------------->8---

Bye,
Tassilo

--20cf30050e8a8cb95104d7e41bd6-- From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 14 11:31:33 2013 Received: (at 13887) by debbugs.gnu.org; 14 Mar 2013 15:31:33 +0000 Received: from localhost ([127.0.0.1]:54239 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGA7r-00044A-Fk for submit@debbugs.gnu.org; Thu, 14 Mar 2013 11:31:33 -0400 Received: from deliver.uni-koblenz.de ([141.26.64.15]:56762) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGA7j-00043v-72 for 13887@debbugs.gnu.org; Thu, 14 Mar 2013 11:31:25 -0400 Received: from localhost (localhost [127.0.0.1]) by deliver.uni-koblenz.de (Postfix) with ESMTP id 119331A8658; Thu, 14 Mar 2013 16:30:07 +0100 (CET) X-Virus-Scanned: amavisd-new at uni-koblenz.de Received: from deliver.uni-koblenz.de ([127.0.0.1]) by localhost (deliver.uni-koblenz.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id O8FA8t1aJsfO; Thu, 14 Mar 2013 16:30:06 +0100 (CET) X-CHKRCPT: Envelopesender noch tsdh@gnu.org Received: from thinkpad.tsdh.de (tsdh.uni-koblenz.de [141.26.67.142]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by deliver.uni-koblenz.de (Postfix) with ESMTPSA id A81EF1A864D; Thu, 14 Mar 2013 16:30:06 +0100 (CET) From: Tassilo Horn To: Stefan Monnier Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available References: <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> Date: Thu, 14 Mar 2013 16:30:05 +0100 In-Reply-To: (Stefan Monnier's message of "Thu, 14 Mar 2013 09:26:22 -0400") Message-ID: <87a9q6dmo2.fsf@thinkpad.tsdh.de> User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -3.5 (---) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, E Sabof X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.5 (---) Stefan Monnier writes: >> + (unless (eq (window-buffer) (current-buffer)) >> + (set-window-buffer (selected-window) (current-buffer))) > > This can't be the right fix: doc-view.el is just a major-mode that > controls how a particular buffer is displayed, and not which buffer to > display in which window. > > [ I see Tassilo has a better patch already, so I'll let him take care of > it, but I just wanted to point out "the obvious". ] I've committed my patch now. Evgeni, please report back if it really solves the issue for you, so that I can close this issue. Stefan, do you think the horizontal centering of images in case the window is wider than the image should be customizable? Currently it's not which is fine with me and is what other viewers also do. Bye, Tassilo From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 14 11:54:59 2013 Received: (at 13887) by debbugs.gnu.org; 14 Mar 2013 15:54:59 +0000 Received: from localhost ([127.0.0.1]:54296 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGAUX-0004ds-TO for submit@debbugs.gnu.org; Thu, 14 Mar 2013 11:54:58 -0400 Received: from mail-qa0-f45.google.com ([209.85.216.45]:54791) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGAUQ-0004dZ-1m for 13887@debbugs.gnu.org; Thu, 14 Mar 2013 11:54:52 -0400 Received: by mail-qa0-f45.google.com with SMTP id g10so2934659qah.11 for <13887@debbugs.gnu.org>; Thu, 14 Mar 2013 08:53:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=jpAE/0FBl+IT2Eg/EsDivmOs8o6oyCaX8K2QN21anAo=; b=I6dBnQdVEKY2mVgkR0weJJyeQ3GAvFVRlIafferdjWC5w97WcZrQyiP0OwLJ08ERSE JIPBiBHbAdwZVJwoTJdJpF+2sBc4ODaSSF+y75eTalzamdUtZw/7C4kkeXZPZ7xDENbj U9u134nF2L/SOhJI8hWcMnPJD+C+uw0snJwxZ60ZbjdK60iwn9HTUgKWkiZih1P+BlPP 338O6QlPi2nohhpG5sr50z63UFCHOWI2Mp53UhJ3t4hvV2x3bwV9bXj/KimSbw7EKVBD 0qQRyd+O7jed6WuncpoKmk75xyzbmjMSdmTVkorUD0FHJVaidyzq4Tq7SPDYF02gr3kj wjPA== MIME-Version: 1.0 X-Received: by 10.49.87.40 with SMTP id u8mr3109852qez.62.1363276408761; Thu, 14 Mar 2013 08:53:28 -0700 (PDT) Received: by 10.49.70.233 with HTTP; Thu, 14 Mar 2013 08:53:28 -0700 (PDT) In-Reply-To: <87a9q6dmo2.fsf@thinkpad.tsdh.de> References: <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> <87a9q6dmo2.fsf@thinkpad.tsdh.de> Date: Thu, 14 Mar 2013 15:53:28 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Tassilo Horn Content-Type: multipart/alternative; boundary=047d7bdc8b0a13344f04d7e486ac X-Spam-Score: -2.6 (--) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Stefan Monnier X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --047d7bdc8b0a13344f04d7e486ac Content-Type: text/plain; charset=ISO-8859-1 Tested the trunk version of doc-view with "emacs -Q". I am still not getting not getting an inital overlay. However I do get overlays after I zoom and split. (I still get occasional pages with no overlays after spltting if I use my default configuration) Also If you zoom/split/delete windows for a while, doc-view stops centering overlays in new windows. Evgeni On Thu, Mar 14, 2013 at 3:30 PM, Tassilo Horn wrote: > Stefan Monnier writes: > > >> + (unless (eq (window-buffer) (current-buffer)) > >> + (set-window-buffer (selected-window) (current-buffer))) > > > > This can't be the right fix: doc-view.el is just a major-mode that > > controls how a particular buffer is displayed, and not which buffer to > > display in which window. > > > > [ I see Tassilo has a better patch already, so I'll let him take care of > > it, but I just wanted to point out "the obvious". ] > > I've committed my patch now. Evgeni, please report back if it really > solves the issue for you, so that I can close this issue. > > Stefan, do you think the horizontal centering of images in case the > window is wider than the image should be customizable? Currently it's > not which is fine with me and is what other viewers also do. > > Bye, > Tassilo > --047d7bdc8b0a13344f04d7e486ac Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Tested the trunk version of doc-view with "emacs -Q&q= uot;. I am still not getting not getting an inital overlay. However I do ge= t overlays after I zoom and split. (I still get occasional pages with no ov= erlays after spltting if I use my default configuration)

Also If you zoom/split/delete windows for a while, doc= -view stops centering overlays in new windows.

Evgeni


On Thu, Mar 14, 2013 at 3:30 PM, Tassilo Horn <tsdh@gnu.org> wrot= e:
Stefan Monnier <monnier@iro.umontreal.ca> writes:

>> + =A0 =A0 =A0 =A0(unless (eq (window-buffer) (current-buffer))
>> + =A0 =A0 =A0 =A0 =A0(set-window-buffer (selected-window) (current= -buffer)))
>
> This can't be the right fix: doc-view.el is just a major-mode that=
> controls how a particular buffer is displayed, and not which buffer to=
> display in which window.
>
> [ I see Tassilo has a better patch already, so I'll let him take c= are of
> =A0 it, but I just wanted to point out "the obvious". =A0]
I've committed my patch now. =A0Evgeni, please report back = if it really
solves the issue for you, so that I can close this issue.

Stefan, do you think the horizontal centering of images in case the
window is wider than the image should be customizable? =A0Currently it'= s
not which is fine with me and is what other viewers also do.

Bye,
Tassilo

--047d7bdc8b0a13344f04d7e486ac-- From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 14 12:21:34 2013 Received: (at 13887) by debbugs.gnu.org; 14 Mar 2013 16:21:34 +0000 Received: from localhost ([127.0.0.1]:54370 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGAuL-0005Kr-Nx for submit@debbugs.gnu.org; Thu, 14 Mar 2013 12:21:34 -0400 Received: from ironport2-out.teksavvy.com ([206.248.154.182]:58431) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGAuJ-0005Kd-Hm for 13887@debbugs.gnu.org; Thu, 14 Mar 2013 12:21:31 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av4EABK/CFHO+KL9/2dsb2JhbABEvw4Xc4IeAQEEAVYjBQsLDiYSFBgNJIgeBsEtkQoDpHqBXoMT X-IPAS-Result: Av4EABK/CFHO+KL9/2dsb2JhbABEvw4Xc4IeAQEEAVYjBQsLDiYSFBgNJIgeBsEtkQoDpHqBXoMT X-IronPort-AV: E=Sophos;i="4.84,565,1355115600"; d="scan'208";a="4917358" Received: from 206-248-162-253.dsl.teksavvy.com (HELO pastel.home) ([206.248.162.253]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 14 Mar 2013 12:20:03 -0400 Received: by pastel.home (Postfix, from userid 20848) id 9BAFB67A4D; Thu, 14 Mar 2013 12:19:56 -0400 (EDT) From: Stefan Monnier To: Tassilo Horn Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available Message-ID: References: <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> <87a9q6dmo2.fsf@thinkpad.tsdh.de> Date: Thu, 14 Mar 2013 12:19:56 -0400 In-Reply-To: <87a9q6dmo2.fsf@thinkpad.tsdh.de> (Tassilo Horn's message of "Thu, 14 Mar 2013 16:30:05 +0100") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, E Sabof X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) > Stefan, do you think the horizontal centering of images in case the > window is wider than the image should be customizable? I don't see a need for it, no. If we need more flexibility in this area, I think the better option is to let the arrow keys move the picture (i.e. reduce/increase the before-string space), but it's a separate feature. Stefan From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 14 12:49:58 2013 Received: (at 13887) by debbugs.gnu.org; 14 Mar 2013 16:49:58 +0000 Received: from localhost ([127.0.0.1]:54429 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGBLl-00077E-N0 for submit@debbugs.gnu.org; Thu, 14 Mar 2013 12:49:58 -0400 Received: from deliver.uni-koblenz.de ([141.26.64.15]:37720) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGBLf-00076s-4m for 13887@debbugs.gnu.org; Thu, 14 Mar 2013 12:49:52 -0400 Received: from localhost (localhost [127.0.0.1]) by deliver.uni-koblenz.de (Postfix) with ESMTP id B870F1A8680; Thu, 14 Mar 2013 17:48:34 +0100 (CET) X-Virus-Scanned: amavisd-new at uni-koblenz.de Received: from deliver.uni-koblenz.de ([127.0.0.1]) by localhost (deliver.uni-koblenz.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id RhpX7xsXdOGM; Thu, 14 Mar 2013 17:48:34 +0100 (CET) X-CHKRCPT: Envelopesender noch tsdh@gnu.org Received: from thinkpad.tsdh.de (tsdh.uni-koblenz.de [141.26.67.142]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by deliver.uni-koblenz.de (Postfix) with ESMTPSA id 69B641A8677; Thu, 14 Mar 2013 17:48:34 +0100 (CET) From: Tassilo Horn To: E Sabof Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available References: <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> <87ip4ue95q.fsf@thinkpad.tsdh.de> Date: Thu, 14 Mar 2013 17:48:32 +0100 In-Reply-To: (E. Sabof's message of "Thu, 14 Mar 2013 15:23:41 +0000") Message-ID: <8738vydj1b.fsf@thinkpad.tsdh.de> User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -3.5 (---) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Stefan Monnier X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.5 (---) E Sabof writes: > With this patch I don't get an overlay in the initial window, and > sometimes after splitting. Gosh, indeed! I'll look into that later. Bye, Tassilo From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 14 17:44:06 2013 Received: (at 13887) by debbugs.gnu.org; 14 Mar 2013 21:44:06 +0000 Received: from localhost ([127.0.0.1]:54803 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGFwU-0006xd-CT for submit@debbugs.gnu.org; Thu, 14 Mar 2013 17:44:06 -0400 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:35362) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGFwR-0006xU-EA for 13887@debbugs.gnu.org; Thu, 14 Mar 2013 17:44:04 -0400 Received: from compute4.internal (compute4.nyi.mail.srv.osa [10.202.2.44]) by gateway1.nyi.mail.srv.osa (Postfix) with ESMTP id 77799203D1; Thu, 14 Mar 2013 17:42:49 -0400 (EDT) Received: from frontend2.nyi.mail.srv.osa ([10.202.2.161]) by compute4.internal (MEProxy); Thu, 14 Mar 2013 17:42:49 -0400 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=from:to:cc:subject:references:date :in-reply-to:message-id:mime-version:content-type; s=smtpout; bh=mujYxjZFdnYMLmio5GxYfxECgYs=; b=AzTOMd13hD0EcvmidIEpulsLGq1L zGEFv+PjXb2aXdlzKDXM0AOHZ3mmgawFw5P7kvSpM5MVUfKPvSK5NH51zynCDU8L LLJdvcsQWO9Ovw4f5FRuhuOIkwhEVNeOC4yzAx4nvMF4f/QAoAW1gbZsJaRKX90/ cGXN5LHP5kqKygQ= X-Sasl-enc: HFePuiSGp/wG6YLWRQxUEfrVzAkp+VWciJ0ZSH9VG08O 1363297369 Received: from thinkpad.tsdh.de (unknown [91.67.10.84]) by mail.messagingengine.com (Postfix) with ESMTPA id BBF3D200FAD; Thu, 14 Mar 2013 17:42:48 -0400 (EDT) From: Tassilo Horn To: E Sabof Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available References: <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> <87ip4ue95q.fsf@thinkpad.tsdh.de> <8738vydj1b.fsf@thinkpad.tsdh.de> Date: Thu, 14 Mar 2013 22:42:47 +0100 In-Reply-To: <8738vydj1b.fsf@thinkpad.tsdh.de> (Tassilo Horn's message of "Thu, 14 Mar 2013 17:48:32 +0100") Message-ID: <87620t64ko.fsf@thinkpad.tsdh.de> User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Stefan Monnier X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) Tassilo Horn writes: Hi again, >> With this patch I don't get an overlay in the initial window, and >> sometimes after splitting. > > Gosh, indeed! I'll look into that later. Ok, now I really think I've fixed it (revno 112045), although I had to add some obscure code in `doc-view-new-window-function' which adds functions doing a display refresh to a timer. If I execute the code of these functions directly in `doc-view-new-window-function', I get Lisp nesting exceeds `max-lisp-eval-depth' errors. Bye, Tassilo From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 14 21:13:05 2013 Received: (at 13887) by debbugs.gnu.org; 15 Mar 2013 01:13:05 +0000 Received: from localhost ([127.0.0.1]:55018 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGJCj-0003TF-Ab for submit@debbugs.gnu.org; Thu, 14 Mar 2013 21:13:05 -0400 Received: from mail-qe0-f50.google.com ([209.85.128.50]:43692) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGJCg-0003Sl-5B for 13887@debbugs.gnu.org; Thu, 14 Mar 2013 21:13:03 -0400 Received: by mail-qe0-f50.google.com with SMTP id k5so1621884qej.37 for <13887@debbugs.gnu.org>; Thu, 14 Mar 2013 18:11:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=iKeL9QwjWW4PTac/6U7PfySIZYkwxP7DDFo2CuMEXj8=; b=K4BxnVNsZwbABCYczSAvCXDFnXqASyJi9A1XDM3SF7XHVN/nGiSdIPDBuoaU04a61H l0EHWtkZSjtp65eJNNtVT7MBOdc12po9lw1XVhT6jgC/u56A2VEEh8vsP6+AFonYvKNu aNsvJ4AACKbWCl4lk65xW0M+Jb6NLTqP8uG9OtRe7ipBaaW2m/yE5NtLJEnOM4bD5hSE r04nqqvFSpo6UjbiKGYPDLrIPclLUtsHD3DVVRZhXBjkXGx/Q5MID2SEgd5YPWUBbLdk DyVw7dXaKdixDWR3HKjtySUdR/kgGatNU+nA9AHaA5Fj95MzImowS6sKGGxWYp1rKW+f drzw== MIME-Version: 1.0 X-Received: by 10.49.84.6 with SMTP id u6mr3828203qey.35.1363309902457; Thu, 14 Mar 2013 18:11:42 -0700 (PDT) Received: by 10.49.70.233 with HTTP; Thu, 14 Mar 2013 18:11:42 -0700 (PDT) In-Reply-To: <87620t64ko.fsf@thinkpad.tsdh.de> References: <87sj46493q.fsf@thinkpad.tsdh.de> <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> <87ip4ue95q.fsf@thinkpad.tsdh.de> <8738vydj1b.fsf@thinkpad.tsdh.de> <87620t64ko.fsf@thinkpad.tsdh.de> Date: Fri, 15 Mar 2013 01:11:42 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Tassilo Horn Content-Type: multipart/alternative; boundary=047d7bdc093474711204d7ec5294 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Stefan Monnier X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --047d7bdc093474711204d7ec5294 Content-Type: text/plain; charset=ISO-8859-1 Now it works in "emacs -Q", but not with my configuration. To be honest I don't think it's worth coding something final on top of current image-mode's API - it looks under-developed at several points. a) Is all the "window t" stuff necessary? Does anyone really care what is "shown" in a buffer unless it's displayed in a window? b) If yes, should "window t" be passed to a public hook? c) Does (image-get-display-property) have any business asking what buffer is currently selected in the window? d) Why data is sometimes retrieved from the the buffer (as in ( image-get-display-property)), and sometimes from image-mode-winprops-alist (as in (image-mode-winprops))? Is the complexity justified, or is one of the methods "legacy"? I use image viewers, so I could try re-factoring it, adding H/V centering, improving zooming options, and extending the API. Evgeni On Thu, Mar 14, 2013 at 9:42 PM, Tassilo Horn wrote: > Tassilo Horn writes: > > Hi again, > > >> With this patch I don't get an overlay in the initial window, and > >> sometimes after splitting. > > > > Gosh, indeed! I'll look into that later. > > Ok, now I really think I've fixed it (revno 112045), although I had to > add some obscure code in `doc-view-new-window-function' which adds > functions doing a display refresh to a timer. If I execute the code of > these functions directly in `doc-view-new-window-function', I get Lisp > nesting exceeds `max-lisp-eval-depth' errors. > > Bye, > Tassilo > --047d7bdc093474711204d7ec5294 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Now it works in "emacs -Q", but not with my conf= iguration. To be honest I don't think it's worth coding something f= inal on top of current image-mode's=A0API - it looks under-developed=A0= at several points.

a) Is all the "window t" stuff necessary? Do= es anyone really care what is "shown" in a buffer unless it's= displayed in a window?
b) If yes, should "window t&qu= ot; be passed to a public hook?
c) Does (image-get-display-prop= erty) have any=A0business=A0asking what buffer is currently selected in the= window?
d) Why dat= a is sometimes retrieved from the the buffer (as in (image-get-display-property)), and sometimes from=A0image-mode-winpro= ps-alist (as in (image-mode-winprop= s))? Is the complexity = justified, or is one of the methods "legacy"?

I use image viewers, so I could t= ry=A0re-factoring=A0it,=A0adding H/V centering, improving zooming options, and extending the API.<= /span>

Evgeni



On Thu, Mar 14, 2013 at 9:42 PM, Tassilo= Horn <tsdh@gnu.org> wrote:
Tassilo Horn <tsdh@gnu.org> write= s:

Hi again,

>> With this patch I don't get an overlay in the initial window, = and
>> sometimes after splitting.
>
> Gosh, indeed! =A0I'll look into that later.

Ok, now I really think I've fixed it (revno 112045), although I h= ad to
add some obscure code in `doc-view-new-window-function' which adds
functions doing a display refresh to a timer. =A0If I execute the code of these functions directly in `doc-view-new-window-function', I get Lisp<= br> nesting exceeds `max-lisp-eval-depth' errors.

Bye,
Tassilo

--047d7bdc093474711204d7ec5294-- From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 15 08:53:55 2013 Received: (at 13887) by debbugs.gnu.org; 15 Mar 2013 12:53:55 +0000 Received: from localhost ([127.0.0.1]:55642 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGU8x-00045C-8o for submit@debbugs.gnu.org; Fri, 15 Mar 2013 08:53:55 -0400 Received: from ironport2-out.teksavvy.com ([206.248.154.182]:13193) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGU8v-000450-AQ for 13887@debbugs.gnu.org; Fri, 15 Mar 2013 08:53:53 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av4EABK/CFHO+KL9/2dsb2JhbABEvw4Xc4IeAQEEAVYjBQsLNBIUGA0kiB4GwS2RCgOkeoFegxOBSiQ X-IPAS-Result: Av4EABK/CFHO+KL9/2dsb2JhbABEvw4Xc4IeAQEEAVYjBQsLNBIUGA0kiB4GwS2RCgOkeoFegxOBSiQ X-IronPort-AV: E=Sophos;i="4.84,565,1355115600"; d="scan'208";a="4977591" Received: from 206-248-162-253.dsl.teksavvy.com (HELO pastel.home) ([206.248.162.253]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 15 Mar 2013 08:52:28 -0400 Received: by pastel.home (Postfix, from userid 20848) id 1186567A61; Fri, 15 Mar 2013 08:52:30 -0400 (EDT) From: Stefan Monnier To: E Sabof Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available Message-ID: References: <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> <87ip4ue95q.fsf@thinkpad.tsdh.de> <8738vydj1b.fsf@thinkpad.tsdh.de> <87620t64ko.fsf@thinkpad.tsdh.de> Date: Fri, 15 Mar 2013 08:52:30 -0400 In-Reply-To: (E. Sabof's message of "Fri, 15 Mar 2013 01:11:42 +0000") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Tassilo Horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) > a) Is all the "window t" stuff necessary? > Does anyone really care what is "shown" in a buffer unless it's > displayed in a window? It's not a question of caring: it's a mechanism. If you "move to next page" before displaying the buffer, then yes, you probably care. In most cases you don't, but then this "window t stuff" shouldn't hurt you one bit either. > c) Does (image-get-display-property) have any business asking what buffer > is currently selected in the window? Good question. It shouldn't hurt, but maybe it's a mistake. > d) Why data is sometimes retrieved from the the buffer (as in ( > image-get-display-property)), and sometimes from image-mode-winprops-alist > (as in (image-mode-winprops))? Is the complexity justified, or is one of > the methods "legacy"? Can't remember, sorry. That's a good question, tho. I do remember that part of the motivation behind the design was that: - several windows need to be able to display different pages (or different parts of the same page) of the same doc-view buffer. - "current page and page position" info needs to be preserved while the buffer is not shown, so that you can temporarily switch to some other buffer and then switch back to the doc-view buffer without finding yourself back at page 1. Stefan From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 15 09:36:01 2013 Received: (at 13887) by debbugs.gnu.org; 15 Mar 2013 13:36:01 +0000 Received: from localhost ([127.0.0.1]:55726 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGUng-00056w-MZ for submit@debbugs.gnu.org; Fri, 15 Mar 2013 09:36:00 -0400 Received: from mail-qe0-f53.google.com ([209.85.128.53]:64001) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGUne-00056k-Pn for 13887@debbugs.gnu.org; Fri, 15 Mar 2013 09:35:59 -0400 Received: by mail-qe0-f53.google.com with SMTP id cz11so1866990qeb.40 for <13887@debbugs.gnu.org>; Fri, 15 Mar 2013 06:34:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=M7yYr2RV05MO1OWj5jGHXijJ2Gv4/doyLQpa2/PeewI=; b=CtDl/h6rt21SR2zGCNbQfYy+EvWWB2T+bpyBeSYZ3ckeE60b3O8+5DlWX/Q5ErjJgc CKP6zszIHq6qJK1yavJYa+vAijJmuuLK5Fk7Fy2STafHURwpDXLOp12ScHYbwQgrG0Id ighoFzDFPZcbDgIrc8MpvF8ewcfuNhJEzWoye+veVqjjCUr023i5ZrxUsvgzFFIk8xdP Eb6CVTOanH9ShjzW4J1kDaYVGgNumfD2l9I5wMNjeilbCiLrFRC5m1+wzPA1DGeEacxA Dhi2yMvpn8KdG20JOHBQ1lxFU7gTT0ULn/Nug6R78wdXMkw4EhShjumoujKzhAHiWZn1 ccLg== MIME-Version: 1.0 X-Received: by 10.224.27.136 with SMTP id i8mr5628965qac.63.1363354476189; Fri, 15 Mar 2013 06:34:36 -0700 (PDT) Received: by 10.49.70.233 with HTTP; Fri, 15 Mar 2013 06:34:35 -0700 (PDT) In-Reply-To: References: <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> <87ip4ue95q.fsf@thinkpad.tsdh.de> <8738vydj1b.fsf@thinkpad.tsdh.de> <87620t64ko.fsf@thinkpad.tsdh.de> Date: Fri, 15 Mar 2013 13:34:35 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Stefan Monnier Content-Type: multipart/alternative; boundary=bcaec51b1593419f0304d7f6b35c X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Tassilo Horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --bcaec51b1593419f0304d7f6b35c Content-Type: text/plain; charset=ISO-8859-1 On Fri, Mar 15, 2013 at 12:52 PM, Stefan Monnier wrote: > > a) Is all the "window t" stuff necessary? > > Does anyone really care what is "shown" in a buffer unless it's > > displayed in a window? > > It's not a question of caring: it's a mechanism. > > If you "move to next page" before displaying the buffer, then yes, you > probably care. In most cases you don't, but then this "window t stuff" > shouldn't hurt you one bit either. I should have said "associated" instead of "displayed". What I'm trying to say is that a certain window is always selected. If a buffer is not being displayed, I associate data with the selected window, and later show it in the same window, the right thing should happen. If I display it in a different window. Either a) The window already has data, so it will be used. b) The window doesn't have data, so it will take data I have just set. I think the above behavior is acceptable. I don't know if it's any different from the current. Evgeni --bcaec51b1593419f0304d7f6b35c Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable



On Fri, Mar 15, 2013 at 12:52 PM, Stefan Monnier = <monnier@i= ro.umontreal.ca> wrote:
> a) Is all the "w= indow t" stuff necessary?
> Does anyone really care what is "shown" in a buffer unless i= t's
> displayed in a window?

It's not a question of caring: it's a mechanism.

If you "move to next page" before displaying the buffer, then yes= , you
probably care. =A0In most cases you don't, but then this "window t= stuff"
shouldn't hurt you one bit either.

I should have said "associated" instead of "displayed"= ;.=A0

What I'm trying to say is th= at a certain window is always selected. If a buffer is not being displayed,= I associate data with the selected window, and later show it in the same w= indow, the right thing should happen. If I display it in a different window= . Either a) The window already has data, so it will be used. b) The window = doesn't have data, so it will take data I have just set.

I think the above=A0behavior=A0is acceptabl= e. I don't know if it's any different from the current.

Evgeni
--bcaec51b1593419f0304d7f6b35c-- From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 15 09:57:21 2013 Received: (at 13887) by debbugs.gnu.org; 15 Mar 2013 13:57:21 +0000 Received: from localhost ([127.0.0.1]:56418 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGV8G-0005lV-7N for submit@debbugs.gnu.org; Fri, 15 Mar 2013 09:57:18 -0400 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:57896) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGV7r-0005l5-Fy for 13887@debbugs.gnu.org; Fri, 15 Mar 2013 09:56:52 -0400 Received: from compute3.internal (compute3.nyi.mail.srv.osa [10.202.2.43]) by gateway1.nyi.mail.srv.osa (Postfix) with ESMTP id 936AE2071E; Fri, 15 Mar 2013 09:55:33 -0400 (EDT) Received: from frontend1.nyi.mail.srv.osa ([10.202.2.160]) by compute3.internal (MEProxy); Fri, 15 Mar 2013 09:55:33 -0400 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=from:to:cc:subject:references:date :in-reply-to:message-id:mime-version:content-type; s=smtpout; bh=saFVWSQxhr8TS2dQpHvZT42tU2E=; b=TGIOGnAd2E3+hQWKGSMzOElCp74M qYwZMS6i0BHmUE3wapp2jeUylmKDhXsGBoZCTMPycllSRpifuAeAxkvQTRGRWKNG zE9OZEJjyfz6GHPxtcW9wRsv1WxaZImHSEotuIb7hgt7rhuNX4YBKNNtrNXUr/Rh c/pXSeHIRhG6T9Y= X-Sasl-enc: bCNXPFOMZMYq5YnQPdAPJYrFF6WPFKVY4i2i1E0DPpnt 1363355733 Received: from thinkpad.tsdh.de (unknown [91.67.10.84]) by mail.messagingengine.com (Postfix) with ESMTPA id DCBA8C80E8A; Fri, 15 Mar 2013 09:55:32 -0400 (EDT) From: Tassilo Horn To: E Sabof Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available References: <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> <87ip4ue95q.fsf@thinkpad.tsdh.de> <8738vydj1b.fsf@thinkpad.tsdh.de> <87620t64ko.fsf@thinkpad.tsdh.de> Date: Fri, 15 Mar 2013 14:55:31 +0100 In-Reply-To: (E. Sabof's message of "Fri, 15 Mar 2013 01:11:42 +0000") Message-ID: <87wqt8938s.fsf@thinkpad.tsdh.de> User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Stefan Monnier X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) E Sabof writes: > Now it works in "emacs -Q", but not with my configuration. Do you mind to share your configuration? Bye, Tassilo From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 15 10:10:22 2013 Received: (at 13887) by debbugs.gnu.org; 15 Mar 2013 14:10:22 +0000 Received: from localhost ([127.0.0.1]:56439 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGVKv-00064f-On for submit@debbugs.gnu.org; Fri, 15 Mar 2013 10:10:22 -0400 Received: from mail-qe0-f46.google.com ([209.85.128.46]:35761) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGVKs-00064S-ET for 13887@debbugs.gnu.org; Fri, 15 Mar 2013 10:10:20 -0400 Received: by mail-qe0-f46.google.com with SMTP id a11so1937937qen.33 for <13887@debbugs.gnu.org>; Fri, 15 Mar 2013 07:08:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=tcpFf6CLFufwGVsX8Hzat+6AXVrsdUiZjYjZxLICV6Y=; b=TzaWfHXOqjnc6DOBlGEz+R6W3elXQgjN7UCfRwqnRn6SnCQuNvG7uqUZsqQAenibOM FcX2KBby6ZkSsuIXyYIDod/pd+E0cQKoJgwDawNQaMjcnm1CqLLpyDV9Qa7VhCic+P5W wW75ER8f4BykPq/FTQS42MRdzUlNXnvmGt8/Gz+SOPb1ksBzwAWgN3vnwm0RCebEVePe L9aw6OJ+iD2SGvh4BfZW0w8CXvioluyvf+kpqPvTKtgiMG9NQIZebDJ4jOdJrXSTyvU5 mB0OqDrcD7Q79tTHjoukNhEAvGGDh+OwsaK2795piTJG1SEmqM2PN/20YYwFcSNJS8mX 5beg== MIME-Version: 1.0 X-Received: by 10.224.199.70 with SMTP id er6mr5817599qab.19.1363356535722; Fri, 15 Mar 2013 07:08:55 -0700 (PDT) Received: by 10.49.70.233 with HTTP; Fri, 15 Mar 2013 07:08:55 -0700 (PDT) In-Reply-To: <87wqt8938s.fsf@thinkpad.tsdh.de> References: <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> <87ip4ue95q.fsf@thinkpad.tsdh.de> <8738vydj1b.fsf@thinkpad.tsdh.de> <87620t64ko.fsf@thinkpad.tsdh.de> <87wqt8938s.fsf@thinkpad.tsdh.de> Date: Fri, 15 Mar 2013 14:08:55 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Tassilo Horn Content-Type: multipart/alternative; boundary=20cf30050e8a0395c204d7f72ecd X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Stefan Monnier X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --20cf30050e8a0395c204d7f72ecd Content-Type: text/plain; charset=ISO-8859-1 I've checked again, sometimes it works, sometimes it doesn't. My configuration is rather large. It would be a lot easier for me to try and find the differences than for someone else. Evgeni On Fri, Mar 15, 2013 at 1:55 PM, Tassilo Horn wrote: > E Sabof writes: > > > Now it works in "emacs -Q", but not with my configuration. > > Do you mind to share your configuration? > > Bye, > Tassilo > --20cf30050e8a0395c204d7f72ecd Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
I've checked again, sometimes it works, sometimes it d= oesn't.=A0

My configuration is rather large. I= t would be a lot easier for me to try and find the differences than for som= eone else.

Evgeni



On Fri, Mar 15, 2= 013 at 1:55 PM, Tassilo Horn <tsdh@gnu.org> wrote:
E Sabof <esabof@gmail.com> writes:

> Now it works in "emacs -Q", but not with my configuration.
Do you mind to share your configuration?

Bye,
Tassilo

--20cf30050e8a0395c204d7f72ecd-- From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 15 13:52:38 2013 Received: (at 13887) by debbugs.gnu.org; 15 Mar 2013 17:52:38 +0000 Received: from localhost ([127.0.0.1]:56699 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGYo1-000322-J8 for submit@debbugs.gnu.org; Fri, 15 Mar 2013 13:52:37 -0400 Received: from ironport2-out.teksavvy.com ([206.248.154.182]:8659) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGYnz-00031l-98 for 13887@debbugs.gnu.org; Fri, 15 Mar 2013 13:52:35 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av4EABK/CFHO+IB4/2dsb2JhbABEvw4Xc4IeAQEEAVYjBQsLNBIUGA0kiB4GwS2RCgOkeoFegxM X-IPAS-Result: Av4EABK/CFHO+IB4/2dsb2JhbABEvw4Xc4IeAQEEAVYjBQsLNBIUGA0kiB4GwS2RCgOkeoFegxM X-IronPort-AV: E=Sophos;i="4.84,565,1355115600"; d="scan'208";a="5003982" Received: from 206-248-128-120.dsl.teksavvy.com (HELO pastel.home) ([206.248.128.120]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 15 Mar 2013 13:51:09 -0400 Received: by pastel.home (Postfix, from userid 20848) id 1CB45678BF; Fri, 15 Mar 2013 13:51:11 -0400 (EDT) From: Stefan Monnier To: E Sabof Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available Message-ID: References: <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> <87ip4ue95q.fsf@thinkpad.tsdh.de> <8738vydj1b.fsf@thinkpad.tsdh.de> <87620t64ko.fsf@thinkpad.tsdh.de> Date: Fri, 15 Mar 2013 13:51:11 -0400 In-Reply-To: (E. Sabof's message of "Fri, 15 Mar 2013 13:34:35 +0000") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.5 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Tassilo Horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) > What I'm trying to say is that a certain window is always selected. If a > buffer is not being displayed, I associate data with the selected window, > and later show it in the same window, the right thing should happen. If I > display it in a different window. Either a) The window already has data, so > it will be used. b) The window doesn't have data, so it will take data I > have just set. > I think the above behavior is acceptable. It's probably fine as well, yes. > I don't know if it's any different from the current. It probably is in various corner cases. Not sure if it matters. Stefan From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 15 19:27:59 2013 Received: (at 13887) by debbugs.gnu.org; 15 Mar 2013 23:27:59 +0000 Received: from localhost ([127.0.0.1]:56916 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGe2Y-0002oA-WB for submit@debbugs.gnu.org; Fri, 15 Mar 2013 19:27:59 -0400 Received: from mail-qc0-f180.google.com ([209.85.216.180]:38724) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGe2V-0002nx-Je for 13887@debbugs.gnu.org; Fri, 15 Mar 2013 19:27:56 -0400 Received: by mail-qc0-f180.google.com with SMTP id v28so1838027qcm.11 for <13887@debbugs.gnu.org>; Fri, 15 Mar 2013 16:26:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=ZtlY2iwL15HhmCe26o2WgmJDqrPsZoWZRMLY3MR8vVg=; b=iyKA7uX2hpdBl+6CyNfqjZJZZbsvU2Uwz7p0Fo3dir38B4o8q1Nc/VqX24jYC3t18f PCooYhPpQr3S+CCeA1nA7PYh6DDi2O3F0GjFYKnb9V00byeRY0ZWzIcTD58uuzY7Ub+y q6SeUXo05Y9TcEsjqkWsR5Gq3zxS2MT40bpfPK2ScuQhkMuWL0ykO/FtGu8j+Cv3oGqG gN5IKrKxVfWVXHEsvq3pdJX87Z0xOga/Y3/gngyZxEdz/HAIhkcZ8NPvYUilgUNDTove MEf4CzhxuO+uiV9RENK17y9JYfLxJh/GpetcpDW0A2f8cd71xrKBII/wJSmFI+OhrvfD 7aSQ== MIME-Version: 1.0 X-Received: by 10.224.108.4 with SMTP id d4mr8491044qap.83.1363389990657; Fri, 15 Mar 2013 16:26:30 -0700 (PDT) Received: by 10.49.70.233 with HTTP; Fri, 15 Mar 2013 16:26:30 -0700 (PDT) In-Reply-To: References: <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> <87ip4ue95q.fsf@thinkpad.tsdh.de> <8738vydj1b.fsf@thinkpad.tsdh.de> <87620t64ko.fsf@thinkpad.tsdh.de> Date: Fri, 15 Mar 2013 23:26:30 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Stefan Monnier Content-Type: multipart/alternative; boundary=20cf3074b16a1567c604d7fef8e1 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Tassilo Horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --20cf3074b16a1567c604d7fef8e1 Content-Type: text/plain; charset=ISO-8859-1 Should I try to patch it? Without "window t" image-mode would be more predictable. Evgeni On Fri, Mar 15, 2013 at 5:51 PM, Stefan Monnier wrote: > > What I'm trying to say is that a certain window is always selected. If a > > buffer is not being displayed, I associate data with the selected window, > > and later show it in the same window, the right thing should happen. If I > > display it in a different window. Either a) The window already has data, > so > > it will be used. b) The window doesn't have data, so it will take data I > > have just set. > > I think the above behavior is acceptable. > > It's probably fine as well, yes. > > > I don't know if it's any different from the current. > > It probably is in various corner cases. Not sure if it matters. > > > Stefan > --20cf3074b16a1567c604d7fef8e1 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Should I try to patch it? Without "window t" ima= ge-mode would be more predictable.

Evgeni


On Fri, Ma= r 15, 2013 at 5:51 PM, Stefan Monnier <monnier@iro.umontreal.ca= > wrote:
> What I'm trying t= o say is that a certain window is always selected. If a
> buffer is not being displayed, I associate data with the selected wind= ow,
> and later show it in the same window, the right thing should happen. I= f I
> display it in a different window. Either a) The window already has dat= a, so
> it will be used. b) The window doesn't have data, so it will take = data I
> have just set.
> I think the above behavior is acceptable.

It's probably fine as well, yes.

> I don't know if it's any different from the current.

It probably is in various corner cases. =A0Not sure if it matters.

=A0 =A0 =A0 =A0 Stefan

--20cf3074b16a1567c604d7fef8e1-- From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 16 09:42:35 2013 Received: (at 13887) by debbugs.gnu.org; 16 Mar 2013 13:42:35 +0000 Received: from localhost ([127.0.0.1]:57451 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGrNa-0007Ap-Ma for submit@debbugs.gnu.org; Sat, 16 Mar 2013 09:42:34 -0400 Received: from ironport2-out.teksavvy.com ([206.248.154.182]:46756) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UGrNX-0007Ac-UH for 13887@debbugs.gnu.org; Sat, 16 Mar 2013 09:42:32 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av4EABK/CFFFxIIq/2dsb2JhbABEvw4Xc4IeAQEEAVYjBQsLNBIUGA0kiB4GwS2RCgOkeoFegxM X-IPAS-Result: Av4EABK/CFFFxIIq/2dsb2JhbABEvw4Xc4IeAQEEAVYjBQsLNBIUGA0kiB4GwS2RCgOkeoFegxM X-IronPort-AV: E=Sophos;i="4.84,565,1355115600"; d="scan'208";a="5053070" Received: from 69-196-130-42.dsl.teksavvy.com (HELO pastel.home) ([69.196.130.42]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 16 Mar 2013 09:41:01 -0400 Received: by pastel.home (Postfix, from userid 20848) id D599767B17; Sat, 16 Mar 2013 09:41:02 -0400 (EDT) From: Stefan Monnier To: E Sabof Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available Message-ID: References: <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> <87ip4ue95q.fsf@thinkpad.tsdh.de> <8738vydj1b.fsf@thinkpad.tsdh.de> <87620t64ko.fsf@thinkpad.tsdh.de> Date: Sat, 16 Mar 2013 09:41:02 -0400 In-Reply-To: (E. Sabof's message of "Fri, 15 Mar 2013 23:26:30 +0000") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Tassilo Horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) > Should I try to patch it? Without "window t" image-mode would be more > predictable. I don't know. Stefan From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 16 19:32:30 2013 Received: (at 13887) by debbugs.gnu.org; 16 Mar 2013 23:32:30 +0000 Received: from localhost ([127.0.0.1]:58201 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UH0aT-00047n-QT for submit@debbugs.gnu.org; Sat, 16 Mar 2013 19:32:30 -0400 Received: from mail-qa0-f43.google.com ([209.85.216.43]:56064) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UH0aQ-00047Z-BW for 13887@debbugs.gnu.org; Sat, 16 Mar 2013 19:32:28 -0400 Received: by mail-qa0-f43.google.com with SMTP id dx4so1017474qab.2 for <13887@debbugs.gnu.org>; Sat, 16 Mar 2013 16:30:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=fpJIS/5ZEHiOuA9eX2sGtHHuYNNaDGVdZVGhu62Qq+k=; b=IxAVsui67qcN0NFvmXJHwD+A9fszOOO57Tys7auFIGEhaOsHcDPGpxxfMRQzRV2jrD +3xRY9TcLFxUY2Nr1f6MiexzV6/46/QWMrP88jErwP3s4FZgQ+mupNv4IaljLagnwRFY PMXztUOUKjbt9FseOBrv8u8zylS/koXpj05GVBEnWy1nqYm2321NvicNjnOT3HmbNE8N Rf8YYxJmy1mxw0eJmhnFpvoVdRNglO4hnDLb9q+TpRbevI3bZjfXDbbNUd+YfJab3D2Q 7DKIAlI7jEsB0gedsyPwOMyadslTzeEjg2HzxlA9jSJZdpaso8Xp3080oakJIKSi28Nr bVQA== MIME-Version: 1.0 X-Received: by 10.49.84.6 with SMTP id u6mr14371659qey.35.1363476655826; Sat, 16 Mar 2013 16:30:55 -0700 (PDT) Received: by 10.49.70.233 with HTTP; Sat, 16 Mar 2013 16:30:55 -0700 (PDT) In-Reply-To: References: <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> <87ip4ue95q.fsf@thinkpad.tsdh.de> <8738vydj1b.fsf@thinkpad.tsdh.de> <87620t64ko.fsf@thinkpad.tsdh.de> Date: Sat, 16 Mar 2013 23:30:55 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Stefan Monnier Content-Type: multipart/alternative; boundary=047d7bdc0934baf31a04d81325bb X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Tassilo Horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --047d7bdc0934baf31a04d81325bb Content-Type: text/plain; charset=ISO-8859-1 There is a case where I initialize a mode in one window, show it in another, move down several pages, and then switch to the buffer in the first window (and the first page will be shown instead of the current). If my understanding is correct, initialization is the only place in which the behavior of "window t" is evident and beneficial. I'm not sure what I dislike the least. "window t" and the need to track window-buffer, a dedicated initialization mechanism, or switching to "fully initialized mode" the first time a real window is processed. I suppose I could try finding what goes wrong with the current patch in the meanwhile. I think that my previous experiment suggests a confusion regarding the value of (window-buffer) is a likely cause of this bug. Evgeni On Sat, Mar 16, 2013 at 1:41 PM, Stefan Monnier wrote: > > Should I try to patch it? Without "window t" image-mode would be more > > predictable. > > I don't know. > > > Stefan > --047d7bdc0934baf31a04d81325bb Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
There is a case where I initialize a mode in one wind= ow, show it in another,
move down several pages, and then switch = to the buffer in the first window (and
the first page will be sho= wn instead of the current).

If my understanding is correct, initialization is the o= nly place in which the
behavior of "window t" is eviden= t and beneficial.

I'm not sure what I dislike = the least. "window t" and the need to track
window-buffer, a dedicated initialization mechanism, or switching to &= quot;fully
initialized mode" the first time a real window is= processed.

I suppose I could try finding what goe= s wrong with the current patch in the
meanwhile. I think that my previous experiment suggests a confusion re= garding
the value of (window-buffer) is a likely cause of this bu= g.

Evgeni


On Sat, Mar 16, 2013 at 1:41 PM, Stefan = Monnier <monnier@iro.umontreal.ca> wrote:
> Should I try to patch it? Without "window t&quo= t; image-mode would be more
> predictable.

I don't know.


=A0 =A0 =A0 =A0 Stefan

--047d7bdc0934baf31a04d81325bb-- From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 20 12:00:55 2013 Received: (at 13887) by debbugs.gnu.org; 20 Mar 2013 16:00:56 +0000 Received: from localhost ([127.0.0.1]:37814 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UILRZ-00057B-6V for submit@debbugs.gnu.org; Wed, 20 Mar 2013 12:00:52 -0400 Received: from mail-qc0-f178.google.com ([209.85.216.178]:62149) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UILRM-00056o-Os for 13887@debbugs.gnu.org; Wed, 20 Mar 2013 12:00:42 -0400 Received: by mail-qc0-f178.google.com with SMTP id d10so234961qca.9 for <13887@debbugs.gnu.org>; Wed, 20 Mar 2013 08:58:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=XCBuCz91+cFedckTgUb0eU3P8Oi+oJp729FUBkYpFFw=; b=ln01udLzg28bNzTXijXH0+VOc9VeXuwnKeGXBT5RjObOeDeFvv35hlOtxfy6R5LEgY dFkDX6PZVVt8s4/D3v5iZjRb9mc4CRjUhWTTL8pdlM16Rj65xjqxmoyVIksZ5E4pGCeT aQXPHP+FD7uX9pd9+mOy9BR2N7GBralFeANqG8zh2s4g8HsXxz5Ii32VOQdy2W3nFz+H feIQ4lB9MSVlGcSWV2MU9nF6v2S2dilH7i4gcMf+y468PcQmO0Bv6xIZriqve3SAB0H9 CuKHl4ZCFazAHlP7UpaJmJRYGm8V4vyJsp9qixIj+WMmCM0pdAzS21y6/pEobEorNU26 Z1Xw== MIME-Version: 1.0 X-Received: by 10.224.71.16 with SMTP id f16mr6811683qaj.31.1363795130428; Wed, 20 Mar 2013 08:58:50 -0700 (PDT) Received: by 10.49.70.233 with HTTP; Wed, 20 Mar 2013 08:58:50 -0700 (PDT) In-Reply-To: <87wqt8938s.fsf@thinkpad.tsdh.de> References: <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> <87ip4ue95q.fsf@thinkpad.tsdh.de> <8738vydj1b.fsf@thinkpad.tsdh.de> <87620t64ko.fsf@thinkpad.tsdh.de> <87wqt8938s.fsf@thinkpad.tsdh.de> Date: Wed, 20 Mar 2013 15:58:50 +0000 Message-ID: Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available From: E Sabof To: Tassilo Horn Content-Type: multipart/alternative; boundary=bcaec51b1b974bb46804d85d4cfe X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Stefan Monnier X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) --bcaec51b1b974bb46804d85d4cfe Content-Type: text/plain; charset=ISO-8859-1 It sometimes happens when the images are retrieved from cache. I'll try to simplify my config a bit, and send you a link in a PM. Evgeni --bcaec51b1b974bb46804d85d4cfe Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
It sometimes=A0happens=A0when the images are retrieved fro= m cache. I'll try to=A0simplify=A0my config a bit, and send you a link = in a PM.

Evgeni
--bcaec51b1b974bb46804d85d4cfe-- From debbugs-submit-bounces@debbugs.gnu.org Thu Sep 26 13:16:47 2019 Received: (at 13887) by debbugs.gnu.org; 26 Sep 2019 17:16:47 +0000 Received: from localhost ([127.0.0.1]:44639 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iDXNm-0004f1-UI for submit@debbugs.gnu.org; Thu, 26 Sep 2019 13:16:47 -0400 Received: from quimby.gnus.org ([80.91.231.51]:36728) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iDXNh-0004aI-Q1 for 13887@debbugs.gnu.org; Thu, 26 Sep 2019 13:16:45 -0400 Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=marnie) by quimby.gnus.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1iDXNc-0005dO-35; Thu, 26 Sep 2019 19:16:38 +0200 From: Lars Ingebrigtsen To: E Sabof Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available References: <877gle1etb.fsf@thinkpad.tsdh.de> <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> <87ip4ue95q.fsf@thinkpad.tsdh.de> <8738vydj1b.fsf@thinkpad.tsdh.de> <87620t64ko.fsf@thinkpad.tsdh.de> <87wqt8938s.fsf@thinkpad.tsdh.de> Date: Thu, 26 Sep 2019 19:16:35 +0200 In-Reply-To: (E. Sabof's message of "Wed, 20 Mar 2013 15:58:50 +0000") Message-ID: <87sgojm0zw.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: E Sabof writes: > It sometimes happens when the images are retrieved from cache. I'll try to > simplify my config a bit, and send you a link in a PM. This the last entry in this very long bug report. I'm not sure whether everything was resolved or not, though: doc-view-scale-internally was added, which should help with some of these problems. Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Stefan Monnier , Tassilo Horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) E Sabof writes: > It sometimes happens when the images are retrieved from cache. I'll try to > simplify my config a bit, and send you a link in a PM. This the last entry in this very long bug report. I'm not sure whether everything was resolved or not, though: doc-view-scale-internally was added, which should help with some of these problems. PDFs render well for me. Are you still seeing these problems in Emacs 27? -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Thu Sep 26 13:16:51 2019 Received: (at control) by debbugs.gnu.org; 26 Sep 2019 17:16:51 +0000 Received: from localhost ([127.0.0.1]:44641 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iDXNr-0004iY-Bq for submit@debbugs.gnu.org; Thu, 26 Sep 2019 13:16:51 -0400 Received: from quimby.gnus.org ([80.91.231.51]:36744) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iDXNm-0004eI-8d for control@debbugs.gnu.org; Thu, 26 Sep 2019 13:16:46 -0400 Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=marnie) by quimby.gnus.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1iDXNj-0005dV-Fe for control@debbugs.gnu.org; Thu, 26 Sep 2019 19:16:45 +0200 Date: Thu, 26 Sep 2019 19:16:43 +0200 Message-Id: <87r243m0zo.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #13887 X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: tags 13887 + moreinfo quit Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) tags 13887 + moreinfo quit From debbugs-submit-bounces@debbugs.gnu.org Mon Oct 14 02:04:52 2019 Received: (at 13887) by debbugs.gnu.org; 14 Oct 2019 06:04:52 +0000 Received: from localhost ([127.0.0.1]:37730 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iJtTN-0006wL-1c for submit@debbugs.gnu.org; Mon, 14 Oct 2019 02:04:49 -0400 Received: from [80.91.231.51] (port=50186 helo=quimby.gnus.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iJtTJ-0006w5-54 for 13887@debbugs.gnu.org; Mon, 14 Oct 2019 02:04:45 -0400 Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=marnie) by quimby.gnus.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1iJtTB-0002MB-4U; Mon, 14 Oct 2019 08:04:41 +0200 From: Lars Ingebrigtsen To: E Sabof Subject: Re: bug#13887: 24.3; doc-view will render blurry images when image-magick is available References: <838v5tx4av.fsf@gnu.org> <87txohx0g0.fsf@thinkpad.tsdh.de> <831ubllqr0.fsf@gnu.org> <87zjy9vg0r.fsf@thinkpad.tsdh.de> <83y5dtk606.fsf@gnu.org> <83li9sk1bh.fsf@gnu.org> <83hakgjpbi.fsf@gnu.org> <87ip4ue95q.fsf@thinkpad.tsdh.de> <8738vydj1b.fsf@thinkpad.tsdh.de> <87620t64ko.fsf@thinkpad.tsdh.de> <87wqt8938s.fsf@thinkpad.tsdh.de> <87sgojm0zw.fsf@gnus.org> Date: Mon, 14 Oct 2019 08:04:36 +0200 In-Reply-To: <87sgojm0zw.fsf@gnus.org> (Lars Ingebrigtsen's message of "Thu, 26 Sep 2019 19:16:35 +0200") Message-ID: <871rvfooaz.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Lars Ingebrigtsen writes: > E Sabof writes: > >> It sometimes happens when the images are retrieved from cache. I'll try to >> simplify my config a bit, and send you a link in a PM. > > This the last entry i [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 1.3 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: Lars Ingebrigtsen writes: > E Sabof writes: > >> It sometimes happens when the images are retrieved from cache. I'll try to >> simplify my config a bit, and send you a link in a PM. > > This the last entry i [...] Content analysis details: (1.3 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 URIBL_BLOCKED ADMINISTRATOR NOTICE: The query to URIBL was blocked. See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [URIs: gnus.org] 0.0 SPF_NONE SPF: sender does not publish an SPF Record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 1.3 RDNS_NONE Delivered to internal network by a host with no rDNS X-Debbugs-Envelope-To: 13887 Cc: 13887@debbugs.gnu.org, Stefan Monnier , Tassilo Horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 0.3 (/) Lars Ingebrigtsen writes: > E Sabof writes: > >> It sometimes happens when the images are retrieved from cache. I'll try to >> simplify my config a bit, and send you a link in a PM. > > This the last entry in this very long bug report. I'm not sure whether > everything was resolved or not, though: doc-view-scale-internally was > added, which should help with some of these problems. > > PDFs render well for me. > > Are you still seeing these problems in Emacs 27? More information was requested some weeks back, but no response was given, so I'm closing this bug report. If you're still seeing this problem, please reopen. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Mon Oct 14 02:04:54 2019 Received: (at control) by debbugs.gnu.org; 14 Oct 2019 06:04:54 +0000 Received: from localhost ([127.0.0.1]:37732 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iJtTR-0006wZ-Pw for submit@debbugs.gnu.org; Mon, 14 Oct 2019 02:04:54 -0400 Received: from [80.91.231.51] (port=50194 helo=quimby.gnus.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iJtTK-0006wC-Ca for control@debbugs.gnu.org; Mon, 14 Oct 2019 02:04:48 -0400 Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=marnie) by quimby.gnus.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1iJtTH-0002MJ-QE for control@debbugs.gnu.org; Mon, 14 Oct 2019 08:04:45 +0200 Date: Mon, 14 Oct 2019 08:04:43 +0200 Message-Id: <87zhi3n9qc.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #13887 X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: close 13887 quit Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 1.3 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: close 13887 quit Content analysis details: (1.3 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 SPF_NONE SPF: sender does not publish an SPF Record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 1.3 RDNS_NONE Delivered to internal network by a host with no rDNS X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 0.3 (/) close 13887 quit From unknown Sat Jun 21 10:29:10 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Mon, 11 Nov 2019 12:24:14 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator