unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: David Ponce via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: Joseph Turner <joseph@breatheoutbreathe.in>, 70093@debbugs.gnu.org
Cc: Eli Zaretskii <eliz@gnu.org>
Subject: bug#70093: *** SPAM *** bug#70093: Remove unnecessary `image-tests--map-equal'
Date: Sat, 30 Mar 2024 23:04:28 +0100	[thread overview]
Message-ID: <1d1367e3-d888-4a00-8204-1bb6c3607801@orange.fr> (raw)
In-Reply-To: <877chjcxfg.fsf@breatheoutbreathe.in>

On 30/03/2024 20:44, Joseph Turner wrote:
> With the resolution of bug#69992, it may be possible to remove the
> `image-tests--map-equal' equality predicate from lisp/image-tests.el.
> 
> Eli and David, would you please apply the attached patch and then run
> the tests to see if we still need to allow for tolerances in
> `image--compute-map-and-original-map'?
> 
> The tests pass for me, but then again, they never failed on my machine...
> 
> Thank you!! I'm grateful for this fun collaboration. :)
> 
> Joseph
> 
> 

Hi Joseph,

Did you forget to attach the patch? I cannot find it.

Anyway, I don't think the resolution of bug#69992 changed anything
regarding the test `image--compute-map-and-original-map'.  And to
be honest I don't understand why it gives a different result on our
configurations.

To test, I also eval the following simple code in *scratch* buffer,
which gives me consistent results on my laptop:

(let* ((svg (svg-create 200 100))
        (omap `(((rect . ((0 . 0) . (50 . 50)))
                 rect-test (help-echo "rect-test"))
                ((circle . ((85 . 55) . 25))
                 circle-test (help-echo "circle-test"))
                ((poly . [100 0 125 0 170 50 125 50])
                 poly-test (help-echo "poly-test")))))
   (svg-rectangle svg 0 0 50 50
                  :stroke-width 0 :fill "red")
   (svg-circle    svg 85 55 25
                  :stroke-width 0 :fill "green")
   (svg-polyline  svg '((100 . 0) (125 . 0) (170 . 50) (125 . 50))
                  :stroke-width 0 :fill "blue")
   (let ((image (svg-image svg
                           :original-map omap
                           :scale nil    ;; vary scale test
                           :rotation nil ;; vary rotation test
                           :flip nil     ;; vary flip test
                           )))
     ;; Must see the pointer and help-echo change when mouse hovers the
     ;; rect, circle and poly hot spots.
     (insert-image image)
     (insert ?\n)
     ;; Must see the same original map.
     (image--compute-original-map image)))

Thanks!





  reply	other threads:[~2024-03-30 22:04 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-30 19:44 bug#70093: Remove unnecessary `image-tests--map-equal' Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-03-30 22:04 ` David Ponce via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2024-03-31  7:37   ` bug#70093: *** SPAM *** " Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-03-31 10:08     ` David Ponce via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-04-02 10:36       ` David Ponce via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-04-06  1:50         ` Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-04-07 16:01           ` David Ponce via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-03-31  5:10 ` Eli Zaretskii
2024-03-31  5:32   ` Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-03-31  7:33     ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1d1367e3-d888-4a00-8204-1bb6c3607801@orange.fr \
    --to=bug-gnu-emacs@gnu.org \
    --cc=70093@debbugs.gnu.org \
    --cc=da_vid@orange.fr \
    --cc=eliz@gnu.org \
    --cc=joseph@breatheoutbreathe.in \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).