[gtkmm/use-dllexport: 4/60] Remove Gtk::WidgetPath



commit 4793ac087a786d4147fbb40f04385651403e2881
Author: Kjell Ahlstedt <kjellahlstedt gmail com>
Date:   Wed Jan 29 12:00:15 2020 +0100

    Remove Gtk::WidgetPath
    
    GtkWidgetPath has been removed in gtk.

 .gitignore                     |  2 --
 gtk/gtkmm.h                    |  1 -
 gtk/src/cellrendererpixbuf.hg  |  3 +-
 gtk/src/container.hg           | 14 --------
 gtk/src/droptarget.hg          |  1 +
 gtk/src/filelist.am            |  1 -
 gtk/src/gtk_extra_objects.defs |  6 ----
 gtk/src/gtk_vfuncs.defs        |  8 -----
 gtk/src/image.hg               |  1 +
 gtk/src/picture.hg             |  1 +
 gtk/src/stylecontext.ccg       |  8 -----
 gtk/src/stylecontext.hg        | 25 -------------
 gtk/src/widget.ccg             |  1 -
 gtk/src/widget.hg              |  4 ---
 gtk/src/widgetpath.ccg         | 25 -------------
 gtk/src/widgetpath.hg          | 80 ------------------------------------------
 tools/m4/convert_gtk.m4        |  4 ---
 17 files changed, 5 insertions(+), 180 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 02783759..9b6edb70 100644
--- a/.gitignore
+++ b/.gitignore
@@ -562,8 +562,6 @@ gtk/gtkmm/widget.cc
 gtk/gtkmm/widget.h
 gtk/gtkmm/widgetpaintable.cc
 gtk/gtkmm/widgetpaintable.h
-gtk/gtkmm/widgetpath.cc
-gtk/gtkmm/widgetpath.h
 gtk/gtkmm/window.cc
 gtk/gtkmm/window.h
 gtk/gtkmm/windowgroup.cc
diff --git a/gtk/gtkmm.h b/gtk/gtkmm.h
index 97ce59ca..cfa15e09 100644
--- a/gtk/gtkmm.h
+++ b/gtk/gtkmm.h
@@ -285,7 +285,6 @@ extern const int gtkmm_micro_version;
 #include <gtkmm/volumebutton.h>
 #include <gtkmm/widget.h>
 #include <gtkmm/widgetpaintable.h>
-#include <gtkmm/widgetpath.h>
 #include <gtkmm/window.h>
 
 #endif /* #ifndef GTKMM_H */
diff --git a/gtk/src/cellrendererpixbuf.hg b/gtk/src/cellrendererpixbuf.hg
index 81b8f297..f328e053 100644
--- a/gtk/src/cellrendererpixbuf.hg
+++ b/gtk/src/cellrendererpixbuf.hg
@@ -17,12 +17,13 @@
  */
 
 #include <gtkmm/cellrenderer.h>
+#include <gdkmm/pixbuf.h>
 #include <gdkmm/texture.h>
 #include <giomm/icon.h>
+
 _DEFS(gtkmm,gtk)
 _PINCLUDE(gtkmm/private/cellrenderer_p.h)
 
-
 namespace Gtk
 {
 
diff --git a/gtk/src/container.hg b/gtk/src/container.hg
index daf2a315..db3cc1a6 100644
--- a/gtk/src/container.hg
+++ b/gtk/src/container.hg
@@ -127,10 +127,6 @@ public:
 
   _WRAP_METHOD(GType child_type() const, gtk_container_child_type)
 
-  // gtk_container_get_path_for_child() returns a newly created GtkWidgetPath.
-#m4 _CONVERSION(`GtkWidgetPath*',`WidgetPath',`Glib::wrap($3, false)')
-  _WRAP_METHOD(WidgetPath get_path_for_child(const Widget& child) const, gtk_container_get_path_for_child)
-
   _WRAP_SIGNAL(void add(Widget* widget), "add")
 
   //We use the optional custom_c_callback parameter with _WRAP_SIGNAL() here,
@@ -166,16 +162,6 @@ protected:
    */
   _WRAP_VFUNC(void set_focus_child(Widget* child), set_focus_child)
 
-#m4 _CONVERSION(`const Widget*', `GtkWidget*', `const_cast<$2>(Glib::unwrap($3))')
-#m4 _CONVERSION(`WidgetPath', `GtkWidgetPath*', __FR2P)
-  /** Returns a widget path representing all the widget hierarchy
-   * from the toplevel down to and including @a child.
-   *
-   * @param child The child widget.
-   * @return The WidgetPath of @a child.
-   */
-  _WRAP_VFUNC(WidgetPath get_path_for_child(const Widget* child) const, get_path_for_child, refreturn_ctype)
-
 #m4begin
 dnl// Hook in special code to catch explicit uses of gtk_object_destroy() by
 dnl// GTK+ code, e.g. when receiving the GDK_DELETE event.  For details, look
diff --git a/gtk/src/droptarget.hg b/gtk/src/droptarget.hg
index b61d4a99..6f06077a 100644
--- a/gtk/src/droptarget.hg
+++ b/gtk/src/droptarget.hg
@@ -18,6 +18,7 @@
 #include <gdkmm/drop.h>
 #include <gdkmm/enums.h>
 #include <gtkmm/eventcontroller.h>
+#include <gtkmm/selectiondata.h>
 
 _DEFS(gtkmm,gtk)
 _PINCLUDE(gtkmm/private/eventcontroller_p.h)
diff --git a/gtk/src/filelist.am b/gtk/src/filelist.am
index 20d1695c..6cc06c43 100644
--- a/gtk/src/filelist.am
+++ b/gtk/src/filelist.am
@@ -223,7 +223,6 @@ gtkmm_files_any_hg =                \
        volumebutton.hg         \
        widget.hg               \
        widgetpaintable.hg \
-       widgetpath.hg           \
        window.hg \
        windowgroup.hg
 
diff --git a/gtk/src/gtk_extra_objects.defs b/gtk/src/gtk_extra_objects.defs
index 3e65ca7a..d71f7854 100644
--- a/gtk/src/gtk_extra_objects.defs
+++ b/gtk/src/gtk_extra_objects.defs
@@ -585,9 +585,3 @@
   (c-name "GtkViewport")
   (gtype-id "GTK_TYPE_VIEWPORT")
 )
