Each item is showed with an icon who
represent his kind (function, member, structure etc.) and access
(public, private and protected). By right-click, each item display
a menu popup to open his implementation and declaration. If the
implementation if available, the double-click shows it by default. The
items are updated in real
time (creation, modification and deletion) when the text in editor is
modified and the interval between two updates can be configured in
options dialog. By a right-click, it is possible to refresh the
content. When the refreshment is asked, the tree browser is cleared and
all files of project are parsed, what can be slow. To use the class
browser, please read the ctags chapter
Add new method to a class
By right-click on a class name, the menu "Add Method...
" allow to add a new method to this class.
Add new variable to a class
By right-click on a class name, the menu "Add Variable...
" allow to add a new variable to this class.
Add set and get methods to a variable member
The dialog files (.ui) created with Qt Designer contain XML and require
to be transformed into header C++ files to be compiled with the
project. For the dialogs of the project, the transformation is
launched automatically with compilation. This conversion which makes
the dialogs comprehensible by the compiler does not make it possible to
enter the code to execute by these dialogs. An interesting
functionality of QDevelop is to provide an assistance to the
implementation of the dialogs. A right-click on the (.ui) file in
explorer then choice "Dialog subclassing..." shows the sub-classing
window. It list all the widgets present in the dialog and allow, for
each to choose the signals to implement.
The sub-classing is created in two new files (.h) and (.cpp) who
contain a new class inheriting of the header file generated during
compilation. The new implementation contain for each lines selected, a
new slot associating the name of the object and the selected signal.
By default, "impl
" is added to the dialog name. By example, if the name of the dialog is "dialog.ui
", the implementation filename will be "dialogimpl.cpp
" and the header filename will be "dialogimpl.h
". For the name of the class, "Dialog
" becomes by default "DialogImpl
" in the new inherited class. The automatic connections
feature is used for the sub-classing of dialogs. For example a button
named foo selected with the clicked() signal selected will make create
of the method void on_foo_clicked(). This method will be called during
the execution when the button will be clicked by the user. This feature
is available for the widgets and for the menu entries or the toolbar
QDevelop features can be extend by using plugins
Where do I install plugins?
On Linux, plugins can be installed in three locations:
- The plugins directory in /usr/lib/qdevelop/plugins
- A plugins directory in the QDevelop profiles directory (~/.qdevelop/plugins)
- The user path pointed by directory defined in "User
plugins directory" in options dialog. If it is defined, this directory
is used in place of others.
As a general rule, you should install plugins in
/usr/lib/qdevelop/plugins directory. Installing in the profiles
directory is only recommended if
you can not install plugins system-wide because of permissions issues.
The user path can be used by developper to test new plugins.
On Windows, plugins can be installed in two locations:
- The plugins directory in subdirectory plugins in application directory path as C:\Program Files\QDevelop\plugins
- The user path pointed by directory defined in "User plugins
directory" in options dialog. If it is defined, this directory is used
in place of others.