1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!-- /home/espenr/tmp/qt-3.3.8-espenr-2499/qt-x11-free-3.3.8/doc/porting3.doc:36 -->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Porting to TQt 3.x</title>
<style type="text/css"><!--
fn { margin-left: 1cm; text-indent: -1cm; }
a:link { color: #004faf; text-decoration: none }
a:visited { color: #672967; text-decoration: none }
body { background: #ffffff; color: black; }
--></style>
</head>
<body>
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr bgcolor="#E5E5E5">
<td valign=center>
<a href="index.html">
<font color="#004faf">Home</font></a>
| <a href="classes.html">
<font color="#004faf">All Classes</font></a>
| <a href="mainclasses.html">
<font color="#004faf">Main Classes</font></a>
| <a href="annotated.html">
<font color="#004faf">Annotated</font></a>
| <a href="groups.html">
<font color="#004faf">Grouped Classes</font></a>
| <a href="functions.html">
<font color="#004faf">Functions</font></a>
</td>
<td align="right" valign="center"><img src="logo32.png" align="right" width="64" height="32" border="0"></td></tr></table><h1 align=center>Porting to TQt 3.x</h1>
<p> This document describes porting applications from TQt 2.x to TQt 3.x.
<p> The TQt 3.x series is not binary compatible with the 2.x series. This
means programs compiled for TQt 2.x must be recompiled to work with TQt
3.x. TQt 3.x is also not completely <em>source</em> compatible with 2.x,
however all points of incompatibility cause compiler errors or
run-time messages (rather than mysterious results). TQt 3.x includes
many additional features and discards obsolete functionality. Porting
from TQt 2.x to TQt 3.x is straightforward, and once completed makes
the considerable additional power and flexibility of TQt 3.x available
for use in your applications.
<p> To port code from TQt 2.x to TQt 3.x:
<p> <ol type=1>
<p> <li> Briefly read the porting notes below to get an idea of what to expect.
<li> Be sure your code compiles and runs well on all your target platforms
with TQt 2.x.
<li> Recompile with TQt 3.x. For each error, search below for related
identifiers (e.g. function names, class names). This document
mentions all relevant identifiers to help you get the information
you need at the cost of being a little verbose.
<li> If you get stuck, ask on the <a href="http://qt-interest.trolltech.com/">qt-interest</a> mailing list, or Trolltech Technical Support if
you're a registered licensee.
<p> </ol>
<p> Table of contents:
<p> <!-- toc -->
<ul>
<li><a href="#1"> Link Errors on Windows
</a>
<li><a href="#2"> Header file inclusion changes
</a>
<li><a href="#3"> Namespace
</a>
<li><a href="#4"> Removed Functions
</a>
<li><a href="#5"> Obsoleted Functions
</a>
<li><a href="#6"> Collection Class Renaming
</a>
<li><a href="#7"> TQButtonGroup
</a>
<li><a href="#8"> TQDate
</a>
<li><a href="#9"> TQFileDialog
</a>
<li><a href="#10"> TQFont
</a>
<li><a href="#11"> TQInputDialog
</a>
<li><a href="#12"> TQLayout and Other Abstract Layout Classes
</a>
<li><a href="#13"> TQListViewItem
</a>
<li><a href="#14"> TQMoveEvent
</a>
<li><a href="#15"> TQMultiLineEdit
</a>
<li><a href="#16"> TQPrinter
</a>
<li><a href="#17"> TQRegExp
</a>
<ul>
<li><a href="#17-1"> New special characters
</a>
<li><a href="#17-2"> TQRegExp::operator=()
</a>
<li><a href="#17-3"> TQRegExp::match()
</a>
<li><a href="#17-4"> TQRegExp::find()
</a>
<li><a href="#17-5"> TQString::findRev() and TQString::contains()
</a>
<li><a href="#17-6"> TQString::replace()
</a>
</ul>
<li><a href="#18"> TQSemiModal
</a>
<li><a href="#19"> TQSortedList
</a>
<li><a href="#20"> TQTableView
</a>
<li><a href="#21"> TQToolButton
</a>
<li><a href="#22"> TQTextStream
</a>
<li><a href="#23"> TQTranslator
</a>
<li><a href="#24"> TQWidget
</a>
<li><a href="#25"> TQXml Classes
</a>
<ul>
<li><a href="#25-1"> TQXmlInputSource
</a>
<li><a href="#25-2"> TQXmlLocator
</a>
</ul>
<li><a href="#26"> Asynchronous I/O Classes
</a>
<li><a href="#27"> Transparent widgets
</a>
<li><a href="#28"> Bezier Curves
</a>
<li><a href="#29"> Locale-aware String Comparisons in TQIconView, TQListBox,
TQListView and TQTable
</a>
</ul>
<!-- endtoc -->
<p> <a name="Linkerrors"></a>
<h2> Link Errors on Windows
</h2>
<a name="1"></a><p> On Windows, originally in TQt 2.x, the default configuration of the TQt
library is static. If you just use the default configuration you
don't need to set certain preprocessor defines. In TQt 3.0, the
default configuration of the TQt library is to build it as a shared
library, therefore the preprocessor define <tt>QT_DLL</tt> is needed.
<p> If you use tmake with TQt 2.x, and now use qmake with TQt 3.x, then the
cause of the problem is with the project file. In the project file,
there is usually line that looks like:
<p> <tt>CONFIG</tt> = ...
<p> this should be changed to
<p> <tt>CONFIG</tt> += ...
<p> so that qmake can look at the configuration that TQt was built with and
set any relevant preprocessor defines in the makefile.
<p> <a name="Headers"></a>
<h2> Header file inclusion changes
</h2>
<a name="2"></a><p> TQt 3.x remove some unnecessary nested #include directives from
header files. This speeds up compilation when you don't need those
nested header files. But in some cases you will find you need to add
an extra #include to your files.
<p> For example, if you get a message about <a href="qstringlist.html">TQStringList</a> or its functions
not being defined, then add <tt>#include <qstringlist.h></tt> at
the top of the file giving the error.
<p> Header files that you might need to add #include directives for include:
<ul>
<li> <tt><qcursor.h></tt>
<li> <tt><qpainter.h></tt>
<li> <tt><qpen.h></tt>
<li> <tt><qstringlist.h></tt>
<li> <tt><qregexp.h></tt>
<li> <tt><qstrlist.h></tt>
<li> <tt><qstyle.h></tt>
<li> <tt><qvaluelist.h></tt>
</ul>
<p> <h2> Namespace
</h2>
<a name="3"></a><p> TQt 3.x is namespace clean. A few global identifiers that had been
left in TQt 2.x have been discarded.
<p> Enumeration <a href="qt.html#CursorShape-enum">TQt::CursorShape</a> and its values are now part of the
special <a href="qt.html">TQt</a> class defined in qnamespace.h. If you get compilation
errors about these being missing (unlikely, since most of your code will
be in classes that inherit from the TQt namespace class), then apply
the following changes:
<p> <ul>
<li> <tt>TQCursorShape</tt> becomes <a href="qt.html#CursorShape-enum">TQt::CursorShape</a>
<li> <tt>ArrowCursor</tt> becomes <a href="qt.html#CursorShape-enum">TQt::ArrowCursor</a>
<li> <tt>UpArrowCursor</tt> becomes <a href="qt.html#CursorShape-enum">TQt::UpArrowCursor</a>
<li> <tt>CrossCursor</tt> becomes <a href="qt.html#CursorShape-enum">TQt::CrossCursor</a>
<li> <tt>WaitCursor</tt> becomes <a href="qt.html#CursorShape-enum">TQt::WaitCursor</a>
<li> <tt>IbeamCursor</tt> becomes <a href="qt.html#CursorShape-enum">TQt::IbeamCursor</a>
<li> <tt>SizeVerCursor</tt> becomes <a href="qt.html#CursorShape-enum">TQt::SizeVerCursor</a>
<li> <tt>SizeHorCursor</tt> becomes <a href="qt.html#CursorShape-enum">TQt::SizeHorCursor</a>
<li> <tt>SizeBDiagCursor</tt> becomes <a href="qt.html#CursorShape-enum">TQt::SizeBDiagCursor</a>
<li> <tt>SizeFDiagCursor</tt> becomes <a href="qt.html#CursorShape-enum">TQt::SizeFDiagCursor</a>
<li> <tt>SizeAllCursor</tt> becomes <a href="qt.html#CursorShape-enum">TQt::SizeAllCursor</a>
<li> <tt>BlankCursor</tt> becomes <a href="qt.html#CursorShape-enum">TQt::BlankCursor</a>
<li> <tt>SplitVCursor</tt> becomes <a href="qt.html#CursorShape-enum">TQt::SplitVCursor</a>
<li> <tt>SplitHCursor</tt> becomes <a href="qt.html#CursorShape-enum">TQt::SplitHCursor</a>
<li> <tt>PointingHandCursor</tt> becomes <a href="qt.html#CursorShape-enum">TQt::PointingHandCursor</a>
<li> <tt>BitmapCursor</tt> becomes <a href="qt.html#CursorShape-enum">TQt::BitmapCursor</a>
</ul>
<p> The names of some debugging macro variables have been changed. We have
tried not to break source compatibility as much as possible. If you observe
error messages on the UNIX console or the Windows debugging stream that were
previously disabled, please check these macro variables:
<p> <ul>
<li> <tt>DEBUG</tt> becomes <tt>QT_DEBUG</tt>
<li> <tt>NO_DEBUG</tt> becomes <tt>QT_NO_DEBUG</tt>
<li> <tt>NO_CHECK</tt> becomes <tt>QT_NO_CHECK</tt>
<li> <tt>CHECK_STATE</tt> becomes <tt>QT_CHECK_STATE</tt>
<li> <tt>CHECK_RANGE</tt> becomes <tt>QT_CHECK_RANGE</tt>
<li> <tt>CHECK_NULL</tt> becomes <tt>QT_CHECK_NULL</tt>
<li> <tt>CHECK_MATH</tt> becomes <tt>QT_CHECK_MATH</tt>
</ul>
<p> The name of some debugging macro functions has been changed as well
but source compatibility should not be affected if the macro variable
<tt>QT_CLEAN_NAMESPACE</tt> is not defined:
<p> <ul>
<li> <tt>ASSERT</tt> becomes <tt>Q_ASSERT</tt>
<li> <tt>CHECK_PTR</tt> becomes <tt>Q_CHECK_PTR</tt>
</ul>
<p> For the record, undocumented macro variables that are not part of the API
have been changed:
<p> <ul>
<li> <tt>_OS_*_</tt> becomes <tt>Q_OS_*</tt>
<li> <tt>_WS_*_</tt> becomes <tt>Q_WS_*</tt>
<li> <tt>_CC_*_</tt> becomes <tt>Q_CC_*</tt>
</ul>
<p> <h2> Removed Functions
</h2>
<a name="4"></a><p> All these functions have been removed in TQt 3.x:
<ul>
<li> TQFont::charSet()
<li> TQFont::setCharSet()
<li> TQMenuBar::setActItem()
<li> TQMenuBar::setWindowsAltMode()
<li> TQObject::initMetaObject()
<li> TQPainter::drawQuadBezier()
<li> TQPointArray::quadBezier()
<li> TQRegExp::find()
<li> TQSpinBox::downButton()
<li> TQSpinBox::upButton()
<li> TQString::basicDirection()
<li> TQString::visual()
<li> TQStyle::set...() functions
<li> TQStyle::drawArrow()
<li> TQWidget::setFontPropagation()
<li> TQWidget::setPalettePropagation()
</ul>
<p> Also, to avoid conflicts with <tt><iostream></tt>, the following three
global functions have been renamed:
<ul>
<li> setw() (renamed qSetW())
<li> setfill() (renamed qSetFill())
<li> setprecision() (renamed qSetPrecision())
</ul>
<p> <h2> Obsoleted Functions
</h2>
<a name="5"></a><p> The following functions have been obsoleted in TQt 3.0. The
documentation of each of these functions should explain how to
replace them in TQt 3.0.
<p> <b>Warning:</b> It is best to consult <a href="http://doc.trolltech.com/3.0/">http://doc.trolltech.com/3.0/</a>
rather than the documentation supplied with TQt to obtain the latest
information regarding obsolete functions and how to replace them in
new code.
<p> <ul>
<li> <a href="qaccel.html#keyToString">TQAccel::keyToString</a>( <a href="qkeysequence.html">TQKeySequence</a> k )
<li> <a href="qaccel.html#stringToKey">TQAccel::stringToKey</a>( const <a href="qstring.html">TQString</a> & s )
<li> <a href="qactiongroup.html#insert">TQActionGroup::insert</a>( <a href="qaction.html">TQAction</a> *a )
<li> <a href="qbutton.html#autoResize">TQButton::autoResize</a>() const
<li> <a href="qbutton.html#setAutoResize">TQButton::setAutoResize</a>( bool )
<li> <a href="qcanvasitem.html#active">TQCanvasItem::active</a>() const
<li> <a href="qcanvasitem.html#enabled">TQCanvasItem::enabled</a>() const
<li> <a href="qcanvasitem.html#selected">TQCanvasItem::selected</a>() const
<li> <a href="qcanvasitem.html#visible">TQCanvasItem::visible</a>() const
<li> <a href="qcanvaspixmaparray.html#TQCanvasPixmapArray">TQCanvasPixmapArray::TQCanvasPixmapArray</a>( <a href="qptrlist.html">TQPtrList</a><TQPixmap> list, TQPtrList<TQPoint> hotspots )
<li> <a href="qcanvaspixmaparray.html#operator!">TQCanvasPixmapArray::operator!</a>()
<li> <a href="qcolorgroup.html#TQColorGroup">TQColorGroup::TQColorGroup</a>( const <a href="qcolor.html">TQColor</a> & foreground, const TQColor & background, const TQColor & light, const TQColor & dark, const TQColor & mid, const TQColor & text, const TQColor & base )
<li> <a href="qcombobox.html#autoResize">TQComboBox::autoResize</a>() const
<li> <a href="qcombobox.html#setAutoResize">TQComboBox::setAutoResize</a>( bool )
<li> <a href="qdate.html#dayName">TQDate::dayName</a>( int weekday )
<li> <a href="qdate.html#monthName">TQDate::monthName</a>( int month )
<li> <a href="qdir.html#encodedEntryList">TQDir::encodedEntryList</a>( const <a href="qstring.html">TQString</a> & nameFilter, int filterSpec = DefaultFilter, int sortSpec = DefaultSort ) const
<li> TQDir::encodedEntryList( int filterSpec = DefaultFilter, int sortSpec = DefaultSort ) const
<li> <a href="qdockwindow.html#isHorizontalStretchable">TQDockWindow::isHorizontalStretchable</a>() const
<li> <a href="qdockwindow.html#isVerticalStretchable">TQDockWindow::isVerticalStretchable</a>() const
<li> <a href="qdockwindow.html#setHorizontalStretchable">TQDockWindow::setHorizontalStretchable</a>( bool b )
<li> <a href="qdockwindow.html#setVerticalStretchable">TQDockWindow::setVerticalStretchable</a>( bool b )
<li> <a href="qfont.html#defaultFont">TQFont::defaultFont</a>()
<li> <a href="qfont.html#setDefaultFont">TQFont::setDefaultFont</a>( const <a href="qfont.html">TQFont</a> & f )
<li> <a href="qfont.html#setPixelSizeFloat">TQFont::setPixelSizeFloat</a>( float pixelSize )
<li> <a href="qfontdatabase.html#bold">TQFontDatabase::bold</a>( const TQString & family, const TQString & style, const <a href="qstring.html">TQString</a> & ) const
<li> <a href="qfontdatabase.html#families">TQFontDatabase::families</a>( bool ) const
<li> <a href="qfontdatabase.html#font">TQFontDatabase::font</a>( const TQString & familyName, const TQString & style, int pointSize, const TQString & )
<li> <a href="qfontdatabase.html#isBitmapScalable">TQFontDatabase::isBitmapScalable</a>( const TQString & family, const TQString & style, const TQString & ) const
<li> <a href="qfontdatabase.html#isFixedPitch">TQFontDatabase::isFixedPitch</a>( const TQString & family, const TQString & style, const TQString & ) const
<li> <a href="qfontdatabase.html#isScalable">TQFontDatabase::isScalable</a>( const TQString & family, const TQString & style, const TQString & ) const
<li> <a href="qfontdatabase.html#isSmoothlyScalable">TQFontDatabase::isSmoothlyScalable</a>( const TQString & family, const TQString & style, const TQString & ) const
<li> <a href="qfontdatabase.html#italic">TQFontDatabase::italic</a>( const <a href="qstring.html">TQString</a> & family, const TQString & style, const TQString & ) const
<li> <a href="qfontdatabase.html#pointSizes">TQFontDatabase::pointSizes</a>( const TQString & family, const TQString & style, const TQString & )
<li> <a href="qfontdatabase.html#smoothSizes">TQFontDatabase::smoothSizes</a>( const TQString & family, const TQString & style, const TQString & )
<li> <a href="qfontdatabase.html#styles">TQFontDatabase::styles</a>( const TQString & family, const TQString & ) const
<li> <a href="qfontdatabase.html#weight">TQFontDatabase::weight</a>( const TQString & family, const TQString & style, const TQString & ) const
<li> <a href="qlabel.html#autoResize">TQLabel::autoResize</a>() const
<li> <a href="qlabel.html#setAutoResize">TQLabel::setAutoResize</a>( bool enable )
<li> <a href="qlineedit.html#cursorLeft">TQLineEdit::cursorLeft</a>( bool mark, int steps = 1 )
<li> <a href="qlineedit.html#cursorRight">TQLineEdit::cursorRight</a>( bool mark, int steps = 1 )
<li> <a href="qlineedit.html#hasMarkedText">TQLineEdit::hasMarkedText</a>() const
<li> <a href="qlineedit.html#markedText">TQLineEdit::markedText</a>() const
<li> <a href="qlineedit.html#repaintArea">TQLineEdit::repaintArea</a>( int, int )
<li> <a href="qlistbox.html#cellHeight">TQListBox::cellHeight</a>( int i ) const
<li> TQListBox::cellHeight() const
<li> <a href="qlistbox.html#cellWidth">TQListBox::cellWidth</a>() const
<li> <a href="qlistbox.html#findItem">TQListBox::findItem</a>( int yPos ) const
<li> <a href="qlistbox.html#inSort">TQListBox::inSort</a>( const <a href="qlistboxitem.html">TQListBoxItem</a> *lbi )
<li> TQListBox::inSort( const <a href="qstring.html">TQString</a> & text )
<li> <a href="qlistbox.html#itemYPos">TQListBox::itemYPos</a>( int index, int *yPos ) const
<li> <a href="qlistbox.html#numCols">TQListBox::numCols</a>() const
<li> <a href="qlistbox.html#totalHeight">TQListBox::totalHeight</a>() const
<li> <a href="qlistbox.html#totalWidth">TQListBox::totalWidth</a>() const
<li> <a href="qlistboxitem.html#current">TQListBoxItem::current</a>() const
<li> <a href="qlistboxitem.html#selected">TQListBoxItem::selected</a>() const
<li> <a href="qlistview.html#removeItem">TQListView::removeItem</a>( <a href="qlistviewitem.html">TQListViewItem</a> *item )
<li> <a href="qlistviewitem.html#removeItem">TQListViewItem::removeItem</a>( TQListViewItem *item )
<li> <a href="qmainwindow.html#addToolBar">TQMainWindow::addToolBar</a>( <a href="qdockwindow.html">TQDockWindow</a> *, Dock = DockTop, bool newLine = FALSE )
<li> TQMainWindow::addToolBar( TQDockWindow *, const TQString & label, Dock = DockTop, bool newLine = FALSE )
<li> <a href="qmainwindow.html#lineUpToolBars">TQMainWindow::lineUpToolBars</a>( bool keepNewLines = FALSE )
<li> <a href="qmainwindow.html#moveToolBar">TQMainWindow::moveToolBar</a>( TQDockWindow *, Dock = DockTop )
<li> TQMainWindow::moveToolBar( TQDockWindow *, Dock, bool nl, int index, int extraOffset = -1 )
<li> <a href="qmainwindow.html#removeToolBar">TQMainWindow::removeToolBar</a>( TQDockWindow *)
<li> <a href="qmainwindow.html#setToolBarsMovable">TQMainWindow::setToolBarsMovable</a>( bool )
<li> <a href="qmainwindow.html#toolBarPositionChanged">TQMainWindow::toolBarPositionChanged</a>( <a href="qtoolbar.html">TQToolBar</a> *)
<li> <a href="qmainwindow.html#toolBarsMovable">TQMainWindow::toolBarsMovable</a>() const
<li> <a href="qmessagebox.html#message">TQMessageBox::message</a>( const <a href="qstring.html">TQString</a> & caption, const TQString & text, const TQString & buttonText = <a href="qstring.html#TQString-null">TQString::null</a>, <a href="qwidget.html">TQWidget</a> *parent = 0, const char *= 0 )
<li> <a href="qmessagebox.html#query">TQMessageBox::query</a>( const TQString & caption, const TQString & text, const TQString & yesButtonText = TQString::null, const TQString & noButtonText = TQString::null, TQWidget *parent = 0, const char *= 0 )
<li> <a href="qmessagebox.html#standardIcon">TQMessageBox::standardIcon</a>( Icon icon, GUIStyle style )
<li> <a href="qpalette.html#normal">TQPalette::normal</a>()
<li> <a href="qregexp.html#match">TQRegExp::match</a>( const TQString & str, int index = 0, int *len = 0, bool indexIsStart = TRUE ) const
<li> <a href="qscrollview.html#childIsVisible">TQScrollView::childIsVisible</a>( TQWidget *child )
<li> <a href="qscrollview.html#showChild">TQScrollView::showChild</a>( TQWidget *child, bool show = TRUE )
<li> <a href="qsignal.html#block">TQSignal::block</a>( bool b )
<li> <a href="qsignal.html#isBlocked">TQSignal::isBlocked</a>() const
<li> <a href="qsignal.html#parameter">TQSignal::parameter</a>() const
<li> <a href="qsignal.html#setParameter">TQSignal::setParameter</a>( int value )
<li> <a href="qsimplerichtext.html#draw">TQSimpleRichText::draw</a>( <a href="qpainter.html">TQPainter</a> *p, int x, int y, const <a href="qregion.html">TQRegion</a> & clipRegion, const <a href="qcolorgroup.html">TQColorGroup</a> & cg, const <a href="qbrush.html">TQBrush</a> *paper = 0 ) const
<li> <a href="qstring.html#ascii">TQString::ascii</a>() const
<li> <a href="qstring.html#data">TQString::data</a>() const
<li> <a href="qstring.html#setExpand">TQString::setExpand</a>( uint index, <a href="qchar.html">TQChar</a> c )
<li> <a href="qstyle.html#defaultFrameWidth">TQStyle::defaultFrameWidth</a>() const
<li> <a href="qstyle.html#scrollBarExtent">TQStyle::scrollBarExtent</a>() const
<li> <a href="qstyle.html#tabbarMetrics">TQStyle::tabbarMetrics</a>( const <a href="qwidget.html">TQWidget</a> *t, int & hf, int & vf, int & ov ) const
<li> <a href="qtabdialog.html#isTabEnabled">TQTabDialog::isTabEnabled</a>( const char *name ) const
<li> <a href="qtabdialog.html#selected">TQTabDialog::selected</a>( const <a href="qstring.html">TQString</a> & )
<li> TQTabDialog::selected( const TQString & tabLabel )
<li> <a href="qtabdialog.html#setTabEnabled">TQTabDialog::setTabEnabled</a>( const char *name, bool enable )
<li> <a href="qtextstream.html#TQTextStream">TQTextStream::TQTextStream</a>( TQString & str, int filemode )
<li> <a href="qtoolbar.html#TQToolBar">TQToolBar::TQToolBar</a>( const TQString & label, <a href="qmainwindow.html">TQMainWindow</a> *, ToolBarDock = DockTop, bool newLine = FALSE, const char *name = 0 )
<li> <a href="qtoolbutton.html#iconSet">TQToolButton::iconSet</a>( bool on ) const
<li> <a href="qtoolbutton.html#offIconSet">TQToolButton::offIconSet</a>() const
<li> <a href="qtoolbutton.html#onIconSet">TQToolButton::onIconSet</a>() const
<li> <a href="qtoolbutton.html#setIconSet">TQToolButton::setIconSet</a>( const <a href="qiconset.html">TQIconSet</a> & set, bool on )
<li> <a href="qtoolbutton.html#setOffIconSet">TQToolButton::setOffIconSet</a>( const TQIconSet & )
<li> <a href="qtoolbutton.html#setOnIconSet">TQToolButton::setOnIconSet</a>( const TQIconSet & )
<li> <a href="qtooltip.html#enabled">TQToolTip::enabled</a>()
<li> <a href="qtooltip.html#setEnabled">TQToolTip::setEnabled</a>( bool enable )
<li> <a href="qtranslator.html#find">TQTranslator::find</a>( const char *context, const char *sourceText, const char *comment = 0 ) const
<li> <a href="qtranslator.html#insert">TQTranslator::insert</a>( const char *context, const char *sourceText, const <a href="qstring.html">TQString</a> & translation )
<li> <a href="qtranslator.html#remove">TQTranslator::remove</a>( const char *context, const char *sourceText )
<li> <a href="quridrag.html#setFilenames">TQUriDrag::setFilenames</a>( const <a href="qstringlist.html">TQStringList</a> & fnames )
<li> <a href="qwidget.html#backgroundColor">TQWidget::backgroundColor</a>() const
<li> <a href="qwidget.html#backgroundPixmap">TQWidget::backgroundPixmap</a>() const
<li> <a href="qwidget.html#iconify">TQWidget::iconify</a>()
<li> <a href="qwidget.html#setBackgroundColor">TQWidget::setBackgroundColor</a>( const <a href="qcolor.html">TQColor</a> & c )
<li> <a href="qwidget.html#setBackgroundPixmap">TQWidget::setBackgroundPixmap</a>( const <a href="qpixmap.html">TQPixmap</a> & pm )
<li> <a href="qwidget.html#setFont">TQWidget::setFont</a>( const <a href="qfont.html">TQFont</a> & f, bool )
<li> <a href="qwidget.html#setPalette">TQWidget::setPalette</a>( const <a href="qpalette.html">TQPalette</a> & p, bool )
<li> <a href="qwizard.html#setFinish">TQWizard::setFinish</a>( <a href="qwidget.html">TQWidget</a> *, bool )
<li> <a href="qxmlinputsource.html#TQXmlInputSource">TQXmlInputSource::TQXmlInputSource</a>( <a href="qfile.html">TQFile</a> & file )
<li> TQXmlInputSource::TQXmlInputSource( <a href="qtextstream.html">TQTextStream</a> & stream )
<li> <a href="qxmlreader.html#parse">TQXmlReader::parse</a>( const <a href="qxmlinputsource.html">TQXmlInputSource</a> & input )
</ul>
<p> Additionally, these preprocessor directives have been removed:
<p> <ul>
<li> <tt>#define strlen qstrlen</tt>
<li> <tt>#define strcpy qstrcpy</tt>
<li> <tt>#define strcmp qstrcmp</tt>
<li> <tt>#define strncmp qstrncmp</tt>
<li> <tt>#define stricmp qstricmp</tt>
<li> <tt>#define strnicmp qstrnicmp</tt>
</ul>
<p> See the changes-3.0.0 document for an explanation of why this had to be done.
You might have been relying on the non-portable and unpredictable behavior
resulting from these directives. We strongly recommend that you either make
use of the safe qstr* variants directly or ensure that no 0 pointer is
passed to the standard C functions in your code base.
<p> <h2> Collection Class Renaming
</h2>
<a name="6"></a><p> The classes TQArray, TQCollection, TQList, TQListIterator, TQQueue, TQStack
and TQVector have been renamed. To ease porting, the old names and the
old header-file names are still supported.
<p> <center><table cellpadding="4" cellspacing="2" border="0">
<tr bgcolor="#a2c511"> <th valign="top">Old Name <th valign="top">New Name <th valign="top">New Header File
<tr bgcolor="#f0f0f0"> <td valign="top">TQArray <td valign="top"><a href="qmemarray.html">TQMemArray</a> <td valign="top"><tt><qmemarray.h></tt>
<tr bgcolor="#d0d0d0"> <td valign="top">TQCollection <td valign="top"><a href="qptrcollection.html">TQPtrCollection</a> <td valign="top"><tt><qptrcollection.h></tt>
<tr bgcolor="#f0f0f0"> <td valign="top">TQList <td valign="top"><a href="qptrlist.html">TQPtrList</a> <td valign="top"><tt><qptrlist.h></tt>
<tr bgcolor="#d0d0d0"> <td valign="top">TQListIterator <td valign="top"><a href="qptrlistiterator.html">TQPtrListIterator</a> <td valign="top"><tt><qptrlist.h></tt>
<tr bgcolor="#f0f0f0"> <td valign="top">TQQueue <td valign="top"><a href="qptrqueue.html">TQPtrQueue</a> <td valign="top"><tt><qptrqueue.h></tt>
<tr bgcolor="#d0d0d0"> <td valign="top">TQStack <td valign="top"><a href="qptrstack.html">TQPtrStack</a> <td valign="top"><tt><qptrstack.h></tt>
<tr bgcolor="#f0f0f0"> <td valign="top">TQVector <td valign="top"><a href="qptrvector.html">TQPtrVector</a> <td valign="top"><tt><qptrvector.h></tt>
</table></center>
<p> <h2> <a href="qbuttongroup.html">TQButtonGroup</a>
</h2>
<a name="7"></a><p> In TQt 2.x, the function <a href="qbuttongroup.html#selected">TQButtonGroup::selected</a>() returns the selected
<em>radio</em> button (<a href="qradiobutton.html">TQRadioButton</a>). In TQt 3.0, it returns the selected <em>toggle</em> button (<a href="qbutton.html#toggleButton-prop">TQButton::toggleButton</a>), a more general concept.
This might affect programs that use TQButtonGroups that contain a
mixture of radio buttons and non-radio (e.g. <a href="qcheckbox.html">TQCheckBox</a>) toggle buttons.
<p> <h2> <a href="qdate.html">TQDate</a>
</h2>
<a name="8"></a><p> Two TQDate member functions that were virtual in TQt 2.0 are not virtual
in TQt 3.0. This is only relevant if you subclassed TQDate and
reimplemented these functions:
<p> <ul>
<li> <a href="qstring.html">TQString</a> <a href="qdate.html#monthName">TQDate::monthName</a>( int month ) const
<li> TQString <a href="qdate.html#dayName">TQDate::dayName</a>( int weekday ) const
</ul>
<p> In addition to no longer being virtual, TQDate::monthName() and
TQDate::dayName() have been renamed <a href="qdate.html#shortMonthName">TQDate::shortMonthName</a>() and
<a href="qdate.html#shortDayName">TQDate::shortDayName</a>() and have been made static (as they should had
been in the first place). The old names are still provided for source
compatibility.
<p> <h2> <a href="qfiledialog.html">TQFileDialog</a>
</h2>
<a name="9"></a><p> If the mode was not set explicitly, and the user entered a
non-existent file, the dialog would accept this. In TQt 3.x, you must
set the mode, e.g. setMode(TQFileDialog::AnyFile), to get the same
behavior.
<p> <h2> <a href="qfont.html">TQFont</a>
</h2>
<a name="10"></a><p> The internals of TQFont have changed significantly between TQt 2.2 and
TQt 3.0, to give better Unicode support and to make developing
internationalized applications easier. The original API has been
preserved with minimal changes. The CharSet enum and its related
functions have disappeared. This is because TQt now handles all charset
related issues internally, and removes this burden from the developer.
<p> If you used the CharSet enum or its related functions, e.g
TQFont::charSet() or TQFont::setCharSet(), just remove them from your
code. There are a few functions that took a TQFont::CharSet as a
parameter; in these cases simply remove the charset from the
parameter list.
<p> <h2> <a href="qinputdialog.html">TQInputDialog</a>
</h2>
<a name="11"></a><p> The two static getText(...) methods in TQInputDialog have been merged.
The <tt>echo</tt> parameter is the third parameter and defaults to
TQLineEdit::Normal.
<p> If you used calls to <a href="qinputdialog.html#getText">TQInputDialog::getText</a>(...) that provided more
than the first two required parameters you will must add a value
for the <tt>echo</tt> parameter.
<p> <h2> <a href="qlayout.html">TQLayout</a> and Other Abstract Layout Classes
</h2>
<a name="12"></a><p> The definitions of <a href="qglayoutiterator.html">TQGLayoutIterator</a>, <a href="qlayout.html">TQLayout</a>, <a href="qlayoutitem.html">TQLayoutItem</a>, <a href="qlayoutiterator.html">TQLayoutIterator</a>, <a href="qspaceritem.html">TQSpacerItem</a> and <a href="qwidgetitem.html">TQWidgetItem</a> have been moved from <tt><qabstractlayout.h></tt> to <tt><qlayout.h></tt>. The header <tt><qabstractlayout.h></tt> now includes <tt><qlayout.h></tt> for compatibility. It
might be removed in a future version.
<p> <h2> <a href="qlistviewitem.html">TQListViewItem</a>
</h2>
<a name="13"></a><p> The paintBranches() function in TQt 2.x had a GUIStyle parameter; this
has been dropped for TQt 3.x since GUI style is handled by the new
style engine (See <a href="qstyle.html">TQStyle</a>.)
<p> <h2> <a href="qmoveevent.html">TQMoveEvent</a>
</h2>
<a name="14"></a><p> In TQt 2.x, the function <a href="qmoveevent.html#pos">TQMoveEvent::pos</a>() returned the position of the
widget in its parent widget, including the window frame. In TQt 3.0,
it returns the new position of the widget, excluding window frame for
top level widgets.
<p> <h2> TQMultiLineEdit
</h2>
<a name="15"></a><p> The TQMultiLineEdit was a simple editor widget in previous TQt versions.
Since TQt 3.0 includes a new richtext engine, which also supports
editing, TQMultiLineEdit is obsolete. For the sake of compatibility
TQMultiLineEdit is still provided. It is now a subclass of <a href="qtextedit.html">TQTextEdit</a>
which wraps the old TQMultiLineEdit so that it is mostly source
compatible to keep old applications working.
<p> For new applications and when maintaining existing applications we
recommend that you use TQTextEdit instead of TQMultiLineEdit wherever
possible.
<p> Although most of the old TQMultiLineEdit API is still available, there
is one important difference. The old TQMultiLineEdit operated in terms
of lines, whereas TQTextEdit operates in terms of paragraphs. This is
because lines change all the time during wordwrap, whereas paragraphs
remain paragraphs. The consequence of this change is that functions
which previously operated on lines, e.g. numLines(), textLine(), etc.,
now work on paragraphs.
<p> Also the function getString() has been removed since it
published the internal data structure.
<p> In most cases, applications that used TQMultiLineEdit will continue to
work without problems. Applications that worked in terms of lines may
require some porting.
<p> The source code for the old 2.x version of TQMultiLineEdit can be found
in <tt>$QTDIR/src/attic/qtmultilineedit.h/cpp</tt>. Note that the class has
been renamed to TQtMultiLineEdit to avoid name clashes. If you really
need to keep compatibility with the old TQMultiLineEdit, simply include
this class in your project and rename TQMultiLineEdit to
TQtMultiLineEdit throughout.
<p> <h2> <a href="qprinter.html">TQPrinter</a>
</h2>
<a name="16"></a><p> TQPrinter has undergone some changes, to make it more flexible and
to ensure it has the same runtime behaviour on both Unix and Windows. In 2.x,
TQPrinter behaved differently on Windows and Unix, when using view
transformations on the <a href="qpainter.html">TQPainter</a>. This has changed now, and TQPrinter
behaves consistently across all platforms. A compatibilty mode has been
added that forces the old behaviour, to ease porting from TQt 2.x
to TQt 3.x. This compatibilty mode can be enabled by passing the
TQPrinter::Compatible flag to the TQPrinter constructor.
<p> On X11, TQPrinter used to generate encapsulated postscript when
fullPage() was TRUE and only one page was printed. This does not
happen by default anymore, providing a more consistent printing output.
<p> <h2> <a href="qregexp.html">TQRegExp</a>
</h2>
<a name="17"></a><p> The <a href="qregexp.html">TQRegExp</a> class has been rewritten to support many of the features of Perl
regular expressions. Both the <a href="qregexp.html#regular-expression">regular expression</a> syntax and the TQRegExp
interface have been modified.
<p> Be also aware that <tt><qregexp.h></tt> is no longer included
automatically when you include <tt><qstringlist.h></tt>. See
<a href="#Headers">above</a> for details.
<p>
<p> <h3> New special characters
</h3>
<a name="17-1"></a><p> There are five new special characters: <tt>(</tt>, <tt>)</tt>, <tt>{</tt>,
<tt>|</tt> and <tt>}</tt> (parentheses, braces and pipe). When porting old
regular expressions, you must add <tt>\</tt> (backslash) in front of any
of these (actually, <tt>\\</tt> in C++ strings), unless it is already
there.
<p> Example: Old code like
<pre>
<a href="qregexp.html">TQRegExp</a> rx( "([0-9|]*\\)" ); // works in TQt 2.x
</pre>
should be converted into
<pre>
<a href="qregexp.html">TQRegExp</a> rx( "\\([0-9\\|]*\\)" ); // works in TQt 2.x and 3.x
</pre>
(Within character classes, the backslash is not necessary in front of certain
characters, e.g. <tt>|</tt>, but it doesn't hurt.)
<p> Wildcard patterns need no conversion. Here are two examples:
<pre>
<a href="qregexp.html">TQRegExp</a> wild( "(*.*)" );
wild.<a href="qregexp.html#setWildcard">setWildcard</a>( TRUE );
</pre>
<pre>
// TRUE as third argument means wildcard
<a href="qregexp.html">TQRegExp</a> wild( "(*.*)", FALSE, TRUE );
</pre>
However, when they are used, make sure to use <a href="qregexp.html#exactMatch">TQRegExp::exactMatch</a>()
rather than the obsolete <a href="qregexp.html#match">TQRegExp::match</a>(). TQRegExp::match(), like
TQRegExp::find(), tries to find a match somewhere in the target
string, while TQRegExp::exactMatch() tries to match the whole target
string.
<p> <h3> <a href="qregexp.html#operator-eq">TQRegExp::operator=</a>()
</h3>
<a name="17-2"></a><p> This function has been replaced by <a href="qregexp.html#setPattern">TQRegExp::setPattern</a>() in TQt 2.2.
Old code such as
<pre>
<a href="qregexp.html">TQRegExp</a> rx( "alpha" );
rx.<a href="qregexp.html#setCaseSensitive">setCaseSensitive</a>( FALSE );
rx.<a href="qregexp.html#setWildcard">setWildcard</a>( TRUE );
rx = "beta";
</pre>
still compiles with TQt 3, but produces a different result (the case sensitivity
and wildcard options are forgotten). This way,
<pre>
rx = "beta";
</pre>
is the same as
<pre>
rx = TQRegExp( "beta" );
</pre>
which is what one expects.
<p> <h3> TQRegExp::match()
</h3>
<a name="17-3"></a><p> The following function is now obsolete, as it has an unwieldy
parameter list and was poorly named:
<ul>
<li> bool <a href="qregexp.html#match">TQRegExp::match</a>( const <a href="qstring.html">TQString</a> & str, int index = 0,
int * len = 0, bool indexIsStart = TRUE ) const
</ul>
It will be removed in a future version of TQt. Its <a href="qregexp.html#match">documentation</a> explains how to replace it.
<p> <h3> TQRegExp::find()
</h3>
<a name="17-4"></a><p> This function was removed, after a brief appearance in TQt 2.2. Its
name clashed with <a href="qstring.html#find">TQString::find</a>(). Use <a href="qregexp.html#search">TQRegExp::search</a>() or <a href="qstring.html#find">TQString::find</a>() instead.
<p> <h3> <a href="qstring.html#findRev">TQString::findRev</a>() and <a href="qstring.html#contains">TQString::contains</a>()
</h3>
<a name="17-5"></a><p> <a href="qstring.html#findRev">TQString::findRev</a>()'s and <a href="qstring.html#contains">TQString::contains</a>()'s semantics have changed
between 2.0 and 3.0 to be more consistent with the other overloads.
<p> For example,
<pre>
TQString( "" ).contains( TQRegExp("") )
</pre>
returns 1 in TQt 2.0; it returns 0 in TQt 3.0. Also, "^" now really means
start of input, so
<pre>
TQString( "Heisan Hoppsan" ).contains( TQRegExp("^.*$") )
</pre>
returns 1, not 13 or 14.
<p> This change affect very few existing programs.
<p> <h3> <a href="qstring.html#replace">TQString::replace</a>()
</h3>
<a name="17-6"></a><p> With TQt 1.0 and 2.0, a <a href="qstring.html">TQString</a> is converted implicitly into a <a href="qregexp.html">TQRegExp</a>
as the first argument to TQString::replace():
<pre>
<a href="qstring.html">TQString</a> text = fetch_it_from_somewhere();
text.<a href="qstring.html#replace">replace</a>( TQString("[A-Z]+"), "" );
</pre>
With TQt 3.0, the compiler gives an error. The solution is to use a
TQRegExp cast:
<pre>
text.replace( TQRegExp("[A-Z]+"), "" );
</pre>
This change makes it possible to introduce a
TQString::replace(TQString, TQString) overload in a future version of TQt
without breaking source compatibility.
<p> <h2> TQSemiModal
</h2>
<a name="18"></a><p> The TQSemiModal class is now obsolete. You should call show() on a
modal dialog instead.
<p> <h2> TQSortedList
</h2>
<a name="19"></a><p> The TQSortedList class is now obsolete. Consider using a <a href="qdict.html">TQDict</a>, a <a href="qmap.html">TQMap</a>
or a plain <a href="qptrlist.html">TQPtrList</a> instead.
<p> <h2> TQTableView
</h2>
<a name="20"></a><p> The TQTableView class has been obsoleted and is no longer a part of the
TQt API. Either use the powerful <a href="qtable.html">TQTable</a> class or the simplistic
<a href="qgridview.html">TQGridView</a> in any new code you create. If you really need the old table
view for compatibility you can find it in <tt>$QTDIR/src/attic/qttableview.{cpp,h}</tt>. Note that the class has been
renamed from TQTableView to TQtTableView to avoid name clashes. To use
it, simply include it in your project and rename TQTableView to
TQtTableView throughout.
<p> <h2> <a href="qtoolbutton.html">TQToolButton</a>
</h2>
<a name="21"></a><p> The <a href="qtoolbutton.html">TQToolButton</a> class used to distinguish between "on" and "off"
icons. In 3.0, this mechanism was moved into the <a href="qiconset.html">TQIconSet</a> class
(see <a href="qiconset.html#State-enum">TQIconSet::State</a>).
<p> The old <a href="qtoolbutton.html#onIconSet-prop">TQToolButton::onIconSet</a> and <a href="qtoolbutton.html#offIconSet-prop">TQToolButton::offIconSet</a>
properties are still provided so that old source will compile, but
their semantics have changed: they are now synonyms for <a href="qtoolbutton.html#iconSet-prop">TQToolButton::iconSet</a>. If you used that distinction in TQt 2.x, you will
need to adjust your code to use the <a href="qiconset.html">TQIconSet</a> On/Off mechanism.
<p> Likewise, the <em>on</em> parameter of these two functions is now ignored:
<p> <ul>
<li> void TQToolButton::setIconSet ( const TQIconSet & set, bool on )
<li> TQIconSet TQToolButton::iconSet ( bool on ) const
</ul>
<p> These functions are only provided for ease of porting. New code
should use the following instead:
<p> <ul>
<li> void <a href="qtoolbutton.html#setIconSet">TQToolButton::setIconSet</a>( const TQIconSet & set )
<li> TQIconSet <a href="qtoolbutton.html#iconSet">TQToolButton::iconSet</a>() const
</ul>
<p> Finally, this function is no longer virtual:
<p> <ul>
<li> void TQToolButton::setIconSet( const TQIconSet & set, bool on )
</ul>
<p> If you have a class that inherits <a href="qtoolbutton.html">TQToolButton</a> and that reimplements
TQToolButton::setIconSet(), you should make the signature of the
reimplementation agree with the new <a href="qtoolbutton.html#setIconSet">TQToolButton::setIconSet</a>(),
a virtual function.
<p> <h2> <a href="qtextstream.html">TQTextStream</a>
</h2>
<a name="22"></a><p> The global TQTextStream manipulators setw(), setfill() and setprecison()
were renamed to qSetW(), qSetFill() and qSetPrecision() to avoid conflicts
with <tt><iostream.h></tt>. If you used them, you must rename the occurrences to
the new names.
<p> <h2> <a href="qtranslator.html">TQTranslator</a>
</h2>
<a name="23"></a><p> The <a href="qtranslator.html">TQTranslator</a> class was extended in TQt 2.2, and these extensions
lead to a new interface. This interface is used mainly by translation
tools (for example, <a href="linguist-manual.html">TQt
Linguist</a>). For source compatibility, no member function was
effectively removed. The <a href="qtranslator.html">TQTranslator</a> documentation points out
which functions are obsolete.
<p> This function is no longer virtual:
<p> <ul>
<li> <a href="qstring.html">TQString</a> <a href="qtranslator.html#find">TQTranslator::find</a>( const char * context,
const char * sourceText ) const
</ul>
<p> If you have a class that inherits TQTranslator and which reimplements
TQTranslator::find(), you should reimplement <a href="qtranslator.html#findMessage">TQTranslator::findMessage</a>() instead.
In fact, find() is now defined in terms of findMessage(). By doing the
conversion, you will also gain support for translator comments and for any
future extensions.
<p> <h2> <a href="qwidget.html">TQWidget</a>
</h2>
<a name="24"></a><p> <a href="qwidget.html#backgroundColor">TQWidget::backgroundColor</a>(), <a href="qwidget.html#setBackgroundColor">TQWidget::setBackgroundColor</a>(),
<a href="qwidget.html#backgroundPixmap">TQWidget::backgroundPixmap</a>() and <a href="qwidget.html#setBackgroundPixmap">TQWidget::setBackgroundPixmap</a>() have
often been the source of much confusion in previous releases. TQt 3.0
addresses this by obsoleting these functions and by replacing them
with eight new functions: <a href="qwidget.html#eraseColor">TQWidget::eraseColor</a>(),
<a href="qwidget.html#setEraseColor">TQWidget::setEraseColor</a>(), <a href="qwidget.html#erasePixmap">TQWidget::erasePixmap</a>(),
<a href="qwidget.html#setErasePixmap">TQWidget::setErasePixmap</a>(), <a href="qwidget.html#paletteBackgroundColor">TQWidget::paletteBackgroundColor</a>(),
<a href="qwidget.html#setPaletteBackgroundColor">TQWidget::setPaletteBackgroundColor</a>(),
<a href="qwidget.html#paletteBackgroundPixmap">TQWidget::paletteBackgroundPixmap</a>() and
<a href="qwidget.html#setPaletteBackgroundPixmap">TQWidget::setPaletteBackgroundPixmap</a>(). See their documentation for
details.
<p> <h2> TQXml Classes
</h2>
<a name="25"></a><p> <h3> <a href="qxmlinputsource.html">TQXmlInputSource</a>
</h3>
<a name="25-1"></a><p> The semantics of TQXmlInputSource has changed slightly. This change
only affects code that parses the same data from the same input source
multiple times. In such cases you must call
<a href="qxmlinputsource.html#reset">TQXmlInputSource::reset</a>() before the second call to
<a href="qxmlsimplereader.html#parse">TQXmlSimpleReader::parse</a>().
<p> So code like
<pre>
<a href="qxmlinputsource.html">TQXmlInputSource</a> source( &xmlFile );
<a href="qxmlsimplereader.html">TQXmlSimpleReader</a> reader;
...
reader.<a href="qxmlsimplereader.html#parse">parse</a>( source );
...
reader.<a href="qxmlsimplereader.html#parse">parse</a>( source );
</pre>
must be changed to
<pre>
<a href="qxmlinputsource.html">TQXmlInputSource</a> source( &xmlFile );
<a href="qxmlsimplereader.html">TQXmlSimpleReader</a> reader;
...
reader.<a href="qxmlsimplereader.html#parse">parse</a>( source );
...
source.<a href="qxmlinputsource.html#reset">reset</a>();
reader.<a href="qxmlsimplereader.html#parse">parse</a>( source );
</pre>
<p> <h3> <a href="qxmllocator.html">TQXmlLocator</a>
</h3>
<a name="25-2"></a><p> Due to some internal changes, it was necessary to clean-up the semantics of
TQXmlLocator: this class is now an abstract class. This shouldn't cause
any problems, since programmers usually used the TQXmlLocator that was
reported by <a href="qxmlcontenthandler.html#setDocumentLocator">TQXmlContentHandler::setDocumentLocator</a>(). If you used this
class in some other way, you must adjust your code to use the
TQXmlLocator that is reported by the
TQXmlContentHandler::setDocumentLocator() function.
<p> <h2> Asynchronous I/O Classes
</h2>
<a name="26"></a><p> TQASyncIO, TQDataSink, TQDataSource, TQIODeviceSource and TQDataPump were
used internally in previous versions of TQt, but are not used anymore.
They are now obsolete.
<p> <h2> Transparent widgets
</h2>
<a name="27"></a><p> In TQt 2.x, the AutoMask property was used to obtain a
transparent-looking widget. In general, this approach is slow and
processor hungry. TQt 3.0 uses the BackgroundOrigin which provides
vastly improved performance and more flexibility in most cases. The
few classes for which the AutoMask property is still the best approach
are <a href="qcheckbox.html">TQCheckBox</a>, <a href="qcombobox.html">TQComboBox</a>, <a href="qpushbutton.html">TQPushButton</a>, <a href="qradiobutton.html">TQRadioButton</a> and <a href="qtabwidget.html">TQTabWidget</a>.
<p> <h2> Bezier Curves
</h2>
<a name="28"></a><p> The function names for Bezier curves in <a href="qpainter.html">TQPainter</a> and <a href="qpointarray.html">TQPointArray</a> have
been corrected. They now properly reflect their cubic form instead of
a quadratic one. If you have been using either
TQPainter::drawQuadBezier() or TQPointArray::quadBezier() you must
replace these calls with
<ul>
<li> void <a href="qpainter.html#drawCubicBezier">TQPainter::drawCubicBezier</a>( const TQPointArray &, int index=0 ) and
<li> TQPointArray <a href="qpointarray.html#cubicBezier">TQPointArray::cubicBezier</a>() const
</ul>
respectively. Neither the arguments nor the resulting curve have changed.
<p> <h2> Locale-aware String Comparisons in <a href="qiconview.html">TQIconView</a>, <a href="qlistbox.html">TQListBox</a>,
<a href="qlistview.html">TQListView</a> and <a href="qtable.html">TQTable</a>
</h2>
<a name="29"></a><p> In TQt 2.x, <a href="qstring.html">TQString</a> only provided string comparisons using the Unicode
values of the characters of a string. This is efficient and reliable,
but it is not the appropriate order for most languages. For example,
French users expect 'é' (e acute) to be treated essentially as
'e' and not put after 'z'.
<p> In TQt 3.0, <a href="qstring.html#localeAwareCompare">TQString::localeAwareCompare</a>() implements locale aware
string comparisions on certain platforms. The classes <a href="qiconview.html">TQIconView</a>, <a href="qlistbox.html">TQListBox</a>, <a href="qlistview.html">TQListView</a> and <a href="qtable.html">TQTable</a> now use
TQString::localeAwareCompare() instead of <a href="qstring.html#compare">TQString::compare</a>(). If you
want to control the behaviour yourself you can always reimplement
<a href="qiconviewitem.html#compare">TQIconViewItem::compare</a>(), <a href="qlistbox.html#text">TQListBox::text</a>(), <a href="qlistviewitem.html#compare">TQListViewItem::compare</a>()
or <a href="qtableitem.html#key">TQTableItem::key</a>() as appropriate.
<p>
<!-- eof -->
<p><address><hr><div align=center>
<table width=100% cellspacing=0 border=0><tr>
<td>Copyright © 2007
<a href="troll.html">Trolltech</a><td align=center><a href="trademarks.html">Trademarks</a>
<td align=right><div align=right>TQt 3.3.8</div>
</table></div></address></body>
</html>
|