From xemacs-m  Sat May 31 10:41:48 1997
Received: from jagor.srce.hr (hniksic@jagor.srce.hr [161.53.2.130])
	by xemacs.org (8.8.5/8.8.5) with ESMTP id KAA14798
	for <xemacs-beta@xemacs.org>; Sat, 31 May 1997 10:41:47 -0500 (CDT)
Received: (from hniksic@localhost)
          by jagor.srce.hr (8.8.5/8.8.4)
	  id RAA26264; Sat, 31 May 1997 17:41:43 +0200 (MET DST)
To: David Moore <dmoore@ucsd.edu>
Cc: XEmacs Developers <xemacs-beta@xemacs.org>
Subject: Bug in `set-text-properties'
X-Attribution: Hrv
X-Face: Mie8:rOV<\c/~z{s.X4A{!?vY7{drJ([U]0O=W/<W*SMo/Mv:58:*_y~ki>xDi&N7XG
        KV^$k0m3Oe/)'e%3=$PCR&3ITUXH,cK>]bci&<qQ>Ff%x_>1`T(+M2Gg/fgndU%k*ft
        [(7._6e0n-V%|%'[c|q:;}td$#INd+;?!-V=c8Pqf}3J
X-Kibo-Says: Everyone could wrap up some weenie.
From: Hrvoje Niksic <hniksic@srce.hr>
Date: 31 May 1997 17:41:43 +0200
In-Reply-To: David Moore's message of 31 May 1997 08:36:55 -0700
Message-ID: <kig7mgflkco.fsf_-_@jagor.srce.hr>
Lines: 35
X-Mailer: Gnus v5.4.52/XEmacs 20.2

David Moore <dmoore@ucsd.edu> writes:

> Hrvoje Niksic <hniksic@srce.hr> writes:
> 
> > Do you understand the `set-text-properties' function?  It seems to
> > have a bug which causes me problems with widget.el.
> 
> Hmm, what problems are you seeing?  It's possible that there's a bug,
> since people only seem to use it for removing properties (nil arg).  It
> also looks like it might have a logic error, but I'd have to think more
> about it.  :)

Guess what: I see the bug when I try to remove text properties. :-)

The simplest repeat-method:

(set-text-properties (point-min) (point-max) '(hrvoje hahaha face red))

(set-text-properties (point-min) (point-max) nil)

And the face stays red.  Which is to say: only the first text
property is removed.  This is a very serious bug in a very basic
functionality (it also hits Gnus in many places), and I'd like to see
a correct version of this ideologically totally blasphemous, but alas
very much used function.

If I get the fix for this, there'll be a very good chance of Customize
buffers not being writable at beginnings and ends in the future
(i.e. I've found how to fix it, but run into this bug).

-- 
Hrvoje Niksic <hniksic@srce.hr> | Student at FER Zagreb, Croatia
--------------------------------+--------------------------------
4.  Thou shalt not warlorde a sig if it bee the sig of Kibo, nor if
    it bee the sig of the Inner Circle.

