Viadeo Twitter Google Bookmarks ! Facebook Digg del.icio.us MySpace Yahoo MyWeb Blinklist Netvouz Reddit Simpy StumbleUpon Bookmarks Windows Live Favorites 
Logo Documentation Qt ·  Page d'accueil  ·  Toutes les classes  ·  Toutes les fonctions  ·  Vues d'ensemble  · 

FAQ

This section contains answers to some frequently asked questions about Qt Creator. You might also find answers to your questions in the Known Issues and Tips and Tricks sections, or the Troubleshooting sections for a special area, such as debugging.

General Questions

How do I reset all Qt Creator settings?

Qt Creator creates two files and a directory:

  • QtCreator.db
  • QtCreator.ini
  • qtcreator

The location depends on the platform. On Linux, Unix, and Mac OS, the files are located in ~/.config/Nokia.

On Windows XP, the files are located in <drive>:\Documents and Settings\<username>\Application Data\Nokia, and on Windows Vista and Windows 7 in <drive>:\Users\<username>\AppData\Roaming\Nokia. For all versions, try the path APPDATA\Nokia.

Qt Creator comes with MinGW, should I use this version with Qt?

Use the version that was built against the Qt version.

Qt Creator does not find a helper application, such as Git or a compiler. What should I do?

Make sure that the application is in your system PATH when starting Qt Creator. Also select Tools > Options to check the settings specified for the application. Many plugins specify either the path to the tool they need or the environment they run in.

This is especially relevant for the Mac OS where /usr/local/bin might not be in the path when Qt Creator is started.

How do I change the interface language for Qt Creator?

Qt Creator has been localized into several languages. If the system language is one of the supported languages, it is automatically selected. To change the language, select Tools > Options > Environment and select a language in the Language field. The change takes effect after you restart Qt Creator.

Has a reported issue been addressed?

You can look up any issue in the Qt bug tracker.

Qt Designer Integration Questions

Why are custom widgets not loaded in Design mode even though it works in standalone Qt Designer?

Qt Designer fetches plugins from standard locations and loads the plugins that match its build key. The locations are different for standalone and integrated Qt Designer.

For more information, see Adding Qt Designer Plugins.

Help Questions

The Qt API Reference Documentation is missing and context help does not find topics. What can I do?

Qt Creator comes fully integrated with Qt documentation and examples using the Qt Help plugin. The integrated Qt Reference Documentation is available for Qt 4.4 and later. Qt Creator, Qt SDK, and other Qt deliverables contain documentation as .qch files. All the documentation is accessible in the Help mode.

To view the documentation that is available and to add documentation, select Tools > Options... > Help > Documentation. For more information, see Adding External Documentation.

Debugger Questions

For information on troubleshooting debugger, see Troubleshooting Debugger.

If I have a choice of GDB versions, which should I use?

On Linux and Windows, use the Python-enabled GDB versions that are installed when you install Qt Creator and Qt SDK. On Mac OS X, use the GDB provided with Xcode. For a custom target, you can build your own Python-enabled GDB. Follow the instructions in Building GDB.

You must use at least Python version 2.5, but we recommend that you use version 2.6.

For more information on setting up debugger, see Setting Up Debugger.

How do I generate a core file in Qt Creator?

To trigger the GDB command that generates a core file while debugging, select Window > Views > Debugger Log. In the Command field, type gcore and press Enter. The core file is created in the current working directory. You can specify another location for the file, including a relative or absolute path, as an argument of the command.

To generate a temporary core file, select Create Snapshot in the context menu in the Snapshot view. The core file is deleted when you stop debugging.

Code Editor Questions

How can I get code-completion to work on the standard headers and phonon?

Install a build from March 31, 2009, or later.

Compiler Questions

How can I make use of my multi-core CPU with Qt Creator?

On Linux and Mac OS X, go to Project mode, select your configuration in the Build Settings, locate the Build Steps, and add the following value, where <num> is the amount of cores in your CPU: -j <num>

On Windows, nmake does not support the -j parameter. Instead, we provide a drop-in replacement called jom. You can download a precompiled version of jom from Qt FTP server. Put jom.exe in a location in the %PATH%. Go to the Build Settings and set jom.exe as the make command.

Note:: Unlike GNU make, jom automatically detects your cores and spawns as many parallel processes as your CPU has cores. You can override this behavior by using the -j parameter as described above.

Qt SDK Questions

I cannot use QSslSocket with the SDK. What should I do?

The Qt build in the SDK is built with QT_NO_OPENSSL defined. Rebuilding it is possible. For more information, see http://www.qtcentre.org/forum/f-qt-programming-2/t-qssl-19222-post94842.html.

Which development packages from the distribution are needed on Ubuntu or Debian?

 sudo apt-get install libglib2.0-dev libSM-dev libxrender-dev libfontconfig1-dev libxext-dev

If you use QtOpenGL, you also need:

 sudo apt-get install libgl-dev libglu-dev

Platform Releated Questions

Where is application output shown in Qt Creator?

On Unix (Linux and Mac OS): qDebug() and related functions use the standard output and error output. When you run or debug the application, you can view the output in the Application Output pane.

For console applications that require input, select Projects > Run Settings > Run in terminal.

On Windows: Output is displayed differently for console applications and GUI applications.

The setting CONFIG += console in the .pro file specifies that the application is built as a console application using some other runtime. When you run a console application, you can view the output in the console window of the calling application. If the calling application is a GUI application (for example, a release-built version of Qt Creator), a new console window is opened. For this type of application, qDebug() and related functions use standard output and error output.

We recommend that you select Projects > Run Settings > Run in terminal for console applications.

