Qt Reference Documentation

Third-Party Licenses Used in Qt

DES ()

FreeType 2 () version 2.3.6

HarfBuzz ()

The Independent JPEG Group's JPEG Software () version 8c

MD4 ( and )

MD5 ( and )

MNG Library () version 1.0.10

PNG Reference Library () version 1.5.1

The ptmalloc memory allocator () version 1.8

SHA-1 ()

SQLite () version 3.7.7.1

TIFF Software Distribution () version 3.9.2

Wintab API ()

Data Compression Library () version 1.2.5

JavaScriptCore

Pixman () version 0.17.11

WebCore (WebKit)

The Public Suffix List

Generic Algorithms

Types of Iterators

Input Iterators

Output Iterators

Forward Iterators

Bidirectional Iterators

Random Access Iterators

Concurrent Filter and Filter-Reduce

Concurrent Filter

Concurrent Filter-Reduce

Additional API Features

Using Iterators instead of Sequence

Using Member Functions

Using Function Objects

Using Bound Function Arguments

Concurrent Map and Map-Reduce

Concurrent Map

Concurrent Map-Reduce

Additional API Features

Using Iterators instead of Sequence

Blocking Variants

Using Member Functions

Using Function Objects

Using Bound Function Arguments

Asynchronous Run

Running a Function in a Separate Thread

Passing Arguments to the Function

Returning Values from the Function

Additional API Features

Using Member Functions

Using Bound Function Arguments

Math Functions

Endian Conversion Functions

Global Qt Declarations

Types

Functions

Macros

Macros for Defining Plugins

Drawing Utility Functions

QML AnchorAnimation Element

QML AnchorChanges Element

QML AnimatedImage Element

Example Usage

QML Animation Element

QML Behavior Element

QML Binding Element

QML BorderImage Element

Example Usage

Quality and Performance

QML ColorAnimation Element

QML Column Element

Example Usage

Using Transitions

Limitations

QML Component Element

QML Connections Element

QML DoubleValidator Element

QML Flickable Element

Example Usage

Limitations

QML Flipable Element

Example Usage

QML Flow Element

Example Usage

Using Transitions

Limitations

QML FocusPanel Element

QML FocusScope Element

QML FolderListModel Element

Filtering

Example Usage

Path Separators

QML FontLoader Element

QML GestureArea Element

QML Gradient Element

Example Usage

Performance and Limitations

QML GradientStop Element

QML Grid Element

Example Usage

Using Transitions

Limitations

QML GridView Element

Example Usage

Hardware Acceleration and Embedded Platforms.

Abstract

Hardware Acceleration

Qt for Embedded Graphics pipeline

Hardware configuration requirements

Different architectures

Recommended use of hardware acceleration based on hardware

Supported platforms

QML Image Element

Example Usage

Performance

QML IntValidator Element

QML Item Element

Key Handling

Layout Mirroring

QML KeyEvent Element

QML KeyNavigation Element

QML Keys Element

Example Usage

Key Handling Priorities

QML LayoutItem Element

QML LayoutMirroring Element

QML ListElement Element

Referencing Roles

Example Usage

QML ListModel Element

Example Usage

Modifying List Models

Using Threaded List Models with WorkerScript

Restrictions

QML ListView Element

Example Usage

QML Loader Element

Loader sizing behavior

Receiving signals from loaded items

Focus and key events

QML MouseArea Element

Example Usage

QML MouseEvent Element

QML NumberAnimation Element

QML Package Element

QML ParallelAnimation Element

QML ParentAnimation Element

QML ParentChange Element

QML ParticleMotionGravity Element

QML ParticleMotionLinear Element

QML ParticleMotionWander Element

QML Particles Element

QML Path Element

QML PathAttribute Element

QML PathCubic Element

QML PathElement Element

QML PathLine Element

QML PathPercent Element

QML PathQuad Element

QML PathView Element

QML PauseAnimation Element

QML PinchArea Element

QML PinchEvent Element

QML PropertyAction Element

QML PropertyAnimation Element

QML PropertyChanges Element

Resetting property values

Immediate property changes in transitions

QAxContainer Module

License Information

QAxServer Module

License Information

QML Qt Element

Enums

Types

Date/Time Formatters

Dynamic Object Creation

QML QtObject Element

Qt3Support Module

QtCore Module

QtDBus module

Qt Declarative Module

QtDesigner Module

QtGui Module

QtHelp Module

License Information

QtMultimedia Module

QtNetwork Module

QtOpenGL Module

QtOpenVG Module

QtScript Module

License Information

QtScriptTools Module

Configuring the Build Process

QtSql Module

QtSvg Module

License Information

QtTest Module

QtUiTools Module

WebKit in Qt

Including In Your Project

Notes

Architecture

Netscape Plugin Support

License Information

QtXml Module

QtXmlPatterns Module

Further Reading

License Information

QML Rectangle Element

Appearance

Example Usage

Performance

QML RegExpValidator Element

QML Repeater Element

Considerations when using Repeater

QML Rotation Element

QML RotationAnimation Element

QML Row Element

Example Usage

Using Transitions

Limitations

QML Scale Element

QML ScriptAction Element

QML SequentialAnimation Element

QML ShaderEffectItem Element

QML ShaderEffectSource Element

QML SmoothedAnimation Element

QML SpringAnimation Element

QML State Element

QML StateChangeScript Element

QML StateGroup Element

QML SystemPalette Element

QML Text Element

QML TextEdit Element

QML TextInput Element

QML Timer Element

QML Transform Element

QML Transition Element

QML Translate Element

QML Vector3dAnimation Element

QML VisualDataModel Element

QML VisualItemModel Element

QML WebView Element

Appearance

User Interaction and Navigation

Example Usage

QML WorkerScript Element

Restrictions

QML XmlListModel Element

Using key XML roles

QML XmlRole Element

Abstract Widget Classes

Standard Accelerator Keys

Accessibility Classes

Accessibility

Introduction

Architecture

Accessibility in Qt

The Accessible Object Tree

The Static QAccessible Functions

Enabling Accessibility Support

Implementing Accessibility

The QAccessibleObject and QAccessibleWidget Convenience Classes

QAccessibleWidget Example

Handling Action Requests from Clients

Implementing Accessible Plugins

Implementing Interface Factories

Further Reading

action

Using ActiveX controls and COM in Qt

Using the Library

Distributing QAxContainer Applications

Instantiating COM Objects

Typical Error Messages

Requested control could not be instantiated

Accessing the Object API

Generating a C++ Namespace

Call-by-Name

Calling Function Through a Script Engine

Calling a Function Using the Native COM Interfaces

Typical Error Messages

QAxBase::internalInvoke: No such method

Error calling IDispatch member: Non-optional parameter missing

Error calling IDispatch member: Type mismatch in parameter n

QAxScriptManager::call(): No script provides this function

Dot Net Example (ActiveQt)

Qt vs. .NET

Walkthrough: .NET interop with MC++ and IJW

Walkthrough: .NET/COM Interop with ActiveQt

Starting a Project

Importing Qt Widgets

Using Qt Widgets

Handling Qt Signals

Summary

Limitations

Performance Considerations

The dumpcpp Tool (ActiveQt)

The dumpdoc Tool (ActiveQt)

IDC - The Interface Description Compiler (ActiveQt)

Building ActiveX servers in Qt

Using the Library

Out-of-Process vs. In-Process

Typical Errors During the Post-Build Steps

The Server Executable Crashes

The Server Executable Is Not a Valid Win32 Application

"Unable to locate DLL"

"Cannot open file ..."

Implementing Controls

Data Types

Sub-Objects

Property Notification

Serving Controls

Typical Compile-Time Problems

"No overloaded function takes 2 parameters"

"Syntax error: bad suffix on number"

"Unresolved external symbol _ucm_instantiate"

"_ucm_initialize already defined in ..."

Distributing QAxServer Binaries

Installing Stand-Alone Servers

Installing In-Process Servers

Distributing Servers over the Internet

Using the Controls

Supported and Unsupported ActiveX Clients

Supported Clients

Unsupported Clients

Typical Runtime Errors

The Server Does Not Respond

The Object Cannot Be Created

Debugging Runtime Errors

Class Information and Tuning

Developing Licensed Components

More Interfaces

testcon - An ActiveX Test Container (ActiveQt)

Tools for ActiveQt

Qt's ActiveX Framework (ActiveQt)

COM App Example (ActiveQt)

Hierarchy Example (ActiveQt)

Menus Example (ActiveQt)

Multiple Example (ActiveQt)

OpenGL Example (ActiveQt)

Qutlook Example (ActiveQt)

Simple Example (ActiveQt)

Web Browser Example (ActiveQt)

Wrapper Example (ActiveQt)

Advanced Widgets

Qt Examples

Qt Quick Example Code

Qt Mobility Example Code

Qt Examples by Module or Technology

Animation Framework

The Animation Framework

The Animation Architecture

Classes in the Animation Framework

Animating Qt Properties

Animations and the Graphics View Framework

Easing Curves

Putting Animations Together

Animations and States

Animated Tiles Example

Application Chooser Example

Easing Curves Example

Move Blocks Example

The Function

The Function

The StateSwitcher Class

The StateSwitchTransition Class

The StateSwitchEvent Class

The QGraphicsRectWidget Class

Moving On

States Example

Stickman Example

Annotated Class List

Widget Appearance and Style

Setting the Application Icon

Setting the Application Icon on Windows

Setting the Application Icon on Mac OS X

Setting the Application Icon on Common Linux Desktops

K Desktop Environment (KDE)

GNOME

Setting the Application Icon on the Symbian platform

Window and Dialog Widgets

Primary and Secondary Windows

Main Windows and Dialogs

Window Geometry

X11 Peculiarities

Symbian Peculiarities

Using Qt Assistant as a Custom Help Viewer

Qt Help Collection Files

Displaying Custom Documentation

Changing the Appearance of Qt Assistant

Creating a Custom Help Collection File

Using Qt Assistant Remotely

Compatibility with Old Formats

Qt Assistant in More Detail

Command Line Options

Tool Windows

Documentation Window

Toolbars

Menus

File Menu

Edit Menu

View Menu

Go Menu

Bookmarks Menu

Dialogs

Print Dialog

Preferences Dialog

Find Text Control

Filtering Help Contents

Full Text Searching

Qt Assistant Manual

The One-Minute Guide to Using Qt Assistant

Implementing Atomic Operations

Basic Widgets

Bearer Management

Overview

The API in Detail

Service networks

Managing network sessions

Roaming

Platform capabilities

Best Practice Guides

bool

How to Report a Bug

CatharonLicense.txt

All Classes

Class and Function Documentation

Class Lists

Function Lists

Big5 Text Codec

Big5-HKSCS Text Codec

EUC-JP Text Codec

EUC-KR Text Codec

GBK Text Codec

Shift-JIS Text Codec

TSCII Text Codec

Codecs

ISO 2022-JP (JIS) Text Codec

color

Qt3 Support Classes

Configuration Options for Qt

Cross platform options:

Third Party Libraries

Qt for Windows only:

Qt for Windows CE only:

Qt for Symbian OS only:

Container Classes

Introduction

The Container Classes

The Iterator Classes

Java-Style Iterators

STL-Style Iterators

The foreach Keyword

Other Container-Like Classes

Algorithmic Complexity

Growth Strategies

Coordinate System

Rendering

Logical Representation

Aliased Painting

Anti-aliased Painting

Transformations

Window-Viewport Conversion

Thanks!

Creating Custom Qt Types

Overview

Creating a Custom Type

Declaring the Type with QMetaType

Creating and Destroying Custom Objects

Making the Type Printable

Further Reading

Database Classes

Serializing Qt Data Types

date

Complex Ping Pong Example

D-Bus Chat Example

D-Bus List Names Example

D-Bus Ping Pong Example

D-Bus Remote Controlled Car Example

Debugging Techniques

Configuring Qt for Debugging

Debugging in Mac OS X and Xcode

Debugging With/Without Frameworks

With Frameworks:

Without Frameworks:

Debug Symbols and Size

Command Line Options Recognized by Qt

Warning and Debugging Messages

Providing Support for the qDebug() Stream Operator

Debugging Macros

Common Bugs

C++ Extensions: QGraphicsLayouts examples

C++ Extensions: Reference examples

Animation: Basics Example

Animation: Basics Property Animation Example

Animation: Behavior Example

Animation: Wiggly Text Example

Animation: Easing Example

Animation: States Example

C++ Extensions: Image Provider Example

C++ Extensions: Network Access Manager Factory Example

C++ Extensions: Plugins Example

LayoutItem Example

QGraphicsGridLayout Example

QGraphicsLinearLayout Example

C++ Extensions: QWidgets Example

Extending QML - Adding Types Example

Declare the Person class

Define the Person class

Running the example

Extending QML - Attached Properties Example

Extending QML - Binding Example

Extending QML - Inheritance and Coercion Example

Declare Boy and Girl

Define People as a base class

Define Boy and Girl

Running the example

Extending QML - Default Property Example

Declaring the BirthdayParty class

Running the example

Extending QML - Grouped Properties Example

Extending QML - Methods Example

Extending QML - Object and List Property Types Example

Declare the BirthdayParty

Define the BirthdayParty

Running the example

Extending QML - Signal Support Example

Extending QML - Property Value Source Example

Internationalization Example

Introduction

Updating Translations

Image Elements: Border Image Example

Image Elements: Image Example

Image Elements: Shadows Image Example

Key Interaction: Focus Example

Models and Views: AbstractItemModel Example

Models and Views: GridView Example

Models and Views: Dynamic List ListView Example

Models and Views: Expanding Delegate ListView Example

Models and Views: Highlight ListView Example

Models and Views: Highlight Ranges ListView Example

Models and Views: Sections ListView Example

Models and Views: Object ListModel Example

Models and Views: Package Example

Models and Views: Parallax Example

Models and Views: PathView Example

Models and Views: String ListModel Example

Models and Views: VisualItemModel Example

Models and Views: Alert WebView Example

Models and Views: Autosize WebView Example

Models and Views: GoogleMaps WebView Example

Models and Views: Inline HTML WebView Example

Models and Views: New Windows WebView Example

Positioners Example

Right-to-left User Interfaces: Layout Direction Example

Right-to-left User Interfaces: Layout Mirroring Example

Right-to-left User Interfaces: Text Alignment Example

Screen Orientation

Labs: Shader Effects

SQL Local Storage Example

Text: Fonts Example

Text: Banner Fonts Example

Text: Fonts Example

Text: Hello Fonts Example

Text: Text Selection Example

Threading: Threaded ListModel Example

Threading: WorkerScript Example

Touch Interaction: Gestures Example

Touch Interaction: MouseArea Example

Toys: Clocks Example

Toys: Corkboards Example

Toys: Dynamic Scene Example

Toys: Tic-Tac-Toe Example

Toys: TV Tennis Example

Chapter 1: Creating a New Type

Chapter 2: Connecting to C++ Methods and Signals

Chapter 3: Adding Property Bindings

Chapter 4: Using Custom Property Types

Chapter 5: Using List Property Types

Chapter 6: Writing an Extension Plugin

QML Advanced Tutorial 1 - Creating the Game Canvas and Blocks

Creating the application screen

Adding and components

QML Advanced Tutorial 2 - Populating the Game Canvas

Generating the blocks in JavaScript

Connecting JavaScript components to QML

QML Advanced Tutorial 3 - Implementing the Game Logic

Making a playable game

Enabling mouse click interaction

Updating the score

A dash of color

A working game

QML Advanced Tutorial 4 - Finishing Touches

Adding some flair

Animating block movement

Animating block opacity changes

Adding particle effects

Keeping a High Scores table

Storing high scores offline

Storing high scores online

That's it!

UI Components: Dial Control Example

UI Components: Flipable Example

UI Components: Progress Bars Example

UI Components: Scroll Bar Example

UI Components: Search Box Example

UI Components: Slide Switch Example

UI Components: Spinner Example

UI Components: Tab Widget Example

XML: XMLHttpRequest Example

Web Browser

Qt Demonstrations

Mobile Applications

Painting

Item Views

SQL

Rich Text

Main Window

Graphics View

Tools

QtWebKit

Phonon

Multimedia

Animation

Embedded Platforms

Affine Transformations

Arthur Plugin

Books Demonstration

Boxes

40000 Chips

Composition Modes

Calculator

Flickr Mobile

Minehunt

Photo Viewer

RSS News

Same Game

Snake

Twitter Mobile

Qt Quick Web Browser

Vector Deformation

Anomaly Demonstration

Embedded Desktop Services Demonstration

Digiflip Demonstration

Embedded SVG Viewer Demonstration

Flickable List Demonstration

Flight Info Demonstration

Fluid Launcher Demonstration

Light Maps Demonstration

Ray Casting Demonstration

Embedded Styles Demonstration

Weather Info Demonstration

Embedded Dialogs

GL Hypnotizer

Gradients

Interview

Mac Main Window Demo

Main Window

Guitar Tuner Demonstration

QCamera Demo

Required capabilities

Compatibility

Qt Bubble Level Demo

Initialising the application

Accessing the accelerometer information

The Qt Quick UI

Quick Hit Demo

Path Stroking

Media Player

Spectrum Analyzer

