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

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

bug#36858: 27.0.50; display bugs with display-fill-column-indicator-mode


From: Ergus
Subject: bug#36858: 27.0.50; display bugs with display-fill-column-indicator-mode
Date: Mon, 5 Aug 2019 17:27:47 +0200
User-agent: NeoMutt/20180716

Hi Eli:

I have been looking into this issue and I already fixed both, but I have
a doubt and two comments.

Comment:

1) The condition ends_at_zv_p didn't work as expected, I don't know If
this is an issue somewhere else, but at least in my tests, the condition
was always false. (for all the lines implied before and after ZV, where
there was company window or not)

So the filter condition I am using now is:

IT_CHARPOS (*it) < ZV

which seems to work fine.

2) There is a corner case because the indicator is never generated for
the latest line in the buffer. So a \n is required always at the end of
the buffer if there is text, which for me is fine (unix format), but I
don't know if I should correct that, should I? This issue was there
before this latest changes, so it is unrelated and it is not really so
significant I think.

Doubt:

In terminal emacs, in the original emacs-26 code, in the function:
extend_face_to_end_of_line the code was:

```
face = FACE_FROM_ID (f, (it->face_before_selective_p
                           ? it->saved_face_id
                           : it->face_id));
(...)

if (it->glyph_row->ends_at_zv_p)
    it->face_id = default_face->id;
else
    it->face_id = face->id;
PRODUCE_GLYPHS (it);

while (it->current_x <= it->last_visible_x)
    PRODUCE_GLYPHS (it);
```

So the rest of the line was filled with the last face, (so this issue was
already there since then, because the rest of the line is filled with an
underlined face)

I can change the code to fill the rest of the line with a new merged
face (as I do for graphical emacs), but I think that this fix is
unrelated with dfci, so maybe someone else must give a look before to
prevent me breaking anything.

Which face is the right one to use to fill the rest of the row in the
general case?

For my case I use:
   merge_faces (it->w, Qfill_column_indicator, 0, saved_face_id)

because Qfill_column_indicator face has explicitly set underline and
overline (and some other properties) to false; But maybe we need an
extra face with same properties?

What do you suggest?


On Fri, Aug 02, 2019 at 12:16:52PM +0300, Eli Zaretskii wrote:
From: Davor Rotim <address@hidden>
Date: Tue, 30 Jul 2019 20:11:04 +0200

Hello, in the attached images are two cases I noticed where 
`display-fill-column-indicator-mode' causes
display bugs. First case is with faces that use the :overline or :underline 
property, the lines will extend fully
towards the indicator. Second case is with `company-mode' when there's no text 
entered and the completion
dialog pops up which display-fill-column-indicator-mode treats like ordinary 
text.

Jimmy, could you please take a look at these two issues?

Thanks.





reply via email to

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