-
-(define-object WidgetPath
-  (in-module "Gtk")
-  (c-name "GtkWidgetPath")
-  (gtype-id "GTK_TYPE_WIDGET_PATH")
-)
diff --git a/gtk/src/gtk_vfuncs.defs b/gtk/src/gtk_vfuncs.defs
index d16ed5ee..846e3f06 100644
--- a/gtk/src/gtk_vfuncs.defs
+++ b/gtk/src/gtk_vfuncs.defs
@@ -288,14 +288,6 @@
   )
 )
 
-(define-vfunc get_path_for_child
-  (of-object "GtkContainer")
-  (return-type "GtkWidgetPath*")
-  (parameters
-    '("GtkWidget*" "child")
-  )
-)
-
 ; GtkEditable
 
 (define-vfunc get_text
diff --git a/gtk/src/image.hg b/gtk/src/image.hg
index 1bcb5cef..d2adf7bb 100644
--- a/gtk/src/image.hg
+++ b/gtk/src/image.hg
@@ -17,6 +17,7 @@
  */
 
 #include <gtkmm/widget.h>
+#include <gdkmm/pixbuf.h>
 #include <giomm/icon.h>
 
 _DEFS(gtkmm,gtk)
diff --git a/gtk/src/picture.hg b/gtk/src/picture.hg
index c49b4f42..392f6f1b 100644
--- a/gtk/src/picture.hg
+++ b/gtk/src/picture.hg
@@ -15,6 +15,7 @@
  */
 
 #include <gtkmm/widget.h>
+#include <gdkmm/pixbuf.h>
 #include <giomm/file.h>
 
 _DEFS(gtkmm,gtk)
diff --git a/gtk/src/stylecontext.ccg b/gtk/src/stylecontext.ccg
index f471a1e9..2035f64b 100644
--- a/gtk/src/stylecontext.ccg
+++ b/gtk/src/stylecontext.ccg
@@ -30,14 +30,6 @@ Gdk::RGBA StyleContext::get_color() const
   return Gdk::RGBA(&crgba, true);
 }
 