Spreadsheet

SQL Browser

Sub-Attaq

Text Edit

Undo Framework

Deploying an Application on Mac OS X

The Bundle

Xcode

Static Linking

Building Qt Statically

Linking the Application to the Static Version of Qt

Frameworks

Building Qt as Frameworks

Linking the Application to Qt as Frameworks

Creating the Application Package

Application Dependencies

Qt Plugins

Additional Libraries

Mac OS X Version Dependencies

Deploying Phonon Applications on Mac OS X

Architecture Dependencies

The Mac Deployment Tool

Deploying Plugins

The Plugin Directory

Loading and Verifying Plugins Dynamically

The Build Key

The Plugin Cache

Debugging Plugins

Deploying an Application on the Symbian Platform

Overview

Requirements

Static Linking

Shared Libraries

Building Qt as a Shared Library

Shared Libraries

Deploying an Application on Windows

Static Linking

Building Qt Statically

Linking the Application to the Static Version of Qt

Shared Libraries

Building Qt as a Shared Library

Linking the Application to Qt as a Shared Library

Creating the Application Package

Visual Studio 2005 Onwards

Visual Studio 2008 And Manual Installs

Application Dependencies

Additional Libraries

Qt Plugins

Related Third Party Resources

Deploying an Application on X11 Platforms

Static Linking

Building Qt Statically

Linking the Application to the Static Version of Qt

Shared Libraries

Building Qt as a Shared Library

Linking the Application to Qt as a Shared Library

Creating the Application Package

Application Dependencies

Additional Libraries

Qt Plugins

Deploying Qt Applications

Static vs. Shared Libraries

Deploying Qt's Libraries

Licensing

Platform-Specific Notes

Qt Designer's Buddy Editing Mode

Linking Labels to Buddy Widgets

Removing Buddy Connections

Qt Designer's Signals and Slots Editing Mode

Connecting Objects

Editing and Deleting Connections

Creating Custom Widget Extensions

Extension Types

Creating an Extension

Exposing an Extension to Qt Designer

Creating an Extension Factory

Accessing Qt Designer's Extension Manager

Related Examples

Creating Custom Widgets for Qt Designer

Getting Started

Providing an Interface Description

Notes on the Function

Plugin Requirements

Creating Well Behaved Widgets

Building and Installing the Plugin

A Simple Plugin

Splitting up the Plugin

Related Examples

Creating Main Windows in Qt Designer

Menus

Creating a Menu

Creating a Menu Entry

Toolbars

Creating and Removing a Toolbar

Adding and Removing Toolbar Buttons

Actions

The Action Editor

Creating an Action

Adding an Action

Dock Widgets

Adding a Dock Widget

Customizing Qt Designer Forms

Modifying the Form Settings

Qt Designer's Editing Modes

Using Layouts in Qt Designer

Applying and Breaking Layouts

Setting A Top Level Layout

Horizontal and Vertical Layouts

The Grid Layout

Splitter Layouts

The Form Layout

Shortcut Keys

Qt Designer Manual

Legal Notices

Saving, Previewing and Printing Forms in Qt Designer

Viewing the Form's Code

Saving and Printing the Form

A Quick Start to Qt Designer

Implementation of the Recursive Shadow Casting Algorithm in Qt Designer

Editing Resources with Qt Designer

Defining a Resource File

Using the Resources

Using Stylesheets with Qt Designer

Qt Designer's Tab Order Editing Mode

Setting the Tab Order

Getting to Know Qt Designer

Launching Designer

The User Interface

The Concept of Layouts in Qt

Qt Designer's UI File Format

Using a Designer UI File in Your Application

Compile Time Form Processing

The Direct Approach

The Single Inheritance Approach

Using a Member Variable

Using a Pointer Member Variable

The Multiple Inheritance Approach

Reacting to Language Changes

Run Time Form Processing

The UiTools Approach

Automatic Connections

A Dialog Without Auto-Connect

Widgets and Dialogs with Auto-Connect

Using Containers in Qt Designer

Using Custom Widgets with Qt Designer

Handling Custom Widgets

Promoting Widgets

User Defined Custom Widgets

Qt Designer's Widget Editing Mode

Editing A Form

The Property Editor

Dynamic Properties

The Object Inspector

Calculator Builder Example

Preparation

CalculatorForm Class Definition

CalculatorForm Class Implementation

Calculator Form Example

Preparation

CalculatorForm Class Definition

CalculatorForm Class Implementation

Container Extension Example

The Project File: containerextension.pro

MultiPageWidgetPlugin Class Definition

MultiPageWidgetPlugin Class Implementation

MultiPageWidgetExtensionFactory Class Definition

MultiPageWidgetExtensionFactory Class Implementation

MultiPageWidgetContainerExtension Class Definition

MultiPageWidgetContainerExtension Class Implementation

MultiPageWidget Class Definition

Custom Widget Plugin Example

Preparation

AnalogClock Class Definition and Implementation

AnalogClockPlugin Class Definition

AnalogClockPlugin Implementation

Task Menu Extension Example

The Project File: taskmenuextension.pro

TicTacToePlugin Class Definition

TicTacToePlugin Class Implementation

TicTacToeTaskMenuFactory Class Definition

TicTacToeTaskMenuFactory Class Implementation

TicTacToeTaskMenu Class Definition

TicTacToeTaskMenu Class Implementation

TicTacToeDialog Class Definition

TicTacToeDialog Class Implementation

TicTacToe Class Definition

World Time Clock Builder Example

Preparation

Loading and Building the Form

World Time Clock Plugin Example

WorldTimeClock Class

WorldTimeClockPlugin Class

The Project File: worldtimeclockplugin.pro

Desktop Integration

Useful Classes

Setting the Application Icon

Opening External Resources

System Tray Icons

Desktop Widgets

Screenshot Example

Screenshot Class Definition

Screenshot Class Implementation

System Tray Icon Example

Window Class Definition

Window Class Implementation

Developing Qt Applications for Mac OS X

What Versions of Mac OS X are Supported?

Carbon or Cocoa?

Which One Should I Use?

Building Qt statically

Universal Binaries

Working with several versions of Qt

Day-to-Day Application Development on OS X

Deployment - "Compile once, deploy everywhere"

Cross-Platform and Platform-Specific Development

Cross-Platform Development with Qt

Platform-Specific Development with Qt

Dialog Windows

Class Wizard Example

ClassWizard Class Definition

The ClassWizard Class

The IntroPage Class

The ClassInfoPage Class

The CodeStylePage Class

Config Dialog Example

Extension Example

FindDialog Class Definition

FindDialog Class Implementation

Find Files Example

Window Class Definition

Window Class Implementation

License Wizard Example

The LicenseWizard Class

The IntroPage Class

The EvaluatePage Class

The ConclusionPage Class

SIP Dialog Example

Dialog Class Definition

Dialog Class Implementation

The function

Standard Dialogs Example

Tab Dialog Example

TabDialog Class Definition

TabDialog Class Implementation

GeneralTab Class Definition

GeneralTab Class Implementation

PermissionsTab Class Definition

PermissionsTab Class Implementation

ApplicationsTab Class Definition

ApplicationsTab Class Implementation

Trivial Wizard Example

Introduction Page

Registration Page

Conclusion Page

Function

Drag and Drop

Drag and Drop Classes

Configuration

Dragging

Dropping

Overriding Proposed Actions

Subclassing Complex Widgets

Drag and Drop Actions

Adding New Drag and Drop Types

Drop Actions

Drop Rectangles

The Clipboard

Examples

Interoperating with Other Applications

double

Delayed Encoding Example

SourceWidget Class Definition

SourceWidget Class Implementation

MimeData Class Definition

MimeData Class Implementation

Draggable Icons Example

DragWidget Class Definition

DragWidget Class Implementation

Draggable Text Example

Drop Site Example

DropArea Class Definition

DropArea Class Implementation

DropSiteWindow Class Definition

DropSiteWindow Class Implementation

The main() Function

Fridge Magnets Example

DragLabel Class Definition

DragLabel Class Implementation

DragWidget Class Definition

DragWidget Class Implementation

Dragging

Dropping

Summary

Drag and Drop Puzzle Example

ECMAScript Reference

The Global Object

Value Properties

Function Properties

Constructor Properties

Other Properties

Object Objects

Object Constructor

Function Properties

Object Prototype Object

Function Properties

Function Objects

Function Prototype Object

Function Properties

Array Objects

Array Prototype Object

Function Properties

String Objects

String Prototype Object

Function Properties

Boolean Objects

Boolean Prototype Object

Function Properties

Number Objects

Number Prototype Object

Function Properties

The Math Object

Value Properties

Function Properties

Date Objects

Date Prototype Object

Function Properties

RegExp Objects

RegExp Prototype Object

Function Properties

Error Objects

Error Prototype Object

Value Properties

Function Properties

The JSON Object

Function Properties

Qt Editions

Blur Picker Effect Example

Fade Message Effect Example

Lighting Effect Example

Support for Embedded Linux

Qt on Embedded Linux

Getting Started on Embedded Linux

Key Features for Embedded Linux Development

Compact and Efficient Windowing System QWS

Virtual Frame Buffer (QVFb)

Inter-Process Communication (IPC)

Extended Font Format

enumeration

Event Classes

The Event System

How Events are Delivered

Event Types

Event Handlers

Event Filters

Sending Events

ActiveQt Examples

Animation Framework Examples

D-Bus Examples

Qt Designer Examples

Desktop Examples

Dialog Examples

Drag and Drop Examples

Qt for Embedded Linux Examples

Gestures Examples

Graphics View Examples

Help System Examples

IPC Examples

Item Views Examples

Layout Examples

Qt Linguist Examples

Main Window Examples

Multimedia Examples

Multimedia

Audio Handling

Video Output

Phonon

Network Examples

OpenGL Examples

OpenVG Examples

Painting Examples

Rich Text Examples

Qt Script Examples

SQL Examples

State Machine Examples

Threading and Concurrent Programming Examples

Touch Input Examples

UiTools Examples

WebKit Examples

Widget Examples

XML Examples

Tools Examples

Exception Safety

Exception safe modules

Containers

Out of Memory Handling

Recovering from exceptions

Platform-Specific Exception Handling

The Symbian platform

Platform-Specific Functions

void qt_set_library_config_file(const QString &fileName)

void qt_set_sequence_auto_mnemonic(bool enable)

void qt_x11_wait_for_window_manager(QWidget *widget)

void qt_mac_secure_keyboard(bool enable)

void qt_mac_set_dock_menu(QMenu *menu)

void qt_mac_set_menubar_icons(bool enable)

void qt_mac_set_menubar_merge(bool enable)

void qt_mac_set_native_menubar(bool enable)

void qt_mac_set_press_and_hold_context(bool enable)

Fine-Tuning Features in Qt

Simple Customization

Embedded Linux

Windows CE

Managing Large Numbers of Features

Keyboard Focus

Focus Motion

Tab or Shift+Tab

The User Clicks a Widget

The User Presses a Keyboard Shortcut

The User Rotates the Mouse Wheel

The User Moves the Focus to This Window

font

Motif Extension

All Functions

Qt Widget Gallery

CDE Style Widget Gallery

Buttons

Containers

Item Views

Display Widgets

Input Widgets

Cleanlooks Style Widget Gallery

Buttons

Containers

Item Views

Display Widgets

Input Widgets

GTK Style Widget Gallery

Buttons

Containers

Item Views

Display Widgets

Input Widgets

Macintosh Style Widget Gallery

Buttons

Containers

Item Views

Display Widgets

Input Widgets

Motif Style Widget Gallery

Buttons

Containers

Item Views

Display Widgets

Input Widgets

Plastique Style Widget Gallery

Buttons

Containers

Item Views

Display Widgets

Input Widgets

Windows Style Widget Gallery

Buttons

Containers

Item Views

Display Widgets

Input Widgets

Windows Vista Style Widget Gallery

Buttons

Containers

Item Views

Display Widgets

Input Widgets

Windows XP Style Widget Gallery

Buttons

Containers

Item Views

Display Widgets

Input Widgets

Layout Classes

Gestures Programming

Overview

Using Standard Gestures with Widgets

Handling Events

Standard Procedure for Event Handling

Example Event Handling

Creating Your Own Gesture Recognizer

Filtering Input Events

Custom Gestures

Resetting Gestures

Using a New Gesture Recognizer

Further Reading

Image Gestures Example

ImageWidget Class Definition

ImageWidget Class Implementation

Getting Started Guides

Creating applications using Qt and QML is easy enough once you get started.

Develop with Qt

Configuring Qt and Creator Targets

Configuring Creator for Qt Development:

Qt Platform Support

Qt Technologies

Qt's Meta-Object System

UI Creation

Inter-Process Communication, Threading, and Networking

Rendering and Paint System

QtWebKit Module

Utilities

Testing Qt Applications

Deployment

Ovi Store Publishing

Where to Go from Here

Getting Started Programming with QML

Installation

QML to Build User Interfaces

Defining a Button and a Menu

Basic Component - a Button

Creating a Menu Page

Implementing a Menu Bar

Using Data Models and Views

Building a Text Editor

Declaring a TextArea

Combining Components for the Text Editor

Decorating the Text Editor

Implementing a Drawer Interface

Where to Go from Here

Extending QML using Qt C++

Exposing C++ Classes to QML

Building a Qt Plugin

Registering a Class into QML

Creating QML Properties in a C++ class

Importing a Plugin in QML

Integrating a File Dialog into the File Menu

Text Editor Completion

Running the Text Editor

Getting Started Programming with Qt

Hello Notepad

Learn More

Adding a Quit Button

Learn More

Subclassing QWidget

Learn More

Creating a .pro file

Using a QMainWindow

Learn More

Saving and Loading

Learn More

GNU General Public License (GPL)

The GNU General Public License (Version 3)

Graphics View Classes

Porting to Graphics View

Introduction

Porting from Q3Canvas

Porting table

Porting scenes with tiles

Porting from Q3CanvasView

Porting table

Other differences

Porting from Q3CanvasItem

Q3CanvasPolygonalItem

Q3CanvasEllipse

Q3CanvasLine

Q3CanvasPolygon

Q3CanvasSpline

Q3CanvasRectangle

Q3CanvasSprite

Q3CanvasPixmap, Q3CanvasPixmapArray

Q3CanvasText

Q3CanvasItemList

Other Resources

Graphics View Framework

The Graphics View Architecture

The Scene

The View

The Item

Classes in the Graphics View Framework

The Graphics View Coordinate System

Item Coordinates

Scene Coordinates

View Coordinates

Coordinate Mapping

Key Features

Zooming and rotating

Printing

Drag and Drop

Cursors and Tooltips

Animation

OpenGL Rendering

Item Groups

Widgets and Layouts

QGraphicsWidget

QGraphicsLayout

Embedded Widget Support

Performance

Floating Point Instructions

Anchor Layout Example

Basic Graphics Layouts Example

Window Class Definition

Window Class Implementation

LayoutItem Class Definition

LayoutItem Class Implementation

Colliding Mice Example

Mouse Class Definition

Mouse Class Definition

The Main() Function

Diagram Scene Example

MainWindow Class Definition

MainWindow Class Implementation

DiagramScene Class Definition

DiagramScene Class Implementation

DiagramItem Class Definition

DiagramItem Class Implementation

DiagramTextItem Class Definition

DiagramTextItem Implementation

Arrow Class Definition

Arrow Class Implementation

Drag and Drop Robot Example

Robot Class Definition

ColorItem Class Definition

The main() Function

Elastic Nodes Example

Node Class Definition

Edge Class Definition

GraphWidget Class Definition

The main() Function

Graphics View Flow Layout Example

Pad Navigator Example

RoundRectItem Class Definition

FlippablePad Class Definition

SplashItem Class Definition

PadNavigator Class Definition

The main() Function

Performance Notes

Ported Asteroids Example

Ported Canvas Example

Simple Anchor Layout Example

Weather Anchor Layout Example

Groups Of Related Classes

Books about GUI Design

Buying these Books from Amazon.com

Context-Sensitive Help Example

Remote Control Example

Simple Text Viewer Example

Creating Documentation and Customizing Qt Assistant

Organizing Documentation for Qt Assistant

Customizing Qt Assistant

Controlling Qt Assistant via the Assistant Class

MainWindow Class

FindFileDialog Class

Summary

Help System

Inheritance Hierarchy

How to Learn Qt

Required programming skills

Tools to install

Examples in action

Qt technology guides

Tutorials

Getting most of Qt documentation

Get advice and support from the Qt Community

Books about Qt

Training

Listen to Qt experts on videos

Prove your knowledge

Further Readings and Materials

AccessibleEventID.idl File Reference

Arora Browser

Bug Report Form

Qt Bug Tracker

Task Tracker

Netscape Cookie Specification

HTML5 Canvas API

HTML5 Web Storage

Mac OS X Aqua

Qt Developer Network

Qt Video Portal

Qt Essentials - Application Creation part 2

Qt Essentials - Application Creation part 2

Qt Essentials - Application Creation part 3

Qt Essentials - Application Creation part 3

Qt Essentials - Graphics View part 1

Qt Essentials - Graphics View part 1

Qt Essentials - Graphics View part 2

Qt Essentials - Graphics View part 2

