emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/company 54cf6f8 2/2: Merge pull request #1279 from yuga


From: ELPA Syncer
Subject: [elpa] externals/company 54cf6f8 2/2: Merge pull request #1279 from yugaego/tooltip-minimum
Date: Thu, 23 Dec 2021 05:57:12 -0500 (EST)

branch: externals/company
commit 54cf6f8d0990b4e9210ea55af86eae13603d3f33
Merge: 3432f9e c09ff70
Author: Dmitry Gutov <dgutov@yandex.ru>
Commit: GitHub <noreply@github.com>

    Merge pull request #1279 from yugaego/tooltip-minimum
    
    Improve company-tooltip-minimum docs
---
 company.el                                 |   5 +++--
 doc/company.texi                           |  27 ++++++++++++++++++---------
 doc/images/large/tooltip-minimum-above.png | Bin 0 -> 96871 bytes
 doc/images/large/tooltip-minimum-below.png | Bin 0 -> 51038 bytes
 doc/images/small/tooltip-minimum-above.png | Bin 0 -> 42117 bytes
 doc/images/small/tooltip-minimum-below.png | Bin 0 -> 22238 bytes
 6 files changed, 21 insertions(+), 11 deletions(-)

diff --git a/company.el b/company.el
index 8f7fcbb..f5894b7 100644
--- a/company.el
+++ b/company.el
@@ -266,8 +266,9 @@ The visualized data is stored in `company-prefix', 
`company-candidates',
   :type 'integer)
 
 (defcustom company-tooltip-minimum 6
-  "The minimum height of the tooltip.
-If this many lines are not available, prefer to display the tooltip above."
+  "Ensure visibility of this number of candidates.
+When that many lines are not available between point and the bottom of the
+window, display the tooltip above point."
   :type 'integer)
 
 (defcustom company-tooltip-minimum-width 0
diff --git a/doc/company.texi b/doc/company.texi
index 7d12bbf..22f2cc8 100644
--- a/doc/company.texi
+++ b/doc/company.texi
@@ -678,22 +678,31 @@ displayed by the current tooltip page.
 @end defopt
 
 @defopt company-tooltip-minimum
-When the number of lines between the point and the bottom of the
-window is less than @code{company-tooltip-minimum} value, then the
-tooltip is displayed above the point.
+This user option acts only when a tooltip is shown close to the bottom
+of a window.  It guarantees visibility of this number of completion
+candidates below point.  When the number of lines between point and
+the bottom of a window is less than @w{@code{company-tooltip-minimum}}
+value, the tooltip is displayed above point.
 
 @lisp
 (setq company-tooltip-minimum 4)
 @end lisp
+
+@img{tooltip-minimum-below}
+
+@ifnothtml
+@sp 1
+@end ifnothtml
+
+@img{tooltip-minimum-above}
 @end defopt
 
 @defopt company-tooltip-flip-when-above
 This is one of the fancy features Company has to suggest.  When this
-setting is enabled, no matter if a tooltip is shown above or below the
-point, the candidates are always listed starting near the point.
-(Putting it differently, the candidates are mirrored horizontally if a
-tooltip changes its position, instead of being commonly listed
-top-to-bottom.)
+setting is enabled, no matter if a tooltip is shown above or below
+point, the candidates are always listed starting near point.  (Putting
+it differently, the candidates are mirrored horizontally if a tooltip
+changes its position, instead of being commonly listed top-to-bottom.)
 
 @lisp
 (setq company-tooltip-flip-when-above t)
@@ -882,7 +891,7 @@ Frontends in this group output a completion candidate or a 
common part
 of the candidates temporarily inline, as if a word had already been
 completed @footnote{The candidates retrieved according to
 @code{non-prefix} matches (@pxref{Terminology}) may be shown in full
-after the point.}.
+after point.}.
 
 @defun company-preview-if-just-one-frontend
 This is one of the frontends enabled by default.  This frontend
diff --git a/doc/images/large/tooltip-minimum-above.png 
b/doc/images/large/tooltip-minimum-above.png
new file mode 100644
index 0000000..0c6ac46
Binary files /dev/null and b/doc/images/large/tooltip-minimum-above.png differ
diff --git a/doc/images/large/tooltip-minimum-below.png 
b/doc/images/large/tooltip-minimum-below.png
new file mode 100644
index 0000000..f300bde
Binary files /dev/null and b/doc/images/large/tooltip-minimum-below.png differ
diff --git a/doc/images/small/tooltip-minimum-above.png 
b/doc/images/small/tooltip-minimum-above.png
new file mode 100644
index 0000000..0052ca5
Binary files /dev/null and b/doc/images/small/tooltip-minimum-above.png differ
diff --git a/doc/images/small/tooltip-minimum-below.png 
b/doc/images/small/tooltip-minimum-below.png
new file mode 100644
index 0000000..c7b3f19
Binary files /dev/null and b/doc/images/small/tooltip-minimum-below.png differ



reply via email to

[Prev in Thread] Current Thread [Next in Thread]