Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SPC key will be translated into two when pressed on top of a flycheck errors #2110

Closed
zilongshanren opened this issue Jun 25, 2015 · 11 comments

Comments

@zilongshanren
Copy link
Contributor

  • How to reproduce, open a file which flycheck turn on
  • press SPC e n move to the next error
  • press SPC

Then you will see two SPC was sent.
Wired~

@zilongshanren
Copy link
Contributor Author

I'm using emacs-mac port and the version is 24.5.1.
I have tested on Linux, there is no such a problem.

@d12frosted
Copy link
Collaborator

Can't reproduce it. Does it still happening to you, @zilongshanren ?

@zilongshanren
Copy link
Contributor Author

@d12frosted
Sometimes it will happens, but sometimes the which-key pop windows can't be shown when cursor is on top of a flycheck warning or error after I press the SPC key.

@StreakyCobra
Copy link
Contributor

I can reproduce this:

  • The which-key not showing problem can be reproduced by:
    • Open your dotspacemacs file: SPC f e d

    • Enable flycheck: SPC t s

    • Go one line above (defun dotspacemacs/layers ()

    • Go down one line (to the error), and press SPC between 0.5 and 0.9 seconds after being on it:

      [0s] On the line
      [0.5s < t1 < 0.9s] SPC pressed
      [0.9s] Flycheck tooltip shown 
      [t1 + 0.4s] which-key should appear, but doesn't
      
    • Notice which-key is not showing up

  • The two SPC in the message-area appear when the error tooltip is already shown and you press SPC (shown only for a brief amount of time)

@justbur @lunaryorn Any idea how to make them play well together?

@justbur
Copy link
Contributor

justbur commented Nov 9, 2015

Looks like an issue with popup.el, specifically these lines https://github.com/auto-complete/popup-el/blob/master/popup.el#L1075-L1076 are screwing with this-command-keys which is something which-key uses to decide whether to show or not

@swsnr
Copy link
Contributor

swsnr commented Nov 9, 2015

@StreakyCobra These are not Flycheck's tooltips. You're using a 3rd party extension for these that I neither wrote nor maintain. I'm surprised that it uses popup now, it didn't when this project became part of the Flycheck org. popup is a horrible library, known for many display issues and faulty interactions with other packages.

I'd recommend you to file an issue on flycheck-pos-tip to make it use pos-tip again. I do have commit access to the project, in case all else fails.

@StreakyCobra
Copy link
Contributor

Thanks @justbur and @lunaryorn for the explanations 👍

swsnr pushed a commit to flycheck/flycheck-pos-tip that referenced this issue Nov 9, 2015
@swsnr
Copy link
Contributor

swsnr commented Nov 9, 2015

@StreakyCobra @syl20bnr I noticed that the original author of flycheck-pos-tip has apparently left Github, so I've taken over maintenance of that extension.

I've reverted the change to popup and made the library use pos-tip again. I hope that this should fix some, if not all, of the issues regarding these tooltips. The changes should make it into the next MELPA build of flycheck-pos-tip, so be prepared for changes to the appearance, behaviour and contents of those tooltips. Please report any issues you discover to the tracker of https://github.com/flycheck/flycheck-pos-tip.

@StreakyCobra
Copy link
Contributor

@StreakyCobra
Copy link
Contributor

@lunaryorn The changes didn't went well on my side 😕. I'll open an issue on flycheck-pos-tip.

@StreakyCobra
Copy link
Contributor

All problems are now resolved thanks to @lunaryorn's work on flyspell-pos-tip. I'm closing it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants