Closed MeltWS closed 4 years ago
I can overwritte binds, but they won't work during the completion.
For example when trying to rebind the toggle help function to an ununsed keybind, it will not call the function when the keys are pressed.
I tested with
(define-key company-posframe-active-map (kbd "<f4>") 'company-posframe-quickhelp-toggle)
, seem to work
in company-posframe-quickhelp-show-params not all posframe supported options are working
if my understanding is correct, it should be possible to use foreground-color or background-color directly.
They are alternatives like setting a face but it seems posframe should be able to handle thoses directly?
background-color and foreground-color are controled by company-posframe-quickhelp face
having a max-height max-width setting for quickhelp
I tried writing something but the result was very unsatisfying. The quickhelp frame is drawn where the precedent was, which leads to issues when increasing the size. It seems like this would take a bit of effort, to get something good would require better positional handling of the frame.
the real problem is doc's hight and width, you can try and pr :-)
an option to offset the quickhelp
customize company-posframe-quickhelp-show-params's :poshandler is right thing :-) If you think your poshandler is better than default, just pr and change default poshandler
(define-key company-posframe-active-map (kbd "<f4>") 'company-posframe-quickhelp-toggle)
, seem to work
Doesn't work for me, if I bind an unbound key to company-posframe-active-map
and I try using it during completion, it just prompt for undefined
it's like the keymap is inactive.
Using which-key
confirms company-posframe-active-map
exist and I can override binds correctly.
As a workaround I tried binding directly in company-active-map
it works as long as I call directly company-posframe functions.
I can't get it to work if I call them from a custom function ie
(defun my-company-posframe-quickhelp-toggle ()
(interactive)
(company-posframe-quickhelp-toggle) ;; Doesn't work
)
I don't know how to debug why complany-posframe-active-map
doesn't activate during completion
I tried debuging for the workaround, it seems to make the correct call to posframe-funcall
to check if the quickhelp frame is visible but when called using custom function, it always returns the frame is hidden, so something is happening to the frame before that I guess.
having a max-height max-width setting for quickhelp I tried writing something but the result was very unsatisfying. The quickhelp frame is drawn where the precedent was, which leads to issues when increasing the size. It seems like this would take a bit of effort, to get something good would require better positional handling of the frame.
the real problem is doc's hight and width, you can try and pr :-)
Doesn't work for me, if I bind an unbound key to company-posframe-active-map and I try using it during completion, it just prompt for undefined it's like the keymap is inactive.
Using which-key confirms company-posframe-active-map exist and I can override binds correctly.
Try to reinstall company to new version
Try to reinstall company to new version
Reinstalling company related packages worked thanks.
First of all I want to say thanks for this package, it works well as a child frame alternative to company popup, which is quite usefull, and is not too slow like some alternative are.
that said, if I may give a list of some things I found out are not working for me, or that could be nice to improve.
bugs
company-posframe-quickhelp-show-params
not all posframe supported options are working if my understanding is correct, it should be possible to useforeground-color
orbackground-color
directly. They are alternatives like setting a face but it seems posframe should be able to handle thoses directly?Some things that could be improved
[x] Option to hide the header on quickhelp I can PR if you want
[x] List active backends before inactives
[ ] having a
max-height
max-width
setting for quickhelp I tried writing something but the result was very unsatisfying. The quickhelp frame is drawn where the precedent was, which leads to issues when increasing the size. It seems like this would take a bit of effort, to get something good would require better positional handling of the frame.[x] an option to offset the quickhelp I guess this is more of a request for posframe directly, the only way I found currently to offset the quickhelp frame is to write my own poshandler.
doesn't seem iddeal
```elisp (defun my-company-posframe-quickhelp-right-poshandler (_info) (with-current-buffer company-posframe-buffer (let ((pos posframe--last-posframe-pixel-position)) (cons (+ (car pos) (+ company-posframe-quickhelp-y-offset (frame-pixel-width posframe-- frame))) (cdr pos))))) ```[ ] prevent frame from going over the modline and doing things like below
example
![image](https://user-images.githubusercontent.com/15630634/74089917-5a67cc80-4aa6-11ea-972d-8f0209966429.png)