Qt Essentials - Graphics View part 3

Qt Essentials - Graphics View part 3

Qt Essentials - Model/View II part 1

Qt Essentials - Model/View II part 1

Qt Essentials - Model/View II part 3

Qt Essentials - Model/View II part 3

Qt Essentials - Model/View II part 4

Qt Essentials - Model/View II part 4

Qt Essentials - Model/View II part 5

Qt Essentials - Model/View II part 5

Qt Essentials - Model/View I part 1

Qt Essentials - Model/View I part 1

Qt Essentials - Model/View I part 2

Qt Essentials - Model/View I part 2

Qt Essentials - Model/View I part 3

Qt Essentials - Model/View I part 3

Qt Essentials - Model/View I part 4

Qt Essentials - Model/View I part 4

ModelView Programming by basysKom

ModelView Programming by KDAB

Multithreading by ICS

Multithreading by KDAB

QGraphicsView by ICS

QGraphicsView by KDAB

QWebKit by KDAB

Qt Essentials - Application Creation part 1

Qt Essentials - Application Creation part 1

Qt Essentials - Fundamentals of Qt part 2

Qt Essentials - Fundamentals of Qt part 2

Qt Essentials - Fundamentals of Qt part 1

Qt Essentials - Fundamentals of Qt part 1

Qt Mobile Development for Nokia Devices by Digia part 3

Qt Mobile Development for Nokia Devices by Digia part 1

Qt Mobile Development for Nokia Devices by Digia part 2

Qt Essentials by ICS part 1

Qt Essentials by ICS part 2

Qt Essentials by KDAB part 1

Qt Essentials by KDAB part 2

Quick by KDAB part 3

Quick by KDAB part 1

Quick by KDAB part 4

Quick by KDAB part 2

Embedded Development by basysKom

Embedded Development by ICS

UI Development with Qt by ICS

UI Development with Qt by KDAB

Qt Essentials - Widgets part 1

Qt Essentials - Widgets part 1

Qt Essentials - Widgets part 2

Qt Essentials - Widgets part 2

Qt Essentials - Widgets part 3

Qt Essentials - Widgets part 3

Forums on Qt Developer Network

Wiki on Qt Developer Network

Qt Language Bindings on Wiki

Qt Creator Whitepaper

Qt Whitepaper

Qt Modules' Maturity Levels - Modules List

Sun Studio Patches

DeviceAtlas

DirectFB - IDirectFBImageProvider

Qt Docs Web Start Page

external: Qt SDK Manual

Qt Quarterly

QtCanvas

external: Build Settings in Creator

external: Building and Running Applications in Creator

external: Debugging Applications in Creator

external: Maemo Deployment in Creator

external: Symbian Deployment in Creator

external: Setting Up Development Environment for Maemo

external: Setting Up Development Environment for Symbian

external: Creating Qt Projects in Creator

external: Publishing Applications to Ovi Store

external: Developing Qt Quick Applications with Creator

external: Run Settings in Creator

external: Set Compiler Targets in Creator

external: Designer in Creator

external: Developing Qt Quick Applications

external: Qt Creator Manual

external: Qt Mobility Examples

external: Qt Mobility Manual

external: Mobility Location

external: Mobility Multimedia

external: Qt Mobility QML Plugins

Qt Quick Components for Symbian 1.1

external: Qt Simulator Manual

Platform Support Policy

Qt 4 Platforms Overview

Framebuffer HOWTO

Smart Installer

HTML5 Doctor: Introducing Web SQL Databases

Qt Labs

Qt Modules' Maturity Level - Description

qtestlib-tools Announcement

D-Bus Accessibility Bridge

ModelTest

http://linux.sybase.com

Qt Mailing Lists

Microsoft Active Accessibility Event Constants

Mitigating Cross-site Scripting With HTTP-only Cookies

New and Modified BSD Licenses

publicsuffix.org

XML Bookmark Exchange Language Resource Page

Public Qt Repository

qtestlib-tools

Qt Coding Style

Qt Homepage

Qt website

About Qt

Qt Certification

Qt Certification

Developer Zone

Books about Qt Programming

GUI Programming with Qt 3

FAQs

License FAQ

Installation FAQ

Qt Certification Exam Preparation and Prerequisites

Qt Certification Exam Preparation and Prerequisites

Qt Developer Days 2010

Qt eLearning

Qt eLearning Training Materials

Download Qt training materials

Training Day at Qt Developer Days 2009

Downloads

Qt in Education Course Material

Qt Training Partners

Open Enrollment Qt Training Courses

Product Overview

Qt Solutions

CORBA Framework

QtSharedMemory

Calendar Widget

Window Menu

QtWizard

QtWinForms Solution

Qt Creator Product Page

Visual Studio Integration

Whitepapers

Qt Script for Applications (QSA)

Free Software and Contributions

Qt Licensing Overview

Qt License Pricing

Qt SDK Product Page

Porting to Qt 4.2's Graphics View

Customer Success Stories

Partner Directory

Trafikanten

WebKit Open Source Project

Forum Nokia Wiki

Symbian Capabilities

UID Q&As (Symbian Signed)

WURFL

ActivePerl

Thread Time: The Multithreaded Programming Guide

Threads Primer: A Guide to Multithreaded Programming

Pthreads Programming: A POSIX Standard for Better Multiprocessing

Win32 Multithreaded Programming

Amnesty International

CanvasDemos.com: animated cartoon

C++ Reference - memcpy

Common Unix Printing System (CUPS)

JavaScript: The Definitive Guide

Dependency Walker

Graphics Out Of Memory monitor

Symbian Platform Security

DirectFB - IDirectFBPalette

DirectFB - IDirectFBSurface

DirectFB - IDirectFBWindow

DirectFB - CreateInputEventBuffer

DirectFB - DFBSurfaceBlittingFlags

DirectFB - DFBSurfaceDescription

DirectFB - df_window example

ECMA-262

ECMAScript Language Specification

freedesktop.org

Icon Themes Specification

XEmbed Specification

Desktop Entry Specification

http://www.freetds.org

GNOME

GNU General Public License

GNU Lesser General Public License, version 2.1

GNU Emacs

IANA character-sets encoding file

RFC 1179

C++ GUI Programming with Qt 4, 2nd Edition

ISO 8601

KDE

The K Desktop Environment

KDE applications

libusb

OpenSSL Toolkit

"Item View Classes" Chapter of C++ GUI Programming with Qt 4

http://www.postgresql.org

PostgreSQL MinGW/Native Windows

Qt Centre

Qt Extended

RFC 5646 - BCP47

RFC 1738

RFC 1928

RFC 1929

RFC 2045

RFC 2109

RFC 2965

RFC 3174

RFC 3491

RFC 3986

http://www.sqlite.org

http://www.sybase.com

Symbian Signed

http://www.unixodbc.org

SVG Working Group

About SVG

SVG 1.2 Tiny Static Features

CSS3 Color Module specification

Standard CSS2 selector

SVG color keyword names

Mobile SVG Profiles

SVG 1.2 Tiny

HTML 4

HTML 5

State Chart XML: State Machine Notation for Control Abstraction

Selectors API

error handling in the XQuery language

XML Schema

CSS Color Value

Statecharts: A visual formalism for complex systems

XaoS

Submitting to the Mac App Store

JavaScript Resources

About JavaScript

JavaScript Guide

JavaScript Reserved Words

Qt Classes for Internationalization

Writing Source Code for Translation

The Basics

Defining a Translation Context

Using tr() to Obtain a Translation

Translator Comments

Adding Meta-Data to Strings

Disambiguation

Character Encodings

Handling Plurals

Enabling Translation

Further Reading

Implicit Sharing

Overview

Implicit Sharing in Detail

List of Classes

Installing Qt for the Symbian platform from a Binary Package

Installing Qt for the Symbian Platform

Step 1: Set Up the Development Environment

Step 2: Install Qt

Step 3: Set the Environment variables

Step 4: Configure Qt

Step 5: Build Qt

Step 7: Installing Qt Libraries on the Device

Running Qt demos

Installing Qt for Mac OS X

Step 1: Install the License File (commercial editions only)

Step 2: Build the Qt Library

Step 3: Set the Environment variables

Qt Demos and Examples

Installing Qt for the Symbian platform using Linux (experimental)

Step 1: Setup the Development Environment

Step 2: Unpack the Archive

Step 3: Set the Environment Variables

Step 4: Configure Qt

Step 5: Build Qt

Step 6: Building Qt Packages for the Device

Installing Qt Packages to the Device.

Obtaining the App TRK package.

Configuring App TRK on the Phone

Configuring the USB Serial Driver on the Linux System

Building the runonphone Tool.

Installing the Built Package onto the Phone

Running Qt Demos

Installing Qt for Windows

Step 1: Install the License File (commercial editions only)

Step 2: Unpack the Archive

Step 3: Set the Environment variables

Step 4: Build the Qt Library

Qt Demos and Examples

Installing Qt for Windows CE

Step 1: Install the License File (commercial editions only)

Step 2: Set the Environment variables

Step 3: Configure Qt

Step 4: Build Qt Library

Qt Demos and Examples

Installing Qt for X11 Platforms

Step 1: Installing the License File (commercial editions only)

Step 2: Unpacking the Archive

Step 3: Building the Library

Step 4: Set the Environment Variables

Qt Demos and Examples

Installation

int

Internationalization with Qt

Relevant Qt Classes and APIs

Languages and Writing Systems

Step by Step

Use QString for All User-Visible Text

Use tr() for All Literal Text

Use QKeySequence() for Accelerator Values

Use QString::arg() for Dynamic Text

Produce Translations

Support for Encodings

Localize

Dynamic Translation

Translating Non-Qt Classes

System Support

Unix/X11

Windows

Mac OS X

D-Bus

Introduction

The Buses

Concepts

Messages

Service Names

Object Paths

Interfaces

Cheat Sheet

Debugging

Further Reading

Input/Output and Networking

Inter-Process Communication in Qt

TCP/IP

Shared Memory

D-Bus

Qt COmmunications Protocol (QCOP)

Local Fortune Client Example

Local Fortune Server Example

Shared Memory Example

Address Book Example

Overview

TableModel Class Definition

TableModel Class Implementation

AddressWidget Class Definition

AddressWidget Class Implementation

NewAddressTab Class Definition

NewAddressTab Class Implementation

AddDialog Class Definition

AddDialog Class Implementation

MainWindow Class Definition

MainWindow Class Implementation

main() Function

Basic Sort/Filter Model Example

Chart Example

Color Editor Factory Example

Window Class Implementation

ColorListEditor Definition

ColorListEditor Implementation

Further Customization of Item View Editors

Combo Widget Mapper Example

Window Class Definition

Window Class Implementation

Summary and Further Reading

Custom Sort/Filter Model Example

MySortFilterProxyModel Class Definition

MySortFilterProxyModel Class Implementation

Window Class Definition

Window Class Implementation

The Main() Function

Dir View Example

Editable Tree Model Example

Overview

Design

TreeItem Class Definition

TreeItem Class Implementation

TreeModel Class Definition

TreeModel Class Implementation

Fetch More Example

FileListModel Class Definition

FileListModel Class Implementation

Frozen Column Example

FreezeTableWidget Class Definition

FreezeTableWidget Class Implementation

Pixelator Example

ImageModel Class Definition

ImageModel Class Implementation

PixelDelegate Class Definition

PixelDelegate Class Implementation

Using The Custom Delegate

Item Views Puzzle Example

Simple DOM Model Example

Design and Concepts

DomModel Class Definition

DomItem Class Definition

DomItem Class Implementation

DomModel Class Implementation

Basic Properties of The Model

Navigating The Document

Implementation Notes

Simple Tree Model Example

Design and Concepts

TreeItem Class Definition

TreeItem Class Implementation

TreeModel Class Definition

TreeModel Class Implementation

Setting Up the Data in the Model

Simple Widget Mapper Example

Window Class Definition

Window Class Implementation

More Complex Mappings

Spin Box Delegate Example

SpinBoxDelegate Class Definition

SpinBoxDelegate Class Implementation

The Main Function

Star Delegate Example

StarDelegate Class Definition

StarDelegate Class Implementation

StarEditor Class Definition

StarEditor Class Implementation

StarRating Class Definition

StarRating Class Implementation

The Function

Possible Extensions and Suggestions

Known Issues

Layout Management

Introduction

Qt's Layout Classes

Horizontal, Vertical, Grid, and Form Layouts

Laying Out Widgets in Code

Tips for Using Layouts

Adding Widgets to a Layout

Stretch Factors

Custom Widgets in Layouts

Layout Issues

Manual Layout

How to Write A Custom Layout Manager

The Header File ()

The Implementation File ()

Further Notes

Basic Layouts Example

Dialog Class Definition

Dialog Class Implementation

Border Layout Example

Dynamic Layouts Example

Flow Layout Example

FlowLayout Class Definition

FlowLayout Class Implementation

Easing Equations by Robert Penner

GNU Lesser General Public License (LGPL)

The GNU Lesser General Public License (Version 2.1)

Nokia Qt LGPL Exception version 1.0

Licenses for Fonts Used in Qt for Embedded Linux

Adobe Helvetica

Adobe Utopia

Babelfish

Bigelow & Holmes Luxi

Bitstream Charter and Courier

Bitstream Vera

Cursor

DejaVu Fonts

Fixed Fonts

IBM Courier

Micro

Unifont

Other Licenses Used in Qt

Licensing Information

Qt Licenses and Credits

Qt Linguist Manual: Release Manager

Qt Project Files

lupdate

lrelease

Missing Translations

Qt Linguist Manual

Overview of the Translation Process

Qt Linguist Manual: Programmers

Making the Application Translation-Aware

Creating Translation Files

Loading Translations

Making the Application Translate User-Visible Strings

Distinguishing Between Identical Translatable Strings

Helping the Translator with Navigation Information

Handling Plural Forms

Coping With C++ Namespaces

Translating Text That is Outside of a QObject Subclass

Using QCoreApplication::translate()

Using QT_TR_NOOP() and QT_TRANSLATE_NOOP()

Tutorials

Qt Linguist Manual: Translators

The One Minute Guide to Using Qt Linguist

The Qt Linguist Window

Context Window

Strings Window

The Translation Area

Phrases and Guesses Window

Sources and Forms Window

Warnings Window

Translating Multiple Languages Simultaneously

Common Tasks

Leaving a Translation for Later

Phrases That Require Multiple Translations Depending on Context

Changing Keyboard Accelerators

Alt Key Accelerators

Ctrl Key Accelerators

Handling Numbered Arguments and Plurals

Reusing Translations

Changing the Target Locale

Phrase Books

Creating and Editing Phrase Books

Shortcuts for Editing Phrase Books

Batch Translation

Validation Tests

Form Preview

Qt Linguist Reference

File Types

The Menu Bar

The Toolbar

Qt Linguist Manual: TS File Format

Arrow Pad Example

Line by Line Walkthrough

Translating to French and Dutch

Exercises

Hello tr() Example

Line by Line Walkthrough

Running the Application in English

Creating a Latin Message File

Translating to Latin with Qt Linguist

Running the Application in Latin

Troll Print Example

Line by Line Walkthrough

Running Troll Print 1.0 in English and in Portuguese

Troll Print 1.1

Support for Linux/X11

Qt on Linux/X11

Getting Started on Linux/X11

Key Features for Linux/X11 Development

Integrated Development Tools

Cross-Platform Development using Qt Creator

Rich Class Library

Qt is the Foundation of KDE

list

Qt for Mac OS X - Specific Issues

GUI Applications

Painting

Library Support

Qt libraries as frameworks

Bundle-Based Libraries

Combining Libraries

Initialization Order

Compile-Time Flags

Mac OS X Native API Access

Accessing the Bundle Path

Translating the Application Menu and Native Dialogs

User Interface

Right-Mouse Clicks

Menu Bar

Special Keys

Limitations

Menu Actions

Native Widgets

Preparing a Qt application for Mac App Store submission

Changing the location of global Qt settings

Storage location paths

Info.plist and application icon

Debug symbols

Support for Mac OS X

Qt on Mac OS X

Getting Started on Mac

Key Features for Mac OS X Development

Integrated Development Tools

Cross-Platform Development using Qt Creator

Rich Class Library

Supports Intel Hardware and Universal Binaries

Main Window and Related Classes

Application Main Window

Overview of the Main Window Classes

The Main Window Classes

Example Code

Application Example

MainWindow Class Definition

MainWindow Class Implementation

The main() Function

The Resource File

Dock Widgets Example

MainWindow Class Definition

MainWindow Class Implementation

MDI Example

Menus Example

MainWindow Class Definition

MainWindow Class Implementation

Recent Files Example

SDI Example

The Meta-Object System

Using the Meta-Object Compiler (moc)

Usage

Writing Make Rules for Invoking

Command-Line Options

Diagnostics

Limitations

Multiple Inheritance Requires QObject to Be First

Function Pointers Cannot Be Signal or Slot Parameters

Enums and Typedefs Must Be Fully Qualified for Signal and Slot Parameters

Type Macros Cannot Be Used for Signal and Slot Parameters

Nested Classes Cannot Have Signals or Slots

Signal/Slot return types cannot be references

