[Top][All Lists]

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

Re: Question about display engine

From: Ergus
Subject: Re: Question about display engine
Date: Thu, 8 Aug 2019 18:43:19 +0200
User-agent: NeoMutt/20180716

On Thu, Aug 08, 2019 at 04:59:54PM +0300, Eli Zaretskii wrote:
Cc: Eli Zaretskii <address@hidden>
From: martin rudalics <address@hidden>
Date: Thu, 8 Aug 2019 15:05:37 +0200

 > Yes, that's exactly the point. The only face I see that needs to be
 > extended so far is the region. If only the region is extended
 > (assuming we won't stop extending that one too) you won't need your
 > workarounds, extra settings, another flag in the face structure, or
 > call extend face to end of line most of the time.

I'm afraid things are not that simple.  We have at least the secondary
selection and 'hl-line-mode' to take care of.

Indeed, nothing is ever as simple in the display code, due to the
sheer amount of different use cases.  I think at least one other face
attribute that's special in this regard is :box, in particular (but
not only) because extend_face_to_end_of_line is called from the
function which redisplays the mode line and the header line.

Yes I have seen :p. That's why I will vote for simplicity+efficiency
over more complex customization that 99% of the users won't

I only want a uniform behavior between gui and tui. Because bigger
changes I have understand that are close to impossible.

Moreover, there might be users who do prefer the current way of
extending (and not extending) faces to window edges.  And I have no
idea whether image or rectangular regions require special treatment

Yes, I think we will have to provide some backward compatibility shims
for these and other use cases.

So finally what's the agreement about this? Does Eli (or anyone) have
the time to implement it?? (else I can try with some hints of
course). Can we add maybe a deadline to decide? I'm just wondering that
this can be forgotten like the discussion in Bug#23574 if nobody starts
working on it.

When and who decides/approves the changes to do?

I vote for:

Reproduce in TUI the gui behavior as is now by default but:

1) With a not-extend-by-default policy

2.0) With some condition checks to extend the mentioned exceptions
(secondary, region, hl_line_mode etc) maybe this last can be set in a
customizable variable as there will be relatively few elements.


2.1) Add the "extensible" flag to the face.

3) Add an extra face to extend (like in my previous code) that needs to
be merged with the last face in the line conditionally and can be used
in case the user wants extend but removing the underline and keeping
the background color (for example).

This seems to be the most general solution in my opinion.

I am specially concerned about this because org-mode behavior in
terminal affects many users.

reply via email to

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