Initializes soft function-key labels.
Curses Library (libcurses.a)
#include <curses.h>
slk_init( Labfmt)
int Labfmt;
The slk_init subroutine initializes soft function-key labels. This is one of several subroutines curses provides for manipulating soft function-key labels. These labels appear at the bottom of the screen and give applications, such as editors, a more user-friendly look. To use soft labels, you must call the slk_init subroutine before calling the initscr or newterm subroutine.
Some terminals support soft labels, others do not. For terminals that do not support soft labels. Curses emulates soft labels by using the bottom line of the stdscr. To accommodate soft labels, curses reduces the size of the stdscr and the LINES environment variable as required.
Item | Description |
---|---|
Labfmt | Simulates soft labels. To arrange three labels on the right, two in the center, and three on the right of the screen, specify a 0 for this parameter. To arrange four labels on the left and four on the right of the screen, specify a 1 for this parameter. |
To initialize soft labels on a terminal that does not support soft labels internally, do the following:
slk_init(1);
This example arranges the labels so that four labels appear on the right of the screen and four appear on the left.