* poe.el (make-local-hook): Move to after defining `add-local-hook' and
[elisp/apel.git] / tinycustom.el
1 ;; tinycustom.el -- a tiny custom.el for emulating purpose.
2
3 ;; Copyright (C) 1999 Mikio Nakajima <minakaji@osaka.email.ne.jp>
4
5 ;; Author: Mikio Nakajima <minakaji@osaka.email.ne.jp>
6 ;; Maintainer: Mikio Nakajima <minakaji@osaka.email.ne.jp>
7 ;; Version: $Id: tinycustom.el,v 1.3 1999-03-25 00:18:05 yamaoka Exp $
8 ;; Last Modified: $Date: 1999-03-25 00:18:05 $
9 ;; Keywords: emulating, custom
10
11 ;; This file is part of APEL (A Portable Emacs Library).
12
13 ;; This program is free software; you can redistribute it and/or
14 ;; modify it under the terms of the GNU General Public License as
15 ;; published by the Free Software Foundation; either version 2, or (at
16 ;; your option) any later version.
17
18 ;; This program is distributed in the hope that it will be useful, but
19 ;; WITHOUT ANY WARRANTY; without even the implied warranty of
20 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
21 ;; General Public License for more details.
22
23 ;; You should have received a copy of the GNU General Public License
24 ;; along with GNU Emacs; see the file COPYING.  If not, write to the
25 ;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
26 ;; Boston, MA 02111-1307, USA.
27
28 ;;; Commentary:
29
30 ;; Purpose of this program is emulating for who does not have
31 ;; `custom.el'.
32 ;;
33 ;; DEFCUSTOM below has the same effect as the original DEFVAR has.
34 ;; DEFFACE only makes a face.
35 ;; DEFGROUP and DEFINE-WIDGET below are just nop macro.
36
37 ;;; Code:
38
39 (require 'poe)
40
41 (defmacro-maybe defgroup (symbol members doc &rest args)
42   "Declare SYMBOL as a customization group containing MEMBERS.
43 SYMBOL does not need to be quoted.
44 Third arg DOC is the group documentation.
45
46 This is a nop defgroup only for emulating purpose."
47   nil )
48     
49 (defmacro-maybe defcustom (symbol value doc &rest args) 
50   "Declare SYMBOL as a customizable variable that defaults to VALUE.
51 DOC is the variable documentation.
52
53 This is a defcustom only for emulating purpose.
54 Its effect is just as same as that of defvar."
55   (` (defvar (, symbol) (, value) (, doc))) )
56     
57 (defmacro-maybe defface (face value doc &rest args) 
58   "Declare FACE as a customizable face that defaults to SPEC.
59 FACE does not need to be quoted.
60
61 This is a defface which only makes face FACE for emulating purpose."
62   (` (make-face (, face))) )
63
64 (defmacro-maybe define-widget (name class doc)
65   "Define a new widget type named NAME from CLASS.
66 The third argument DOC is a documentation string for the widget.
67
68 This is a nop define-widget only for emulating purpose."
69   nil )
70
71 (provide 'tinycustom)
72 (provide 'custom)
73
74 ;; end of tinycustom.el