unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Francis Litterio <franl@world.std.com>
Subject: Patch to function make-text-button in lisp/button.el
Date: Sat, 26 Feb 2005 19:21:28 -0500	[thread overview]
Message-ID: <u8y5ax2ya.fsf@world.std.com> (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)

             reply	other threads:[~2005-02-27  0:21 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-02-27  0:21 Francis Litterio [this message]
2005-03-02  9:11 ` Patch to function make-text-button in lisp/button.el Miles Bader

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=u8y5ax2ya.fsf@world.std.com \
    --to=franl@world.std.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).