nano-devel
[Top][All Lists]
Advanced

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

Re: [Nano-devel] Softwrap navigation overhaul


From: David Ramsey
Subject: Re: [Nano-devel] Softwrap navigation overhaul
Date: Thu, 9 Feb 2017 10:20:28 -0600

On Thu, Feb 9, 2017 at 6:12 AM, Benno Schulenberg
<address@hidden> wrote:
> The latter sounds like the right approach.  Then we can finally get
> rid of all this partitioning.

Except of course for the partitioning in copy_from_filestruct() :)

> Surely that can be adjusted, to be made to work.

Okay.  And execute_command() needs adapting too.

> Yes, this is far from easy.

Detecting it in display_string() may be the wrong place.  Maybe start
adapting Mark Majeres' line-breaking softwrap on top of what I have,
making it break lines not only at whitespace near the edge of the
screen, but at unbreakable two-column Unicode there as well?  At least
the left edge will always be a multiple of the number of columns; only
the right edge will vary.

> This is kind of silly: first you set needed_margin to zero, and then
> compare it with COLS minus three.  So what you're in fact checking is
> whether COLS is at least four, and then you will show line numbers.
> But the idea is: to only show line numbers if they leave at least four
> columns of text visible.  So this 'needed_margin < COLS - 3' test will
> have to come later.

Attached new (standalone) patch that should fix this.

Attachment: 0001-Reshuffle-line-numbering-mode-handling-so-we-always-.patch
Description: Text Data


reply via email to

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