From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: bojohan+news@dd.chalmers.se (Johan =?utf-8?Q?Bockg=C3=A5rd?=) Newsgroups: gmane.emacs.help Subject: Re: Image overlays using font-lock-add-keywords() and create-image() for more compact code view Date: Fri, 06 Jun 2008 14:52:39 +0200 Message-ID: References: <2b8977f4-7143-4afb-98a3-a9a74c872e58@l42g2000hsc.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: ger.gmane.org 1212759668 7463 80.91.229.12 (6 Jun 2008 13:41:08 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 6 Jun 2008 13:41:08 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Jun 06 15:41:50 2008 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1K4cC2-0004wa-Ev for geh-help-gnu-emacs@m.gmane.org; Fri, 06 Jun 2008 15:41:22 +0200 Original-Received: from localhost ([127.0.0.1]:37617 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1K4cBF-00020P-PE for geh-help-gnu-emacs@m.gmane.org; Fri, 06 Jun 2008 09:40:33 -0400 Original-Path: news.stanford.edu!newsfeed.stanford.edu!goblin1!goblin.stu.neva.ru!uio.no!quimby.gnus.org!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 25 Original-NNTP-Posting-Host: remote5.student.chalmers.se Original-X-Trace: quimby.gnus.org 1212756779 22802 129.16.29.83 (6 Jun 2008 12:52:59 GMT) Original-X-Complaints-To: usenet@quimby.gnus.org Original-NNTP-Posting-Date: Fri, 6 Jun 2008 12:52:59 +0000 (UTC) Mail-Copies-To: never User-Agent: Gnus/5.110009 (No Gnus v0.9) Emacs/23.0.60 (gnu/linux) Cancel-Lock: sha1:QVuyBalBYUDAlypETI30bOkfPJQ= Original-Xref: news.stanford.edu gnu.emacs.help:159163 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:54508 Archived-At: Nordlöw writes: > I thought the following snippet of code should give me a new more > compact view of gtk-code. > > (defun pretty-gtk () > "Highlight symbols starting with gtk_ using the GIMP Tool Kit (GTK) > Icon." (add-to-list 'char-property-alias-alist '(display pretty)) (add-to-list 'font-lock-extra-managed-props 'pretty) > (font-lock-add-keywords > nil > `(("\\_<\\(gtk\\)_" > (1 '(face nil pretty ,(create-image "~/pnw/images/gtk-logo-rgb- > cropped-10x13.png"))))))) > (add-hook 'c-mode-common-hook 'pretty-gtk) > > It does not show the image overlay, however... What have I missed? This does not use overlays, BTW. -- Johan Bockgård