-Pango::FontDescription StyleContext::get_font() const
-{
-  PangoFontDescription* description = nullptr;
-  gtk_style_context_get(const_cast<GtkStyleContext*>(gobj()), "font", &description, NULL);
-  // gtk_style_context_get() returns a newly allocated font description, owned by the caller.
-  return Glib::wrap(description, false);
-}
-
 Border StyleContext::get_border() const
 {
   GtkBorder cborder;
diff --git a/gtk/src/stylecontext.hg b/gtk/src/stylecontext.hg
index d1d6384c..60a62f7c 100644
--- a/gtk/src/stylecontext.hg
+++ b/gtk/src/stylecontext.hg
@@ -26,7 +26,6 @@ _PINCLUDE(gtk/gtk.h)
 #include <gdkmm/rgba.h>
 
 #include <gtkmm/enums.h>
-#include <gtkmm/widgetpath.h>
 #include <pangomm/context.h>
 #include <pangomm/fontdescription.h>
 #include <pangomm/layout.h>
@@ -116,28 +115,12 @@ public:
   _WRAP_METHOD(void context_save(), gtk_style_context_save)
   _WRAP_METHOD(void context_restore(), gtk_style_context_restore)
 
-//TODO: GtkCssSection * gtk_style_context_get_section (GtkStyleContext *context, const gchar     *property);
-/* TODO:
-  _WRAP_METHOD(void get_property (
-                                     const Glib::ustring& property,
-                                     GValue          *value), gtk_style_context_get_property)
-  _WRAP_METHOD(void get_valist   (
-                                     va_list          args), gtk_style_context_get_valist)
-  _WRAP_METHOD(void get          (
-                                     ...) G_GNUC_NULL_TERMINATED;
-*/
-
   _WRAP_METHOD(void set_state(StateFlags flags), gtk_style_context_set_state)
   _WRAP_METHOD(StateFlags get_state() const, gtk_style_context_get_state)
 
   _WRAP_METHOD(void set_scale(int scale), gtk_style_context_set_scale)
   _WRAP_METHOD(int get_scale() const, gtk_style_context_get_scale)
 
-  _WRAP_METHOD(void set_path(const WidgetPath& path), gtk_style_context_set_path)
-
-#m4 _CONVERSION(`const GtkWidgetPath*',`WidgetPath',`WidgetPath(const_cast<GtkWidgetPath*>($3), true)')
-  _WRAP_METHOD(WidgetPath get_path() const, gtk_style_context_get_path)
-
   _WRAP_METHOD(void set_parent(const Glib::RefPtr<StyleContext>& parent), gtk_style_context_set_parent)
   void unset_parent();
 
@@ -167,14 +150,6 @@ public:
   Gdk::RGBA get_color() const;
   _IGNORE(gtk_style_context_get_color)
 
-  /** Returns the font description for a given state.
-   *
-   * @newin{3,0}
-   *
-   * @return The Pango::FontDescription for the given state.
-   */
-  Pango::FontDescription get_font() const;
-
   Border get_border() const;
   _IGNORE(gtk_style_context_get_border)
 
diff --git a/gtk/src/widget.ccg b/gtk/src/widget.ccg
index 533596a4..cf5e3b80 100644
--- a/gtk/src/widget.ccg
+++ b/gtk/src/widget.ccg
@@ -28,7 +28,6 @@
 #include <gtkmm/settings.h>
 #include <gtkmm/container.h>
 #include <gtkmm/eventcontroller.h>
-#include <gtkmm/selectiondata_private.h>
 #include <gtkmm/tooltip.h>
 #include <gtkmm/snapshot.h>
 #include <gtkmm/layoutmanager.h>
diff --git a/gtk/src/widget.hg b/gtk/src/widget.hg
index 82110b37..e1e8af18 100644
--- a/gtk/src/widget.hg
+++ b/gtk/src/widget.hg
@@ -36,9 +36,7 @@ _CONFIGINCLUDE(gtkmmconfig.h)
 #include <gdkmm/display.h>
 #include <gdkmm/clipboard.h>
 #include <gtkmm/requisition.h>
-#include <gtkmm/selectiondata.h>
 #include <gtkmm/stylecontext.h>
-#include <gtkmm/widgetpath.h>
 #include <giomm/actiongroup.h>
 
 _DEFS(gtkmm,gtk)
@@ -397,8 +395,6 @@ public:
   _WRAP_METHOD(Glib::RefPtr<Gdk::Cursor> get_cursor(), gtk_widget_get_cursor, refreturn)
   _WRAP_METHOD(Glib::RefPtr<const Gdk::Cursor> get_cursor() const, gtk_widget_get_cursor, refreturn, 
constversion)
 
-  _WRAP_METHOD(WidgetPath get_path() const, gtk_widget_get_path)
-
 #m4 _CONVERSION(`GList*',`std::vector<Widget*>',`Glib::ListHandler<Widget*>::list_to_vector($3, 
Glib::OWNERSHIP_SHALLOW)')
  _WRAP_METHOD(std::vector<Widget*> list_mnemonic_labels(), gtk_widget_list_mnemonic_labels)
 #m4 _CONVERSION(`GList*',`std::vector<const Widget*>',`Glib::ListHandler<const Widget*>::list_to_vector($3, 
Glib::OWNERSHIP_SHALLOW)')
diff --git a/tools/m4/convert_gtk.m4 b/tools/m4/convert_gtk.m4
index 72921e91..9c9f60c7 100644
--- a/tools/m4/convert_gtk.m4
+++ b/tools/m4/convert_gtk.m4
@@ -573,10 +573,6 @@ _CONVERSION(`GActionGroup*',`Glib::RefPtr<const Gio::ActionGroup>',`Glib::wrap($
 _CONVERSION(`GtkDragResult',`DragResult',`static_cast<$2>($3)')
 _CONVERSION(`GtkDropTarget*',`Glib::RefPtr<DropTarget>',`Glib::wrap($3)')
 
-_CONVERSION(`GtkWidgetPath*',`WidgetPath',`Glib::wrap($3, true)')
-_CONVERSION(`const GtkWidgetPath*',`WidgetPath',`Glib::wrap(const_cast<GtkWidgetPath*>($3), true)')
-_CONVERSION(`const WidgetPath&',`GtkWidgetPath*',`const_cast<WidgetPath&>($3).gobj()')
-
 # LayoutChild, LayoutManager
 _CONVERSION(`GtkLayoutManager*',`Glib::RefPtr<LayoutManager>',`Glib::wrap($3)')
 _CONVERSION(`GtkLayoutManager*',`Glib::RefPtr<const LayoutManager>',`Glib::wrap($3)')


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]