Only Signals and Slots May Appear in the and Sections of a Class

Model/View Classes

Model/View Programming

Introduction to Model/View Programming

The model/view architecture

Models

Views

Delegates

Sorting

Convenience classes

Using models and views

Two models included in Qt

Using views with an existing model

Model classes

Basic concepts

Model indexes

Rows and columns

Parents of items

Item roles

Summary

Using model indexes

Further reading

View classes

Concepts

Using an existing view

Using a model

Using multiple views of a model

Handling selections of items

Sharing selections among views

Delegate classes

Concepts

Using an existing delegate

A simple delegate

Providing an editor

Submitting data to the model

Updating the editor's geometry

Editing hints

Handling selections in item views

Concepts

Current item and selected items

Using a selection model

Selecting items

Reading the selection state

Updating a selection

Selecting all items in a model

Creating new models

Designing a model

A read-only example model

Dimensions of the model

Model headers and data

An editable model

Making the model editable

Inserting and removing rows

Next steps

Item view convenience classes

List widgets

Tree widgets

Table widgets

Common features

Hidden items

Selections

Searching

Using Drag and Drop with Item Views

Using convenience views

Using model/view classes

Enabling drag and drop for items

Encoding exported data

Inserting dropped data into a model

Decoding imported data

Proxy models

Using proxy models

Customizing proxy models

Custom filtering models

Custom sorting models

Custom data models

Model subclassing reference

Item data handling

Read-Only access

Editable items

Resizable models

Lazy population of model data

Navigation and model index creation

Parents and children

Drag and drop support and MIME type handling

MIME data

Accepting dropped data

Convenience views

Performance optimization for large amounts of data

The model/view classes

Related examples

main.cpp

Model/View Tutorial

1. Introduction

1.1 Standard Widgets

1.2 Model/View to the Rescue

1.3 Overview of the Model/View Widgets

1.4 Using Adapters between Forms and Models

2. A Simple Model/View Application

2.1 A Read Only Table

2.2 Extending the Read Only Example with Roles

2.3 A Clock inside a Table Cell

2.4 Setting up Headers for Columns and Rows

2.5 The Minimal Editing Example

3. Intermediate Topics

3.1 TreeView

3.2 Working with Selections

3.3 Predefined Models

3.4 Delegates

3.5 Debugging with ModelTest

4. Good Sources of Additional Information

4.1 Books

4.2 Qt Documentation

All Modules

QML Mouse Events

Mouse Elements

Mouse Event Handling

Defining a Mouse Area

Receiving Events

Enabling Gestures

MouseEvent Object

Accepting Further Signals

Audio Devices Example

AudioInput Example

Audio Output Example

Video Graphics Item Example

Video Widget Example

VideoWidgetSurface Class Definition

VideoWidgetSurface Class Implementation

VideoWidget Class Definition

VideoWidget Class Implementation

All Namespaces

Network Programming API

Network Programming

Qt's Classes for Network Programming

High Level Network Operations for HTTP and FTP

Writing FTP Clients with QFtp

Using TCP with QTcpSocket and QTcpServer

Using UDP with QUdpSocket

Resolving Host Names using QHostInfo

Support for Network Proxies

Bearer Management Support

Bearer Cloud Example

Setting the scene

Responding to changes

Bearer Monitor Example

Blocking Fortune Client Example

Broadcast Receiver Example

Broadcast Sender Example

Network Download Example

Network Download Manager Example

Fortune Client Example

Fortune Server Example

Google Suggest Example

GSuggestCompletion Class Declaration

GSuggestCompletion Class Implementation

SearchBox Class Declaration

SearchBox Class Implementation

HTTP Example

Loopback Example

Multicast Receiver Example

Multicast Sender Example

Network Chat Example

FTP Example

FtpWindow Class Definition

FtpWindow Class Implementation

Secure Socket Client Example

Threaded Fortune Server Example

Torrent Example

License Information

Object Model

Important Classes

Qt Objects: Identity vs Value

Object Trees & Ownership

Overview

Construction/Destruction Order of QObjects

Obsolete Classes

2D Painting Example

Overview

Helper Class Definition

Helper Class Implementation

Widget Class Definition

Widget Class Implementation

GLWidget Class Definition

GLWidget Class Implementation

Window Class Definition

Window Class Implementation

Running the Example

Cube OpenGL ES 2.0 example

Initializing OpenGL ES 2.0

Loading textures from Qt Resource files

Cube Geometry

Perspective projection

Orientation of the 3D object

Framebuffer Object Example

Framebuffer Object 2 Example

Grabber Example

Hello GL Example

GLWidget Class Definition

GLWidget Class Implementation

Widget Construction and Sizing

OpenGL Initialization

Resizing the Viewport

Painting the Scene

Mouse Handling

QtLogo Class

Window Class Definition

Window Class Implementation

Summary

Hello GL ES Example

Using QGLWidget

Porting OpenGL to OpenGL ES

Using QGLPainter

Summary

Overpainting Example

GLWidget Class Definition

GLWidget Class Implementation

Summary

Pixel Buffers Example

Pixel Buffers 2 Example

Sample Buffers Example

Textures Example

Open Source Versions of Qt

OpenVG Rendering in Qt

Building Qt with OpenVG support

Using the OpenVG graphics system

Supported features

Context modes

Transformation matrices

Composition modes

Pens and brushes

Rectangles, lines, and points

Polygons and Ellipses

Other Objects

Clipping

Opacity

Text Drawing

Pixmaps

Pixmap filters

Scrolling

Known issues

OpenVG Star Example

Organizers

All Overviews and HOWTOs

Painting Classes

Rendering in 3D

Basic Drawing Example

Window Class Definition

Window Class Implementation

RenderArea Class Definition

RenderArea Class Implementation

Concentric Circles Example

CircleWidget Class Definition

CircleWidget Class Implementation

Window Class Definition

Window Class Implementation

Font Sampler Example

Image Composition Example

Setting Up The Resource File

ImageComposer Class Definition

ImageComposer Class Implementation

The Function

Painter Paths Example

Window Class Definition

Window Class Implementation

RenderArea Class Definition

RenderArea Class Implementation

SVG Generator Example

The DisplayWidget Class

The Window Class

Further Reading

SVG Viewer Example

Transformations Example

Transformation Operations

RenderArea Class Definition

RenderArea Class Implementation

Window Class Definition

Window Class Implementation

Summary

Paint Devices and Backends

Creating a Paint Device

Selecting the Painting Backend

Drawing and Filling

Drawing

Filling

Reading and Writing Image Files

Rendering SVG files

Styling

Paint System

Topics

Classes for Painting

Notes about PDF Licensing

Phonon Module

Qt Backends

License Information

Phonon multimedia framework

Introduction

Architecture

Media Objects

Sinks

Processors

Playback

Building Graphs

Audio

Audio Effects

Video

Backends

Querying Backends for Support

Installing Phonon

Windows

Windows XP and later Windows versions

Earlier Windows versions than Windows XP

Setting up the environment

Linux

Mac OS X

Deploying Phonon Applications on Windows and Mac OS X

Capabilities Example

Window Class Definition

Window Class Implementation

The main() function

Music Player Example

MainWindow Class Definition

MainWindow Class Implementation

The main() function.

Platform and Compiler Notes - Symbian

Source Compatibility

Binary Compatibility

Supported Devices

Functionality Support

Compiler Notes

Known Issues

Required Capabilities

Multimedia Support

Hardware Accelerated Rendering

OpenGL Support in Symbian

UI Performance in S60 3rd and 5th Edition Devices

Platform and Compiler Notes

Platform-Specific Documentation

Plugin Classes

How to Create Qt Plugins

The Higher-Level API: Writing Qt Extensions

The Lower-Level API: Extending Qt Applications

Locating Plugins

Static Plugins

Deploying and Debugging Plugins

point

Porting Guides

Moving from QSA to Qt Script

The Scripting Language

Classes vs. Objects and Properties

Constructors

Member Functions and Prototypes

Inheritance

Static Members

The Built-in Functions and Library

The C++ API of QSA vs Qt Script

Making QObjects Accessible from Scripts

Accessing Non-QObjects

Data Mapping

Porting UI Files to Qt 4

uic Output

Working with uic3

Limitations of uic3

Icons

Custom Widgets

Porting to Qt 4 - Drag and Drop

Dragging

Dropping

MIME Types and Data

Moving from Qt 3 to Qt 4

Qt 3 Features to Avoid

Painting Outside Paint Events

Qt Designer

Menu Items (QMenuItem)

Pointer-Based Classes (QPtr*)

Other Collection Classes (QStrList, Q*Dict)

Memory Arrays (QMemArray)

URL Operations (QUrlOperator)

SQL Cursors (QSqlCursor)

Domain Name Service (QDns)

Wizard Dialogs (QWizard)

Abstract Grid Views (QGridView)

Specialized Scrolling Views

Significantly Changed Features

Drag and Drop

Extensive Customization of Item Views

Double Buffering

Data-Aware Forms

Dock Windows and Areas

Custom Styles

Events

Porting to Qt 4 - Virtual Functions

Virtual Functions

Porting to Qt 4

Casting and Object Types

Type Names

Enum Values

Properties

Explicit Sharing

Painting and Redrawing Widgets

Compatibility Signals and Slots

QAccel

QAccessibleInterface

QAccessibleTitleBar

QAction

QActionGroup

QApplication

QAquaStyle

QAsciiCache<T>

QAsciiDict<T>

QAsyncIO

QBackInsertIterator

QBitArray

QButton

QButtonGroup

QByteArray

QCache<T>

QCanvas

QColor

QColorGroup

QColorDrag

QComboBox

QCString

QCustomEvent

QDataBrowser

QDataPump

QDataSink

QDataSource

QDataTable

QDataView

QDateEdit

QDateTimeEditBase

QDateTimeEdit

QDeepCopy<T>

QDial

QDict<T>

QDir

QDns

QDockArea

QDockWindow

QDragObject

QDropSite

QEditorFactory

QEventLoop

QFileDialog

QFocusData

QFocusEvent

QFont

QFrame

QFtp

QGLayoutIterator

QGrid

QGridLayout

QGridView

QGroupBox

QHBox

QHeader

QHGroupBox

QHttp

QIconFactory

QIconSet

QIconView

QImageDrag

QImageIO

QIntCache<T>

QIntDict<T>

QIODevice

QIODeviceSource

QLabel

QLayout

QLayoutIterator

QLineEdit

QListBox

QListView

QLocalFs

QMainWindow

QMemArray<T>

QMenuBar

QMenuData

QMessageBox

QMimeSourceFactory

QMovie

QMultiLineEdit

QNetworkProtocol

QObject

QObjectDictionary

QObjectList

QPaintDevice

QPaintDeviceMetrics

QPainter

QPicture

QPixmap

QPointArray

QPopupMenu

QPrinter

QProcess

QProgressBar

QProgressDialog

QPtrCollection<T>

QPtrDict<T>

QPtrList<T>

QPtrQueue<T>

QPtrStack<T>

QPtrVector<T>

QPushButton

QRangeControl

QRegExp

QRegion

QScrollBar

QScrollView

QServerSocket

QSettings

QShared

QSignal

QSimpleRichText

QSlider

QSocket

QSocketDevice

QSortedList

QSplitter

QSpinBox

QSqlCursor

QSqlDatabase

QSqlEditorFactory

QSqlError

QSqlFieldInfo

QSqlForm

QSqlPropertyMap

QSqlQuery

QSqlRecord

QSqlRecordInfo

QSqlSelectCursor

QStoredDrag

QStr(I)List

QStr(I)Vec

QString

QStringList

QStyle

QStyleSheet

QSyntaxHighlighter

QTabBar

QTabDialog

QTabWidget

QTable

QTextCodec

QTextDrag

QTextEdit

QTextIStream

QTextOStream

QTextOStreamIterator

QTextStream

QTextView

QTimeEdit

QTimer

QToolBar

QToolButton

QToolTip

QUriDrag

QUrl

QUrlOperator

QValueList<T>

QValueVector<T>

QVariant

QVBox

QVGroupBox

QWhatsThis

QWidget

QWidgetFactory

QWidgetIntDict

QWidgetList

QWidgetPlugin

QWidgetStack

QWizard

QWorkspace

Printer and Printing APIs

Printing with Qt

Classes Supporting Printing

Paint Devices and Printing

Creating a QPrinter

Painting onto a Page

Coordinate Systems

Printing Widgets

Printing from Complex Widgets

The Property System

Requirements for Declaring Properties

Reading and Writing Properties with the Meta-Object System

A Simple Example

Dynamic Properties

Properties and Custom Types

Adding Additional Information to a Class

Property Binding

Properties

Property Binding

Property Assignment versus Property Binding

Types of Properties

Basic Property Types

The Property

Elements and Objects as Property Values

Attached Properties

Attached Signal Handlers

List properties

Grouped Properties

Property Aliases

Considerations for property aliases

Default Properties

Using the Binding Element

Changing Property Values in States

Qt Widget Hierarchy

Menubar Merging

Two Simple Qt Widgets

OpenGL in an HTML page

A standard ActiveX and the "simple" ActiveQt widget

Standard Qt widgets in an HTML page

D-Bus Adaptor Example

The header

The properties

The constructor

Slots/methods

Signals

Declaring Signals in D-Bus Adaptors

Declaring Slots in D-Bus Adaptors

Asynchronous Slots

Input-Only Slots

Input and Output Slots

Automatic Replies

Delayed Replies

The QtDBus Type System

Primitive Types

Compound Types

Extending the Type System

The Type System in Use

D-Bus Viewer

QtDBus XML compiler (qdbusxml2cpp)

QML Animation and Transitions

Animation and Transitions Elements

Triggering Animations

Direct Property Animation

Transitions during State Changes

Default Animation as Behaviors

Playing Animations in Parallel or in Sequence

Controlling Animations

Animation Playback

Easing

Other Animation Elements

QML Basic Types

Debugging QML

Logging

Debugging Transitions

Debugging module imports

Debugging with Qt Creator

QML Documents

Documents as Component Definitions

Inline Components

Dynamic Object Management in QML

Creating Objects Dynamically

Creating a Component Dynamically

Creating an Object from a String of QML

Maintaining Dynamically Created Objects

Deleting Objects Dynamically

QML Elements

Basic QML Elements

Graphics

Text Handling

Mouse and Interaction Area

Positioners and Repeater

Transformations

States

Animation and Transitions

Models and Data Handling

Views

Path Definition

Utility

Graphical Effects

Add-On Elements

QML Examples and Demos

Demos

Examples

Animation

Image Elements

Text

Positioners

Key Interaction

Touch Interaction

UI Components

Toys

Models and Views

XML

Internationalization (i18n)

Right-to-left User Interfaces

Threading

Screen Orientation

SQL Local Storage

C++ Extensions

Labs

QML Example - Toggle Switch

Switch.qml

Walkthrough

Interface

Images and user interaction

States

Functions

Transition

Usage

Keyboard Focus in QML

Key Handling Overview

Querying the Active Focus Item

Acquiring Focus and Focus Scopes

Advanced uses of Focus Scopes

QML Global Object

Qt Object

XMLHttpRequest

Offline Storage API

Database API

db = openDatabaseSync(identifier, version, description, estimated_size, callback(db))

db.changeVersion(from, to, callback(tx))

db.transaction(callback(tx))

db.readTransaction(callback(tx))

results = tx.executeSql(statement, values)

Logging

QML Internationalization

Example

Introduction to the QML Language

Basic QML Syntax

Comments

Object Identifiers

Expressions

Properties

Basic Property Types

Property Change Notifications

List properties

Default Properties

Grouped Properties

Attached Properties

Signal Handlers

Integrating JavaScript

Inline JavaScript

Separate JavaScript files

Code-Behind Implementation Files

Stateless JavaScript libraries

Importing One JavaScript File From Another

Running JavaScript at Startup

JavaScript and Property Binding

Receiving QML Signals in JavaScript

QML JavaScript Restrictions

QML Data Models

QML Data Models

ListModel

XmlListModel

VisualItemModel

C++ Data Models

QStringList-based model

QObjectList-based model

QAbstractItemModel

Exposing C++ Data Models to QML

Other Data Models

An Integer

An Object Instance

Accessing Views and Models from Delegates

Modules

QML Modules

Located Modules

Installed Modules

Creating Installed Modules

Creating Installed Modules in C++

Namespaces: Using Named Imports

JavaScript Files

Writing a qmldir File

Debugging

Writing a qmltypes file

Network Transparency

Relative vs. Absolute URLs

Progressive Loading

Accessing Network Services

Configuring the Network Access Manager

QRC Resources

Limitations

QML Performance

Opaque Items

Clipping

Anchors vs. Binding

Images

View Delegates

Image resources over composition

Limit JavaScript

Rendering

QML Scope

JavaScript Scope

Element Names and Imported JavaScript Files

Binding Scope Object

Component Scope

Component Instance Hierarchy

JavaScript Global Object

QML Security

QML Security

QML States

States Elements

Creating States

The Default State

The Property

Animating State Changes

State Fast Forwarding

qmake Advanced Usage

Operators

Scopes

Syntax

Scopes and Conditions

Configuration and Scopes

Platform Scope Values

Variables

Variable Processing Functions

