Browse Source

Sync with latest script

tags/r14.0.0
Timothy Pearson 8 years ago
parent
commit
e02e31c8b9
100 changed files with 235 additions and 235 deletions
  1. +13
    -13
      ChangeLog.immodule
  2. +3
    -3
      LICENSE.GPL2
  3. +17
    -17
      LICENSE.GPL3
  4. +1
    -1
      LICENSE.QPL
  5. +1
    -1
      README.immodule
  6. +4
    -4
      changes.immodule
  7. +1
    -1
      config.tests/unix/ipv6/ipv6test.cpp
  8. +1
    -1
      config.tests/x11/opengl.test
  9. +1
    -1
      config.tests/x11/xcursor.test
  10. +1
    -1
      config.tests/x11/xrandr.test
  11. +1
    -1
      configure
  12. +1
    -1
      doc/3rdparty.doc
  13. +1
    -1
      doc/accel.doc
  14. +1
    -1
      doc/annotated.doc
  15. +2
    -2
      doc/application-walkthrough.doc
  16. +2
    -2
      doc/canvas.doc
  17. +2
    -2
      doc/changes.doc
  18. +1
    -1
      doc/charinput-qws.doc
  19. +1
    -1
      doc/classchart.doc
  20. +1
    -1
      doc/classes.doc
  21. +1
    -1
      doc/collect.doc
  22. +1
    -1
      doc/commercialeditions.doc
  23. +1
    -1
      doc/coordsys.doc
  24. +1
    -1
      doc/credits.doc
  25. +1
    -1
      doc/customstyles.doc
  26. +1
    -1
      doc/datastreamformat.doc
  27. +1
    -1
      doc/debug.doc
  28. +3
    -3
      doc/distributingqt.doc
  29. +1
    -1
      doc/dnd.doc
  30. +1
    -1
      doc/editions.doc
  31. +2
    -2
      doc/embclasses.doc
  32. +1
    -1
      doc/embporting.doc
  33. +1
    -1
      doc/envvars.doc
  34. +2
    -2
      doc/faq.doc
  35. +1
    -1
      doc/features.doc
  36. +1
    -1
      doc/focus.doc
  37. +1
    -1
      doc/framebuffer-howto.doc
  38. +1
    -1
      doc/functions.doc
  39. +1
    -1
      doc/headers.doc
  40. +1
    -1
      doc/hierarchy.doc
  41. +1
    -1
      doc/how-to-learn-qt.doc
  42. +2
    -2
      doc/html/activeqt-dotnet.html
  43. +1
    -1
      doc/html/activeqt-tools-idc.html
  44. +1
    -1
      doc/html/activeqt-tools-testcon.html
  45. +1
    -1
      doc/html/assistant-6.html
  46. +1
    -1
      doc/html/canvas.html
  47. +1
    -1
      doc/html/commonproblems.html
  48. +1
    -1
      doc/html/customlayout.html
  49. +3
    -3
      doc/html/designer-manual-1.html
  50. +4
    -4
      doc/html/designer-manual-13.html
  51. +1
    -1
      doc/html/designer-manual-14.html
  52. +2
    -2
      doc/html/designer-manual-16.html
  53. +6
    -6
      doc/html/designer-manual-3.html
  54. +1
    -1
      doc/html/designer-manual-4.html
  55. +3
    -3
      doc/html/designer-manual-5.html
  56. +4
    -4
      doc/html/designer-manual-6.html
  57. +9
    -9
      doc/html/designer-manual-7.html
  58. +13
    -13
      doc/html/designer-manual-8.html
  59. +3
    -3
      doc/html/designer-manual-9.html
  60. +2
    -2
      doc/html/distributingqt.html
  61. +1
    -1
      doc/html/emb-classes.html
  62. +1
    -1
      doc/html/emb-performance.html
  63. +2
    -2
      doc/html/emb-porting.html
  64. +1
    -1
      doc/html/emb-running.html
  65. +2
    -2
      doc/html/faq.html
  66. +3
    -3
      doc/html/gpl.html
  67. +1
    -1
      doc/html/helpsystem-example.html
  68. +5
    -5
      doc/html/i18n.html
  69. +1
    -1
      doc/html/keyfeatures30.html
  70. +5
    -5
      doc/html/layout.html
  71. +1
    -1
      doc/html/license.html
  72. +2
    -2
      doc/html/licenses.html
  73. +2
    -2
      doc/html/linguist-manual-1.html
  74. +3
    -3
      doc/html/linguist-manual-2.html
  75. +2
    -2
      doc/html/linguist-manual-3.html
  76. +4
    -4
      doc/html/linguist-manual-4.html
  77. +2
    -2
      doc/html/mac-differences.html
  78. +3
    -3
      doc/html/moc.html
  79. +1
    -1
      doc/html/motif-walkthrough-10.html
  80. +2
    -2
      doc/html/motif-walkthrough-3.html
  81. +3
    -3
      doc/html/motif-walkthrough.html
  82. +1
    -1
      doc/html/network.html
  83. +2
    -2
      doc/html/object.html
  84. +1
    -1
      doc/html/opengl-x11-overlays.html
  85. +2
    -2
      doc/html/opengl.html
  86. +1
    -1
      doc/html/picture-example.html
  87. +7
    -7
      doc/html/plugins-howto.html
  88. +2
    -2
      doc/html/porting.html
  89. +3
    -3
      doc/html/porting2.html
  90. +16
    -16
      doc/html/propertydocs
  91. +1
    -1
      doc/html/qaccel-h.html
  92. +1
    -1
      doc/html/qaccessible-h.html
  93. +1
    -1
      doc/html/qaction-h.html
  94. +1
    -1
      doc/html/qapplication-h.html
  95. +4
    -4
      doc/html/qapplication.html
  96. +1
    -1
      doc/html/qasciicache-h.html
  97. +1
    -1
      doc/html/qasciidict-h.html
  98. +1
    -1
      doc/html/qassistantclient-h.html
  99. +1
    -1
      doc/html/qassistantclient.html
  100. +1
    -1
      doc/html/qasyncimageio-h.html

+ 13
- 13
ChangeLog.immodule View File

@@ -121,7 +121,7 @@
- (removePostedEvents): New overriding function. This function only
removes events that has specified event type. The implementation
is copied from original version of the function and modified to
accept event_type. This function is retquired by postIMEvent()
accept event_type. This function is required by postIMEvent()
- (setActiveWindow): Enclose immodule specific code by #if
defined(Q_WS_X11)
@@ -138,12 +138,12 @@
- Remove #include "qinputcontext.h" to reduce compilation dependency
- Add 'class QWidget' declaration
- Remove inappropriate #ifndef QT_NO_STRINGLIST. QStringList is now
retquired feature for immodule. See also changes of qfeatures.h
required feature for immodule. See also changes of qfeatures.h
* src/input/qinputcontextfactory.cpp
- Add #include "qinputcontext.h"
- Remove unnecessary #include "qpopupmenu.h"
- Remove inappropriate #ifndef QT_NO_STRINGLIST. QStringList is now
retquired feature for immodule. See also changes of qfeatures.h
required feature for immodule. See also changes of qfeatures.h
* src/tools/qfeatures.h
- Define QT_NO_IM if QT_NO_STRINGLIST is defined
@@ -492,7 +492,7 @@
- Follow Trolltech's coding style for Qt3
- Remove unnecessary headers
- (UNITIZE): Moved from qsimpleinputcontext.cpp. QT_ prefix is not
retquired since a macro does not pollute symbol space
required since a macro does not pollute symbol space
- (struct _ComposeTableElement): Rename to QComposeTableElement
- (struct QComposeTableElement): Renamed from _ComposeTableElement
- (struct _ComposeTable): Rename to QComposeTable
@@ -553,7 +553,7 @@
2004-08-10 YamaKen <yamaken@bp.iij4u.or.jp>
* This commit changes the XIM input method into plugin. A little
modification is still retquired to work. See next commit information
modification is still required to work. See next commit information
* src/input/qinputcontextfactory.cpp
- Remove XIM dependency
@@ -581,7 +581,7 @@
- New file
* plugins/src/inputmethods/xim/qximinputcontext.h
- Moved from src/input/qximinputcontext_p.h. No code changes have
been applied. A little modification is retquired to work. See next
been applied. A little modification is required to work. See next
commit information
* plugins/src/inputmethods/xim/qximinputcontext_x11.cpp
- Moved from src/input/qximinputcontext_x11.cpp. No code changes have
@@ -606,7 +606,7 @@
- (setHolderWidget): New override function
* src/input/qximinputcontext_x11.cpp
- (QXIMInputContext): Split most part of the initialization code
into setHolderWidget() to allow null widget. This is retquired to
into setHolderWidget() to allow null widget. This is required to
make imsw-none working properly
- (setHolderWidget): New function
@@ -1034,7 +1034,7 @@
- (class QInputContext): Modify the class description comment
- (filterEvent): Mark the argument as /* const */ to make it const
in future
- (reset): Add a retquirement to the function description comment for
- (reset): Add a requirement to the function description comment for
reimplementation
* src/kernel/qapplication_x11.cpp
@@ -1581,7 +1581,7 @@

* src/kernel/qwidget_x11.cpp
- (setMicroFocusHint): Replace relative coordinate with
global one for qic->setMicroFocus(). This is retquired to
global one for qic->setMicroFocus(). This is required to
share particular IM plugin code with Qt/Embedded

* src/widgets/qlineedit.cpp
@@ -1679,7 +1679,7 @@
* src/kernel/qinputcontext.h
- Remove several pointers to QWidget to share concrete IM
implementation code with Qt/Embedded. The IM model of
Qt/Embedded retquires that widgets and input contexts are
Qt/Embedded requires that widgets and input contexts are
existing in another process
- (QInputContext): Remove the QWidget * arg
- (focusWidget, ownerWidget):
@@ -1723,7 +1723,7 @@
- (filterEvent): Follow API change of removal of keywidget
- (sendIMEvent): Add #ifdef to isolate Qt/X11 dependent code
- (sendIMError): New function to hide ownerWidget() from
derived QInputContext. This is retquired to share particular
derived QInputContext. This is required to share particular
IM plugin code with Qt/Embedded
- (setFocus, unsetFocus): Follow API change

@@ -1739,7 +1739,7 @@
focusInputContext()
- (getInputContext): Return input context only if
isInputMethodEnabled() widget, otherwise returns 0. This
is retquired for proper focus transition handling
is required for proper focus transition handling
- (unfocusInputContext): Follow API change of
QInputContext::unsetFocus()

@@ -1942,7 +1942,7 @@
invocation to follow API change
- (translateKeyEventInternal):
* Add new arg statefulTranslation to enable duplicate call
within single event loop. This is retquired to support both
within single event loop. This is required to support both
QInputContext::filterEvent() and RTL extensions
* Restore accidencially omitted qt_mode_switch_remove_mask
handling


+ 3
- 3
LICENSE.GPL2 View File

@@ -117,9 +117,9 @@ above, provided that you also meet all of these conditions:
these conditions, and telling the user how to view a copy of this
License. (Exception: if the Program itself is interactive but
does not normally print such an announcement, your work based on
the Program is not retquired to print an announcement.)
the Program is not required to print an announcement.)
These retquirements apply to the modified work as a whole. If
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
@@ -185,7 +185,7 @@ However, parties who have received copies, or rights, from you under
this License will not have their licenses terminated so long as such
parties remain in full compliance.

5. You are not retquired to accept this License, since you have not
5. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Program or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by


+ 17
- 17
LICENSE.GPL3 View File

@@ -51,7 +51,7 @@ giving you legal permission to copy, distribute and/or modify it.

For the developers' and authors' protection, the GPL clearly explains
that there is no warranty for this free software. For both users' and
authors' sake, the GPL retquires that modified versions be marked as
authors' sake, the GPL requires that modified versions be marked as
changed, so that their problems will not be attributed erroneously to
authors of previous versions.

@@ -148,7 +148,7 @@ programs which are used unmodified in performing those activities but
which are not part of the work. For example, Corresponding Source
includes interface definition files associated with source files for
the work, and the source code for shared libraries and dynamically
linked subprograms that the work is specifically designed to retquire,
linked subprograms that the work is specifically designed to require,
such as by intimate data communication or control flow between those
subprograms and other parts of the work.

@@ -224,7 +224,7 @@ terms of section 4, provided that you also meet all of these conditions:

b) The work must carry prominent notices stating that it is
released under this License and any conditions added under section
7. This retquirement modifies the retquirement in section 4 to
7. This requirement modifies the requirement in section 4 to
"keep intact all notices".

c) You must license the entire work, as a whole, under this
@@ -283,7 +283,7 @@ in one of these ways:
d) Convey the object code by offering access from a designated
place (gratis or for a charge), and offer equivalent access to the
Corresponding Source in the same way through the same place at no
further charge. You need not retquire recipients to copy the
further charge. You need not require recipients to copy the
Corresponding Source along with the object code. If the place to
copy the object code is a network server, the Corresponding Source
may be on a different server (operated by you or a third party)
@@ -291,7 +291,7 @@ in one of these ways:
clear directions next to the object code saying where to find the
Corresponding Source. Regardless of what server hosts the
Corresponding Source, you remain obligated to ensure that it is
available for as long as needed to satisfy these retquirements.
available for as long as needed to satisfy these requirements.

e) Convey the object code using peer-to-peer transmission, provided
you inform other peers where the object code and Corresponding
@@ -316,7 +316,7 @@ commercial, industrial or non-consumer uses, unless such uses represent
the only significant mode of use of the product.

"Installation Information" for a User Product means any methods,
procedures, authorization keys, or other information retquired to install
procedures, authorization keys, or other information required to install
and execute modified versions of a covered work in that User Product from
a modified version of its Corresponding Source. The information must
suffice to ensure that the continued functioning of the modified object
@@ -329,13 +329,13 @@ part of a transaction in which the right of possession and use of the
User Product is transferred to the recipient in perpetuity or for a
fixed term (regardless of how the transaction is characterized), the
Corresponding Source conveyed under this section must be accompanied
by the Installation Information. But this retquirement does not apply
by the Installation Information. But this requirement does not apply
if neither you nor any third party retains the ability to install
modified object code on the User Product (for example, the work has
been installed in ROM).

The retquirement to provide Installation Information does not include a
retquirement to continue to provide support service, warranty, or updates
The requirement to provide Installation Information does not include a
requirement to continue to provide support service, warranty, or updates
for a work that has been modified or installed by the recipient, or for
the User Product in which it has been modified or installed. Access to a
network may be denied when the modification itself materially and
@@ -345,7 +345,7 @@ protocols for communication across the network.
Corresponding Source conveyed, and Installation Information provided,
in accord with this section must be in a format that is publicly
documented (and with an implementation available to the public in
source code form), and must retquire no special password or key for
source code form), and must require no special password or key for
unpacking, reading or copying.

7. Additional Terms.
@@ -361,7 +361,7 @@ this License without regard to the additional permissions.

