1、GTK+? (Gtkmm)
GTK+基礎(chǔ)
GTK+最初是GIMP的專用開發(fā)庫,后來發(fā)展為Linux下開發(fā)圖形界面的應(yīng)用程序的主流開發(fā)工具之一。GTK+2.0是自由軟件,并且是GNU工程的一部分。GTK+2.0的許可協(xié)議是LGPL。
GTK+使用C語言開發(fā),但是其設(shè)計(jì)者使用面向?qū)ο蠹夹g(shù)。 在GNOME平臺(tái)上提供了C++(gtkmm)、Perl、Ruby、Java和Python(PyGTK)綁定,其他的綁定有Ada、 D、 Haskell、PHP和所有的.NET編程語言。
與其他很多部件工具箱不同,GTK+并不基于Xt。這一決策優(yōu)劣互見:優(yōu)點(diǎn)是GTK+可以應(yīng)用于其他系統(tǒng),其靈活性也很強(qiáng);而缺點(diǎn)就是它無法利用以傳統(tǒng)方法為X11定制的X資源數(shù)據(jù)庫。
Glade是一個(gè)界面設(shè)計(jì)工具,但是它也包含了一種描述GUI界面的XML語言,它和libglade一起工作就可以直接使用GTK和GNOME控件。
2、Qt
Qt簡介
Qt是Trolltech公司的一個(gè)產(chǎn)品。
Qt是一個(gè)多平臺(tái)的C++圖形用戶界面應(yīng)用程序框架。它提供給應(yīng)用程序開發(fā)者建立藝術(shù)級(jí)的圖形用戶界面所需的所用功能。Qt是完全面向?qū)ο蟮暮苋菀讛U(kuò)展,并且 允許真正地組件編程。
自從1996年早些時(shí)候,Qt進(jìn)入商業(yè)領(lǐng)域,它已經(jīng)成為全世界范圍內(nèi)數(shù)千種成功的應(yīng)用 程序的基礎(chǔ)。Qt也是流行的Linux桌面環(huán)境KDE 的基礎(chǔ),KDE是所有主要的Linux發(fā)行版的一個(gè)標(biāo)準(zhǔn)組件。
Qt支持下述平臺(tái): MS/Windows - 95、98、NT 4.0、ME、和2000
Unix/X11 - Linux、Sun Solaris、HP-UX、Compaq Tru64 UNIX、IBM AIX、SGI IRIX和其它很多X11平臺(tái)
Macintosh - Mac OS X
Embedded - 有幀緩沖(framebuffer)支持的Linux平臺(tái)。
3、wxWidgets
開源軟件(LGPL),針對(duì)C++、Python以及Perl的跨平臺(tái)工具集。
詳細(xì)介紹,參見細(xì)述 wxWindows
wxWidget作為一個(gè)C++ GUI Library從1992發(fā)展到現(xiàn)在,已經(jīng)在全球范圍內(nèi)產(chǎn)生了極大的影響力,利用這個(gè)類庫進(jìn)行GUI開發(fā)的軟件更是不計(jì)其數(shù)。
wxWidgets原名wxWindows,是由Julian Smart于1992年還在英國愛丁堡大學(xué)人工智能應(yīng)用研究所開始的一個(gè)項(xiàng)目。Julian Smart現(xiàn)在是Anthemion軟件公司的技術(shù)總監(jiān)。
簡單地說,wxWidgets提供了用于可在多平臺(tái)上開發(fā)GUI應(yīng)用程序的一整套簡單易學(xué)易用的API。wxWidgets支持的多平臺(tái)包括
Windows 3.1/95/98/NT/2000/XP、帶有Motif
1.2版本以上的Unix、帶有GTK+的Unix/Linux/*BSD、Mac等等。開發(fā)者只需要用自己使用的系統(tǒng)平臺(tái)的編譯器編譯源程序,并鏈接上
相應(yīng)的庫文件,生成的程序代碼即具有該平臺(tái)的外觀和界面。在這些GUI之上,wxWidgets還提供了在線幫助、網(wǎng)絡(luò)編程、流處理、多種常用圖形格式支
持、數(shù)據(jù)庫支持、HTML察看和打印,等等各種強(qiáng)大的功能。
wxWidgets支持的Windows上的多種流行編譯器包括:
Visual C++ 1.5, 4.0, 5.0, 6.0
Borland C++ 4.5, 5.0
Borland C++ Builder 1.0, 3.0
Watcom C++ 10.6 (Win32)
Cygwin
MinGW32
Metrowerks CodeWarrior 4
4、Fox
What is FOX?
FOX is a C++ based Toolkit for developing Graphical User Interfaces easily and
effectively. It offers a wide, and growing, collection of Controls, and provides
state of the art facilities such as drag and drop, selection, as well as OpenGL
widgets for 3D graphical manipulation. FOX also implements icons, images, and
user-convenience features such as status line help, and tooltips.
Tooltips may even be used for 3D objects!
Considerable importance has been placed on making FOX one of the fastest
toolkits around, and to minimize memory use:- FOX uses a number of techniques
to speed up drawing and spatial layout of the GUI. Memory is conserved by
allowing programmers to create and destroy GUI elements on the fly.
Even though FOX offers a large collection of Controls already, FOX leverages C++
to allow programmers to easily build additional Controls and GUI elements,
simply by taking existing controls, and creating a derived class which simply
adds or redefines the desired behavior.
One of the prime design goals of FOX is the ease of programming; thus, most
controls can be created using a single line of C++ code; most parameters have
sensible default values, so that they may be omitted, and layout managers ensure
that designers of GUI's do not have to worry about precise alignments.
Another nice feature of FOX which significantly reduces the number of lines of
code which have to be written is FOX's ability to have widgets connect to each
other, and passing certain commands between them; for example, a menu entry Hide
Toolbar can be directly connected to the Toolbar, and cause it to hide.
Finally, FOX makes it easy to maintain the state of the GUI in an application
by having the GUI elements automatically updating themselves by interrogating
the application's state. This feature eliminates the large amount of effort that
may go into sensitizing, graying out, checking/unchecking etc. depending on
the application state.
FOX is Platform Independence!
|
The list of platforms is growing! Currently, we have FOX
running on a large number of operating systems, ranging from Linux,
FreeBSD, SGI IRIX, HP-UX, IBM AIX, SUN Solaris, DEC/Compaq Tru64 UNIX,
to MS-Window operating systems like Windows 9x, Windows NT, Windows ME
and Windows 2000. Since most of the FOX implementation is completely
oblivious to the underlying platform (in many cases it is not even
including header files), applications work virtually identically on all
these platforms.
For example, here is the FOX textedit sample application running under Windows NT.? And here is the same application running on a Silicon
GraphicsOctane system.
個(gè)人比較喜歡Gtkmm,代碼比較干凈,只有GUI,但在Windows下的效果似乎沒有原生的Window控件好
Features
- Use inheritance to derive custom widgets.
- Type-safe signal handlers, in standard C++.
- Polymorphism.
- Use of Standard C++ Library, including strings, containers, and iterators.
- Full internationalisation with UTF8.
- Complete C++ memory management
- Object composition
- Automatic deallocation of dynamically allocated widgets.
- Full use of C++ namespaces.
- No macros.
- Cross-platform:
Linux (gcc), FreeBSD (gcc), NetBSD (gcc), Solaris (gcc, Forte), Win32
(gcc, MSVC++ .Net 2003), MacOS X (gcc), others
- Free software and free of cost for both Open Source and
proprietary development.
- Discussed, designed and implemented in public.