www.delorie.com/gnu/docs/emacs/gnus_242.html   search  
 
Buy the book!


Gnus Manual

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

8.4.4 User-Defined Specs

All the specs allow for inserting user defined specifiers---`u'. The next character in the format string should be a letter. Gnus will call the function gnus-user-format-function-`X', where `X' is the letter following `%u'. The function will be passed a single parameter--what the parameter means depends on what buffer it's being called from. The function should return a string, which will be inserted into the buffer just like information from any other specifier. This function may also be called with dummy values, so it should protect against that.

You can also use tilde modifiers (see section 8.4.3 Advanced Formatting to achieve much the same without defining new functions. Here's an example: `%~(form (count-lines (point-min) (point)))@'. The form given here will be evaluated to yield the current line number, and then inserted.


  webmaster   donations   bookstore     delorie software   privacy  
  Copyright © 2003   by The Free Software Foundation     Updated Jun 2003  

Please take a moment to fill out this visitor survey
You can help support this site by visiting the advertisers that sponsor it! (only once each, though)