For GUI applications, qDebug() and related functions use the Windows API function OutputDebugString(). The output is displayed in the Application Output pane. However, only one output pane tab may be open at a time or the output is not displayed correctly. You can use an external debug output viewer, such as the DebugView for Windows to display output from GUI applications.

On Symbian OS: qDebug() and related functions use the native RDebug::Print functionality.

When you use the Symbian emulator on Windows, the output is redirected to standard debug output. To view it, you can use a Windows debug output viewer, such as the DebugView for Windows.

On devices, the RDebug output is intercepted by CODA or App TRK and then propagated to Qt Creator, which displays it in the Application Output pane.

Symbian OS provides no support for differentiating between standard output and error output.

Questions about New Features

Will a requested feature be implemented?

If it is a scheduled feature, you can see this in the task tracker. If a feature already has been implemented, it is mentioned in the changes file for the upcoming release.

Why does Qt Creator not use tabs for editors?

This question comes up from time to time, so we have considered it carefully. Here are our main reasons for not using tabs:

  • Tabs do not scale. They work fine if you have 5 to 6 editors open, they become cumbersome with 10, and if you need more horizontal space than the tab bar, the interface does not work at all.
  • Tabs do not adapt to your working set.
  • The common solution is to give the user the ability to reorder tabs. Now user has to manage tabs instead of writing code.
  • Tabs force you to limit the amount of open editors, because otherwise you get confused.

Consider the following use case: Developers want to switch editors.

In fact, developers do not want to switch editors, but might have to do so to accomplish their tasks. We need to figure out what the tasks are to provide developers with better ways to navigate while performing the tasks.

One common factor in many use cases is switching editors while working on a set of open files. While working on files A and B, users sometimes need to look at file C. They can press Ctrl+Tab to move between the files and have the files open in the correct editor according to file type. The list is sorted by last used.

Typically, users also work on multiple classes or functions that are related, even though they are defined or declared in different files. Qt Creator provides two shortcuts for that: F2 to follow the symbol and Ctrl+Shift+U to find usages.

In addition, developers can:

  • Press F4 to switch between header and source.
  • Press Alt+Left to move backwards in the navigation history.
  • Use the locator (Ctrl+K) to simply tell Qt Creator where to go.

The locator can be used to open files, but opening files is also just a step on the way to accomplish a task. For example, consider the following use case: Fix AMethod in SomeClass which comes from someclass.cpp/someclass.h.

With a tabbed user interface, developers would search for someclass.cpp in the tab bar, and then search for ::AMethod, only to find out that the method is not located in that file. They would then search for someclass.h in the tab bar, find our that the function is inline, fix the problem, and forget where they came from.

With Qt Creator, developers can type Ctrl+K m AMet to find the method. Typically, they only need to type 3 to 4 characters of the method name. They can then fix the problem and press Alt+Back to go back to where they were.

Other locator filters include c for classes, : for all symbols, and (thanks to a community contribution) . for symbols in the current file.

X

Thank you for giving your feedback.

Make sure it is related to this specific page. For more general bugs and requests, please use the Qt Bug Tracker.

[0]; s.parentNode.insertBefore(ga, s); })();
Publicité

Best Of

Actualités les plus lues

Semaine
Mois
Année
  1. « Quelque chose ne va vraiment pas avec les développeurs "modernes" », un développeur à "l'ancienne" critique la multiplication des bibliothèques 53
  2. Les développeurs ignorent-ils trop les failles découvertes dans leur code ? Prenez-vous en compte les remarques des autres ? 17
  3. Apercevoir la troisième dimension ou l'utilisation multithreadée d'OpenGL dans Qt, un article des Qt Quarterly traduit par Guillaume Belz 0
  4. BlackBerry 10 : premières images du prochain OS de RIM qui devrait intégrer des widgets et des tuiles inspirées de Windows Phone 0
  5. Quelles nouveautés de C++11 Visual C++ doit-il rapidement intégrer ? Donnez-nous votre avis 10
  6. Adieu qmake, bienvenue qbs : Qt Building Suite, un outil déclaratif et extensible pour la compilation de projets Qt 17
  7. La rubrique Qt a besoin de vous ! 1
Page suivante

Le blog Digia au hasard

Logo

Déploiement d'applications Qt Commercial sur les tablettes Windows 8

Le blog Digia est l'endroit privilégié pour la communication sur l'édition commerciale de Qt, où des réponses publiques sont apportées aux questions les plus posées au support. Lire l'article.

Communauté

Ressources

Liens utiles

Contact

  • Vous souhaitez rejoindre la rédaction ou proposer un tutoriel, une traduction, une question... ? Postez dans le forum Contribuez ou contactez-nous par MP ou par email (voir en bas de page).

Qt dans le magazine

Cette page est une traduction d'une page de la documentation de Qt, écrite par Nokia Corporation and/or its subsidiary(-ies). Les éventuels problèmes résultant d'une mauvaise traduction ne sont pas imputables à Nokia. Qt qtcreator-2.3
Copyright © 2012 Developpez LLC. Tous droits réservés Developpez LLC. Aucune reproduction, même partielle, ne peut être faite de ce site et de l'ensemble de son contenu : textes, documents et images sans l'autorisation expresse de Developpez LLC. Sinon, vous encourez selon la loi jusqu'à 3 ans de prison et jusqu'à 300 000 E de dommages et intérêts. Cette page est déposée à la SACD.
Vous avez déniché une erreur ? Un bug ? Une redirection cassée ? Ou tout autre problème, quel qu'il soit ? Ou bien vous désirez participer à ce projet de traduction ? N'hésitez pas à nous contacter ou par MP !
 
 
 
 
Partenaires

Hébergement Web