GtkLabel
GtkObject<br> `-- GtkWidget<br> `-- GtkMisc<br> `-- GtkLabel<br>Object Properties and Methods
Constructor
构造器
Object GtkLabel (char labelstring);
Constructs a GtkLabel.
构造一个标签
Methods
void set_text (char labeltext);
-- Writes text to the label.
向标签写文本
void set_justify (int justify);
-- Justify method.
对齐方式
void set_pattern (char pattern);
-- Underline method.
设置下划线
void set_line_wrap (bool linewrap);
-- Linewrap toggle switch.
切换行回绕
char get()
-- Method for harvesting current text content of label.
void parse_uline (char text_to_be_parsed);
-- Accelerator key definition method.
定义方法的快捷键
Properties<br>None - Not Directly Accessible.
Signals<br>None - Not Directly Accessible.
Detailed Description
GtkLabel is a widget for displaying a small amount of text. If you need to display a great deal of text, use GtkText instead.
用于显示少量文字的部件,如果量很大,用 GtkText 部件代替
Labels do not emit signals. If you want to catch signals (e.g. from a button click) you will need to put it in a GtkEventBox.
标签不能带信号,如果你想携带信号(如按钮点击),你需要把它放到 GtkEvenBox 里面
Methods
void set_text (char labeltext);
set_text is not needed when first creating a label; this method is only useful for replacing the text of the label later, eg. to report a server connection status or to reflect user input.
设置标签在创建的时候是不必要的。这个方法用来在以后更改标签的文本用的。用于报告服务器连接状态或反映用户输入。
$label->set_text("Whatever you wish to pass");<br> <br>This could also be passed as a reference to a string, e.g. <br>$label->set_text($pass_stuff);
void set_justify (int justify);
This is the method for justifying text in GtkLabel. The options are pre-set enum flags, giving the choices of:
设置 标签的对齐方式,参数是预设的枚举标志
GTK_JUSTIFY_LEFT, <br>GTK_JUSTIFY_RIGHT, <br>GTK_JUSTIFY_CENTER, <br>GTK_JUSTIFY_FILL.
$label->set_justify(GTK_JUSTIFY_LEFT);
void set_pattern (char pattern);
This is the method for underlining text in GtkLabel. It needs to be defined as a pattern, eg if your text consists of "Apple Banana Carrot", then "__ __" will underline Apple and Carrot but not Banana, as that is where the space falls.
用于标签的下划线。需要定义一个规范,如果你的标签为 "Apple Banana Carrot", 那么 "__ __"将给前后2个做下划线
$label->set_pattern("__ __");
void set_line_wrap (bool linewrap);
Boolean switch between linewrap on and linewrap off, with TRUE being linewrap on.
设置行回绕状态
$label->set_line_wrap(TRUE);
char get()
Returns the current text content of the label.
返回当前的标签文本
$label->get();
void parse_uline (char text_to_be_parsed);
This method checks the text for underscores, and then underlines the character following the underscore. It will take the last underlined character in a label and return it as a lower-case accelerator key, e.g. "_Save" will return the accelerator key value for "s".
检查下划线状态,返回下划线下一个字母的小写作为快捷键。
$label->parse_uline("_File");
Properties<br>None - Not Directly Accessible.
Signals<br>None - Not Directly Accessible.
|
kehui
|
|
智慧家居
智慧家居颠覆传统智能家居
智慧云谷让智能家居变成有智慧的
智慧云谷引领智慧家居新生活
科技改变生活 智慧云谷智慧家居系
智慧家居领航者,智慧云谷助你玩
智能家居如何赢得市场美誉度?
智慧云谷智慧家居:创业者有无限
WiFi智能家居你还在用?这样的智
互联网+助推智能家居产业
智慧云谷为您打造真正的智能家居
智能家居产业需要的不是单品,而
新家如何选择开关?智慧云谷iWis
智能传感器-世界首款“智”为你的
智慧云谷开关智能安防智能空气质
智能开关品牌,如何选择智能开关
秋季干燥,智慧家居温湿度传感器
传感器助力智慧家居 感知爱家
iWiscloud智能触摸开关缔造家居装
※室内空气污染的危害及 [sensor]
※超声波风速传感器在生 [sensor]
※这么冷清 [gabc111]
※手机APP操作有问题 [ssy11407]
※智慧云谷智慧家居将在 [cici]
※上传下载 [cici]
※下载智慧家居 [apple2008]
※秋季干燥,智慧家居温 [apple2008]
※智慧家居紧扣热点 安全 [apple2008]
※办公大楼如何智慧化管 [apple2008]
※智慧云谷工业自控的优 [apple2008]
※传感器助力智慧家居 感 [apple2008]
※智能开关品牌,如何选 [apple2008]
※智慧云谷开关智能安防 [apple2008]
※没有专业人员,如何安 [apple2008]
※烟台智慧云谷董事长任 [apple2008]
※互联网+助推智能家居产 [apple2008]
※WiFi智能家居你还在用 [apple2008]
※智慧云谷智慧家居:创 [apple2008]
※智能家居如何赢得市场 [apple2008]
|