all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Calling functions dynamically
@ 2024-09-16 11:08 Heime
  0 siblings, 0 replies; only message in thread
From: Heime @ 2024-09-16 11:08 UTC (permalink / raw)
  To: Heime via Users list for the GNU Emacs text editor

I wonder how to implement the following function dynamically,
so that I will have just a single

    (let ( (anctr  (torium-fpln-anctr xiakos-data)) )
       (torium-fpln-test-chart "xiakos F-Pln" xiakos-data anctr)))

where xiakos-data would use either xiakos-fpln or xiakos-sec-fpln, depending
on the interactive condition.

(defun xiakos-chart (actm)

  (interactive
    (let ( (cseq '("F-PLN" "Sec F-PLN")) )
      (completing-read " ACTM: " cseq nil t "F-PLN")))

  (cond

    ((string-equal actm "F-PLN")

     (let ( (anctr  (torium-fpln-anctr xiakos-fpln)) )
       (torium-fpln-test-chart "xiakos F-Pln" xiakos-fpln anctr)))

    ((string-equal actm "Sec F-PLN")

     (let ( (anctr  (torium-anctr xiakos-sec-fpln)) )
       (torium-fpln-test-chart "xiakos Sec F-Pln" xiakos-sec-fpln anctr))) ))





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

only message in thread, other threads:[~2024-09-16 11:08 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-09-16 11:08 Calling functions dynamically 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.