1 Qt 3.0 adds a lot of new features and improvements over the Qt 2.x
2 series. Some internals have undergone major redesign and new classes
3 and methods have been added.
5 We have tried to keep the API of Qt 3.0 as compatible as possible with
6 the Qt 2.x series. For most applications only minor changes will be
7 needed to compile and run them successfully using Qt 3.0.
9 One of the major new features that has been added in the 3.0 release
10 is a module allowing you to easily work with databases. The API is
11 platform independent and database neutral. This module is seamlessly
12 integrated into Qt Designer, greatly simplifying the process of
13 building database applications and using data aware widgets.
15 Other major new features include a component architecture allowing you
16 to build cross platform components, 'plugins' with Qt. You can use
17 your own and third party plugins your own applications. The Unicode
18 support of Qt 2.x has been greatly enhanced, it now includes full
19 support for scripts written from right to left (e.g. Arabic and
20 Hebrew) and also provides improved support for Asian languages.
22 Many new classes have been added to the Qt Library. Amongst them are
23 classes that provide a docking architecture (QDockArea/QDockWindow), a
24 powerful rich text editor (QTextEdit), a class to store and access
25 application settings (QSettings) and a class to create and communicate
26 with processes (QProcess).
28 Apart from the changes in the library itself a lot has been done to
29 make the development of Qt applications with Qt 3.0 even easier than
30 before. Two new applications have been added: Qt Linguist is a tool to
31 help you translate your application into different languages; Qt
32 Assistant is an easy to use help browser for the Qt documentation that
33 supports bookmarks and can search by keyword.
35 Another change concerns the Qt build system, which has been reworked
36 to make it a lot easier to port Qt to new platforms. You can use this
37 platform independent build system for your own applications.
41 ========================================
43 A large number of new features has been added to Qt 3.0. The following
44 list gives an overview of the most important new and changed aspects
45 of the Qt library. A full list of every new method follows the
52 One of the major new features in Qt 3.0 is the SQL module that
53 provides cross-platform access to SQL databases, making database
54 application programming with Qt seamless and portable. The API, built
55 with standard SQL, is database-neutral and software development is
56 independent of the underlying database.
58 A collection of tightly focused C++ classes are provided to give the
59 programmer direct access to SQL databases. Developers can send raw SQL
60 to the database server or have the Qt SQL classes generate SQL queries
61 automatically. Drivers for Oracle, PostgreSQL, MySQL and ODBC are
62 available and writing new drivers is straightforward.
64 Tying the results of SQL queries to GUI components is fully supported
65 by Qt's SQL widgets. These classes include a tabular data widget
66 (for spreadsheet-like data presentation with in-place editing), a
67 form-based data browser (which provides data navigation and edit
68 functions) and a form-based data viewer (which provides read-only
69 forms). This framework can be extended by using custom field editors,
70 allowing for example, a data table to use custom widgets for in-place
71 editing. The SQL module fully supports Qt's signal/slots mechanism,
72 making it easy for developers to include their own data validation and
75 Qt Designer fully supports Qt's SQL module. All SQL widgets can be
76 laid out within Qt Designer, and relationships can be established
77 between controls visually. Many interactions can be defined purely in
78 terms of Qt's signals/slots mechanism directly in Qt Designer.
81 Component model - plugins
82 -------------------------
84 The QLibrary class provides a platform independent wrapper for runtime
85 loading of shared libraries. Access to the shared libraries uses a
86 COM-like interface. QPluginManager makes it trivial to implement
87 plugin support in applications. The Qt library is able to load
88 additional styles, database drivers and text codecs from plugins which
89 implement the relevant interfaces, e.g. QStyleFactoryInterface,
90 QSqlDriverInterface or QTextCodecInterface. It is possible to remove
91 unused components from the Qt library, and easy to extend any
92 application with 3rd party styles, database drivers or text codecs.
94 Qt Designer supports custom widgets in plugins, and will use the
95 widgets both when designing and previewing forms.
97 QComponentFactory makes it easy to register any kind of component in a
98 global database (e.g. the Windows Registry) and to use any registered
102 Rich text engine and editor
103 ---------------------------
105 The rich text engine originally introduced in Qt 2.0 has been further
106 optimized and extended to support editing. It allows editing formatted
107 text with different fonts, colors, paragraph styles, tables and
108 images. The editor supports different word wrap modes, command-based
109 undo/redo, multiple selections, drag and drop, and many other
110 features. The engine is highly optimized for proccesing and displaying
111 large documents quickly and efficiently.
117 Apart from the rich text engine, another new feature of Qt 3.0 that
118 relates to text handling is the greatly improved Unicode support. Qt
119 3.0 includes an implementation of the bidirectional algorithm (BiDi)
120 as defined in the Unicode standard and a shaping engine for Arabic,
121 which gives full native language support to Arabic and Hebrew speaking
122 people. At the same time the support for Asian languages has been
125 The support is almost transparent for the developer using Qt to
126 develop their applications. This means that developers who developed
127 applications using Qt 2.x will automatically gain the full support for
128 these languages when switching to Qt 3.0. Developers can rely on their
129 application to work for people using writing systems different from
130 Latin1, without having to worry about the complexities involved with
131 these scripts, as Qt takes care of this automatically.
134 Docked and Floating Windows
135 ---------------------------
137 Qt 3.0 introduces the concept of Dock Windows and Dock Areas. Dock
138 windows are widgets, that can be attached to, and detached from, dock
139 areas. The commonest kind of dock window is a tool bar. Any number of
140 dock windows may be placed in a dock area. A main window can have dock
141 areas, for example, QMainWindow provides four dock areas (top, left,
142 bottom, right) by default. The user can freely move dock windows and
143 place them at a convenient place in a dock area, or drag them out of
144 the application and have them float freely as top level windows in
145 their own right. Dock windows can also be minimized or hidden.
147 For developers, dock windows behave just like ordinary widgets. QToolbar
148 for example is now a specialized subclass of a dock window. The API
149 of QMainWindow and QToolBar is source compatible with Qt 2.x, so
150 existing code which uses these classes will continue to work.
156 Qt has always provided regular expression support, but that support
157 was pretty much limited to what was required in common GUI control
158 elements such as file dialogs. Qt 3.0 introduces a new regular
159 expression engine that supports most of Perl's regex features and is
160 Unicode based. The most useful additions are support for parentheses
161 (capturing and non-capturing) and backreferences.
164 Storing application settings
165 ----------------------------
167 Most programs will need to store some settings between runs, for
168 example, user selected fonts, colors and other preferences, or a list
169 of recently used files. The new QSettings class provides a platform
170 independent way to achieve this goal. The API makes it easy to store
171 and retrieve most of the basic data types used in Qt (such as basic
172 C++ types, strings, lists, colors, etc). The class uses the registry
173 on the Windows platform and traditional resource files on Unix.
176 Creating and controlling other processes
177 ----------------------------------------
179 QProcess is a class that allows you to start other programs from
180 within a Qt application in a platform independent manner. It gives you
181 full control over the started program, for example you can redirect
182 the input and output of console applications.
185 Accessibility (not part of the beta1 release)
186 ---------------------------------------------
188 Accessibility means making software usable and accessible to a wide
189 range of users, including those with disabilities. In Qt 3.0, most
190 widgets provide accessibility information for assistive tools that can
191 be used by a wide range of disabled users. Qt standard widgets like
192 buttons or range controls are fully supported. Support for complex
193 widgets, like e.g. QListView, is in development. Existing applications
194 that make use of standard widgets will become accessible just by using
197 Qt uses the Active Accessibility infrastructure on Windows, and needs
198 the MSAA SDK, which is part of most platform SDKs. With improving
199 standardization of accessibility on other platforms, Qt will support
200 assistive technologies on other systems, too.
202 The accessibility API in Qt is not yet stable, which is why we decided
203 not to make it a part of the beta1 release.
209 The XML framework introduced in Qt 2.2 has been vastly improved. Qt
210 2.2 already supported level 1 of the Document Object Model (DOM), a
211 W3C standard for accessing and modifying XML documents. Qt 3.0 has
212 added support for DOM Level 2 and XML namespaces.
214 The XML parser has been extended to allow incremental parsing of XML
215 documents. This allows you to start parsing the document directly
216 after the first parts of the data have arrived, and to continue
217 whenever new data is available. This is especially useful if the XML
218 document is read from a slow source, e.g. over the network, as it
219 allows the application to start working on the data at a very early
226 SVG is a W3C standard for "Scalable Vector Graphics". Qt 3.0's SVG
227 support means that QPicture can optionally generate and import static
228 SVG documents. All the SVG features that have an equivalent in
229 QPainter are supported.
235 Many professional applications, such as DTP and CAD software, are able
236 to display data on two or more monitors. In Qt 3.0 the QDesktopWidget
237 class provides the application with runtime information about the
238 number and geometry of the desktops on the different monitors and such
239 allows applications to efficiently use a multi-monitor setup.
241 The virtual desktop of Windows 98 and 2000 is supported, as well as
242 the traditional multi-screen and the newer Xinerama multihead setups
246 X11 specific enhancements
247 -------------------------
249 Qt 3.0 now complies with the NET WM Specification, recently adopted
250 by KDE 2.0. This allows easy integration and proper execution with
251 desktop environments that support the NET WM specification.
253 The font handling on X11 has undergone major changes. QFont no longer
254 has a one-to-one relation with window system fonts. QFont is now a
255 logical font that can load multiple window system fonts to simplify
256 Unicode text display. This completely removes the burden of
257 changing/setting fonts for a specific locale/language from the
258 programmer. For end-users, any font can be used in any locale. For
259 example, a user in Norway will be able to see Korean text without
260 having to set their locale to Korean.
262 Qt 3.0 also supports the new render extension recently added to
263 XFree86. This adds support for anti aliased text and pixmaps with
264 alpha channel (semi transparency) on the systems that support the
265 rendering extension (at the moment XFree 4.0.3 and later).
271 Printing support has been enhanced on all platforms. The QPrinter
272 class now supports setting a virtual resolution for the painting
273 process. This makes WYSIWYG printing trivial, and also allows you to
274 take full advantage of the high resolution of a printer when painting
277 The postscript driver built into Qt and used on Unix has been greatly
278 enhanced. It supports the embedding of true/open type and type1 fonts
279 into the document, and can correctly handle and display Unicode.
280 Support for fonts built into the printer has been enhanced and Qt now
281 knows about the most common printer fonts used for Asian languages.
287 This class provides a simple interface for HTTP downloads and uploads.
290 Compatibility with the Standard Template Library (STL)
291 ------------------------------------------------------
293 Support for the C++ Standard Template Library has been added to the Qt
294 Template Library (QTL). The QTL classes now contain appropriate copy
295 constructors and typedefs so that they can be freely mixed with other
296 STL containers and algorithms. In addition, new member functions have
297 been added to QTL template classes which correspond to STL-style
298 naming conventions (e.g., push_back()).
302 ========================================
304 Qt Designer was a pure dialog editor in Qt 2.2 but has now been
305 extended to provide the full functionality of a GUI design tool.
307 This includes the ability to lay out main windows with menus and
308 toolbars. Actions can be edited within Qt Designer and then plugged
309 into toolbars and menu bars via drag and drop. Splitters can now be
310 used in a way similar to layouts to group widgets horizontally or
313 In Qt 2.2, many of the dialogs created by Qt Designer had to be
314 subclassed to implement functionality beyond the predefined signal and
315 slot connections. Whilst the subclassing approach is still fully supported,
316 Qt Designer now offers an alternative: a plugin for editing
317 slots. The editor offers features such as syntax highlighting,
318 completion, parentheses matching and incremental search.
320 The functionality of Qt Designer can now be extended via plugins.
321 Using Qt Designer's interface or by implementing one of the provided
322 interfaces in a plugin, a two way communication between plugin and Qt
323 Designer can be established. This functionality is used to implement
324 plugins for custom widgets, so that they can be used as real widgets
327 Basic support for project management has been added. This allows you
328 to read and edit *.pro files, add and remove files to/from the project
329 and do some global operations on the project. You can now open the
330 project file and have one-click access to all the *.ui forms in the
333 In addition to generating code via uic, Qt Designer now supports the
334 dynamic creation of widgets directly from XML user interface
335 description files (*.ui files) at runtime. This eliminates the need of
336 recompiling your application when the GUI changes, and could be used
337 to enable your customers to do their own customizations. Technically,
338 the feature is provided by a new class, QWidgetFactory in the
343 ========================================
345 Qt Linguist is a GUI utility to support translating the user-visible
346 text in applications written with Qt. It comes with two command-line
347 tools: lupdate and lrelease.
349 Translation of a Qt application is a three-step process:
351 1) Run lupdate to extract user-visible text from the C++ source
352 code of the Qt application, resulting in a translation source file
354 2) Provide translations for the source texts in the *.ts file using
356 3) Run lrelease to obtain a light-weight message file (a *.qm file)
357 from the *.ts file, which provides very fast lookup for released
360 Qt Linguist is a tool suitable for use by translators. Each
361 user-visible (source) text is characterized by the text itself, a
362 context (usually the name of the C++ class containing the text), and
363 an optional comment to help the translator. The C++ class name will
364 usually be the name of the relevant dialog, and the comment will often
365 contain instructions that describe how to navigate to the relevant
368 You can create phrase books for Qt Linguist to provide common
369 translations to help ensure consistency and to speed up the
370 translation process. Whenever a translator navigates to a new text to
371 translate, Qt Linguist uses an intelligent algorithm to provide a list
372 of possible translations: the list is composed of relevant text from
373 any open phrase books and also from identical or similar text that has
374 already been translated.
376 Once a translation is complete it can be marked as "done"; such
377 translations are included in the *.qm file. Text that has not been
378 "done" is included in the *.qm file in its original form. Although Qt
379 Linguist is a GUI application with dock windows and mouse control,
380 toolbars, etc., it has a full set of keyboard shortcuts to make
381 translation as fast and efficient as possible.
383 When the Qt application that you're developing evolves (e.g. from
384 version 1.0 to version 1.1), the utility lupdate merges the source
385 texts from the new version with the previous translation source file,
386 reusing existing translations. In some typical cases, lupdate may
387 suggest translations. These translations are marked as unfinished, so
388 you can easily find and check them.
392 ========================================
394 Due to the positive feedback we received about the help system built
395 into Qt Designer, we decided to offer this part as a separate
396 application called Qt Assistant. Qt Assistant can be used to browse
397 the Qt class documentation as well as the manuals for Qt Designer and
398 Qt Linguist. It offers index searching, a contents overview, bookmarks
399 history and incremental search. Qt Assistant is used by both Qt
400 Designer and Qt Linguist for browsing their help documentation.
404 ========================================
406 To ease portability we now provide the qmake utility to replace tmake.
407 QMake is a C++ version of tmake which offers additional functionallity
408 that is difficult to reproduce in tmake. Trolltech uses qmake in its
409 build system for Qt and related products and we have released it as
414 ========================================
420 void addedTo( QWidget *actionWidget, QWidget *container );
421 void addedTo( int index, QPopupMenu *menu );
426 New mode "uses drop down", where members are shown in a separate
427 subwidget such as a combobox or a submenu (enable with
428 setUsesDropDown(TRUE) )
433 void addedTo( QWidget *actionWidget, QWidget *container, QAction *a );
434 void addedTo( int index, QPopupMenu *menu, QAction *a );
435 void setUsesDropDown( bool enable );
436 bool usesDropDown() const;
442 Added the setStyle(const QString&) overload that takes the name of the
443 style as its argument. This loads a style plugin via a QStyleFactory.
445 desktop() now returns a QDesktopWidget that provides access to
446 multi-head information. Prior to 3.0, it returned a normal QWidget.
448 New functions to define the library search path for plugins
449 (setLibraryPaths, ...).
451 New functions to define reverse layout for bidirectional languages
452 (setReverseLayout, ...).
455 bool hasPendingEvents()
457 void setLibraryPaths(const QStringList &);
458 QStringList libraryPaths();
459 void addLibraryPath(const QString &);
460 void removeLibraryPath(const QString &);
462 void setReverseLayout( bool b );
463 bool reverseLayout();
464 int horizontalAlignment( int align );
471 On systems that support it, for example X11, QClipboard now
472 differentiates between the primary selection and the data in the clipboard.
475 bool supportsSelection() const;
476 bool ownsClipboard() const;
477 void setSelectionMode(bool enable);
478 bool selectionModeEnabled() const;
480 void selectionChanged()
487 Now inherits Qt namespace. Enum values like ArrowCursor,
488 UpArrowCursor, CrossCursor etc. are now part of that namespace.
494 Added missing operators for Q_LONG and Q_ULONG
497 QDateTime / QDate / QTime
498 -------------------------
500 More sophisticated toString() function that takes a DateFormat, where
501 DateFormat can be either TextDate (the default), ISODate (ISO 8601) or
502 LocalDate (locale dependent).
505 QDate addMonths( int months ) const;
506 QDate addYears( int years ) const;
507 QDate fromString( const QString& s, Qt::DateFormat f = Qt::TextDate );
508 static QString shortMonthName( int month );
509 static QString longMonthName( int month );
510 static QString shortDayName( int weekday );
511 static QString longDayName( int weekday );
512 static void setShortMonthNames( const QStringList& names );
513 static void setLongMonthNames( const QStringList& names );
514 static void setShortDayNames( const QStringList& names );
515 static void setLongDayNames( const QStringList& names );
520 Merged with QSemiModal. Calling show() on a modal dialog will return
521 immediately, not enter a local event loop. Showing a modal dialog in
522 its own event loop is achieved using exec().
524 exec() is now a public slot.
526 Usability: For widgets supporting What's This help, QDialog
527 automatically offers a context menu containing a "What's This?" entry.
533 Mouse events are now propagated up to the toplevel widget if no widget
534 accepts them and no event filter filters them out. In previous Qt
535 versions, only key events were propagated.
537 All events carry a flag 'spontaneous' to determine whether the even
538 came from the outside or was generated by code within the
539 applications. Previously, only show and hide events had this flag.
541 Enter/Leave event generation has been fixed. Previously, a widget
542 received a leave event when the mouse pointer entered one of its
543 children. This was both unnatural and contradictive to the
546 QWheelevent now carries an orientation to differentiate between
547 horizontal and vertical wheels.
549 QFocusEvent: new reason 'Backtab' (previously only 'Tab' was
550 available). This makes it possible to discover from what direction on
551 the tab-focus chain the widget was entered.
553 New events: QContextMenuEvent, QIMEvent
559 Ported from int to Q_LONG to prepare for large file sizes on 64 bit
562 Filter handling made more flexible.
569 void setSelectedFilter( const QString& );
570 void setSelectedFilter( int );
572 void filesSelected( const QStringList& );
573 void filterSelected( const QString& );
575 If you try to specify an invalid file when using getOpenFileName(s), an error message
576 will appear and the file will not be accepted. In 2.x, this function behaved differently
577 because users were using getOpenFileName(s) as a Save File Dialog; you should use
578 getSaveFileName() when you require a Save File Dialog.
585 QCanvasSpline - a multi-bezier spline
592 void setUnchanged( const QRect& area );
593 void drawArea(const QRect&, QPainter* p, bool double_buffer);
594 void drawViewArea( QCanvasView* view, QPainter* p, const QRect& r, bool dbuf );
595 QRect changeBounds(const QRect& inarea);
598 const QWMatrix &worldMatrix() const;
599 const QWMatrix &inverseWorldMatrix() const;
600 void setWorldMatrix( const QWMatrix & );
602 int leftEdge() const;
604 int rightEdge() const;
605 int bottomEdge() const;
606 int leftEdge(int nx) const;
607 int topEdge(int ny) const;
608 int rightEdge(int nx) const;
609 int bottomEdge(int ny) const;
611 QCanvasSprite can now be set to animate its frames without the need to
615 QFont, QFontDatabase, QFontInfo, QFontMetrics
616 ---------------------------------------------
618 The QFont::CharSet enum has been removed and replaced with the
619 QFont::Script enum. With this change, a QFont is not associated with a
620 specific character set. Instead, QFont uses Unicode Scripts for
621 loading fonts. On platforms where most fonts do not use the Unicode
622 encoding (currently only X11), multiple locale and character-set
623 dependent fonts can be loaded for the individual Unicode Scripts.
625 Another new feature of QFont is a much more flexible substitution
626 mechanism. Each family can have a list of appropriate substitutes. The
627 font substitution feature allows you to specify a list of substitute
628 fonts. Substitute fonts are used when a font cannot be loaded, or if
629 the specified font doesn't have a particular character (X11 only).
631 For example (on X11), you select the font Lucida, which doesn't have
632 Korean characters. For Korean text, you want to use the Mincho font
633 family. By adding Mincho to the list, any Korean characters not found
634 in Lucida will be used from Mincho. Because the font substitutions are
635 lists, you can also select multiple families, such as Song Ti (for use
638 QFontInfo and QFontMetrics had small API changes related to the
639 disappearance of QFont::CharSet. In terms of functionality, the
640 behavior of these classes is unchanged.
642 QFontDatabase had several API cleanups related to the disappearance of
643 QFont::CharSet. Most QFontDatabase member functions take one less
644 argument, yet compatibility functions still exist to keep old source
647 Family and style names returned from QFontDatabase are now processed
648 and formatted in a way that is suitable for display to users. Family
649 and foundry names are capitalized and foundry names are enclosed in
650 square brackets after the family name. For example, the Helvetica
651 font family might have 3 different foundries: Adobe, Cronyx and
652 Phaisarn. In 2.x, QFontDatabase listed them like this:
658 Starting with 3.0, QFontDatabase lists them like this:
668 Two new frame shapes for more sophisticated style features:
669 MenuBarPanel and ToolBarPanel.
677 enum Direction { Horizontal, Vertical };
679 has been eliminated, as it is redundant: use Qt::Orientation instead.
680 Old code referring to QGrid::Horizontal or QGrid::Vertical will still
681 work, as QGrid counts Qt among its ancestors.
687 More functionality of the built-in layout is exposed:
689 int insideMargin() const;
690 int insideSpacing() const;
691 void setInsideMargin( int m );
692 void setInsideSpacing( int s );
698 New property: bool stretching
701 bool isStretchEnabled( int section );
702 void setStretchEnabled( bool b, int section );
708 In addition to the mode - which can be either Normal, Disabled or
709 Active - QIconSet now supports different pixmaps for a state, i.e. On
710 or Off. The functions pixmap() and setPixmap() have been extended
713 The default constructor no longer initializes the iconset to
714 contain a null pixmap. QIconSet::isNull() returns TRUE for un-
715 initialized iconsets, and pixmap() still returns a null pixmap for
716 pixmaps that couldn't be generated.
722 Extended findItem() to support ComparisonFlags. Support for
723 soft-hyphens when doing word wrap.
726 contextMenuRequested( QIconViewItem*, const QPoint& pos);
732 Added support for explicit rtti.
742 Extended findItem() to support ComparisonFlags.
745 void contextMenu( QListBoxItem *, const QPoint & );
751 Added support for explicit rtti.
761 It was never really hard to implement drag and drop with QListView,
762 but since many applications demand this functionality today, we
763 decided to add it to the listview itself.
765 In addition, in-place editing and per-item tooltips have been added.
766 Extended findItem() to support ComparisonFlags
770 ResizeMode resizeMode
773 contextMenuRequested( QIconViewItem*, const QPoint& pos);
774 void dropped( QDropEvent *e );
775 void itemRenamed( QListViewItem *item, int col, const QString & );
776 void itemRenamed( QListViewItem *item, int col );
779 void setResizeMode( ResizeMode m );
780 ResizeMode resizeMode() const;
781 QDragObject *dragObject();
789 Added support for explicit rtti.
792 void setDragEnabled( bool allow );
793 void setDropEnabled( bool allow );
794 bool dragEnabled() const;
795 bool dropEnabled() const;
796 bool acceptDrop( const QMimeSource *mime ) const;
797 void setVisible( bool b );
798 bool isVisible() const;
799 void setRenameEnabled( int col, bool b );
800 bool renameEnabled( int col ) const;
801 void startRename( int col );
802 void setEnabled( bool b );
803 bool isEnabled() const;
806 void dropped( QDropEvent *e );
809 void okRename( int col );
810 void cancelRename( int col );
816 In addition to text, rich text, pixmaps and movies, QLabel can now
817 display QPicture vector graphics.
821 QPicture *picture() const;
822 void setPicture( const QPicture & );
828 New property: bool dragEnabled
831 contextMenuRequested( QIconViewItem*, const QPoint& pos);
834 void cursorForward( bool mark, int steps = 1 );
835 void cursorBackward( bool mark, int steps = 1 );
836 void cursorWordForward( bool mark );
837 void cursorWordBackward( bool mark );
839 void setDragEnabled( bool b );
845 Added a dock window architecture. Previous versions of QMainWindow
846 could only deal with toolbars, now they handle generalized dock
847 windows. QToolBar inherits QDockWindow.
851 bool dockWindowsMovable;
854 void dockWindowPositionChanged( QDockWindow * );
857 void setDockEnabled( Dock dock, bool enable );
858 bool isDockEnabled( Dock dock ) const;
859 bool isDockEnabled( QDockArea *area ) const;
860 void setDockEnabled( QDockWindow *tb, Dock dock, bool enable );
861 bool isDockEnabled( QDockWindow *tb, Dock dock ) const;
862 bool isDockEnabled( QDockWindow *tb, QDockArea *area ) const;
864 void addDockWindow( QDockWindow *, Dock = Top, bool newLine = FALSE );
865 void addDockWindow( QDockWindow *, const QString &label, Dock = Top, bool newLine = FALSE );
866 void moveDockWindow( QDockWindow *, Dock = Top );
867 void moveDockWindow( QDockWindow *, Dock, bool nl, int index, int extraOffset = -1 );
868 void removeDockWindow( QDockWindow * );
870 QDockArea *dockingArea( const QPoint &p );
871 QDockArea *leftDock() const;
872 QDockArea *rightDock() const;
873 QDockArea *topDock() const;
874 QDockArea *bottomDock() const;
876 bool isCustomizable() const;
877 bool appropriate( QDockWindow *dw ) const;
878 QPopupMenu *createDockWindowMenu( DockWindows dockWindows = AllDockWindows ) const;
880 bool showDockMenu( const QPoint &globalPos );
892 New static functions:
893 QMimeSourceFactory* takeDefaultFactory();
894 static void addFactory( QMimeSourceFactory *f );
900 Spelling fix in Error::ErrListChildren enum.
906 QRegExp now has a more complete regular expression engine similar to
907 Perl's, with full Unicode and backreference support.
910 bool minimal() const;
911 void setMinimal( bool minimal );
912 bool exactMatch( const QString& str );
913 bool exactMatch( const QString& str ) const;
914 int search( const QString& str, int start = 0 );
915 int search( const QString& str, int start = 0 ) const;
916 int searchRev( const QString& str, int start = -1 );
917 int searchRev( const QString& str, int start = -1 ) const;
919 QStringList capturedTexts();
920 QString cap( int nth = 0 );
921 int pos( int nth = 0 );
927 Renamed the misnamed setProperty() overloads to setManagerProperty()
928 to resolve the conflict with the now virtual QObject::setProperty().
935 bool endsWith( const QString & );
936 int similarityWith( const QString & );
948 The extended QTabWidget support in Qt Designer made two more
949 functions handy to have:
950 QTab * tabAt( int ) const;
951 int indexOf( int ) const;
958 Inherits QDockWindow now, previously only QWidget.
968 QIconSet iconSet() const;
969 virtual void setIconSet( const QIconSet & );
976 const QColor & eraseColor() const;
977 virtual void setEraseColor( const QColor & );
978 const QPixmap * erasePixmap() const;
979 virtual void setErasePixmap( const QPixmap & );
986 New property: QString titleFont
989 QFont titleFont() const;
990 void setTitleFont( const QFont & );
991 int indexOf( QWidget* ) const;
998 bool isIdentity() const;
1006 QGLFormat requestedFormat() const;
1007 QImage grabFrameBuffer( bool withAlpha = FALSE );
1013 A new property scrollBarsEnabled makes it possible to add on-demand
1014 scrollbars to the workspace. We define this property in Qt Designer to
1015 make designing forms larger than the available space on the desktop
1019 bool scrollBarsEnabled
1024 Many new functions have been added:
1026 QDomDocumentType createDocumentType( const QString& qName, const QString& publicId, const QString& systemId );
1027 QDomDocument createDocument( const QString& nsURI, const QString& qName, const QDomDocumentType& doctype );
1029 QDomNode insertBefore( const QDomNode& newChild, const QDomNode& refChild );
1030 QDomNode insertAfter( const QDomNode& newChild, const QDomNode& refChild );
1031 QDomNode replaceChild( const QDomNode& newChild, const QDomNode& oldChild );
1032 QDomNode removeChild( const QDomNode& oldChild );
1033 QDomNode appendChild( const QDomNode& newChild );
1034 bool hasChildNodes() const;
1035 QDomNode cloneNode( bool deep = TRUE ) const;
1037 bool isSupported( const QString& feature, const QString& version ) const;
1038 QString namespaceURI() const;
1039 QString localName() const;
1040 bool hasAttributes() const;
1042 bool setContent( const QCString& text, bool namespaceProcessing=FALSE );
1043 bool setContent( const QByteArray& text, bool namespaceProcessing=FALSE );
1044 bool setContent( const QString& text, bool namespaceProcessing=FALSE );
1045 bool setContent( QIODevice* dev, bool namespaceProcessing=FALSE );
1047 QDomNode namedItemNS( const QString& nsURI, const QString& localName ) const;
1048 QDomNode setNamedItemNS( const QDomNode& newNode );
1049 QDomNode removeNamedItemNS( const QString& nsURI, const QString& localName );
1052 QString attributeNS( const QString nsURI, const QString& localName, const QString& defValue ) const;
1053 void setAttributeNS( const QString nsURI, const QString& qName, const QString& value );
1054 void setAttributeNS( const QString nsURI, const QString& qName, int value );
1055 void setAttributeNS( const QString nsURI, const QString& qName, uint value );
1056 void setAttributeNS( const QString nsURI, const QString& qName, double value );
1057 void removeAttributeNS( const QString& nsURI, const QString& localName );
1058 QDomAttr attributeNodeNS( const QString& nsURI, const QString& localName );
1059 QDomAttr setAttributeNodeNS( const QDomAttr& newAttr );
1060 QDomNodeList elementsByTagNameNS( const QString& nsURI, const QString& localName ) const;
1061 bool hasAttributeNS( const QString& nsURI, const QString& localName ) const;
1066 void append( const QString &qName, const QString &uri, const QString &localPart, const QString &value );
1069 void setData( const QByteArray& dat );
1074 QString fromRawData( const QByteArray &data, bool beginning = FALSE );
1077 bool parse( const QXmlInputSource& input, bool incremental );
1078 bool parseContinue();
1081 bool startEntity( const QString& name );
1082 bool endEntity( const QString& name );
1089 QAquaStyle (only on MacOS X)
1092 QComponentFactoryInterface
1093 QComponentServerInterface
1099 QFeatureListInterface
1101 QInterfaceListInterface
1118 QArray has been renamed QMemArray
1119 QCollection has been renamed QPtrCollection
1120 QList has been renamed QPtrList
1121 QListIterator has been renamed QPtrListIterator
1122 QQueue has been renamed QPtrQueue
1123 QStack has been renamed QPtrStack
1124 QVector has been renamed QPtrVector
1126 The include file names have changed accordingly (e.g., <qmemarray.h>).
1143 QSemiModal, use QDialog instead.
1144 QMultiLineEdit, use QTextEdit instead.
1145 QTableView, use QScrollView or QTable instead.
1146 QAsyncIO, QDataSink, QDataSource, QDataPump and QIODeviceSource
1151 QActionGroup::insert( QAction * ), use QActionGroup::add( QAction* ) instead.
1152 QApplication::setWinStyleHighlightColor( const QColor &c ), use setPalette() instead
1153 QApplication::winStyleHighlightColor(), use palette() instead
1154 QDir::encodedEntryList( int filterSpec, int sortSpec ), use QDir::entryList() instead
1155 QDir::encodedEntryList( const QString &nameFilter, int filterSpec, int sortSpec ), use QDir::entryList() instead
1156 QMainWindow::addToolBar( QDockWindow *, Dock = Top, bool newLine = FALSE );
1157 QMainWindow::addToolBar( QDockWindow *, const QString &label, Dock = Top, bool newLine = FALSE );
1158 QMainWindow::moveToolBar( QDockWindow *, Dock = Top );
1159 QMainWindow::moveToolBar( QDockWindow *, Dock, bool nl, int index, int extraOffset = -1 );
1160 QMainWindow::removeToolBar( QDockWindow * );
1161 QMainWindow::toolBarsMovable() const;
1162 QMainWindow::toolBars( Dock dock ) const;
1163 QMainWindow::lineUpToolBars( bool keepNewLines = FALSE );
1164 QRegExp::match( const QString& str, int index = 0, int *len = 0,
1165 bool indexIsStart = TRUE );
1166 QToolButton::setOnIconSet( const QIconSet & )
1167 QToolButton::setOffIconSet( const QIconSet & )
1168 QToolButton::onIconSet() const
1169 QToolButton::offIconSet() const
1170 QToolButton::setIconSet( const QIconSet & set, bool on )
1171 QToolButton::iconSet( bool on ) const
1172 QXmlInputSource::QXmlInputSource( QFile& file ), use QXmlInputSource( QIODevice *dev ) instead.
1173 QXmlInputSource::QXmlInputSource( QTextStream& stream ), use QXmlInputSource( QIODevice *dev ) instead.
1176 QWidget::setFontPropagation
1177 QWidget::setPalettePropagation
1178 QMenuBar::setActItem
1179 QMenuBar::setWindowsAltMode
1180 QCheckListItem::paintBranches
1182 QString::basicDirection
1183 QRegExp::find( const QString& str, int index ) const; - has been renamed QRegExp::search()
1184 QFont::charSet() const, not needed anymore
1185 QFont::setCharSet( QFont::CharSet ), not needed anymore
1186 QPushButton::upButton(), not relevant anymore
1187 QPushButton::downButton(), not relevant anymore
1188 QSpinBox::upButton(), not relevant anymore
1189 QSpinBox::downButton(), not relevant anymore
1192 Removed preprocessor directives
1193 -------------------------------
1195 qcstring.h no longer contains the following defines:
1197 #define strlen qstrlen
1198 #define strcpy qstrcpy
1199 #define strcmp qstrcmp
1200 #define strncmp qstrncmp
1201 #define stricmp qstricmp
1202 #define strnicmp qstrnicmp
1204 These directives were meant to automagically replace calls to the
1205 above listed standard C functions with the equivalent Qt wrappers.
1206 The latter pre-check the input parameters for null pointers as those
1207 might cause crashes on some platforms.
1209 Although convenient, this trick turned out to sometimes conflict with
1210 third-party code, or, simply be nullified by standard system and
1211 library headers depending on version and include order.
1213 The name of some debugging macro variables has been changed.
1215 DEBUG becomes QT_DEBUG
1216 NO_DEBUG becomes QT_NO_DEBUG
1217 NO_CHECK becomes QT_NO_CHECK
1218 CHECK_STATE becomes QT_CHECK_STATE
1219 CHECK_RANGE becomes QT_CHECK_RANGE
1220 CHECK_NULL becomes QT_CHECK_NULL
1221 CHECK_MATH becomes QT_CHECK_MATH
1223 The name of some other debugging macro functions has also been changed
1224 but source compatibility should not be affected if the macro variable
1225 QT_CLEAN_NAMESPACE is not defined:
1227 ASSERT becomes Q_ASSERT
1228 CHECK_PTR becomes Q_CHECK_PTR
1230 For the record these undocumented macro variables that are not part of
1231 the API have been changed:
1233 _OS_*_ becomes Q_OS_*
1234 _WS_*_ becomes Q_WS_*
1235 _CC_*_ becomes Q_CC_*