[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [pykde5] /: Added kcodeaddons support.
From:       Simon Edwards <simon () simonzone ! com>
Date:       2014-03-22 15:03:04
Message-ID: E1WRNRw-00055j-LL () scm ! kde ! org
[Download RAW message or body]

Git commit ca26344c8d2b650417c72baedfb3957032f517ee by Simon Edwards.
Committed on 22/03/2014 at 15:02.
Pushed by sedwards into branch 'master'.

Added kcodeaddons support.

M  +12   -3    CMakeLists.txt
A  +154  -0    sip/kcoreaddons/kaboutdata.sip
A  +36   -0    sip/kcoreaddons/kautosavefile.sip
A  +30   -0    sip/kcoreaddons/kbackup.sip
A  +38   -0    sip/kcoreaddons/kcompositejob.sip
A  +49   -0    sip/kcoreaddons/kcoreaddonsmod.sip
A  +67   -0    sip/kcoreaddons/kdirwatch.sip
A  +36   -0    sip/kcoreaddons/kfilesystemtype_p.sip
A  +67   -0    sip/kcoreaddons/kformat.sip
A  +103  -0    sip/kcoreaddons/kjob.sip
A  +43   -0    sip/kcoreaddons/kjobtrackerinterface.sip
A  +40   -0    sip/kcoreaddons/kjobuidelegate.sip
A  +87   -0    sip/kcoreaddons/kmacroexpander.sip
A  +42   -0    sip/kcoreaddons/kmessage.sip
A  +60   -0    sip/kcoreaddons/kprocess.sip
A  +28   -0    sip/kcoreaddons/krandom.sip
A  +36   -0    sip/kcoreaddons/krandomsequence.sip
A  +47   -0    sip/kcoreaddons/kshareddatacache.sip
A  +43   -0    sip/kcoreaddons/kshell.sip
A  +38   -0    sip/kcoreaddons/kstringhandler.sip
A  +35   -0    sip/kcoreaddons/kurlmimedata.sip
A  +89   -0    sip/kcoreaddons/kuser.sip

http://commits.kde.org/pykde5/ca26344c8d2b650417c72baedfb3957032f517ee

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 4be8899..c0f8802 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -20,7 +20,7 @@ include(PythonMacros)
 include(FeatureSummary)
 include(ECMSetupVersion)
 
-find_package(KF5 CONFIG REQUIRED Auth ItemModels ItemViews Archive Plotting Solid)
+find_package(KF5 CONFIG REQUIRED Auth ItemModels ItemViews Archive Plotting Solid CoreAddons Sonnet)
 
 #option(PYKDEUIC4_ALTINSTALL "Enable parallel-installation of the PyKDE4 tools" FALSE)
 
@@ -130,11 +130,20 @@ add_sip_python_module(PyKDE5.kplotting sip/kplotting/kplottingmod.sip KF5::Plott
 # solid
 file(GLOB solid_files_sip sip/solid/*.sip)
 set(SIP_EXTRA_FILES_DEPEND ${solid_files_sip})
+add_sip_python_module(PyKDE5.solid sip/solid/solidmod.sip KF5::Solid)
 
+## kcoreaddons
+file(GLOB kcoreaddons_files_sip sip/kcoreaddons/*.sip)
+set(SIP_EXTRA_FILES_DEPEND ${kcoreaddons_files_sip})
+add_sip_python_module(PyKDE5.kcoreaddons sip/kcoreaddons/kcoreaddonsmod.sip KF5::CoreAddons)
+
+# sonnet
+#file(GLOB sonnet_files_sip sip/sonnet/*.sip)
+#set(SIP_EXTRA_FILES_DEPEND ${sonnet_files_sip})
+#add_sip_python_module(PyKDE5.sonnet sip/sonnet/sonnetmod.sip KF5::SonnetCore KF5::SonnetUi)
 
-add_sip_python_module(PyKDE5.solid sip/solid/solidmod.sip KF5::Solid)
 
-set(PYKDE_MODULES "kitemmodels kitemviews karchive kplotting solid")
+set(PYKDE_MODULES "kitemmodels kitemviews karchive kplotting solid kcoreaddons")
 
 ###############################################################################
 
diff --git a/sip/kcoreaddons/kaboutdata.sip b/sip/kcoreaddons/kaboutdata.sip
new file mode 100644
index 0000000..38485a7
--- /dev/null
+++ b/sip/kcoreaddons/kaboutdata.sip
@@ -0,0 +1,154 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+//namespace KCrash
+//{
+//ig void                    defaultCrashHandler (int sig);
+//};
+
+class KAboutPerson
+{
+%TypeHeaderCode
+#include <kaboutdata.h>
+%End
+
+public:
+    explicit                KAboutPerson (const QString& name, const QString& task = QString(), const \
QString& emailAddress = QString(), const QString& webAddress = QString(), const QString& ocsUsername = \
QString()); +                            KAboutPerson (const KAboutPerson& other);
+    ~KAboutPerson ();
+    QString                 name () const;
+    QString                 task () const;
+    QString                 emailAddress () const;
+    QString                 webAddress () const;
+    QString                 ocsUsername () const;
+private:
+    explicit                KAboutPerson (const QString& name, const QString& email, bool \
disambiguation); +public:
+//ig    KAboutPerson&           operator= (const KAboutPerson& other);
+};
+class KAboutData
+{
+%TypeHeaderCode
+#include <kaboutdata.h>
+%End
+
+public:
+    static KAboutData       applicationData ();
+    static void             setApplicationData (const KAboutData& aboutData);
+    static void             registerPluginData (const KAboutData& aboutData);
+    static KAboutData*      pluginData (const QString& componentName);
+    enum LicenseKey
+    {
+        License_Custom,
+        License_File,
+        License_Unknown,
+        License_GPL,
+        License_GPL_V2,
+        License_LGPL,
+        License_LGPL_V2,
+        License_BSD,
+        License_Artistic,
+        License_QPL,
+        License_QPL_V1_0,
+        License_GPL_V3,
+        License_LGPL_V3
+    };
+    enum NameFormat
+    {
+        ShortName,
+        FullName
+    };
+                            KAboutData (const QString& componentName, const QString& catalogName, const \
QString& displayName, const QString& version, const QString& shortDescription = QString(), \
KAboutData::LicenseKey licenseType = KAboutData::LicenseKey::License_Unknown, const QString& \
copyrightStatement = QString(), const QString& otherText = QString(), const QString& homePageAddress = \
QString(), const QString& bugsEmailAddress = QLatin1String("submit@bugs.kde.org")); +                     \
KAboutData (const KAboutData& other); +    ~KAboutData ();
+    KAboutData&             addAuthor (const QString& name, const QString& task = QString(), const \
QString& emailAddress = QString(), const QString& webAddress = QString(), const QString& ocsUsername = \
QString()); +    KAboutData&             addCredit (const QString& name, const QString& task = QString(), \
const QString& emailAddress = QString(), const QString& webAddress = QString(), const QString& \
ocsUserName = QString()); +    KAboutData&             setTranslator (const QString& name, const QString& \
emailAddress); +    KAboutData&             setLicenseText (const QString& license);
+    KAboutData&             addLicenseText (const QString& license);
+    KAboutData&             setLicenseTextFile (const QString& file);
+    KAboutData&             addLicenseTextFile (const QString& file);
+    KAboutData&             setComponentName (const QString& componentName);
+    KAboutData&             setDisplayName (const QString& displayName);
+    KAboutData&             setProgramIconName (const QString& iconName);
+    KAboutData&             setProgramLogo (const QVariant& image);
+    KAboutData&             setOcsProvider (const QString& providerUrl);
+    KAboutData&             setVersion (const QByteArray& version);
+    KAboutData&             setShortDescription (const QString& shortDescription);
+    KAboutData&             setCatalogName (const QString& catalogName);
+    KAboutData&             setLicense (KAboutData::LicenseKey licenseKey);
+    KAboutData&             addLicense (KAboutData::LicenseKey licenseKey);
+    KAboutData&             setCopyrightStatement (const QString& copyrightStatement);
+    KAboutData&             setOtherText (const QString& otherText);
+    KAboutData&             setHomepage (const QString& homepage);
+    KAboutData&             setBugAddress (const QByteArray& bugAddress);
+    KAboutData&             setOrganizationDomain (const QByteArray& domain);
+    KAboutData&             setProductName (const QByteArray& name);
+    QString                 componentName () const;
+    QString                 productName () const;
+    QString                 displayName () const;
+    QString                 organizationDomain () const;
+    const char*             internalProgramName () const;
+    QString                 programIconName () const;
+    QVariant                programLogo () const;
+    QString                 ocsProviderUrl () const;
+    QString                 version () const;
+    const char*             internalVersion () const;
+    QString                 shortDescription () const;
+    QString                 catalogName () const;
+    QString                 homepage () const;
+    QString                 bugAddress () const;
+    const char*             internalBugAddress () const;
+    QList<KAboutPerson>     authors () const;
+    QList<KAboutPerson>     credits () const;
+    QList<KAboutPerson>     translators () const;
+    static QString          aboutTranslationTeam ();
+    QString                 otherText () const;
+    QString                 license () const;
+    QString                 licenseName (KAboutData::NameFormat formatName) const;
+    QList<KAboutLicense>    licenses () const;
+    QString                 copyrightStatement () const;
+    QString                 customAuthorPlainText () const;
+    QString                 customAuthorRichText () const;
+    bool                    customAuthorTextEnabled () const;
+    KAboutData&             setCustomAuthorText (const QString& plainText, const QString& richText);
+    KAboutData&             unsetCustomAuthorText ();
+//ig    bool                    setupCommandLine (QCommandLineParser* parser);
+//ig    void                    processCommandLine (QCommandLineParser* parser);
+//ig    KAboutData&             operator= (const KAboutData& other);
+};
+class KAboutLicense
+{
+%TypeHeaderCode
+#include <kaboutdata.h>
+%End
+
+public:
+                            KAboutLicense (const KAboutLicense& other);
+    ~KAboutLicense ();
+    QString                 text () const;
+    QString                 name (KAboutData::NameFormat formatName) const;
+    KAboutData::LicenseKey  key () const;
+    static KAboutLicense    byKeyword (const QString& keyword);
+private:
+    explicit                KAboutLicense (KAboutData::LicenseKey licenseType, const KAboutData* \
aboutData); +    explicit                KAboutLicense (const KAboutData* aboutData);
+public:
+//ig    KAboutLicense&          operator= (const KAboutLicense& other);
+};
diff --git a/sip/kcoreaddons/kautosavefile.sip b/sip/kcoreaddons/kautosavefile.sip
new file mode 100644
index 0000000..a451d65
--- /dev/null
+++ b/sip/kcoreaddons/kautosavefile.sip
@@ -0,0 +1,36 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+class KAutoSaveFile : QFile
+{
+%TypeHeaderCode
+#include <kautosavefile.h>
+%End
+
+public:
+    explicit                KAutoSaveFile (const QUrl& filename, QObject* parent = 0);
+    explicit                KAutoSaveFile (QObject* parent = 0);
+    ~KAutoSaveFile ();
+    QUrl                    managedFile () const;
+    void                    setManagedFile (const QUrl& filename);
+    virtual void            releaseLock ();
+    virtual bool            open (QIODevice::OpenMode openmode);
+    static QList<KAutoSaveFile*>  staleFiles (const QUrl& url, const QString& applicationName = \
QString()); +    static QList<KAutoSaveFile*>  allStaleFiles (const QString& applicationName = \
QString()); +};
diff --git a/sip/kcoreaddons/kbackup.sip b/sip/kcoreaddons/kbackup.sip
new file mode 100644
index 0000000..9a57d65
--- /dev/null
+++ b/sip/kcoreaddons/kbackup.sip
@@ -0,0 +1,30 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+%ModuleHeaderCode
+#include <kbackup.h>
+%End
+
+namespace KBackup
+{
+bool                    backupFile (const QString& filename, const QString& backupDir = QString());
+bool                    simpleBackupFile (const QString& filename, const QString& backupDir = QString(), \
const QString& backupExtension = QLatin1String("~")); +bool                    numberedBackupFile (const \
QString& filename, const QString& backupDir = QString(), const QString& backupExtension = \
QString::fromLatin1("~"), const uint maxBackups = 10); +bool                    rcsBackupFile (const \
QString& filename, const QString& backupDir = QString(), const QString& backupMessage = QString()); +};
diff --git a/sip/kcoreaddons/kcompositejob.sip b/sip/kcoreaddons/kcompositejob.sip
new file mode 100644
index 0000000..3ce6ed5
--- /dev/null
+++ b/sip/kcoreaddons/kcompositejob.sip
@@ -0,0 +1,38 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+class KCompositeJob : KJob
+{
+%TypeHeaderCode
+#include <kcompositejob.h>
+%End
+
+public:
+    explicit                KCompositeJob (QObject* parent = 0);
+    virtual ~KCompositeJob ();
+protected:
+    virtual bool            addSubjob (KJob* job);
+    virtual bool            removeSubjob (KJob* job);
+    bool                    hasSubjobs () const;
+    const QList<KJob*>&     subjobs () const;
+    void                    clearSubjobs ();
+    virtual void            slotResult (KJob* job);
+    virtual void            slotInfoMessage (KJob* job, const QString& plain, const QString& rich);
+//ig                            KCompositeJob (KCompositeJobPrivate& dd, QObject* parent);
+};
diff --git a/sip/kcoreaddons/kcoreaddonsmod.sip b/sip/kcoreaddons/kcoreaddonsmod.sip
new file mode 100644
index 0000000..753c345
--- /dev/null
+++ b/sip/kcoreaddons/kcoreaddonsmod.sip
@@ -0,0 +1,49 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+%Module PyKDE5.kcoreaddons
+
+%ModuleHeaderCode
+#pragma GCC visibility push(default)
+%End
+
+%Import typedefs.sip
+%Import QtCore/QtCoremod.sip
+
+%Include kfilesystemtype_p.sip
+%Include kaboutdata.sip
+%Include kautosavefile.sip
+%Include kbackup.sip
+%Include kcompositejob.sip
+%Include kdirwatch.sip
+// FIXME doesn't compile, problem in the .h file.
+// %Include kformat.sip
+%Include kjob.sip
+%Include kjobtrackerinterface.sip
+%Include kjobuidelegate.sip
+%Include kmacroexpander.sip
+%Include kmessage.sip
+%Include kprocess.sip
+%Include krandom.sip
+%Include krandomsequence.sip
+%Include kshareddatacache.sip
+%Include kshell.sip
+%Include kstringhandler.sip
+%Include kurlmimedata.sip
+%Include kuser.sip
diff --git a/sip/kcoreaddons/kdirwatch.sip b/sip/kcoreaddons/kdirwatch.sip
new file mode 100644
index 0000000..a261890
--- /dev/null
+++ b/sip/kcoreaddons/kdirwatch.sip
@@ -0,0 +1,67 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+class KDirWatch : QObject
+{
+%TypeHeaderCode
+#include <kdirwatch.h>
+%End
+
+public:
+    enum WatchMode
+    {
+        WatchDirOnly,
+        WatchFiles,
+        WatchSubDirs
+    };
+    typedef QFlags<KDirWatch::WatchMode> WatchModes;
+                            KDirWatch (QObject* parent = 0);
+    ~KDirWatch ();
+    void                    addDir (const QString& path, KDirWatch::WatchModes watchModes = \
KDirWatch::WatchMode::WatchDirOnly); +    void                    addFile (const QString& file);
+    QDateTime               ctime (const QString& path) const;
+    void                    removeDir (const QString& path);
+    void                    removeFile (const QString& file);
+    bool                    stopDirScan (const QString& path);
+    bool                    restartDirScan (const QString& path);
+    void                    startScan (bool notify = 0, bool skippedToo = 0);
+    void                    stopScan ();
+    bool                    isStopped ();
+    bool                    contains (const QString& path) const;
+    void                    deleteQFSWatcher ();
+    static void             statistics ();
+    enum Method
+    {
+        FAM,
+        INotify,
+        DNotify,
+        Stat,
+        QFSWatch
+    };
+    KDirWatch::Method       internalMethod () const;
+    static KDirWatch*       self ();
+    static bool             exists ();
+    void                    setCreated (const QString& path);
+    void                    setDirty (const QString& path);
+    void                    setDeleted (const QString& path);
+signals:
+    void                    dirty (const QString& path);
+    void                    created (const QString& path);
+    void                    deleted (const QString& path);
+};
diff --git a/sip/kcoreaddons/kfilesystemtype_p.sip b/sip/kcoreaddons/kfilesystemtype_p.sip
new file mode 100644
index 0000000..fa655a8
--- /dev/null
+++ b/sip/kcoreaddons/kfilesystemtype_p.sip
@@ -0,0 +1,36 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+%ModuleHeaderCode
+#include <kfilesystemtype_p.h>
+%End
+
+namespace KFileSystemType
+{
+enum Type
+{
+    Unknown,
+    Nfs,
+    Smb,
+    Fat,
+    Ramfs,
+    Other
+};
+KFileSystemType::Type   fileSystemType (const QString& path);
+};
diff --git a/sip/kcoreaddons/kformat.sip b/sip/kcoreaddons/kformat.sip
new file mode 100644
index 0000000..9d8e713
--- /dev/null
+++ b/sip/kcoreaddons/kformat.sip
@@ -0,0 +1,67 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+class KFormat /NoDefaultCtors/
+{
+%TypeHeaderCode
+#include <kformat.h>
+%End
+
+public:
+    enum BinarySizeUnits
+    {
+        DefaultBinaryUnits,
+        UnitByte,
+        UnitKiloByte,
+        UnitMegaByte,
+        UnitGigaByte,
+        UnitTeraByte,
+        UnitPetaByte,
+        UnitExaByte,
+        UnitZettaByte,
+        UnitYottaByte,
+        UnitLastUnit
+    };
+    enum BinaryUnitDialect
+    {
+        DefaultBinaryDialect,
+        IECBinaryDialect,
+        JEDECBinaryDialect,
+        MetricBinaryDialect,
+        LastBinaryDialect
+    };
+    enum DurationFormatOption
+    {
+        DefaultDuration,
+        InitialDuration,
+        ShowMilliseconds,
+        HideSeconds,
+        FoldHours
+    };
+    typedef QFlags<KFormat::DurationFormatOption> DurationFormatOptions;
+    explicit                KFormat (const QLocale& locale = QLocale());
+                            KFormat (const KFormat& other);
+    ~KFormat ();
+    QString                 formatByteSize (double size, int precision = 1, KFormat::BinaryUnitDialect \
dialect = KFormat::DefaultBinaryDialect, KFormat::BinarySizeUnits units = KFormat::DefaultBinaryUnits) \
const; +    QString                 formatDuration (quint64 msecs, KFormat::DurationFormatOptions options \
= KFormat::DefaultDuration) const; +    QString                 formatDecimalDuration (quint64 msecs, int \
decimalPlaces = 2) const; +    QString                 formatSpelloutDuration (quint64 msecs) const;
+    QString                 formatRelativeDate (const QDate& date, QLocale::FormatType format) const;
+    QString                 formatRelativeDateTime (const QDateTime& dateTime, QLocale::FormatType \
format) const; +};
diff --git a/sip/kcoreaddons/kjob.sip b/sip/kcoreaddons/kjob.sip
new file mode 100644
index 0000000..c8c3c31
--- /dev/null
+++ b/sip/kcoreaddons/kjob.sip
@@ -0,0 +1,103 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+class KJob : QObject
+{
+%TypeHeaderCode
+#include <kjob.h>
+%End
+
+public:
+    enum Unit
+    {
+        Bytes,
+        Files,
+        Directories
+    };
+    enum Capability
+    {
+        NoCapabilities,
+        Killable,
+        Suspendable
+    };
+    typedef QFlags<KJob::Capability> Capabilities;
+    explicit                KJob (QObject* parent = 0);
+    virtual ~KJob ();
+    void                    setUiDelegate (KJobUiDelegate* delegate);
+    KJobUiDelegate*         uiDelegate () const;
+    KJob::Capabilities      capabilities () const;
+    bool                    isSuspended () const;
+    virtual void            start ()=0;
+    enum KillVerbosity
+    {
+        Quietly,
+        EmitResult
+    };
+    bool                    kill (KJob::KillVerbosity verbosity = KJob::KillVerbosity::Quietly);
+    bool                    suspend ();
+    bool                    resume ();
+protected:
+    virtual bool            doKill ();
+    virtual bool            doSuspend ();
+    virtual bool            doResume ();
+    void                    setCapabilities (KJob::Capabilities capabilities);
+public:
+    bool                    exec ();
+    enum
+    {
+        NoError,
+        KilledJobError,
+        UserDefinedError
+    };
+    int                     error () const;
+    QString                 errorText () const;
+    virtual QString         errorString () const;
+    qulonglong              processedAmount (KJob::Unit unit) const;
+    qulonglong              totalAmount (KJob::Unit unit) const;
+    unsigned long           percent () const;
+    void                    setAutoDelete (bool autodelete);
+    bool                    isAutoDelete () const;
+signals:
+//ig    void                    finished (KJob* job, QPrivateSignal);
+//ig    void                    suspended (KJob* job, QPrivateSignal);
+//ig    void                    resumed (KJob* job, QPrivateSignal);
+//ig    void                    result (KJob* job, QPrivateSignal);
+
+//force
+    void                    finished (KJob* job);
+    void                    suspended (KJob* job);
+    void                    resumed (KJob* job);
+    void                    result (KJob* job);
+//end
+
+// FIXME
+//ig    void                    description (KJob* job, const QString& title, const \
QPair<QString,QString>& field1 = qMakePair(QString(),QString()), const QPair<QString,QString>& field2 = \
qMakePair(QString(),QString())); +    void                    infoMessage (KJob* job, const QString& \
plain, const QString& rich = QString()); +    void                    warning (KJob* job, const QString& \
plain, const QString& rich = QString()); +protected:
+    void                    setError (int errorCode);
+    void                    setErrorText (const QString& errorText);
+    void                    setProcessedAmount (KJob::Unit unit, qulonglong amount);
+    void                    setTotalAmount (KJob::Unit unit, qulonglong amount);
+    void                    setPercent (unsigned long percentage);
+    void                    emitResult ();
+    void                    emitPercent (qulonglong processedAmount, qulonglong totalAmount);
+    void                    emitSpeed (unsigned long speed);
+//ig                            KJob (KJobPrivate& dd, QObject* parent);
+};
diff --git a/sip/kcoreaddons/kjobtrackerinterface.sip b/sip/kcoreaddons/kjobtrackerinterface.sip
new file mode 100644
index 0000000..07284ef
--- /dev/null
+++ b/sip/kcoreaddons/kjobtrackerinterface.sip
@@ -0,0 +1,43 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+class KJobTrackerInterface : QObject
+{
+%TypeHeaderCode
+#include <kjobtrackerinterface.h>
+%End
+
+public:
+                            KJobTrackerInterface (QObject* parent = 0);
+    virtual ~KJobTrackerInterface ();
+    virtual void            registerJob (KJob* job);
+    virtual void            unregisterJob (KJob* job);
+protected:
+    virtual void            finished (KJob* job);
+    virtual void            suspended (KJob* job);
+    virtual void            resumed (KJob* job);
+// FIXME
+//ig    virtual void            description (KJob* job, const QString& title, const \
QPair<QString,QString>& field1, const QPair<QString,QString>& field2); +    virtual void            \
infoMessage (KJob* job, const QString& plain, const QString& rich); +    virtual void            warning \
(KJob* job, const QString& plain, const QString& rich); +    virtual void            totalAmount (KJob* \
job, KJob::Unit unit, qulonglong amount); +    virtual void            processedAmount (KJob* job, \
KJob::Unit unit, qulonglong amount); +    virtual void            percent (KJob* job, unsigned long \
percent); +    virtual void            speed (KJob* job, unsigned long value);
+};
diff --git a/sip/kcoreaddons/kjobuidelegate.sip b/sip/kcoreaddons/kjobuidelegate.sip
new file mode 100644
index 0000000..82107ba
--- /dev/null
+++ b/sip/kcoreaddons/kjobuidelegate.sip
@@ -0,0 +1,40 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+class KJobUiDelegate : QObject
+{
+%TypeHeaderCode
+#include <kjobuidelegate.h>
+%End
+
+public:
+                            KJobUiDelegate ();
+    virtual ~KJobUiDelegate ();
+protected:
+    virtual bool            setJob (KJob* job);
+    KJob*                   job () const;
+public:
+    virtual void            showErrorMessage ();
+    void                    setAutoErrorHandlingEnabled (bool enable);
+    bool                    isAutoErrorHandlingEnabled () const;
+    void                    setAutoWarningHandlingEnabled (bool enable);
+    bool                    isAutoWarningHandlingEnabled () const;
+protected:
+    virtual void            slotWarning (KJob* job, const QString& plain, const QString& rich);
+};
diff --git a/sip/kcoreaddons/kmacroexpander.sip b/sip/kcoreaddons/kmacroexpander.sip
new file mode 100644
index 0000000..a27f9d5
--- /dev/null
+++ b/sip/kcoreaddons/kmacroexpander.sip
@@ -0,0 +1,87 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+class KMacroExpanderBase /NoDefaultCtors/
+{
+%TypeHeaderCode
+#include <kmacroexpander.h>
+%End
+
+public:
+    explicit                KMacroExpanderBase (QChar c = QLatin1Char('%'));
+    virtual ~KMacroExpanderBase ();
+    void                    expandMacros (QString& str);
+    bool                    expandMacrosShellQuote (QString& str, int& pos);
+//ig    bool                    expandMacrosShellQuote (QString& str);
+    void                    setEscapeChar (QChar c);
+    QChar                   escapeChar () const;
+protected:
+    virtual int             expandPlainMacro (const QString& str, int pos, QStringList& ret);
+    virtual int             expandEscapedMacro (const QString& str, int pos, QStringList& ret);
+%ConvertToSubClassCode
+    // CTSCC for subclasses of 'KMacroExpanderBase'
+    sipType = NULL;
+
+    if (dynamic_cast<KCharMacroExpander*>(sipCpp))
+        sipType = sipType_KCharMacroExpander;
+    else if (dynamic_cast<KWordMacroExpander*>(sipCpp))
+        sipType = sipType_KWordMacroExpander;
+%End
+};
+class KWordMacroExpander : KMacroExpanderBase
+{
+%TypeHeaderCode
+#include <kmacroexpander.h>
+%End
+
+public:
+    explicit                KWordMacroExpander (QChar c = QLatin1Char('%'));
+protected:
+    virtual int             expandPlainMacro (const QString& str, int pos, QStringList& ret);
+    virtual int             expandEscapedMacro (const QString& str, int pos, QStringList& ret);
+    virtual bool            expandMacro (const QString& str, QStringList& ret)=0;
+};
+class KCharMacroExpander : KMacroExpanderBase
+{
+%TypeHeaderCode
+#include <kmacroexpander.h>
+%End
+
+public:
+    explicit                KCharMacroExpander (QChar c = QLatin1Char('%'));
+protected:
+    virtual int             expandPlainMacro (const QString& str, int pos, QStringList& ret);
+    virtual int             expandEscapedMacro (const QString& str, int pos, QStringList& ret);
+    virtual bool            expandMacro (QChar chr, QStringList& ret)=0;
+};
+namespace KMacroExpander
+{
+QString                 expandMacros (const QString& str, const QHash<QChar,QString>& map, QChar c = \
QLatin1Char('%')); +//ig QString                 expandMacrosShellQuote (const QString& str, const \
QHash<QChar,QString>& map, QChar c = QLatin1Char('%')); +QString                 expandMacros (const \
QString& str, const QHash<QString,QString>& map, QChar c = QLatin1Char('%')); +//ig QString               \
expandMacrosShellQuote (const QString& str, const QHash<QString,QString>& map, QChar c = \
QLatin1Char('%')); +QString                 expandMacros (const QString& str, const \
QHash<QChar,QStringList>& map, QChar c = QLatin1Char('%')); +QString                 expandMacros (const \
QString& str, const QHash<QString,QStringList>& map, QChar c = QLatin1Char('%')); +//ig QString           \
expandMacrosShellQuote (const QString& str, const QHash<QChar,QStringList>& map, QChar c = \
QLatin1Char('%')); +QString                 expandMacrosShellQuote (const QString& str, const \
QHash<QString,QStringList>& map, QChar c = QLatin1Char('%')); +};
+%ModuleHeaderCode
+//ctscc
+#include <kmacroexpander.h>
+%End
diff --git a/sip/kcoreaddons/kmessage.sip b/sip/kcoreaddons/kmessage.sip
new file mode 100644
index 0000000..5ccfafb
--- /dev/null
+++ b/sip/kcoreaddons/kmessage.sip
@@ -0,0 +1,42 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+%ModuleHeaderCode
+#include <kmessage.h>
+%End
+namespace KMessage
+{
+enum MessageType
+{
+    Error,
+    Information,
+    Warning,
+    Sorry,
+    Fatal
+};
+void                    message (KMessage::MessageType messageType, const QString& text, const QString& \
caption = QString()); +void                    setMessageHandler (KMessageHandler* handler);
+};
+class KMessageHandler
+{
+
+public:
+    virtual ~KMessageHandler ();
+    virtual void            message (KMessage::MessageType type, const QString& text, const QString& \
caption)=0; +};
diff --git a/sip/kcoreaddons/kprocess.sip b/sip/kcoreaddons/kprocess.sip
new file mode 100644
index 0000000..d9ec15d
--- /dev/null
+++ b/sip/kcoreaddons/kprocess.sip
@@ -0,0 +1,60 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+class KProcess : QProcess
+{
+%TypeHeaderCode
+#include <kprocess.h>
+%End
+
+public:
+    enum OutputChannelMode
+    {
+        SeparateChannels,
+        MergedChannels,
+        ForwardedChannels,
+        OnlyStdoutChannel,
+        OnlyStderrChannel
+    };
+    explicit                KProcess (QObject* parent = 0);
+    virtual ~KProcess ();
+    void                    setOutputChannelMode (KProcess::OutputChannelMode mode);
+    KProcess::OutputChannelMode  outputChannelMode () const;
+    void                    setNextOpenMode (QIODevice::OpenMode mode);
+    void                    setEnv (const QString& name, const QString& value, bool overwrite = 1);
+    void                    unsetEnv (const QString& name);
+    void                    clearEnvironment ();
+    void                    setProgram (const QString& exe, const QStringList& args = QStringList());
+    void                    setProgram (const QStringList& argv);
+    KProcess&               operator<< (const QString& arg);
+    KProcess&               operator<< (const QStringList& args);
+    void                    clearProgram ();
+    void                    setShellCommand (const QString& cmd);
+    QStringList             program () const;
+    void                    start ();
+    int                     execute (int msecs = -1);
+    static int              execute (const QString& exe, const QStringList& args = QStringList(), int \
msecs = -1); +    static int              execute (const QStringList& argv, int msecs = -1);
+    int                     startDetached ();
+    static int              startDetached (const QString& exe, const QStringList& args = QStringList());
+    static int              startDetached (const QStringList& argv);
+    int                     pid () const;
+protected:
+//ig                            KProcess (KProcessPrivate* d, QObject* parent);
+};
diff --git a/sip/kcoreaddons/krandom.sip b/sip/kcoreaddons/krandom.sip
new file mode 100644
index 0000000..7fafdc4
--- /dev/null
+++ b/sip/kcoreaddons/krandom.sip
@@ -0,0 +1,28 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+%ModuleHeaderCode
+#include <krandom.h>
+%End
+
+namespace KRandom
+{
+int                     random ();
+QString                 randomString (int length);
+};
diff --git a/sip/kcoreaddons/krandomsequence.sip b/sip/kcoreaddons/krandomsequence.sip
new file mode 100644
index 0000000..37209a1
--- /dev/null
+++ b/sip/kcoreaddons/krandomsequence.sip
@@ -0,0 +1,36 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+class KRandomSequence
+{
+%TypeHeaderCode
+#include <krandomsequence.h>
+%End
+
+public:
+    explicit                KRandomSequence (long lngSeed = 0);
+    virtual ~KRandomSequence ();
+                            KRandomSequence (const KRandomSequence& a);
+//ig    KRandomSequence&        operator= (const KRandomSequence& a);
+    void                    setSeed (long lngSeed = 0);
+    double                  getDouble ();
+    unsigned long           getLong (unsigned long max);
+    bool                    getBool ();
+    void                    modulate (int i);
+};
diff --git a/sip/kcoreaddons/kshareddatacache.sip b/sip/kcoreaddons/kshareddatacache.sip
new file mode 100644
index 0000000..201f215
--- /dev/null
+++ b/sip/kcoreaddons/kshareddatacache.sip
@@ -0,0 +1,47 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+class KSharedDataCache
+{
+%TypeHeaderCode
+#include <kshareddatacache.h>
+%End
+
+public:
+                            KSharedDataCache (const QString& cacheName, unsigned defaultCacheSize, \
unsigned expectedItemSize = 0); +    ~KSharedDataCache ();
+    enum EvictionPolicy
+    {
+        NoEvictionPreference,
+        EvictLeastRecentlyUsed,
+        EvictLeastOftenUsed,
+        EvictOldest
+    };
+    KSharedDataCache::EvictionPolicy  evictionPolicy () const;
+    void                    setEvictionPolicy (KSharedDataCache::EvictionPolicy newPolicy);
+    bool                    insert (const QString& key, const QByteArray& data);
+    bool                    find (const QString& key, QByteArray* destination) const;
+    void                    clear ();
+    static void             deleteCache (const QString& cacheName);
+    bool                    contains (const QString& key) const;
+    unsigned                totalSize () const;
+    unsigned                freeSize () const;
+    unsigned                timestamp () const;
+    void                    setTimestamp (unsigned newTimestamp);
+};
diff --git a/sip/kcoreaddons/kshell.sip b/sip/kcoreaddons/kshell.sip
new file mode 100644
index 0000000..eb447b6
--- /dev/null
+++ b/sip/kcoreaddons/kshell.sip
@@ -0,0 +1,43 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+%ModuleHeaderCode
+#include <kshell.h>
+%End
+
+namespace KShell
+{
+enum Option
+{
+    NoOptions,
+    TildeExpand,
+    AbortOnMeta
+};
+typedef QFlags<KShell::Option> Options;
+enum Errors
+{
+    NoError,
+    BadQuoting,
+    FoundMeta
+};
+QStringList             splitArgs (const QString& cmd, KShell::Options flags = \
KShell::Option::NoOptions, KShell::Errors* err = 0); +QString                 joinArgs (const \
QStringList& args); +QString                 quoteArg (const QString& arg);
+QString                 tildeExpand (const QString& path);
+};
diff --git a/sip/kcoreaddons/kstringhandler.sip b/sip/kcoreaddons/kstringhandler.sip
new file mode 100644
index 0000000..a991478
--- /dev/null
+++ b/sip/kcoreaddons/kstringhandler.sip
@@ -0,0 +1,38 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+%ModuleHeaderCode
+#include <kstringhandler.h>
+%End
+namespace KStringHandler
+{
+QString                 capwords (const QString& text);
+QStringList             capwords (const QStringList& list);
+QString                 lsqueeze (const QString& str, int maxlen = 40);
+QString                 csqueeze (const QString& str, int maxlen = 40);
+QString                 rsqueeze (const QString& str, int maxlen = 40);
+QStringList             perlSplit (const QString& sep, const QString& s, int max = 0);
+QStringList             perlSplit (const QChar& sep, const QString& s, int max = 0);
+QStringList             perlSplit (const QRegExp& sep, const QString& s, int max = 0);
+QString                 tagUrls (const QString& text);
+QString                 obscure (const QString& str);
+bool                    isUtf8 (const char* str);
+QString                 from8Bit (const char* str);
+QString                 preProcessWrap (const QString& text);
+};
diff --git a/sip/kcoreaddons/kurlmimedata.sip b/sip/kcoreaddons/kurlmimedata.sip
new file mode 100644
index 0000000..47ca787
--- /dev/null
+++ b/sip/kcoreaddons/kurlmimedata.sip
@@ -0,0 +1,35 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+%ModuleHeaderCode
+#include <kurlmimedata.h>
+%End
+namespace KUrlMimeData
+{
+typedef QMap<QString,QString> MetaDataMap;
+void                    setUrls (const QList<QUrl>& urls, const QList<QUrl>& mostLocalUrls, QMimeData* \
mimeData); +void                    setMetaData (const KUrlMimeData::MetaDataMap& metaData, QMimeData* \
mimeData); +QStringList             mimeDataTypes ();
+enum DecodeOptions
+{
+    PreferLocalUrls,
+    PreferKdeUrls
+};
+QList<QUrl>             urlsFromMimeData (const QMimeData* mimeData, KUrlMimeData::DecodeOptions \
decodeOptions = KUrlMimeData::DecodeOptions::PreferKdeUrls, KUrlMimeData::MetaDataMap* metaData = 0); +};
diff --git a/sip/kcoreaddons/kuser.sip b/sip/kcoreaddons/kuser.sip
new file mode 100644
index 0000000..430343b
--- /dev/null
+++ b/sip/kcoreaddons/kuser.sip
@@ -0,0 +1,89 @@
+// Copyright 2014 Simon Edwards <simon@simonzone.com>
+
+//                 Generated by twine2
+
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as
+// published by the Free Software Foundation; either version 2, or
+// (at your option) any later version.
+
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details
+
+// You should have received a copy of the GNU Library General Public
+// License along with this program; if not, write to the
+// Free Software Foundation, Inc.,
+// 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+
+typedef uid_t K_UID;
+typedef gid_t K_GID;
+class KUser
+{
+%TypeHeaderCode
+#include <kuser.h>
+%End
+
+public:
+    enum UIDMode
+    {
+        UseEffectiveUID,
+        UseRealUserID
+    };
+    explicit                KUser (KUser::UIDMode mode = KUser::UIDMode::UseEffectiveUID);
+    explicit                KUser (K_UID uid);
+    explicit                KUser (const QString& name);
+    explicit                KUser (const char* name);
+//ig    explicit                KUser (const passwd* p);
+                            KUser (const KUser& user);
+//ig    KUser&                  operator= (const KUser& user);
+    bool                    operator== (const KUser& user) const;
+    bool                    operator!= (const KUser& user) const;
+    bool                    isValid () const;
+    K_UID                   uid () const;
+    K_GID                   gid () const;
+    bool                    isSuperUser () const;
+    QString                 loginName () const;
+    QString                 homeDir () const;
+    QString                 faceIconPath () const;
+    QString                 shell () const;
+    QList<KUserGroup>       groups () const;
+    QStringList             groupNames () const;
+    enum UserProperty
+    {
+        FullName,
+        RoomNumber,
+        WorkPhone,
+        HomePhone
+    };
+    QVariant                property (KUser::UserProperty which) const;
+    ~KUser ();
+    static QList<KUser>     allUsers ();
+    static QStringList      allUserNames ();
+};
+class KUserGroup
+{
+%TypeHeaderCode
+#include <kuser.h>
+%End
+
+public:
+    explicit                KUserGroup (const QString& name);
+    explicit                KUserGroup (const char* name);
+    explicit                KUserGroup (KUser::UIDMode mode = KUser::UseEffectiveUID);
+    explicit                KUserGroup (K_GID gid);
+//ig    explicit                KUserGroup (const group* g);
+                            KUserGroup (const KUserGroup& group);
+//ig    KUserGroup&             operator= (const KUserGroup& group);
+    bool                    operator== (const KUserGroup& group) const;
+    bool                    operator!= (const KUserGroup& group) const;
+    bool                    isValid () const;
+    K_GID                   gid () const;
+    QString                 name () const;
+    QList<KUser>            users () const;
+    QStringList             userNames () const;
+    ~KUserGroup ();
+    static QList<KUserGroup>  allGroups ();
+    static QStringList      allGroupNames ();
+};


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic