all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Defaults for optional arguments for use with interactive
@ 2024-09-07 14:44 Heime
  0 siblings, 0 replies; only message in thread
From: Heime @ 2024-09-07 14:44 UTC (permalink / raw)
  To: Heime via Users list for the GNU Emacs text editor

With the following function, how can I default actm to be 'list
so that the "(interactive (list" part guts executed rather than 
the "(interactive string" part ?


(defun xiakos-context (search-text &optional n actm)

  (setq n (or n 8))
  (setq actm (or actm 'list))

  (interactive

   (cond
     ((eq actm 'list)

         (list
           (read-string "Search Text: ")
           (read-number "Number of Context Lines: ")
           ('list)))

     (t

         "s - Search Text: \n\
n - Number of Context Lines: ") ))




^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2024-09-07 14:44 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-09-07 14:44 Defaults for optional arguments for use with interactive Heime

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.