bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#27427: 26.0.50; Native line numbers lead to display error in company


From: Eli Zaretskii
Subject: bug#27427: 26.0.50; Native line numbers lead to display error in company-mode popup
Date: Tue, 20 Jun 2017 18:04:22 +0300

> Cc: 27427@debbugs.gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> Date: Tue, 20 Jun 2017 00:03:08 +0300
> 
> With (setq line-prefix "..."),
> 
> (car (posn-col-row (posn-at-point))) suddenly returns 3 at bol.

I guess you think this result is incorrect, but I don't think I
understand why.  posn-col-row returns the horizontal window-relative
coordinate in units of the frame's canonical column width, so it is
expected that its value at BOL will be non-zero when there's a
line-prefix displayed there.

Can you tell how this value is used in company-mode?  I think the key
to my understanding why this change interferes with company-mode is in
that direction.

> > Per Martin's analysis, the
> > same problems should happen when the buffer has line-prefix defined;
> > could you try that?
> 
> Indeed, it does. But it's easy for company-mode to ignore the 
> possibility of line-prefix variable being set (it almost never happens).
> 
> We do support line-prefix when it's assigned via text property.

If you do support the line-prefix property, why are there problems
with line-prefix the variable?  The effect on display is the same,
AFAIU.





reply via email to

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