MyWebUniversity.com Home Page
 



OpenSolaris man pages main menu


X/Open Curses Library Functions             slkattroff(3XCURSES)



NAME
     slkattroff,    slkattroff,    slkattron,    slkattron,
     slkattrset,  slkattrset,  slkclear, slkcolor, slkinit,
     slklabel,   slknoutrefresh,   slkrefresh,    slkrestore,
     slkset, slktouch, slkwset - soft label functions

SYNOPSIS
     cc [ flag... ] file... -I /usr/xpg4/include  -L  /usr/xpg4/lib \
      -R  /usr/xpg4/lib  -lcurses  [ library... ]

     c89 [ flag... ] file... -lcurses [ library... ]

     #include 

     int slkattroff(const chtype attrs);


     int slkattroff(const attrt attrs, void *opts);


     int slkattron(const chtype attrs);


     int slkattron(const attrt attrs, void *opts);


     int slkattrset(const chtype attrs);


     int slkattrset(const attrt attrs, short colorpairnumber, void *opts);


     int slkclear(void);


     int slkcolor(short colorpairnumber);


     int slkinit(int fmt);


     char *slklabel(int labnum);


     int slknoutrefresh(void);


     int slkrefresh(void);


     int slkrestore(void);




SunOS 5.11           Last change: 5 Jun 2002                    1






X/Open Curses Library Functions             slkattroff(3XCURSES)



     int slkset(int labnum, const char *label, int justify);


     int slktouch(void);


     int slkwset(int labnum, const wchart *label, int justify);


PARAMETERS
     attrs                are the window attributes to  be  added
                          or removed.


     opts                 Is reserved for future use.  Currently,
                          this must be a null pointer.


     colorpairnumber    Is a color pair.


     fmt                  Is the format of  how  the  labels  are
                          arranged on the screen.


     labnum               Is the number of the soft label.


     label                Is the name  to  be  given  to  a  soft
                          label.


     justify              Is a number indicating how  to  justify
                          the label name.


DESCRIPTION
     The Curses interface manipulates the set of  soft  function-
     key labels that exist on many terminals. For those terminals
     that do not have soft labels, Curses takes over  the  bottom
     line of stdscr, reducing the size of stdscr and the value of
     the LINES external variable. There can be up to eight labels
     of up to eight display columns each.


     To use soft labels, slkinit() must be called before calling
     initscr(3XCURSES),           newterm(3XCURSES),           or
     ripoffline(3XCURSES). If initscr() eventually  uses  a  line
     from  stdscr to emulate the soft labels, then fmt determines
     how the labels are arranged on the screen. Setting fmt to  0
     indicates  a  3-2-3 arrangement of the labels; 1 indicates a
     4-4 arrangement. Other values for fmt are unspecified.



SunOS 5.11           Last change: 5 Jun 2002                    2






X/Open Curses Library Functions             slkattroff(3XCURSES)



     The slkinit() function has the effect  of  calling  ripoff-
     line()  to  reserve  one  screen  line  to  accommodate  the
     requested format.


     The slkset() and slkwset() functions specify the  text  of
     soft  label  number  labnum,  within the range from 1 to and
     including 8. The label argument is the string to be put  the
     lable. With slkset() and slkwset(), the width of the label
     is limited to eight columns positions. A null  string  or  a
     null  pointer  specifies a blank label. The justify argument
     can have the following values to  indicate  how  to  justify
     label within the space reserved for it:

     0    Align the start of label with the start of the space


     1    Center label within the space


     2    Align the end of label with the end of the space



     The slkrefresh() and slknoutrefresh() functions correspond
     to  the  wrefresh(3XCURSES) and wnoutrefresh(3XCURSES) func-
     tions.


     The slklabel() function obtains soft label number labnum.


     The slkclear() function immediately clears the soft  labels
     from the screen.


     The slkrestore() function  immediately  restores  the  soft
     labels to the screen after a call to slkclear().


     The slktouch() function forces all the soft  labels  to  be
     output  the  next time slkrefresh() or slknoutrefresh() is
     called.


     The slkattron(), slkattrset(), and slkattroff() functions
     correspond  to  the attron(3XCURSES), attrset(3XCURSES), and
     attroff(3XCURSES) functions. They have  an  effect  only  if
     soft labels are stimulated on the bottom line of the screen.






SunOS 5.11           Last change: 5 Jun 2002                    3






X/Open Curses Library Functions             slkattroff(3XCURSES)



     The  slkattron(),   slkattroff(),   slkattrset()   and
     slkcolor()  functions  correspond to the attron(3XCURSES),
     attroff(3XCURSES),         attrset(3XCURSES),          and
     colorset(3XCURSES)  functions.  As  a  result, they support
     color and the attribute constants with the WA prefix.


     The opts argument is reserved for  definition  in  a  future
     release. Currently, the opts argument is a null pointer.

RETURN VALUES
      Upon  successful  completion,  the   slklabel()   function
     returns the requested label with leading and trailing blanks
     stripped. Otherwise, it returns a null pointer.


      Upon successful completion, the other functions return  OK.
     Otherwise, they return ER.

ERORS
     No errors are defined.

USAGE
      When using multi-byte character sets,  applications  should
     check  the  width  of the string by calling mbstowcs(3C) and
     then wcswidth(3C) before calling slkset(). When using  wide
     characters,  applications  should  check  the  width  of the
     string by calling wcswidth() before calling slkset().


     Since the number of columns that a wide string  will  occupy
     is  codeset-specific,  call  wcwidth(3C) and wcswidth(3C) to
     check the number of column positions in  the  string  before
     calling slkwset().


      Most applications would  use  slknoutrefresh()  because  a
     wrefresh() is likely to follow soon.

ATRIBUTES
     See attributes(5) for descriptions of the  following  attri-
     butes:













SunOS 5.11           Last change: 5 Jun 2002                    4






X/Open Curses Library Functions             slkattroff(3XCURSES)



     
           ATRIBUTE TYPE               ATRIBUTE VALUE       
    
     Interface Stability          Standard                    
    
     MT-Level                     Unsafe                      
    


SEE ALSO
     attrget(3XCURSES), attroff(3XCURSES),  delscreen(3XCURSES),
     libcurses(3XCURSES),   mbstowcs(3C),   ripoffline(3XCURSES),
     wcswidth(3C), wcwidth(3C), attributes(5), standards(5)










































SunOS 5.11           Last change: 5 Jun 2002                    5



OpenSolaris man pages main menu

Contact us      |       About us      |       Term of use      |       Copyright © 2000-2010 MyWebUniversity.com ™