/[emacs]/emacs/lisp/progmodes/cc-vars.el
ViewVC logotype

Diff of /emacs/lisp/progmodes/cc-vars.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.21 by mast, Mon Apr 22 00:35:36 2002 UTC revision 1.21.2.1 by miles, Fri Apr 4 06:20:32 2003 UTC
# Line 50  Line 50 
50    
51  ;; Pull in custom if it exists and is recent enough (the one in Emacs  ;; Pull in custom if it exists and is recent enough (the one in Emacs
52  ;; 19.34 isn't).  ;; 19.34 isn't).
53  (eval  (eval-when-compile
54   (cc-eval-when-compile    (require 'custom)
55     (condition-case nil    (require 'wid-edit))
        (progn  
          (require 'custom)  
          (or (fboundp 'defcustom) (error ""))  
          (require 'wid-edit)  
          '(progn                        ; Compile in the require's.  
             (require 'custom)  
             (require 'wid-edit)))  
      (error  
       (message "Warning: Compiling without Customize support \  
 since a (good enough) custom library wasn't found")  
       (cc-bytecomp-defmacro define-widget (name class doc &rest args))  
       (cc-bytecomp-defmacro defcustom (symbol value doc &rest args)  
         `(defvar ,symbol ,value ,doc))  
       (cc-bytecomp-defmacro custom-declare-variable (symbol value doc  
                                                      &rest args)  
         `(defvar ,(eval symbol) ,(eval value) ,doc))  
       nil))))  
56    
57  (cc-eval-when-compile  (cc-eval-when-compile
58    ;; Need the function form of `backquote', which isn't standardized    ;; Need the function form of `backquote', which isn't standardized
# Line 721  space." Line 704  space."
704    :type 'function    :type 'function
705    :group 'c)    :group 'c)
706    
707    (defcustom c-require-final-newline
708      ;; C and C++ mandates that all nonempty files should end with a
709      ;; newline.  Objective-C refers to C for all things it doesn't
710      ;; specify, so the same holds there.  The other languages does not
711      ;; require it (at least not explicitly in a normative text).
712      '((c-mode    . t)
713        (c++-mode  . t)
714        (objc-mode . t))
715      "*Controls whether a final newline is ensured when the file is saved.
716    The value is an association list that for each language mode specifies
717    the value to give to `require-final-newline' at mode initialization;
718    see that variable for details about the value.  If a language isn't
719    present on the association list, CC Mode won't set
720    `require-final-newline' in buffers for that language."
721      :type `(set (cons :format "%v"
722                        (const :format "C     " c-mode)
723                        (symbol :format "%v" :value ,require-final-newline))
724                  (cons :format "%v"
725                        (const :format "C++   " c++-mode)
726                        (symbol :format "%v" :value ,require-final-newline))
727                  (cons :format "%v"
728                        (const :format "ObjC  " objc-mode)
729                        (symbol :format "%v" :value ,require-final-newline))
730                  (cons :format "%v"
731                        (const :format "Java  " java-mode)
732                        (symbol :format "%v" :value ,require-final-newline))
733                  (cons :format "%v"
734                        (const :format "IDL   " idl-mode)
735                        (symbol :format "%v" :value ,require-final-newline))
736                  (cons :format "%v"
737                        (const :format "Pike  " pike-mode)
738                        (symbol :format "%v" :value ,require-final-newline)))
739      :group 'c)
740    
741  (defcustom c-electric-pound-behavior nil  (defcustom c-electric-pound-behavior nil
742    "*List of behaviors for electric pound insertion.    "*List of behaviors for electric pound insertion.
743  Only currently supported behavior is `alignleft'."  Only currently supported behavior is `alignleft'."
# Line 997  If OFFSET is one of the symbols `+', `-' Line 1014  If OFFSET is one of the symbols `+', `-'
1014  positive or negative multiple of `c-basic-offset' is added; 1, -1, 2,  positive or negative multiple of `c-basic-offset' is added; 1, -1, 2,
1015  -2, 0.5, and -0.5, respectively.  -2, 0.5, and -0.5, respectively.
1016    
1017  If OFFSET is a vector, it's first element, which must be an integer,  If OFFSET is a vector, its first element, which must be an integer,
1018  is used as an absolute indentation column.  This overrides all  is used as an absolute indentation column.  This overrides all
1019  relative offsets.  If there are several syntactic elements which  relative offsets.  If there are several syntactic elements which
1020  evaluates to absolute indentation columns, the first one takes  evaluates to absolute indentation columns, the first one takes

Legend:
Removed from v.1.21  
changed lines
  Added in v.1.21.2.1

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26