unixdev.net


Switch to SpeakEasy.net DSL

The Modular Manual Browser

Home Page
Manual: (NetBSD-2.0)
Page:
Section:
Apropos / Subsearch:
optional field

cdk_marquee(3)             Library Functions Manual             cdk_marquee(3)



NAME
       newCDKMarquee,   activateCDKMarquee,  drawCDKMarquee,  eraseCDKMarquee,
       setCDKMarqueeULChar, setCDKMarqueeURChar,  setCDKMarqueeLLChar,  setCD-
       KMarqueeLRChar, setCDKMarqueeVerticalChar, setCDKMarqueeHorizontalChar,
       setCDKMarqueeBoxAttribute, setCDKMarqueeBackgroundColor, destroyCDKMar-
       quee - Creates a managed curses marquee widget.

SYNOPSIS
       cc [ flag ... ] file ...  -lcdk [ library ... ]

       #include <cdk.h>

       CDKMARQUEE  *newCDKMarquee  (CDKSCREEN  *cdkscreen, int xpos, int ypos,
       int fieldWidth, boolean shadow);

       int activateCDKMarquee (CDKMARQUEE *marquee, char *message, int  delay,
       int repeat, boolean box);

       void setCDKMarqueeULChar (CDKMARQUEE *,marquee, chtype character);

       void setCDKMarqueeURChar (CDKMARQUEE *,marquee, chtype character);

       void setCDKMarqueeLLChar (CDKMARQUEE *,marquee, chtype character);

       void setCDKMarqueeLRChar (CDKMARQUEE *,marquee, chtype character);

       void  setCDKMarqueeVerticalChar  (CDKMARQUEE  *,marquee, chtype charac-
       ter);

       void setCDKMarqueeHorizontalChar (CDKMARQUEE *,marquee, chtype  charac-
       ter);

       void  setCDKMarqueeBoxAttribute  (CDKMARQUEE  *,marquee, chtype charac-
       ter);

       void setCDKMarqueeBackgroundColor (CDKMARQUEE *,marquee, char * color);

       void moveCDKMarquee (CDKMARQUEE *marquee, int  box,  int  box,  boolean
       relative, boolean refresh);

       void positionCDKMarquee (CDKMARQUEE *marquee);

       void drawCDKMarquee (CDKMARQUEE *marquee, boolean box);

       void eraseCDKMarquee (CDKMARQUEE *marquee);

       void destroyCDKMarquee (CDKMARQUEE *marquee);

DESCRIPTION
       The  Cdk  marquee widget creates a pop-up marquee window. The following
       are functions which create or manipulate the Cdk marquee widget.