When you convey a copy of a covered work, you may at your option
remove any additional permissions from that copy, or from any part of
it. (Additional permissions may be written to retquire their own
it. (Additional permissions may be written to require their own
removal in certain cases when you modify the work.) You may place
additional permissions on material, added by you to a covered work,
for which you have or can give appropriate copyright permission.
@@ -410,7 +410,7 @@ where to find the applicable terms.

Additional terms, permissive or non-permissive, may be stated in the
form of a separately written license, or stated as exceptions;
the above retquirements apply either way.
the above requirements apply either way.

8. Termination.

@@ -442,10 +442,10 @@ material under section 10.

9. Acceptance Not Required for Having Copies.

You are not retquired to accept this License in order to receive or
You are not required to accept this License in order to receive or
run a copy of the Program. Ancillary propagation of a covered work
occurring solely as a consequence of using peer-to-peer transmission
to receive a copy likewise does not retquire acceptance. However,
to receive a copy likewise does not require acceptance. However,
nothing other than this License grants you permission to propagate or
modify any covered work. These actions infringe copyright if you do
not accept this License. Therefore, by modifying or propagating a
@@ -489,7 +489,7 @@ by this License, of making, using, or selling its contributor version,
but do not include claims that would be infringed only as a
consequence of further modification of the contributor version. For
purposes of this definition, "control" includes the right to grant
patent sublicenses in a manner consistent with the retquirements of
patent sublicenses in a manner consistent with the requirements of
this License.

Each contributor grants you a non-exclusive, worldwide, royalty-free
@@ -511,7 +511,7 @@ publicly available network server or other readily accessible means,
then you must either (1) cause the Corresponding Source to be so
available, or (2) arrange to deprive yourself of the benefit of the
patent license for this particular work, or (3) arrange, in a manner
consistent with the retquirements of this License, to extend the patent
consistent with the requirements of this License, to extend the patent
license to downstream recipients. "Knowingly relying" means you have
actual knowledge that, but for the patent license, your conveying the
covered work in a country, or your recipient's use of the covered work
@@ -564,7 +564,7 @@ permission to link or combine any covered work with a work licensed
under version 3 of the GNU Affero General Public License into a single
combined work, and to convey the resulting work. The terms of this
License will continue to apply to the part which is the covered work,
but the special retquirements of the GNU Affero General Public License,
but the special requirements of the GNU Affero General Public License,
section 13, concerning interaction through a network will apply to the
combination as such.



+ 1
- 1
LICENSE.QPL View File

@@ -65,7 +65,7 @@ and development of free software which uses the Software.
6. You may develop application programs, reusable components and other
software items that link with the original or modified versions of the
Software. These items, when distributed, are subject to the following
retquirements:
requirements:

a. You must ensure that all recipients of machine-executable forms of
these items are also able to receive and use the complete


+ 1
- 1
README.immodule View File

@@ -99,7 +99,7 @@ immodule for Qt

- set "iiimqcf" that has its own input method switching framework as
default, and disable input method selection menu in the context
menu. Such configuration is retquired by some system integrators to
menu. Such configuration is required by some system integrators to
provide unified user interface for global input method switching
over the desktop



+ 4
- 4
changes.immodule View File

@@ -52,7 +52,7 @@ Build & Install
+ configure options have been changed for internal reasons. See 'How
to install' section of README.immodule

- This version of immodule retquires corresponding version of each
- This version of immodule requires corresponding version of each
input method plugins (i.e. update your additional input method
plugins)

@@ -93,7 +93,7 @@ New features
- QInputContext proxying

Some methods of QInputContext have been changed to enable
QInputContext proxying. This feature is retquired to implement
QInputContext proxying. This feature is required to implement
pluggable input method switcher.


@@ -102,7 +102,7 @@ General

+ QInputContext has been source compatible with Qt4 version. Basic
input method plugin can be source compatible without #ifdef. Only
pluggable popup menu retquires #ifdef'ed different code. In addition,
pluggable popup menu requires #ifdef'ed different code. In addition,
be careful about use of classes that is deprecated in Qt4.

- Our two development tree for Qt3 'Binary Compatible' and 'ALL' have
@@ -146,7 +146,7 @@ API Changes in qt-x11-immodule-unified-qt3.3.3-20040910
* QInputContext()

Added 'parent' arg to be compatible with Qt4. Since the arg
defaults to 0, no modification of plugins are retquired.
defaults to 0, no modification of plugins are required.

* language()
* identifierName()


+ 1
- 1
config.tests/unix/ipv6/ipv6test.cpp View File

@@ -1,5 +1,5 @@
/* Sample program for configure to test IPv6 support on target
platforms. We check for the retquired IPv6 data structures. */
platforms. We check for the required IPv6 data structures. */

#if defined(__hpux)
#define _HPUX_SOURCE


+ 1
- 1
config.tests/x11/opengl.test View File

@@ -60,7 +60,7 @@ for L in $LIBS; do
if [ "x$F_REASON" = "xthreads" ]; then
echo
echo "WARNING: $FOUND_LIB is threaded!"
echo "The Qt OpenGL module retquires Qt to be configured with -thread."
echo "The Qt OpenGL module requires Qt to be configured with -thread."
echo
else
[ "$VERBOSE" = "yes" ] && echo " Could not find $L lib anywhere in $LIBDIRS"


+ 1
- 1
config.tests/x11/xcursor.test View File

@@ -75,7 +75,7 @@ if [ "$XCURSOR" = "yes" ]; then
elif [ "$XCURSOR_MAJOR" != "1" ]; then
XCURSOR=no
[ "$VERBOSE" = "yes" ] && \
echo " Found Xcursor version $XCURSOR_MAJOR.$XCURSOR_MINOR, version 1.0 or higher retquired."
echo " Found Xcursor version $XCURSOR_MAJOR.$XCURSOR_MINOR, version 1.0 or higher required."
else
[ "$VERBOSE" = "yes" ] && \
echo " Found Xcursor version $XCURSOR_MAJOR.$XCURSOR_MINOR"


+ 1
- 1
config.tests/x11/xrandr.test View File

@@ -78,7 +78,7 @@ if [ "$XRANDR" = "yes" ]; then
elif [ "$XRANDR_MAJOR" != "1" -o "$XRANDR_MINOR" -lt "1" ]; then
XRANDR=no
[ "$VERBOSE" = "yes" ] && \
echo " Found XRandR version $XRANDR_MAJOR.$XRANDR_MINOR, version 1.1 or higher retquired."
echo " Found XRandR version $XRANDR_MAJOR.$XRANDR_MINOR, version 1.1 or higher required."
else
[ "$VERBOSE" = "yes" ] && \
echo " Found XRandR version $XRANDR_MAJOR.$XRANDR_MINOR"


+ 1
- 1
configure View File

@@ -2330,7 +2330,7 @@ Qt/Embedded only:

-depths list ....... Comma-separated list of supported bit-per-pixel
depths, from: 4, 8, 16, 24, and 32.
(8bpp is retquired by the VGA16 driver)
(8bpp is required by the VGA16 driver)

-qt-gfx-<driver> ... Enable a graphics <driver> in the Qt Library.
-plugin-gfx-<driver> Enable graphics <driver> as a plugin to be


+ 1
- 1
doc/3rdparty.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/accel.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/annotated.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 2
- 2
doc/application-walkthrough.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:
@@ -244,7 +244,7 @@ will implement later.

Now that we have done the File menu we shift our focus back to the
menu bar and insert a separator. From now on further menu bar entries
will be aligned to the right if the windows system style retquires it.
will be aligned to the right if the windows system style requires it.

\printline help
\printuntil whatsThis


+ 2
- 2
doc/canvas.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:
@@ -52,7 +52,7 @@ QCanvasItem QCanvasItems \endlink. Canvas items can have an arbitrary
shape, size and content, can be freely moved around in the canvas,
and can be checked for collisions. Canvas items can be set to move
across the canvas automatically and animated canvas items are
supported with QCanvasSprite. (If you retquire 3D graphics see Qt's
supported with QCanvasSprite. (If you require 3D graphics see Qt's
\link opengl.html OpenGL module \endlink.)

The canvas module uses a document/view model. The \l QCanvasView class


+ 2
- 2
doc/changes.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:
@@ -207,7 +207,7 @@ existing code which uses these classes will continue to work.
\section2 Regular Expressions

Qt has always provided regular expression support, but that support
was pretty much limited to what was retquired in common GUI control
was pretty much limited to what was required in common GUI control
elements such as file dialogs. Qt 3.0 introduces a new regular
expression engine, QRegExp, that supports most of Perl's regex
features and is Unicode based. The most useful additions are support


+ 1
- 1
doc/charinput-qws.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/classchart.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/classes.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/collect.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/commercialeditions.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/coordsys.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/credits.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/customstyles.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/datastreamformat.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/debug.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 3
- 3
doc/distributingqt.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:
@@ -43,7 +43,7 @@

This document lists the platform-specific files needed to distribute
Qt applications. We do not include any compiler-specific files that
may also be retquired. (See also, \link winsystem.html Window
may also be required. (See also, \link winsystem.html Window
System-specific Notes\endlink.)

\tableofcontents
@@ -85,7 +85,7 @@ version is prefixed with \e {-mt}.

\section2 Distributing Plugins

You must include any plugin files retquired by the application.
You must include any plugin files required by the application.

Plugins must be put into a subdirectory under a directory known to
Qt as a plugin directory. The subdirectory must have the name of the


+ 1
- 1
doc/dnd.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/editions.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 2
- 2
doc/embclasses.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:
@@ -129,7 +129,7 @@ typically 2-20KB in size; they can be mmap'd direct from disk in order
to save memory). If a QPF font is found which matches a font request
no new QRenderedFont need be created for it. It's possible to strip out
all QFontFactory support and simply use QPFs if your font needs are modest
(for instance, if you only retquire a few fixed point sizes). Note that
(for instance, if you only require a few fixed point sizes). Note that
no best-match loading is performed with QPFs, as opposed to those
loaded via QFontManager, so if you don't have the correct QPF for a point
size, text in that size will simply not be displayed.


+ 1
- 1
doc/embporting.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/envvars.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 2
- 2
doc/faq.doc View File

@@ -229,7 +229,7 @@ project. Can we transfer the license to another developer?

Yes. Qt licences are for the individual use of named developers. If
the developer associated with a licence leaves the organization, or
moves on to another project that does not retquire a Qt license,
moves on to another project that does not require a Qt license,
another developer can take over the licence. You can change the name
of the developer using a licence at any time, but after a change you
must wait at least six (6) months before changing again.
@@ -342,7 +342,7 @@ software pool to do so without paying license fees.
Although it is possible to write free software for internal
use, it is difficult to ensure that such software is used and
distributed legally. For example, if your free software
retquires any modules that impose conditions on you that
requires any modules that impose conditions on you that
contradict the conditions of the GNU GPL, including, but not
limited to, software patents, commercial license agreements,
copyrighted interface definitions or any sort of


+ 1
- 1
doc/features.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/focus.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/framebuffer-howto.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/functions.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/headers.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/hierarchy.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 1
- 1
doc/how-to-learn-qt.doc View File

@@ -16,7 +16,7 @@
** and the KDE Free Qt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:


+ 2
- 2
doc/html/activeqt-dotnet.html View File

@@ -106,7 +106,7 @@ is presented, which includes using a thin MC++ wrapper class around
the normal TQt/C++ class. Then, the automated way is presented, which
utilizes the <a href="activeqt.html#ActiveTQt">ActiveTQt</a> framework as a generic bridge. The advantage of
the first method is that it gives the application developer full
control, while the second method retquires less coding and relieves the
control, while the second method requires less coding and relieves the
developer of dealing with the conversion between managed and normal
data objects.
<p> The impatient reader, who right away wants to see a <a href="qpushbutton.html">TQPushButton</a> and a
@@ -405,7 +405,7 @@ available to .NET. This has the positive side effect that the same
API is automatically available in <a href="http://www.trolltech.com/products/qsa">TQSA</a>, the cross platform
scripting solution for TQt applications, and to COM clients in general.
<p> When using the "IJW" method, in priciple the only limitation is the
time retquired to write the wrapper classes and data type conversion
time required to write the wrapper classes and data type conversion
functions.
<p> <h3> Performance Considerations
</h3>


+ 1
- 1
doc/html/activeqt-tools-idc.html View File

@@ -59,7 +59,7 @@ type library wll have version x.y.
<td valign="top">Unregister the COM server <em>dll</em>
</table></center>
<p> It is usually never necessary to invoke IDC manually, as the
<tt>qmake</tt> build system takes care of adding the retquired post
<tt>qmake</tt> build system takes care of adding the required post
processing steps to the build process. See the
<a href="qaxserver.html#4">ActiveTQt build system</a>
documentation for details.


+ 1
- 1
doc/html/activeqt-tools-testcon.html View File

@@ -51,7 +51,7 @@ VBScript, Perl and Python to program the controls loaded. Example
script files using the TQAxWidget2 class are available in the <tt>scripts</tt>
subdirectory.
<p> Note that the qmake project of this example includes a resource file
<tt>testcon.rc</tt> with a version resource. This is retquired by some
<tt>testcon.rc</tt> with a version resource. This is required by some
ActiveX controls (ie. Shockwave ActiveX Controls), which might crash
or misbehave otherwise if such version information is missing.
<p> To build the tool you must first build the


+ 1
- 1
doc/html/assistant-6.html View File

@@ -81,7 +81,7 @@ body { background: #ffffff; color: black; }
<li><p>Start Page- This property specifies which page <em>TQt Assistant</em> should initially display when the profile is used. Usually, this is the HTML file which contains the documentation's table of contents. This property also describes the default location to go to when pressing the home button in <em>TQt Assistant</em>'s main user interface. The start page is specified relative to the location of the profile. The property name is <tt>startpage</tt></p>
<li><p>About Menu Text- This property describes the text that appears in the <b>Help</b> menu, e.g. About Application. The property name is <tt>aboutmenutext</tt></p>
<li><p>About URL- This property can be used to point to an HTML file that describes the contents in the About dialog that is opened for the <b>Help</b> menu, e.g. About Application. The url is specified relative to the location of the profile. The property name is <tt>abouturl</tt></p>
<li><p><em>TQt Assistant</em> Documentation- This property describes the location of the <em>TQt Assistant</em> documentation. This is retquired since <em>TQt Assistant</em> provides self help, such as the full text search help and the <em>TQt Assistant</em> Manual option in the <b>Help</b> menu. The location is a directory relative to the location of the profile. The property name is <tt>assistantdocs</tt>.</p>
<li><p><em>TQt Assistant</em> Documentation- This property describes the location of the <em>TQt Assistant</em> documentation. This is required since <em>TQt Assistant</em> provides self help, such as the full text search help and the <em>TQt Assistant</em> Manual option in the <b>Help</b> menu. The location is a directory relative to the location of the profile. The property name is <tt>assistantdocs</tt>.</p>
</ul><p>To define a profile, one needs to specify a <em>TQt Assistant</em> Document Profile, usually abbreviated <tt>.adp</tt>. The profile is an extension of the Documentation Content File described above. We add a <tt>profile</tt> tag containing <tt>property</tt> tags to the format.</p>
<p>An example of a document profile file is shown below:</p>
<p><tt>helpdemo.adp</tt></p>


+ 1
- 1
doc/html/canvas.html View File

@@ -39,7 +39,7 @@ body { background: #ffffff; color: black; }
shape, size and content, can be freely moved around in the canvas,
and can be checked for collisions. Canvas items can be set to move
across the canvas automatically and animated canvas items are
supported with <a href="qcanvassprite.html">TQCanvasSprite</a>. (If you retquire 3D graphics see TQt's
supported with <a href="qcanvassprite.html">TQCanvasSprite</a>. (If you require 3D graphics see TQt's
<a href="opengl.html">OpenGL module</a>.)
<p> The canvas module uses a document/view model. The <a href="qcanvasview.html">TQCanvasView</a> class
is used to show a particular view of a canvas. Multiple views can operate


+ 1
- 1
doc/html/commonproblems.html View File

@@ -75,7 +75,7 @@ tools are usually located in the <tt>bin</tt> subdirectory of TQt distributions.
Either run <tt>"$QTDIR"/bin/moc</tt> and <tt>"$QTDIR"/bin/uic</tt> or add <tt>"$QTDIR"/bin</tt>
to your <tt>PATH</tt> and run <a href="moc.html#moc">moc</a> and <tt>uic</tt>. If you use <tt>qmake</tt> the
appropriate lines will be added to your Makefiles so that <em>uic</em> and
<em>moc</em> will be executed as retquired.
<em>moc</em> will be executed as required.
<p> <dt>Static or shared libraries - Link time
<p> <dd>Programmers need to link with the TQt static or shared libraries. The TQt
libraries are usually located in the <tt>lib</tt> subdirectory of TQt distributions.


+ 1
- 1
doc/html/customlayout.html View File

@@ -136,7 +136,7 @@ TQLayoutIterator CardLayout::iterator()
It must be implemented. It is used by <a href="qlayout.html#add">TQLayout::add</a>(), by the <a href="qlayout.html">TQLayout</a>
constructor that takes a layout as parent, and it is used to implement
the <a href="qlayout.html#autoAdd">auto-add</a> feature. If your layout
has advanced placement options that retquire parameters, you must
has advanced placement options that require parameters, you must
provide extra access functions such as <a href="qgridlayout.html#addMultiCell">TQGridLayout::addMultiCell</a>().
<p> <pre>
void CardLayout::addItem( <a href="qlayoutitem.html">TQLayoutItem</a> *item )


+ 3
- 3
doc/html/designer-manual-1.html View File

@@ -32,12 +32,12 @@ body { background: #ffffff; color: black; }
<td align="right" valign="center"><img src="logo32.png" align="right" width="64" height="32" border="0"></td></tr></table><p align="right">[<a href="designer-manual.html">Home</a>] [<a href="designer-manual-2.html">Next: Quick Start</a>]</p>
<h2 align="center">Preface</h2>
<h3><a name="1"></a>Introduction</h3>
<p>This manual presents <em>TQt Designer</em>, a tool for designing and implementing user interfaces built with the TQt multiplatform GUI toolkit. <em>TQt Designer</em> makes it easy to experiment with user interface design. At any time you can generate the code retquired to reproduce the user interface from the files <em>TQt Designer</em> produces, changing your design as often as you like. If you used an earlier version you will find yourself immediately productive in the new version since the interface is very similar. And you will also find new widgets and new and improved functionality which have been developed as a result of your feedback.</p>
<p>This manual presents <em>TQt Designer</em>, a tool for designing and implementing user interfaces built with the TQt multiplatform GUI toolkit. <em>TQt Designer</em> makes it easy to experiment with user interface design. At any time you can generate the code required to reproduce the user interface from the files <em>TQt Designer</em> produces, changing your design as often as you like. If you used an earlier version you will find yourself immediately productive in the new version since the interface is very similar. And you will also find new widgets and new and improved functionality which have been developed as a result of your feedback.</p>
<p><em>TQt Designer</em> helps you build user interfaces with layout tools that move and scale your widgets (<em>controls</em> in Windows terminology) automatically at runtime. The resulting interfaces are both functional and attractive, comfortably suiting your users' operating environments and preferences. <em>TQt Designer</em> supports TQt's signals and slots mechanism for type-safe communication between widgets. <em>TQt Designer</em> includes a code editor which you can use to embed your own custom slots inside the generated code. Those who prefer to separate generated code from hand crafted code can continue to use the subclassing approach pioneered in the first version of <em>TQt Designer</em>.<!-- index Controls!Widgets --></p>
<p>The manual introduces you to <em>TQt Designer</em> by leading you through the development of example applications. The first seven chapters are tutorials, each designed to be as self-contained as possible. Every chapter, except the first three, assumes that you are familiar with the material in chapters two and three which cover the basics of building a TQt application with <em>TQt Designer</em>. Here's a brief overview of the chapters:</p>
<ul><li><p>Chapter one, <a href="designer-manual-2.html">Quick Start</a>, is a fast hands-on tutorial that takes you through the creation of a short, simple dialog application. The aim of this chapter is to give you a feel for how <em>TQt Designer</em> works, with explanations and details deferred to later chapters.</p>
<li><p>Chapter two, <a href="designer-manual-3.html">Creating a Main Window Application</a>, introduces <em>TQt Designer</em> and takes you step by step through the creation of a small but fully functional application. Along the way you will learn how to create a main window with menus, toolbars and a status bar. Most of the application's implementation will be covered, but the custom dialogs are deferred until chapter three. In the course of this chapter you will use the form and property editors to customize the application. You'll also learn how to use TQt's signals and slots mechanism and <em>TQt Designer</em>'s built-in code editor to make the application functional. We will also explain how to use <tt>qmake</tt> to generate a Makefile so that you can compile and run the application.</p>
<li><p>In chapter three, <a href="designer-manual-4.html">Creating Dialogs</a>, we will create the custom dialogs retquired by the main window application created in chapter two. In addition to demonstrating various ways of creating dialogs, you will also learn how to lay out forms using the layout tools.</p>
<li><p>In chapter three, <a href="designer-manual-4.html">Creating Dialogs</a>, we will create the custom dialogs required by the main window application created in chapter two. In addition to demonstrating various ways of creating dialogs, you will also learn how to lay out forms using the layout tools.</p>
<li><p>Chapter four, <a href="designer-manual-5.html#the-designer-approach">The Designer Approach</a>, provides information on the <em>TQt Designer</em> approach to developing applications, and explains some of the rationale behind <em>TQt Designer</em>.</p>
<li><p>Chapter five, <a href="designer-manual-6.html">Subclassing and Dynamic Dialogs</a>, will show you how to subclass a form; this allows you to clearly separate the user interface from the underlying code that implements its functionality. Additional information on <tt>qmake</tt> and <tt>uic</tt> is included in this chapter. This chapter will also explain how you can dynamically load dialogs from<!-- index .ui --> <tt>.ui</tt> files into your application using <a href="qwidgetfactory.html">TQWidgetFactory</a> and how to access the widgets and sub-widgets of these dialogs.</p>
<li><p>Chapter six, <a href="designer-manual-7.html">Creating Custom Widgets</a>, explains how you can create your own custom widgets. Both the simple method, that was introduced with the first version of <em>TQt Designer</em>, and the new more powerful method using plugins, are explained.</p>
@@ -46,7 +46,7 @@ body { background: #ffffff; color: black; }
</ul><p>The remaining chapters provide reference material that explains <em>TQt Designer</em>'s <a href="designer-manual-11.html#reference-menu-options">menu options</a>, <a href="designer-manual-12.html#reference-toolbar-buttons">toolbars</a>, <a href="designer-manual-10.html#reference-key-bindings">key bindings</a>, <a href="designer-manual-13.html#reference-dialogs">dialogs</a>, <a href="designer-manual-14.html#reference-wizards">wizards</a>, and <a href="designer-manual-15.html#reference-windows">windows</a> in detail.</p>
<h3><a name="2"></a>What You Should Know</h3>
<p>This manual assumes that you have some basic knowledge of C++ and the TQt GUI toolkit. If you need to learn more about C++ or TQt there are a vast number of C++ books available, and a small but increasing number of TQt books. TQt comes with extensive online documentation and many example applications that you can try.</p>
<p>The Enterprise Edition of TQt includes the TQt SQL module. In <a href="designer-manual-8.html">Creating Database Applications</a> we demonstrate how to build SQL applications with <em>TQt Designer</em>; this chapter retquires some knowledge of SQL and relational databases.</p>
<p>The Enterprise Edition of TQt includes the TQt SQL module. In <a href="designer-manual-8.html">Creating Database Applications</a> we demonstrate how to build SQL applications with <em>TQt Designer</em>; this chapter requires some knowledge of SQL and relational databases.</p>
<h3><a name="3"></a>What's New in <em>TQt Designer</em> for TQt 3.0?</h3>
<p>This version of <em>TQt Designer</em> has a great deal more functionality than its predecessor. For example, the code for custom slots can be edited directly in <em>TQt Designer</em>; main windows with actions, toolbars and menus can be created; layouts that incorporate splitters can be used; and plugins allow you to package any number of custom widgets and make them available to <em>TQt Designer</em>. Many other enhancements have been incorporated, from small improvements in the user interface to improved efficiency, for example the ability to share pixmaps across all the forms in an application.</p>
<p>This version of <em>TQt Designer</em> introduces project files which make it easy to switch between all the forms in an application, and to maintain a common set of database settings and images. Although subclassing is fully supported, writing code directly in <em>TQt Designer</em> offers a number of benefits which are covered in <a href="designer-manual-5.html#the-designer-approach">The Designer Approach</a> chapter. A new library, <tt>libtqui</tt>, has also been introduced which allows you to load dialogs dynamically at runtime from <em>TQt Designer</em>'s <tt>.ui</tt> files. This allows you to provide your application's users with considerable interface customizability without them needing to use C++.</p>


+ 4
- 4
doc/html/designer-manual-13.html View File

@@ -127,7 +127,7 @@ body { background: #ffffff; color: black; }
</p>
<blockquote><p align="center"><em>Edit Functions</em></p></blockquote>
<p>Click <b>Edit|Slots</b> to invoke the <em>Edit Functions</em> dialog. Use this dialog to edit or create slots and functions which are used in conjunction with signals to provide communication between objects.</p>
<p>When this dialog is invoked, all existing slots and functions are shown in the listview. The column headers Function, Return Type, Specifier, Access, Type, and In Use provide details about each function that is listed. Click on any of the column headers to sort the functions. To create a new function, click the <b>New Function</b> button. The new function has a default name that you should replace by typing the new name in the 'Function' line edit. The 'Return Type' is also a default that can be changed by typing in the line edit. To change the 'Specifier' or 'Access', click the combobox and choose the retquired specifier or access. To change the type of a function (function or slot), click the Type combobox. To remove a function, click the function you want to delete, and then click the <b>Delete Function</b> button.</p>
<p>When this dialog is invoked, all existing slots and functions are shown in the listview. The column headers Function, Return Type, Specifier, Access, Type, and In Use provide details about each function that is listed. Click on any of the column headers to sort the functions. To create a new function, click the <b>New Function</b> button. The new function has a default name that you should replace by typing the new name in the 'Function' line edit. The 'Return Type' is also a default that can be changed by typing in the line edit. To change the 'Specifier' or 'Access', click the combobox and choose the required specifier or access. To change the type of a function (function or slot), click the Type combobox. To remove a function, click the function you want to delete, and then click the <b>Delete Function</b> button.</p>
<p>Click <b>OK</b> to save all changes made to the functions. Click <b>Cancel</b> to leave the dialog without making any changes to the functions.</p>
<a name="dialog-view-connections"></a><h4><a name="4-2"></a>View and Edit Connections Dialog</h4>
<p align="center"><img align="middle" src="qs-editconn1.png" width="608" height="391">
@@ -142,10 +142,10 @@ body { background: #ffffff; color: black; }
<blockquote><p align="center"><em>Form Settings</em></p></blockquote>
<p>Click <b>Edit|Form Settings</b> to invoke the <em>Form Settings</em> dialog. Use this dialog to save the form's settings, pixmap, and layout properties.</p>
<h5><a name="4-3-1"></a>Settings</h5>
<p>In the Settings section, you can change or add the name of the class that will be created by typing in the 'Class Name' line edit. Note that the default name is the form name, but it can be changed. You can also enter text to the 'Comment' and 'Author' line edits or leave them blank, since they are not retquired.</p>
<p>In the Settings section, you can change or add the name of the class that will be created by typing in the 'Class Name' line edit. Note that the default name is the form name, but it can be changed. You can also enter text to the 'Comment' and 'Author' line edits or leave them blank, since they are not required.</p>
<h5><a name="4-3-2"></a>Pixmaps</h5>
<p>The default (for projects) is 'Project Imagefile'. This is the recommended option. Images are handled automatically, with <em>TQt Designer</em> storing the images in a subdirectory, and <tt>uic</tt> producing code that contains the images and the necessary supporting code. Each image is stored just once, no matter how many forms it is used in.</p>
<p>If you do not want <em>TQt Designer</em> to handle the images, (or are not using a project) choose either 'Save Inline' or 'Use Function'. 'Save Inline' saves the pixmaps in the <tt>.ui</tt> files. The disadvantage of this approach is that it stores images in the forms in which they're used, meaning that images cannot be shared across forms. Click 'Use Function' to use your own icon-loader function for loading pixmaps. Type the function's name (with no signature) in the 'Use Function' line edit. This function will be used in the generated code for loading pixmaps. Your function will be called with the text you put in the pixmap property (e.g. the image name) whenever an image is retquired.</p>
<p>If you do not want <em>TQt Designer</em> to handle the images, (or are not using a project) choose either 'Save Inline' or 'Use Function'. 'Save Inline' saves the pixmaps in the <tt>.ui</tt> files. The disadvantage of this approach is that it stores images in the forms in which they're used, meaning that images cannot be shared across forms. Click 'Use Function' to use your own icon-loader function for loading pixmaps. Type the function's name (with no signature) in the 'Use Function' line edit. This function will be used in the generated code for loading pixmaps. Your function will be called with the text you put in the pixmap property (e.g. the image name) whenever an image is required.</p>
<h5><a name="4-3-3"></a>Layouts</h5>
<p>Click the 'Default Margin' spinbox or the 'Default Spacing' spinbox to change the default layout settings of the current form.</p>
<p>To use the functions in the generated code to dynamically retrieve values for the layout's default margin and spacing, check the Use Functions chechbox. In the Margin and Spacing line edits, specify the function names (no signatures or parantheses) which should be used to retrieve the margin and spacing.</p>
@@ -233,7 +233,7 @@ body { background: #ffffff; color: black; }
<h3><a name="7"></a>The Tools Dialog</h3>
<a name="dialog-edit-custom-widgets"></a><h4><a name="7-1"></a>Edit Custom Widgets Dialog</h4>
<p>The <em>Edit Custom Widgets</em> dialog is invoked by clicking <b>Tools|Custom|Edit Custom Widgets</b>. Use this dialog to create custom widgets.</p>
<p>Custom widgets are created in code. They may contain a combination of existing widgets but with additional functionality, slots and signals, or they may be written from scratch, or a mixture of both. A custom widget is often a specialization (subclass) of another widget or a combination of widgets working together or a blend of both these approaches. If you simply want a collection of widgets in a particular configuration it is easiest to create them, select them as a group, and copy and paste them as retquired within <em>TQt Designer</em>. Custom widgets are generally created when you need to add new functionality to existing widgets or groups of widgets. To add create a new widget, click the <b>New Widget</b> button. You will find more information about adding new widgets in the 'Definitions Section'. To load a file which contains descriptions of custom widgets, click the <b>Load Descriptions</b> button. Clicking this button invokes the <em>Open Dialog</em>. To save the descriptions of the listed custom widgets, click the <b>Save Descriptions</b> button, which invokes the <em>Save As Dialog</em>. To delete a widget, click the widget in the listbox and then click the <b>Delete Widget</b> button.</p>
<p>Custom widgets are created in code. They may contain a combination of existing widgets but with additional functionality, slots and signals, or they may be written from scratch, or a mixture of both. A custom widget is often a specialization (subclass) of another widget or a combination of widgets working together or a blend of both these approaches. If you simply want a collection of widgets in a particular configuration it is easiest to create them, select them as a group, and copy and paste them as required within <em>TQt Designer</em>. Custom widgets are generally created when you need to add new functionality to existing widgets or groups of widgets. To add create a new widget, click the <b>New Widget</b> button. You will find more information about adding new widgets in the 'Definitions Section'. To load a file which contains descriptions of custom widgets, click the <b>Load Descriptions</b> button. Clicking this button invokes the <em>Open Dialog</em>. To save the descriptions of the listed custom widgets, click the <b>Save Descriptions</b> button, which invokes the <em>Save As Dialog</em>. To delete a widget, click the widget in the listbox and then click the <b>Delete Widget</b> button.</p>
<p>Click <b>Close</b> to leave the Edit Custom Widgets dialog.</p>
<h5><a name="7-1-1"></a>The Definition Tab</h5>
<p align="center"><img align="middle" src="rd-cwidgdef.png" width="720" height="412">


+ 1
- 1
doc/html/designer-manual-14.html View File

@@ -43,7 +43,7 @@ body { background: #ffffff; color: black; }
<p align="center"><img align="middle" src="qd-mainwinwzdpage2.png" width="658" height="418">
</p>
<h4><a name="2-2"></a>Setup Toolbar</h4>
<p>The 'Setup Toolbar' wizard page is used to populate a toolbar with actions from each of the default action categories. Click the Category combobox to select which set of actions you wish to work on. The Actions listbox lists the actions available for the current category. The Toolbar listbox lists the toolbar buttons you want to create. Click the blue left and right arrow buttons to move actions into or out of the Toolbar list box. Click the blue up and down arrow buttons to move actions up and down within the Toolbar list box. Note that the '&lt;Separator&gt;' item in the Actions list box may be moved to the Toolbar list box as often as retquired and will cause a separator to appear in the finished toolbar.</p>
<p>The 'Setup Toolbar' wizard page is used to populate a toolbar with actions from each of the default action categories. Click the Category combobox to select which set of actions you wish to work on. The Actions listbox lists the actions available for the current category. The Toolbar listbox lists the toolbar buttons you want to create. Click the blue left and right arrow buttons to move actions into or out of the Toolbar list box. Click the blue up and down arrow buttons to move actions up and down within the Toolbar list box. Note that the '&lt;Separator&gt;' item in the Actions list box may be moved to the Toolbar list box as often as required and will cause a separator to appear in the finished toolbar.</p>
<p>Click <b>Back</b> if you want to return to the 'Choose available menus and toolbars' wizard page. Click <b>Finish</b> to populate the main window and to exit the wizard. Click <b>Cancel</b> on any of the wizard pages to leave the wizard without making any changes.</p>
<h3><a name="3"></a>Data Table Wizard</h3>
<p>The Data Table Wizard is automatically invoked by clicking the datatable widget and placing it on the form. The datatable widget is used to create tabular views of database data.</p>


+ 2
- 2
doc/html/designer-manual-16.html View File

@@ -123,7 +123,7 @@ body { background: #ffffff; color: black; }
** and the KDE Free TQt Foundation.
**
** Please review the following information to ensure GNU General
** Public Licensing retquirements will be met:
** Public Licensing requirements will be met:
** http://trolltech.com/products/qt/licenses/licensing/opensource/.
** If you are unsure which license is appropriate for your use, please
** review the following information:
@@ -185,7 +185,7 @@ body { background: #ffffff; color: black; }
</pre>
<a name="exportmacro"></a><h4><a name="1-7"></a>exportmacro</h4>
<p>This tag is only relevant to Windows users.</p>
<p>If you have a class that retquires some Windows-specific export macro, e.g. for classes in a DLL that need to be declared like this: <tt>class win_specific_declaration_goes_here Class</tt>, you can use the <tt>&lt;exportmacro&gt;</tt> tag. (In standard TQt we use the <tt>Q_EXPORT</tt> macro, e.g. <tt>class Q_EXPORT TQWidget</tt>.) If you use this tag you must also:</p>
<p>If you have a class that requires some Windows-specific export macro, e.g. for classes in a DLL that need to be declared like this: <tt>class win_specific_declaration_goes_here Class</tt>, you can use the <tt>&lt;exportmacro&gt;</tt> tag. (In standard TQt we use the <tt>Q_EXPORT</tt> macro, e.g. <tt>class Q_EXPORT TQWidget</tt>.) If you use this tag you must also:</p>
<ol type=1><li><p><a href="designer-manual-16.html#1-11">include</a> the file which contains the macro definition;</p>
<li><p>add the export macro to the form -- this is achieved by entering the macro's name in the 'export macro' sub-property of the form's name property.</p>
</ol><p>Following these steps will ensure that <a href="uic.html">uic</a> will create the correct <tt>class YOUR_MACRO Form</tt> declarations.</p>


+ 6
- 6
doc/html/designer-manual-3.html View File

@@ -87,7 +87,7 @@ body { background: #ffffff; color: black; }
<p align="center"><img align="middle" src="mw-menuwiz.png" width="616" height="420">
</p>
<blockquote><p align="center"><em>Main Window Wizard- Choosing menus and toolbars</em></p></blockquote>
<li><!-- index Creating Toolbars --><!-- index Toolbars, Creating --><!-- index Toolbar Buttons!Adding --><!-- index Adding!Toolbar Buttons --><!-- index Separator!Menu item --><!-- index Separator!Toolbar button --><p>The <em>Setup Toolbar</em> wizard page is used to populate a toolbar with actions from each of the default action categories. The Category combobox is used to select which set of actions you wish to choose from. The Actions list box lists the actions available for the current category. The Toolbar listbox lists the toolbar buttons you want to create. The blue left and right arrow buttons are used to move actions into or out of the Toolbar list box. The blue up and down arrow buttons are used to move actions up and down within the Toolbar list box. Note that the '&lt;Separator&gt;' item in the Actions list box may be moved to the Toolbar list box as often as retquired and will cause a separator to appear in the finished toolbar.</p>
<li><!-- index Creating Toolbars --><!-- index Toolbars, Creating --><!-- index Toolbar Buttons!Adding --><!-- index Adding!Toolbar Buttons --><!-- index Separator!Menu item --><!-- index Separator!Toolbar button --><p>The <em>Setup Toolbar</em> wizard page is used to populate a toolbar with actions from each of the default action categories. The Category combobox is used to select which set of actions you wish to choose from. The Actions list box lists the actions available for the current category. The Toolbar listbox lists the toolbar buttons you want to create. The blue left and right arrow buttons are used to move actions into or out of the Toolbar list box. The blue up and down arrow buttons are used to move actions up and down within the Toolbar list box. Note that the '&lt;Separator&gt;' item in the Actions list box may be moved to the Toolbar list box as often as required and will cause a separator to appear in the finished toolbar.</p>
<p>Copy the New, Open, and Save Actions to the Toolbar list box. Copy a &lt;Separator&gt; to the Toolbar list box. Change the Category to Edit and copy the Cut, Copy, and Find actions to the Toolbar list box. Click <b>Next</b> and then click <b>Finish</b>.</p>
<p>Click <b>File|Save</b> and save the form as <tt>mainform.ui</tt>.</p>
<p align="center"><img align="middle" src="mw-settoolwiz.png" width="616" height="420">
@@ -126,8 +126,8 @@ body { background: #ffffff; color: black; }
<p align="center"><img align="middle" src="mw-objexplor.png" width="328" height="465">
</p>
<blockquote><p align="center"><em>Object Explorer</em></p></blockquote>
<!-- index Code Editing --><!-- index Subclassing --><!-- index Forward declarations --><!-- index Includes --><!-- index Adding!Code --><!-- index Adding!Forward declarations --><!-- index Adding!Includes --><!-- index Adding!Class variables --><!-- index Class variables --><!-- index Deleting!Forward declarations --><!-- index Deleting!Includes --><!-- index Deleting!Class variables --><!-- index Forms!Forward declarations --><!-- index Forms!Class variables --><!-- index Forms!Code editing --><!-- index Forms!destructor --><!-- index Forms!constructor --><p>In the original version of <em>TQt Designer</em> if you wanted to provide code for a form you had to subclass the form and put your code in the subclass. This version fully supports the subclassing approach, but now provides an alternative: placing your code directly into forms. Writing code in <em>TQt Designer</em> is not quite the same as subclassing, for example you cannot get direct access to the form's constructor or destructor. If you need code to be executed by the constructor create a slot called<!-- index init() --> <tt>void init()</tt>; if it exists it will be called from the constructor. Similarly, if you need code to be executed before destruction create a slot called<!-- index destroy() --> <tt>void destroy()</tt>. You can also add your own class variables which will be put in the generated constructor's code, and you can add forward declarations and any includes you retquire. To add a variable or declaration, right click the appropriate item, e.g. Class Variables, then click <b>New</b> then enter your text, e.g. <tt>TQString m_filename</tt>. If one or more items exist, right click to pop up a menu that has New, Edit and Delete options. If you want to enter multiple items, e.g. multiple include files or multiple data members, it is easiest to right click in the relevant section, then click <b>Edit</b> to invoke an Edit dialog. To edit code, just click the name of a function to invoke the code editor. Code editing and creating slots are covered later in the chapter.</p>
<!-- index Subclassing --><p>If you subclass the form you create your own<!-- index .cpp --> <tt>.cpp</tt> files which can contain your own constructor, destructor, functions, slots, declarations and variables as your retquirements dictate. (See <a href="designer-manual-6.html#1">Subclassing</a> for more information.)</p>
<!-- index Code Editing --><!-- index Subclassing --><!-- index Forward declarations --><!-- index Includes --><!-- index Adding!Code --><!-- index Adding!Forward declarations --><!-- index Adding!Includes --><!-- index Adding!Class variables --><!-- index Class variables --><!-- index Deleting!Forward declarations --><!-- index Deleting!Includes --><!-- index Deleting!Class variables --><!-- index Forms!Forward declarations --><!-- index Forms!Class variables --><!-- index Forms!Code editing --><!-- index Forms!destructor --><!-- index Forms!constructor --><p>In the original version of <em>TQt Designer</em> if you wanted to provide code for a form you had to subclass the form and put your code in the subclass. This version fully supports the subclassing approach, but now provides an alternative: placing your code directly into forms. Writing code in <em>TQt Designer</em> is not quite the same as subclassing, for example you cannot get direct access to the form's constructor or destructor. If you need code to be executed by the constructor create a slot called<!-- index init() --> <tt>void init()</tt>; if it exists it will be called from the constructor. Similarly, if you need code to be executed before destruction create a slot called<!-- index destroy() --> <tt>void destroy()</tt>. You can also add your own class variables which will be put in the generated constructor's code, and you can add forward declarations and any includes you require. To add a variable or declaration, right click the appropriate item, e.g. Class Variables, then click <b>New</b> then enter your text, e.g. <tt>TQString m_filename</tt>. If one or more items exist, right click to pop up a menu that has New, Edit and Delete options. If you want to enter multiple items, e.g. multiple include files or multiple data members, it is easiest to right click in the relevant section, then click <b>Edit</b> to invoke an Edit dialog. To edit code, just click the name of a function to invoke the code editor. Code editing and creating slots are covered later in the chapter.</p>
<!-- index Subclassing --><p>If you subclass the form you create your own<!-- index .cpp --> <tt>.cpp</tt> files which can contain your own constructor, destructor, functions, slots, declarations and variables as your requirements dictate. (See <a href="designer-manual-6.html#1">Subclassing</a> for more information.)</p>
</blockquote>
<h4><a name="4-3"></a>Adding Custom Actions</h4>
<p>We want to provide the user with actions that are specific to our application. We want to provide the ability to switch between the two views we will be offering, and allow the user to add colors and set their preferred options. We'll prepare the way by creating a new menu for the view options and by adding a separator to the toolbar.</p>
@@ -301,7 +301,7 @@ body { background: #ffffff; color: black; }
<p align="center"><img align="middle" src="mw-conn4.png" width="600" height="407">
</p>
<h4><a name="6-5"></a>Editing the Code: Setting Up</h4>
<p>There is quite a lot of code to include in the application, but this does not mean that a lot of typing is retquired! All the code is reproduced here so, if you're reading an electronic copy, you can simply cut and paste. If you're reading a print copy, all the code is provided in <tt>/tools/designer/examples/colortool</tt>; simply open the relevant <tt>.ui.h</tt> files and copy and paste from there into your own version of the project.</p>
<p>There is quite a lot of code to include in the application, but this does not mean that a lot of typing is required! All the code is reproduced here so, if you're reading an electronic copy, you can simply cut and paste. If you're reading a print copy, all the code is provided in <tt>/tools/designer/examples/colortool</tt>; simply open the relevant <tt>.ui.h</tt> files and copy and paste from there into your own version of the project.</p>
<blockquote>
<p align="center"><b> Cutting &amp; Pasting Into the Code Editor</b></p>
<p>If you cut and paste code from this manual, because we've indented the code for readability, the code will be over-indented in <em>TQt Designer</em>. This is easily solved. Simply select the function containing the pasted code (either with the mouse, or <b>Shift+Arrow</b>s) and press <b>Tab</b>: this will make <em>TQt Designer</em> fix the indentation. Note that you must select the <em>entire</em> function, including its name and parameters.</p>
@@ -421,7 +421,7 @@ body { background: #ffffff; color: black; }
}
}
</pre>
<p>This function is at the heart of the application. It visually presents the data to the user. If the table is "dirty" (e.g. if the user has added or deleted colors in the icon view, or has opened a color file) we will populate the table. We start by deleting the contents of every cell. Next we change the number of rows to equal the number of colors in the colors map. For each color we want to display a little square that shows the color, so we create a pixmap of the retquired size.</p>
<p>This function is at the heart of the application. It visually presents the data to the user. If the table is "dirty" (e.g. if the user has added or deleted colors in the icon view, or has opened a color file) we will populate the table. We start by deleting the contents of every cell. Next we change the number of rows to equal the number of colors in the colors map. For each color we want to display a little square that shows the color, so we create a pixmap of the required size.</p>
<p>We now create an iterator for our colors map, and iterate over every color. The colors map has the user's color names as its keys, and <a href="qcolor.html">TQColor</a> instances as values. We retrieve the color and fill our pixmap with that color. We then set the "Name" column (column <tt>COL_NAME</tt>), to have the color's name (<tt>it.key()</tt>) and the pixmap we've just filled with that color. <a href="qcolor.html">TQColor</a>'s <tt>name()</tt> function returns a string that is the hex representation of a color, e.g. "#12AB2F"; we retrieve this and set the second ("Hex") column to this value.</p>
<p>If the user wants to see if which colors are web colors we create a <a href="qchecktableitem.html">TQCheckTableItem</a>, and check it if it is a web color. (We'll cover <tt>isWebColor()</tt> shortly.) We then insert this <a href="qchecktableitem.html">TQCheckTableItem</a> into the "Web" column.</p>
<p>Having populated the table we call <tt>adjustColumn()</tt> to ensure that each column is just wide enough to show its widest entry, and show or hide the "Web" column depending on the user's preference.</p>
@@ -762,7 +762,7 @@ Captures: cap(1) cap(2) cap(3) cap(4)
<p>This is the second revision of this function. Now we only exit if the user has had the opportunity to save any unsaved changes. (We'll make a third and final version of this function later, when we deal with saving user settings.)</p>
<p>Try making and running the program. If you have <tt>rgb.txt</tt> on your system try loading it and saving it under a new name for testing purposes. If you don't have this file, save the standard colors and use those. In the next section we'll cover adding and deleting colors so that you can create your own color files. (If it doesn't build see the <a href="designer-manual-4.html#6">Troubleshooting</a> section.)</p>
<h4><a name="6-28"></a>Editing the Code: The Edit Options</h4>
<p>Adding a new color, finding a color and handling user options all retquire custom dialogs, so we'll defer them until chapter three when we deal with dialogs.</p>
<p>Adding a new color, finding a color and handling user options all require custom dialogs, so we'll defer them until chapter three when we deal with dialogs.</p>
<h4><a name="6-29"></a>editCut()</h4>
<pre> void MainForm::editCut()
{


+ 1
- 1
doc/html/designer-manual-4.html View File

@@ -396,7 +396,7 @@ body { background: #ffffff; color: black; }
}
}
</pre>
<p>We create a new options form, passing it TRUE to make it modal. We set the radio buttons depending on the current setting of the <tt>m_clip_as</tt> variable. We set the check box to correspond with the <tt>m_show_web</tt> variable. We execute the form, and if the user clicks <b>OK</b>, we reflect their choices back into the relevant main form variables. If the user changed the <tt>m_show_web</tt> variable (by clicking the webCheckBox), we mark the table as "dirty" since it will need updating. We then call <tt>populate()</tt> which will update the table view if retquired.</p>
<p>We create a new options form, passing it TRUE to make it modal. We set the radio buttons depending on the current setting of the <tt>m_clip_as</tt> variable. We set the check box to correspond with the <tt>m_show_web</tt> variable. We execute the form, and if the user clicks <b>OK</b>, we reflect their choices back into the relevant main form variables. If the user changed the <tt>m_show_web</tt> variable (by clicking the webCheckBox), we mark the table as "dirty" since it will need updating. We then call <tt>populate()</tt> which will update the table view if required.</p>
<p>Because we use our OptionsForm and access its radio buttons and checkbox we must add "optionsform.h", "qradiobutton.h" and "qcheckbox.h" to our includes in implementation. (Click Object Explorer's Members tab, right click "Includes (in Implementation)", then click <b>Edit</b>. Click <b>Add</b> and enter "optionsform.h"; click <b>Add</b> again and enter "qradiobutton.h"; click <b>Add</b> again and enter "qcheckbox.h". Press <b>Enter</b>, then click <b>Close</b>.)</p>
<p>You should now have added the following declarations to your includes (in implementation):</p>
<ul><li><p>"optionsform.h"</p>


+ 3
- 3
doc/html/designer-manual-5.html View File

@@ -45,11 +45,11 @@ body { background: #ffffff; color: black; }
<ul><li><p>Grouping forms that belong together.</p>
<li><p>Sharing images between different forms.</p>
<li><p>Sharing database information between different forms.</p>
</ul><p>The following sections explain these benefits in more detail, and why project management is retquired to achieve them.</p>
</ul><p>The following sections explain these benefits in more detail, and why project management is required to achieve them.</p>
<h4><a name="2-1"></a>Grouping forms</h4>
<p>Grouping forms means that <em>TQt Designer</em> maintains a list of the <tt>.ui</tt> files that belong to the same project. This makes it easy to switch between forms with a single mouse click.</p>
<h4><a name="2-2"></a>Sharing images in a image collection</h4>
<p>In TQt 2.x's <em>TQt Designer</em> each form included the images it retquired and no images were shared. This led to duplication when several forms needed to use the same images. Furthermore the images were stored in the XML <tt>.ui</tt> files which made them large.</p>
<p>In TQt 2.x's <em>TQt Designer</em> each form included the images it required and no images were shared. This led to duplication when several forms needed to use the same images. Furthermore the images were stored in the XML <tt>.ui</tt> files which made them large.</p>
<p>As a workaround, we introduced a pixmap-loading function that you could define in <em>TQt Designer</em>. It then was your responsibility to provide the implementation of this function in your application code. The big disadvantage of this approach was that you couldn't see the images during the design process in <em>TQt Designer</em>. This not only makes designing a form less visually interesting, but also has a noticeable impact on geometry management.</p>
<p>In the TQt 3.0 version of <em>TQt Designer</em> we've introduced the concept of a project image collection. If you use a project you can add images to the project's image collection, and these images can be shared and used by any of the forms you include in the project. The images are stored as PNGs (portable network graphics) in a subdirectory, <tt>images/</tt>, inside the project's directory. Whenever you modify the image collection, <em>TQt Designer</em> creates a source file which contains both the image data in binary format and a function to instantiate the images. The images are accessible by all forms in the project and the data is shared.</p>
<p>A further benefit of using an image collection is that the images are added to the default TQMimeSourceFactory. This way they are accessible from rich-text labels, What's This? context help and even tooltips through standard HTML image tags. The <em>source</em> argument of the image tag is simply the image's name in the image collection. This also works during the design process in <em>TQt Designer</em>.</p>
@@ -59,7 +59,7 @@ body { background: #ffffff; color: black; }
<p>In most non-trivial database applications you will want to access the database from more than one form. This is why the <tt>.db</tt> file is part of a project, not just part of a single form.</p>
<h4><a name="2-4"></a>.pro files</h4>
<p><em>TQt Designer</em> needs to store information on projects, for example, the list of forms, the image collection and information about available databases and how to access them. The majority of TQt users already use a project file format to create multiplatform makefiles: <tt>tmake</tt> (and with TQt 3.0 <tt>qmake</tt>) project <tt>.pro</tt> files. These files already contain the list of forms, <tt>.ui</tt> files, used in the project for <tt>uic</tt>.</p>
<p>We've extended the sections in the <tt>.pro</tt> file to include the extra information that <em>TQt Designer</em> needs to manage projects. For example, when you add a form to your project in <em>TQt Designer</em>, it is automatically added to the FORMS section of the project file, and thus <tt>qmake</tt> will generate the retquired build rules without any further work. Similarly, the images are added to the IMAGES section and thus gets automatically compiled into your executable.</p>
<p>We've extended the sections in the <tt>.pro</tt> file to include the extra information that <em>TQt Designer</em> needs to manage projects. For example, when you add a form to your project in <em>TQt Designer</em>, it is automatically added to the FORMS section of the project file, and thus <tt>qmake</tt> will generate the required build rules without any further work. Similarly, the images are added to the IMAGES section and thus gets automatically compiled into your executable.</p>
<p>We don't force you to use <tt>qmake</tt>; if you prefer another build system, for example automake/autoconf or jam, you can still continue to use it. Look upon the <tt>.pro</tt> file as a file that describes the GUI part of your application. All you need to do -- as previously -- is add the <tt>.ui</tt> files and the images collection to your own Makefiles.</p>
<h3><a name="3"></a>Extending the functionality of a form</h3>
<p>First let us look at a small figure that shows the relationship between <tt>.ui</tt> files, generated code and application code:</p>


+ 4
- 4
doc/html/designer-manual-6.html View File

@@ -95,7 +95,7 @@ int main( int argc, char *argv[] )
}
</pre>
<p>Note that we're including <tt>creditformbase.h</tt> and instantiating a CreditFormBase object; once we've written our subclass we'll replace the header with our subclass, <tt>creditform.h</tt>, and instantiate a CreditForm.</p>
<p>We can now generate the application with <tt>qmake</tt>, e.g. <tt>qmake -o Makefile credit.pro</tt>, make it and run it. The form should run fine, but doesn't yet have the behaviour we retquire.</p>
<p>We can now generate the application with <tt>qmake</tt>, e.g. <tt>qmake -o Makefile credit.pro</tt>, make it and run it. The form should run fine, but doesn't yet have the behaviour we require.</p>
<h5><a name="1-3-3"></a>Creating the Subclass</h5>
<p>We need to create a header and an implementation file for our subclass. The code for our subclass is minimal. The header file is <tt>qt/tools/designer/examples/credit/creditform.h</tt>:</p>
<pre> #include "creditformbase.h"
@@ -174,7 +174,7 @@ FORMS = mainform.ui
LANGUAGE = C++
INCLUDEPATH += $(QTDIR)/tools/designer/uilib
</pre>
<p>We do <em>not</em> include the <tt>creditformbase.ui</tt> file since this file will be read at runtime, as we'll see shortly. We must include the <tt>tqui</tt> library since the functionality we retquire is not part of the standard TQt library.</p>
<p>We do <em>not</em> include the <tt>creditformbase.ui</tt> file since this file will be read at runtime, as we'll see shortly. We must include the <tt>tqui</tt> library since the functionality we require is not part of the standard TQt library.</p>
<h4><a name="2-2"></a>Creating main.cpp</h4>
<p>The<!-- index main.cpp --> <tt>main.cpp</tt> is quite standard. It will invoke the form we're going to create in <em>TQt Designer</em> as its main form. This form will then load and execute the dynamic dialog.</p>
<pre> #include &lt;<a href="qapplication-h.html">qapplication.h</a>&gt;
@@ -217,7 +217,7 @@ INCLUDEPATH += $(QTDIR)/tools/designer/uilib
delete creditForm;
}
</pre>
<p>The<!-- index create() --> <tt>create()</tt> function is a static <a href="qwidgetfactory.html">TQWidgetFactory</a> function. It loads the specified<!-- index .ui --> <tt>.ui</tt> file and returns a pointer to the toplevel <a href="qwidget.html">TQWidget</a> created from the<!-- index .ui --> <tt>.ui</tt> file. We have cast the pointer to <a href="qdialog.html">TQDialog</a> since we know that the <tt>creditformbase.ui</tt> file defines a <a href="qdialog.html">TQDialog</a>. After creating the dialog we<!-- index exec() --> <tt>exec()</tt> it. If the user clicked <b>OK</b> the dialog returns Accepted and we enter the body of the <tt>if</tt> statement. We want to know the amount of credit that the user selected. We call the<!-- index child() --> <tt>child()</tt> function on the dialog passing it the name of the widget we're interested in. The<!-- index child() --> <tt>child()</tt> function returns a pointer to the widget with the name we passed, or returns 0 if no widget of that name was found. In the example we call<!-- index child() --> <tt>child()</tt> to get a pointer to the 'amountSpinBox'. If the pointer we get back is not 0 we set the rating text to the amount in the dialog's spin box. At the end we delete the dynamic dialog. Deleting the dialog ensures that we free up its resources as soon as it is no longer retquired.</p>
<p>The<!-- index create() --> <tt>create()</tt> function is a static <a href="qwidgetfactory.html">TQWidgetFactory</a> function. It loads the specified<!-- index .ui --> <tt>.ui</tt> file and returns a pointer to the toplevel <a href="qwidget.html">TQWidget</a> created from the<!-- index .ui --> <tt>.ui</tt> file. We have cast the pointer to <a href="qdialog.html">TQDialog</a> since we know that the <tt>creditformbase.ui</tt> file defines a <a href="qdialog.html">TQDialog</a>. After creating the dialog we<!-- index exec() --> <tt>exec()</tt> it. If the user clicked <b>OK</b> the dialog returns Accepted and we enter the body of the <tt>if</tt> statement. We want to know the amount of credit that the user selected. We call the<!-- index child() --> <tt>child()</tt> function on the dialog passing it the name of the widget we're interested in. The<!-- index child() --> <tt>child()</tt> function returns a pointer to the widget with the name we passed, or returns 0 if no widget of that name was found. In the example we call<!-- index child() --> <tt>child()</tt> to get a pointer to the 'amountSpinBox'. If the pointer we get back is not 0 we set the rating text to the amount in the dialog's spin box. At the end we delete the dynamic dialog. Deleting the dialog ensures that we free up its resources as soon as it is no longer required.</p>
<p>We used the<!-- index child() --> <tt>child()</tt> to gain access to a widget within the dynamic dialog, passing it the name of the widget we were interested in. In some situations we might not know what a widget is called. We can access the first widget of a specified class by calling<!-- index child() --> <tt>child()</tt> with a null widget name and a classname, e.g. <tt>child(0,"TQPushButton")</tt>. This will return a pointer to the first <a href="qpushbutton.html">TQPushButton</a> it finds (or 0 if there isn't one). If you want pointers to all the widgets of a given class you can call the<!-- index TQObject::queryList() --> <tt>TQObject::queryList()</tt> function, passing it the name of the class. It returns a <a href="qobjectlist.html">TQObjectList</a> pointer which points to every object in the dialog that is derived from the given class. See the online <a href="http://doc.trolltech.com/qobject.html">TQObject</a> documentation for further details.</p>
<h5><a name="2-3-3"></a>Implementing Slots for Dynamic Dialogs</h5>
<!-- index Signals and Slots!Dynamic Dialogs --><!-- index Dynamic Dialogs --><p>There is one outstanding issue that we haven't addressed: the dynamic dialog does not have the behaviour of the original credit dialog because we have not implemented the <tt>setAmount()</tt> slot. We can implement slots for dynamic dialogs by creating a <a href="qobject.html">TQObject</a> subclass. We then create an instance of this subclass and pass a pointer to it to the<!-- index TQWidgetFactory::create() --> <tt>TQWidgetFactory::create()</tt> function which will connect the dynamic dialog's signals to the slots implemented in our subclass.</p>
@@ -260,7 +260,7 @@ private:
};
</pre>
<!-- index Macros!Q_OBJECT --><!-- index Q_OBJECT!Macros --><p>Our class must be a <a href="qobject.html">TQObject</a> subclass and because we're using signals and slots it must include the <tt>Q_OBJECT</tt> macro. We declare a function and the <tt>setAmount()</tt> slot that we wish to implement as well as a private <a href="qdialog.html">TQDialog</a> pointer.</p>
<p>The implementation retquires the header files of the classes it uses:</p>
<p>The implementation requires the header files of the classes it uses:</p>
<pre> #include &lt;<a href="qradiobutton-h.html">qradiobutton.h</a>&gt;
#include &lt;<a href="qspinbox-h.html">qspinbox.h</a>&gt;
#include "receiver.h"


+ 9
- 9
doc/html/designer-manual-7.html View File

@@ -68,8 +68,8 @@ body { background: #ffffff; color: black; }
<a href="qpushbutton.html">TQPushButton</a> *rewind = new <a href="qpushbutton.html">TQPushButton</a>( TQPixmap( rewind_xpm ), 0, this, "vcr_rewind" );
layout-&gt;<a href="qboxlayout.html#addWidget">addWidget</a>( rewind );
</pre>
<p>We create a <a href="qhboxlayout.html">TQHBoxLayout</a> in which we'll place the buttons. We've only shown the rewind button in the code above since all the others are identical except for the names of the buttons, pixmaps and signals. For each of the buttons we retquire we call the <a href="qpushbutton.html">TQPushButton</a> constructor passing it the appropriate embedded pixmap. We then add it to the layout. Finally we connect the button's<!-- index clicked() --> <tt>clicked()</tt> signal to the appropriate <em>signal</em>. Since the<!-- index clicked() --> <tt>clicked()</tt> signals aren't specific to our widget we want to emit signals that reflect the widget's use. The <tt>rewind()</tt>, <tt>play()</tt>, etc. signals are meaningful in the context of our widget so we propagate each button's<!-- index clicked() --> <tt>clicked()</tt> signal to the appropriate widget-specific signal.</p>
<!-- index Forms!Creating Test Harnesses --><p>The implementation is complete, but to make sure that our widget compiles and runs we'll create a tiny test harness. The test harness will retquire two files, a<!-- index .pro --> <tt>.pro</tt> project file and a<!-- index main.cpp --> <tt>main.cpp</tt>. The <tt>qt/tools/designer/examples/vcr/vcr.pro</tt> project file:</p>
<p>We create a <a href="qhboxlayout.html">TQHBoxLayout</a> in which we'll place the buttons. We've only shown the rewind button in the code above since all the others are identical except for the names of the buttons, pixmaps and signals. For each of the buttons we require we call the <a href="qpushbutton.html">TQPushButton</a> constructor passing it the appropriate embedded pixmap. We then add it to the layout. Finally we connect the button's<!-- index clicked() --> <tt>clicked()</tt> signal to the appropriate <em>signal</em>. Since the<!-- index clicked() --> <tt>clicked()</tt> signals aren't specific to our widget we want to emit signals that reflect the widget's use. The <tt>rewind()</tt>, <tt>play()</tt>, etc. signals are meaningful in the context of our widget so we propagate each button's<!-- index clicked() --> <tt>clicked()</tt> signal to the appropriate widget-specific signal.</p>
<!-- index Forms!Creating Test Harnesses --><p>The implementation is complete, but to make sure that our widget compiles and runs we'll create a tiny test harness. The test harness will require two files, a<!-- index .pro --> <tt>.pro</tt> project file and a<!-- index main.cpp --> <tt>main.cpp</tt>. The <tt>qt/tools/designer/examples/vcr/vcr.pro</tt> project file:</p>
<pre>TEMPLATE = app
LANGUAGE = C++
TARGET = vcr
@@ -104,12 +104,12 @@ DBFILE = vcr.db
</ol><p>The remaining items to be completed will depend on the characteristics of the widget you've created. If, for example, your widget can be used to contain other widgets you'd check the Container Widget checkbox. In the case of our Vcr example the only items we need to add are its signals.</p>
<p>Click the Signals tab. Click the <b>New Signal</b> button and type in the signal name 'rewind()'. Click <b>New Signal</b> again and this time type in 'play()'. Add the 'next()' and 'stop()' signals in the same way.</p>
<p>Since our example hasn't any slots or properties we've finished and can click <b>Close</b>. A new icon will appear in <em>TQt Designer</em>'s toolbars which represents the new widget. If you create a new form you can add Vcr widgets and connect the Vcr's signals to your slots.</p>
<p>Incorporating custom widgets that have their own slots and properties is achieved in a similar way to adding signals. All the retquired information is in our custom widget's header file.</p>
<p>Incorporating custom widgets that have their own slots and properties is achieved in a similar way to adding signals. All the required information is in our custom widget's header file.</p>
<a name="creatingplugins"></a><h3><a name="2"></a>Creating Custom Widgets with Plugins</h3>
<!-- index Custom Widgets!Plugins --><!-- index Plugins!Implementing Custom Widgets --><p>This section will show you how to write a custom widget and how to embed the custom widget into a plugin. There are no restrictions or special considerations that must be taken into account when creating a widget that is destined to become a plugin. If you are an experienced TQt programmer you can safely skip the section on creating a custom widget and go directly to <a href="designer-manual-7.html#2-2">Creating a Plugin</a>.</p>
<p>Be aware that if you use the plugin approach to custom widgets, the plugin needs to be available not only to <em>TQt Designer</em> but also to <tt>uic</tt> at compile-time.</p>
<h4><a name="2-1"></a>Creating a Custom Widget</h4>
<!-- index Creating Custom Widgets --><!-- index Widgets!Creating a Custom Widget --><!-- index Subclassing!Widgets --><p>A custom widget is often a specialization (subclass) of another widget or a combination of widgets working together or a blend of both these approaches. If you simply want a collection of widgets in a particular configuration it is easiest to create them, select them as a group, and copy and paste them as retquired within <em>TQt Designer</em>. Custom widgets are generally created when you need to add new functionality to existing widgets or groups of widgets.</p>
<!-- index Creating Custom Widgets --><!-- index Widgets!Creating a Custom Widget --><!-- index Subclassing!Widgets --><p>A custom widget is often a specialization (subclass) of another widget or a combination of widgets working together or a blend of both these approaches. If you simply want a collection of widgets in a particular configuration it is easiest to create them, select them as a group, and copy and paste them as required within <em>TQt Designer</em>. Custom widgets are generally created when you need to add new functionality to existing widgets or groups of widgets.</p>
<!-- index Properties!Creating Custom Properties --><p>We have two recommendations that you should consider when creating a custom widget for a plugin:</p>
<ol type=1><li><p>Using TQt's property system will provide <em>TQt Designer</em> users with a direct means of configuring the widget through the property editor. (See the <a href="http://doc.trolltech.com/properties.html">TQt Properties</a> documentation.)</p>
<li><p>Consider making your widget's public 'set' functions into public slots so that you can perform signal-slot connections with the widget in <em>TQt Designer</em>.</p>
@@ -128,7 +128,7 @@ DBFILE = vcr.db
</pre>
<p>Our widget will be derived from <a href="qwidget.html">TQWidget</a> so we include the <tt>qwidget.h</tt> header file. We also forward declare the two classes that our widget will be built from.</p>
<pre></pre>
<!-- index Macros!Q_OBJECT --><!-- index Q_OBJECT --><!-- index Macros!Q_ENUMS --><!-- index Q_ENUMS --> <p>We include the <tt>Q_OBJECT</tt> macro since this is retquired for classes that declare signals or slots. The <tt>Q_ENUMS</tt> declaration is used to register the Mode enumeration. Our widget has two properties, mode, to store whether the user should select a File or a Directory and fileName which stores the file or directory they chose.</p>
<!-- index Macros!Q_OBJECT --><!-- index Q_OBJECT --><!-- index Macros!Q_ENUMS --><!-- index Q_ENUMS --> <p>We include the <tt>Q_OBJECT</tt> macro since this is required for classes that declare signals or slots. The <tt>Q_ENUMS</tt> declaration is used to register the Mode enumeration. Our widget has two properties, mode, to store whether the user should select a File or a Directory and fileName which stores the file or directory they chose.</p>
<pre> class QT_WIDGET_PLUGIN_EXPORT FileChooser : public <a href="qwidget.html">TQWidget</a>
{
Q_OBJECT
@@ -222,7 +222,7 @@ DBFILE = vcr.db
<p>When <tt>chooseFile()</tt> is called it presents the user with a file or directory dialog depending on the mode. If the user chooses a file or directory the <a href="qlineedit.html">TQLineEdit</a> is updated with the chosen file or directory and the <tt>fileNameChanged()</tt> signal is emitted.</p>
<p>Although these two files complete the implementation of the FileChooser widget it is good practice to write a test harness to check that the widget behaves as expected before attempting to put it into a plugin.</p>
<h5><a name="2-1-3"></a>Testing the Implementation</h5>
<!-- index main.cpp --><!-- index Forms!Creating Test Harnesses --><p>We present a rudimentary test harness which will allow us to run our custom widget. The test harness retquires two files, a <tt>main.cpp</tt> to contain the FileChooser, and a <tt>.pro</tt> file to create the Makefile from. Here is <tt>qt/tools/designer/examples/filechooser/widget/main.cpp</tt>:</p>
<!-- index main.cpp --><!-- index Forms!Creating Test Harnesses --><p>We present a rudimentary test harness which will allow us to run our custom widget. The test harness requires two files, a <tt>main.cpp</tt> to contain the FileChooser, and a <tt>.pro</tt> file to create the Makefile from. Here is <tt>qt/tools/designer/examples/filechooser/widget/main.cpp</tt>:</p>
<pre> #include &lt;<a href="qapplication-h.html">qapplication.h</a>&gt;
#include "filechooser.h"

@@ -245,13 +245,13 @@ CONFIG += qt warn_on release
DBFILE = filechooser.db
DEFINES += FILECHOOSER_IS_WIDGET
</pre>
<p>We can create the makefile using <tt>qmake</tt>: <tt>qmake -o Makefile filechooser.pro</tt>, then we can make and run the harness to test our new widget. Once we're satisfied that the custom widget is robust and has the behaviour we retquire we can embed it into a plugin.</p>
<p>We can create the makefile using <tt>qmake</tt>: <tt>qmake -o Makefile filechooser.pro</tt>, then we can make and run the harness to test our new widget. Once we're satisfied that the custom widget is robust and has the behaviour we require we can embed it into a plugin.</p>
<h4><a name="2-2"></a>Creating a Plugin</h4>
<!-- index Creating Plugins --><!-- index Plugins!Creating a Plugin --><!-- index Component!Plugins --><p>TQt Plugins can be used to provide self-contained software components for TQt applications. TQt currently supports the creation of five kinds of plugins: codecs, image formats, database drivers, styles and custom widgets. In this section we will explain how to convert our filechooser custom widget into a <em>TQt Designer</em> custom widget plugin.</p>
<p>A <em>TQt Designer</em> custom widget plugin is always derived from <a href="qwidgetplugin.html">TQWidgetPlugin</a>. The amout of code that needs to be written is minimal.</p>
<p>To make your own plugin it is probably easiest to start by copying our example<!-- index plugin.h --> <tt>plugin.h</tt> and<!-- index plugin.cpp --> <tt>plugin.cpp</tt> files and changing 'CustomWidgetPlugin' to the name you wish to use for your widget plugin implementation class. Below we provide an introduction to the header file although it needs no changes beyond class renaming. The implementation file retquires simple changes, mostly more class renaming; we will review each function in turn and explain what you need to do.</p>
<p>To make your own plugin it is probably easiest to start by copying our example<!-- index plugin.h --> <tt>plugin.h</tt> and<!-- index plugin.cpp --> <tt>plugin.cpp</tt> files and changing 'CustomWidgetPlugin' to the name you wish to use for your widget plugin implementation class. Below we provide an introduction to the header file although it needs no changes beyond class renaming. The implementation file requires simple changes, mostly more class renaming; we will review each function in turn and explain what you need to do.</p>
<h5><a name="2-2-1"></a>The <b>CustomWidgetPlugin</b> Implementation</h5>
<p>We have called our header file<!-- index plugin.h --> <tt>plugin.h</tt> and we've called our plugin class <b>CustomWidgetPlugin</b> since we will be using our plugin class to wrap our custom widgets. We present the entire header file to give you an impression of the scope of the implementation retquired. Most of the functions retquire just a few lines of code.</p>
<p>We have called our header file<!-- index plugin.h --> <tt>plugin.h</tt> and we've called our plugin class <b>CustomWidgetPlugin</b> since we will be using our plugin class to wrap our custom widgets. We present the entire header file to give you an impression of the scope of the implementation required. Most of the functions require just a few lines of code.</p>
<pre> #include &lt;<a href="qwidgetplugin-h.html">qwidgetplugin.h</a>&gt;

class CustomWidgetPlugin : public <a href="qwidgetplugin.html">TQWidgetPlugin</a>


+ 13
- 13
doc/html/designer-manual-8.html View File

@@ -113,7 +113,7 @@ bool createConnections()
<!-- index TQSqlDatabase::database() --><p>You do not need to keep a reference to database connections. If you use a single database connection, this becomes the default connection and database functions will use this connection automatically. We can always get a pointer to any of our connections by calling <tt>TQSqlDatabase::database()</tt>.</p>
<p>If you create a <tt>main.cpp</tt> file using <em>TQt Designer</em>, this file will <em>not</em> include <tt>createConnections()</tt>. We do not include this function because it needs the username and password for the database connection, and you may prefer to handle these differently from our simple example function. As a result, applications that preview correctly in <em>TQt Designer</em> will not run unless you implement your own database connections function.</p>
<h3><a name="2"></a>Using <a href="qdatatable.html">TQDataTable</a></h3>
<p><a href="qdatatable.html">TQDataTable</a>s may be placed on any form to provide browsing of database tables and views. <a href="qdatatable.html">TQDataTable</a>s can also be used to update or delete records in-place, i.e. inside the cells themselves. Inserting records via a <a href="qdatatable.html">TQDataTable</a> usually retquires connecting to the<!-- index primeInsert() --> <tt>primeInsert()</tt> signal, so that we can generate primary keys for example, or provide default values. If we wish to present records using a form view (perhaps combining data from several tables and views) we might use several <a href="qdatabrowser.html">TQDataBrowser</a>s and <a href="qdataview.html">TQDataView</a>s.</p>
<p><a href="qdatatable.html">TQDataTable</a>s may be placed on any form to provide browsing of database tables and views. <a href="qdatatable.html">TQDataTable</a>s can also be used to update or delete records in-place, i.e. inside the cells themselves. Inserting records via a <a href="qdatatable.html">TQDataTable</a> usually requires connecting to the<!-- index primeInsert() --> <tt>primeInsert()</tt> signal, so that we can generate primary keys for example, or provide default values. If we wish to present records using a form view (perhaps combining data from several tables and views) we might use several <a href="qdatabrowser.html">TQDataBrowser</a>s and <a href="qdataview.html">TQDataView</a>s.</p>
<h4><a name="2-1"></a>Quickly Viewing a Database Table</h4>
<p>This example, along with all the other examples in this chapter, has the project name 'book' and uses the database created by the<!-- index book.sql --> <tt>book.sql</tt> script. As we work through the chapter we will build the 'book' application step by step. Create or copy the <tt>qt/tools/designer/examples/book/book1/main.cpp</tt> file shown earlier. The project file for this first example is <tt>qt/tools/designer/examples/book/book1/book.pro</tt>. Start a new project by clicking <b>File|New</b>, then click the 'C++ Project' icon to invoke the <em>Project Settings</em> dialog. Click the ellipsis button to invoke the <em>Save As</em> dialog; navigate to the project's directory (creating it if necessary). Make sure you're in the project's directory, then enter a project name of 'book.pro'. Click the <b>Save</b> button to return to the <em>Project Settings</em> dialog, then click <b>OK</b>. Now click <b>Project|Database Connections</b>. Fill in the connection information appropriate to your database then press <b>Connect</b>. The connection name should now appear in the left hand list box. (If this doesn't happen you'll need to contact your database systems administrator for help.) Close the dialog.</p>
<p>We will now create a new form with a <a href="qdatatable.html">TQDataTable</a> that's connected to one of our database tables.</p>
@@ -144,7 +144,7 @@ bool createConnections()
<!-- index Foreign Keys --><!-- index Databases!Foreign Keys --><p>In most relational databases tables contain fields which are foreign keys into other tables. In our 'book' database example the authorid in the book table is a foreign key into the author table. When we present a form to the end user we do not usually want the foreign key itself to be visible but rather the text associated with it. Thus, we would want the author's name to appear rather than the author id when we show book information. In many databases, this can be achieved by using a view. See your database's documentation for details.</p>
</blockquote>
<h4><a name="2-2"></a>Inserting Records in <a href="qdatatable.html">TQDataTable</a>s</h4>
<!-- index Inserting Records --><!-- index Databases!Inserting Records --><p>Record insertion into a relational database usually retquires the generation of a primary key value which uniquely identifies the record in the table. Also we often want to create default values for some fields to minimize the user's work. We will create a slot to capture the <a href="qdatatable.html">TQDataTable</a>s<!-- index primeInsert() --> <tt>primeInsert()</tt> signal and populate the <a href="qsqlrecord.html">TQSqlRecord</a> insertion buffer with a unique primary key.</p>
<!-- index Inserting Records --><!-- index Databases!Inserting Records --><p>Record insertion into a relational database usually requires the generation of a primary key value which uniquely identifies the record in the table. Also we often want to create default values for some fields to minimize the user's work. We will create a slot to capture the <a href="qdatatable.html">TQDataTable</a>s<!-- index primeInsert() --> <tt>primeInsert()</tt> signal and populate the <a href="qsqlrecord.html">TQSqlRecord</a> insertion buffer with a unique primary key.</p>
<ol type=1><li><p>Click <b>Edit|Slots</b> to invoke the <em>Edit Functions</em> dialog. Click <b>New Function</b>, then enter the slot name <tt>primeInsertAuthor(TQSqlRecord*)</tt> into the Function Properties' Function line edit box. Click <b>OK</b>.</p>
<li><p>Click the <b>Connect Signals/Slots</b> toolbar button, then click the AuthorDataTable, drag to the form and release the mouse. The <em>Edit Connections</em> dialog will now appear. Click the<!-- index primeInsert() --> <tt>primeInsert()</tt> signal and then the <tt>primeInsertAuthor()</tt> slot to make the connection. Now click <b>OK</b>.</p>
<li><p>Click the Members tab of the Object Explorer window (click <b>Window|Views|Object Explorer</b> to make the window visible if necessary). Click the <tt>primeInsertAuthor()</tt> slot and an editor window will appear.</p>
@@ -161,15 +161,15 @@ bool createConnections()
</pre>
<p>A <a href="qsqlquery.html">TQSqlQuery</a> object is used to increment and retrieve a unique 'sequence' number for the author table. The signal passed us a pointer to the insertion buffer and we then put the value we've retrieved, i.e. the next sequence number, into the buffer's id field. (Again, note that SQL databases often support a native 'sequence' function. The method used here is inappropriate for production systems, and is for example purposes only. See your database's documentation for details on how to generate unique keys in code. In many cases, the database can generate them automatically, or the database may provide a special syntax for dealing with sequences.)</p>
</ol><!-- index Deleting!Records!Databases --><!-- index Databases!Deleting Records --><!-- index Updating Records --><!-- index Databases!Updating Records --><p>If we rebuild the application it will now support <tt>INSERT</tt> as well as <tt>UPDATE</tt> and <tt>DELETE</tt>. We could easily have added additional code to insert default values, e.g. today's date into a date field, if necessary.</p>
<!-- index Databases!Browsing --><!-- index Databases!Confirmations --><!-- index Browsing Databases --><p>Browsing is supported by clicking records and by using the arrow keys. Once a record is active (highlighted) we can edit the it. Press the <b>Insert</b> key to <tt>INSERT</tt> a new record; press <b>F2</b> to <tt>UPDATE</tt> the current record; press the <b>Del</b> key to <tt>DELETE</tt> the current record. All these operations take place immediately. Users can be given the opportunity to confirm their edits by setting the <a href="qdatatable.html">TQDataTable</a>'s confirmEdits property to True. If the confirmEdits property is True then user confirmation will be retquired for all insertions, updates and deletes. For finer control you can set the confirmInsert, confirmUpdate and confirmDelete properties individually.</p>
<!-- index Databases!Browsing --><!-- index Databases!Confirmations --><!-- index Browsing Databases --><p>Browsing is supported by clicking records and by using the arrow keys. Once a record is active (highlighted) we can edit the it. Press the <b>Insert</b> key to <tt>INSERT</tt> a new record; press <b>F2</b> to <tt>UPDATE</tt> the current record; press the <b>Del</b> key to <tt>DELETE</tt> the current record. All these operations take place immediately. Users can be given the opportunity to confirm their edits by setting the <a href="qdatatable.html">TQDataTable</a>'s confirmEdits property to True. If the confirmEdits property is True then user confirmation will be required for all insertions, updates and deletes. For finer control you can set the confirmInsert, confirmUpdate and confirmDelete properties individually.</p>
<blockquote>
<p align="center"><b> <a href="qdatatable.html">TQDataTable</a> User Interface Interaction</b></p>
<!-- index Databases!User Interface Interaction --><!-- index User Interface Interaction, Databases --><p>The default user-interface behavior for <a href="qdatatable.html">TQDataTable</a>s is as follows:</p>
<ul><li><p>Users can move to records by clicking the scrollbar and clicking records with the mouse. They can also use the keyboard's navigation keys, e.g. <b>Left Arrow</b>, <b>Right Arrow</b>, <b>Up Arrow</b>, <b>Down Arrow</b>, <b>Page Up</b>, <b>Page Down</b>, <b>Home</b> and <b>End</b>.</p>
<li><p><tt>INSERT</tt> is initiated by right-clicking the record and clicking Insert or by pressing the <b>Ins</b> (Insert) key. The user moves between fields using <b>Tab</b> and <b>Shift+Tab</b>. The <tt>INSERT</tt> will take place if the user presses <b>Enter</b> or <b>Tab</b>s off the last field. If autoEdit is TRUE the insert will take place if the user navigates to another record. <tt>INSERT</tt> is cancelled by pressing <b>Esc</b> (Escape). If autoEdit is FALSE navigating to another record also cancels the <tt>INSERT</tt>. Setting confirmInsert to TRUE will retquire the user to confirm each <tt>INSERT</tt>.</p>
<li><p><tt>UPDATE</tt> is initiated by right-clicking the record and clicking Update or by pressing <b>F2</b>. The update will take place if the user presses Enter or Tabs off the last field. If autoEdit is TRUE the update will take place if the user navigates to another record. <tt>UPDATE</tt> is cancelled by pressing <b>Esc</b>. If autoEdit is FALSE navigating to another record also cancels the <tt>UPDATE</tt>. Setting confirmUpdate to TRUE will retquire the user to confirm each <tt>UPDATE</tt>.</p>
<li><p><tt>DELETE</tt> is achieved by right-clicking the record and clicking Delete or by pressing the <b>Del</b> (Delete) key. Setting confirmDelete to TRUE will retquire the user to confirm each <tt>DELETE</tt>.</p>
</ul><p>You can change this default behavior programmatically if retquired.</p>
<li><p><tt>INSERT</tt> is initiated by right-clicking the record and clicking Insert or by pressing the <b>Ins</b> (Insert) key. The user moves between fields using <b>Tab</b> and <b>Shift+Tab</b>. The <tt>INSERT</tt> will take place if the user presses <b>Enter</b> or <b>Tab</b>s off the last field. If autoEdit is TRUE the insert will take place if the user navigates to another record. <tt>INSERT</tt> is cancelled by pressing <b>Esc</b> (Escape). If autoEdit is FALSE navigating to another record also cancels the <tt>INSERT</tt>. Setting confirmInsert to TRUE will require the user to confirm each <tt>INSERT</tt>.</p>
<li><p><tt>UPDATE</tt> is initiated by right-clicking the record and clicking Update or by pressing <b>F2</b>. The update will take place if the user presses Enter or Tabs off the last field. If autoEdit is TRUE the update will take place if the user navigates to another record. <tt>UPDATE</tt> is cancelled by pressing <b>Esc</b>. If autoEdit is FALSE navigating to another record also cancels the <tt>UPDATE</tt>. Setting confirmUpdate to TRUE will require the user to confirm each <tt>UPDATE</tt>.</p>
<li><p><tt>DELETE</tt> is achieved by right-clicking the record and clicking Delete or by pressing the <b>Del</b> (Delete) key. Setting confirmDelete to TRUE will require the user to confirm each <tt>DELETE</tt>.</p>
</ul><p>You can change this default behavior programmatically if required.</p>
</blockquote>
<h4><a name="2-3"></a>Relating Two Tables Together (Master-Detail)</h4>
<!-- index Databases!Master-Detail Relationships --><!-- index Master-Detail Relationships --><p>Databases often have pairs of tables that are related. For example, an invoice table might list the numbers, dates and customers for invoices, but not the actual invoice items, which an invoice item table might store. In the 'book' application we wish to have a <a href="qdatatable.html">TQDataTable</a> that we can use to browse through the authors table and a second <a href="qdatatable.html">TQDataTable</a> to show the books they've written.</p>
@@ -210,7 +210,7 @@ bool createConnections()
BookDataTable-&gt;refresh();
}
</pre>
<p>All that's retquired now is to change the BookDataTable's filter and refresh the <a href="qdatatable.html">TQDataTable</a> to show the results of the filter.</p>
<p>All that's required now is to change the BookDataTable's filter and refresh the <a href="qdatatable.html">TQDataTable</a> to show the results of the filter.</p>
</ol><h5><a name="2-3-2"></a>Preparing the Interface for Drilldown</h5>
<!-- index Databases!Drilldown --><!-- index Drilldown --><p>We can now browse and edit authors and see their books in the BookDataTable. In the next section we explore <a href="qdatabrowser.html">TQDataBrowser</a>, which will allow us to drill down to a dialog through which we can edit books. For now we will add some buttons to the main BookForm which we will use to invoke the book editing dialog.</p>
<ol type=1><li><p>Click the form, then click the <b>Break Layout</b> toolbar button. Resize the form to make room for some buttons at the bottom.</p>
@@ -250,9 +250,9 @@ bool createConnections()
<li><!-- index readFields() --><p><tt>readFields()</tt> to read data from the cursor's edit buffer and<!-- index writeFields() --> <tt>writeFields()</tt> to write the form's data to the cursor's edit buffer;</p>
<li><!-- index clearValues() --><p><tt>clearValues()</tt> to clear the form's values.</p>
</ul><p>If you use <em>TQt Designer</em>'s <a href="qdatabrowser.html">TQDataBrowser</a> wizard you will be given the option of creating a default set of buttons for navigation and editing. The behavior of these buttons is set up using the slots described above to provide the following functionality:</p>
<ul><li><p><tt>INSERT</tt> is initiated by pressing the <b>Ins</b> (Insert) key. The user moves between fields using <b>Tab</b> and <b>Shift+Tab</b>. If the user presses the Update button the <tt>INSERT</tt> will take place and the user will be taken to the record they have just inserted. If the user presses the Insert button (i.e. a second time) the <tt>INSERT</tt> will take place and a new insertion will be initiated. If autoEdit is TRUE the <tt>INSERT</tt> will take place if the user navigates to another record. <tt>INSERT</tt> is cancelled by pressing the <b>Esc</b> key or by pressing the <b>Del</b> (Delete) key. If autoEdit is FALSE then navigating to another record also cancels the <tt>INSERT</tt>. Setting confirmInsert to TRUE will retquire the user to confirm each <tt>INSERT</tt>.</p>
<li><p><tt>UPDATE</tt> is automatically initiated whenever the user navigates to a record. An update will take place if the user presses the Update button. If autoEdit is TRUE the update will take place if the user navigates to another record. <tt>UPDATE</tt> is cancelled by pressing the <b>Esc</b> key or by pressing the <b>Del</b> button. If autoEdit is FALSE then navigating to another record also cancels the <tt>UPDATE</tt>. Setting confirmUpdate to TRUE will retquire the user to confirm each <tt>UPDATE</tt>.</p>
<li><p><tt>DELETE</tt> is achieved by pressing the <b>Del</b> key. Setting confirmDelete to TRUE will retquire the user to confirm each <tt>DELETE</tt>.</p>
<ul><li><p><tt>INSERT</tt> is initiated by pressing the <b>Ins</b> (Insert) key. The user moves between fields using <b>Tab</b> and <b>Shift+Tab</b>. If the user presses the Update button the <tt>INSERT</tt> will take place and the user will be taken to the record they have just inserted. If the user presses the Insert button (i.e. a second time) the <tt>INSERT</tt> will take place and a new insertion will be initiated. If autoEdit is TRUE the <tt>INSERT</tt> will take place if the user navigates to another record. <tt>INSERT</tt> is cancelled by pressing the <b>Esc</b> key or by pressing the <b>Del</b> (Delete) key. If autoEdit is FALSE then navigating to another record also cancels the <tt>INSERT</tt>. Setting confirmInsert to TRUE will require the user to confirm each <tt>INSERT</tt>.</p>
<li><p><tt>UPDATE</tt> is automatically initiated whenever the user navigates to a record. An update will take place if the user presses the Update button. If autoEdit is TRUE the update will take place if the user navigates to another record. <tt>UPDATE</tt> is cancelled by pressing the <b>Esc</b> key or by pressing the <b>Del</b> button. If autoEdit is FALSE then navigating to another record also cancels the <tt>UPDATE</tt>. Setting confirmUpdate to TRUE will require the user to confirm each <tt>UPDATE</tt>.</p>
<li><p><tt>DELETE</tt> is achieved by pressing the <b>Del</b> key. Setting confirmDelete to TRUE will require the user to confirm each <tt>DELETE</tt>.</p>
</ul></blockquote>
<h5><a name="3-1-2"></a>Performing the Drilldown</h5>
<!-- index Databases!Drilldown --><!-- index Drilldown --><p>We now have a working form for editing book records. We need to start the form when the user clicks our 'Edit Books' button, and to navigate to the record they have selected in the BookDataTable. We also need to provide a means of editing the foreign keys, e.g. authorid.</p>
@@ -344,7 +344,7 @@ bool createConnections()
}
</pre>
<p>Firstly we look up the book's author and secondly we iterate through the <em>ComboBox</em>'s items until we find the author and set the <em>ComboBox</em>'s current item to the matching author.</p>
</ul></ol><p>If the author name has changed or been deleted the query will fail and no author id will be inserted into the buffer causing the <tt>INSERT</tt> to fail. An alternative is to record the author id's as we populate the <em>ComboBox</em> and store them in a <a href="qmap.html">TQMap</a> which we can then look up as retquired. This approach retquires changes to the<!-- index init() --> <tt>init()</tt>, <tt>beforeUpdateBook()</tt> and <tt>primeInsertBook()</tt> functions and the addition of a new function, <tt>mapAuthor()</tt>. The relevant code from <tt>qt/tools/designer/examples/book/book8/editbook.ui</tt> is shown below.</p>
</ul></ol><p>If the author name has changed or been deleted the query will fail and no author id will be inserted into the buffer causing the <tt>INSERT</tt> to fail. An alternative is to record the author id's as we populate the <em>ComboBox</em> and store them in a <a href="qmap.html">TQMap</a> which we can then look up as required. This approach requires changes to the<!-- index init() --> <tt>init()</tt>, <tt>beforeUpdateBook()</tt> and <tt>primeInsertBook()</tt> functions and the addition of a new function, <tt>mapAuthor()</tt>. The relevant code from <tt>qt/tools/designer/examples/book/book8/editbook.ui</tt> is shown below.</p>
<ol type=1><li><p>First we need to create a class variable to map author names to author id's. Click in the Members tab of the Object Explorer, then right click the Class Variables item and click <b>New</b>. Type in 'TQMap&lt;TQString,int&gt; authorMap;'.</p>
<li><p>We now record the author id's in the<!-- index init() --> <tt>init()</tt> function.</p>
<pre> void EditBookForm::init()
@@ -389,7 +389,7 @@ bool createConnections()
}
}
</pre>
</ol><!-- index Databases!Foreign Keys --><!-- index Foreign Keys --> <p>Another approach which is especially useful if the same foreign key lookups are retquired in different parts of the application is to subclass a cursor and use this for our lookups. This is described in the <a href="http://doc.trolltech.com/sql.html">TQt SQL Module documentation</a>, particulary the section on subclassing <a href="qsqlcursor.html">TQSqlCursor</a>.</p>
</ol><!-- index Databases!Foreign Keys --><!-- index Foreign Keys --> <p>Another approach which is especially useful if the same foreign key lookups are required in different parts of the application is to subclass a cursor and use this for our lookups. This is described in the <a href="http://doc.trolltech.com/sql.html">TQt SQL Module documentation</a>, particulary the section on subclassing <a href="qsqlcursor.html">TQSqlCursor</a>.</p>
<p>The 'book' example demonstrates the basic techniques needed for SQL programming with TQt. Additional information on the TQt SQL classes, especially the <a href="qsqlquery.html">TQSqlQuery</a> and <a href="qsqlcursor.html">TQSqlCursor</a> classes is provided in the <a href="http://doc.trolltech.com/sql.html">TQt SQL Module documentation</a>.</p>
<!-- eof -->
<p align="right">[<a href="designer-manual-7.html">Prev: Creating Custom Widgets</a>] [<a href="designer-manual.html">Home</a>] [<a href="designer-manual-9.html">Next: Customizing and Integrating TQt Designer</a>]</p>


+ 3
- 3
doc/html/designer-manual-9.html View File

@@ -82,7 +82,7 @@ body { background: #ffffff; color: black; }
<h3><a name="2"></a>Creating and Using Templates</h3>
<!-- index Creating Templates --><!-- index Templates!Creating and Using --><p><em>TQt Designer</em> supports two approaches to creating template forms. The simplest approach involves little more than saving a<!-- index .ui --> <tt>.ui</tt> file into the templates directory. The second approach involves creating a container widget class to be used as a base class for forms that use the template. We will explain both techniques.</p>
<h4><a name="2-1"></a>Simple Templates</h4>
<p>These templates are most useful when you want to create a whole set of forms which all have some common widgets. For example, you might have a project that will retquire many forms, all of which need to be branded with a company name and logo.</p>
<p>These templates are most useful when you want to create a whole set of forms which all have some common widgets. For example, you might have a project that will require many forms, all of which need to be branded with a company name and logo.</p>
<p>First we'll create the simple template.</p>
<ol type=1><li><p>Click <b>File|New</b> to invoke the <em>New File</em> dialog. Click the Dialog template then click <b>OK</b>.</p>
<li><p>Click the <b>Text Label</b> toolbar button, then click near the top left of the form. Change the font Point Size property to 16 and change the <em>text</em> property to your or your company's name. Click the <b>Line</b> toolbar button, then click the form below the label; click Horizontal on the pop-up menu.</p>
@@ -111,7 +111,7 @@ body { background: #ffffff; color: black; }
<p>If you wish to delete the add-in remove it from the toolbar then delete the<!-- index qmsdev.dll --> <tt>qmsdev.dll</tt> file from the add-ins directory.</p>
<h4><a name="3-1"></a>Creating Makefiles without qmake</h4>
<!-- index Makefiles --><p>The <tt>qmake</tt> tool provided with TQt can create Makefiles appropriate to your platform based on<!-- index .pro --> <tt>.pro</tt> project files. This section describes the dependencies involved in building a TQt application and gives a couple of simple example Makefiles. This section assumes that you have a good understanding of Makefiles.</p>
<!-- index Macros!Q_OBJECT --><!-- index Q_OBJECT --><p><em>TQt Designer</em> produces<!-- index .ui --> <tt>.ui</tt> files which are used to generate<!-- index .h --> <tt>.h</tt> and<!-- index .cpp --> <tt>.cpp</tt> files for the compiler to compile. The<!-- index .ui --> <tt>.ui</tt> files are processed by <tt>uic</tt>. Classes which inherit from <a href="qobject.html">TQObject</a>, e.g. those which use slots and signals, retquire an additional<!-- index .cpp --> <tt>.cpp</tt> file to be generated. These files are generated by the <tt>moc</tt> and are named '<em>moc_</em>file.cpp' where the original<!-- index .cpp --> <tt>.cpp</tt> file is called 'file.cpp'. If your<!-- index .cpp --> <tt>.cpp</tt> file contains the <tt>Q_OBJECT</tt> macro an additional file 'file.moc' should be generated which must be <tt>#include</tt>d in the<!-- index .cpp --> <tt>.cpp</tt>, normally at the end. This retquires an extra dependency being created.</p>
<!-- index Macros!Q_OBJECT --><!-- index Q_OBJECT --><p><em>TQt Designer</em> produces<!-- index .ui --> <tt>.ui</tt> files which are used to generate<!-- index .h --> <tt>.h</tt> and<!-- index .cpp --> <tt>.cpp</tt> files for the compiler to compile. The<!-- index .ui --> <tt>.ui</tt> files are processed by <tt>uic</tt>. Classes which inherit from <a href="qobject.html">TQObject</a>, e.g. those which use slots and signals, require an additional<!-- index .cpp --> <tt>.cpp</tt> file to be generated. These files are generated by the <tt>moc</tt> and are named '<em>moc_</em>file.cpp' where the original<!-- index .cpp --> <tt>.cpp</tt> file is called 'file.cpp'. If your<!-- index .cpp --> <tt>.cpp</tt> file contains the <tt>Q_OBJECT</tt> macro an additional file 'file.moc' should be generated which must be <tt>#include</tt>d in the<!-- index .cpp --> <tt>.cpp</tt>, normally at the end. This requires an extra dependency being created.</p>
<p>Processing<!-- index .ui --> <tt>.ui</tt> files with <tt>uic</tt> is done <em>twice</em>:</p>
<pre>
uic myform.ui -o myform.h
@@ -172,7 +172,7 @@ myform.h: myform.ui
</pre>
<p>To see more sophisticated Makefiles simply generate them using <tt>qmake</tt> on any of your TQt projects or any of the examples supplied with TQt.</p>
<h3><a name="4"></a>Importing Foreign File Formats</h3>
<!-- index Foreign File Formats --><p>To import a file in a supported foreign file format click <b>File|Open</b>, then click the File Type combobox to choose the file type you wish to load. Click the retquired file and <em>TQt Designer</em> will convert and load the file.</p>
<!-- index Foreign File Formats --><p>To import a file in a supported foreign file format click <b>File|Open</b>, then click the File Type combobox to choose the file type you wish to load. Click the required file and <em>TQt Designer</em> will convert and load the file.</p>
<p>The filters that <em>TQt Designer</em> uses to read foreign file formats are 'works in progress'. You may have different filters available in your version of <em>TQt Designer</em> than those described here. The easiest way to see which filters are available is to invoke the file open dialog; all your filters are listed in the File Type combobox.</p>
<h4><a name="4-1"></a>Importing TQt Architect Files</h4>
<!-- index Foreign File Formats!TQt Architect --><!-- index TQt Architect --><p><a href="http://qtarch.sourceforge.net/">TQt Architect</a> is a free GUI builder for TQt written by Jeff Harris and Klaus Ebner. The<!-- index .dlg --> <tt>.dlg</tt> extension is associated with TQt Architect dialog files.</p>


+ 2
- 2
doc/html/distributingqt.html View File

@@ -35,7 +35,7 @@ body { background: #ffffff; color: black; }

<p> This document lists the platform-specific files needed to distribute
TQt applications. We do not include any compiler-specific files that
may also be retquired. (See also, <a href="winsystem.html">Window
may also be required. (See also, <a href="winsystem.html">Window
System-specific Notes</a>.)
<p> <!-- toc -->
<ul>
@@ -81,7 +81,7 @@ path.
version is prefixed with <em>-mt</em>.
<p> <h3> Distributing Plugins
</h3>
<a name="2-1"></a><p> You must include any plugin files retquired by the application.
<a name="2-1"></a><p> You must include any plugin files required by the application.
<p> Plugins must be put into a subdirectory under a directory known to
TQt as a plugin directory. The subdirectory must have the name of the
plugin category (e.g. <tt>styles</tt>, <tt>sqldrivers</tt>, <tt>designer</tt>, etc.).


+ 1
- 1
doc/html/emb-classes.html View File

@@ -163,7 +163,7 @@ typically 2-20KB in size; they can be mmap'd direct from disk in order
to save memory). If a TQPF font is found which matches a font request
no new TQRenderedFont need be created for it. It's possible to strip out
all TQFontFactory support and simply use TQPFs if your font needs are modest
(for instance, if you only retquire a few fixed point sizes). Note that
(for instance, if you only require a few fixed point sizes). Note that
no best-match loading is performed with TQPFs, as opposed to those
loaded via <a href="qfontmanager.html">TQFontManager</a>, so if you don't have the correct TQPF for a point
size, text in that size will simply not be displayed.


+ 1
- 1
doc/html/emb-performance.html View File

@@ -35,7 +35,7 @@ body { background: #ffffff; color: black; }
When building embedded applications on low-powered devices, a number
of options are available that would not be considered in a desktop
application environment. These options reduce the memory and/or CPU
retquirements at the cost of other factors.
requirements at the cost of other factors.
<p> <ul>
<li> <a href="emb-features.html"><b>Tuning the functionality of TQt</a>
<li> <a href="#general">General programming style</a>


+ 2
- 2
doc/html/emb-porting.html View File

@@ -32,7 +32,7 @@ body { background: #ffffff; color: black; }
<td align="right" valign="center"><img src="logo32.png" align="right" width="64" height="32" border="0"></td></tr></table><h1 align=center>Porting your applications to TQt/Embedded</h1>

<p> Existing TQt applications should retquire no porting provided there is no
<p> Existing TQt applications should require no porting provided there is no
platform dependent code. Platform dependent code includes system calls,
calls to the underlying window system (Windows or X11), and TQt platform
specific methods such as <a href="qapplication.html#x11EventFilter">TQApplication::x11EventFilter</a>().
@@ -45,7 +45,7 @@ using <tt>#ifdef</tt> directives:
<tr bgcolor="#d0d0d0"> <td valign="top">TQt/Windows <td valign="top">Q_WS_WIN
<tr bgcolor="#f0f0f0"> <td valign="top">TQt/Embedded <td valign="top">Q_WS_QWS
</table></center>
<p> TQt/Embedded also retquires the following flags to be defined when compiling
<p> TQt/Embedded also requires the following flags to be defined when compiling
applications:
<pre>
-DTQWS -fno-exceptions -fno-rtti


+ 1
- 1
doc/html/emb-running.html View File

@@ -32,7 +32,7 @@ body { background: #ffffff; color: black; }
<td align="right" valign="center"><img src="logo32.png" align="right" width="64" height="32" border="0"></td></tr></table><h1 align=center>Running TQt/Embedded applications</h1>

<p> A TQt/Embedded application retquires a master application to be running
<p> A TQt/Embedded application requires a master application to be running
or to be a master application itself. The master application is
primarily responsible for managing top-level window regions, and
pointer and keyboard input.


+ 2
- 2
doc/html/faq.html View File

@@ -330,7 +330,7 @@ project. Can we transfer the license to another developer?
</h3>
<a name="4-1"></a><p> Yes. TQt licences are for the individual use of named developers. If
the developer associated with a licence leaves the organization, or
moves on to another project that does not retquire a TQt license,
moves on to another project that does not require a TQt license,
another developer can take over the licence. You can change the name
of the developer using a licence at any time, but after a change you
must wait at least six (6) months before changing again.
@@ -420,7 +420,7 @@ software pool to do so without paying license fees.
<p> Although it is possible to write free software for internal
use, it is difficult to ensure that such software is used and
distributed legally. For example, if your free software
retquires any modules that impose conditions on you that
requires any modules that impose conditions on you that
contradict the conditions of the GNU GPL, including, but not
limited to, software patents, commercial license agreements,
copyrighted interface definitions or any sort of


+ 3
- 3
doc/html/gpl.html View File

@@ -151,9 +151,9 @@ above, provided that you also meet all of these conditions:
these conditions, and telling the user how to view a copy of this
License. (Exception: if the Program itself is interactive but
does not normally print such an announcement, your work based on
the Program is not retquired to print an announcement.)
the Program is not required to print an announcement.)

These retquirements apply to the modified work as a whole. If
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
@@ -219,7 +219,7 @@ However, parties who have received copies, or rights, from you under
this License will not have their licenses terminated so long as such
parties remain in full compliance.

5. You are not retquired to accept this License, since you have not
5. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Program or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by


+ 1
- 1
doc/html/helpsystem-example.html View File

@@ -476,7 +476,7 @@ and use the make tool to build the library.

<hr>
<ol> <li><a name="footnote1"></a>
Note that <a href="moc.html#moc">moc</a> retquires that <a href="qobject.html">TQObject</a>
Note that <a href="moc.html#moc">moc</a> requires that <a href="qobject.html">TQObject</a>
is the first base class. <a href="#footnote-call1">Back...</a> <li><a name="footnote2"></a>

Note that we have to explicitly scope the orientation


+ 5
- 5
doc/html/i18n.html View File

@@ -73,10 +73,10 @@ the application usable by people in countries other than one's own.
<!-- endtoc -->

<p> In some cases internationalization is simple, for example, making a US
application accessible to Australian or British users may retquire
application accessible to Australian or British users may require
little more than a few spelling corrections. But to make a US
application usable by Japanese users, or a Korean application usable
by German users, will retquire that the software operate not only in
by German users, will require that the software operate not only in
different languages, but use different input techniques, character
encodings and presentation conventions.
<p> TQt tries to make internationalization as painless as possible for
@@ -94,7 +94,7 @@ time.
<li> Greek
<li> Hebrew
<li> Thai and Lao
<li> All scripts in Unicode 3.2 that do not retquire special processing
<li> All scripts in Unicode 3.2 that do not require special processing
</ul>
<p> On Windows NT/2000/XP and Unix/X11 with Xft (client side font support)
the following languages are also supported:
@@ -149,7 +149,7 @@ takes a <a href="qrect.html">TQRect</a> since this will align in accordance with
<p> <li> When you write your own text input controls, use <a href="qfontmetrics.html#charWidth">TQFontMetrics::charWidth</a>() to determine the width of a character in a
string. In some languages (e.g. Arabic or languages from the Indian
subcontinent), the width and shape of a glyph changes depending on the
surrounding characters. Writing input controls usually retquires a
surrounding characters. Writing input controls usually requires a
certain knowledge of the scripts it is going to be used in. Usually
the easiest way is to subclass <a href="qlineedit.html">TQLineEdit</a> or <a href="qtextedit.html">TQTextEdit</a>.
<p> </ul>
@@ -394,7 +394,7 @@ support many input and output encodings for your users' data. When an
application starts, the locale of the machine will determine the 8-bit
encoding used when dealing with 8-bit data: such as for font
selection, text display, 8-bit text I/O and character input.
<p> The application may occasionally retquire encodings other than the
<p> The application may occasionally require encodings other than the
default local 8-bit encoding. For example, an application in a
Cyrillic KOI8-R locale (the de-facto standard locale in Russia) might
need to output Cyrillic in the ISO 8859-5 encoding. Code for this


+ 1
- 1
doc/html/keyfeatures30.html View File

@@ -151,7 +151,7 @@ existing code which uses these classes will continue to work.
<p> <h3> Regular Expressions
</h3>
<a name="1-6"></a><p> TQt has always provided <a href="qregexp.html#regular-expression">regular expression</a> support, but that support
was pretty much limited to what was retquired in common GUI control
was pretty much limited to what was required in common GUI control
elements such as file dialogs. TQt 3.0 introduces a new regular
expression engine, <a href="qregexp.html">TQRegExp</a>, that supports most of Perl's regex
features and is Unicode based. The most useful additions are support


+ 5
- 5
doc/html/layout.html View File

@@ -103,11 +103,11 @@ only get more space if no other widgets want the space. Of these,
space is allocated to widgets with an <tt>Expanding</tt> size policy first.
<li> Any widgets that are allocated less space than their minimum size
(or minimum size hint if no minimum size is specified) are allocated
this minimum size they retquire. (Widgets don't have to have a minimum
this minimum size they require. (Widgets don't have to have a minimum
size or minimum size hint in which case the strech factor is their
determining factor.)
<li> Any widgets that are allocated more space than their maximum size
are allocated the maximum size space they retquire. (Widgets don't have
are allocated the maximum size space they require. (Widgets don't have
to have a maximum size in which case the strech factor is their
determining factor.)
</ol>
@@ -201,7 +201,7 @@ layout, you should reimplement the following <a href="qwidget.html">TQWidget</a>
<li> <a href="qwidget.html#sizeHint">TQWidget::sizeHint</a>() returns the preferred size of the widget.
<li> <a href="qwidget.html#minimumSizeHint">TQWidget::minimumSizeHint</a>() returns the smallest size the widget can have.
<li> <a href="qwidget.html#sizePolicy">TQWidget::sizePolicy</a>() returns a <a href="qsizepolicy.html">TQSizePolicy</a>; a value describing
the space retquirements of the widget.
the space requirements of the widget.
</ul>
<p> Call <a href="qwidget.html#updateGeometry">TQWidget::updateGeometry</a>() whenever the size hint, minimum size
hint or size policy changes. This will cause a layout recalculation.
@@ -215,12 +215,12 @@ of the widget, and it is used by <a href="qlayout.html">TQLayout</a> subclasses
support heightForWidth() (both <a href="qgridlayout.html">TQGridLayout</a> and <a href="qboxlayout.html">TQBoxLayout</a> support it).
<p> For further guidance when implementing these functions, see their
implementations in existing TQt classes that have similar layout
retquirements to your new widget.
requirements to your new widget.
<p> <h2> Manual Layout
</h2>
<a name="6"></a><p> If you are making a one-of-a-kind special layout, you can also make a
custom widget as described above. Reimplement <a href="qwidget.html#resizeEvent">TQWidget::resizeEvent</a>()
to calculate the retquired distribution of sizes and call <a href="qwidget.html#setGeometry">setGeometry</a>() on each child.
to calculate the required distribution of sizes and call <a href="qwidget.html#setGeometry">setGeometry</a>() on each child.
<p> The widget will get an event with <a href="qevent.html#type">type</a>
<tt>LayoutHint</tt> when the layout needs to be recalculated. Reimplement
<a href="qwidget.html#event">TQWidget::event</a>() to be notified of <tt>LayoutHint</tt> events.


+ 1
- 1
doc/html/license.html View File

@@ -107,7 +107,7 @@ or by others.
<p> 6. You may develop application programs, reusable components and other
software items that link with the original or modified versions of the
Software. These items, when distributed, are subject to the following
retquirements:
requirements:
<p> <blockquote>
a. You must ensure that all recipients of machine-executable forms of
these items are also able to receive and use the complete


+ 2
- 2
doc/html/licenses.html View File

@@ -302,13 +302,13 @@ above.
</ul>
<hr>
<p> TQt supports GIF reading if it is configured that way during
installation (see qgif.h). If it is, we are retquired to state that
installation (see qgif.h). If it is, we are required to state that
"The Graphics Interchange Format(c) is the Copyright property of
CompuServe Incorporated. GIF(sm) is a Service Mark property of