2006-09-08

Use Doxygen in Emacs - Doxymacs

  • Depencency
    1. W3 http://www.cs.indiana.edu/usr/local/www/elisp/w3/docs.html
    2. tempo http://www.lysator.liu.se/~davidk/elisp/
    3. libxml2 http://www.libxml.org/
  • Make
    • Create a doxymacs_parser in the installation path.
  • Setup the .emacs

;;_+ Doxygen mode
(add-to-list 'load-path "~/emacs-lisp/doxymacs")
(require 'doxymacs)

;; font-lock
(defun my-doxymacs-font-lock-hook ()
(if (or (eq major-mode 'c-mode) (eq major-mode 'c++-mode))
(doxymacs-font-lock)))
(add-hook 'font-lock-mode-hook 'my-doxymacs-font-lock-hook)
;;_+ Invoked automatically when in C/C++ mode
(add-hook 'c-mode-common-hook 'doxymacs-mode)
  • Key Bindings
C-c d ?will look up documentation for the symbol under the point.
C-c d rwill rescan your Doxygen tags file.
C-c d fwill insert a Doxygen comment for the next function.
C-c d iwill insert a Doxygen comment for the current file.
C-c d ;will insert a Doxygen comment for the current member.
C-c d mwill insert a blank multi-line Doxygen comment.
C-c d swill insert a blank single-line Doxygen comment.
C-c d @will insert grouping comments around the current region.

沒有留言:

張貼留言