Show
Ignore:
Timestamp:
08/18/06 08:35:31 (2 years ago)
Author:
miyoshi
Message:

Sync up with Emacs CVS HEAD.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/lisp/facemenu.el

    r4111 r4148  
    135135(defcustom facemenu-listed-faces nil 
    136136  "*List of faces to include in the Face menu. 
    137 Each element should be a symbol, which is the name of a face. 
     137Each element should be a symbol, the name of a face. 
    138138The \"basic \" faces in `facemenu-keybindings' are automatically 
    139 added to the Face menu, and are not included in this list. 
    140  
    141 You can set this list before loading facemenu.el, or add a face to it before 
    142 creating that face if you want it to be listed.  If you change the 
    143 variable so as to eliminate faces that have already been added to the menu, 
    144 call `facemenu-update' to recalculate the menu contents. 
    145  
    146 If this variable is t, all faces will be added to the menu.  This 
    147 is useful for setting temporarily if you want to add faces to the 
    148 menu when they are created." 
     139added to the Face menu, and need not be in this list. 
     140 
     141This value takes effect when you load facemenu.el.  If the 
     142list includes symbols which are not defined as faces, they 
     143are ignored; however, subsequently defining or creating 
     144those faces adds them to the menu then.  You can call 
     145`facemenu-update' to recalculate the menu contents, such as 
     146if you change the value of this variable, 
     147 
     148If this variable is t, all faces that you apply to text 
     149using the face menu commands (even by name), and all faces 
     150that you define or create, are added to the menu.  You may 
     151find it useful to set this variable to t temporarily while 
     152you define some faces, so that they will be added.  However, 
     153if the value is no longer t and you call `facemenu-update', 
     154it will remove any faces not explicitly in the list." 
    149155  :type '(choice (const :tag "List all faces" t) 
    150156                 (const :tag "None" nil) 
     
    321327;;;###autoload 
    322328(defun facemenu-set-face (face &optional start end) 
    323   "Add FACE to the region or next character typed. 
    324 This adds FACE to the top of the face list; any faces lower on the list that 
    325 will not show through at all will be removed. 
    326  
    327 Interactively, reads the face name with the minibuffer. 
    328  
    329 If the region is active (normally true except in Transient Mark mode) 
    330 and there is no prefix argument, this command sets the region to the 
    331 requested face. 
    332  
    333 Otherwise, this command specifies the face for the next character 
    334 inserted.  Moving point or switching buffers before 
    335 typing a character to insert cancels the specification." 
     329  "Apply FACE to the region or next character typed. 
     330 
     331If the region is active (normally true except in Transient 
     332Mark mode) and nonempty, and there is no prefix argument, 
     333this command applies FACE to the region.  Otherwise, it applies FACE 
     334to the faces to use for the next character 
     335inserted.  (Moving point or switching buffers before typing 
     336a character to insert cancels the specification.) 
     337 
     338If FACE is `default', to \"apply\" it means clearing 
     339the list of faces to be used.  For any other value of FACE, 
     340to \"apply\" it means putting FACE at the front of the list 
     341of faces to be used, and removing any faces further 
     342along in the list that would be completely overridden by 
     343preceding faces (including FACE). 
     344 
     345This command can also add FACE to the menu of faces, 
     346if `facemenu-listed-faces' says to do that." 
    336347  (interactive (list (progn 
    337348                       (barf-if-buffer-read-only) 
     
    613624                                            (if (listp prev) 
    614625                                                prev 
    615                                               (list prev))))))) 
     626                                              (list prev))) 
     627                                      ;; Specify the selected frame 
     628                                      ;; because nil would mean to use 
     629                                      ;; the new-frame default settings, 
     630                                      ;; and those are usually nil. 
     631                                      (selected-frame))))) 
    616632              (setq part-start part-end))) 
    617633        (setq self-insert-face (if (eq last-command self-insert-face-command) 
     
    656672 
    657673(defun facemenu-add-new-face (face) 
    658   "Add FACE (a face) to the Face menu. 
    659  
    660 This is called whenever you create a new face." 
     674  "Add FACE (a face) to the Face menu if `facemenu-listed-faces' says so. 
     675This is called whenever you create a new face, and at other times." 
    661676  (let* (name 
    662677         symbol