summaryrefslogtreecommitdiffstats
path: root/qtsharp/src/bindings/static/QToolButton.cs
diff options
context:
space:
mode:
authortoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
committertoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
commit90825e2392b2d70e43c7a25b8a3752299a933894 (patch)
treee33aa27f02b74604afbfd0ea4f1cfca8833d882a /qtsharp/src/bindings/static/QToolButton.cs
downloadtdebindings-90825e2392b2d70e43c7a25b8a3752299a933894.tar.gz
tdebindings-90825e2392b2d70e43c7a25b8a3752299a933894.zip
Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features.
BUG:215923 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebindings@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'qtsharp/src/bindings/static/QToolButton.cs')
-rw-r--r--qtsharp/src/bindings/static/QToolButton.cs290
1 files changed, 290 insertions, 0 deletions
diff --git a/qtsharp/src/bindings/static/QToolButton.cs b/qtsharp/src/bindings/static/QToolButton.cs
new file mode 100644
index 00000000..90f36785
--- /dev/null
+++ b/qtsharp/src/bindings/static/QToolButton.cs
@@ -0,0 +1,290 @@
+// QToolButton.cs - A Qt to C# binding.
+//
+// Copyright (C) 2002 Adam Treat (manyoso@yahoo.com)
+//
+// This program is free software; you can redistribute it and/or
+// modify it under the terms of the GNU General Public License
+// as published by the Free Software Foundation; either version 2
+// of the License, 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 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.
+//
+// Created static file 26 January 2003
+// Marcus Urban
+
+
+namespace Qt {
+
+ using Qt;
+ using System;
+ using System.Runtime.InteropServices;
+
+ public class QToolButton : QButton, IDisposable {
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern IntPtr qt_new_QToolButton (IntPtr parent, string name);
+ public QToolButton (QWidget parent, string name) : this (QNull.Instance)
+ {
+ rawObject = qt_new_QToolButton (parent != null ? parent.RawObject : IntPtr.Zero, name);
+
+ if ((qparent = parent) != null)
+ qparent.AddChild (this);
+
+ RegisterObject (this);
+ Connect (this, SIGNAL ("destroyed ()"), SLOT ("NativeDestroyed ()"));
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern IntPtr qt_new_QToolButton1 (IntPtr iconSet, IntPtr textLabel, IntPtr groupText, IntPtr receiver, string slot, IntPtr parent, string name);
+ public QToolButton (QIconSet iconSet, QString textLabel, QString groupText, QObject receiver, string slot, QToolBar parent, string name) : this (QNull.Instance)
+ {
+ rawObject = qt_new_QToolButton1 (iconSet.RawObject, textLabel.RawObject, groupText.RawObject, IntPtr.Zero, null, parent != null ? parent.RawObject : IntPtr.Zero, name);
+ Connect( this, SIGNAL("clicked()"), receiver, slot );
+
+
+ if ((qparent = parent) != null)
+ qparent.AddChild (this);
+
+ RegisterObject (this);
+ Connect (this, SIGNAL ("destroyed ()"), SLOT ("NativeDestroyed ()"));
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern IntPtr qt_new_QToolButton2 (Qt.ArrowType type, IntPtr parent, string name);
+ public QToolButton (Qt.ArrowType type, QWidget parent, string name) : this (QNull.Instance)
+ {
+ rawObject = qt_new_QToolButton2 (type, parent != null ? parent.RawObject : IntPtr.Zero, name);
+
+ if ((qparent = parent) != null)
+ qparent.AddChild (this);
+
+ RegisterObject (this);
+ Connect (this, SIGNAL ("destroyed ()"), SLOT ("NativeDestroyed ()"));
+ }
+
+ public QToolButton (QWidget parent) : this (parent, "") {}
+
+ internal QToolButton () : this (QNull.Instance) {}
+
+ internal QToolButton (IntPtr ptr) : this (QNull.Instance)
+ {
+ rawObject = ptr;
+ RegisterObject(this);
+ }
+
+ internal QToolButton (QNull dummy) : base (QNull.Instance) {}
+
+ ~QToolButton ()
+ {
+ Dispose (false);
+ }
+
+ internal override void Delete ()
+ {
+ if (deleted) return;
+
+ // libqtc lacks a qt_del_QToolButton function
+ deleted = true;
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern void qt_QToolButton_setUsesBigPixmap (IntPtr raw, bool enable);
+ public void SetUsesBigPixmap (bool enable)
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ qt_QToolButton_setUsesBigPixmap (rawObject, enable);
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern void qt_QToolButton_setUsesTextLabel (IntPtr raw, bool enable);
+ public void SetUsesTextLabel (bool enable)
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ qt_QToolButton_setUsesTextLabel (rawObject, enable);
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern void qt_QToolButton_setTextLabel (IntPtr raw, IntPtr arg1, bool arg2);
+ public void SetTextLabel (QString arg1, bool arg2)
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ qt_QToolButton_setTextLabel (rawObject, arg1.RawObject, arg2);
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern void qt_QToolButton_setToggleButton (IntPtr raw, bool enable);
+ public void SetToggleButton (bool enable)
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ qt_QToolButton_setToggleButton (rawObject, enable);
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern void qt_QToolButton_setOn (IntPtr raw, bool enable);
+ public void SetOn (bool enable)
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ qt_QToolButton_setOn (rawObject, enable);
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern void qt_QToolButton_toggle (IntPtr raw);
+ public void Toggle ()
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ qt_QToolButton_toggle (rawObject);
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern void qt_QToolButton_setTextLabel1 (IntPtr raw, IntPtr arg1);
+ public void SetTextLabel (QString arg1)
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ qt_QToolButton_setTextLabel1 (rawObject, arg1.RawObject);
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern void qt_QToolButton_setIconSet (IntPtr raw, IntPtr set);
+ public void SetIconSet (QIconSet set)
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ qt_QToolButton_setIconSet (rawObject, set.RawObject);
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern void qt_QToolButton_setIconSet1 (IntPtr raw, IntPtr set, bool on);
+ public void SetIconSet (QIconSet set, bool on)
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ qt_QToolButton_setIconSet1 (rawObject, set.RawObject, on);
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern IntPtr qt_QToolButton_iconSet (IntPtr raw, bool on);
+ public QIconSet IconSet (bool on)
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ return LookupObject (qt_QToolButton_iconSet (rawObject, on), typeof (QIconSet)) as QIconSet;
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern void qt_QToolButton_setPopupDelay (IntPtr raw, int delay);
+ public void SetPopupDelay (int delay)
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ qt_QToolButton_setPopupDelay (rawObject, delay);
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern int qt_QToolButton_popupDelay (IntPtr raw);
+ public int PopupDelay ()
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ return qt_QToolButton_popupDelay (rawObject);
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern void qt_QToolButton_openPopup (IntPtr raw);
+ public void OpenPopup ()
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ qt_QToolButton_openPopup (rawObject);
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern void qt_QToolButton_setAutoRaise (IntPtr raw, bool enable);
+ public void SetAutoRaise (bool enable)
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ qt_QToolButton_setAutoRaise (rawObject, enable);
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern bool qt_QToolButton_autoRaise (IntPtr raw);
+ public bool AutoRaise ()
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ return qt_QToolButton_autoRaise (rawObject);
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern void qt_QToolButton_drawButtonLabel (IntPtr raw, IntPtr arg1);
+ protected void DrawButtonLabel (QPainter arg1)
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ qt_QToolButton_drawButtonLabel (rawObject, arg1.RawObject);
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern bool qt_QToolButton_uses3D (IntPtr raw);
+ protected bool Uses3D ()
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ return qt_QToolButton_uses3D (rawObject);
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern bool qt_QToolButton_eventFilter (IntPtr raw, IntPtr o, IntPtr e);
+ protected bool EventFilter (QObject o, QEvent e)
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ return qt_QToolButton_eventFilter (rawObject, o.RawObject, e.RawObject);
+ }
+
+ [DllImport("libqtc", CharSet=CharSet.Ansi)]
+ private static extern void qt_QToolButton_paletteChange (IntPtr raw, IntPtr arg1);
+ protected void PaletteChange (QPalette arg1)
+ {
+ if (disposed)
+ throw new ObjectDisposedException (this+": Attempted use of disposed object");
+
+ qt_QToolButton_paletteChange (rawObject, arg1.RawObject);
+ }
+
+ // Begin interface methods.
+
+ }
+}