help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: diary display won't initialise correctly?


From: Kevin Rodgers
Subject: Re: diary display won't initialise correctly?
Date: Mon, 10 Feb 2003 17:29:10 -0700
User-agent: Mozilla/5.0 (X11; U; SunOS i86pc; en-US; rv:0.9.4.1) Gecko/20020406 Netscape6/6.2.2

Kester Clegg wrote:

Kevin Rodgers <kevin.rodgers@ihs.com> writes:
(defadvice view-diary-entries (before number-of-diary-entries activate)
  "If ARG is not specified, display `number-of-diary-entries' instead of 1."
  (if (and (interactive-p)
           (null current-prefix-arg))
      (ad-set-arg 0 number-of-diary-entries)))


Thanks for that, seems to work fine - so is defadvice the standard way
to get a hook into something before it runs?  What made you take that
route?

Since view-diary-entries isn't controlled by a variable, there's no
other way to do it without defining your own command that merely calls
view-diary-entries with an explicit argument -- and I would be loathe to
do that just to provide a more sensible interactive default.

--
<a href="mailto:&lt;kevin.rodgers&#64;ihs.com&gt;";>Kevin Rodgers</a>



reply via email to

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