Conditional Functions

Adding New Configuration Features

qmake Common Projects

Building an Application

The app Template

Building a Library

The lib Template

Building a Plugin

Building a Qt Designer Plugin

Building and Installing in Debug and Release Modes

Building in Both Modes

Installing in Both Modes

Configuring qmake's Environment

Properties

QMAKESPEC

INSTALLS

Cache File

Library Dependencies

File Extensions

Customizing Makefile Output

qmake Function Reference

packagesExist(packages)

basename(variablename)

CONFIG(config)

contains(variablename, value)

count(variablename, number)

dirname(file)

error(string)

eval(string)

exists(filename)

find(variablename, substr)

for(iterate, list)

include(filename)

infile(filename, var, val)

isEmpty(variablename)

join(variablename, glue, before, after)

member(variablename, position)

message(string)

prompt(question)

quote(string)

replace(string, old_string, new_string)

sprintf(string, arguments...)

system(command)

unique(variablename)

warning(string)

qmake Manual

Getting Started

Table of Contents

qmake Platform Notes

Mac OS X

Source and Binary Packages

Using Frameworks

Creating Frameworks

Creating Universal Binaries

Creating and Moving Xcode Projects

On supporting two build targets simultaneously

Windows

Creating Visual Studio Project Files

Visual Studio 2005 Manifest Files

Symbian Platform

Handling of Static Data

Stack and Heap Size

Compiler-Specific Options

Unique Identifiers

Capabilities

Using Precompiled Headers

Adding Precompiled Headers to Your Project

Contents of the Precompiled Header File

Example:

Project Options

Notes on Possible Issues

Example Project

qmake Project Files

Project File Elements

Variables

Whitespace

Comments

Built-in Functions and Control Flow

Project Templates

General Configuration

Declaring Qt Libraries

Configuration Features

Declaring Other Libraries

qmake Reference

Variable Reference

Function Reference

Frequently Used Variables

Environment Variables and Configuration

Running qmake

Command-Line Options

Syntax

Options

Makefile Mode Options

Project Mode Options

qmake Tutorial

Starting off Simple

Making an Application Debuggable

Adding Platform-Specific Source Files

Stopping qmake If a File Doesn't Exist

Checking for More than One Condition

Using qmake

Describing a Project

Building a Project

Using Precompiled Headers

qmake Variable Reference

BACKUP_REGISTRATION_FILE_MAEMO

BACKUP_REGISTRATION_FILE_SYMBIAN

BLD_INF_RULES

CONFIG

DEFINES

DEF_FILE

DEPENDPATH

DEPLOYMENT

DEPLOYMENT_PLUGIN

DESTDIR

DESTDIR_TARGET

DLLDESTDIR

DISTFILES

DSP_TEMPLATE

FORMS

FORMS3

GUID

HEADERS

ICON

INCLUDEPATH

INSTALLS

LEXIMPLS

LEXOBJECTS

LEXSOURCES

LIBS

LITERAL_HASH

MAKEFILE

MAKEFILE_GENERATOR

MMP_RULES

MOC_DIR

OBJECTS

OBJECTS_DIR

OBJMOC

POST_TARGETDEPS

PRE_TARGETDEPS

PRECOMPILED_HEADER

PWD

OUT_PWD

QMAKE

QMAKESPEC

QMAKE_APP_FLAG

QMAKE_APP_OR_DLL

QMAKE_AR_CMD

QMAKE_BUNDLE_DATA

QMAKE_BUNDLE_EXTENSION

QMAKE_CC

QMAKE_CFLAGS_DEBUG

QMAKE_CFLAGS_MT

QMAKE_CFLAGS_MT_DBG

QMAKE_CFLAGS_MT_DLL

QMAKE_CFLAGS_MT_DLLDBG

QMAKE_CFLAGS_RELEASE

QMAKE_CFLAGS_SHLIB

QMAKE_CFLAGS_THREAD

QMAKE_CFLAGS_WARN_OFF

QMAKE_CFLAGS_WARN_ON

QMAKE_CLEAN

QMAKE_CXX

QMAKE_CXXFLAGS

QMAKE_CXXFLAGS_DEBUG

QMAKE_CXXFLAGS_MT

QMAKE_CXXFLAGS_MT_DBG

QMAKE_CXXFLAGS_MT_DLL

QMAKE_CXXFLAGS_MT_DLLDBG

QMAKE_CXXFLAGS_RELEASE

QMAKE_CXXFLAGS_SHLIB

QMAKE_CXXFLAGS_THREAD

QMAKE_CXXFLAGS_WARN_OFF

QMAKE_CXXFLAGS_WARN_ON

QMAKE_DISTCLEAN

QMAKE_EXTENSION_SHLIB

QMAKE_EXT_MOC

QMAKE_EXT_UI

QMAKE_EXT_PRL

QMAKE_EXT_LEX

QMAKE_EXT_YACC

QMAKE_EXT_OBJ

QMAKE_EXT_CPP

QMAKE_EXT_H

QMAKE_EXTRA_COMPILERS

QMAKE_EXTRA_TARGETS

QMAKE_FAILED_REQUIREMENTS

QMAKE_FILETAGS

QMAKE_FRAMEWORK_BUNDLE_NAME

QMAKE_FRAMEWORK_VERSION

QMAKE_INCDIR

QMAKE_INCDIR_EGL

QMAKE_INCDIR_OPENGL

QMAKE_INCDIR_OPENGL_ES1, QMAKE_INCDIR_OPENGL_ES2

QMAKE_INCDIR_OPENVG

QMAKE_INCDIR_QT

QMAKE_INCDIR_THREAD

QMAKE_INCDIR_X11

QMAKE_INFO_PLIST

QMAKE_LFLAGS

QMAKE_LFLAGS_CONSOLE

QMAKE_LFLAGS_CONSOLE_DLL

QMAKE_LFLAGS_DEBUG

QMAKE_LFLAGS_PLUGIN

QMAKE_LFLAGS_RPATH

QMAKE_LFLAGS_QT_DLL

QMAKE_LFLAGS_RELEASE

QMAKE_LFLAGS_SHAPP

QMAKE_LFLAGS_SHLIB

QMAKE_LFLAGS_SONAME

QMAKE_LFLAGS_THREAD

QMAKE_LFLAGS_WINDOWS

QMAKE_LFLAGS_WINDOWS_DLL

QMAKE_LIBDIR

QMAKE_LIBDIR_FLAGS

QMAKE_LIBDIR_EGL

QMAKE_LIBDIR_OPENGL

QMAKE_LIBDIR_OPENVG

QMAKE_LIBDIR_QT

QMAKE_LIBDIR_X11

QMAKE_LIBS

QMAKE_LIBS_CONSOLE

QMAKE_LIBS_EGL

QMAKE_LIBS_OPENGL

QMAKE_LIBS_OPENGL_QT

QMAKE_LIBS_OPENGL_ES1, QMAKE_LIBS_OPENGL_ES2

QMAKE_LIBS_OPENVG

QMAKE_LIBS_QT

QMAKE_LIBS_QT_DLL

QMAKE_LIBS_QT_OPENGL

QMAKE_LIBS_QT_THREAD

QMAKE_LIBS_RT

QMAKE_LIBS_RTMT

QMAKE_LIBS_THREAD

QMAKE_LIBS_WINDOWS

QMAKE_LIBS_X11

QMAKE_LIBS_X11SM

QMAKE_LIB_FLAG

QMAKE_LINK_SHLIB_CMD

QMAKE_LN_SHLIB

QMAKE_POST_LINK

QMAKE_PRE_LINK

QMAKE_PROJECT_NAME

QMAKE_MAC_SDK

QMAKE_MACOSX_DEPLOYMENT_TARGET

QMAKE_MAKEFILE

QMAKE_MOC_SRC

QMAKE_QMAKE

QMAKE_QT_DLL

QMAKE_RESOURCE_FLAGS

QMAKE_RPATH

QMAKE_RPATHDIR

QMAKE_RUN_CC

QMAKE_RUN_CC_IMP

QMAKE_RUN_CXX

QMAKE_RUN_CXX_IMP

QMAKE_TARGET

QMAKE_UIC

QT

QTPLUGIN

QT_VERSION

QT_MAJOR_VERSION

QT_MINOR_VERSION

QT_PATCH_VERSION

RC_FILE

RCC_DIR

REQUIRES

RESOURCES

RES_FILE

RSS_RULES

S60_VERSION

SIGNATURE_FILE

SOURCES

SRCMOC

SUBDIRS

Ordered Targets and Visual Studio Solution Files

SYMBIAN_VERSION

TARGET

TARGET.CAPABILITY

TARGET.EPOCALLOWDLLDATA

TARGET.EPOCHEAPSIZE

TARGET.EPOCSTACKSIZE

TARGET.SID

TARGET.UID2

TARGET.UID3

TARGET.VID

TARGET_EXT

TARGET_x

TARGET_x.y.z

TEMPLATE

TRANSLATIONS

UICIMPLS

UICOBJECTS

UI_DIR

UI_HEADERS_DIR

UI_SOURCES_DIR

VERSION

VER_MAJ

VER_MIN

VER_PAT

VPATH

YACCIMPLS

YACCOBJECTS

YACCSOURCES

_PRO_FILE_

_PRO_FILE_PWD_

QML Advanced Tutorial

Anchor-based Layout in QML

Anchor Margins and Offsets

Restrictions

QML Animation and Transition Elements

QML Architecture

Basic QML Interaction Elements

Basic QML Visual Elements

Using QML Behaviors with States

Using Behaviors with States

QML Best Practices Guides

QML Best Practices: Coding Conventions

Coding Conventions

Importing Files into QML

Commenting Code

Group Properties

QML Best Practices: Data Types

Basic Data Types

Qt Data Types

Exporting Qt Types to QML

Using QStringLists in QML

QML Coding Conventions

QML Objects

Grouped Properties

Private Properties

Lists

JavaScript Code

QML Event Elements

Tutorial: Writing QML Extensions with C++

Chapter 7: In Summary

Extending QML Functionalities using C++

Adding Types

QML Type Versioning

Object and List Property Types

Inheritance and Coercion

Default Property

Grouped Properties

Attached Properties

Memory Management and QVariant types

Signal Support

Methods

Property Value Sources

Property Binding

Extension Objects

Optimization

QML Features

Groups Of Related QML Elements

Integrating QML Code with Existing Qt UI Code

Integrating with a QWidget-based UI

Integrating with a QGraphicsView-based UI

Adding QML widgets to a QGraphicsScene

Loading QGraphicsWidget objects in QML

Introduction to Qt Quick

The QML Language

QtDeclarative Module

Creator Tools

Where to Go from Here

License Information

Models and Views: ListView Examples

QML Particle Elements

Using QML Positioner and Repeater Items

Positioners

Column

Row

Grid

Flow

Repeaters

Using Transitions

Other Ways to Position Items

QML Positioning Elements

Presenting Data with QML

Introduction

Views

ListView

GridView

PathView

Decorating Views

Headers and Footers

Sections

Navigation

Further Reading

QML Right-to-left User Interfaces

Overview

Text Alignment

Layout direction of positioners and views

Layout mirroring

Mirroring icons

Default layout direction

QML Shader Elements

QML State Elements

QML Transform Elements

QML Tutorial

QML Tutorial 1 - Basic Types

Walkthrough

Import

Rectangle element

Text element

Viewing the example

QML Tutorial 2 - QML Components

Walkthrough

The Cell Component

The main QML file

QML Tutorial 3 - States and Transitions

Walkthrough

QML Utility Elements

QML View Elements

Presenting Data with Views

Models

View Delegates

Decorating Views

ListView Sections

Models and Views: WebView Examples

Working With Data in QML

QML Basic Elements

Basic Elements

Properties and Qt Declarative Module

Item Element

Rectangle Element

Image Element

Text Elements

Using Elements as the Top-Level Component

QML Signal and Handler Event System

Signals and Handlers

Connecting Signals to Methods and Signals

Signal to Signal Connect

C++ Additions

Using QML elements

Importing Reusable Components

Defining New Components

Loading a Component

Importing a Component

Loading an Inline Component

Component Properties

Top-Level Component

Qt Declarative UI Runtime

Deploying QML-based applications

Deploying with QDeclarativeView

Creating a QDeclarativeEngine directly

Developing and prototyping with QML Viewer

QML Syntax

Basic QML Syntax

Expressions

QML Comments

QML Viewer

Adding module import paths

Loading translation files

Loading placeholder data with QML Viewer

Using the object

QtWebKit QML Module

WebKit QML Elements

QtWebKit Module

Simple Usage

ActiveX in Qt

Programming with Qt

Using qt.conf

Qt for Embedded Platforms

Adding an Accelerated Graphics Driver to Qt for Embedded Linux

Step 1: Create a Custom Screen

Step 2: Implement a Custom Raster Paint Engine

Step 3: Make the Paint Device Aware of Your Paint Engine

Step 4: Make the Window Surface Aware of Your Paint Device

Step 5: Enable Creation of an Instance of Your Window Surface

Qt for Embedded Linux Architecture

Client/Server Communication

Pointer Handling Layer

Character Input Layer

Graphics Rendering

Drawing on Screen

Qt for Embedded Linux Character Input

Available Keyboard Drivers

Keymaps

Specifying a Keyboard Driver

Cross-Compiling Qt for Embedded Linux Applications

Step 1: Set the Cross-Compiler's Path

Step 2: Create a Target Specific qmake Specification

Step 3: Provide Architecture Specific Files

Step 4: Provide Hardware Drivers

Step 5: Build the Target Specific Executable

Deploying Qt for Embedded Linux Applications

Fonts

Environment Variables

Framebuffer Support

Porting Qt Applications to Qt for Embedded Linux

Qt for Embedded Linux Display Management

Available Drivers

Specifying a Driver

Subdrivers and Multiple Drivers

Qt for Embedded Linux Environment Variables

Qt for Embedded Linux Fonts

FreeType Formats

Qt Prerendered Font (QPF2)

Legacy Qt Prerendered Font (QPF)

The Legacy File

Installing Qt for Embedded Linux

Step 1: Installing the License File (commercial editions only)

Step 2: Unpacking the Archive

Step 3: Building the Library

Step 4: Adjusting the Environment Variables

Step 5: Building the Virtual Framebuffer

kmap2qmap

Qt for Embedded Linux

makeqpf

Qt for Embedded Linux Pointer Handling

Available Drivers

Specifying a Driver

Troubleshooting

Device Files

File Permissions

Porting Qt for Embedded Linux to a New Architecture

Hardware Drivers

Atomic Operations

Porting Qt for Embedded Linux to Another Operating System

Shared Memory and Semaphores

Inter-Application Communication

Screen Management

Sound Management

Event Dispatching

Running Qt for Embedded Linux Applications

Using a Single Display

Using Multiple Displays

Command Line Options

Testing the Linux Framebuffer

The VNC Protocol and Qt for Embedded Linux

Configuring Qt with VNC Capabilities

Running a Server Application

Running Client Applications

Related Resources

Qt for Embedded Linux Hardware Accelerated Graphics

Hardware Acceleration

Qt for Embedded Graphics pipeline

Hardware configuration requirements

Different architectures

Recommended use of hardware acceleration based on hardware

Windowing on Embedded Linux with Hardware Accelerated Graphics

General options

Supported Hardware Accelerated Graphics APIs

Qt for Embedded Linux and DirectFB

Introduction

Using DirectFB with Qt

Configure

Supported graphics operations

DirectFB driver

Optimize performance using define options

Unsupported graphics operations

Avoiding fallbacks

When painting images

Top level transparency

Qt for Embedded Linux and OpenGL

Introduction

Using OpenGL ES with Qt

Using OpenGL with Qt for Embedded Linux

Configure

Using OpenGL to Implement Window Compositing and Effects

Integrating OpenGL/ES into Qt for Embedded Linux

Reference Integration

Integrating Other Chipsets

Qt for Embedded Linux and OpenVG

Introduction

Using OpenVG with Qt

Configure

Supported OpenVG Engines

Using the OpenVG graphics system

Supported features

Known issues

Qt for Windows CE Hardware Accelerated Graphics

Hardware Acceleration

Qt for Embedded Graphics pipeline

Hardware configuration requirements

Different architectures

Recommended use of hardware acceleration based on hardware

Supported Hardware Accelerated Graphics APIs

Qt Graphics and Printing

UI Design with Qt

Contributions to the Following QtGui Files: qapplication_cocoa_p.h, qapplication_mac.mm, qdesktopwidget_mac.mm qeventdispatcher_mac.mm qeventdispatcher_mac_p.h qmacincludes_mac.h qt_cocoa_helpers.mm qt_cocoa_helpers_p.h qwidget_mac.mm qsystemtrayicon_mac.mm

Network programming with Qt

Qt Features Overview

Fundamental Technologies in Qt

Graphical User Interfaces

Painting, Printing and Rendering

Infrastructure

Web Client Integration

Further Reading

Qt Performance Tuning

Programming Style

Static vs. Dynamic Linking

Alternative Memory Allocation

Bypassing the Backing Store

Not Used

SQL in Qt

Contributions to the Following qt3to4 Files: treewalker.h, treedump.cpp, treedump.h, treewalker.cpp

