Chinaunix首页 | 论坛 | 博客
  • 博客访问: 34780
  • 博文数量: 23
  • 博客积分: 1415
  • 博客等级: 上尉
  • 技术积分: 235
  • 用 户 组: 普通用户
  • 注册时间: 2009-02-20 09:41
文章分类
文章存档

2011年(1)

2010年(2)

2009年(20)

我的朋友

分类: C/C++

2009-09-02 05:44:59

First time to learn about GUI programming with QT4.

The QT modules:
QtCore
QtGUI
QtXML
QtSVG
QtOpenGL
QtNetWork

OBjects in QT:
QApplication: .exec() begin the main loop.

Widgets:
GDialog: setTitle
GPushButton: clicked()
GCheckBox
GLabel
GLineEdit
GSlider
GSpinBox

Layout:
QHBoxLayout
QVBoxLayout
QGridLayout
methods for layout:
addWidget
addLayout
addStrech

Q_OBJECT: QT MACRO SYSTEM, object, tr(), slots, signals ...
new object have slots and signals

connect(object1, SIGNAL(clicked(parameters 1)), object2, SLOT(clickedfun(parameters 2)))
the number of parameters1 must equal to parameters2
and the clickedfun must declared under the region of slots
and the function of slots could emit the a function which is declared in signals region.

and the install of QT building system under freebsd, actually I dont know how it works, I failed when using qmake, but it works when using qdevelop. it seems the QTDIR, QTSPECIFIC ... are not set correctly in my system. but left this question for later.

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

上一篇:const in c

下一篇:vi 使用

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