From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: patrick mc allister Newsgroups: gmane.emacs.bugs Subject: bug#20508: 24.4; image map properties not working as described Date: Tue, 5 May 2015 19:27:54 +0200 Message-ID: <20150505172753.GC18015@rdorte.org> References: <87pp6ffk5h.fsf@kamala.i-did-not-set--mail-host-address--so-tickle-me> <83bnhzrnni.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="cvVnyQ+4j833TQvp" X-Trace: ger.gmane.org 1430846969 29102 80.91.229.3 (5 May 2015 17:29:29 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 5 May 2015 17:29:29 +0000 (UTC) Cc: 20508@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue May 05 19:29:19 2015 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Ypgej-0007GG-Vm for geb-bug-gnu-emacs@m.gmane.org; Tue, 05 May 2015 19:29:18 +0200 Original-Received: from localhost ([::1]:40960 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ypgej-0000IL-4S for geb-bug-gnu-emacs@m.gmane.org; Tue, 05 May 2015 13:29:17 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:38731) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ypgeb-0000I7-T5 for bug-gnu-emacs@gnu.org; Tue, 05 May 2015 13:29:14 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YpgeU-0005jM-BL for bug-gnu-emacs@gnu.org; Tue, 05 May 2015 13:29:09 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:53776) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YpgeU-0005is-8X for bug-gnu-emacs@gnu.org; Tue, 05 May 2015 13:29:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1YpgeT-0007Jq-QY for bug-gnu-emacs@gnu.org; Tue, 05 May 2015 13:29:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: patrick mc allister Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 05 May 2015 17:29:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 20508 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 20508-submit@debbugs.gnu.org id=B20508.143084688728071 (code B ref 20508); Tue, 05 May 2015 17:29:01 +0000 Original-Received: (at 20508) by debbugs.gnu.org; 5 May 2015 17:28:07 +0000 Original-Received: from localhost ([127.0.0.1]:35518 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Ypgdb-0007Ig-2f for submit@debbugs.gnu.org; Tue, 05 May 2015 13:28:07 -0400 Original-Received: from mail-wg0-f49.google.com ([74.125.82.49]:33329) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1YpgdY-0007I7-3Z for 20508@debbugs.gnu.org; Tue, 05 May 2015 13:28:04 -0400 Original-Received: by wgin8 with SMTP id n8so190647600wgi.0 for <20508@debbugs.gnu.org>; Tue, 05 May 2015 10:27:58 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-type:content-disposition:in-reply-to :user-agent; bh=MAxox2MmwlaR/RxF5/pPt1PHtkDL11j6+xxj8YIEbCM=; b=LPw5M3Jkirr0zfptzjPk1kMyZ7KlSNxcek+iqLMpNVzlF1Ps1wmXEIOeQ5bzFYh3J6 DrBl6uh+372PCXsm8bensXUwlx98HS+UOn7kcnI37UPcNzKctM0+UByazwD/+9VhZIWF 8V/N9IXWluJ6/SPENFVNl5GIH/HA0SG29pjMy5h/HWTAEe78CjDTiWlMoMMlkQlXXPzs pbfbh1DKRQp+M/EPL9O0A1ElAuu5Cuh4eoM73pbXmd8Js6wmTByHqy0FjBjURu6Ev5La zyDGLlPPWc7FqlFBtahJ6rHRTvY4gIjWLACHEDX5N/lKY51PXqCdl4kXIBWj0x0kK2IP bkZg== X-Gm-Message-State: ALoCoQl82QuaIntHljZc1czQMJvYtWTptzjqzw+u95R5uWuek9uA//aJ+faphx/ilYLNHq7Ywxfb X-Received: by 10.194.95.2 with SMTP id dg2mr20293665wjb.53.1430846878487; Tue, 05 May 2015 10:27:58 -0700 (PDT) Original-Received: from rdorte.org (HSI-KBW-046-005-019-026.hsi8.kabel-badenwuerttemberg.de. [46.5.19.26]) by mx.google.com with ESMTPSA id a18sm26548900wja.46.2015.05.05.10.27.56 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 05 May 2015 10:27:57 -0700 (PDT) Content-Disposition: inline In-Reply-To: <83bnhzrnni.fsf@gnu.org> User-Agent: Mutt/1.5.23 (2014-03-12) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:102516 Archived-At: --cvVnyQ+4j833TQvp Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, May 05, 2015 at 07:32:01PM +0300, Eli Zaretskii wrote: > > It's a cockpit error: you should use 'pointer', not ':pointer' in the > first instance. IOW, this works for me (note the underlined part): >=20 > (defun image-wipe-and-insert () > (interactive) > (let () > (with-current-buffer (get-buffer-create "*an image area test buffer*") > (switch-to-buffer (current-buffer)) > (erase-buffer) > (insert-image (find-image '((:type png :file "/usr/share/emacs/24.4= /etc/images/icons/hicolor/128x128/apps/emacs.png" > :map '((rect . ((0 . 0) . (50 . 50))) anAreaID (poi= nter hourglass :help-echo "You found an area!")) > ;; ^^^= ^^^^ > ;; :relief -20 > ;; :conversion laplace > :margin (0 . 0) > :pointer arrow))))))) >=20 > (Yes, it's confusing to have ':pointer' on the top level and 'pointer' > inside the value for ':map'. But the manual correctly says 'pointer' > in the latter case, so at least the documentation is consistent with > the code.) Thanks a lot, indeed I missed that point! Now, however, I have a follow-up problem (which kind-of nearly fits the subject line): I was actually trying to get more than one of these hotspots onto the image, something like this: (defun image-wipe-and-insert-two-maps () (interactive) (let () (with-current-buffer (get-buffer-create "*an image area test buffer*") (switch-to-buffer (current-buffer)) (erase-buffer) (insert-image (find-image '((:type png :file "/usr/share/emacs/24.4/e= tc/images/icons/hicolor/128x128/apps/emacs.png" :map '( ((rect . ((0 . 0) . (50 . 50))) anAreaID (pointer hourglass help-echo= "You found an area!")) ((rect . ((51 . 51) . (100 . 100))) aSecondAreaID (pointer hand help-= echo "You found another area!"))) ;; :relief -20 ;; :conversion laplace :margin (0 . 0) :pointer arrow))))))) I thought this would be in accordance to the info node, where it says: ``An image map is an alist where each element has the format `(AREA ID PLIST)'."=20 But my attempt to insert two of those elements leads to no :map properties being shown for the image. They are there, though: (with-current-buffer "*an image area test buffer*" (pp (text-properties-at (point-min)) (current-buffer))) gives me: (rear-nonsticky (display) display (image :type png :file "/usr/share/emacs/24.4/etc/images/icons/hicolor/128= x128/apps/emacs.png" :map '(((rect (0 . 0) 50 . 50) anAreaID (pointer hourglass help-echo "You found an area!")) ((rect (51 . 51) 100 . 100) aSecondAreaID (pointer hand help-echo "You found another area!"))) :margin (0 . 0) :pointer arrow)) --=20 patrick --cvVnyQ+4j833TQvp Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iEYEARECAAYFAlVI/ZkACgkQN5RlYmr8acQDJQCeKwR4FNAlfalE3U6cvbVBjoOJ QD4AoK4r8fskhRUQlfIID/4c3XS6IbW6 =gKpi -----END PGP SIGNATURE----- --cvVnyQ+4j833TQvp--