The hk_kdeclasses programmer's tutorial

Horst Knorr

Version 0.1.4

Abstract

Thanks to Salvatore Enrico Indiogine for proof-reading the documentation.

This is a short, quick and dirty tutorial to help you to write programs with hk_kdeclasses. For further information see the programmer's API documentation. This manual describe hk_kdeclasses version 0.5.3. To compile the source code of example.cpp use

c++ -o example example.cpp  -ldl -lhk_classes -L/usr/lib/hk_classes/ \
-I /usr/include/hk_classes  -L /opt/kde3/lib -lkdecore -lkdeui -lhk_kdeclasses \
-L/usr/lib/qt3/lib -lqt -I /opt/kde3/include -I /usr/lib/qt3/include

All examples refer to the example database "literature" described in the knoda tutorial. First you should first create this database (it is best to use knoda for this).

Please read the hk_classes tutorial first, because we take these examples and use it for KDE. You should also have some experience in programming with KDE.


Table of Contents

1. Getting started
2. A graphical login
3. Adding data sensitive widgets
The hk_kdeclasses widgets
Adding a data sensitive widget
Adding a grid with a depending data source
4. The high level widgets
Forms
Tables
5. A runtime version

List of Figures

3.1. The example application

List of Examples

1.1. The first program
2.1. Getting the messages to KDE
3.1. Adding a lineedit field
3.2. Adding a row selector
3.3. Adding a grid with a depending data source
4.1. Using a form
4.2. Using a table
5.1. Using a table - the runtime version