AVAILABLE FUNCTIONS
       CDKMARQUEE *newCDKMarquee (CDKSCREEN *screen, int xpos, int  ypos,  int
       fieldWidth, boolean shadow);
          This  function  creates  a  pointer  to a marquee widget. The screen
          parameter is the screen you wish this widget to be  placed  in.  The
          parameter  xpos controls the placement of the object along the hori-
          zontal axis. This parameter can accept an integer value  or  one  of
          the  pre-defined  values  of  LEFT, RIGHT, and CENTER. The parameter
          ypos controls the placement of the object along the  vertical  axis.
          This parameter can accept an integer value or one of the pre-defined
          values of TOP, BOTTOM, and CENTER.  The width  parameter  state  how
          wide  the  field  is  to  be. If you provide a value of zero for the
          width, the widget will assume the full width of  the  screen.  If  a
          negative  value  is  provided,  then the widget will assume the full
          width of the screen minus the value provided. The  shadow  parameter
          accepts  a  boolean  value  to turn the shadow on or off around this
          widget. If the widget could not be created then a  NULL  pointer  is
          returned.

       int  activateCDKMarquee (CDKMARQUEE *marquee, char *message, int delay,
       int repeat, boolean box);
          This function activates the marquee widget. The marquee parameter is
          a  pointer  to  a defined marquee widget. The delay parameter states
          how long to wait between movements. This value is  highly  dependent
          on each machine the program runs on. The repeat value tells the mar-
          quee widget how many times to display the  given  message.  The  box
          option draws the widget with or without a box. This function returns
          -1 if the message passed is NULL, 0 otherwise.

       void setCDKMarqueeULChar (CDKMARQUEE *marquee, chtype character);
          This function sets the upper left hand corner of the widgets box  to
          the given character.

       void setCDKMarqueeURChar (CDKMARQUEE *marquee, chtype character);
          This function sets the upper right hand corner of the widgets box to
          the given character.

       void setCDKMarqueeLLChar (CDKMARQUEE *marquee, chtype character);
          This function sets the lower left hand corner of the widgets box  to
          the given character.

       void setCDKMarqueeLRChar (CDKMARQUEE *marquee, chtype character);
          This function sets the lower right hand corner of the widgets box to
          the given character.

       void setCDKMarqueeVerticalChar (CDKMARQUEE *marquee, chtype character);
          This function sets the vertical drawing character for the box to the
          given character.

       void  setCDKMarqueeHorizontalChar  (CDKMARQUEE *marquee, chtype charac-
       ter);
          This function sets the horizontal drawing character for the  box  to
          the given character.

       void setCDKMarqueeBoxAttribute (CDKMARQUEE *marquee, chtype attribute);
          This function sets the attribute of the box.

       void setCDKMarqueeBackgroundColor (CDKMARQUEE *marquee, char *color);
          This sets the background color of the widget. The parameter color is
          in the format of the Cdk format strings.  To  get  more  information
          look at the cdk_display manual page.

       void  moveCDKMarquee  (CDKMARQUEE *marquee, int xpos, int ypos, boolean
       relative, boolean refresh);
          This function moves the given widget  to  the  given  position.  The
          parameters  xpos  and  ypos  is  the new position of the widget. The
          parameter xpos can accept an integer value or one of the pre-defined
          values  of TOP, BOTTOM, and CENTER. The parameter ypos can accept an
          integer value or one of the pre-defined values of LEFT,  RIGHT,  and
          CENTER.  The parameter relative states whether the xpos/ypos pair is
          a relative move or an absolute move. For example if  xpos  =  1  and
          ypos  =  2  and  relative = TRUE, then the widget would move one row
          down and two columns right. If the value of relative was FALSE  then
          the  widget  would move to the position (1,2). Do not use the values
          of TOP, BOTTOM, LEFT, RIGHT, or CENTER when relative = TRUE.  (weird
          things  may  happen). The final parameter refresh is a boolean value
          which states whether the widget will get refreshed after the move or
          not.

       void positionCDKMarquee (CDKMARQUEE *marquee);
          This  function  allows the user to move the widget around the screen
          via the cursor/keypad keys. The following key bindings can  be  used
          to move the widget around the screen.

          Key Bindings
             Key          Action
             Up Arrow     Moves the widget up one line.
             Down Arrow   Moves the widget down one line.
             Left Arrow   Moves the widget left one column
             Right Arrow  Moves the widget right one column
             Keypad-1     Moves the widget down one line
                          and left one column.
             Keypad-2     Moves the widget down one line.
             Keypad-3     Moves the widget down one line
                          and right one column.
             Keypad-4     Moves the widget left one column
             Keypad-5     Centers the widget both vertically
                          and horizontally.
             Keypad-6     Moves the widget right one column
             Keypad-7     Moves the widget up one line
                          and left one column.
             Keypad-8     Moves the widget up one line.
             Keypad-9     Moves the widget up one line
                          and right one column.
             t            Moves the widget to the top of the screen.
             b            Moves the widget to the bottom of the screen.
             l            Moves the widget to the left of the screen.
             r            Moves the widget to the right of the screen.
             c            Centers the widget between the left and
                          right of the window.
             C            Centers the widget between the top and
                          bottom of the window.
             Escape       Returns the widget to its original position.
             Return       Exits the function and leaves the widget
                          where it was.

             Keypad  means  that  if  the keyboard you are using has a keypad,
             then the Num-Lock light has to be on in order to use the keys  as
             listed. (The numeric keys at the top of the keyboard will work as
             well.)

             void drawCDKMarquee (CDKMARQUEE *marquee, boolean box);
                This function draws the marquee widget on the screen. The  box
                option draws the widget with or without a box.

             void eraseCDKMarquee (CDKMARQUEE *marquee);
                This  function  removes  the widget from the screen. This does
                NOT destroy the widget.

             void destroyCDKMarquee (CDKMARQUEE *marquee);
                This function removes the widget from the screen and frees  up
                any memory the object may be using.


SEE ALSO
       cdk(3), cdk_binding(3), cdk_display(3), cdk_screen(3)

NOTES
       The  header  file  &lt&lt;cdk.h&gt&gt;  automatically  includes  the  header  files
       &lt&lt;curses.h&gt&gt;, &lt&lt;stdlib.h&gt&gt;, &lt&lt;string.h&gt&gt;, &lt&lt;ctype.h&gt&gt;, &lt&lt;unistd.h&gt&gt;,  &lt&lt;dirent.h&gt&gt;,
       &lt&lt;time.h&gt&gt;, &lt&lt;errno.h&gt&gt;, &lt&lt;pwd.h&gt&gt;, &lt&lt;grp.h&gt&gt;, &lt&lt;sys/stat.h&gt&gt;, and &lt&lt;sys/types.h&gt&gt;.
       The &lt&lt;curses.h&gt&gt; header file includes &lt&lt;stdio.h&gt&gt; and &lt&lt;unctrl.h&gt&gt;.

       If you have Ncurses installed on your machine add -DNCURSES to the com-
       pile line to include the Ncurses header files instead.



                                 24 April 1997                  cdk_marquee(3)