flymake-posframe/README.org

33 lines
1.8 KiB
Org Mode
Raw Normal View History

2018-12-29 12:10:02 +11:00
* flymake-posframe
[[http://www.gnu.org/licenses/gpl-3.0.txt][https://img.shields.io/badge/license-GPL_3-green.svg]]
Display Emacs 26 flymake errors using [[https://github.com/tumashu/posframe][posframe]].
** Description
Emacs 26 includes a reworked =flymake-mode= to provide a built-in error checking and reporting tool. flymake-posframe displays these reports in a pop-up frame, as opposed to the older method of popups of rendering them over the top of the existing buffer as text.
flymake-posframe is heavily inspired by [[https://github.com/alexmurray/flycheck-posframe][flycheck-posframe]] and [[https://github.com/meqif/flymake-diagnostic-at-point][flymake-diagnostic-at-point]], and is essentially a rewrite of the former to plug into the latter. I wrote this primarily as a way to display diagnostics in a way that I was more familiar with while using [[https://github.com/joaotavora/eglot][eglot]], as it uses flymake as its reporting backend.
** Usage
#+BEGIN_SRC emacs-lisp
(with-eval-after-load 'flymake
(require 'flymake-posframe)
(add-hook 'flymake-mode-hook #'flymake-posframe-mode))
#+END_SRC
** Customisation
- =flymake-posframe-display-delay= :: flymake-posframe uses [[https://github.com/meqif/flymake-diagnostic-at-point][flymake-diagnostic-at-point]] to automatically display the diagnostic posframe after a delay on hover. Setting to =0= disables this behaviour.
- =flymake-posframe-display-function= :: Allows overriding the default display function.
- =flymake-posframe-<type>-prefix= :: Customise the message shown before any posframe diagnostic.
- =flymake-posframe-<type>-face= :: Customise the face to show diagnostics in. By default, inherits from =default=.
** License
Copyright © 2018 Alex Smith
Distributed under the GNU General Public License, version 3.