|
From: | Christer Enfors |
Subject: | Re: filter() prevents clearing of screen, but still clears current line |
Date: | Fri, 16 Mar 2007 15:00:28 +0100 |
User-agent: | Thunderbird 1.5.0.10 (Windows/20070221) |
Thomas Dickey wrote:
On Fri, 16 Mar 2007, Christer Enfors wrote:Thomas Dickey wrote:I assume you mean that you don't want it to clear after the end of your window on the current line. Again, you can fool it:Actually, I'm not explicitly opening a window (should I?), I just callinitscr and newterm make a standard window (stdscr).
I know, but since you said "... after the end of your window on the current line..." it sounded like you were talking about a window that was smaller than the screen (or the current line, as in this case). That made me think that perhaps I was supposed to open my own subwindow for my form.
newterm(). And come to think of it, I don't know if the code clears the line *after* my form field; what I did notice was that it erased my "label" in *front* of the field. Therefore, I assumed it was clearing the entire line.a) make ncurses think that the screen does not extend past your window's right margin, and b) remove the "el" capability (so it will be forced to use blanks to fill the line). See use_env() for the first part.Given the above, should I still do what you say here?yes - I think that's the way to go (if you want to retain text on the right-side of your prompt). I'd normally assume a one-line screen for filter() uses the whole line.
I've tried this now, but it still seems to clear the entire current line before displaying my field. I don't want it to clear anything, only display the field.
I'm starting to suspect that perhaps I should modify my copy of ncurses so that it doesn't clear the line at all on startup when using filter(). We have to ship ncurses with our release anyway, so shipping a modified version of ncurses shouldn't be a problem.
-- Christer Enfors
[Prev in Thread] | Current Thread | [Next in Thread] |