From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.help Subject: RE: Specifying plist requirements in defcustom? Date: Wed, 15 Oct 2008 09:58:41 -0700 Message-ID: <001b01c92ee7$4706a270$c2b22382@us.oracle.com> References: <006f01c92ed5$5b49e150$0200a8c0@us.oracle.com><48F6041E.5050707@gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1224090012 4637 80.91.229.12 (15 Oct 2008 17:00:12 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 15 Oct 2008 17:00:12 +0000 (UTC) To: "'jrwats'" , Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Oct 15 19:01:09 2008 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1Kq9jR-0005xy-Cm for geh-help-gnu-emacs@m.gmane.org; Wed, 15 Oct 2008 19:00:21 +0200 Original-Received: from localhost ([127.0.0.1]:34274 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Kq9iM-0004zd-Gz for geh-help-gnu-emacs@m.gmane.org; Wed, 15 Oct 2008 12:59:14 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Kq9hz-0004x6-Dy for help-gnu-emacs@gnu.org; Wed, 15 Oct 2008 12:58:51 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Kq9hx-0004uC-O2 for help-gnu-emacs@gnu.org; Wed, 15 Oct 2008 12:58:50 -0400 Original-Received: from [199.232.76.173] (port=54407 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Kq9hx-0004u5-Jc for help-gnu-emacs@gnu.org; Wed, 15 Oct 2008 12:58:49 -0400 Original-Received: from rgminet01.oracle.com ([148.87.113.118]:56284) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1Kq9hx-0005jp-1s for help-gnu-emacs@gnu.org; Wed, 15 Oct 2008 12:58:49 -0400 Original-Received: from rgmgw1.us.oracle.com (rgmgw1.us.oracle.com [138.1.186.110]) by rgminet01.oracle.com (Switch-3.2.4/Switch-3.1.6) with ESMTP id m9FGwhve019397; Wed, 15 Oct 2008 10:58:43 -0600 Original-Received: from acsmt701.oracle.com (acsmt701.oracle.com [141.146.40.71]) by rgmgw1.us.oracle.com (Switch-3.2.4/Switch-3.2.4) with ESMTP id m9FGwegQ018085; Wed, 15 Oct 2008 10:58:40 -0600 Original-Received: from dradamslap1 (/130.35.178.194) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Wed, 15 Oct 2008 09:58:40 -0700 X-Mailer: Microsoft Office Outlook 11 In-Reply-To: Thread-Index: Acku5NuwzXGogpLHQuGeARoZWyZcBAAAZ6Pw X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3350 X-Brightmail-Tracker: AAAAAQAAAAI= X-Brightmail-Tracker: AAAAAQAAAAI= X-Whitelist: TRUE X-Whitelist: TRUE X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.4-2.6 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:58812 Archived-At: > > ~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).