X-Git-Url: https://ncurses.scripts.mit.edu/?a=blobdiff_plain;f=doc%2Fhtml%2Fncurses-intro.html;h=451e7ab4d32dba74f0b72854dd9f9c9fb495476b;hb=9edffa2f21102c06dcf682d58b074c407bcedd0a;hp=3500e7a6f84636edb04b3297d8d917d9ba8cb15c;hpb=46722468f47c2b77b3987729b4bcf2321cccfd01;p=ncurses.git diff --git a/doc/html/ncurses-intro.html b/doc/html/ncurses-intro.html index 3500e7a6..451e7ab4 100644 --- a/doc/html/ncurses-intro.html +++ b/doc/html/ncurses-intro.html @@ -1,11 +1,39 @@
@@ -613,6 +636,7 @@ Presently, mouse event reporting works in the following environments:
gpm
(1), Alessandro
Rubini's mouse server.
+
@@ -690,7 +714,7 @@ the first call to refresh()
will clear the screen. If an error
occurs a message is written to standard error and the program
exits. Otherwise it returns a pointer to stdscr. A few functions may be
called before initscr (slk_init()
, filter()
,
-ripofflines()
, use_env()
, and, if you are using multiple
+ripoffline()
, use_env()
, and, if you are using multiple
terminals, newterm()
.)
endwin()
endwin()
before exiting or
@@ -732,7 +756,7 @@ the terminal, as other routines merely manipulate data
structures. wrefresh()
copies the named window to the physical
terminal screen, taking into account what is already
there in order to do optimizations. refresh()
does a
-refresh of stdscr()
. Unless leaveok()
has been
+refresh of stdscr
. Unless leaveok()
has been
enabled, the physical cursor of the terminal is left at the
location of the window's cursor.
doupdate()
and wnoutrefresh(win)
@@ -890,15 +914,14 @@ Here is some sample code for shellout:
ncurses
library provides an experimental signal
-handler, but in general does not catch this signal, because it cannot
-know how you want the screen re-painted. You will usually have to write the
-SIGWINCH handler yourself. Ncurses can give you some help.
+A resize operation in X sends SIGWINCH
to the application running
+under xterm.
-The easiest way to code your SIGWINCH handler is to have it do an
-endwin
, followed by an refresh
and a screen repaint you code
-yourself. The refresh
will pick up the new screen size from the
+The easiest way to handle SIGWINCH
+is to do an endwin
,
+followed by an refresh
and a screen repaint you code
+yourself.
+The refresh
will pick up the new screen size from the
xterm's environment.
That is the standard way, of course (it even works with some vendor's curses
@@ -910,8 +933,17 @@ not resize subwindows which must be shrunk.
are limited to the new screen dimensions, and pads stdscr
with blanks if the screen is larger.
-Finally, ncurses can be configured to provide its own SIGWINCH handler,
-based on resizeterm
.
+The ncurses
library provides a SIGWINCH signal handler,
+which pushes a KEY_RESIZE
via the wgetch() calls.
+When ncurses
returns that code,
+it calls resizeterm
+to update the size of the standard screen's window, repainting that
+(filling with blanks or truncating as needed).
+It also resizes other windows,
+but its effect may be less satisfactory because it cannot
+know how you want the screen re-painted.
+You will usually have to write special-purpose code to handle
+KEY_RESIZE
yourself.
The really clean way to handle this is to use the panels library. If,
when you want a screen update, you do update_panels()
, it will
-do all the necessary wnoutrfresh()
calls for whatever panel
+do all the necessary wnoutrefresh()
calls for whatever panel
stacking order you have defined. Then you can do one doupdate()
and there will be a single burst of physical I/O that will do
all your updates.
@@ -1222,10 +1254,10 @@ The general flow of control of a menu program looks like this:
curses
.
new_item()
.
new_menu()
.
-menu_post()
.
+post_menu()
.
menu_unpost()
.
+unpost_menu()
.
free_menu()
.
free_item()
.
curses
.
@@ -1308,8 +1340,8 @@ refreshed or erased at post/unpost time. The inner window or
By default, both windows are stdscr
. You can set them with the
functions in menu_win(3x)
.
-When you call menu_post()
, you write the menu to its
-subwindow. When you call menu_unpost()
, you erase the
+When you call post_menu()
, you write the menu to its
+subwindow. When you call unpost_menu()
, you erase the
subwindow, However, neither of these actually modifies the screen. To
do that, call wrefresh()
or some equivalent.
@@ -1441,10 +1473,10 @@ The general flow of control of a form program looks like this:
curses
.
new_field()
.
new_form()
.
-form_post()
.
+post_form()
.
form_unpost()
.
+unpost_form()
.
free_form()
.
free_field()
.
curses
.
@@ -1480,7 +1512,7 @@ the screen (the third and fourth arguments, which must be zero or
greater). Note that these coordinates are relative to the form
subwindow, which will coincide with stdscr
by default but
need not be stdscr
if you've done an explicit
-set_form_window()
call.
+set_form_win()
call.
The fifth argument allows you to specify a number of off-screen rows. If
this is zero, the entire field will always be displayed. If it is
@@ -2160,7 +2192,7 @@ These requests treat the list as cyclic; that is, REQ_NEXT_PAGE
from the last page goes to the first, and REQ_PREV_PAGE
from
the first page goes to the last.
-
REQ_MOVE_RIGHT
from A will
go to B only if A, B, and C all share the same first line;
otherwise it will skip over B to C.
-REQ_NEW_LINE
as described in Editing Requests. The value of this option is
+href="#fedit">Editing Requests. The value of this option is
ignored on dynamic fields that have not reached their size limit;
these have no last line, so the circumstances for triggering a
REQ_NEXT_FIELD
never arise.
REQ_DEL_PREV
as described in
-Editing Requests.
+Editing Requests.