Skip to content

Latest commit

 

History

History
188 lines (104 loc) · 12.6 KB

File metadata and controls

188 lines (104 loc) · 12.6 KB

Checkbox

Category Requires Version
User Interface API 21, Android 5.0 Lollipop 6

Overview

Checkbox that raises an event when the user clicks on it. There are many properties affecting its appearance that can be set in the Designer or Blocks Editor.

Events

Changed

Default Changed event handler.

Click

Indicates a user has clicked on the checkbox.

Got Focus

Default GotFocus event handler.

Lost Focus

Default LostFocus event handler.

Methods

Set Shadow

Place a blurred shadow of text underneath the text, drawn with the specified x, y, radius, color (e.g. -11, 12, 13, black

Params
x Number
y Number
radius Number
color Number

Properties

Background Color

Color Default: #FFFFFF00 Read Write - Designer Blocks

Returns the checkbox's background color as an alpha-red-green-blueinteger.

Checkbox Color

Color Default: #000000FF Read Write - Designer Blocks

Change the checkbox component color.

Checked

Boolean Default: FalseRead Write - Designer Blocks

Returns true if the checkbox is checked.

Enabled

Boolean Default: TrueRead Write - Designer Blocks

Returns true if the checkbox is active and clickable.

Font Bold

Boolean Default: FalseWrite - Designer

Returns true if the checkbox's text should be bold
If bold has been requested, this property will return true, even if thefont does not support bold.

Font Italic

Boolean Default: FalseWrite - Designer

Returns true if the checkbox's text should be italic
If italic has been requested, this property will return true, even if thefont does not support italic.

Font Size

Number Default: 14.0Read Write - Designer Blocks

Returns the checkbox's text's font size, measured in sp(scale-independent pixels).

Font Typeface

Number Default: 0Write - Designer

Returns the checkbox's text's font face as default, serif, sansserif, or monospace.

Font Typeface Import

Available as ^^Advanced^^ Property

TextWrite - Designer Blocks

Set a custom font.

Height

NumberRead Write - Blocks

Specifies the component's vertical height, measured in pixels.

Height Percent

NumberWrite - Blocks

Specifies the component's vertical height as a percentageof the height of its parent Component.

Text

TextRead Write - Designer Blocks

Returns the text displayed by the checkbox.

Text Color

Color Default: #000000FF Read Write - Designer Blocks

Returns the checkbox's text color as an alpha-red-green-blueinteger.

Visible

Boolean Default: TrueRead Write - Designer Blocks

Returns true iff the component is visible.

Width

NumberRead Write - Blocks

Specifies the component's horizontal width, measured in pixels.

Width Percent

NumberWrite - Blocks

Specifies the component's horizontal width as a percentageof the Width of its parent Component.