linux gtk+基础编程源代码

源代码在线查看: table.c

软件大小: 28 K
上传用户: liu2000dz
关键词: linux gtk 编程 源代码
下载地址: 免注册下载 普通下载 VIP

相关代码

				#include				int main(int argc, char *argv[])				{					GtkWidget *window;					GtkWidget *table;					GtkWidget *button;										gtk_init(&argc, &argv);					window=gtk_window_new(GTK_WINDOW_TOPLEVEL);					gtk_signal_connect(GTK_OBJECT(window),"destroy",G_CALLBACK(gtk_main_quit),NULL);					table=gtk_table_new(4,4,FALSE);					button=gtk_button_new_with_label("button1");					gtk_table_attach(GTK_TABLE(table),button,0,1,0,1,GTK_EXPAND,GTK_EXPAND,0,0);					gtk_widget_show(button);					button=gtk_button_new_with_label("button2");					gtk_table_attach(GTK_TABLE(table),button,1,2,1,2,GTK_EXPAND,GTK_EXPAND,0,0);					gtk_widget_show(button);					button=gtk_button_new_with_label("button3");					gtk_table_attach(GTK_TABLE(table),button,2,3,2,3,GTK_EXPAND,GTK_EXPAND,0,0);					gtk_widget_show(button);									gtk_container_add(GTK_CONTAINER(window),table);					gtk_widget_show(table);					gtk_widget_show(window);					gtk_main();					return FALSE;				}							

相关资源