From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Stephen J. Turnbull" Newsgroups: gmane.emacs.devel Subject: Re: Does face support underline other than a straight line? Date: Wed, 25 Jan 2012 18:26:25 +0900 Message-ID: <871uqo3zge.fsf@uwakimon.sk.tsukuba.ac.jp> References: <87r4yoiaiv.fsf@gnu.org> <8739b446qj.fsf@uwakimon.sk.tsukuba.ac.jp> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 X-Trace: dough.gmane.org 1327483618 24046 80.91.229.12 (25 Jan 2012 09:26:58 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 25 Jan 2012 09:26:58 +0000 (UTC) Cc: cyd@gnu.org, sdl.web@gmail.com, emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Jan 25 10:26:54 2012 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Rpz80-0000vc-Om for ged-emacs-devel@m.gmane.org; Wed, 25 Jan 2012 10:26:52 +0100 Original-Received: from localhost ([::1]:53593 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Rpz7x-0000Ih-4A for ged-emacs-devel@m.gmane.org; Wed, 25 Jan 2012 04:26:49 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]:60276) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Rpz7q-0000IT-51 for emacs-devel@gnu.org; Wed, 25 Jan 2012 04:26:47 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Rpz7l-0000HT-W7 for emacs-devel@gnu.org; Wed, 25 Jan 2012 04:26:42 -0500 Original-Received: from mgmt2.sk.tsukuba.ac.jp ([130.158.97.224]:55973) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Rpz7d-0000GL-FL; Wed, 25 Jan 2012 04:26:29 -0500 Original-Received: from uwakimon.sk.tsukuba.ac.jp (uwakimon.sk.tsukuba.ac.jp [130.158.99.156]) by mgmt2.sk.tsukuba.ac.jp (Postfix) with ESMTP id DDCE19707DE; Wed, 25 Jan 2012 18:26:25 +0900 (JST) Original-Received: by uwakimon.sk.tsukuba.ac.jp (Postfix, from userid 1000) id ABC221A2770; Wed, 25 Jan 2012 18:26:25 +0900 (JST) In-Reply-To: X-Mailer: VM undefined under 21.5 (beta31) "ginger" e6b5c49f9e13 XEmacs Lucid (x86_64-unknown-linux) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 130.158.97.224 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:147909 Archived-At: Eli Zaretskii writes: > > If Emacs supports background pixmaps to attach to faces, then it > > should be possible to create an appropriate pixmap on the fly. > > We have the :stipple attribute of faces; is that what you mean? I don't know how that works; never used it. In X11, "stipple" means a bitmap (mask), and I don't think that would cut it, you need to paint the whole background. I wouldn't be surprised if in Emacs it just means "background image", though. In XEmacs you can specify a color or a pixmap as background (bitmaps are promoted to pixmaps, but with -- until about a week ago -- less than satisfactory results). So you could specify a background pixmap (eg, as an XPM) as +------+ | | | | | | | | | ** | |* * | | **| +------+ and it will be tiled appropriately over the extent of the face, and the text will be printed over that in the foreground color. Sort of like poor man's image layers. Of course you have to set the background color of the pixmap to the background of the face, and you also have to get the height of the pixmap in pixels exactly right, I suspect. The latter might be difficult for some fonts, especially with sizes specified in printer's units rather than pixels.