xHarbour Reference Documentation > Class Reference (textmode) |
|
|
HbRadioButton()
Creates a new HRadioButton object.
Syntax
HbRadioButton():new( <nRow> , ;
<nCol> , ;
[<cCaption>], ;
[<xValue> ) --> oHbRadioButton
Arguments
- <nRow>
- This is the numeric row coordinate on the screen where the HbRadioButton object
is displayed. <nRow> is assigned to oRadioButton:row.
- <nCol>
- This is the numeric column coordinate on the screen where the HbRadioButton object
is displayed. <nCol> is assigned to oHbRadioButton:col.
- <cCaption>
- This is an optional character string holding the caption of the radio button.
<cCaption> is assigned to oHbRadioButton:caption.
- <xValue>
- This is an optional value of any data type to associate with the radio button object.
Return
Function HbRadioButton() returns a new HbRadioButton object and method :new() initializes
the object.
Description
Objects of the HbRadioButton class are used in text mode applications to display
and edit a single state from multiple options. A single HbRadioButton object maintains
a single state. Radio buttons must be added to a HbRadioGroup() object, which maintains
multipe radio buttons. Both classes are designed to be integrated into
the standard Get system and are usually created with the @...GET RADIOGROUP
command. This command creates a Get() object and an associated HbRadioGroup
object. Editing the edit buffer of the radio button group is then accomplished by the
READ command.
Instance variables
- :buffer
- Logical edit buffer indicating the (un)selected state.
- :caption
- Character string defining the caption.
- :capCol
- Numeric column position of the caption.
- :capRow
- Numeric row position of the caption.
- :cargo
- Instance variable for user-defined purposes.
- :col
- Numeric column position of the HbRadioButton object.
- :colorSpec
- Color string for display and selecting.
- :fBlock
- Code block evaluated when input focus changes.
- :hasFocus
- Indicates if the HbRadioButton object has input focus.
- :row
- Numeric row position of the HbRadioButton object.
- :sBlock
- Code block evaluated when the (un)selected state changes.
- :style
- Character string defining the radio button delimiters.
Methods
- :display() --> self
- Displays the radio button on the screen.
- :hitTest( <nMouseRow>, <nMouseCol> ) --> nHitCode
- Tests if a radio button is hit by the mouse cursor.
- :isAccel( <nKey>|<cChr> ) --> lIsAccelerator
- Checks if an accelerator key is pressed.
- :killFocus() --> self
- Removes input focus from the HbRadioButton object.
- :select( [<lSelected>] ) --> self
- Toggles or defines the (un)cheked state.
- :setFocus() --> self
- Gives input focus to the HbRadioButton object.
Info
Copyright © 2006-2007 xHarbour.com Inc. All rights reserved.
http://www.xHarbour.com
Created by docmaker.exe