qt3to4 - The Qt 3 to 4 Porting Tool

Usage

Porting Rules

Location of the qt3porting.xml File

Logging

Advanced Usage

Limitations

Legal Notices

What's New in Qt 4.6

Support for Symbian

Animation Framework

State Machine Framework

Touch and Gestures

DOM Access API

Performance Optimizations

Graphics Effects

XML Schema Validation

Qt3D Enablers

Multimedia Services

New Classes, Functions, Macros, etc.

What's New in Qt 4.7

Declarative UI Development with Qt Quick

Network Bearer Management

Feature Improvements in QtWebKit

QtWebKit Performance Benchmarks

Other Performance Related Improvements

New Classes, Functions, Macros, etc.

What's New in Qt 4.8

Qt Quick 1.1

Qt Platform Abstraction -- Lighthouse

Qt WebKit 2.2

Threaded OpenGL

Deprecated Items in Qt 4.8

Additions to the Qt API

New Classes, Functions, Macros, etc.

Cross-Platform Accessibility Support in Qt 4

General Overview

Enabling Accessibility Support

Creating New Accessible Interfaces

Example Code

The Arthur Paint System

Architecture

A Look Back at Qt 3

How Painting is Done in Qt 4

New Features in the Qt 4 Paint System

Gradient Brushes

Alpha-Blended Drawing

QPainter and QGLWidget

Anti-Aliased Edges

Extensive Use of Native Graphics Operations

Painter Paths

Widget Double-Buffering

Pen and Brush Transformation

Custom Filled Pens

QImage as a Paint Device

SVG Rendering Support

The New Qt Designer

The Current State of Qt Designer

User Interface Features

Editing Features

Plugin Support

Run-Time Support for Forms

The Interview Framework

Overview of The Model/View Architecture

Model/View Classes

Example Code

Sharing a Model Between Views

Creating a Custom Model

What's Changed Since Qt 3?

What's New in Qt 4

New Technologies in Qt 4

Recent Additions to Qt 4

Significant Improvements

Build System

Include Syntax

Namespaces

QObject/QWidget Constructors

Dynamic Casts

QPointer<T>

Paint Events

Qt 3 Support Layer

The Qt 4 Main Window Classes

Overview of the Main Window Classes

The Main Window Classes

Example Code

What's Changed since Qt 3?

New Functionality

Independent QDockWidget And QToolBar Classes

Code Change Examples

The Network Module in Qt 4

General Overview

Example Code

TCP Client

TCP Server

UDP Senders and Receivers

Comparison with Qt 3

The Scribe Classes

Overview of Scribe

The Document Interface

Document Structure

Editing and Content Creation

Document Layout

Example Code

Manipulating Rich Text

Plain Text Layout

Printing Features

Comparison with Qt 3

The Qt 4 Database GUI Layer

General Overview

Example Code

Comparison with Qt 3

The Qt 4 Style API

General Overview

Example Code

Comparison with Qt 3

Thread Support in Qt 4

General Overview

Comparison with Qt 3

The Tulip Container Classes

General Overview

Examples

Comparison with Qt 3

Using QML Bindings in C++ Applications

Core module classes

Approaches to using QML with C++

Loading QML Components from C++

Locating child objects

Embedding C++ Objects into QML Components

Defining New QML Elements

Exchanging Data between QML and C++

Calling Functions

Receiving Signals

Modifying Properties

Supported data types

JavaScript Arrays and Objects

Using Enumerations of a Custom Type

Using Enumeration Values as Signal and Method Parameters

Automatic Type Conversion from Strings

Writing QML plugins

Managing resource files with the Qt resource system

Qt for Windows CE

QtConcurrent Image Scaling Example

QtConcurrent Map Example

QtConcurrent Progress Dialog Example

QtConcurrent Run Function Example

QtConcurrent Word Count Example

Configuring Qt

Examples and Demos Launcher

Creating and Using Components for Qt Designer

Creating Custom Widget Plugins

Retrieving Access to Qt Designer Components

Creating User Interfaces at Run-Time

Qt Development: The Steps from Challenge to Achievement

The Challenge

Brainstorming Ideas - It is time to play!

Creating an Objective

Developing Plans

Execution: The Coding Begins!

Innovating

The Achievement

QTestLib Manual

QTestLib Features

QTestLib API

Using QTestLib

Creating a Test

Building a Test

QTestLib Command Line Arguments

Syntax

Options

Creating a Benchmark

Using QTestLib remotely on Windows CE

Using

Syntax

Options

QtRemote

Requirements

3rd Party Code

QTestLib Tutorial

Chapter 1: Writing a Unit Test

Writing a Test

Executing a Test

Chapter 2: Data Driven Testing

Writing the Data Function

Rewriting the Test Function

Chapter 3: Simulating GUI Events

Writing a GUI test

Chapter 4: Replaying GUI Events

Writing the Data Function

Rewriting the Test Function

Chapter 5: Writing a Benchmark

Writing a Benchmark

Data Functions

External Tools

The Qt Help Framework

Topics

Overview

Generating Qt Help

Creating a Qt Help Collection

Using Qt Help

Using Qt Assistant

Using QHelpEngine API

Qt Help Project

Qt Help Project File Format

Namespace

Virtual Folders

Custom Filters

Filter Section

Filter Attributes

Table of contents

Keywords

Files

Qt is Mac OS X Native

The Global Menu Bar

Aqua

Dock

Accessiblity

Development Tools

The qtmain Library

License Information

QML for Qt Programmers

Familiar Concepts

QML Items compared with QWidgets

Simple Widgets

Parent Widgets

Compound Widgets

QML Items Compared With QGraphicsWidgets

What's New in Qt Quick

Qt 4.7.4 includes QtQuick 1.1

PinchArea

LayoutMirroring attached property

Text

TextEdit

TextInput

Image, BorderImage and AnimatedImage

Item

Flickable

MouseArea

ListView and GridView

Flow, Grid and Row

Repeater

Component

Qt

Other changes

Qt 4.7.1

QtQuick namespace

Qt Quick

Getting Started

QML Features

QML Add-Ons

Qt Quick Tools

Reference

Architecture

Examples

Best Practices

License Information

Online Examples

Qt Quick Licensing Information

Qt Script Debugger Manual

Getting Started

Overview of Debugger Components

Resuming Script Evaluation

Resuming After an Uncaught Exception

Console Command Reference

Breakpoint-related Commands

break <location>

clear <location>

condition <breakpoint-id> <expression>

delete <breakpoint-id>

disable <breakpoint-id>

enable <breakpoint-id>

ignore <breakpoint-id> <count>

info breakpoints

tbreak <location>

File-related Commands

list <location>

info scripts

Execution-related Commands

advance <location>

continue

eval <program>

finish

interrupt

next <count = 1>

return <expression>

step <count = 1>

Stack-related Commands

backtrace

down

frame <index>

info locals

up

Creating QtScript Extensions

Static Extensions

Qt for the Symbian platform

Qt's Tools

The QtWebKit Bridge

Overview

The technology

Use Cases

Web Content in Native Applications

Thin Clients

Difference from Other Bridge Technologies

Relationship with QtScript

Accessing QObjects

Making QObjects known to JavaScript via QWebFrame

Using Signals and Slots

Signal to Function Connections

Signal to Member Function Connections

Signal to Named Member Function Connections

Error Handling

Emitting Signals from Scripts

Overloaded Signals and Slots

Invokable Methods

Accessing Properties

Accessing Child QObjects

Data types

Numbers

Strings

Date & Time

Regular Expressions

Lists

Compound (JSON) objects

QVariants

QObjects

Pixmaps and Images

QWebElement

Architecture Issues

Limiting the Scope of the Hybrid Layer

Internet Security

QtWebKit Goes Mobile

Overview

Resize to Contents

Using a View as the Window onto the Contents

Adjusting How Contents are Laid Out

The 'viewport' Meta-Tag

Enabling the Tiling

Avoiding Scrollable Subelements

QtWebKit Guide - Client Storage

Client Storage

Simple Data Storage

Storing Non-String Data

Storage Events

WebSQL Databases

Creating and Opening a New Database

Transaction Calls and ExecuteSQL Method

Changing Database Versions

Errors

QtWebKit Guide - Canvas Graphics

Canvas Graphics

Accessing the Rendering Context

Drawing Shapes

Drawing Rectangles

Drawing Lines

Drawing Arcs

Compositing

Saving and Exporting Canvas Drawings as Image Files

Drawing Text

Working with Images

Creating Patterns with Images

Applying Colors

Applying Gradients

Applying Shadows

Transforming Graphics

Translating the Canvas Origin

Rotating the Canvas

Scaling the Canvas Grid

Manipulating the Transformation Matrix

Canvas Animations

QtWebKit Guide - Level 3 CSS

Level 3 CSS

Media Queries

Media Types and Media Queries

In-line Media Queries

Media Queries via JavaScript

Selectors

Attribute Matching

Form Input State

Navigational Selectors

Indirect Sibling Selector

Positional Selectors

Other Selectors

Visual Effects

Specifying Color and Opacity

Rounded Corners

Border Images

Backgrounds

Text Shadow and Stroke

Text Overflow

Custom Scrollbars

Gradients

Reflections

Masks

Dynamic CSS

CSS Animation Concepts

2D Transforms

Transitions

Transitional Sequences

Keyframe Animations

QtWebKit Guide

Introduction to QtWebKit

QtWebKit 2.1 for Web Developers

Qt WebKit Module

Mobile HTML5 Developer's Guide for QtWebKit (BETA)

Overview of Qt's Undo Framework

Introduction

Classes

Concepts

The Virtual Framebuffer

Displaying the Virtual Framebuffer

Skins

The File Menu

The View Menu

Running Applications Using the Virtual Framebuffer

Qt for Embedded Linux Classes

Double Buffered Graphics Driver Example

Step 1: Creating a Custom Graphics Driver

Step 2: Implementing the Back Buffer

Device initializing and shutdown

Drawing to the back buffer

Displaying the buffer on the screen

Step 3: Creating the Driver Plugin

Mouse Calibration Example

The Main Program

Calibration Class Definition

Calibration Class Implementation

Simple Decoration Example

Styles and Window Decorations

MyDecoration Class Definition

MyDecoration Class Implementation

Finding Regions

Painting the Decoration

Using the Decoration

Notes

Accelerated Graphics Driver Example

Step 1: Creating a Custom Graphics Driver

SvgalibScreen Class Implementation

Step 2: Implementing a Custom Raster Paint Engine

Step 3: Making the Widgets Aware of the Custom Paint Engine

Implementing a Custom Paint Device

Implementing a Custom Window Surface

Adjusting the Graphics Driver

Resource Compiler (rcc)

real

rect

Qt for Embedded Linux Requirements

Building Qt for Embedded Linux with uclibc

Memory Requirements

Additional X11 Libraries for QVFb

Qt for Mac OS X Requirements

Qt for the Symbian platform Requirements

Qt for Windows Requirements

Qt for Windows CE Requirements

Requirements

Qt for X11 Requirements

QtGui Dependencies

OpenGL Dependencies

Phonon Dependencies

General Qt Requirements

OpenSSL (version 0.9.7 or later)

Platform-Specific Requirements

The Qt Resource System

Resource Collection Files ()

External Binary Resources

Compiled-In Resources

Compression

Using Resources in the Application

Restoring a Window's Geometry

Advanced Rich Text Processing

Handling Large Files

Common Rich Text Editing Tasks

Using QTextEdit

Selecting Text

Finding Text

Printing Documents

The QTextCursor Interface

Cursor-Based Editing

Using a Cursor

Grouping Cursor Operations

Multiple Cursors

Inserting Document Elements

Text and Text Fragments

Blocks

Frames

Tables

Lists

Images

Examples

Manipulating Rich Text

Generating a Calendar

Supported HTML Subset

Using HTML Markup in Text Widgets

Supported Tags

Block Attributes

List Attributes

Table Cell Attributes

CSS Properties

Supported CSS Selectors

Document Layouts

Overview

Example - Shaped Text Layout

Rich Text Processing APIs

Rich Text Document Structure

Rich Text Documents

Document Elements

Text Blocks

Frames

Tables

Lists

Images

Rich Text Processing

Rich Text Processing APIs

Calendar Example

MainWindow Class Definition

MainWindow Class Implementation

Order Form Example

DetailsDialog Definition

DetailsDialog Implementation

MainWindow Definition

MainWindow Implementation

Function

Syntax Highlighter Example

Highlighter Class Definition

Highlighter Class Implementation

MainWindow Class Definition

MainWindow Class Implementation

Other Code Editor Features

Text Object Example

SvgTextObject Class Definition

SvgTextObject Class Implementation

Window Class Definition

Window Class Implementation

Scalability

Developing Scalable UIs

Implementing the Top-Level Layouts

Defining Measurements

Using QML's Layout Features

Orientation Switches

Scripting Classes and Overviews

QtScript Calculator Example

Context2D Example

Using The HTML Canvas Element in a Web Browser

Using Qt Script to script a Canvas

The Context2D Class

Implementation

The Canvas Widget

The Environment

The Application Window

Custom Script Class Example

ByteArray Class In Use

ByteArray Class Implementation

ByteArray Iterator Implementation

ByteArray Prototype Implementation

Default Prototypes Example

Hello Script Example

Translating the Application

Qt Script Marshalling Example

Qt Script Interpreter Example

Qt Script Debugger Example

Qt Script Tetrix Example

Overview

Setting up the GUI

Making Applications Scriptable

Scripting Classes

Language Overview

Basic Usage

Making a QObject Available to the Script Engine

Using Signals and Slots

Signal to Function Connections

Signal to Member Function Connections

Signal to Named Member Function Connections

Error Handling

Emitting Signals from Scripts

Overloaded Signals and Slots

Accessing Properties

Accessing Child QObjects

Controlling QObject Ownership

Qt Ownership

Script Ownership

Auto-Ownership

What Happens When Someone Else Deletes the QObject?

Customizing Access to the QObject

Making a QObject-based Class New-able from a Script

Enum Values

Conversion Between QtScript and C++ Types

Default Conversion from Qt Script to C++

Default Conversion from C++ to Qt Script

How to Design and Implement Application Objects

Making a C++ object available to Scripts Written in QtScript

Making C++ Class Member Functions Available in QtScript

Making C++ Class Properties Available in QtScript

Reacting to C++ Objects Signals in Scripts

Design of Application Objects

Returning QObject Pointers

Function Objects and Native Functions

Calling a Qt Script Function from C++

The Object

Wrapping a Native Function

The QScriptContext Object

Processing Function Arguments

Formal Parameters and the Arguments Object

Checking the Number of Arguments

Checking the Types of Arguments

Functions with Variable Numbers of Arguments

Accessing the Arguments Object

Constructor Functions

Associating Data with a Function

Native Functions as Arguments to Functions

The Activation Object

Property Getters and Setters

Making Use of Prototype-Based Inheritance

Prototype Objects and Shared Properties

Defining Classes in a Prototype-Based Universe

Prototype-Based Programming with the QtScript C++ API

Implementing Prototype Objects for Value-based Types

Implementing Constructors for Value-based Types

Managing Non-QObject-based Objects

Defining Custom Script Classes with QScriptClass

Error Handling and Debugging Facilities

Redefining print()

Using QtScript Extensions

Internationalization

Use qsTr() for All Literal Text

Use String.prototype.arg() for Dynamic Text

Produce Translations

Apply Translations

ECMAScript Compatibility

QtScript Extensions to ECMAScript

Session Management

Shutting a Session Down

Protocols and Support on Different Platforms

Getting Session Management to Work with Qt

Testing and Debugging Session Management

Windows CE - Using shadow builds

Implicitly Shared Classes

Creating Shared Libraries

Using Symbols from Shared Libraries

Header File Considerations

Binary compatibility

Signals & Slots

Introduction

Signals and Slots

A Small Example

Building the Example

Signals

Slots

Meta-Object Information

A Real Example

Signals And Slots With Default Arguments

Advanced Signals and Slots Usage

Using Qt with 3rd Party Signals and Slots

size

Connecting to Databases

SQL Database Drivers

Supported Databases

Building the Drivers Using Configure

Building the Plugins Manually

QMYSQL for MySQL 4 and higher

QMYSQL Stored Procedure Support

Embedded MySQL Server

How to Build the QMYSQL Plugin on Unix and Mac OS X

How to Build the QMYSQL Plugin on Windows

How to build the MySQL driver for MinGW users

QOCI for the Oracle Call Interface (OCI)

General Information about the OCI plugin

OCI User Authentication

OCI BLOB/LOB Support

How to Build the OCI Plugin on Unix and Mac OS X

How to Build the OCI Plugin on Windows

QODBC for Open Database Connectivity (ODBC)

General Information about the ODBC plugin

ODBC Stored Procedure Support

ODBC Unicode Support

How to Build the ODBC Plugin on Unix and Mac OS X

How to Build the ODBC Plugin on Windows

QPSQL for PostgreSQL (Version 7.3 and Above)

General Information about the QPSQL driver

QPSQL Unicode Support

QPSQL BLOB Support

How to Build the QPSQL Plugin on Unix and Mac OS X

How to Build the QPSQL Plugin on Windows

