emacs-wiki-discuss
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[emacs-wiki-discuss] Macros, menu documentation, and miscellaneous bugfi


From: Michael Olson
Subject: [emacs-wiki-discuss] Macros, menu documentation, and miscellaneous bugfixes
Date: Sun, 26 Sep 2004 20:30:47 -0500
User-agent: Gnus/5.1006 (Gnus v5.10.6) Emacs/21.3.50 (gnu/linux)

Thought I'd catch you all up on the latest changes in my
emacs-wiki--main--1.0 branch.

Patch-9: Applied patch from John Sullivan to allow Info URI's with
spaces in them to be correctly buttonized.  To see what this does,
make a new planner task from an Info buffer that contains a space in
its title.

Patch-10: Fix problem with `font-lock-multiline', which is undefined
in XEmacs.  To fix this, I added definitions of 'nil for
`font-lock-mode' and `font-lock-multiline', since this is what was
done in Muse.  One source tells me that this might be the wrong way to
fix the problem, but I don't know of a better one.  Please advise me.

Patch-11: Fix accidental use of `planner-make-link' with
`emacs-wiki-make-link'.

Patch-12: Now we get to the good stuff.  I added Marc Tommasi's macro
expansion patch.  A short description follows.

;;;_ + Startup

;; Macro functionality is automatically loaded from emacs-wiki.el, so
;; you don't need to do anything special to enable them.  This may
;; possibly change in the future.

;;;_ + Usage

;; You can specify macros with an association list:
;;
;; (setq emacs-wiki-macro-alist
;;       '(("mt"
;;          . "<a
;;             href=\"http://www.grappa.univ-lille3.fr/~tommasi\";>Marc
;;             Tommasi</a>")
;;         ("ap"
;;          . "<a
;;             href=\"http://www.cril-univ-artois.fr/~parrain\";>Anne
;;             Parrain</a>")))
;;
;; Use the syntax %macro% in project pages to denote a macro.
;;
;; For example, %mt% is expanded into
;;
;; "<a
;; href=\"http://www.grappa.univ-lille3.fr/~tommasi";>Marc
;; Tommasi</a>"
;;
;; during the publication process.

I added some better documentation to the emacs-wiki-menu.el file.  You
should probably take a look at it.  To ease this process, I've taken
the liberty of pasting it here.

;;;_ + Startup

;; To generate menus for your projects, you will need to put this in
;; your .emacs file:
;;
;;   (require 'emacs-wiki-menu)
;;
;; You will have to include the following in your stylesheet:
;;
;;   <lisp>(funcall emacs-wiki-menu-factory)</lisp>
;;
;; In order to make menu entries look right, you should take a look at
;; the /* Menu properties */ section of `emacs-wiki-style-sheet' and
;; add those entries to your style sheet.

;;;_ + Usage

;; Once you have gone through all of the procedures in the Startup
;; section, emacs-wiki-menu.el will generate menus that contain an
;; alphabetized listing of everything in `emacs-wiki-projects'.
;;
;; Of course, other options are available.  If you change
;; `emacs-wiki-menu-factory', you will have access to several other
;; ways of generating menus.  Here are the different possible settings
;; for that option.
;;
;;     `emacs-wiki-menu-fixed': The text in `emacs-wiki-menu-default'
;;        will be used to generate the menu.
;;
;;     `emacs-wiki-menu-no-menu': No menu will be made.
;;
;;     `emacs-wiki-menu-make-from-projects': Create menu items from
;;        the project lists.
;;
;;     `emacs-wiki-menu-make-from-file': Create menu from a file.
;;
;;     `emacs-wiki-menu-make-from-list': Pass this function a list of
;;        3 tuples of the form: text, url, tooltip, and it will
;;        generate a menu based on that list."

I also fixed a bug related to the use of
`emacs-wiki-make-menu-from-list' which was caused by forgetting to use
`save-excursion'.  Thanks to Marc Tommasi for the heads-up.

-- 
Michael Olson -- FSF Associate Member #652 -- Web: http://www.mwolson.org/
Jabber: mwolson_at_hcoop.net -- IRC: bigmike160 on freenode.net: #muse, #pulug
 /~ |\ | | |   Interests: animé, Debian GNU/Linux, XHTML, wiki, Lisp
|_] | \| |_|  Fun quotes: http://www.mwolson.org/plans/QuoteList.html





reply via email to

[Prev in Thread] Current Thread [Next in Thread]