From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: storm@cua.dk (Kim F. Storm) Newsgroups: gmane.emacs.devel Subject: Help fix this: Bug in sliced XPM images on X -- bad clip mask origin. Date: 04 Jun 2004 00:15:50 +0200 Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1086301000 23566 80.91.224.253 (3 Jun 2004 22:16:40 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 3 Jun 2004 22:16:40 +0000 (UTC) Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Fri Jun 04 00:16:24 2004 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1BW0Vc-0002u7-00 for ; Fri, 04 Jun 2004 00:16:24 +0200 Original-Received: from lists.gnu.org ([199.232.76.165]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1BW0Vb-0005Uu-00 for ; Fri, 04 Jun 2004 00:16:23 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1BW0Vx-0002hi-LR for emacs-devel@quimby.gnus.org; Thu, 03 Jun 2004 18:16:45 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1BW0Vv-0002hR-5Y for emacs-devel@gnu.org; Thu, 03 Jun 2004 18:16:43 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1BW0Vt-0002h3-KQ for emacs-devel@gnu.org; Thu, 03 Jun 2004 18:16:42 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1BW0Vt-0002gt-Ib for emacs-devel@gnu.org; Thu, 03 Jun 2004 18:16:41 -0400 Original-Received: from [195.41.46.235] (helo=pfepa.post.tele.dk) by monty-python.gnu.org with esmtp (Exim 4.34) id 1BW0Uv-000625-O7 for emacs-devel@gnu.org; Thu, 03 Jun 2004 18:15:42 -0400 Original-Received: from kfs-l.imdomain.dk.cua.dk (0x503e2644.bynxx3.adsl-dhcp.tele.dk [80.62.38.68]) by pfepa.post.tele.dk (Postfix) with SMTP id DE46B47FE19 for ; Fri, 4 Jun 2004 00:15:38 +0200 (CEST) Original-To: emacs-devel@gnu.org Original-Lines: 31 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.4 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:24485 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:24485 Some time ago I installed changes to support image slices, and it works fine with e.g. png. However, there are severe problems with sliced XPM images, at least on X. The clip mask for each slice is taken from top/leftmost part of the image, rather than the actual slice of the image. I have tried a zillion things to setup the clip mask (and rewrite other parts of the code) to make this work, but to no avail. So I hereby ask for help from more skilled X people. How do you setup the clip mask of an image with an image mask so that XCopyArea will use the corresponding part of the image mask when copying a slice from the image ? Here is some code to illustrate the bug: (progn (setq im2 (find-image '((:type xpm :file "gnus.xpm")))) (insert "\n") (insert-image im2) (insert "\n") (insert-sliced-image im2 nil nil 5 4) (insert "\n")) Does this code work on W32 and/or MAC ? -- Kim F. Storm http://www.cua.dk