Hello,

I am probably just doing something stupid:

I want to set up a bunch of interactive commands that are somewhat alike

here is a contrived example:

(defmacro deftext (functionname texttoinsert)
  `(defun ,(make-symbol (concatenate 'string "text-" functionname)) ()
     (interactive)
     (insert-string ,texttoinsert)))

(deftext "swallow" "What is the flight speed velocity of a laden swallow?")

I would expect this to create an interactive function that I could
call text-swallow that inserts the bigger string.

if I macroexpand the macro, paste the results and evaluate that in the
buffer, I get exactly the function I want (for my contrived example),
but if I just evaluate the macro above, the function doesn't appear to
be interactive.

Thanks,
Kelly McDonald


Reply via email to