summaryrefslogtreecommitdiffstats
path: root/lib/interfaces/external/Mainpage.dox
blob: 0febd41d8cfcd5ac9568da06659494af1ba2b299 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
/**
@mainpage The %KInterfaceDesigner Library

This library contains all %KInterfaceDesigner classes and interfaces which form the core of 
GUI Designer integration framework.

<b>Link with</b>: -lkinterfacedesigner

<b>Include path</b>: -I\$(kde_includes)/kinterfacedesigner

\section designerintegration Overview of GUI designer integration process
Each KPart that wants to act as a GUI Designer must implement @ref KInterfaceDesigner::Designer
interface. It defines necessary Q_SIGNALS to communicate with an IDE and abstract virtual
functions to determine designer type.

If a part which can "design" user interface files of a certain mimetype
implements this interface and sets itself as a default handler for that 
mimetype then it becomes automatically integrated into TDevelop IDE.

When a part is embedded into TDevelop shell, its Q_SIGNALS (defined in @ref
KInterfaceDesigner::Designer interface):
@code
    void addedFunction(DesignerType type, const TQString &formName, Function function)
    void removedFunction(DesignerType type, const TQString &formName, Function function)
    void editedFunction(DesignerType type, const TQString &formName, Function oldFunction, Function function)
    void editFunction(DesignerType type, const TQString &formName, const TQString &functionName)
    void editSource(DesignerType type, const TQString &formName);
@endcode
are connected to corresponding Q_SLOTS of TDevelop designer integration engine which can be implemented in TDevelop language support plugin.
 
Each language support which wants to use integrated designer, must reimplement 
@code
virtual KDevDesignerIntegration *KDevLanguageSupport::designer(KInterfaceDesigner::DesignerType type)
@endcode
method and return designer integration object.

Convenience designer integration support library is available for programming language support
developers. With the convenience library writing %Qt designer integration for the language is a
trivial task.


\section kdevdesigner TDevelop Designer technical overview
TDevelop version >= 3.1 comes with a customized version (fork ;)) of %Qt Designer. It is called TDevelop Designer (KDevDesigner, kdevdesigner from the command line). KDevDesigner has some important differences:
- KDevDesigner provides a read/write KPart which can be embedded into any application which wants to edit .ui files. TDevelop IDE embeds KDevDesigner this way.
- KDevDesigner uses %KDE icons and dialogs and thus provides better integration with a system.
.

It is safe to preview forms with some %KDE widgets from tdeui and tdeio libraries - KDevDesigner part is linked to those libraries so it will not crash under some circumstances.

KDevDesigner will not create .ui.h files - this feature is completely disabled. Integrated KDevDesigner will use subclassing approach, standalone does not allow to enter code.

\section other Other information

@note It is technically possible to integrate not only %Qt Designer, but also, for example, Glade. Glade-3 can be compiled as a library and probably be embedded via XParts technology.

*/