*******************************
*   KDE Kolor Manager README  *
*******************************

started by Joe Simon in summer 2008-2009
KolorManager maintained by Kai-Uwe Behrmann 2010-2014
KolorServer maintained by Casian Andrei 2012

*kmdevices (Kolor Management Devices - Monitor/Printer/etc. profile setup)
*kminfo (Kolor Management Information - Displays specific profile information)
*kmsettings (Kolor Management Settings - Change behavior and policy settings)
*kolorserver (X Color Management support for KWin)

-----REQUIRED LIBRARIES---------------------------------------------

- The v1.0.2 tagged release builds fine using Oyranos-0.9.5 .
- Actual git should the latest Oyranos from it's git repository. KolorManager gets updated pretty quick to Oyranos changes.


-----INSTALLATION----------------------------------------------------

Enter the following commands in the "build" directory:

cmake ..
make
make install


-----RUNNING-------------------------------------------------------

-This build should install a "Kolor Management" icon in the KDE4 settings window, under "Computer Administration".  An alternative method for running the individual modules would be to type this in a terminal:

kcmshell4 [KMMODULE]     (Where KMMODULE is "kmdevices", "kminfo", or "kmsettings")  

This is handy for displaying debug information through the console.


-----BUILD NOTES-----------------------------------------------

The following files are installed under each module directory.  They are shown here for reference:

MODULE.cpp (source code)
MODULE.h (header)
MODULE.ui (Qt Designer file)
icons.qrc (resource file for icons in 'kmdevices' and 'kminfo')
ui_MODULE.h (Qt designer header file - for hand coding purposes)
CMakeLists.txt (build instructions for each module)


-----LINKS---------------------------------------------------------------------

http://www.oyranos.org/kolormanager
ColourWiki: http://www.oyranos.org/wiki/index.php?title=Kolor-manager

-----DEVELOPMENT---------------------------------------------------------------

# local debug build
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=~/.kde4/ -DCMAKE_BUILD_TYPE=debugfull -DCMAKE_CXX_FLAGS="-g -Wall" ../kolor-manager
#Possibly prepend the PKG_CONFIG_PATH variable to reflect Oyranos...
kbuildsycoca4 # update KDEs internal icon and module cachings
kcmshell4 kminfo & # start

# Debug
echo $!  # obtain process id from bashs most recent process - kcmshell4
KDE_DEBUG=1 gdb kcmshell4  # the variable avoid KDE's crash handler
gdb > attach to process id
gdb > breakpoint kminfo.cpp:line_number
gdb > continue

# create tar ball from git
sha=`cat .git/refs/heads/master | head -c 8`
git archive --format=tar --prefix=kolor-manager-$sha/ HEAD | bzip2 > kolor-manager-$sha.tar.bz2

# show kolorserver
qdbus org.kde.kded /kded loadedModules | grep kolorserver
# restart kded (omit kdeinit4_wrapper to see LD_LIBRARY_PATH)
kquitapp kded; sleep 1s; kdeinit4_wrapper kded4
# kdebugdialog --fullmode   might be useful


-----MAJOR CHANGES FROM LAST TEST BUILDS---------------------------------------

GENERAL
-Icons should now be visible (kmdevices/kminfo)
-Column widths are now tidied up.


-----CURRENT ISSUES (FIXME)----------------------------------------------------

The following issues, shall be forwarded as "FIXMEs" from here on:

KMSETTINGS
-The configuration has to be ported to a Oyranos configure object to manipulate
settings and then apply at once. This is currently not possible, as each setting
is imediately applied to the Oyranos settings DB.  

KMDEVICES
-Camera support needs to be outlined first

KMINFO
-There needs to be a way to refresh the profile listing every time a change has been made in 'devices' and 'settings' modules.  Right now, the user must restart Kolor Manager in order to see 
the profile listing to be changed in Information.