QTDS for Sybase Adaptive Server

General Information about QTDS

How to Build the QTDS Plugin on Unix and Mac OS X

How to Build the QDTS Plugin on Windows

QDB2 for IBM DB2 (Version 7.1 and Above)

General Information about QDB2

How to Build the QDB2 Plugin on Unix and Mac OS X

How to Build the QDB2 Plugin on Windows

QSQLITE2 for SQLite Version 2

QSQLITE for SQLite (Version 3 and Above)

General Information about QSQLITE

How to Build the QSQLITE Plugin

QSQLITE File Format Compatibility

QSYMSQL for SQLite (Version 3 and Above) with Symbian SQL Database

General Information about QSYMSQL

How to Build the QSYMSQL Plugin

QIBASE for Borland InterBase

General Information about QIBASE

QIBASE Unicode Support and Text Encoding

QIBASE Stored procedures

How to Build the QIBASE Plugin on Unix and Mac OS X

How to Build the QIBASE Plugin on Windows

Troubleshooting

How to Write Your Own Database Driver

Creating Data-Aware Forms

Using the SQL Model Classes

The SQL Query Model

The SQL Table Model

The SQL Relational Table Model

Presenting Data in a Table View

SQL Programming

Topics:

Database Classes

Driver Layer

SQL API Layer

User Interface Layer

Executing SQL Statements

Executing a Query

Navigating the Result Set

Inserting, Updating, and Deleting Records

Transactions

Data Types for Qt-supported Database Systems

Recommended Data Types for Qt-Supported Database Systems

IBM DB2 Data Types

Borland InterBase Data Types

MySQL Data Types

Oracle Call Interface Data Types

ODBC Data Types

PostgreSQL Data Types

QSQLITE SQLite version 3 Data Types

Sybase Adaptive Server Data Types

SQLite Version 2

Cached Table Example

TableEditor Class Definition

TableEditor Class Implementation

Drill Down Example

InformationWindow Class Definition

InformationWindow Class Implementation

View Class Definition

View Class Implementation

ImageItem Class Definition

ImageItem Class Implementation

Master Detail Example

Query Model Example

Relational Table Model Example

SQL Widget Mapper Example

Window Class Definition

Window Class Implementation

Summary and Further Reading

Table Model Example

FolderListModel - a C++ model plugin

Usage from QML

Defining the Model

Connecting the Model to QML

Implementing the Model

Secure Sockets Layer (SSL) Classes

Enabling and Disabling SSL Support

Licensing Information

Standard Dialogs

State Machine Classes

The State Machine Framework

Classes in the State Machine Framework

A Simple State Machine

Doing Useful Work on State Entry and Exit

State Machines That Finish

Sharing Transitions By Grouping States

Using History States to Save and Restore the Current State

Using Parallel States to Avoid a Combinatorial Explosion of States

Detecting that a Composite State has Finished

Targetless Transitions

Events, Transitions and Guards

Using Restore Policy To Automatically Restore Properties

Animating Property Assignments

Detecting That All Properties Have Been Set In A State

What Happens If A State Is Exited Before The Animation Has Finished

Default Animations

Event Transitions Example

Factorial States Example

Ping Pong States Example

Rogue Example

Window Class Definition

Window Class Implementation

The MovementTransition Class

The Roguelike Tradition

Traffic Light Example

Two-way Button Example

string

Classes for String Data

Styles and Style Aware Widgets

Classes for Widget Styling

The QStyle implementation

The Style Elements

Primitive Elements

Control Elements

Complex Control Elements

Other QStyle Tasks

Style Options

QStyle Functions

The Palette

Implementation Issues

Java Style

Design and Implementation

Limitations and Differences from Java

Styling Java Check Boxes

Widget Walkthrough

Common Widget Properties

Widget Reference

Push Buttons

Check and Radio Buttons

Tabs

Scroll Bars

Sliders

Spin Boxes

Title Bar

Combo Box

Group Boxes

Splitters

Progress Bar

Tool Buttons

Toolbars

Menus

Menu Bar

Item View Headers

Tree Branch Indicators

Tool Boxes

Size Grip

Rubber Band

Dock Widgets

Customizing Qt Widgets Using Style Sheets

The Box Model

Sub-controls

Qt Designer Integration

Qt Style Sheets Examples

Style Sheet Usage

Customizing the Foreground and Background Colors

Customizing Using Dynamic Properties

Customizing a QPushButton Using the Box Model

Customizing the QPushButton's Menu Indicator Sub-Control

Complex Selector Example

Customizing specific widgets

Customizing QAbstractScrollArea

Customizing QCheckBox

Customizing QComboBox

Customizing QDockWidget

Customizing QFrame

Customizing QGroupBox

Customizing QHeaderView

Customizing QLineEdit

Customizing QListView

Customizing QMainWindow

Customizing QMenu

Customizing QMenuBar

Customizing QProgressBar

Customizing QPushButton

Customizing QRadioButton

Customizing QScrollBar

Customizing QSizeGrip

Customizing QSlider

Customizing QSpinBox

Customizing QSplitter

Customizing QStatusBar

Customizing QTabWidget and QTabBar

Customizing QTableView

Customizing QToolBar

Customizing QToolBox

Customizing QToolButton

Customizing QToolTip

Customizing QTreeView

Common mistakes

QPushButton and images

Qt Style Sheets Reference

List of Stylable Widgets

List of Properties

List of Icons

List of Property Types

List of Pseudo-States

List of Sub-Controls

The Style Sheet Syntax

Style Rules

Selector Types

Sub-Controls

Pseudo-States

Conflict Resolution

Cascading

Inheritance

Widgets inside C++ namespaces

Setting QObject properties

Qt Style Sheets

Overview

Supported Platforms

Qt is Available for the Following Platforms

Supported Platform Details

Tier 1 Platforms

Tier 2 Platforms

Tier 3 Platforms (Not Supported by Nokia)

General Legal Disclaimer

Symbian Platform Security Requirements

Support for Symbian

Qt on Symbian

Getting Started on Symbian

Key Features for Symbian Development

Native Look and Feel

Graphics Features

Device Configurations

Cross-Platform Development using Qt Creator

Licensing

The Symbian platform - Introduction to Qt

Required Tools

Installing Qt and Running Demos

Building Your Own Applications

Alternative Build Targets

Running Applications from the Command Line

Installing Your Own Applications

Deployment and the Smart Installer

Exception Safety with Symbian

What the problem is

Qt calls to Symbian

Be careful with new and CBase

Qt called from Symbian

Common sense things

Advanced technique

Qt and Key Technologies

Why Doesn't Qt Use Templates for Signals and Slots?

Syntax matters

Code Generators are Good

GUIs are Dynamic

Calling Performance is Not Everything

No Limits

QML Text Handling and Validators

Text Elements

Validators

Displaying Text in QML

Validating Input Text

Threading Classes

Threading Basics

What Are Threads?

GUI Thread and Worker Thread

Simultaneous Access to Data

Using Threads

When to Use Alternatives to Threads

Which Qt Thread Technology Should You Use?

Qt Thread Basics

QObject and Threads

Using a Mutex to Protect the Integrity of Data

Using the Event Loop to Prevent Data Corruption

Dealing with Asynchronous Execution

Examples

Example 1: Using the Thread Pool

Example 2: Using QtConcurrent

Example 3: Clock

Example 4: A Permanent Thread

Digging Deeper

Thread-Support in Qt Modules

Threads and the SQL Module

Painting in Threads

Threads and Rich Text Processing

Threads and the SVG module

Threads and Implicitly Shared Classes

Threads and QObjects

QObject Reentrancy

Per-Thread Event Loop

Accessing QObject Subclasses from Other Threads

Signals and Slots Across Threads

Concurrent Programming

Reentrancy and Thread-Safety

Reentrancy

Thread-Safety

Notes on Qt Classes

Starting Threads with QThread

Creating a Thread

Starting a Thread

Synchronizing Threads

Thread Support in Qt

Topics:

Recommended Reading

The Threading Classes

Mandelbrot Example

RenderThread Class Definition

RenderThread Class Implementation

MandelbrotWidget Class Defintion

MandelbrotWidget Class Implementation

The main() Function

Queued Custom Type Example

Overview

The Block Class

The Window Class

The RenderThread Class

Registering the Type

Further Reading

Semaphores Example

Global Variables

Producer Class

Consumer Class

The main() Function

Wait Conditions Example

Global Variables

Producer Class

Consumer Class

The main() Function

time

Timers

Non-GUI Classes

Codecs Example

Completer Example

The Resource File

FileSystemModel Class Definition

FileSystemModel Class Implementation

MainWindow Class Definition

MainWindow Class Implementation

Function

Contiguous Cache Example

Custom Completer Example

Setting Up The Resource File

TextEdit Class Definition

TextEdit Class Implementation

MainWindow Class Definition

MainWindow Class Implementation

Function

Custom Type Example

Overview

The Message Class Definition

The Message Class Implementation

Using the Message

Further Reading

Custom Type Sending Example

Overview

The Window and Message Class Definitions

The Window Class Implementation

Making the Connection

Further Reading

Echo Plugin Example

EchoWindow Class Definition

EchoWindow Class Implementation

EchoInterface Class Definition

EchoPlugin Class Definition

EchoPlugin Class Implementation

The function

The Profiles

Further reading and examples

I18N Example

Input Panel Example

Main Form Class Definition

MyInputPanelContext Class Definition

MyInputPanelContext Class Implementation

MyInputPanel Class Definition

MyInputPanel Class Implementation

Setting the Input Context

Further Reading

Plug & Paint Example

The Plugin Interfaces

The MainWindow Class

The PaintArea Class

The PluginDialog Class

Importing Static Plugins

Plug & Paint Basic Tools Example

Declaration of the Plugin Class

Implementation of the Brush Interface

Implementation of the Shape Interface

Implementation of the Filter Interface

Exporting the Plugin

The .pro File

Plug & Paint Extra Filters Example

Regular Expressions Example

Settings Editor Example

Style Plugin Example

SimpleStylePlugin Class Definition

SimpleStylePlugin Class Implementation

The function

The Simple Style Plugin Profile

Related articles and examples

Tree Model Completer Example

The Resource File

TreeModelCompleter Class Definition

TreeModelCompleter Class Implementation

MainWindow Class Definition

MainWindow Class Implementation

Function

Undo Framework Example

MainWindow Class Definition

MainWindow Class Implementation

AddCommand Class Definition

AddCommand Class Implementation

DeleteCommand Class Definition

DeleteCommand Class Implementation

MoveCommand Class Definition

MoveCommand Class Implementation

DiagramScene Class Definition

The Function

Touch Dials Example

Finger Paint Example

Touch Knobs Example

Pinch Zoom Example

Trademarks

Tutoriel "Carnet d'adresses"

Address Book Tutorial

Tutorials

Qt Creator Tutorial

Qt Essentials

Qt Quick Essentials

QtWebKit

Qt Utilities

Online Learning Materials

Carnet d'adresses 1 - Conception de l'interface utilisateur

Programmation en Qt - héritage

La classe AddressBook

Implémentation de la classe AddressBook

Exécution de l'application

Carnet d'adresses 2 - Ajouter des adresses

Définition de la classe AddressBook

Implémentation de la classe AddressBook

Carnet d'adresses 3 - Navigation entre les éléments

Définition de la classe AddressBook

Implémentation de la classe AddressBook

Carnet d'Adresses 4 - éditer et supprimer des adresses

Définition de la classe AddressBook

Implémentation de la classe AddressBook

Mise à jour de l'Interface utilisateur

Carnet d'adresse 5 - Ajout d'une fonction de recherche

Définition de la classe FindDialog

Implémentation de la classe FindDialog

Définition de la classe AddressBook

Implémentation de la classe AddressBook

Carnet d'Adresses 6 - Sauvegarde et chargement

Définition de la classe AddressBook

Implémentation de la classe AddressBook

Carnet d'adresse 7 - Fonctionnalités avancées

Définition de la classe AddressBook

Implémentation de la classe AddressBook

Part 1 - Designing the User Interface

Qt Programming - Subclassing

Defining the AddressBook Class

Implementing the AddressBook Class

Running the Application

Part 2 - Adding Addresses

Defining the AddressBook Class

Implementing the AddressBook Class

Part 3 - Navigating between Entries

Defining the AddressBook Class

Implementing the AddressBook Class

Part 4 - Editing and Removing Addresses

Defining the AddressBook Class

Implementing the AddressBook Class

Updating the User Interface

Part 5 - Adding a Find Function

Defining the FindDialog Class

Implementing the FindDialog Class

Defining the AddressBook Class

Implementing the AddressBook Class

Part 6 - Loading and Saving

Defining the AddressBook Class

Implementing the AddressBook Class

Part 7 - Additional Features

Defining the AddressBook Class

Implementing the AddressBook Class

Widgets Tutorial - Child Widgets

Widgets Tutorial - Nested Layouts

Setting up the Model

Widgets Tutorial - Creating a Window

Widgets Tutorial - Using Layouts

User Interface Compiler (uic)

Options

Examples

Multiple Inheritance Example

CalculatorForm Definition

CalculatorForm Implementation

Function

Text Finder Example

Setting Up The Resource File

TextFinder Class Definition

TextFinder Class Implementation

Function

Unicode in Qt

Qt's Classes for Working with Strings

Information about Unicode on the Web

The Standard

Unicode in Qt

Calling Qt Functions From Unix Signal Handlers

url

Using QtDBus Adaptors

variant

vector3d

anim_accord

anim_demo-rotate

anim_demo-scale

anim_demo-skew

anim_gallery

anim_panel

anim_pulse

anim_skew

anim_slide1

anim_tabbedSkew

css3_mask-grad_css

css3_backgrounds

css3_border-img

css3_grad-radial

css3_gradientBack

css3_gradientBackStop

css3_gradientButton

css3_mask-grad

css3_mask-img

css3_multicol

css3_reflect

css3_scroll

css3_sel-nth

css3_text-overflow

css3_text-shadow

css3_text-stroke

form_tapper

form_toggler

css3_mask-grad_js

layout_link-fmt

layout_tbl-keyhole

mob_condjs

mob_layout

mob_mediaquery

ex_storage

anim_accord_css

anim_demo-rotate_css

anim_demo-scale_css

anim_demo-skew_css

anim_gallery_css

anim_panel_css

anim_pulse_css

anim_skew_css

anim_slide_css

anim_tabbedSkew_css

css3_backgrounds_css

css3_border-img_css

css3_grad-radial_css

css3_gradientBack_css

css3_gradientBackStop_css

css3_gradientButton_css

css3_mask-img_css

css3_multicol_css

css3_reflect_css

css3_scroll_css

css3_sel-nth_css

css3_text-overflow_css

css3_text-shadow_css

css3_text-stroke_css

form_tapper_css

form_toggler_css

layout_link-fmt_css

layout_tbl-keyhole_css

mob_condjs_css

mob_mediaquery_css

mq_desktop_css

mq_mobile_css

mq_touch_css

mqlayout_desktop_css

mqlayout_mobile_css

mqlayout_touch_css

storage_css

anim_gallery_js

anim_panel_js

anim_skew_js

css3_backgrounds_js

css3_grad-radial_js

css3_text-overflow_js

mob_condjs_js

storage_js

DOM Traversal Example

Window Class Definition

Window Class Implementation

Starting the Example

Further Reading

Fancy Browser Example

MainWindow Class Definition

MainWindow Class Implementation

Form Extractor Example

WebKit Frame Capture Example

Google Chat Example

The Webkit Bridge Tutorial - Hybrid Client Application

Previewer Example

The User Interface

Previewer Class Definition

Previewer Class Implementation

MainWindow Class Definition

MainWindow Class Implementation

The Function

Simple Selector Example

Window Class Definition

Window Class Implementation

Starting the Example

Further Reading

Simple Web Plugin Example

QtWebKit Basics

Adding a Widget to a Page

Creating a Widget to Embed

Further Reading

Web FTP Client Example

Introduction

Network Access

Creating a New Network Manager

Creating a Custom Reply

Fetching Data from the Server

Preparing Content for the Reader

Supplying Data to the Browser

Enabling the Protocol

Summary

QtWebKit Guide Files

Web Plugin Example

Setting up Communications

Connecting Components Together

Linking Things Together

Widgets and Layouts

Widgets

Layouts

Widget Styles

The Widget Classes

Basic Widgets

Advanced Widgets

Organizer Widgets

Abstract Widget Classes

Widgets Tutorial

Introduction

Writing a main Function

Simple widget examples

Real world widget examples

Building The Examples

Analog Clock Example

AnalogClock Class Definition

AnalogClock Class Implementation

Application Icon Example

Creating an icon for Maemo

Creating an icon for Symbian

Adding the icons to the project

Calculator Example

Calculator Class Definition

Calculator Class Implementation

Button Class Definition

Button Class Implementation

Calendar Widget Example

Window Class Definition

Window Class Implementation

Character Map Example

CharacterWidget Class Definition

CharacterWidget Class Implementation

MainWindow Class Definition

MainWindow Class Implementation

Code Editor Example

The LineNumberArea Class

CodeEditor Class Definition

CodeEditor Class Implementation

Suggestions for Extending the Code Editor

Digital Clock Example

