all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Providing additional information with C-h f
@ 2024-12-10 22:59 Heime via Users list for the GNU Emacs text editor
  0 siblings, 0 replies; only message in thread
From: Heime via Users list for the GNU Emacs text editor @ 2024-12-10 22:59 UTC (permalink / raw)
  To: Heime via Users list for the GNU Emacs text editor



Have changed the value of companiol-navaid-level to 3, hoping that the documentation 
of the function companiol-launch will update.  But it does not.  

The documentation is evaluated once when the function is defined, and not dynamically 
when companiol-navaid-level changes.  Is there some other way to do this?  To provide 
more information about a function according to the desire of the user?

Perhaps one can include a link in the documentation string to show more information about
the function, or something similar.

(defun companiol-update-doc ()
  "Update the documentation string of `companiol-launch` dynamically."

  (let ( (doc (concat
              "Launch company-mode globally."
              (when (>= companiol-navaid-level 1)
                (concat "\n\n" companiol-dlvsec))
              (when (>= companiol-navaid-level 2)
                (concat "\n\n" companiol-dlvtri))
              (when (>= companiol-navaid-level 3)
                (concat "\n\n" companiol-dlvqtr)))) )

    (put 'paharganj-company-launch 'function-documentation doc)))

(defun companiol-launch (actm-seqr)
  "Launch company-mode globally."

  (companiol-update-doc))



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

only message in thread, other threads:[~2024-12-10 22:59 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-12-10 22:59 Providing additional information with C-h f Heime via Users list for the GNU Emacs text editor

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.