[gtkmm] gdkmm: Screen: Added signals and properties.
- From: Murray Cumming <murrayc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtkmm] gdkmm: Screen: Added signals and properties.
- Date: Sat, 25 Sep 2010 13:33:20 +0000 (UTC)
commit 275f563c98a7e6c784e9023fccdc04b129461b64
Author: Murray Cumming <murrayc murrayc com>
Date: Fri Sep 24 08:57:27 2010 +0200
gdkmm: Screen: Added signals and properties.
* gdk/src/gdk_signals.defs: Regenerated by taking the part of the
extra_defs_gen output for GDK.
* gdk/src/screen.hg: Added composited_changed() and monitors_changed()
signals, but with no default signal handlers, to avoid breaking ABI.
Added font-options and resolution properties.
ChangeLog | 10 ++++++
gdk/src/gdk_signals.defs | 72 ++++++++++++++++++++++++++++++++++++++++++++++
gdk/src/screen.hg | 7 ++++
gdk/src/window.hg | 12 ++++++-
4 files changed, 99 insertions(+), 2 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 19c3968..8a6c9a1 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2010-09-24 Murray Cumming <murrayc murrayc com>
+
+ gdkmm: Screen: Added signals and properties.
+
+ * gdk/src/gdk_signals.defs: Regenerated by taking the part of the
+ extra_defs_gen output for GDK.
+ * gdk/src/screen.hg: Added composited_changed() and monitors_changed()
+ signals, but with no default signal handlers, to avoid breaking ABI.
+ Added font-options and resolution properties.
+
2010-09-22 Murray Cumming <murrayc murrayc com>
Fix the build with GTK+ from git master.
diff --git a/gdk/src/gdk_signals.defs b/gdk/src/gdk_signals.defs
index 7313265..289080a 100644
--- a/gdk/src/gdk_signals.defs
+++ b/gdk/src/gdk_signals.defs
@@ -161,7 +161,79 @@
(when "last")
)
+(define-signal composited-changed
+ (of-object "GdkScreen")
+ (return-type "void")
+ (when "last")
+)
+
+(define-signal monitors-changed
+ (of-object "GdkScreen")
+ (return-type "void")
+ (when "last")
+)
+
+(define-property font-options
+ (of-object "GdkScreen")
+ (prop-type "GParamPointer")
+ (docs "The default font options for the screen")
+ (readable #t)
+ (writable #t)
+ (construct-only #f)
+)
+
+(define-property resolution
+ (of-object "GdkScreen")
+ (prop-type "GParamDouble")
+ (docs "The resolution for fonts on the screen")
+ (readable #t)
+ (writable #t)
+ (construct-only #f)
+)
+
;; From GdkVisual
;; From GdkWindow
+(define-signal pick-embedded-child
+ (of-object "GdkWindow")
+ (return-type "GdkWindow*")
+ (when "last")
+ (parameters
+ '("gdouble" "p0")
+ '("gdouble" "p1")
+ )
+)
+
+(define-signal to-embedder
+ (of-object "GdkWindow")
+ (return-type "void")
+ (when "last")
+ (parameters
+ '("gdouble" "p0")
+ '("gdouble" "p1")
+ '("gpointer" "p2")
+ '("gpointer" "p3")
+ )
+)
+
+(define-signal from-embedder
+ (of-object "GdkWindow")
+ (return-type "void")
+ (when "last")
+ (parameters
+ '("gdouble" "p0")
+ '("gdouble" "p1")
+ '("gpointer" "p2")
+ '("gpointer" "p3")
+ )
+)
+
+(define-property cursor
+ (of-object "GdkWindow")
+ (prop-type "GParamBoxed")
+ (docs "Cursor")
+ (readable #t)
+ (writable #t)
+ (construct-only #f)
+)
diff --git a/gdk/src/screen.hg b/gdk/src/screen.hg
index e84dbe6..56dcd5d 100644
--- a/gdk/src/screen.hg
+++ b/gdk/src/screen.hg
@@ -129,6 +129,13 @@ public:
* height of a screen changes.
*/
_WRAP_SIGNAL(void size_changed(), size-changed)
+
+ //TODO: Remove no_default_handler when we can break ABI:
+ _WRAP_SIGNAL(void composited_changed(), composited-changed, no_default_handler)
+ _WRAP_SIGNAL(void monitors_changed(), size-changed, no_default_handler)
+
+ _WRAP_PROPERTY("font-options", Cairo::FontOptions)
+ _WRAP_PROPERTY("resolution", double)
};
template <class ValueType>
diff --git a/gdk/src/window.hg b/gdk/src/window.hg
index 3cb1b21..42b92c0 100644
--- a/gdk/src/window.hg
+++ b/gdk/src/window.hg
@@ -343,15 +343,23 @@ public:
_WRAP_METHOD(Glib::RefPtr<Window> get_offscreen_embedder(), gdk_offscreen_window_get_embedder, refreturn)
_WRAP_METHOD(Glib::RefPtr<const Window> get_offscreen_embedder() const, gdk_offscreen_window_get_embedder, constversion, refreturn)
- _WRAP_METHOD(void set_offscreen_embedder(const Glib::RefPtr<Window>& embedder), gdk_offscreen_window_set_embedder)
+ _WRAP_METHOD(void set_offscreen_embedder(const Glib::RefPtr<Window>& embedder), gdk_offscreen_window_set_embedder)
_WRAP_METHOD(void redirect_to_drawable(const Glib::RefPtr<Drawable>& drawable, int src_x, int src_y, int dest_x, int dest_y, int width, int height), gdk_window_redirect_to_drawable)
_WRAP_METHOD(void remove_redirection(), gdk_window_remove_redirection)
_WRAP_METHOD(void geometry_changed(), gdk_window_geometry_changed)
-
+
_WRAP_METHOD(void set_support_multidevice(bool support_multidevice = true), gdk_window_set_support_multidevice)
_WRAP_METHOD(bool get_support_multidevice(), gdk_window_get_support_multidevice)
+
+ //TODO: Wrap these? Find out when they are emitted and if they are useful outside of GTK+, and improve the C docs.
+ //_WRAP_SIGNAL(Glib::RefPtr<Gdk::Window> pick_embedded_child(double x, double y), pick-embedded-child, no_default_handler)
+ //_WRAP_SIGNAL(Glib::RefPtr<Gdk::Window> to_embedder(double offscreen_x, double offscreen_y, double& embedder_x, double& embedder_y), to-embedder, no_default_handler)
+ //_WRAP_SIGNAL(Glib::RefPtr<Gdk::Window> from_embedder(double embedder_x, double embedder_y, double& offscreen_x, double& offscreen_y), from-embedder, no_default_handler)
+
+
+ //TODO: _WRAP_PROPERTY("cursor", Cursor)
};
} // namespace Gdk
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]