DigitalClock Class Definition

DigitalClock Class Implementation

Elided Label Example

ElidedLabel Class Definition

ElidedLabel Class Implementation

TestWidget Class Definition

TestWidget Class Implementation

The Function

Group Box Example

Window Class Definition

Window Class Implementation

Icons Example

QIcon Overview

Overview of the Icons Application

Line-by-Line Walkthrough

IconPreviewArea Class Definition

IconPreviewArea Class Implementation

MainWindow Class Definition

MainWindow Class Implementation

IconSizeSpinBox Class Definition

IconSizeSpinBox Class Implementation

ImageDelegate Class Definition

ImageDelegate Class Implementation

Image Viewer Example

ImageViewer Class Definition

ImageViewer Class Implementation

Line Edits Example

Window Class Definition

Window Class Implementation

Maemo Vibration Example

MceVibrator Class Definition

MceVibrator Class Implementation

ButtonWidget Class Definition

ButtonWidget Class Implementation

Function

Movie Example

Orientation Example

Landscape UI

Portrait UI

MainWindow Class Definition

MainWindow Class Implementation

The Function

Scribble Example

ScribbleArea Class Definition

ScribbleArea Class Implementation

MainWindow Class Definition

MainWindow Class Implementation

Shaped Clock Example

ShapedClock Class Definition

ShapedClock Class Implementation

Notes on Widget Masks

Sliders Example

Window Class Definition

Window Class Implementation

SlidersGroup Class Definition

SlidersGroup Class Implementation

Soft Keys Example

Spin Boxes Example

Window Class Definition

Window Class Implementation

Styles Example

NorwegianWoodStyle Class Definition

NorwegianWoodStyle Class Implementation

WidgetGallery Class

Style Sheet Example

Symbian Vibration Example

XQVibra Class Definition

VibrationSurface Class Definition

VibrationSurface Class Implementation

MainWindow Class Definition

MainWindow Class Implementation

Symbian Vibration Library

Tablet Example

MainWindow Class Definition

MainWindow Class Implementation

TabletCanvas Class Definition

TabletCanvas Class Implementation

TabletApplication Class Definition

TabletApplication Class Implementation

The function

Tetrix Example

TetrixWindow Class Definition

TetrixWindow Class Implementation

TetrixPiece Class Definition

TetrixPiece Class Implementation

TetrixBoard Class Definition

TetrixBoard Class Implementation

Tool Tips Example

SortingBox Class Definition

SortingBox Class Implementation

ShapeItem Class Definition

ShapeItem Class Implementation

Validators Example

Wiggly Example

Dialog Class Definition

Dialog Class Implementation

WigglyWidget Class Definition

WigglyWidget Class Implementation

Window Flags Example

ControllerWindow Class Definition

ControllerWindow Class Implementation

PreviewWindow Class Definition

PreviewWindow Class Implementation

Windows CE - Introduction to using Qt

Required tools

Installing Qt

Building your own applications

Running the application

Support for Windows

Qt on Windows

Getting Started on Windows

Key Features for Windows Development

Rich Class Library

Integrated Development Tools

Cross-Platform Development using Qt Creator

Visual Studio Add-in.

Windows CE - Working with Custom SDKs

Creating a Custom Build Specification

Fine-Tuning Options

Cross-compilation Environment for a Custom SDK

Compiling Qt for a Custom SDK

Making Qt Applications Start on a Custom Device

Qt for Windows CE and OpenGL ES

Introduction

Using OpenGL ES with Qt

Using OpenGL with Qt for Windows CE

Configure

Using OpenGL to Accelerate Normal 2D Painting

Qt for Windows CE and OpenVG

Introduction

Using OpenVG with Qt

Configure

Supported OpenVG Engines

Using the OpenVG graphics system

Supported features

Known issues

Using OpenVG with Qt for Windows CE

Windows CE - Signing

Signing on Windows CE

Window System Specific Notes

Qt for X11

Qt for Windows

Qt for Mac OS X

Qt for Embedded Linux

Qt for Windows CE

Qt for the Symbian platform

anim_accord_js

How to Use X11 Overlays with Qt

Working with the DOM Tree

Introduction to DOM

An Introduction to Namespaces

Conventions Used in the Qt XML Documentation

XML Processing

Topics:

Classes for XML Processing

The SAX interface

Introduction to SAX2

SAX2 Features

Namespace Support via Features

Summary

Properties

XML Streaming

XML Classes

DOM Bookmarks Example

XML HTML Info Example

Basic Operation

RSS-Listing Example

SAX Bookmarks Example

QXmlStream Bookmarks Example

XbelWriter Class Definition

XbelWriter Class Implementation

XbelReader Class Definition

XbelReader Class Implementation

MainWindow Class Definition

MainWindow Class Implementation

Function

XML Stream Lint Example

Basic Operation

File System Example

Introduction

The User Inteface

Running your own XQueries

Code Walk-Through

The Custom Node Model Class: FileTree

Accessing The Node Model

Building And Traversing The Node Model

The UI Class: MainWindow

Selecting A Directory To Model

Selecting And Running An XQuery

Node Model Building Strategy

QObject XML Model Example

Introduction

The User Interface

Code Walk-Through

The Custom Node Model Class: QObjextXmlModel

Accessing The Node Model

Traversing The Node Model

Including The QMetaObject Tree

Recipes Example

Introduction

The User Interface

Running your own XQueries

Code Walk-Through

The UI Class: QueryMainWindow

XML Schema Validation Example

Introduction

The User Interface

Validating XML Instance Documents

Code Walk-Through

The UI Class: MainWindow

TrafficInfo Example

Overview

Retrieving the Data

C++ Source Code Analyzer Example

Introduction

Reporting Uses of Mutable Global Variables

A C++ application

The XML description of the C++ application

The XQuery for finding global variables

Running the XQuery

The XQuery output

XQuery Code Walk-Through

XQuery

Introduction

Advantages of using QtXmlPatterns and XQuery

Using the QtXmlPatterns module

Running the query engine from your Qt application

Running the query engine from the command line utility

The XQuery Data Model

Binding program variables to XQuery variables

Binding To QVariant::Time

Binding To QVariantList

Interpreting XQuery results

Handling QXmlNames

No mapping for xs:time

Using XQuery with Non-XML Data

More on using QtXmlPatterns with non-XML Data

Security Considerations

Code Injection

Denial of Service Attacks

Features and Conformance

XQuery 1.0

XSLT 2.0

XPath 2.0

xml:id

XML Schema 1.0

Resource Loading

XML

A Short Path to XQuery

Introduction

Using Path Expressions To Match And Select Items

Axis Steps

Axis Specifiers

Node Tests

Shorthand Form

Name Tests

Wildcards in Name Tests

Using Predicates In Path Expressions

Positional Predicates

Boolean Predicates

Constructing Elements

Element Constructors are Expressions

Constructing Atomic Values

Running The Cookbook Examples

Further Reading

FAQ

Why didn't my path expression match anything?

What if my input namespace is different from my output namespace?

Why doesn't my return clause work?

Why didn't my expression get evaluated?

My predicate is correct, so why doesn't it select the right stuff?

Why doesn't my FLWOR behave as expected?

Why are my elements created in the wrong order?

Why can't I use and in my XQuery?

Qt Backends

Browser Features

Examples

Resources

Inspector configuration persistence

Using QWebPage in a Widget-less Environment

Enabling Plugins

Web Application Support

Elements of QWebView

Creating Your Own Codec Class

Flags and the Meta-Object System

Naming Convention

Versioning

Reading and writing raw binary data

Reading and writing Qt collection classes

Reading and writing other Qt classes.

Basic Use

Writing Custom Types to a Stream

Navigation and Directory Operations

Files and Directory Contents

The Current Directory and Other Special Paths

Path Manipulation and Strings

Examples

Reading Files Directly

Using Streams to Read Files

Signals

Platform Specific Issues

Performance Issues

Running a Process

Communicating via Channels

Synchronous Process API

Notes for Windows Users

Symbian Platform Security Requirements

Dynamic Resource Loading

Basic Usage

QVariant and GUI Types

Section and Key Syntax

Fallback Mechanism

Restoring the State of a GUI Application

Accessing Settings from Multiple Threads or Processes Simultaneously

Platform-Specific Notes

Locations Where Application Settings Are Stored

Accessing INI and .plist Files Directly

Accessing the Windows Registry Directly

Accessing Common Registry Settings on Windows

Securing application settings in Symbian

Changing the location of global Qt settings on Mac OS X

Platform Limitations

Character Conversions

Subclassing

Subclassing

Subclassing

The Event Loop and Event Handling

Application and Library Paths

Internationalization and Translations

Accessing Command Line Arguments

Locale Settings

Property Meta-Data

Copying and Assignment

Platform-Specific MIME Types

No copy constructor or assignment operator

Auto-Connection

Dynamic Properties

Internationalization (i18n)

Notes for Windows Users

Platform-Specific Behavior

Accuracy and Timer Resolution

Alternatives to QTimer

Looking up Translations

Using Multiple Translations

A Note on GUI Types

Using canConvert() and convert() Consecutively

Subclassing

Subclassing

Subclassing

States with Child States

Non-atomic convenience operators

The Atomic API

Reference counting

Memory ordering

Test-and-set

Fetch-and-store

Fetch-and-add

Feature Tests for the Atomic API

Non-atomic convenience operators

The Atomic API

Memory ordering

Test-and-set

Fetch-and-store

Fetch-and-add

Feature Tests for the Atomic API

Caveats

Notes on Locale

Number-String Conversions

8-bit Character Comparisons

Use of Gregorian and Julian Calendars

Use of Gregorian and Julian Calendars

No Year 0

Range of Valid Dates

Use of Gregorian and Julian Calendars

Use of Gregorian and Julian Calendars

No Year 0

Range of Valid Dates

Use of System Timezone

Daylight Savings Time (DST)

Reference clocks

32-bit overflows

Rendering

Coordinates

Rendering

Coordinates

Introduction

Characters and Abbreviations for Sets of Characters

Sets of Characters

Quantifiers

Capturing Text

Assertions

Wildcard Matching

Notes for Perl Users

Code Examples

Custom cleanup handlers

Forward Declared Pointers

Implicit vs Explicit Sharing

Thread-Safety

Other Pointer Classes

Optional pointer tracking

Tracking QObject

Initializing a String

Manipulating String Data

Querying String Data

Converting Between 8-Bit Strings and Unicode Strings

Distinction Between Null and Empty Strings

Argument Formats

More Efficient String Construction

Adding strings

Iterating over the strings

Manipulating the strings

Namespaces

Incremental parsing

Performance and memory consumption

Availability

Network Components

The Context Hierarchy

An example

An example

Asynchronous image loading

Image caching

Relationships and Navigation

Properties

Actions and Selection

Objects and children

Modal Dialogs

Modeless Dialogs

Default Button

Escape Key

Extensibility

Return Value (Modal Dialogs)

Code Examples

Example Usage

Caching and Performance

The Property-based API

Rich Text and the Text Format Property

Severity Levels and the Icon and Pixmap Properties

The Static Functions API

Advanced Usage

Default and Escape Keys

A Trivial Example

Wizard Look and Feel

Elements of a Wizard Page

Registering and Using Fields

Creating Linear Wizards

Creating Non-Linear Wizards

Dynamic Allocation

Static Allocation

Rendering

Framebuffer Management

Palette Management

Drawing on Screen

Properties

Subclassing and Initial Values

Creating Custom Input Methods

Using Input Methods

Client Administration

Mouse Handling

Keyboard Handling

Display Handling

Input Method Handling

Size Hints and Size Policies in an Anchor Layout

Spacing within an Anchor Layout

Known issues

Size Hints and Size Policies in QGraphicsGridLayout

Transformations

Painting

Sorting

Events

Custom Data

Parents and Children

Writing a Custom Layout

Activating the Layout

Activating the Layout Implicitly

Event Handling

Margin Handling

Subclassing QGraphicsLayoutItem

Nesting QGraphicsLayoutItems

Size Hints and Size Policies in QGraphicsLinearLayout

Spacing within QGraphicsLinearLayout

Stretch Factor in QGraphicsLinearLayout

QGraphicsLinearLayout Compared to Other Layouts

Embedding a Widget with QGraphicsProxyWidget

Synchronizing Widget States

Event Handling and Propagation

Making Classes that Use QIcon

Reading and Writing Image Files

Image Information

Pixel Manipulation

Image Formats

Image Transformations

Legal Information

Reading and Writing Image Files

Pixmap Information

Pixmap Conversion

Pixmap Transformations

Groups of Functions

Licensing Information

Moving Header Sections

Appearance

Standard Roles and Data Types

Subclassing

QStyledItemDelegate vs. QItemDelegate

Standard Editing Widgets

Improving Performance

Subclassing

Sorting

Filtering

Subclassing

Subclassing

Subclassing QStyledItemDelegate

QStyledItemDelegate vs. QItemDelegate

Navigation

Visual Appearance

Coordinate Systems

Styles

Subclassing

Key Bindings

Improving Performance

Subclassing

Notes for X11 Users

Notes for Mac OS X Users

Notes for Windows and Mac OS X Users

A Note for X11 Users

Obtaining a Desktop Widget

Screen Geometry

Use of the Primary Screen

Further Reading

Automatic Clipping

Notes for X11 Users

Enabling Touch Events

Event Handling

Event Delivery and Propagation

Touch Point Grouping

Mouse Events and the Primary Touch Point

Caveats

Gesture Properties

Lifecycle of a Gesture Object

Recognizing Gestures

Supporting New Gestures

Standard Shortcuts

Keyboard Layout Issues

GNU Emacs Style Key Sequences

Top-Level and Child Widgets

Composite Widgets

Custom Widgets and Painting

Size Hints and Size Policies

Events

Groups of Functions and Properties

Widget Style Sheets

Transparency and Double Buffering

Creating Translucent Windows

Native Widgets vs Alien Widgets

Softkeys

Integer vs. Floating Point Precision

Alpha-Blended Drawing

Predefined Colors

The HSV Color Model

The HSL Color Model

The CMYK Color Model

Rendering Graphics

Basic Matrix Operations

Settings

Drawing

Rendering Quality

Coordinate Transformations

Clipping

Composition Modes

Limitations

Performance

Composing a QPainterPath

QPainterPath Information

QPainterPath Conversion

Examples

Pen Style

Cap Style

Join Style

Creating and Using Regions

Additional License Information

Rendering Graphics

Basic Matrix Operations

Setting a Style

Developing Style-Aware Custom Widgets

Creating a Custom Style

Using a Custom Style

Right-to-Left Desktops

Styles in Item Views

Basic Usage

Iterating Through Completions

The Completion Model

Handling Tree Models

URL Handlers

Undo and Redo Actions

Command Compression and Macros

Clean State

Using a Pop-up Calendar Widget

Appearance

Qt Main Window Framework

Creating Main Window Components

Creating Menus

Creating Toolbars

Creating Dock Widgets

The Status Bar

Storing State

Subwindow Handling

Actions

QMenu on Qt for Windows CE

QMenu on Mac OS X with Qt build against Cocoa

Usage

Platform Dependent Look and Feel

QMenuBar on Mac OS X

QMenuBar on Windows CE

Examples

Introduction and Concepts

Using QPlainTextEdit as a Display Widget

Read-only Key Bindings

Using QPlainTextEdit as an Editor

Syntax Highlighting

Editing Key Bindings

Differences to QTextEdit

Size Hints and Layouts

Subclassing QSpinBox

Document Source and Contents

Navigation

Introduction and Concepts

Using QTextEdit as a Display Widget

Read-only Key Bindings

Using QTextEdit as an Editor

Drag and Drop

Editing Key Bindings

Symbian Platform Security Requirements

Network and Roaming support

Symbian Platform Security Requirements

Configuration states

Roaming

Options

Basic

NTLM version 2

Digest-MD5

SOCKS5

System Proxies

Symbian Platform Security Requirements

Symbian Platform Security Requirements

Symbian Platform Security Requirements

Symbian Platform Security Requirements

Overlays

Painting Techniques

Threading

Threading

Threading

Introduction

Writing portable shaders

Simple shader example

Binary shaders and programs

Creating and using preview widgets

Drag and Drop

Headers

Rows and Columns

Cells

Large tables

Selections

Signals

Notes for Windows users

Introduction and Concepts

Using Q3TextEdit as a Display Widget

Read-only key bindings

Using Q3TextEdit in Qt::LogText Mode

Using Q3TextEdit as an Editor

Editing key bindings

Lines.

Using One Big Widget

Using a Very Big View with Some Widgets

Using a Very Big View with Many Widgets

Details Relevant for All Views

Evaluating Scripts

Engine Configuration

Script Exceptions

Script Object Creation

QObject Integration

Support for Custom C++ Types

Importing Extensions

Native Functions

Long-running Scripts

Garbage Collection

Core Debugging/Tracing Facilities

Approaches to Binding Values

Usage

Subclassing

Thread Safety

XQuery Sequences

Comparing QXmlNames

Running XQueries

Running XPath Expressions

Running XSLT stylesheets

Binding A Query To A Starting Node

Reentrancy and Thread-Safety

Error Handling

Resource Management

Event Handling

XML Schema Version

XML Schema Version