Giter Club home page Giter Club logo

Comments (2)

yanghaoxie avatar yanghaoxie commented on July 19, 2024

which-key--hide-popup - why would it try to hide the popup when it was never opened, I'm just moving cursor around?

  1. I think this is because the fowlling code in which-key:
(add-hook 'pre-command-hook #'which-key--hide-popup)
  1. Maybe you can use profiler to see which functions cause the lag, and please post the profiler report here in order to let us investigate the possible issues.

from which-key-posframe.

eeshugerman avatar eeshugerman commented on July 19, 2024

I'm seeing this too. It's strange because I've used this package for a long time now, and only in the past few weeks has this become an issue for me. A few notes:

I don't see this issue on my Mac, which is running v28/master, from this project.

On GNU/Linux I'm using the v28/master + pgtk fork from the AUR. I think pgtk might be part of the problem. @agzam, are you using pgtk perchance? I'm not sure if it's a thing on Mac.


When I open something (e.g., a big .org file), moving the cursor around initially is slow; I'd disable which-key-posframe and, voila - it gets fast again. I would re-enable the mode - and it is still fast, it won't go back to lagging as when I open the file. So, it is slow only when the first time I open the file.

I observe this too, but it usually becomes slow again once I do something to actually activate which-key-posframe (eg <C-x>, pause...).


I can reproduce this with a very minimal setup: emacs -Q and then:

(require 'which-key)
(require 'which-key-posframe)

(which-key-mode 1)
(which-key-posframe-mode 1)

...so I think we can rule out interactions with other packages.


Maybe you can use profiler to see which functions cause the lag, and please post the profiler report here in order to let us investigate the possible issues.

Here's mine:

         626  46% - which-key--hide-popup
         621  45%  - which-key--hide-popup-ignore-command
         621  45%   - which-key-posframe--hide
         604  44%      posframe-hide
         264  19% + timer-event-handler
         173  12% + command-execute
         122   9% + eldoc-pre-command-refresh-echo-area
         113   8% + redisplay_internal (C function)
          19   1% + sp--save-pre-command-state
          12   0% + winner-save-old-configurations
           8   0% + evil--jump-hook
           5   0% + evil-repeat-pre-hook
           4   0% + global-hl-line-highlight
           3   0%   sp--post-command-hook-handler
           3   0% + highlight-parentheses--initiate-highlight
           3   0% + evil-escape-pre-command-hook
           0   0% + ...

from which-key-posframe.

Related Issues (14)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.