unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Patch to function make-text-button in lisp/button.el
@ 2005-02-27  0:21 Francis Litterio
  2005-03-02  9:11 ` Miles Bader
  0 siblings, 1 reply; 2+ messages in thread
From: Francis Litterio @ 2005-02-27  0:21 UTC (permalink / raw)


In lisp/button.el, function make-button sets the type of the button to a
default value if the user doesn't supply a :type property, but function
make-text-button does not.

This patch makes function make-text-button set the type of the button if
the user does not supply a :type property.
--
Francis Litterio
franl <at> world . std . com


--- button.el	13 Oct 2004 14:52:52 -0400	1.14
+++ button.el	26 Feb 2005 19:17:48 -0500	
@@ -315,6 +315,9 @@
 	     (error "Button `category' property may not be set directly")))
       ;; Add the property.
       (put-text-property beg end prop val)))
+  ;; If the user didn't specify a type, use the default.
+  (unless (get-text-property beg 'category)
+    (put-text-property beg end 'category 'default-button))
   ;; Return something that can be used to get at the button.
   beg)

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Patch to function make-text-button in lisp/button.el
  2005-02-27  0:21 Patch to function make-text-button in lisp/button.el Francis Litterio
@ 2005-03-02  9:11 ` Miles Bader
  0 siblings, 0 replies; 2+ messages in thread
From: Miles Bader @ 2005-03-02  9:11 UTC (permalink / raw)
  Cc: emacs-devel

On Sat, 26 Feb 2005 19:21:28 -0500, Francis Litterio
<franl@world.std.com> wrote:
> In lisp/button.el, function make-button sets the type of the button to a
> default value if the user doesn't supply a :type property, but function
> make-text-button does not.

Thanks; I've fixed this (in a slightly different way).

-Miles
-- 
Do not taunt Happy Fun Ball.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2005-03-02  9:11 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-02-27  0:21 Patch to function make-text-button in lisp/button.el Francis Litterio
2005-03-02  9:11 ` Miles Bader

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).