xHarbour Reference Documentation > Class Reference (textmode) xHarbour Developers Network  

HbPushButton()

Creates a new HbPushButton object.

Syntax

HbPushButton():new( <nRow>, <nCol>, [<cCaption>] ) --> oHbPushButton

Arguments

<nRow>
This is the numeric row coordinate on the screen where the HbPushButton object is displayed. <nRow> is assigned to oPushButton:row.
<nCol>
This is the numeric column coordinate on the screen where the HbPushButton object is displayed. <nCol> is assigned to oHbPushButton:col.
<cCaption>
This is an optional character string holding the caption of the push button. <cCaption> is assigned to oHbPushButton:caption.

Return

Function HbPushButton() returns a new HbPushButton object and method :new() initializes the object.

Description

Objects of the HbpushButton class are used in text mode applications to display a push button. They are designed to be integrated into the standard Get system and are usually created with the @...GET PUSHBUTTON command. This command creates a Get() object and an associated HbPushButton object. A push button can then be activated along with other Get object by the READ command.

Instance variables

:buffer
Logical edit buffer indicating the pressed/released state.
:caption
Character string defining the caption.
:cargo
Instance variable for user-defined purposes.
:col
Numeric column position of the HbPushButton object.
:colorSpec
Color string for displaying a push button.
:fBlock
Code block evaluated when input focus changes.
:hasFocus
Indicates if the HbPushButton object has input focus.
:message
Character string to be displayed as message when the push button receives input focus.
:row
Numeric row position of the HbRadioButton object.
:sBlock
Code block evaluated when the pressed/released state changes.
:style
Character string defining the push button delimiters.
:typeOut
Logical value .F. (false).

Methods

:display() --> self
Displays the push button on the screen.
:hitTest( <nMouseRow>, <nMouseCol> ) --> nHitCode
Tests if a push button is hit by the mouse cursor.
:killFocus() --> self
Removes input focus from the HbPushButton object.
:select( [<nKey>] ) --> self
Activates a push button.
:setFocus() --> self
Gives input focus to the HbPushButton object.

Info

See also:@...GET, @...GET PUSHBUTTON, Get(), READ, ReadModal(), ReadVar(), Valtype(), SetColor()
Category: Object functions , Get system
Source:rtl\pushbtn.prg
LIB:lib\xhb.lib
DLL:dll\xhbdll.dll


Copyright © 2006-2007 xHarbour.com Inc. All rights reserved.
http://www.xHarbour.com
Created by docmaker.exe