[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: commit "328c9a1af * bad org.el: Enhance menus" caused error
From: |
stardiviner |
Subject: |
Re: commit "328c9a1af * bad org.el: Enhance menus" caused error |
Date: |
Thu, 06 Feb 2020 15:11:30 +0800 |
User-agent: |
mu4e 1.3.2; emacs 27.0.50 |
Bastien <address@hidden> writes:
> Hi,
>
> stardiviner <address@hidden> writes:
>
>> BTW, the function ~org-insert-dblock-bindings~ is from package
>> =orgtbl-aggregate=.
>
> I don't know this function and this package.
>
> Can you share the minimal Emacs config with which you reproduce
> the problem?
Besides of package =orgtbl-aggregate=, seems another package
=orgtbl-ascii-plot= use
same code to define menu too. Here is its code:
#+begin_src emacs-lisp
;;;###autoload
(defun orgtbl-ascii-plot-bindings ()
(org-defkey org-mode-map "\C-c\"a" 'orgtbl-ascii-plot)
(org-defkey org-mode-map "\C-c\"g" 'org-plot/gnuplot)
(easy-menu-add-item
org-tbl-menu '("Column")
["Ascii plot" orgtbl-ascii-plot t]))
;;;###autoload
(if (functionp 'org-defkey)
(orgtbl-ascii-plot-bindings) ;; org-mode already loaded
(setq org-load-hook ;; org-mode will be loaded later
(cons 'orgtbl-ascii-plot-bindings
(if (boundp 'org-load-hook)
org-load-hook))))
#+end_src
Bastien, might consider add a hook after loaded org menus? Like named
~org-menu-after-loaded-hook~ or something else? So third libraries can define
menu
entries with function added on the hook. I think those packages will have to
updated with patches?
--
[ stardiviner ]
I try to make every word tell the meaning what I want to express.
Blog: https://stardiviner.github.io/
IRC(freenode): stardiviner, Matrix: stardiviner
GPG: F09F650D7D674819892591401B5DF1C95AE89AC3