Function: srecode-minor-mode

srecode-minor-mode is an autoloaded, interactive and byte-compiled function defined in mode.el.gz.

Signature

(srecode-minor-mode &optional ARG)

Documentation

Toggle srecode minor mode.

The minor mode can be turned on only if semantic feature is available and the current buffer was set up for parsing. Return non-nil if the minor mode is enabled.

C-c / . srecode-insert-again
C-c / / srecode-insert
C-c / <insert> srecode-insert
C-c / C srecode-document-insert-comment
C-c / E srecode-edit
C-c / G srecode-insert-getset
C-c / a srecode-bind-insert
C-c / b srecode-bind-insert
C-c / c srecode-bind-insert
C-c / d srecode-bind-insert
C-c / e srecode-bind-insert
C-c / f srecode-bind-insert
C-c / g srecode-bind-insert
C-c / h srecode-bind-insert
C-c / i srecode-bind-insert
C-c / j srecode-bind-insert
C-c / k srecode-bind-insert
C-c / l srecode-bind-insert
C-c / m srecode-bind-insert
C-c / n srecode-bind-insert
C-c / o srecode-bind-insert
C-c / p srecode-bind-insert
C-c / q srecode-bind-insert
C-c / r srecode-bind-insert
C-c / s srecode-bind-insert
C-c / t srecode-bind-insert
C-c / u srecode-bind-insert
C-c / v srecode-bind-insert
C-c / w srecode-bind-insert
C-c / x srecode-bind-insert
C-c / y srecode-bind-insert
C-c / z srecode-bind-insert

This is a minor mode. If called interactively, toggle the Srecode minor mode mode. If the prefix argument is positive, enable the mode, and if it is zero or negative, disable the mode.

If called from Lisp, toggle the mode if ARG is toggle. Enable the mode if ARG is nil, omitted, or is a positive number. Disable the mode if ARG is a negative number.

To check whether the minor mode is enabled in the current buffer, evaluate srecode-minor-mode(var)/srecode-minor-mode(fun).

The mode's hook is called both when the mode is enabled and when it is disabled.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/cedet/srecode/mode.el.gz
;;;###autoload
(define-minor-mode srecode-minor-mode
  "Toggle srecode minor mode.

The minor mode can be turned on only if semantic feature is
available and the current buffer was set up for parsing.  Return
non-nil if the minor mode is enabled.

\\{srecode-mode-map}"
  :keymap srecode-mode-map
  ;; If we are turning things on, make sure we have templates for
  ;; this mode first.
  (if srecode-minor-mode
      (if (not (apply
		#'append
		(mapcar (lambda (map)
			  (srecode-map-entries-for-mode map major-mode))
			(srecode-get-maps))))
	  (setq srecode-minor-mode nil)
	;; Else, we have success, do stuff
	;; FIXME: Where are `cedet-m3-menu-do-hooks' nor `srecode-m3-items'?
	(when (fboundp 'srecode-m3-items)
	  (add-hook 'cedet-m3-menu-do-hooks #'srecode-m3-items nil t)))
    (when (fboundp 'srecode-m3-items)
      (remove-hook 'cedet-m3-menu-do-hooks #'srecode-m3-items t)))
  ;; Run hooks if we are turning this on.
  (when srecode-minor-mode
    (run-hooks 'srecode-minor-mode-hook))
  srecode-minor-mode)