help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Specifying plist requirements in defcustom?


From: Drew Adams
Subject: RE: Specifying plist requirements in defcustom?
Date: Wed, 15 Oct 2008 09:58:41 -0700

> > ~All you have to do is write...~ means that it's not there 
> > already. Playing with widgets is, in my book, extending
> > Customize. And it's not necessarily a clear-cut exercise.
> 
> I ostensibly agree.  Despite all the searching I did, I could not find
> a solid example of creating a new widget.  And they all seemed
> graphics related... The default customization prompt that occurs with
> something like this:
> 
> (defcustom rep-list '(("wcdc" "working.client.deskcomm" "e:" "e:
> \wcdeskomm"))
>   "test this!"
>   :type '(repeat (list
>                   (string :tag "name")
>                   (string :tag "branch")
>                   (string :tag "drive")
>                   (string :tag "path"))))
> 
> is EXACTLY what I want - I just want a plist with keys: name, branch,
> drive, and path rather than a list, so I don't have to write silly
> things like: (defun path (cadddr list))
> 
> ...I might just give in to silly application code for the 
> sake of user-friendly client experience.

I'm no expert on Customize. The code in wid-edit+.el might help
(http://www.emacswiki.org/emacs/wid-edit%2b.el), or it might not - dunno. 

If not, I believe that Lennart has some widget code that might help. And of
course you can look in the Lisp sources that come with Emacs. And there's the
widget Info manual, FWIW.

If you do write some useful widget/Customize code, please share it (e.g.
gnu-emacs-sources@gnu.org or Emacs Wiki).





reply via email to

[Prev in Thread] Current Thread [Next in Thread]