Class: Newt::Textbox
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from Widget
#==, #callback, #takesFocus
Class Method Details
.new(left, top, width, height, flags) ⇒ Object
779
780
781
782
783
784
785
|
# File 'ext/ruby_newt/ruby_newt.c', line 779
static VALUE rb_ext_Textbox_new(VALUE self, VALUE left, VALUE top, VALUE width, VALUE height, VALUE flags)
{
newtComponent co;
co = newtTextbox(NUM2INT(left), NUM2INT(top), NUM2INT(width), NUM2INT(height), NUM2INT(flags));
return Data_Wrap_Struct(self, 0, 0, co);
}
|
Instance Method Details
#get_num_lines ⇒ Object
805
806
807
808
809
810
811
|
# File 'ext/ruby_newt/ruby_newt.c', line 805
static VALUE rb_ext_Textbox_GetNumLines(VALUE self)
{
newtComponent co;
Data_Get_Struct(self, struct newtComponent_struct, co);
return INT2NUM(newtTextboxGetNumLines(co));
}
|
#set_height(height) ⇒ Object
796
797
798
799
800
801
802
803
|
# File 'ext/ruby_newt/ruby_newt.c', line 796
static VALUE rb_ext_Textbox_SetHeight(VALUE self, VALUE height)
{
newtComponent co;
Data_Get_Struct(self, struct newtComponent_struct, co);
newtTextboxSetHeight(co, NUM2INT(height));
return Qnil;
}
|
#set_text(text) ⇒ Object
787
788
789
790
791
792
793
794
|
# File 'ext/ruby_newt/ruby_newt.c', line 787
static VALUE rb_ext_Textbox_SetText(VALUE self, VALUE text)
{
newtComponent co;
Data_Get_Struct(self, struct newtComponent_struct, co);
newtTextboxSetText(co, StringValuePtr(text));
return Qnil;
}
|