bug-ncurses
[Top][All Lists]
Advanced

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

Re: 'touchcell' functions?


From: Bill Gray
Subject: Re: 'touchcell' functions?
Date: Tue, 27 Jun 2023 11:14:59 -0400
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0



On 6/27/23 03:50, Thomas Dickey wrote:
On Mon, Jun 26, 2023 at 02:11:28PM -0400, Bill Gray wrote:
    Am I correct in thinking that these functions don't exist,  in ncurses or
elsewhere?  (PDCurses and PDCursesMod provide some of this information,  but
only by examining internal WINDOW struct data.)

correct - not in NetBSD curses, either (which inherits some little-used
functions from around 1990 in 4.4BSD).

It could be done in ncurses and other implementations using the first/last
character change on a given line,

Ah, yes... I see ncurses has 'firstchar' and 'lastchar' fields similar to the _firstch and _lastch ones in PDCurses and PDCursesMod.

but I don't recall any expressed need for this (ymmv).

The need is, I admit, _very_ minor. In the PDCurses and PDCursesMod panel libraries, overlapping windows are checked with logic that boils down to "if this line in window1 is touched, touch the corresponding line in window2." Ideally, we would instead say "if the touched range in this line in window1 overlaps window2, then touch the corresponding cells in window2."

The PDCurses* panel libraries have deeper issues, though, so I think I'll drop this as "not needed".

Thanks!          -- Bill



reply via email to

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