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.devel Subject: Re: Fwd: overlay face property not used for after-string property Date: Sun, 28 Oct 2007 16:21:11 +0100 Message-ID: References: <86r6jfz3bb.fsf@macs.hw.ac.uk> 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 1193584912 21848 80.91.229.12 (28 Oct 2007 15:21:52 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 28 Oct 2007 15:21:52 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Oct 28 16:21:53 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1Im9xX-0003qp-6u for ged-emacs-devel@m.gmane.org; Sun, 28 Oct 2007 16:21:51 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Im9xO-0004dJ-3p for ged-emacs-devel@m.gmane.org; Sun, 28 Oct 2007 11:21:42 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Im9xL-0004be-Dn for emacs-devel@gnu.org; Sun, 28 Oct 2007 11:21:39 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Im9xJ-0004Y8-RP for emacs-devel@gnu.org; Sun, 28 Oct 2007 11:21:39 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Im9xJ-0004Xz-MO for emacs-devel@gnu.org; Sun, 28 Oct 2007 11:21:37 -0400 Original-Received: from main.gmane.org ([80.91.229.2] helo=ciao.gmane.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1Im9xJ-0002hJ-8k for emacs-devel@gnu.org; Sun, 28 Oct 2007 11:21:37 -0400 Original-Received: from list by ciao.gmane.org with local (Exim 4.43) id 1Im9x8-00051t-BZ for emacs-devel@gnu.org; Sun, 28 Oct 2007 15:21:26 +0000 Original-Received: from remote1.student.chalmers.se ([129.16.29.79]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 28 Oct 2007 15:21:26 +0000 Original-Received: from bojohan+news by remote1.student.chalmers.se with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 28 Oct 2007 15:21:26 +0000 X-Injected-Via-Gmane: http://gmane.org/ Mail-Followup-To: emacs-devel@gnu.org Original-Lines: 35 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: remote1.student.chalmers.se Mail-Copies-To: never User-Agent: Gnus/5.110007 (No Gnus v0.7) Emacs/23.0.50 (gnu/linux) Cancel-Lock: sha1:Ale7O4eEoKMAhVKejD7eIgmpAmo= X-detected-kernel: by monty-python.gnu.org: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:81964 Archived-At: Joe Wells writes: > Also, fixing this issue this way leaves behind the difficulty of > adding a face property manually to a property string (before-string, > after-string, or display) which already has face properties. In font-lock.el we find ;;; Additional text property functions. ;; The following text property functions should be builtins. This ;; means they should be written in C and put with all the other text ;; property functions. In the meantime, those that are used by ;; font-lock.el are defined in Lisp below and given a `font-lock-' ;; prefix. Those that are not used are defined in Lisp below and ;; commented out. sm. (defun font-lock-prepend-text-property ([...]) "Prepend to one property of the text from START to END. Arguments PROP and VALUE specify the property and value to prepend to the value already in place. The resulting property values are always lists. Optional argument OBJECT is the string or buffer containing the text." [...] (let ((s (propertize "abc" 'face 'bar))) (font-lock-prepend-text-property 1 2 'face 'foo s) s) => #("abc" 0 1 (face bar) 1 2 (face (foo bar)) 2 3 (face bar)) -- Johan Bockgård