[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: [pykde5] /: * Added kwidgetsaddons.
From: Simon Edwards <simon () simonzone ! com>
Date: 2014-07-03 19:52:46
Message-ID: E1X2n3m-0000r4-AX () scm ! kde ! org
[Download RAW message or body]
Git commit 509902841f58145be3361b2ecf426fbe1f3a9347 by Simon Edwards.
Committed on 03/07/2014 at 19:52.
Pushed by sedwards into branch 'master'.
* Added kwidgetsaddons.
* Some API updates.
M +8 -3 CMakeLists.txt
M +0 -1 sip/kcoreaddons/kcoreaddonsmod.sip
C +9 -14 sip/kwidgetsaddons/kacceleratormanager.sip [from: sip/kcoreaddons/kfilesystemtype_p.sip - \
067% similarity] A +41 -0 sip/kwidgetsaddons/kactionmenu.sip
A +73 -0 sip/kwidgetsaddons/kactionselector.sip
C +11 -14 sip/kwidgetsaddons/kanimatedbutton.sip [from: sip/kcoreaddons/kfilesystemtype_p.sip - 068% \
similarity] A +41 -0 sip/kwidgetsaddons/kassistantdialog.sip
A +52 -0 sip/kwidgetsaddons/kcapacitybar.sip
A +53 -0 sip/kwidgetsaddons/kcharselect.sip
A +48 -0 sip/kwidgetsaddons/kcolorbutton.sip
C +15 -17 sip/kwidgetsaddons/kcolorcombo.sip [from: sip/solid/networkshare.sip - 056% similarity]
C +11 -14 sip/kwidgetsaddons/kcursor.sip [from: sip/kcoreaddons/kfilesystemtype_p.sip - 068% \
similarity] A +72 -0 sip/kwidgetsaddons/kdatecombobox.sip
A +60 -0 sip/kwidgetsaddons/kdatepicker.sip
A +109 -0 sip/kwidgetsaddons/kdatetimeedit.sip
C +11 -17 sip/kwidgetsaddons/kdragwidgetdecorator.sip [from: sip/solid/networkshare.sip - 062% \
similarity] A +54 -0 sip/kwidgetsaddons/kdualaction.sip
A +79 -0 sip/kwidgetsaddons/keditlistwidget.sip
C +10 -17 sip/kwidgetsaddons/kfontaction.sip [from: sip/solid/networkshare.sip - 059% similarity]
A +77 -0 sip/kwidgetsaddons/kfontchooser.sip
C +15 -17 sip/kwidgetsaddons/kfontrequester.sip [from: sip/solid/networkshare.sip - 054% similarity]
C +12 -17 sip/kwidgetsaddons/kfontsizeaction.sip [from: sip/solid/networkshare.sip - 059% \
similarity] A +48 -0 sip/kwidgetsaddons/kguiitem.sip
A +66 -0 sip/kwidgetsaddons/kled.sip
A +107 -0 sip/kwidgetsaddons/kmessagebox.sip
C +0 -17 sip/kwidgetsaddons/kmessageboxdontaskagaininterface.sip [from: \
sip/kcoreaddons/kfilesystemtype_p.sip - 078% similarity] C +0 -17 \
sip/kwidgetsaddons/kmessageboxnotifyinterface.sip [from: sip/kcoreaddons/kfilesystemtype_p.sip - 078% \
similarity] A +65 -0 sip/kwidgetsaddons/kmessagewidget.sip
A +49 -0 sip/kwidgetsaddons/kmimetypechooser.sip
A +96 -0 sip/kwidgetsaddons/kmultitabbar.sip
A +50 -0 sip/kwidgetsaddons/knewpassworddialog.sip
A +61 -0 sip/kwidgetsaddons/kpagedialog.sip
C +14 -14 sip/kwidgetsaddons/kpagemodel.sip [from: sip/kcoreaddons/kfilesystemtype_p.sip - 070% \
similarity] A +53 -0 sip/kwidgetsaddons/kpageview.sip
A +44 -0 sip/kwidgetsaddons/kpagewidget.sip
A +74 -0 sip/kwidgetsaddons/kpagewidgetmodel.sip
A +73 -0 sip/kwidgetsaddons/kpassworddialog.sip
C +10 -17 sip/kwidgetsaddons/kpixmapregionselectordialog.sip [from: sip/solid/networkshare.sip - \
051% similarity] A +52 -0 sip/kwidgetsaddons/kpixmapregionselectorwidget.sip
C +13 -17 sip/kwidgetsaddons/kpixmapsequence.sip [from: sip/solid/networkshare.sip - 054% \
similarity] A +43 -0 sip/kwidgetsaddons/kpixmapsequenceoverlaypainter.sip
C +10 -17 sip/kwidgetsaddons/kpixmapsequencewidget.sip [from: sip/solid/networkshare.sip - 061% \
similarity] C +15 -17 sip/kwidgetsaddons/kpopupframe.sip [from: sip/solid/networkshare.sip - 057% \
similarity] A +49 -0 sip/kwidgetsaddons/kratingpainter.sip
A +56 -0 sip/kwidgetsaddons/kratingwidget.sip
A +82 -0 sip/kwidgetsaddons/kruler.sip
A +79 -0 sip/kwidgetsaddons/kselectaction.sip
A +69 -0 sip/kwidgetsaddons/kselector.sip
C +9 -14 sip/kwidgetsaddons/kseparator.sip [from: sip/kcoreaddons/kfilesystemtype_p.sip - 067% \
similarity] A +43 -0 sip/kwidgetsaddons/ksqueezedtextlabel.sip
A +104 -0 sip/kwidgetsaddons/kstandardguiitem.sip
A +73 -0 sip/kwidgetsaddons/ktimecombobox.sip
A +59 -0 sip/kwidgetsaddons/ktitlewidget.sip
C +9 -17 sip/kwidgetsaddons/ktoggleaction.sip [from: sip/solid/networkshare.sip - 064% similarity]
C +9 -17 sip/kwidgetsaddons/ktogglefullscreenaction.sip [from: sip/solid/networkshare.sip - 063% \
similarity] C +13 -17 sip/kwidgetsaddons/ktoolbarlabelaction.sip [from: sip/solid/networkshare.sip - \
055% similarity] C +9 -17 sip/kwidgetsaddons/ktoolbarpopupaction.sip [from: \
sip/solid/networkshare.sip - 063% similarity] C +8 -14 sip/kwidgetsaddons/ktoolbarspaceraction.sip \
[from: sip/kcoreaddons/kfilesystemtype_p.sip - 075% similarity] A +66 -0 \
sip/kwidgetsaddons/kurllabel.sip C +10 -17 sip/kwidgetsaddons/kviewstatemaintainerbase.sip [from: \
sip/solid/networkshare.sip - 061% similarity] A +45 -0 sip/kwidgetsaddons/kviewstateserializer.sip
A +90 -0 sip/kwidgetsaddons/kwidgetsaddonsmod.sip
A +48 -0 sip/kwidgetsaddons/kxyselector.sip
R +8 -14 sip/kwidgetsaddons/lineediturldropeventfilter.sip [from: \
sip/kcoreaddons/kfilesystemtype_p.sip - 073% similarity] M +18 -3 sip/solid/battery.sip
M +1 -1 sip/solid/device.sip
M +0 -11 sip/solid/deviceinterface.sip
M +1 -2 sip/solid/networkshare.sip
M +5 -5 sip/solid/predicate.sip
M +20 -13 sip/solid/solidmod.sip
http://commits.kde.org/pykde5/509902841f58145be3361b2ecf426fbe1f3a9347
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 77be745..77cc2e6 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 CoreAddons Sonnet \
GuiAddons) +find_package(KF5 CONFIG REQUIRED Auth ItemModels ItemViews Archive Plotting Solid CoreAddons \
Sonnet GuiAddons WidgetsAddons)
#option(PYKDEUIC4_ALTINSTALL "Enable parallel-installation of the PyKDE4 tools" FALSE)
@@ -96,7 +96,7 @@ include_directories(
${qt5core_include}
${qt5gui_include}
${qt5widgets_include}
- ${solid_include}/solid
+ ${solid_include}/Solid/solid
${kf5sonnetcore_include}/SonnetCore/sonnet
${kf5sonnetcore_include}/SonnetUi/sonnet
)
@@ -152,7 +152,12 @@ file(GLOB kguiaddons_files_sip sip/kguiaddons/*.sip)
set(SIP_EXTRA_FILES_DEPEND ${kguiaddons_files_sip})
add_sip_python_module(PyKDE5.kguiaddons sip/kguiaddons/kguiaddonsmod.sip KF5::GuiAddons)
-set(PYKDE_MODULES "kitemmodels kitemviews karchive kplotting solid kcoreaddons sonnet kguiaddons")
+# kwidgetsaddons
+file(GLOB kwidgetsaddons_files_sip sip/kwidgetsaddons/*.sip)
+set(SIP_EXTRA_FILES_DEPEND ${kwidgetsaddons_files_sip})
+add_sip_python_module(PyKDE5.kwidgetsaddons sip/kwidgetsaddons/kwidgetsaddonsmod.sip KF5::WidgetsAddons)
+
+set(PYKDE_MODULES "kitemmodels kitemviews karchive kplotting solid kcoreaddons sonnet kguiaddons \
kwidgetsaddons")
###############################################################################
diff --git a/sip/kcoreaddons/kcoreaddonsmod.sip b/sip/kcoreaddons/kcoreaddonsmod.sip
index bffc3c4..64f821f 100644
--- a/sip/kcoreaddons/kcoreaddonsmod.sip
+++ b/sip/kcoreaddons/kcoreaddonsmod.sip
@@ -33,7 +33,6 @@
%Include kdelibs4migration.sip
%Include kdirwatch.sip
%Include kexportplugin.sip
-%Include kfilesystemtype_p.sip
%Include kformat.sip
%Include kjob.sip
%Include kjobtrackerinterface.sip
diff --git a/sip/kcoreaddons/kfilesystemtype_p.sip b/sip/kwidgetsaddons/kacceleratormanager.sip
similarity index 67%
copy from sip/kcoreaddons/kfilesystemtype_p.sip
copy to sip/kwidgetsaddons/kacceleratormanager.sip
index fa655a8..4700251 100644
--- a/sip/kcoreaddons/kfilesystemtype_p.sip
+++ b/sip/kwidgetsaddons/kacceleratormanager.sip
@@ -17,20 +17,15 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-%ModuleHeaderCode
-#include <kfilesystemtype_p.h>
+class KAcceleratorManager
+{
+%TypeHeaderCode
+#include <kacceleratormanager.h>
%End
-namespace KFileSystemType
-{
-enum Type
-{
- Unknown,
- Nfs,
- Smb,
- Fat,
- Ramfs,
- Other
-};
-KFileSystemType::Type fileSystemType (const QString& path);
+public:
+ static void manage (QWidget* widget, bool programmers_mode = 0);
+ static void last_manage (QString& added, QString& changed, QString& removed);
+ static void setNoAccel (QWidget* widget);
+ static void addStandardActionNames (const QStringList& names);
};
diff --git a/sip/kwidgetsaddons/kactionmenu.sip b/sip/kwidgetsaddons/kactionmenu.sip
new file mode 100644
index 0000000..6cb1bb1
--- /dev/null
+++ b/sip/kwidgetsaddons/kactionmenu.sip
@@ -0,0 +1,41 @@
+// 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 KActionMenu : QWidgetAction
+{
+%TypeHeaderCode
+#include <kactionmenu.h>
+%End
+
+public:
+ explicit KActionMenu (QObject* parent);
+ KActionMenu (const QString& text, QObject* parent);
+ KActionMenu (const QIcon& icon, const QString& text, QObject* parent);
+ virtual ~KActionMenu ();
+ void addAction (QAction* action);
+ QAction* addSeparator ();
+ void insertAction (QAction* before, QAction* action);
+ QAction* insertSeparator (QAction* before);
+ void removeAction (QAction* action);
+ bool delayed () const;
+ void setDelayed (bool delayed);
+ bool stickyMenu () const;
+ void setStickyMenu (bool sticky);
+ virtual QWidget* createWidget (QWidget* parent);
+};
diff --git a/sip/kwidgetsaddons/kactionselector.sip b/sip/kwidgetsaddons/kactionselector.sip
new file mode 100644
index 0000000..dff29f5
--- /dev/null
+++ b/sip/kwidgetsaddons/kactionselector.sip
@@ -0,0 +1,73 @@
+// 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 KActionSelector : QWidget
+{
+%TypeHeaderCode
+#include <kactionselector.h>
+%End
+
+public:
+ explicit KActionSelector (QWidget* parent = 0);
+ ~KActionSelector ();
+ QListWidget* availableListWidget () const;
+ QListWidget* selectedListWidget () const;
+ enum MoveButton
+ {
+ ButtonAdd,
+ ButtonRemove,
+ ButtonUp,
+ ButtonDown
+ };
+ enum InsertionPolicy
+ {
+ BelowCurrent,
+ Sorted,
+ AtTop,
+ AtBottom
+ };
+ bool moveOnDoubleClick () const;
+ void setMoveOnDoubleClick (bool enable);
+ bool keyboardEnabled () const;
+ void setKeyboardEnabled (bool enable);
+ QString availableLabel () const;
+ void setAvailableLabel (const QString& text);
+ QString selectedLabel () const;
+ void setSelectedLabel (const QString& text);
+ KActionSelector::InsertionPolicy availableInsertionPolicy () const;
+ void setAvailableInsertionPolicy (KActionSelector::InsertionPolicy policy);
+ KActionSelector::InsertionPolicy selectedInsertionPolicy () const;
+ void setSelectedInsertionPolicy (KActionSelector::InsertionPolicy policy);
+ bool showUpDownButtons () const;
+ void setShowUpDownButtons (bool show);
+ void setButtonIcon (const QString& icon, KActionSelector::MoveButton button);
+ void setButtonIconSet (const QIcon& iconset, KActionSelector::MoveButton button);
+ void setButtonTooltip (const QString& tip, KActionSelector::MoveButton button);
+ void setButtonWhatsThis (const QString& text, KActionSelector::MoveButton \
button); +signals:
+ void added (QListWidgetItem* item);
+ void removed (QListWidgetItem* item);
+ void movedUp (QListWidgetItem* item);
+ void movedDown (QListWidgetItem* item);
+public:
+ void setButtonsEnabled ();
+protected:
+ void keyPressEvent (QKeyEvent*);
+ bool eventFilter (QObject*, QEvent*);
+};
diff --git a/sip/kcoreaddons/kfilesystemtype_p.sip b/sip/kwidgetsaddons/kanimatedbutton.sip
similarity index 68%
copy from sip/kcoreaddons/kfilesystemtype_p.sip
copy to sip/kwidgetsaddons/kanimatedbutton.sip
index fa655a8..f7f043d 100644
--- a/sip/kcoreaddons/kfilesystemtype_p.sip
+++ b/sip/kwidgetsaddons/kanimatedbutton.sip
@@ -17,20 +17,17 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-%ModuleHeaderCode
-#include <kfilesystemtype_p.h>
+class KAnimatedButton : QToolButton
+{
+%TypeHeaderCode
+#include <kanimatedbutton.h>
%End
-namespace KFileSystemType
-{
-enum Type
-{
- Unknown,
- Nfs,
- Smb,
- Fat,
- Ramfs,
- Other
-};
-KFileSystemType::Type fileSystemType (const QString& path);
+public:
+ explicit KAnimatedButton (QWidget* parent = 0);
+ virtual ~KAnimatedButton ();
+ QString animationPath () const;
+ void setAnimationPath (const QString& path);
+ void start ();
+ void stop ();
};
diff --git a/sip/kwidgetsaddons/kassistantdialog.sip b/sip/kwidgetsaddons/kassistantdialog.sip
new file mode 100644
index 0000000..3d17bfe
--- /dev/null
+++ b/sip/kwidgetsaddons/kassistantdialog.sip
@@ -0,0 +1,41 @@
+// 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 KAssistantDialog : KPageDialog
+{
+%TypeHeaderCode
+#include <kassistantdialog.h>
+%End
+
+public:
+ explicit KAssistantDialog (QWidget* parent = 0, Qt::WindowFlags flags = 0);
+ virtual ~KAssistantDialog ();
+ void setValid (KPageWidgetItem* page, bool enable);
+ bool isValid (KPageWidgetItem* page) const;
+ void setAppropriate (KPageWidgetItem* page, bool appropriate);
+ bool isAppropriate (KPageWidgetItem* page) const;
+ QPushButton* nextButton () const;
+ QPushButton* backButton () const;
+ QPushButton* finishButton () const;
+ virtual void back ();
+ virtual void next ();
+protected:
+ explicit KAssistantDialog (KPageWidget* widget, QWidget* parent = 0, Qt::WindowFlags \
flags = 0); + virtual void showEvent (QShowEvent* event);
+};
diff --git a/sip/kwidgetsaddons/kcapacitybar.sip b/sip/kwidgetsaddons/kcapacitybar.sip
new file mode 100644
index 0000000..57607ba
--- /dev/null
+++ b/sip/kwidgetsaddons/kcapacitybar.sip
@@ -0,0 +1,52 @@
+// 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 KCapacityBar : QWidget
+{
+%TypeHeaderCode
+#include <kcapacitybar.h>
+%End
+
+public:
+ enum DrawTextMode
+ {
+ DrawTextInline,
+ DrawTextOutline
+ };
+ explicit KCapacityBar (KCapacityBar::DrawTextMode drawTextMode = \
KCapacityBar::DrawTextMode::DrawTextOutline, QWidget* parent = 0); + ~KCapacityBar ();
+ void setValue (int value);
+ int value () const;
+ void setText (const QString& text);
+ QString text () const;
+ void setFillFullBlocks (bool fillFullBlocks);
+ bool fillFullBlocks () const;
+ void setContinuous (bool continuous);
+ bool continuous () const;
+ void setBarHeight (int barHeight);
+ int barHeight () const;
+ void setHorizontalTextAlignment (Qt::Alignment textAlignment);
+ Qt::Alignment horizontalTextAlignment () const;
+ void setDrawTextMode (KCapacityBar::DrawTextMode mode);
+ KCapacityBar::DrawTextMode drawTextMode () const;
+ void drawCapacityBar (QPainter* p, const QRect& rect) const;
+ virtual QSize minimumSizeHint () const;
+protected:
+ virtual void paintEvent (QPaintEvent* event);
+};
diff --git a/sip/kwidgetsaddons/kcharselect.sip b/sip/kwidgetsaddons/kcharselect.sip
new file mode 100644
index 0000000..6ee9203
--- /dev/null
+++ b/sip/kwidgetsaddons/kcharselect.sip
@@ -0,0 +1,53 @@
+// 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 KCharSelect : QWidget
+{
+%TypeHeaderCode
+#include <kcharselect.h>
+%End
+
+public:
+ enum Control
+ {
+ SearchLine,
+ FontCombo,
+ FontSize,
+ BlockCombos,
+ CharacterTable,
+ DetailBrowser,
+ HistoryButtons,
+ AllGuiElements
+ };
+ typedef QFlags<KCharSelect::Control> Controls;
+ explicit KCharSelect (QWidget* parent, const KCharSelect::Controls controls = \
KCharSelect::Control::AllGuiElements); + explicit KCharSelect (QWidget* parent, \
QObject* actionParent, const KCharSelect::Controls controls = KCharSelect::Control::AllGuiElements); + \
~KCharSelect (); + virtual QSize sizeHint () const;
+ QChar currentChar () const;
+ QFont currentFont () const;
+ QList<QChar> displayedChars () const;
+ void setCurrentChar (const QChar& c);
+ void setCurrentFont (const QFont& font);
+signals:
+ void currentFontChanged (const QFont& font);
+ void currentCharChanged (const QChar& c);
+ void displayedCharsChanged ();
+ void charSelected (const QChar& c);
+};
diff --git a/sip/kwidgetsaddons/kcolorbutton.sip b/sip/kwidgetsaddons/kcolorbutton.sip
new file mode 100644
index 0000000..75cd017
--- /dev/null
+++ b/sip/kwidgetsaddons/kcolorbutton.sip
@@ -0,0 +1,48 @@
+// 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 KColorButton : QPushButton
+{
+%TypeHeaderCode
+#include <kcolorbutton.h>
+%End
+
+public:
+ explicit KColorButton (QWidget* parent = 0);
+ explicit KColorButton (const QColor& c, QWidget* parent = 0);
+ KColorButton (const QColor& c, const QColor& defaultColor, QWidget* parent = \
0); + virtual ~KColorButton ();
+ QColor color () const;
+ void setColor (const QColor& c);
+ void setAlphaChannelEnabled (bool alpha);
+ bool isAlphaChannelEnabled () const;
+ QColor defaultColor () const;
+ void setDefaultColor (const QColor& c);
+ QSize sizeHint () const;
+ QSize minimumSizeHint () const;
+signals:
+ void changed (const QColor& newColor);
+protected:
+ virtual void paintEvent (QPaintEvent* pe);
+ virtual void dragEnterEvent (QDragEnterEvent*);
+ virtual void dropEvent (QDropEvent*);
+ virtual void mousePressEvent (QMouseEvent* e);
+ virtual void mouseMoveEvent (QMouseEvent* e);
+ virtual void keyPressEvent (QKeyEvent* e);
+};
diff --git a/sip/solid/networkshare.sip b/sip/kwidgetsaddons/kcolorcombo.sip
similarity index 56%
copy from sip/solid/networkshare.sip
copy to sip/kwidgetsaddons/kcolorcombo.sip
index aeb8343..3057a6c 100644
--- a/sip/solid/networkshare.sip
+++ b/sip/kwidgetsaddons/kcolorcombo.sip
@@ -17,26 +17,24 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-namespace Solid
-{
-class NetworkShare : Solid::DeviceInterface
+class KColorCombo : QComboBox
{
%TypeHeaderCode
-#include <networkshare.h>
+#include <kcolorcombo.h>
%End
- explicit NetworkShare (QObject* backendObject);
public:
- virtual ~NetworkShare ();
- enum ShareType
- {
- Unknown,
- Nfs,
- Cifs,
- Upnp
- };
- static Solid::DeviceInterface::Type deviceInterfaceType ();
- Solid::NetworkShare::ShareType type () const;
- QUrl url () const;
-};
+ explicit KColorCombo (QWidget* parent = 0);
+ ~KColorCombo ();
+ void setColor (const QColor& col);
+ QColor color () const;
+ bool isCustomColor () const;
+ void setColors (const QList<QColor>& colors);
+ QList<QColor> colors () const;
+ void showEmptyList ();
+signals:
+ void activated (const QColor& col);
+ void highlighted (const QColor& col);
+protected:
+ virtual void paintEvent (QPaintEvent* event);
};
diff --git a/sip/kcoreaddons/kfilesystemtype_p.sip b/sip/kwidgetsaddons/kcursor.sip
similarity index 68%
copy from sip/kcoreaddons/kfilesystemtype_p.sip
copy to sip/kwidgetsaddons/kcursor.sip
index fa655a8..5641a30 100644
--- a/sip/kcoreaddons/kfilesystemtype_p.sip
+++ b/sip/kwidgetsaddons/kcursor.sip
@@ -17,20 +17,17 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-%ModuleHeaderCode
-#include <kfilesystemtype_p.h>
+class KCursor
+{
+%TypeHeaderCode
+#include <kcursor.h>
%End
-namespace KFileSystemType
-{
-enum Type
-{
- Unknown,
- Nfs,
- Smb,
- Fat,
- Ramfs,
- Other
-};
-KFileSystemType::Type fileSystemType (const QString& path);
+public:
+ static void setAutoHideCursor (QWidget* w, bool enable, bool customEventFilter = 0);
+ static void setHideCursorDelay (int ms);
+ static int hideCursorDelay ();
+ static void autoHideEventFilter (QObject*, QEvent*);
+private:
+ KCursor ();
};
diff --git a/sip/kwidgetsaddons/kdatecombobox.sip b/sip/kwidgetsaddons/kdatecombobox.sip
new file mode 100644
index 0000000..b2d247e
--- /dev/null
+++ b/sip/kwidgetsaddons/kdatecombobox.sip
@@ -0,0 +1,72 @@
+// 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 KDateComboBox : QComboBox
+{
+%TypeHeaderCode
+#include <kdatecombobox.h>
+%End
+
+public:
+ enum Option
+ {
+ EditDate,
+ SelectDate,
+ DatePicker,
+ DateKeywords,
+ WarnOnInvalid
+ };
+ typedef QFlags<KDateComboBox::Option> Options;
+ explicit KDateComboBox (QWidget* parent = 0);
+ virtual ~KDateComboBox ();
+ QDate date () const;
+ bool isValid () const;
+ bool isNull () const;
+ KDateComboBox::Options options () const;
+ QLocale::FormatType displayFormat () const;
+ QDate minimumDate () const;
+ QDate maximumDate () const;
+ QMap<QDate,QString> dateMap () const;
+signals:
+ void dateEntered (const QDate& date);
+ void dateChanged (const QDate& date);
+ void dateEdited (const QDate& date);
+public:
+ void setDate (const QDate& date);
+ void setOptions (KDateComboBox::Options options);
+ void setDisplayFormat (QLocale::FormatType format);
+ void setDateRange (const QDate& minDate, const QDate& maxDate, const QString& \
minWarnMsg = QString(), const QString& maxWarnMsg = QString()); + void \
resetDateRange (); + void setMinimumDate (const QDate& minTime, const QString& \
minWarnMsg = QString()); + void resetMinimumDate ();
+ void setMaximumDate (const QDate& maxDate, const QString& maxWarnMsg = \
QString()); + void resetMaximumDate ();
+ void setDateMap (QMap<QDate,QString> dateMap);
+protected:
+ virtual bool eventFilter (QObject* object, QEvent* event);
+ virtual void showPopup ();
+ virtual void hidePopup ();
+ virtual void mousePressEvent (QMouseEvent* event);
+ virtual void wheelEvent (QWheelEvent* event);
+ virtual void keyPressEvent (QKeyEvent* event);
+ virtual void focusInEvent (QFocusEvent* event);
+ virtual void focusOutEvent (QFocusEvent* event);
+ virtual void resizeEvent (QResizeEvent* event);
+ virtual void assignDate (const QDate& date);
+};
diff --git a/sip/kwidgetsaddons/kdatepicker.sip b/sip/kwidgetsaddons/kdatepicker.sip
new file mode 100644
index 0000000..6753dc8
--- /dev/null
+++ b/sip/kwidgetsaddons/kdatepicker.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 KDatePicker : QFrame
+{
+%TypeHeaderCode
+#include <kdatepicker.h>
+%End
+
+public:
+ explicit KDatePicker (QWidget* parent = 0);
+ explicit KDatePicker (const QDate& dt, QWidget* parent = 0);
+ virtual ~KDatePicker ();
+ QSize sizeHint () const;
+ bool setDate (const QDate& date);
+ const QDate& date () const;
+//ig KDateTable* dateTable () const;
+ void setFontSize (int);
+ int fontSize () const;
+ void setCloseButton (bool enable);
+ bool hasCloseButton () const;
+protected:
+ virtual bool eventFilter (QObject* o, QEvent* e);
+ virtual void resizeEvent (QResizeEvent*);
+ void dateChangedSlot (const QDate& date);
+ void tableClickedSlot ();
+ void monthForwardClicked ();
+ void monthBackwardClicked ();
+ void yearForwardClicked ();
+ void yearBackwardClicked ();
+ void selectMonthClicked ();
+ void selectYearClicked ();
+ void uncheckYearSelector ();
+ void lineEnterPressed ();
+ void todayButtonClicked ();
+ void weekSelected (int);
+signals:
+ void dateChanged (const QDate& date);
+ void dateSelected (const QDate& date);
+ void dateEntered (const QDate& date);
+ void tableClicked ();
+protected:
+ void changeEvent (QEvent* event);
+};
diff --git a/sip/kwidgetsaddons/kdatetimeedit.sip b/sip/kwidgetsaddons/kdatetimeedit.sip
new file mode 100644
index 0000000..3103ad2
--- /dev/null
+++ b/sip/kwidgetsaddons/kdatetimeedit.sip
@@ -0,0 +1,109 @@
+// 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 KDateTimeEdit : QWidget
+{
+%TypeHeaderCode
+#include <kdatetimeedit.h>
+%End
+
+public:
+ enum Option
+ {
+ ShowCalendar,
+ ShowDate,
+ ShowTime,
+ ShowTimeZone,
+ EditDate,
+ EditTime,
+ SelectCalendar,
+ SelectDate,
+ SelectTime,
+ SelectTimeZone,
+ DatePicker,
+ DateKeywords,
+ ForceTime,
+ WarnOnInvalid
+ };
+ typedef QFlags<KDateTimeEdit::Option> Options;
+ explicit KDateTimeEdit (QWidget* parent = 0);
+ virtual ~KDateTimeEdit ();
+ KDateTimeEdit::Options options () const;
+ QDateTime dateTime () const;
+ QDate date () const;
+ QTime time () const;
+ QTimeZone timeZone () const;
+ QList<QLocale> calendarLocalesList () const;
+ QDateTime minimumDateTime () const;
+ QDateTime maximumDateTime () const;
+ QLocale::FormatType dateDisplayFormat () const;
+ QMap<QDate,QString> dateMap () const;
+ QLocale::FormatType timeDisplayFormat () const;
+ int timeListInterval () const;
+ QList<QTime> timeList () const;
+ QList<QTimeZone> timeZones () const;
+ bool isValid () const;
+ bool isNull () const;
+ bool isValidDate () const;
+ bool isNullDate () const;
+ bool isValidTime () const;
+ bool isNullTime () const;
+signals:
+ void dateTimeEntered (const QDateTime& dateTime);
+ void dateTimeChanged (const QDateTime& dateTime);
+ void dateTimeEdited (const QDateTime& dateTime);
+ void calendarEntered (const QLocale& calendarLocale);
+ void calendarChanged (const QLocale& calendarLocale);
+ void dateEntered (const QDate& date);
+ void dateChanged (const QDate& date);
+ void dateEdited (const QDate& date);
+ void timeEntered (const QTime& time);
+ void timeChanged (const QTime& time);
+ void timeEdited (const QTime& time);
+ void timeZoneEntered (const QTimeZone& zone);
+ void timeZoneChanged (const QTimeZone& zone);
+public:
+ void setOptions (KDateTimeEdit::Options options);
+ void setDateTime (const QDateTime& dateTime);
+ void setDate (const QDate& date);
+ void setTime (const QTime& time);
+ void setTimeZone (const QTimeZone& zone);
+ void setDateTimeRange (const QDateTime& minDateTime, const QDateTime& \
maxDateTime, const QString& minWarnMsg = QString(), const QString& maxWarnMsg = QString()); + void \
resetDateTimeRange (); + void setMinimumDateTime (const QDateTime& minDateTime, \
const QString& minWarnMsg = QString()); + void resetMinimumDateTime ();
+ void setMaximumDateTime (const QDateTime& maxDateTime, const QString& maxWarnMsg \
= QString()); + void resetMaximumDateTime ();
+ void setDateDisplayFormat (QLocale::FormatType format);
+ void setCalendarLocalesList (const QList<QLocale>& calendarLocales);
+ void setDateMap (QMap<QDate,QString> dateMap);
+ void setTimeDisplayFormat (QLocale::FormatType formatOptions);
+ void setTimeListInterval (int minutes);
+ void setTimeList (QList<QTime> timeList, const QString& minWarnMsg = QString(), \
const QString& maxWarnMsg = QString()); + void setTimeZones (const \
QList<QTimeZone>& zones); +protected:
+ virtual bool eventFilter (QObject* object, QEvent* event);
+ virtual void focusInEvent (QFocusEvent* event);
+ virtual void focusOutEvent (QFocusEvent* event);
+ virtual void resizeEvent (QResizeEvent* event);
+ virtual void assignDateTime (const QDateTime& dateTime);
+ virtual void assignDate (const QDate& date);
+ virtual void assignTime (const QTime& time);
+ void assignTimeZone (const QTimeZone& zone);
+};
diff --git a/sip/solid/networkshare.sip b/sip/kwidgetsaddons/kdragwidgetdecorator.sip
similarity index 62%
copy from sip/solid/networkshare.sip
copy to sip/kwidgetsaddons/kdragwidgetdecorator.sip
index aeb8343..2e1ca5f 100644
--- a/sip/solid/networkshare.sip
+++ b/sip/kwidgetsaddons/kdragwidgetdecorator.sip
@@ -17,26 +17,20 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-namespace Solid
-{
-class NetworkShare : Solid::DeviceInterface
+class KDragWidgetDecoratorBase : QObject
{
%TypeHeaderCode
-#include <networkshare.h>
+#include <kdragwidgetdecorator.h>
%End
- explicit NetworkShare (QObject* backendObject);
public:
- virtual ~NetworkShare ();
- enum ShareType
- {
- Unknown,
- Nfs,
- Cifs,
- Upnp
- };
- static Solid::DeviceInterface::Type deviceInterfaceType ();
- Solid::NetworkShare::ShareType type () const;
- QUrl url () const;
-};
+ explicit KDragWidgetDecoratorBase (QWidget* parent = 0);
+ ~KDragWidgetDecoratorBase ();
+ void setDragEnabled (bool enable);
+ bool isDragEnabled () const;
+protected:
+ QWidget* decoratedWidget () const;
+ virtual QDrag* dragObject ();
+ virtual bool eventFilter (QObject* watched, QEvent* event);
+ virtual void startDrag ();
};
diff --git a/sip/kwidgetsaddons/kdualaction.sip b/sip/kwidgetsaddons/kdualaction.sip
new file mode 100644
index 0000000..ddc585c
--- /dev/null
+++ b/sip/kwidgetsaddons/kdualaction.sip
@@ -0,0 +1,54 @@
+// 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 KDualAction : QAction
+{
+%TypeHeaderCode
+#include <kdualaction.h>
+%End
+
+public:
+ explicit KDualAction (QObject* parent);
+ KDualAction (const QString& inactiveText, const QString& activeText, \
QObject* parent); + ~KDualAction ();
+ void setActiveGuiItem (const KGuiItem&);
+ KGuiItem activeGuiItem () const;
+ void setInactiveGuiItem (const KGuiItem&);
+ KGuiItem inactiveGuiItem () const;
+ void setActiveIcon (const QIcon&);
+ QIcon activeIcon () const;
+ void setInactiveIcon (const QIcon&);
+ QIcon inactiveIcon () const;
+ void setActiveText (const QString&);
+ QString activeText () const;
+ void setInactiveText (const QString&);
+ QString inactiveText () const;
+ void setActiveToolTip (const QString&);
+ QString activeToolTip () const;
+ void setInactiveToolTip (const QString&);
+ QString inactiveToolTip () const;
+ void setIconForStates (const QIcon& icon);
+ bool isActive () const;
+ void setAutoToggle (bool);
+ bool autoToggle () const;
+ void setActive (bool state);
+signals:
+ void activeChanged (bool);
+ void activeChangedByUser (bool);
+};
diff --git a/sip/kwidgetsaddons/keditlistwidget.sip b/sip/kwidgetsaddons/keditlistwidget.sip
new file mode 100644
index 0000000..122a98c
--- /dev/null
+++ b/sip/kwidgetsaddons/keditlistwidget.sip
@@ -0,0 +1,79 @@
+// 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 KEditListWidget : QWidget
+{
+%TypeHeaderCode
+#include <keditlistwidget.h>
+%End
+
+public:
+ class CustomEditor /NoDefaultCtors/
+ {
+%TypeHeaderCode
+#include <keditlistwidget.h>
+%End
+
+ public:
+ CustomEditor ();
+ CustomEditor (QWidget* repWidget, QLineEdit* edit);
+ CustomEditor (QComboBox* combo);
+ virtual ~CustomEditor ();
+ void setRepresentationWidget (QWidget* repWidget);
+ void setLineEdit (QLineEdit* edit);
+ virtual QWidget* representationWidget () const;
+ virtual QLineEdit* lineEdit () const;
+ };
+ enum Button
+ {
+ Add,
+ Remove,
+ UpDown,
+ All
+ };
+ typedef QFlags<KEditListWidget::Button> Buttons;
+ explicit KEditListWidget (QWidget* parent = 0);
+ KEditListWidget (const KEditListWidget::CustomEditor& customEditor, QWidget* \
parent = 0, bool checkAtEntering = 0, KEditListWidget::Buttons buttons = KEditListWidget::Button::All); + \
virtual ~KEditListWidget (); + QListView* listView () const;
+ QLineEdit* lineEdit () const;
+ QPushButton* addButton () const;
+ QPushButton* removeButton () const;
+ QPushButton* upButton () const;
+ QPushButton* downButton () const;
+ int count () const;
+ void insertStringList (const QStringList& list, int index = -1);
+ void insertItem (const QString& text, int index = -1);
+ void clear ();
+ QString text (int index) const;
+ int currentItem () const;
+ QString currentText () const;
+ QStringList items () const;
+ void setItems (const QStringList& items);
+ KEditListWidget::Buttons buttons () const;
+ void setButtons (KEditListWidget::Buttons buttons);
+ void setCheckAtEntering (bool check);
+ bool checkAtEntering ();
+ void setCustomEditor (const KEditListWidget::CustomEditor& editor);
+ bool eventFilter (QObject* o, QEvent* e);
+signals:
+ void changed ();
+ void added (const QString& text);
+ void removed (const QString& text);
+};
diff --git a/sip/solid/networkshare.sip b/sip/kwidgetsaddons/kfontaction.sip
similarity index 59%
copy from sip/solid/networkshare.sip
copy to sip/kwidgetsaddons/kfontaction.sip
index aeb8343..04a8182 100644
--- a/sip/solid/networkshare.sip
+++ b/sip/kwidgetsaddons/kfontaction.sip
@@ -17,26 +17,19 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-namespace Solid
-{
-class NetworkShare : Solid::DeviceInterface
+class KFontAction : KSelectAction
{
%TypeHeaderCode
-#include <networkshare.h>
+#include <kfontaction.h>
%End
- explicit NetworkShare (QObject* backendObject);
public:
- virtual ~NetworkShare ();
- enum ShareType
- {
- Unknown,
- Nfs,
- Cifs,
- Upnp
- };
- static Solid::DeviceInterface::Type deviceInterfaceType ();
- Solid::NetworkShare::ShareType type () const;
- QUrl url () const;
-};
+ KFontAction (uint fontListCriteria, QObject* parent);
+ explicit KFontAction (QObject* parent);
+ KFontAction (const QString& text, QObject* parent);
+ KFontAction (const QIcon& icon, const QString& text, QObject* parent);
+ virtual ~KFontAction ();
+ QString font () const;
+ void setFont (const QString& family);
+ virtual QWidget* createWidget (QWidget* parent);
};
diff --git a/sip/kwidgetsaddons/kfontchooser.sip b/sip/kwidgetsaddons/kfontchooser.sip
new file mode 100644
index 0000000..9e3ab55
--- /dev/null
+++ b/sip/kwidgetsaddons/kfontchooser.sip
@@ -0,0 +1,77 @@
+// 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 KFontChooser : QWidget
+{
+%TypeHeaderCode
+#include <kfontchooser.h>
+%End
+
+public:
+ enum FontColumn
+ {
+ FamilyList,
+ StyleList,
+ SizeList
+ };
+ enum FontDiff
+ {
+ NoFontDiffFlags,
+ FontDiffFamily,
+ FontDiffStyle,
+ FontDiffSize,
+ AllFontDiffs
+ };
+ typedef QFlags<KFontChooser::FontDiff> FontDiffFlags;
+ enum DisplayFlag
+ {
+ NoDisplayFlags,
+ FixedFontsOnly,
+ DisplayFrame,
+ ShowDifferences
+ };
+ typedef QFlags<KFontChooser::DisplayFlag> DisplayFlags;
+ explicit KFontChooser (QWidget* parent = 0L, const KFontChooser::DisplayFlags& flags \
= KFontChooser::DisplayFlag::DisplayFrame, const QStringList& fontList = QStringList(), int \
visibleListSize = 8); +//, Qt::CheckState* sizeIsRelativeState = 0L);
+
+ virtual ~KFontChooser ();
+ void enableColumn (int column, bool state);
+ void setFont (const QFont& font, bool onlyFixed = 0);
+ KFontChooser::FontDiffFlags fontDiffFlags () const;
+ QFont font () const;
+ void setColor (const QColor& col);
+ QColor color () const;
+ void setBackgroundColor (const QColor& col);
+ QColor backgroundColor () const;
+ void setSizeIsRelative (Qt::CheckState relative);
+ Qt::CheckState sizeIsRelative () const;
+ QString sampleText () const;
+ void setSampleText (const QString& text);
+ void setSampleBoxVisible (bool visible);
+ enum FontListCriteria
+ {
+ FixedWidthFonts,
+ ScalableFonts,
+ SmoothScalableFonts
+ };
+ static void getFontList (QStringList& list, uint fontListCriteria);
+ virtual QSize sizeHint () const;
+signals:
+ void fontSelected (const QFont& font);
+};
diff --git a/sip/solid/networkshare.sip b/sip/kwidgetsaddons/kfontrequester.sip
similarity index 54%
copy from sip/solid/networkshare.sip
copy to sip/kwidgetsaddons/kfontrequester.sip
index aeb8343..047b1c1 100644
--- a/sip/solid/networkshare.sip
+++ b/sip/kwidgetsaddons/kfontrequester.sip
@@ -17,26 +17,24 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-namespace Solid
-{
-class NetworkShare : Solid::DeviceInterface
+class KFontRequester : QWidget
{
%TypeHeaderCode
-#include <networkshare.h>
+#include <kfontrequester.h>
%End
- explicit NetworkShare (QObject* backendObject);
public:
- virtual ~NetworkShare ();
- enum ShareType
- {
- Unknown,
- Nfs,
- Cifs,
- Upnp
- };
- static Solid::DeviceInterface::Type deviceInterfaceType ();
- Solid::NetworkShare::ShareType type () const;
- QUrl url () const;
-};
+ explicit KFontRequester (QWidget* parent = 0L, bool onlyFixed = 0);
+ ~KFontRequester ();
+ QFont font () const;
+ bool isFixedOnly () const;
+ QString sampleText () const;
+ QString title () const;
+ QLabel* label () const;
+ QPushButton* button () const;
+ virtual void setFont (const QFont& font, bool onlyFixed = 0);
+ virtual void setSampleText (const QString& text);
+ virtual void setTitle (const QString& title);
+signals:
+ void fontSelected (const QFont& font);
};
diff --git a/sip/solid/networkshare.sip b/sip/kwidgetsaddons/kfontsizeaction.sip
similarity index 59%
copy from sip/solid/networkshare.sip
copy to sip/kwidgetsaddons/kfontsizeaction.sip
index aeb8343..b39aac7 100644
--- a/sip/solid/networkshare.sip
+++ b/sip/kwidgetsaddons/kfontsizeaction.sip
@@ -17,26 +17,21 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-namespace Solid
-{
-class NetworkShare : Solid::DeviceInterface
+class KFontSizeAction : KSelectAction
{
%TypeHeaderCode
-#include <networkshare.h>
+#include <kfontsizeaction.h>
%End
- explicit NetworkShare (QObject* backendObject);
public:
- virtual ~NetworkShare ();
- enum ShareType
- {
- Unknown,
- Nfs,
- Cifs,
- Upnp
- };
- static Solid::DeviceInterface::Type deviceInterfaceType ();
- Solid::NetworkShare::ShareType type () const;
- QUrl url () const;
-};
+ explicit KFontSizeAction (QObject* parent);
+ KFontSizeAction (const QString& text, QObject* parent);
+ KFontSizeAction (const QIcon& icon, const QString& text, QObject* parent);
+ virtual ~KFontSizeAction ();
+ int fontSize () const;
+ void setFontSize (int size);
+signals:
+ void fontSizeChanged (int);
+protected:
+ virtual void actionTriggered (QAction* action);
};
diff --git a/sip/kwidgetsaddons/kguiitem.sip b/sip/kwidgetsaddons/kguiitem.sip
new file mode 100644
index 0000000..a3be8d3
--- /dev/null
+++ b/sip/kwidgetsaddons/kguiitem.sip
@@ -0,0 +1,48 @@
+// 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 KGuiItem
+{
+%TypeHeaderCode
+#include <kguiitem.h>
+%End
+
+public:
+ KGuiItem ();
+ explicit KGuiItem (const QString& text, const QString& iconName = QString(), const \
QString& toolTip = QString(), const QString& whatsThis = QString()); + \
KGuiItem (const QString& text, const QIcon& icon, const QString& toolTip = QString(), const QString& \
whatsThis = QString()); + KGuiItem (const KGuiItem& rhs);
+ ~KGuiItem ();
+ QString text () const;
+ QString plainText () const;
+ QIcon icon () const;
+ QString iconName () const;
+ QString toolTip () const;
+ QString whatsThis () const;
+ bool isEnabled () const;
+ bool hasIcon () const;
+ void setText (const QString& text);
+ void setIcon (const QIcon& iconset);
+ void setIconName (const QString& iconName);
+ void setToolTip (const QString& tooltip);
+ void setWhatsThis (const QString& whatsThis);
+ void setEnabled (bool enable);
+ static void assign (QPushButton* button, const KGuiItem& item);
+//ig KGuiItem& operator= (const KGuiItem& rhs);
+};
diff --git a/sip/kwidgetsaddons/kled.sip b/sip/kwidgetsaddons/kled.sip
new file mode 100644
index 0000000..3b367a0
--- /dev/null
+++ b/sip/kwidgetsaddons/kled.sip
@@ -0,0 +1,66 @@
+// 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 KLed : QWidget
+{
+%TypeHeaderCode
+#include <kled.h>
+%End
+
+public:
+ enum State
+ {
+ Off,
+ On
+ };
+ enum Shape
+ {
+ Rectangular,
+ Circular
+ };
+ enum Look
+ {
+ Flat,
+ Raised,
+ Sunken
+ };
+ explicit KLed (QWidget* parent = 0);
+ explicit KLed (const QColor& color, QWidget* parent = 0);
+ KLed (const QColor& color, KLed::State state, KLed::Look look, KLed::Shape \
shape, QWidget* parent = 0); + ~KLed ();
+ QColor color () const;
+ KLed::State state () const;
+ KLed::Look look () const;
+ KLed::Shape shape () const;
+ int darkFactor () const;
+ void setColor (const QColor& color);
+ void setState (KLed::State state);
+ void setLook (KLed::Look look);
+ void setShape (KLed::Shape shape);
+ void setDarkFactor (int darkFactor);
+ virtual QSize sizeHint () const;
+ virtual QSize minimumSizeHint () const;
+ void toggle ();
+ void on ();
+ void off ();
+protected:
+ void paintEvent (QPaintEvent*);
+ void resizeEvent (QResizeEvent*);
+ void updateCachedPixmap ();
+};
diff --git a/sip/kwidgetsaddons/kmessagebox.sip b/sip/kwidgetsaddons/kmessagebox.sip
new file mode 100644
index 0000000..bffaa5e
--- /dev/null
+++ b/sip/kwidgetsaddons/kmessagebox.sip
@@ -0,0 +1,107 @@
+// 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 <kmessagebox.h>
+%End
+
+namespace KMessageBox
+{
+enum ButtonCode
+{
+ Ok,
+ Cancel,
+ Yes,
+ No,
+ Continue
+};
+enum DialogType
+{
+ QuestionYesNo,
+ WarningYesNo,
+ WarningContinueCancel,
+ WarningYesNoCancel,
+ Information,
+ Sorry,
+ Error,
+ QuestionYesNoCancel
+};
+enum Option
+{
+ Notify,
+ AllowLink,
+ Dangerous,
+ PlainCaption,
+ NoExec,
+ WindowModal
+};
+typedef QFlags<KMessageBox::Option> Options;
+};
+namespace KMessageBox
+{
+KMessageBox::ButtonCode questionYesNo (QWidget* parent, const QString& text, const QString& caption = \
QString(), const KGuiItem& buttonYes = KStandardGuiItem::yes(), const KGuiItem& buttonNo = \
KStandardGuiItem::no(), const QString& dontAskAgainName = QString(), KMessageBox::Options options = \
KMessageBox::Notify); +KMessageBox::ButtonCode questionYesNoCancel (QWidget* parent, const QString& \
text, const QString& caption = QString(), const KGuiItem& buttonYes = KStandardGuiItem::yes(), const \
KGuiItem& buttonNo = KStandardGuiItem::no(), const KGuiItem& buttonCancel = KStandardGuiItem::cancel(), \
const QString& dontAskAgainName = QString(), KMessageBox::Options options = KMessageBox::Notify); \
+KMessageBox::ButtonCode questionYesNoList (QWidget* parent, const QString& text, const QStringList& \
strlist, const QString& caption = QString(), const KGuiItem& buttonYes = KStandardGuiItem::yes(), const \
KGuiItem& buttonNo = KStandardGuiItem::no(), const QString& dontAskAgainName = QString(), \
KMessageBox::Options options = KMessageBox::Notify); +KMessageBox::ButtonCode warningYesNo (QWidget* \
parent, const QString& text, const QString& caption = QString(), const KGuiItem& buttonYes = \
KStandardGuiItem::yes(), const KGuiItem& buttonNo = KStandardGuiItem::no(), const QString& \
dontAskAgainName = QString(), KMessageBox::Options options = \
KMessageBox::Options(KMessageBox::Notify|KMessageBox::Dangerous)); +KMessageBox::ButtonCode \
warningYesNoList (QWidget* parent, const QString& text, const QStringList& strlist, const QString& \
caption = QString(), const KGuiItem& buttonYes = KStandardGuiItem::yes(), const KGuiItem& buttonNo = \
KStandardGuiItem::no(), const QString& dontAskAgainName = QString(), KMessageBox::Options options = \
KMessageBox::Options(KMessageBox::Notify|KMessageBox::Dangerous)); +KMessageBox::ButtonCode \
warningContinueCancel (QWidget* parent, const QString& text, const QString& caption = QString(), const \
KGuiItem& buttonContinue = KStandardGuiItem::cont(), const KGuiItem& buttonCancel = \
KStandardGuiItem::cancel(), const QString& dontAskAgainName = QString(), KMessageBox::Options options = \
KMessageBox::Notify); +KMessageBox::ButtonCode warningContinueCancelList (QWidget* parent, const \
QString& text, const QStringList& strlist, const QString& caption = QString(), const KGuiItem& \
buttonContinue = KStandardGuiItem::cont(), const KGuiItem& buttonCancel = KStandardGuiItem::cancel(), \
const QString& dontAskAgainName = QString(), KMessageBox::Options options = KMessageBox::Notify); \
+KMessageBox::ButtonCode warningYesNoCancel (QWidget* parent, const QString& text, const QString& \
caption = QString(), const KGuiItem& buttonYes = KStandardGuiItem::yes(), const KGuiItem& buttonNo = \
KStandardGuiItem::no(), const KGuiItem& buttonCancel = KStandardGuiItem::cancel(), const QString& \
dontAskAgainName = QString(), KMessageBox::Options options = KMessageBox::Notify); \
+KMessageBox::ButtonCode warningYesNoCancelList (QWidget* parent, const QString& text, const \
QStringList& strlist, const QString& caption = QString(), const KGuiItem& buttonYes = \
KStandardGuiItem::yes(), const KGuiItem& buttonNo = KStandardGuiItem::no(), const KGuiItem& buttonCancel \
= KStandardGuiItem::cancel(), const QString& dontAskAgainName = QString(), KMessageBox::Options options = \
KMessageBox::Notify); +void error (QWidget* parent, const QString& text, const \
QString& caption = QString(), KMessageBox::Options options = KMessageBox::Notify); +void \
errorList (QWidget* parent, const QString& text, const QStringList& strlist, const QString& caption = \
QString(), KMessageBox::Options options = KMessageBox::Notify); +void detailedError \
(QWidget* parent, const QString& text, const QString& details, const QString& caption = QString(), \
KMessageBox::Options options = KMessageBox::Notify); +void sorry (QWidget* parent, \
const QString& text, const QString& caption = QString(), KMessageBox::Options options = \
KMessageBox::Notify); +void detailedSorry (QWidget* parent, const QString& text, const \
QString& details, const QString& caption = QString(), KMessageBox::Options options = \
KMessageBox::Notify); +void information (QWidget* parent, const QString& text, const \
QString& caption = QString(), const QString& dontShowAgainName = QString(), KMessageBox::Options options \
= KMessageBox::Notify); +void informationList (QWidget* parent, const QString& text, \
const QStringList& strlist, const QString& caption = QString(), const QString& dontShowAgainName = \
QString(), KMessageBox::Options options = KMessageBox::Notify); +void \
enableAllMessages (); +void enableMessage (const QString& dontShowAgainName);
+void about (QWidget* parent, const QString& text, const QString& caption = QString(), \
KMessageBox::Options options = KMessageBox::Notify); +KMessageBox::ButtonCode messageBox (QWidget* \
parent, KMessageBox::DialogType type, const QString& text, const QString& caption = QString(), const \
KGuiItem& buttonYes = KStandardGuiItem::yes(), const KGuiItem& buttonNo = KStandardGuiItem::no(), const \
KGuiItem& buttonCancel = KStandardGuiItem::cancel(), const QString& dontShowAskAgainName = QString(), \
KMessageBox::Options options = KMessageBox::Notify); +bool shouldBeShownYesNo (const \
QString& dontShowAgainName, KMessageBox::ButtonCode& result); +bool \
shouldBeShownContinue (const QString& dontShowAgainName); +void saveDontShowAgainYesNo \
(const QString& dontShowAgainName, KMessageBox::ButtonCode result); +void \
saveDontShowAgainContinue (const QString& dontShowAgainName); +//ig void \
setDontShowAgainConfig (KConfig* cfg); +
+// KMessageBoxDontAskAgainInterface is not public.
+//ig void setDontShowAgainInterface (KMessageBoxDontAskAgainInterface* \
dontAskAgainInterface); +
+//ig void setNotifyInterface (KMessageBoxNotifyInterface* notifyInterface);
+QDialogButtonBox::StandardButton createKMessageBox (QDialog* dialog, QDialogButtonBox* buttons, \
QMessageBox::Icon icon, const QString& text, const QStringList& strlist, const QString& ask, bool* \
checkboxReturn, KMessageBox::Options options, const QString& details = QString()); \
+QDialogButtonBox::StandardButton createKMessageBox (QDialog* dialog, QDialogButtonBox* buttons, const \
QIcon& icon, const QString& text, const QStringList& strlist, const QString& ask, bool* checkboxReturn, \
KMessageBox::Options options, const QString& details = QString(), QMessageBox::Icon notifyType = \
QMessageBox::Information); +KMessageBox::ButtonCode questionYesNoWId (WId parent_id, const QString& \
text, const QString& caption = QString(), const KGuiItem& buttonYes = KStandardGuiItem::yes(), const \
KGuiItem& buttonNo = KStandardGuiItem::no(), const QString& dontAskAgainName = QString(), \
KMessageBox::Options options = KMessageBox::Notify); +KMessageBox::ButtonCode questionYesNoCancelWId \
(WId parent_id, const QString& text, const QString& caption = QString(), const KGuiItem& buttonYes = \
KStandardGuiItem::yes(), const KGuiItem& buttonNo = KStandardGuiItem::no(), const KGuiItem& buttonCancel \
= KStandardGuiItem::cancel(), const QString& dontAskAgainName = QString(), KMessageBox::Options options = \
KMessageBox::Notify); +KMessageBox::ButtonCode questionYesNoListWId (WId parent_id, const QString& text, \
const QStringList& strlist, const QString& caption = QString(), const KGuiItem& buttonYes = \
KStandardGuiItem::yes(), const KGuiItem& buttonNo = KStandardGuiItem::no(), const QString& \
dontAskAgainName = QString(), KMessageBox::Options options = KMessageBox::Notify); \
+KMessageBox::ButtonCode warningYesNoWId (WId parent_id, const QString& text, const QString& caption = \
QString(), const KGuiItem& buttonYes = KStandardGuiItem::yes(), const KGuiItem& buttonNo = \
KStandardGuiItem::no(), const QString& dontAskAgainName = QString(), KMessageBox::Options options = \
KMessageBox::Options(KMessageBox::Notify|KMessageBox::Dangerous)); +KMessageBox::ButtonCode \
warningYesNoListWId (WId parent_id, const QString& text, const QStringList& strlist, const QString& \
caption = QString(), const KGuiItem& buttonYes = KStandardGuiItem::yes(), const KGuiItem& buttonNo = \
KStandardGuiItem::no(), const QString& dontAskAgainName = QString(), KMessageBox::Options options = \
KMessageBox::Options(KMessageBox::Notify|KMessageBox::Dangerous)); +KMessageBox::ButtonCode \
warningContinueCancelWId (WId parent_id, const QString& text, const QString& caption = QString(), const \
KGuiItem& buttonContinue = KStandardGuiItem::cont(), const KGuiItem& buttonCancel = \
KStandardGuiItem::cancel(), const QString& dontAskAgainName = QString(), KMessageBox::Options options = \
KMessageBox::Notify); +KMessageBox::ButtonCode warningContinueCancelListWId (WId parent_id, const \
QString& text, const QStringList& strlist, const QString& caption = QString(), const KGuiItem& \
buttonContinue = KStandardGuiItem::cont(), const KGuiItem& buttonCancel = KStandardGuiItem::cancel(), \
const QString& dontAskAgainName = QString(), KMessageBox::Options options = KMessageBox::Notify); \
+KMessageBox::ButtonCode warningYesNoCancelWId (WId parent_id, const QString& text, const QString& \
caption = QString(), const KGuiItem& buttonYes = KStandardGuiItem::yes(), const KGuiItem& buttonNo = \
KStandardGuiItem::no(), const KGuiItem& buttonCancel = KStandardGuiItem::cancel(), const QString& \
dontAskAgainName = QString(), KMessageBox::Options options = KMessageBox::Notify); \
+KMessageBox::ButtonCode warningYesNoCancelListWId (WId parent_id, const QString& text, const \
QStringList& strlist, const QString& caption = QString(), const KGuiItem& buttonYes = \
KStandardGuiItem::yes(), const KGuiItem& buttonNo = KStandardGuiItem::no(), const KGuiItem& buttonCancel \
= KStandardGuiItem::cancel(), const QString& dontAskAgainName = QString(), KMessageBox::Options options = \
KMessageBox::Notify); +void errorWId (WId parent_id, const QString& text, const \
QString& caption = QString(), KMessageBox::Options options = KMessageBox::Notify); +void \
errorListWId (WId parent_id, const QString& text, const QStringList& strlist, const QString& caption = \
QString(), KMessageBox::Options options = KMessageBox::Notify); +void detailedErrorWId \
(WId parent_id, const QString& text, const QString& details, const QString& caption = QString(), \
KMessageBox::Options options = KMessageBox::Notify); +void sorryWId (WId parent_id, \
const QString& text, const QString& caption = QString(), KMessageBox::Options options = \
KMessageBox::Notify); +void detailedSorryWId (WId parent_id, const QString& text, \
const QString& details, const QString& caption = QString(), KMessageBox::Options options = \
KMessageBox::Notify); +void informationWId (WId parent_id, const QString& text, const \
QString& caption = QString(), const QString& dontShowAgainName = QString(), KMessageBox::Options options \
= KMessageBox::Notify); +void informationListWId (WId parent_id, const QString& text, \
const QStringList& strlist, const QString& caption = QString(), const QString& dontShowAgainName = \
QString(), KMessageBox::Options options = KMessageBox::Notify); +KMessageBox::ButtonCode messageBoxWId \
(WId parent_id, KMessageBox::DialogType type, const QString& text, const QString& caption = QString(), \
const KGuiItem& buttonYes = KStandardGuiItem::yes(), const KGuiItem& buttonNo = KStandardGuiItem::no(), \
const KGuiItem& buttonCancel = KStandardGuiItem::cancel(), const QString& dontShowAskAgainName = \
QString(), KMessageBox::Options options = KMessageBox::Notify); +};
diff --git a/sip/kcoreaddons/kfilesystemtype_p.sip \
b/sip/kwidgetsaddons/kmessageboxdontaskagaininterface.sip similarity index 78%
copy from sip/kcoreaddons/kfilesystemtype_p.sip
copy to sip/kwidgetsaddons/kmessageboxdontaskagaininterface.sip
index fa655a8..4904fb1 100644
--- a/sip/kcoreaddons/kfilesystemtype_p.sip
+++ b/sip/kwidgetsaddons/kmessageboxdontaskagaininterface.sip
@@ -17,20 +17,3 @@
// 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/kfilesystemtype_p.sip b/sip/kwidgetsaddons/kmessageboxnotifyinterface.sip
similarity index 78%
copy from sip/kcoreaddons/kfilesystemtype_p.sip
copy to sip/kwidgetsaddons/kmessageboxnotifyinterface.sip
index fa655a8..4904fb1 100644
--- a/sip/kcoreaddons/kfilesystemtype_p.sip
+++ b/sip/kwidgetsaddons/kmessageboxnotifyinterface.sip
@@ -17,20 +17,3 @@
// 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/kwidgetsaddons/kmessagewidget.sip b/sip/kwidgetsaddons/kmessagewidget.sip
new file mode 100644
index 0000000..6fde811
--- /dev/null
+++ b/sip/kwidgetsaddons/kmessagewidget.sip
@@ -0,0 +1,65 @@
+// 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 KMessageWidget : QFrame
+{
+%TypeHeaderCode
+#include <kmessagewidget.h>
+%End
+
+public:
+ enum MessageType
+ {
+ Positive,
+ Information,
+ Warning,
+ Error
+ };
+ explicit KMessageWidget (QWidget* parent = 0);
+ explicit KMessageWidget (const QString& text, QWidget* parent = 0);
+ ~KMessageWidget ();
+ QString text () const;
+ bool wordWrap () const;
+ bool isCloseButtonVisible () const;
+ KMessageWidget::MessageType messageType () const;
+ void addAction (QAction* action);
+ void removeAction (QAction* action);
+ QSize sizeHint () const;
+ QSize minimumSizeHint () const;
+ int heightForWidth (int width) const;
+ QIcon icon () const;
+ bool isHideAnimationRunning () const;
+ bool isShowAnimationRunning () const;
+ void setText (const QString& text);
+ void setWordWrap (bool wordWrap);
+ void setCloseButtonVisible (bool visible);
+ void setMessageType (KMessageWidget::MessageType type);
+ void animatedShow ();
+ void animatedHide ();
+ void setIcon (const QIcon& icon);
+signals:
+ void linkActivated (const QString& contents);
+ void linkHovered (const QString& contents);
+ void hideAnimationFinished ();
+ void showAnimationFinished ();
+protected:
+ void paintEvent (QPaintEvent* event);
+ bool event (QEvent* event);
+ void resizeEvent (QResizeEvent* event);
+};
diff --git a/sip/kwidgetsaddons/kmimetypechooser.sip b/sip/kwidgetsaddons/kmimetypechooser.sip
new file mode 100644
index 0000000..432c36b
--- /dev/null
+++ b/sip/kwidgetsaddons/kmimetypechooser.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.
+
+class KMimeTypeChooser : QWidget
+{
+%TypeHeaderCode
+#include <kmimetypechooser.h>
+%End
+
+public:
+ enum Visuals
+ {
+ Comments,
+ Patterns,
+ EditButton
+ };
+ explicit KMimeTypeChooser (const QString& text = QString(), const QStringList& \
selectedMimeTypes = QStringList(), const QString& defaultGroup = QString(), const QStringList& \
groupsToShow = QStringList(), int visuals = Comments|Patterns|EditButton, QWidget* parent = 0); + \
~KMimeTypeChooser (); + QStringList mimeTypes () const;
+ QStringList patterns () const;
+};
+class KMimeTypeChooserDialog : QDialog
+{
+%TypeHeaderCode
+#include <kmimetypechooser.h>
+%End
+
+public:
+ explicit KMimeTypeChooserDialog (const QString& caption = QString(), const QString& \
text = QString(), const QStringList& selectedMimeTypes = QStringList(), const QString& defaultGroup = \
QString(), const QStringList& groupsToShow = QStringList(), int visuals = \
KMimeTypeChooser::Comments|KMimeTypeChooser::Patterns|KMimeTypeChooser::EditButton, QWidget* parent = 0); \
+ KMimeTypeChooserDialog (const QString& caption, const QString& text, const \
QStringList& selectedMimeTypes, const QString& defaultGroup, QWidget* parent = 0); + \
~KMimeTypeChooserDialog (); + KMimeTypeChooser* chooser ();
+};
diff --git a/sip/kwidgetsaddons/kmultitabbar.sip b/sip/kwidgetsaddons/kmultitabbar.sip
new file mode 100644
index 0000000..8037331
--- /dev/null
+++ b/sip/kwidgetsaddons/kmultitabbar.sip
@@ -0,0 +1,96 @@
+// 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 KMultiTabBar : QWidget
+{
+%TypeHeaderCode
+#include <kmultitabbar.h>
+%End
+
+public:
+ enum KMultiTabBarPosition
+ {
+ Left,
+ Right,
+ Top,
+ Bottom
+ };
+ enum KMultiTabBarStyle
+ {
+ VSNET,
+ KDEV3ICON,
+ STYLELAST
+ };
+ explicit KMultiTabBar (KMultiTabBar::KMultiTabBarPosition pos, QWidget* parent = 0);
+ virtual ~KMultiTabBar ();
+ int appendButton (const QPixmap& pic, int id = -1, QMenu* popup = 0, const \
QString& not_used_yet = QString()); + void removeButton (int id);
+ int appendTab (const QPixmap& pic, int id = -1, const QString& text = \
QString()); + void removeTab (int id);
+ void setTab (int id, bool state);
+ bool isTabRaised (int id) const;
+ KMultiTabBarButton* button (int id) const;
+ KMultiTabBarTab* tab (int id) const;
+ void setPosition (KMultiTabBar::KMultiTabBarPosition pos);
+ KMultiTabBar::KMultiTabBarPosition position () const;
+ void setStyle (KMultiTabBar::KMultiTabBarStyle style);
+ KMultiTabBar::KMultiTabBarStyle tabStyle () const;
+protected:
+ virtual void fontChange (const QFont&);
+ void updateSeparator ();
+};
+class KMultiTabBarButton : QPushButton
+{
+%TypeHeaderCode
+#include <kmultitabbar.h>
+%End
+
+public:
+ int id () const;
+ virtual ~KMultiTabBarButton ();
+ void setText (const QString& text);
+signals:
+ void clicked (int id);
+protected:
+ virtual void slotClicked ();
+ virtual void hideEvent (QHideEvent*);
+ virtual void showEvent (QShowEvent*);
+ virtual void paintEvent (QPaintEvent*);
+ KMultiTabBarButton (const QPixmap& pic, const QString&, int id, QWidget* \
parent); +};
+class KMultiTabBarTab : KMultiTabBarButton
+{
+%TypeHeaderCode
+#include <kmultitabbar.h>
+%End
+
+public:
+ virtual ~KMultiTabBarTab ();
+ virtual QSize sizeHint () const;
+ virtual QSize minimumSizeHint () const;
+ void setPosition (KMultiTabBar::KMultiTabBarPosition);
+ void setStyle (KMultiTabBar::KMultiTabBarStyle);
+ void setState (bool state);
+ void setIcon (const QString&);
+ void setIcon (const QPixmap&);
+protected:
+ virtual void paintEvent (QPaintEvent*);
+private:
+ KMultiTabBarTab (const QPixmap& pic, const QString&, int id, QWidget* \
parent, KMultiTabBar::KMultiTabBarPosition pos, KMultiTabBar::KMultiTabBarStyle style); +};
diff --git a/sip/kwidgetsaddons/knewpassworddialog.sip b/sip/kwidgetsaddons/knewpassworddialog.sip
new file mode 100644
index 0000000..1371c7c
--- /dev/null
+++ b/sip/kwidgetsaddons/knewpassworddialog.sip
@@ -0,0 +1,50 @@
+// 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 KNewPasswordDialog : QDialog
+{
+%TypeHeaderCode
+#include <knewpassworddialog.h>
+%End
+
+public:
+ explicit KNewPasswordDialog (QWidget* parent = 0);
+ virtual ~KNewPasswordDialog ();
+ void setPrompt (const QString& prompt);
+ QString prompt () const;
+ void setPixmap (const QPixmap&);
+ QPixmap pixmap () const;
+ void setAllowEmptyPasswords (bool allowed);
+ bool allowEmptyPasswords () const;
+ void setMinimumPasswordLength (int minLength);
+ int minimumPasswordLength () const;
+ void setMaximumPasswordLength (int maxLength);
+ int maximumPasswordLength () const;
+ void setReasonablePasswordLength (int reasonableLength);
+ int reasonablePasswordLength () const;
+ void setPasswordStrengthWarningLevel (int warningLevel);
+ int passwordStrengthWarningLevel () const;
+ QString password () const;
+ virtual void accept ();
+protected:
+ virtual bool checkPassword (const QString&);
+ bool checkAndGetPassword (QString* pwd);
+signals:
+ void newPassword (const QString& password);
+};
diff --git a/sip/kwidgetsaddons/kpagedialog.sip b/sip/kwidgetsaddons/kpagedialog.sip
new file mode 100644
index 0000000..c00d24f
--- /dev/null
+++ b/sip/kwidgetsaddons/kpagedialog.sip
@@ -0,0 +1,61 @@
+// 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 KPageDialog : QDialog
+{
+%TypeHeaderCode
+#include <kpagedialog.h>
+%End
+
+public:
+ enum FaceType
+ {
+ Auto,
+ Plain,
+ List,
+ Tree,
+ Tabbed
+ };
+ explicit KPageDialog (QWidget* parent = 0, Qt::WindowFlags flags = 0);
+ ~KPageDialog ();
+ void setFaceType (KPageDialog::FaceType faceType);
+ KPageWidgetItem* addPage (QWidget* widget, const QString& name);
+ void addPage (KPageWidgetItem* item);
+ KPageWidgetItem* insertPage (KPageWidgetItem* before, QWidget* widget, const QString& name);
+ void insertPage (KPageWidgetItem* before, KPageWidgetItem* item);
+ KPageWidgetItem* addSubPage (KPageWidgetItem* parent, QWidget* widget, const QString& name);
+ void addSubPage (KPageWidgetItem* parent, KPageWidgetItem* item);
+ void removePage (KPageWidgetItem* item);
+ void setCurrentPage (KPageWidgetItem* item);
+ KPageWidgetItem* currentPage () const;
+ void setStandardButtons (QDialogButtonBox::StandardButtons buttons);
+ QPushButton* button (QDialogButtonBox::StandardButton which) const;
+signals:
+ void currentPageChanged (KPageWidgetItem* current, KPageWidgetItem* before);
+ void pageRemoved (KPageWidgetItem* page);
+protected:
+ KPageDialog (KPageWidget* widget, QWidget* parent, Qt::WindowFlags flags = \
0); +//ig KPageDialog (KPageDialogPrivate& dd, KPageWidget* widget, QWidget* \
parent, Qt::WindowFlags flags = 0); +//ig KPageWidget* pageWidget ();
+ const KPageWidget* pageWidget () const;
+ void setPageWidget (KPageWidget* widget);
+//ig QDialogButtonBox* buttonBox ();
+ const QDialogButtonBox* buttonBox () const;
+ void setButtonBox (QDialogButtonBox* box);
+};
diff --git a/sip/kcoreaddons/kfilesystemtype_p.sip b/sip/kwidgetsaddons/kpagemodel.sip
similarity index 70%
copy from sip/kcoreaddons/kfilesystemtype_p.sip
copy to sip/kwidgetsaddons/kpagemodel.sip
index fa655a8..54e8da4 100644
--- a/sip/kcoreaddons/kfilesystemtype_p.sip
+++ b/sip/kwidgetsaddons/kpagemodel.sip
@@ -17,20 +17,20 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-%ModuleHeaderCode
-#include <kfilesystemtype_p.h>
+class KPageModel : QAbstractItemModel
+{
+%TypeHeaderCode
+#include <kpagemodel.h>
%End
-namespace KFileSystemType
-{
-enum Type
-{
- Unknown,
- Nfs,
- Smb,
- Fat,
- Ramfs,
- Other
-};
-KFileSystemType::Type fileSystemType (const QString& path);
+public:
+ enum Role
+ {
+ HeaderRole,
+ WidgetRole
+ };
+ explicit KPageModel (QObject* parent = 0);
+ virtual ~KPageModel ();
+protected:
+//ig KPageModel (KPageModelPrivate& dd, QObject* parent);
};
diff --git a/sip/kwidgetsaddons/kpageview.sip b/sip/kwidgetsaddons/kpageview.sip
new file mode 100644
index 0000000..596e6fd
--- /dev/null
+++ b/sip/kwidgetsaddons/kpageview.sip
@@ -0,0 +1,53 @@
+// 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 KPageView : QWidget
+{
+%TypeHeaderCode
+#include <kpageview.h>
+%End
+
+public:
+ enum FaceType
+ {
+ Auto,
+ Plain,
+ List,
+ Tree,
+ Tabbed
+ };
+ explicit KPageView (QWidget* parent = 0);
+ virtual ~KPageView ();
+ void setModel (QAbstractItemModel* model);
+ QAbstractItemModel* model () const;
+ void setFaceType (KPageView::FaceType faceType);
+ KPageView::FaceType faceType () const;
+ void setCurrentPage (const QModelIndex& index);
+ QModelIndex currentPage () const;
+ void setItemDelegate (QAbstractItemDelegate* delegate);
+ QAbstractItemDelegate* itemDelegate () const;
+ void setDefaultWidget (QWidget* widget);
+signals:
+ void currentPageChanged (const QModelIndex& current, const QModelIndex& \
previous); +protected:
+ virtual QAbstractItemView* createView ();
+ virtual bool showPageHeader () const;
+ virtual Qt::Alignment viewPosition () const;
+//ig KPageView (KPageViewPrivate& dd, QWidget* parent);
+};
diff --git a/sip/kwidgetsaddons/kpagewidget.sip b/sip/kwidgetsaddons/kpagewidget.sip
new file mode 100644
index 0000000..ddae45f
--- /dev/null
+++ b/sip/kwidgetsaddons/kpagewidget.sip
@@ -0,0 +1,44 @@
+// 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 KPageWidget : KPageView
+{
+%TypeHeaderCode
+#include <kpagewidget.h>
+%End
+
+public:
+ explicit KPageWidget (QWidget* parent = 0);
+ ~KPageWidget ();
+ KPageWidgetItem* addPage (QWidget* widget, const QString& name);
+ void addPage (KPageWidgetItem* item);
+ KPageWidgetItem* insertPage (KPageWidgetItem* before, QWidget* widget, const QString& name);
+ void insertPage (KPageWidgetItem* before, KPageWidgetItem* item);
+ KPageWidgetItem* addSubPage (KPageWidgetItem* parent, QWidget* widget, const QString& name);
+ void addSubPage (KPageWidgetItem* parent, KPageWidgetItem* item);
+ void removePage (KPageWidgetItem* item);
+ void setCurrentPage (KPageWidgetItem* item);
+ KPageWidgetItem* currentPage () const;
+signals:
+ void currentPageChanged (KPageWidgetItem* current, KPageWidgetItem* before);
+ void pageToggled (KPageWidgetItem* page, bool checked);
+ void pageRemoved (KPageWidgetItem* page);
+protected:
+//ig KPageWidget (KPageWidgetPrivate& dd, QWidget* parent);
+};
diff --git a/sip/kwidgetsaddons/kpagewidgetmodel.sip b/sip/kwidgetsaddons/kpagewidgetmodel.sip
new file mode 100644
index 0000000..dcf883e
--- /dev/null
+++ b/sip/kwidgetsaddons/kpagewidgetmodel.sip
@@ -0,0 +1,74 @@
+// 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 KPageWidgetItem : QObject
+{
+%TypeHeaderCode
+#include <kpagewidgetmodel.h>
+%End
+
+public:
+ KPageWidgetItem (QWidget* widget);
+ KPageWidgetItem (QWidget* widget, const QString& name);
+ ~KPageWidgetItem ();
+ QWidget* widget () const;
+ void setName (const QString& name);
+ QString name () const;
+ void setHeader (const QString& header);
+ QString header () const;
+ void setIcon (const QIcon& icon);
+ QIcon icon () const;
+ void setCheckable (bool checkable);
+ bool isCheckable () const;
+ bool isChecked () const;
+ bool isEnabled () const;
+ void setEnabled (bool);
+ void setChecked (bool checked);
+signals:
+ void changed ();
+ void toggled (bool checked);
+};
+class KPageWidgetModel : KPageModel
+{
+%TypeHeaderCode
+#include <kpagewidgetmodel.h>
+%End
+
+public:
+ explicit KPageWidgetModel (QObject* parent = 0);
+ ~KPageWidgetModel ();
+ KPageWidgetItem* addPage (QWidget* widget, const QString& name);
+ void addPage (KPageWidgetItem* item);
+ KPageWidgetItem* insertPage (KPageWidgetItem* before, QWidget* widget, const QString& name);
+ void insertPage (KPageWidgetItem* before, KPageWidgetItem* item);
+ KPageWidgetItem* addSubPage (KPageWidgetItem* parent, QWidget* widget, const QString& name);
+ void addSubPage (KPageWidgetItem* parent, KPageWidgetItem* item);
+ void removePage (KPageWidgetItem* item);
+ virtual int columnCount (const QModelIndex& parent = QModelIndex()) const;
+ virtual QVariant data (const QModelIndex& index, int role = Qt::DisplayRole) const;
+ virtual bool setData (const QModelIndex& index, const QVariant& value, int role = \
Qt::EditRole); + virtual Qt::ItemFlags flags (const QModelIndex& index) const;
+ virtual QModelIndex index (int row, int column, const QModelIndex& parent = QModelIndex()) \
const; + virtual QModelIndex parent (const QModelIndex& index) const;
+ virtual int rowCount (const QModelIndex& parent = QModelIndex()) const;
+ KPageWidgetItem* item (const QModelIndex& index) const;
+ QModelIndex index (const KPageWidgetItem* item) const;
+signals:
+ void toggled (KPageWidgetItem* page, bool checked);
+};
diff --git a/sip/kwidgetsaddons/kpassworddialog.sip b/sip/kwidgetsaddons/kpassworddialog.sip
new file mode 100644
index 0000000..6e3a676
--- /dev/null
+++ b/sip/kwidgetsaddons/kpassworddialog.sip
@@ -0,0 +1,73 @@
+// 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 KPasswordDialog : QDialog
+{
+%TypeHeaderCode
+#include <kpassworddialog.h>
+%End
+
+public:
+ enum KPasswordDialogFlag
+ {
+ NoFlags,
+ ShowKeepPassword,
+ ShowUsernameLine,
+ UsernameReadOnly,
+ ShowAnonymousLoginCheckBox,
+ ShowDomainLine,
+ DomainReadOnly
+ };
+ typedef QFlags<KPasswordDialog::KPasswordDialogFlag> KPasswordDialogFlags;
+ enum ErrorType
+ {
+ UnknownError,
+ UsernameError,
+ PasswordError,
+ FatalError,
+ DomainError
+ };
+ explicit KPasswordDialog (QWidget* parent = 0L, const \
KPasswordDialog::KPasswordDialogFlags& flags = 0); + ~KPasswordDialog ();
+ void setPrompt (const QString& prompt);
+ QString prompt () const;
+ void setPixmap (const QPixmap&);
+ QPixmap pixmap () const;
+ void addCommentLine (const QString& label, const QString& comment);
+ void showErrorMessage (const QString& message, const KPasswordDialog::ErrorType \
type = KPasswordDialog::ErrorType::PasswordError); + QString password () const;
+ void setUsername (const QString&);
+ QString username () const;
+ void setDomain (const QString&);
+ QString domain () const;
+ void setAnonymousMode (bool anonymous);
+ bool anonymousMode () const;
+ bool keepPassword () const;
+ void setKeepPassword (bool b);
+ void setUsernameReadOnly (bool readOnly);
+ void setPassword (const QString& password);
+ void setKnownLogins (const QMap<QString,QString>& knownLogins);
+ void accept ();
+ QDialogButtonBox* buttonBox () const;
+signals:
+ void gotPassword (const QString& password, bool keep);
+ void gotUsernameAndPassword (const QString& username, const QString& password, \
bool keep); +protected:
+ virtual bool checkPassword ();
+};
diff --git a/sip/solid/networkshare.sip b/sip/kwidgetsaddons/kpixmapregionselectordialog.sip
similarity index 51%
copy from sip/solid/networkshare.sip
copy to sip/kwidgetsaddons/kpixmapregionselectordialog.sip
index aeb8343..011f1aa 100644
--- a/sip/solid/networkshare.sip
+++ b/sip/kwidgetsaddons/kpixmapregionselectordialog.sip
@@ -17,26 +17,19 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-namespace Solid
-{
-class NetworkShare : Solid::DeviceInterface
+class KPixmapRegionSelectorDialog : QDialog
{
%TypeHeaderCode
-#include <networkshare.h>
+#include <kpixmapregionselectordialog.h>
%End
- explicit NetworkShare (QObject* backendObject);
public:
- virtual ~NetworkShare ();
- enum ShareType
- {
- Unknown,
- Nfs,
- Cifs,
- Upnp
- };
- static Solid::DeviceInterface::Type deviceInterfaceType ();
- Solid::NetworkShare::ShareType type () const;
- QUrl url () const;
-};
+ explicit KPixmapRegionSelectorDialog (QWidget* parent = 0);
+ ~KPixmapRegionSelectorDialog ();
+ KPixmapRegionSelectorWidget* pixmapRegionSelectorWidget () const;
+ static QRect getSelectedRegion (const QPixmap& pixmap, QWidget* parent = 0L);
+ static QRect getSelectedRegion (const QPixmap& pixmap, int aspectRatioWidth, int \
aspectRatioHeight, QWidget* parent = 0L); + static QImage getSelectedImage (const QPixmap& \
pixmap, QWidget* parent = 0L); + static QImage getSelectedImage (const QPixmap& pixmap, int \
aspectRatioWidth, int aspectRatioHeight, QWidget* parent = 0L); + void \
adjustRegionSelectorWidgetSizeToFitScreen (); };
diff --git a/sip/kwidgetsaddons/kpixmapregionselectorwidget.sip \
b/sip/kwidgetsaddons/kpixmapregionselectorwidget.sip new file mode 100644
index 0000000..01b03c9
--- /dev/null
+++ b/sip/kwidgetsaddons/kpixmapregionselectorwidget.sip
@@ -0,0 +1,52 @@
+// 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 KPixmapRegionSelectorWidget : QWidget
+{
+%TypeHeaderCode
+#include <kpixmapregionselectorwidget.h>
+%End
+
+public:
+ enum RotateDirection
+ {
+ Rotate90,
+ Rotate180,
+ Rotate270
+ };
+ explicit KPixmapRegionSelectorWidget (QWidget* parent = 0);
+ ~KPixmapRegionSelectorWidget ();
+ void setPixmap (const QPixmap& pixmap);
+ QPixmap pixmap () const;
+ void setSelectedRegion (const QRect& rect);
+ QRect selectedRegion () const;
+ QRect unzoomedSelectedRegion () const;
+ void resetSelection ();
+ QImage selectedImage () const;
+ void setSelectionAspectRatio (int width, int height);
+ void setFreeSelectionAspectRatio ();
+ void setMaximumWidgetSize (int width, int height);
+ void rotate (KPixmapRegionSelectorWidget::RotateDirection direction);
+ void rotateClockwise ();
+ void rotateCounterclockwise ();
+signals:
+ void pixmapRotated ();
+protected:
+ virtual QMenu* createPopupMenu ();
+};
diff --git a/sip/solid/networkshare.sip b/sip/kwidgetsaddons/kpixmapsequence.sip
similarity index 54%
copy from sip/solid/networkshare.sip
copy to sip/kwidgetsaddons/kpixmapsequence.sip
index aeb8343..ac75b74 100644
--- a/sip/solid/networkshare.sip
+++ b/sip/kwidgetsaddons/kpixmapsequence.sip
@@ -17,26 +17,22 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-namespace Solid
-{
-class NetworkShare : Solid::DeviceInterface
+class KPixmapSequence
{
%TypeHeaderCode
-#include <networkshare.h>
+#include <kpixmapsequence.h>
%End
- explicit NetworkShare (QObject* backendObject);
public:
- virtual ~NetworkShare ();
- enum ShareType
- {
- Unknown,
- Nfs,
- Cifs,
- Upnp
- };
- static Solid::DeviceInterface::Type deviceInterfaceType ();
- Solid::NetworkShare::ShareType type () const;
- QUrl url () const;
-};
+ KPixmapSequence ();
+ KPixmapSequence (const KPixmapSequence& other);
+ explicit KPixmapSequence (const QPixmap& pixmap, const QSize& frameSize = QSize());
+ KPixmapSequence (const QString& fullPath, int size);
+ ~KPixmapSequence ();
+ bool isValid () const;
+ bool isEmpty () const;
+ QSize frameSize () const;
+ int frameCount () const;
+ QPixmap frameAt (int index) const;
+//ig KPixmapSequence& operator= (const KPixmapSequence& other);
};
diff --git a/sip/kwidgetsaddons/kpixmapsequenceoverlaypainter.sip \
b/sip/kwidgetsaddons/kpixmapsequenceoverlaypainter.sip new file mode 100644
index 0000000..265d15c
--- /dev/null
+++ b/sip/kwidgetsaddons/kpixmapsequenceoverlaypainter.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 KPixmapSequenceOverlayPainter : QObject
+{
+%TypeHeaderCode
+#include <kpixmapsequenceoverlaypainter.h>
+%End
+
+public:
+ KPixmapSequenceOverlayPainter (QObject* parent = 0);
+ KPixmapSequenceOverlayPainter (const KPixmapSequence& seq, QObject* parent = \
0); + ~KPixmapSequenceOverlayPainter ();
+ KPixmapSequence sequence () const;
+ int interval () const;
+ QRect rect () const;
+ Qt::Alignment alignment () const;
+ QPoint offset () const;
+ void setSequence (const KPixmapSequence& seq);
+ void setInterval (int msecs);
+ void setWidget (QWidget* w);
+ void setRect (const QRect& rect);
+ void setAlignment (Qt::Alignment align);
+ void setOffset (const QPoint& offset);
+ void start ();
+ void stop ();
+};
diff --git a/sip/solid/networkshare.sip b/sip/kwidgetsaddons/kpixmapsequencewidget.sip
similarity index 61%
copy from sip/solid/networkshare.sip
copy to sip/kwidgetsaddons/kpixmapsequencewidget.sip
index aeb8343..3a0eda1 100644
--- a/sip/solid/networkshare.sip
+++ b/sip/kwidgetsaddons/kpixmapsequencewidget.sip
@@ -17,26 +17,19 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-namespace Solid
-{
-class NetworkShare : Solid::DeviceInterface
+class KPixmapSequenceWidget : QWidget
{
%TypeHeaderCode
-#include <networkshare.h>
+#include <kpixmapsequencewidget.h>
%End
- explicit NetworkShare (QObject* backendObject);
public:
- virtual ~NetworkShare ();
- enum ShareType
- {
- Unknown,
- Nfs,
- Cifs,
- Upnp
- };
- static Solid::DeviceInterface::Type deviceInterfaceType ();
- Solid::NetworkShare::ShareType type () const;
- QUrl url () const;
-};
+ KPixmapSequenceWidget (QWidget* parent = 0);
+ KPixmapSequenceWidget (const KPixmapSequence& seq, QWidget* parent = 0);
+ ~KPixmapSequenceWidget ();
+ KPixmapSequence sequence () const;
+ int interval () const;
+ QSize sizeHint () const;
+ void setSequence (const KPixmapSequence& seq);
+ void setInterval (int msecs);
};
diff --git a/sip/solid/networkshare.sip b/sip/kwidgetsaddons/kpopupframe.sip
similarity index 57%
copy from sip/solid/networkshare.sip
copy to sip/kwidgetsaddons/kpopupframe.sip
index aeb8343..210482b 100644
--- a/sip/solid/networkshare.sip
+++ b/sip/kwidgetsaddons/kpopupframe.sip
@@ -17,26 +17,24 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-namespace Solid
-{
-class NetworkShare : Solid::DeviceInterface
+class KPopupFrame : QFrame
{
%TypeHeaderCode
-#include <networkshare.h>
+#include <kpopupframe.h>
%End
- explicit NetworkShare (QObject* backendObject);
+protected:
+ virtual void keyPressEvent (QKeyEvent* e);
+ virtual void hideEvent (QHideEvent* e);
public:
- virtual ~NetworkShare ();
- enum ShareType
- {
- Unknown,
- Nfs,
- Cifs,
- Upnp
- };
- static Solid::DeviceInterface::Type deviceInterfaceType ();
- Solid::NetworkShare::ShareType type () const;
- QUrl url () const;
-};
+ void close (int r);
+ KPopupFrame (QWidget* parent = 0);
+ ~KPopupFrame ();
+ void setMainWidget (QWidget* m);
+ virtual void resizeEvent (QResizeEvent* resize);
+ void popup (const QPoint& pos);
+ int exec (const QPoint& p);
+ int exec (int x, int y);
+signals:
+ void leaveModality ();
};
diff --git a/sip/kwidgetsaddons/kratingpainter.sip b/sip/kwidgetsaddons/kratingpainter.sip
new file mode 100644
index 0000000..a3cf96f
--- /dev/null
+++ b/sip/kwidgetsaddons/kratingpainter.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.
+
+class KRatingPainter /NoDefaultCtors/
+{
+%TypeHeaderCode
+#include <kratingpainter.h>
+%End
+
+public:
+ KRatingPainter ();
+ ~KRatingPainter ();
+ int maxRating () const;
+ bool halfStepsEnabled () const;
+ Qt::Alignment alignment () const;
+ Qt::LayoutDirection layoutDirection () const;
+ QIcon icon () const;
+ bool isEnabled () const;
+ QPixmap customPixmap () const;
+ int spacing () const;
+ void setMaxRating (int max);
+ void setHalfStepsEnabled (bool enabled);
+ void setAlignment (Qt::Alignment align);
+ void setLayoutDirection (Qt::LayoutDirection direction);
+ void setIcon (const QIcon& icon);
+ void setEnabled (bool enabled);
+ void setCustomPixmap (const QPixmap& pixmap);
+ void setSpacing (int spacing);
+ void paint (QPainter* painter, const QRect& rect, int rating, int hoverRating = \
-1) const; + int ratingFromPosition (const QRect& rect, const QPoint& pos) const;
+ static void paintRating (QPainter* p, const QRect& rect, Qt::Alignment align, int \
rating, int hoverRating = -1); + static int getRatingFromPosition (const QRect& rect, \
Qt::Alignment align, Qt::LayoutDirection direction, const QPoint& pos); +};
diff --git a/sip/kwidgetsaddons/kratingwidget.sip b/sip/kwidgetsaddons/kratingwidget.sip
new file mode 100644
index 0000000..2ba23a6
--- /dev/null
+++ b/sip/kwidgetsaddons/kratingwidget.sip
@@ -0,0 +1,56 @@
+// 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 KRatingWidget : QFrame
+{
+%TypeHeaderCode
+#include <kratingwidget.h>
+%End
+
+public:
+ KRatingWidget (QWidget* parent = 0);
+ ~KRatingWidget ();
+ unsigned int rating () const;
+ int maxRating () const;
+ Qt::Alignment alignment () const;
+ Qt::LayoutDirection layoutDirection () const;
+ int spacing () const;
+ QSize sizeHint () const;
+ bool halfStepsEnabled () const;
+ QIcon icon () const;
+signals:
+//ig void ratingChanged (unsigned int rating);
+ void ratingChanged (int rating);
+public:
+ void setRating (int rating);
+ void setMaxRating (int max);
+ void setHalfStepsEnabled (bool enabled);
+ void setSpacing (int);
+ void setAlignment (Qt::Alignment align);
+ void setLayoutDirection (Qt::LayoutDirection direction);
+ void setIcon (const QIcon& icon);
+ void setCustomPixmap (const QPixmap& pixmap);
+ void setPixmapSize (int size);
+protected:
+ void mousePressEvent (QMouseEvent* e);
+ void mouseMoveEvent (QMouseEvent* e);
+ void leaveEvent (QEvent* e);
+ void paintEvent (QPaintEvent* e);
+ void resizeEvent (QResizeEvent* e);
+};
diff --git a/sip/kwidgetsaddons/kruler.sip b/sip/kwidgetsaddons/kruler.sip
new file mode 100644
index 0000000..03d14b1
--- /dev/null
+++ b/sip/kwidgetsaddons/kruler.sip
@@ -0,0 +1,82 @@
+// 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 KRuler : QAbstractSlider
+{
+%TypeHeaderCode
+#include <kruler.h>
+%End
+
+public:
+ enum MetricStyle
+ {
+ Custom,
+ Pixel,
+ Inch,
+ Millimetres,
+ Centimetres,
+ Metres
+ };
+ explicit KRuler (QWidget* parent = 0);
+ explicit KRuler (Qt::Orientation orient, QWidget* parent = 0, Qt::WindowFlags f = 0);
+ KRuler (Qt::Orientation orient, int widgetWidth, QWidget* parent = 0, \
Qt::WindowFlags f = 0); + ~KRuler ();
+ void setTinyMarkDistance (int);
+ int tinyMarkDistance () const;
+ void setLittleMarkDistance (int);
+ int littleMarkDistance () const;
+ void setMediumMarkDistance (int);
+ int mediumMarkDistance () const;
+ void setBigMarkDistance (int);
+ int bigMarkDistance () const;
+ void setShowTinyMarks (bool);
+ bool showTinyMarks () const;
+ void setShowLittleMarks (bool);
+ bool showLittleMarks () const;
+ void setShowMediumMarks (bool);
+ bool showMediumMarks () const;
+ void setShowBigMarks (bool);
+ bool showBigMarks () const;
+ void setShowEndMarks (bool);
+ bool showEndMarks () const;
+ void setShowPointer (bool);
+ bool showPointer () const;
+ void setFrameStyle (int);
+ void setShowEndLabel (bool);
+ bool showEndLabel () const;
+ void setEndLabel (const QString&);
+ QString endLabel () const;
+ void setRulerMetricStyle (KRuler::MetricStyle);
+ void setPixelPerMark (double rate);
+ double pixelPerMark () const;
+ void setLength (int);
+ int length () const;
+ void setLengthFixed (bool fix);
+ bool lengthFixed () const;
+ void slideUp (int count = 1);
+ void slideDown (int count = 1);
+ void setOffset (int offset);
+ int offset () const;
+ int endOffset () const;
+ void slotNewValue (int);
+ void slotNewOffset (int);
+ void slotEndOffset (int);
+protected:
+ virtual void paintEvent (QPaintEvent*);
+};
diff --git a/sip/kwidgetsaddons/kselectaction.sip b/sip/kwidgetsaddons/kselectaction.sip
new file mode 100644
index 0000000..37e59f9
--- /dev/null
+++ b/sip/kwidgetsaddons/kselectaction.sip
@@ -0,0 +1,79 @@
+// 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 KSelectAction : QWidgetAction
+{
+%TypeHeaderCode
+#include <kselectaction.h>
+%End
+
+public:
+ explicit KSelectAction (QObject* parent);
+ KSelectAction (const QString& text, QObject* parent);
+ KSelectAction (const QIcon& icon, const QString& text, QObject* parent);
+ virtual ~KSelectAction ();
+ enum ToolBarMode
+ {
+ MenuMode,
+ ComboBoxMode
+ };
+ KSelectAction::ToolBarMode toolBarMode () const;
+ void setToolBarMode (KSelectAction::ToolBarMode mode);
+ QToolButton::ToolButtonPopupMode toolButtonPopupMode () const;
+ void setToolButtonPopupMode (QToolButton::ToolButtonPopupMode mode);
+ QActionGroup* selectableActionGroup () const;
+ QAction* currentAction () const;
+ int currentItem () const;
+ QString currentText () const;
+ QList<QAction*> actions () const;
+ QAction* action (int index) const;
+ QAction* action (const QString& text, Qt::CaseSensitivity cs = Qt::CaseSensitive) \
const; + bool setCurrentAction (QAction* action);
+ bool setCurrentItem (int index);
+ bool setCurrentAction (const QString& text, Qt::CaseSensitivity cs = \
Qt::CaseSensitive); + void addAction (QAction* action);
+ QAction* addAction (const QString& text);
+ QAction* addAction (const QIcon& icon, const QString& text);
+ virtual QAction* removeAction (QAction* action);
+ virtual void insertAction (QAction* before, QAction* action);
+ void setItems (const QStringList& lst);
+ QStringList items () const;
+ bool isEditable () const;
+ void setEditable (bool);
+ int comboWidth () const;
+ void setComboWidth (int width);
+ void setMaxComboViewCount (int n);
+ void clear ();
+ void removeAllActions ();
+ void setMenuAccelsEnabled (bool b);
+ bool menuAccelsEnabled () const;
+ void changeItem (int index, const QString& text);
+signals:
+ void triggered (QAction* action);
+ void triggered (int index);
+ void triggered (const QString& text);
+protected:
+ virtual void actionTriggered (QAction* action);
+ void slotToggled (bool);
+ virtual QWidget* createWidget (QWidget* parent);
+ virtual void deleteWidget (QWidget* widget);
+ virtual bool event (QEvent* event);
+ virtual bool eventFilter (QObject* watched, QEvent* event);
+//ig KSelectAction (KSelectActionPrivate& dd, QObject* parent);
+};
diff --git a/sip/kwidgetsaddons/kselector.sip b/sip/kwidgetsaddons/kselector.sip
new file mode 100644
index 0000000..31d696a
--- /dev/null
+++ b/sip/kwidgetsaddons/kselector.sip
@@ -0,0 +1,69 @@
+// 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 KSelector : QAbstractSlider
+{
+%TypeHeaderCode
+#include <kselector.h>
+%End
+
+public:
+ explicit KSelector (QWidget* parent = 0);
+ explicit KSelector (Qt::Orientation o, QWidget* parent = 0);
+ ~KSelector ();
+ QRect contentsRect () const;
+ void setIndent (bool i);
+ bool indent () const;
+ void setArrowDirection (Qt::ArrowType direction);
+ Qt::ArrowType arrowDirection () const;
+protected:
+ virtual void drawContents (QPainter*);
+ virtual void drawArrow (QPainter* painter, const QPoint& pos);
+ virtual void paintEvent (QPaintEvent*);
+ virtual void mousePressEvent (QMouseEvent* e);
+ virtual void mouseMoveEvent (QMouseEvent* e);
+ virtual void mouseReleaseEvent (QMouseEvent* e);
+ virtual void wheelEvent (QWheelEvent*);
+};
+class KGradientSelector : KSelector
+{
+%TypeHeaderCode
+#include <kselector.h>
+%End
+
+public:
+ explicit KGradientSelector (QWidget* parent = 0);
+ explicit KGradientSelector (Qt::Orientation o, QWidget* parent = 0);
+ ~KGradientSelector ();
+ void setStops (const QGradientStops& stops);
+ QGradientStops stops () const;
+ void setColors (const QColor& col1, const QColor& col2);
+ void setText (const QString& t1, const QString& t2);
+ void setFirstColor (const QColor& col);
+ void setSecondColor (const QColor& col);
+ void setFirstText (const QString& t);
+ void setSecondText (const QString& t);
+ QColor firstColor () const;
+ QColor secondColor () const;
+ QString firstText () const;
+ QString secondText () const;
+protected:
+ virtual void drawContents (QPainter*);
+ virtual QSize minimumSize () const;
+};
diff --git a/sip/kcoreaddons/kfilesystemtype_p.sip b/sip/kwidgetsaddons/kseparator.sip
similarity index 67%
copy from sip/kcoreaddons/kfilesystemtype_p.sip
copy to sip/kwidgetsaddons/kseparator.sip
index fa655a8..9dd4eb0 100644
--- a/sip/kcoreaddons/kfilesystemtype_p.sip
+++ b/sip/kwidgetsaddons/kseparator.sip
@@ -17,20 +17,15 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-%ModuleHeaderCode
-#include <kfilesystemtype_p.h>
+class KSeparator : QFrame
+{
+%TypeHeaderCode
+#include <kseparator.h>
%End
-namespace KFileSystemType
-{
-enum Type
-{
- Unknown,
- Nfs,
- Smb,
- Fat,
- Ramfs,
- Other
-};
-KFileSystemType::Type fileSystemType (const QString& path);
+public:
+ explicit KSeparator (QWidget* parent = 0, Qt::WindowFlags f = 0);
+ explicit KSeparator (Qt::Orientation orientation, QWidget* parent = 0, \
Qt::WindowFlags f = 0); + Qt::Orientation orientation () const;
+ void setOrientation (Qt::Orientation orientation);
};
diff --git a/sip/kwidgetsaddons/ksqueezedtextlabel.sip b/sip/kwidgetsaddons/ksqueezedtextlabel.sip
new file mode 100644
index 0000000..c844bfb
--- /dev/null
+++ b/sip/kwidgetsaddons/ksqueezedtextlabel.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 KSqueezedTextLabel : QLabel
+{
+%TypeHeaderCode
+#include <ksqueezedtextlabel.h>
+%End
+
+public:
+ explicit KSqueezedTextLabel (QWidget* parent = 0);
+ explicit KSqueezedTextLabel (const QString& text, QWidget* parent = 0);
+ virtual ~KSqueezedTextLabel ();
+ virtual QSize minimumSizeHint () const;
+ virtual QSize sizeHint () const;
+ virtual void setAlignment (Qt::Alignment);
+ Qt::TextElideMode textElideMode () const;
+ void setTextElideMode (Qt::TextElideMode mode);
+ QString fullText () const;
+ void setText (const QString& text);
+ void clear ();
+protected:
+ void mouseReleaseEvent (QMouseEvent*);
+ void resizeEvent (QResizeEvent*);
+ void contextMenuEvent (QContextMenuEvent*);
+ void squeezeTextToLabel ();
+};
diff --git a/sip/kwidgetsaddons/kstandardguiitem.sip b/sip/kwidgetsaddons/kstandardguiitem.sip
new file mode 100644
index 0000000..42985e3
--- /dev/null
+++ b/sip/kwidgetsaddons/kstandardguiitem.sip
@@ -0,0 +1,104 @@
+// 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 <kstandardguiitem.h>
+%End
+
+namespace KStandardGuiItem
+{
+enum BidiMode
+{
+ UseRTL,
+ IgnoreRTL
+};
+enum StandardItem
+{
+ Ok,
+ Cancel,
+ Yes,
+ No,
+ Discard,
+ Save,
+ DontSave,
+ SaveAs,
+ Apply,
+ Clear,
+ Help,
+ Defaults,
+ Close,
+ Back,
+ Forward,
+ Print,
+ Continue,
+ Open,
+ Quit,
+ AdminMode,
+ Reset,
+ Delete,
+ Insert,
+ Configure,
+ Find,
+ Stop,
+ Add,
+ Remove,
+ Test,
+ Properties,
+ Overwrite,
+ CloseWindow,
+ CloseDocument
+};
+KGuiItem guiItem (KStandardGuiItem::StandardItem id);
+QString standardItem (KStandardGuiItem::StandardItem id);
+KGuiItem ok ();
+KGuiItem cancel ();
+KGuiItem yes ();
+KGuiItem no ();
+KGuiItem insert ();
+KGuiItem discard ();
+KGuiItem save ();
+KGuiItem help ();
+KGuiItem dontSave ();
+KGuiItem saveAs ();
+KGuiItem apply ();
+KGuiItem clear ();
+KGuiItem defaults ();
+KGuiItem close ();
+KGuiItem closeWindow ();
+KGuiItem closeDocument ();
+KGuiItem print ();
+KGuiItem properties ();
+KGuiItem reset ();
+KGuiItem overwrite ();
+KGuiItem adminMode ();
+KGuiItem cont ();
+KGuiItem del ();
+KGuiItem open ();
+KGuiItem back (KStandardGuiItem::BidiMode useBidi = \
KStandardGuiItem::BidiMode::IgnoreRTL); +KGuiItem forward (KStandardGuiItem::BidiMode \
useBidi = KStandardGuiItem::BidiMode::IgnoreRTL); +KGuiItem configure ();
+//ig QPair<KGuiItem,KGuiItem> backAndForward ();
+KGuiItem quit ();
+KGuiItem find ();
+KGuiItem stop ();
+KGuiItem add ();
+KGuiItem remove ();
+KGuiItem test ();
+void assign (QPushButton* button, KStandardGuiItem::StandardItem item);
+};
diff --git a/sip/kwidgetsaddons/ktimecombobox.sip b/sip/kwidgetsaddons/ktimecombobox.sip
new file mode 100644
index 0000000..2384cb1
--- /dev/null
+++ b/sip/kwidgetsaddons/ktimecombobox.sip
@@ -0,0 +1,73 @@
+// 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 KTimeComboBox : QComboBox
+{
+%TypeHeaderCode
+#include <ktimecombobox.h>
+%End
+
+public:
+ enum Option
+ {
+ EditTime,
+ SelectTime,
+ ForceTime,
+ WarnOnInvalid
+ };
+ typedef QFlags<KTimeComboBox::Option> Options;
+ explicit KTimeComboBox (QWidget* parent = 0);
+ virtual ~KTimeComboBox ();
+ QTime time () const;
+ bool isValid () const;
+ bool isNull () const;
+ KTimeComboBox::Options options () const;
+ QLocale::FormatType displayFormat () const;
+ QTime minimumTime () const;
+ void resetMinimumTime ();
+ QTime maximumTime () const;
+ void resetMaximumTime ();
+ void setTimeRange (const QTime& minTime, const QTime& maxTime, const QString& \
minWarnMsg = QString(), const QString& maxWarnMsg = QString()); + void \
resetTimeRange (); + int timeListInterval () const;
+ QList<QTime> timeList () const;
+signals:
+ void timeEntered (const QTime& time);
+ void timeChanged (const QTime& time);
+ void timeEdited (const QTime& time);
+public:
+ void setTime (const QTime& time);
+ void setOptions (KTimeComboBox::Options options);
+ void setDisplayFormat (QLocale::FormatType formatOptions);
+ void setMinimumTime (const QTime& minTime, const QString& minWarnMsg = \
QString()); + void setMaximumTime (const QTime& maxTime, const QString& maxWarnMsg \
= QString()); + void setTimeListInterval (int minutes);
+ void setTimeList (QList<QTime> timeList, const QString& minWarnMsg = QString(), \
const QString& maxWarnMsg = QString()); +protected:
+ virtual bool eventFilter (QObject* object, QEvent* event);
+ virtual void showPopup ();
+ virtual void hidePopup ();
+ virtual void mousePressEvent (QMouseEvent* event);
+ virtual void wheelEvent (QWheelEvent* event);
+ virtual void keyPressEvent (QKeyEvent* event);
+ virtual void focusInEvent (QFocusEvent* event);
+ virtual void focusOutEvent (QFocusEvent* event);
+ virtual void resizeEvent (QResizeEvent* event);
+ virtual void assignTime (const QTime& time);
+};
diff --git a/sip/kwidgetsaddons/ktitlewidget.sip b/sip/kwidgetsaddons/ktitlewidget.sip
new file mode 100644
index 0000000..84244f1
--- /dev/null
+++ b/sip/kwidgetsaddons/ktitlewidget.sip
@@ -0,0 +1,59 @@
+// 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 KTitleWidget : QWidget
+{
+%TypeHeaderCode
+#include <ktitlewidget.h>
+%End
+
+public:
+ enum ImageAlignment
+ {
+ ImageLeft,
+ ImageRight
+ };
+ enum MessageType
+ {
+ PlainMessage,
+ InfoMessage,
+ WarningMessage,
+ ErrorMessage
+ };
+ explicit KTitleWidget (QWidget* parent = 0);
+ virtual ~KTitleWidget ();
+ void setWidget (QWidget* widget);
+ QString text () const;
+ QString comment () const;
+ const QPixmap* pixmap () const;
+ void setBuddy (QWidget* buddy);
+ int autoHideTimeout () const;
+ void setText (const QString& text, Qt::Alignment alignment = \
Qt::AlignLeft|Qt::AlignVCenter); + void setText (const QString& text, \
KTitleWidget::MessageType type); + void setComment (const QString& comment, \
KTitleWidget::MessageType type = KTitleWidget::MessageType::PlainMessage); + void \
setPixmap (const QPixmap& pixmap, KTitleWidget::ImageAlignment alignment = \
KTitleWidget::ImageAlignment::ImageRight); + void setPixmap (const QString& icon, \
KTitleWidget::ImageAlignment alignment = KTitleWidget::ImageAlignment::ImageRight); + void \
setPixmap (const QIcon& icon, KTitleWidget::ImageAlignment alignment = \
KTitleWidget::ImageAlignment::ImageRight); + void setPixmap \
(KTitleWidget::MessageType type, KTitleWidget::ImageAlignment alignment = \
KTitleWidget::ImageAlignment::ImageRight); + void setAutoHideTimeout (int msecs);
+protected:
+ void changeEvent (QEvent* e);
+ void showEvent (QShowEvent* event);
+ bool eventFilter (QObject* object, QEvent* event);
+};
diff --git a/sip/solid/networkshare.sip b/sip/kwidgetsaddons/ktoggleaction.sip
similarity index 64%
copy from sip/solid/networkshare.sip
copy to sip/kwidgetsaddons/ktoggleaction.sip
index aeb8343..2c0a5d7 100644
--- a/sip/solid/networkshare.sip
+++ b/sip/kwidgetsaddons/ktoggleaction.sip
@@ -17,26 +17,18 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-namespace Solid
-{
-class NetworkShare : Solid::DeviceInterface
+class KToggleAction : QAction
{
%TypeHeaderCode
-#include <networkshare.h>
+#include <ktoggleaction.h>
%End
- explicit NetworkShare (QObject* backendObject);
public:
- virtual ~NetworkShare ();
- enum ShareType
- {
- Unknown,
- Nfs,
- Cifs,
- Upnp
- };
- static Solid::DeviceInterface::Type deviceInterfaceType ();
- Solid::NetworkShare::ShareType type () const;
- QUrl url () const;
-};
+ explicit KToggleAction (QObject* parent);
+ KToggleAction (const QString& text, QObject* parent);
+ KToggleAction (const QIcon& icon, const QString& text, QObject* parent);
+ virtual ~KToggleAction ();
+ void setCheckedState (const KGuiItem& checkedItem);
+protected:
+ virtual void slotToggled (bool checked);
};
diff --git a/sip/solid/networkshare.sip b/sip/kwidgetsaddons/ktogglefullscreenaction.sip
similarity index 63%
copy from sip/solid/networkshare.sip
copy to sip/kwidgetsaddons/ktogglefullscreenaction.sip
index aeb8343..345167a 100644
--- a/sip/solid/networkshare.sip
+++ b/sip/kwidgetsaddons/ktogglefullscreenaction.sip
@@ -17,26 +17,18 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-namespace Solid
-{
-class NetworkShare : Solid::DeviceInterface
+class KToggleFullScreenAction : KToggleAction
{
%TypeHeaderCode
-#include <networkshare.h>
+#include <ktogglefullscreenaction.h>
%End
- explicit NetworkShare (QObject* backendObject);
public:
- virtual ~NetworkShare ();
- enum ShareType
- {
- Unknown,
- Nfs,
- Cifs,
- Upnp
- };
- static Solid::DeviceInterface::Type deviceInterfaceType ();
- Solid::NetworkShare::ShareType type () const;
- QUrl url () const;
-};
+ explicit KToggleFullScreenAction (QObject* parent);
+ KToggleFullScreenAction (QWidget* window, QObject* parent);
+ virtual ~KToggleFullScreenAction ();
+ void setWindow (QWidget* window);
+ static void setFullScreen (QWidget* window, bool set);
+protected:
+ bool eventFilter (QObject* object, QEvent* event);
};
diff --git a/sip/solid/networkshare.sip b/sip/kwidgetsaddons/ktoolbarlabelaction.sip
similarity index 55%
copy from sip/solid/networkshare.sip
copy to sip/kwidgetsaddons/ktoolbarlabelaction.sip
index aeb8343..74b7407 100644
--- a/sip/solid/networkshare.sip
+++ b/sip/kwidgetsaddons/ktoolbarlabelaction.sip
@@ -17,26 +17,22 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-namespace Solid
-{
-class NetworkShare : Solid::DeviceInterface
+class KToolBarLabelAction : QWidgetAction
{
%TypeHeaderCode
-#include <networkshare.h>
+#include <ktoolbarlabelaction.h>
%End
- explicit NetworkShare (QObject* backendObject);
public:
- virtual ~NetworkShare ();
- enum ShareType
- {
- Unknown,
- Nfs,
- Cifs,
- Upnp
- };
- static Solid::DeviceInterface::Type deviceInterfaceType ();
- Solid::NetworkShare::ShareType type () const;
- QUrl url () const;
-};
+ KToolBarLabelAction (const QString& text, QObject* parent);
+ KToolBarLabelAction (QAction* buddy, const QString& text, QObject* parent);
+ virtual ~KToolBarLabelAction ();
+ void setBuddy (QAction* buddy);
+ QAction* buddy () const;
+ virtual QWidget* createWidget (QWidget* parent);
+signals:
+ void textChanged (const QString& newText);
+protected:
+ virtual bool event (QEvent*);
+ virtual bool eventFilter (QObject* watched, QEvent* event);
};
diff --git a/sip/solid/networkshare.sip b/sip/kwidgetsaddons/ktoolbarpopupaction.sip
similarity index 63%
copy from sip/solid/networkshare.sip
copy to sip/kwidgetsaddons/ktoolbarpopupaction.sip
index aeb8343..783168e 100644
--- a/sip/solid/networkshare.sip
+++ b/sip/kwidgetsaddons/ktoolbarpopupaction.sip
@@ -17,26 +17,18 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-namespace Solid
-{
-class NetworkShare : Solid::DeviceInterface
+class KToolBarPopupAction : QWidgetAction
{
%TypeHeaderCode
-#include <networkshare.h>
+#include <ktoolbarpopupaction.h>
%End
- explicit NetworkShare (QObject* backendObject);
public:
- virtual ~NetworkShare ();
- enum ShareType
- {
- Unknown,
- Nfs,
- Cifs,
- Upnp
- };
- static Solid::DeviceInterface::Type deviceInterfaceType ();
- Solid::NetworkShare::ShareType type () const;
- QUrl url () const;
-};
+ KToolBarPopupAction (const QIcon& icon, const QString& text, QObject* \
parent); + virtual ~KToolBarPopupAction ();
+ bool delayed () const;
+ void setDelayed (bool delayed);
+ bool stickyMenu () const;
+ void setStickyMenu (bool sticky);
+ virtual QWidget* createWidget (QWidget* parent);
};
diff --git a/sip/kcoreaddons/kfilesystemtype_p.sip b/sip/kwidgetsaddons/ktoolbarspaceraction.sip
similarity index 75%
copy from sip/kcoreaddons/kfilesystemtype_p.sip
copy to sip/kwidgetsaddons/ktoolbarspaceraction.sip
index fa655a8..118d14c 100644
--- a/sip/kcoreaddons/kfilesystemtype_p.sip
+++ b/sip/kwidgetsaddons/ktoolbarspaceraction.sip
@@ -17,20 +17,14 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-%ModuleHeaderCode
-#include <kfilesystemtype_p.h>
+class KToolBarSpacerAction : QWidgetAction
+{
+%TypeHeaderCode
+#include <ktoolbarspaceraction.h>
%End
-namespace KFileSystemType
-{
-enum Type
-{
- Unknown,
- Nfs,
- Smb,
- Fat,
- Ramfs,
- Other
-};
-KFileSystemType::Type fileSystemType (const QString& path);
+public:
+ explicit KToolBarSpacerAction (QObject* parent);
+ virtual ~KToolBarSpacerAction ();
+ QWidget* createWidget (QWidget* parent);
};
diff --git a/sip/kwidgetsaddons/kurllabel.sip b/sip/kwidgetsaddons/kurllabel.sip
new file mode 100644
index 0000000..c2530ab
--- /dev/null
+++ b/sip/kwidgetsaddons/kurllabel.sip
@@ -0,0 +1,66 @@
+// 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 KUrlLabel : QLabel
+{
+%TypeHeaderCode
+#include <kurllabel.h>
+%End
+
+public:
+ explicit KUrlLabel (QWidget* parent = 0L);
+ explicit KUrlLabel (const QString& url, const QString& text = QString(), QWidget* \
parent = 0L); + virtual ~KUrlLabel ();
+ QString url () const;
+ QString tipText () const;
+ bool useTips () const;
+ bool useCursor () const;
+ bool isGlowEnabled () const;
+ bool isFloatEnabled () const;
+ const QPixmap* alternatePixmap () const;
+ void setUnderline (bool on = 1);
+ void setUrl (const QString& url);
+ virtual void setFont (const QFont& font);
+ void setUseTips (bool on = 1);
+ void setTipText (const QString& tip);
+ void setHighlightedColor (const QColor& highcolor);
+ void setHighlightedColor (const QString& highcolor);
+ void setSelectedColor (const QColor& color);
+ void setSelectedColor (const QString& color);
+ void setUseCursor (bool on, QCursor* cursor = 0L);
+ void setGlowEnabled (bool glow = 1);
+ void setFloatEnabled (bool do_float = 1);
+ void setAlternatePixmap (const QPixmap& pixmap);
+signals:
+ void enteredUrl (const QString& url);
+ void enteredUrl ();
+ void leftUrl (const QString& url);
+ void leftUrl ();
+ void leftClickedUrl (const QString& url);
+ void leftClickedUrl ();
+ void rightClickedUrl (const QString& url);
+ void rightClickedUrl ();
+ void middleClickedUrl (const QString& url);
+ void middleClickedUrl ();
+protected:
+ virtual void mouseReleaseEvent (QMouseEvent*);
+ virtual void enterEvent (QEvent*);
+ virtual void leaveEvent (QEvent*);
+ virtual bool event (QEvent*);
+};
diff --git a/sip/solid/networkshare.sip b/sip/kwidgetsaddons/kviewstatemaintainerbase.sip
similarity index 61%
copy from sip/solid/networkshare.sip
copy to sip/kwidgetsaddons/kviewstatemaintainerbase.sip
index aeb8343..1338a97 100644
--- a/sip/solid/networkshare.sip
+++ b/sip/kwidgetsaddons/kviewstatemaintainerbase.sip
@@ -17,26 +17,19 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-namespace Solid
-{
-class NetworkShare : Solid::DeviceInterface
+class KViewStateMaintainerBase : QObject
{
%TypeHeaderCode
-#include <networkshare.h>
+#include <kviewstatemaintainerbase.h>
%End
- explicit NetworkShare (QObject* backendObject);
public:
- virtual ~NetworkShare ();
- enum ShareType
- {
- Unknown,
- Nfs,
- Cifs,
- Upnp
- };
- static Solid::DeviceInterface::Type deviceInterfaceType ();
- Solid::NetworkShare::ShareType type () const;
- QUrl url () const;
-};
+ KViewStateMaintainerBase (QObject* parent = 0);
+ ~KViewStateMaintainerBase ();
+ void setSelectionModel (QItemSelectionModel* selectionModel);
+ QItemSelectionModel* selectionModel () const;
+ void setView (QAbstractItemView* view);
+ QAbstractItemView* view () const;
+ virtual void saveState ()=0;
+ virtual void restoreState ()=0;
};
diff --git a/sip/kwidgetsaddons/kviewstateserializer.sip b/sip/kwidgetsaddons/kviewstateserializer.sip
new file mode 100644
index 0000000..53a05a6
--- /dev/null
+++ b/sip/kwidgetsaddons/kviewstateserializer.sip
@@ -0,0 +1,45 @@
+// 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 KViewStateSerializer : QObject
+{
+%TypeHeaderCode
+#include <kviewstateserializer.h>
+%End
+
+public:
+ explicit KViewStateSerializer (QObject* parent = 0);
+ ~KViewStateSerializer ();
+ QAbstractItemView* view () const;
+ void setView (QAbstractItemView* view);
+ QItemSelectionModel* selectionModel () const;
+ void setSelectionModel (QItemSelectionModel* selectionModel);
+ QStringList selectionKeys () const;
+ QStringList expansionKeys () const;
+ QString currentIndexKey () const;
+ QPair<int,int> scrollState () const;
+ void restoreSelection (const QStringList& indexStrings);
+ void restoreCurrentItem (const QString& indexString);
+ void restoreExpanded (const QStringList& indexStrings);
+ void restoreScrollState (int verticalScoll, int horizontalScroll);
+protected:
+ virtual QModelIndex indexFromConfigString (const QAbstractItemModel* model, const QString& key) \
const=0; + virtual QString indexToConfigString (const QModelIndex& index) const=0;
+ void restoreState ();
+};
diff --git a/sip/kwidgetsaddons/kwidgetsaddonsmod.sip b/sip/kwidgetsaddons/kwidgetsaddonsmod.sip
new file mode 100644
index 0000000..ef192b7
--- /dev/null
+++ b/sip/kwidgetsaddons/kwidgetsaddonsmod.sip
@@ -0,0 +1,90 @@
+// 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.kwidgetsaddons
+
+%ModuleHeaderCode
+#pragma GCC visibility push(default)
+%End
+
+%Import typedefs.sip
+%Import QtCore/QtCoremod.sip
+%Import QtWidgets/QtWidgetsmod.sip
+
+%Include kmessagebox.sip
+%Include kmessageboxdontaskagaininterface.sip
+%Include kmessageboxnotifyinterface.sip
+%Include kstandardguiitem.sip
+%Include kacceleratormanager.sip
+%Include kactionmenu.sip
+%Include kactionselector.sip
+%Include kanimatedbutton.sip
+%Include kassistantdialog.sip
+%Include kcapacitybar.sip
+%Include kcharselect.sip
+%Include kcolorbutton.sip
+%Include kcolorcombo.sip
+%Include kcursor.sip
+%Include kdatecombobox.sip
+%Include kdatepicker.sip
+%Include kdatetimeedit.sip
+%Include kdragwidgetdecorator.sip
+%Include kdualaction.sip
+%Include keditlistwidget.sip
+%Include kfontaction.sip
+%Include kfontchooser.sip
+%Include kfontrequester.sip
+%Include kfontsizeaction.sip
+%Include kguiitem.sip
+%Include kled.sip
+%Include kmessagewidget.sip
+%Include kmimetypechooser.sip
+%Include kmultitabbar.sip
+%Include knewpassworddialog.sip
+%Include kpagedialog.sip
+%Include kpagemodel.sip
+%Include kpageview.sip
+%Include kpagewidget.sip
+%Include kpagewidgetmodel.sip
+%Include kpassworddialog.sip
+%Include kpixmapregionselectordialog.sip
+%Include kpixmapregionselectorwidget.sip
+%Include kpixmapsequence.sip
+%Include kpixmapsequenceoverlaypainter.sip
+%Include kpixmapsequencewidget.sip
+%Include kpopupframe.sip
+%Include kratingpainter.sip
+%Include kratingwidget.sip
+%Include kruler.sip
+%Include kselectaction.sip
+%Include kselector.sip
+%Include kseparator.sip
+%Include ksqueezedtextlabel.sip
+%Include ktimecombobox.sip
+%Include ktitlewidget.sip
+%Include ktoggleaction.sip
+%Include ktogglefullscreenaction.sip
+%Include ktoolbarlabelaction.sip
+%Include ktoolbarpopupaction.sip
+%Include ktoolbarspaceraction.sip
+%Include kurllabel.sip
+%Include kviewstatemaintainerbase.sip
+%Include kviewstateserializer.sip
+%Include kxyselector.sip
+%Include lineediturldropeventfilter.sip
diff --git a/sip/kwidgetsaddons/kxyselector.sip b/sip/kwidgetsaddons/kxyselector.sip
new file mode 100644
index 0000000..b68e553
--- /dev/null
+++ b/sip/kwidgetsaddons/kxyselector.sip
@@ -0,0 +1,48 @@
+// 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 KXYSelector : QWidget
+{
+%TypeHeaderCode
+#include <kxyselector.h>
+%End
+
+public:
+ explicit KXYSelector (QWidget* parent = 0);
+ ~KXYSelector ();
+ void setValues (int xPos, int yPos);
+ void setXValue (int xPos);
+ void setYValue (int yPos);
+ void setRange (int minX, int minY, int maxX, int maxY);
+ void setMarkerColor (const QColor& col);
+ int xValue () const;
+ int yValue () const;
+ QRect contentsRect () const;
+ virtual QSize minimumSizeHint () const;
+signals:
+ void valueChanged (int x, int y);
+protected:
+ virtual void drawContents (QPainter*);
+ virtual void drawMarker (QPainter* p, int xp, int yp);
+ virtual void paintEvent (QPaintEvent* e);
+ virtual void mousePressEvent (QMouseEvent* e);
+ virtual void mouseMoveEvent (QMouseEvent* e);
+ virtual void wheelEvent (QWheelEvent*);
+ void valuesFromPosition (int x, int y, int& xVal, int& yVal) const;
+};
diff --git a/sip/kcoreaddons/kfilesystemtype_p.sip b/sip/kwidgetsaddons/lineediturldropeventfilter.sip
similarity index 73%
rename from sip/kcoreaddons/kfilesystemtype_p.sip
rename to sip/kwidgetsaddons/lineediturldropeventfilter.sip
index fa655a8..6d318fa 100644
--- a/sip/kcoreaddons/kfilesystemtype_p.sip
+++ b/sip/kwidgetsaddons/lineediturldropeventfilter.sip
@@ -17,20 +17,14 @@
// Free Software Foundation, Inc.,
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-%ModuleHeaderCode
-#include <kfilesystemtype_p.h>
+class LineEditUrlDropEventFilter : QObject
+{
+%TypeHeaderCode
+#include <lineediturldropeventfilter.h>
%End
-namespace KFileSystemType
-{
-enum Type
-{
- Unknown,
- Nfs,
- Smb,
- Fat,
- Ramfs,
- Other
-};
-KFileSystemType::Type fileSystemType (const QString& path);
+public:
+ LineEditUrlDropEventFilter (QObject* parent = 0);
+ virtual ~LineEditUrlDropEventFilter ();
+ virtual bool eventFilter (QObject* obj, QEvent* ev);
};
diff --git a/sip/solid/battery.sip b/sip/solid/battery.sip
index 766bd14..2247a86 100644
--- a/sip/solid/battery.sip
+++ b/sip/solid/battery.sip
@@ -43,7 +43,8 @@ public:
{
NoCharge,
Charging,
- Discharging
+ Discharging,
+ FullyCharged
};
enum Technology
{
@@ -74,10 +75,24 @@ public:
signals:
void chargePercentChanged (int value, const QString& udi);
void capacityChanged (int value, const QString& udi);
- void chargeStateChanged (int newState, const QString& udi);
- void plugStateChanged (bool newState, const QString& udi);
void energyChanged (double energy, const QString& udi);
void energyRateChanged (double energyRate, const QString& udi);
void powerSupplyStateChanged (bool newState, const QString& udi);
+public:
+ bool isPresent () const;
+ qlonglong timeToEmpty () const;
+ qlonglong timeToFull () const;
+ double temperature () const;
+ bool isRecalled () const;
+ QString recallVendor () const;
+ QString recallUrl () const;
+ QString serial () const;
+signals:
+ void presentStateChanged (bool newState, const QString& udi);
+ void chargeStateChanged (int newState, const QString& udi);
+ void timeToEmptyChanged (qlonglong time, const QString& udi);
+ void timeToFullChanged (qlonglong time, const QString& udi);
+ void voltageChanged (double voltage, const QString& udi);
+ void temperatureChanged (double temperature, const QString& udi);
};
};
diff --git a/sip/solid/device.sip b/sip/solid/device.sip
index e21fbe0..832bdf0 100644
--- a/sip/solid/device.sip
+++ b/sip/solid/device.sip
@@ -33,7 +33,6 @@ public:
explicit Device (const QString& udi = QString());
Device (const Solid::Device& device);
~Device ();
-//ig Solid::Device& operator= (const Solid::Device& device);
bool isValid () const;
QString udi () const;
QString parentUdi () const;
@@ -46,5 +45,6 @@ public:
bool isDeviceInterface (const Solid::DeviceInterface::Type& type) const;
//ig Solid::DeviceInterface* asDeviceInterface (const Solid::DeviceInterface::Type& type);
const Solid::DeviceInterface* asDeviceInterface (const Solid::DeviceInterface::Type& type) const;
+//ig Solid::Device& operator= (const Solid::Device& device);
};
};
diff --git a/sip/solid/deviceinterface.sip b/sip/solid/deviceinterface.sip
index ebf8117..afff40d 100644
--- a/sip/solid/deviceinterface.sip
+++ b/sip/solid/deviceinterface.sip
@@ -39,19 +39,8 @@ public:
OpticalDisc,
Camera,
PortableMediaPlayer,
- NetworkInterface,
- AcAdapter,
Battery,
- Button,
- AudioInterface,
- DvbInterface,
- Video,
- SerialInterface,
- SmartCardReader,
- InternetGateway,
NetworkShare,
- Keyboard,
- PointingDevice,
Last
};
virtual ~DeviceInterface ();
diff --git a/sip/solid/networkshare.sip b/sip/solid/networkshare.sip
index aeb8343..a287084 100644
--- a/sip/solid/networkshare.sip
+++ b/sip/solid/networkshare.sip
@@ -32,8 +32,7 @@ public:
{
Unknown,
Nfs,
- Cifs,
- Upnp
+ Cifs
};
static Solid::DeviceInterface::Type deviceInterfaceType ();
Solid::NetworkShare::ShareType type () const;
diff --git a/sip/solid/predicate.sip b/sip/solid/predicate.sip
index de9a573..4a57b35 100644
--- a/sip/solid/predicate.sip
+++ b/sip/solid/predicate.sip
@@ -45,11 +45,6 @@ public:
explicit Predicate (const Solid::DeviceInterface::Type& ifaceType);
explicit Predicate (const QString& ifaceName);
~Predicate ();
-//ig Solid::Predicate& operator= (const Solid::Predicate& other);
- Solid::Predicate operator& (const Solid::Predicate& other);
- Solid::Predicate& operator&= (const Solid::Predicate& other);
- Solid::Predicate operator| (const Solid::Predicate& other);
- Solid::Predicate& operator|= (const Solid::Predicate& other);
bool isValid () const;
bool matches (const Solid::Device& device) const;
QSet<Solid::DeviceInterface::Type> usedTypes () const;
@@ -62,5 +57,10 @@ public:
Solid::Predicate::ComparisonOperator comparisonOperator () const;
Solid::Predicate firstOperand () const;
Solid::Predicate secondOperand () const;
+//ig Solid::Predicate& operator= (const Solid::Predicate& other);
+ Solid::Predicate operator& (const Solid::Predicate& other);
+ Solid::Predicate& operator&= (const Solid::Predicate& other);
+ Solid::Predicate operator| (const Solid::Predicate& other);
+ Solid::Predicate& operator|= (const Solid::Predicate& other);
};
};
diff --git a/sip/solid/solidmod.sip b/sip/solid/solidmod.sip
index 1c1a66c..9147f2a 100644
--- a/sip/solid/solidmod.sip
+++ b/sip/solid/solidmod.sip
@@ -26,33 +26,40 @@
%Import typedefs.sip
%Import QtCore/QtCoremod.sip
-%Include acadapter.sip
-%Include audiointerface.sip
+//%Include acadapter.sip
+//%Include acpluggedjob.sip
+//%Include audiointerface.sip
%Include battery.sip
%Include block.sip
-%Include button.sip
+//%Include button.sip
%Include camera.sip
%Include device.sip
%Include deviceinterface.sip
%Include devicenotifier.sip
-%Include dvbinterface.sip
+//%Include dvbinterface.sip
%Include genericinterface.sip
-%Include internetgateway.sip
-%Include keyboard.sip
-%Include networking.sip
-%Include networkinterface.sip
+//%Include inhibition.sip
+//%Include inhibitionjob.sip
+//%Include internetgateway.sip
+//%Include job.sip
+//%Include keyboard.sip
+//%Include networking.sip
+//%Include networkinterface.sip
%Include networkshare.sip
%Include opticaldisc.sip
%Include opticaldrive.sip
-%Include pointingdevice.sip
+//%Include pointingdevice.sip
%Include portablemediaplayer.sip
-%Include powermanagement.sip
+//%Include power.sip
+//%Include powermanagement.sip
%Include predicate.sip
%Include processor.sip
-%Include serialinterface.sip
-%Include smartcardreader.sip
+//%Include requeststatejob.sip
+//%Include serialinterface.sip
+//%Include smartcardreader.sip
%Include solidnamespace.sip
+//%Include statesjob.sip
%Include storageaccess.sip
%Include storagedrive.sip
%Include storagevolume.sip
-%Include video.sip
+//%Include video.sip
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic