listing_7_04.c
来自「This source code has been tested under O」· C语言 代码 · 共 38 行
C
38 行
/************************************************************************* **** listing_7_4.c **** **** Toggle buttons and Row-Column. This program demonstrates the **** appearance and interaction of XmToggleButton, both as a check **** box and as a radio button. **** *************************************************************************/#include <Xm/RowColumn.h>#include <Xm/ToggleB.h>Widget appshell, /* Application Shell */ row_col, /* The parent */ buttons[3]; /* The Toggle Buttons */void main( argc, argv ) int argc; char *argv[];{ appshell = XtInitialize( argv[0], "Listing_7_04", NULL, 0, &argc, argv ); row_col = XmCreateRowColumn( appshell, "RowCol", NULL, 0 ); XtManageChild( row_col ); buttons[0] = XmCreateToggleButton( row_col, "Btn_0", NULL, 0 ); buttons[1] = XmCreateToggleButton( row_col, "Btn_1", NULL, 0 ); buttons[2] = XmCreateToggleButton( row_col, "Btn_2", NULL, 0 ); XtManageChildren( buttons, 3 ); XtRealizeWidget( appshell ); XtMainLoop();}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?