Chinaunix首页 | 论坛 | 博客
  • 博客访问: 889473
  • 博文数量: 380
  • 博客积分: 3495
  • 博客等级: 中校
  • 技术积分: 3996
  • 用 户 组: 普通用户
  • 注册时间: 2007-12-02 09:35
文章分类

全部博文(380)

文章存档

2015年(2)

2014年(5)

2013年(9)

2012年(9)

2011年(67)

2010年(103)

2009年(182)

2008年(3)

我的朋友

分类: C/C++

2009-03-05 21:54:17

Gnome里管理各种GUI的大小变化,是Adjustment对象来处理 的。
基本上就是一个方法。
GtkObject *gtk_adjustment_new( gdouble value,
gdouble lower,
gdouble upper,
gdouble step_increment,
gdouble page_increment,
gdouble page_size );
不过这个方法生成的对象应用却是非常广泛,

Progress Bars, Viewports, Scrolled Windows

关联函数
得到,设定相应的值勤
gdouble	gtk_adjustment_get_value( GtkAdjustment *adjustment);
void gtk_adjustment_set_value( GtkAdjustment *adjustment,
gdouble value );
信号处理
void cb_rotate_picture (GtkAdjustment *adj, GtkWidget *picture)
{

set_picture_rotation (picture, gtk_adjustment_get_value (adj));

g_signal_connect (G_OBJECT (adj), "value_changed",
G_CALLBACK (cb_rotate_picture), (gpointer) picture);



阅读(574) | 评论(0) | 转发(0) |
0

上一篇:巷に溢れる

下一篇:Gnome学习7 Adjustment

给主人留下些什么吧!~~