CommonCtrl.CheckBox

a CheckBox control using a button and a text;

Title a CheckBox control using a button and a text;
Author(s) SunLingfeng, LiXizhi
Date  
File script/ide/CheckBox.lua

Description

TIP Sample Code

NPL.load("(gl)script/ide/CheckBox.lua");
local ctl = CommonCtrl.checkbox:new{
   name = "checkbox1",
   alignment = "_lt",
   left = 0,
   top = 0,
   width = 150,
   height = 26,
   parent = nil,
   isChecked = false,
   text = "check box",
};
ctl:Show();

Member Functions

checkbox:GetCheck

get the isChecked property

syntax

function checkbox:GetCheck()

checkbox:SetCheck

set the check property

syntax

function checkbox:SetCheck(bChecked)

parameters

bChecked  

checkbox:SetText

set the text property

syntax

function checkbox:SetText(text)

parameters

text  

checkbox.OnCheck

called when the check button is pressed.

syntax

function checkbox.OnCheck(ctrName)

parameters

ctrName  


This topic: Main > NPL > CheckBox
Topic revision: r1 - 2008-02-29 - LiXizhi
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2024 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback