[gtksourceviewmm] Deprecate more (deprecated in the C API) API.



commit 27b94280fc2b5f3fe6cd98705d54ccb630d21fa6
Author: Murray Cumming <murrayc murrayc com>
Date:   Wed Apr 29 13:35:16 2015 +0200

    Deprecate more (deprecated in the C API) API.

 gtksourceview/src/completioninfo.hg       |    9 ++++++++-
 gtksourceview/src/completionitem.hg       |   11 +++++++++++
 gtksourceview/src/gutter.hg               |    4 ++--
 gtksourceview/src/gutterrendererpixbuf.hg |    2 +-
 gtksourceview/src/markattributes.hg       |    2 +-
 5 files changed, 23 insertions(+), 5 deletions(-)
---
diff --git a/gtksourceview/src/completioninfo.hg b/gtksourceview/src/completioninfo.hg
index 531c9bd..c0b124d 100644
--- a/gtksourceview/src/completioninfo.hg
+++ b/gtksourceview/src/completioninfo.hg
@@ -71,6 +71,7 @@ public:
    */
   void move_to_iter(const Gtk::TextView& view);
 
+#ifndef GTKSOURCEVIEWMM_DISABLE_DEPRECATED
   /** Sets the content widget of the info window.
    *
    * If @a widget does not fit within the size requirements of the window,
@@ -80,6 +81,8 @@ public:
    * @param widget A Gtk::Widget.
    *
    * @newin{2,10}
+   *
+   * @deprecated Use Gtk::Container:add() instead. If there is already a child widget, remove it with 
Gtk::Container::remove().
    */
   _WRAP_METHOD(void set_widget(Gtk::Widget& widget), gtk_source_completion_info_set_widget)
 
@@ -88,9 +91,13 @@ public:
    * @return The current content widget.
    *
    * @newin{2,10}
+   *
+   * @deprecated Use Gtk::Bin:get_child() instead.
    */
   _WRAP_METHOD(Gtk::Widget* get_widget(), gtk_source_completion_info_get_widget)
 
+#endif //GTKSOURCEVIEWMM_DISABLE_DEPRECATED
+
   /** Get the current content widget.
    *
    * @return The current content widget.
@@ -106,7 +113,7 @@ public:
    *
    * @newin{2,10}
    */
-  _WRAP_SIGNAL(void before_show(), "before-show")
+  _WRAP_SIGNAL(void before_show(), "before-show", deprecated "This should not be used in newly-written 
code.")
 };
 
 } /* namespace Gsv */
diff --git a/gtksourceview/src/completionitem.hg b/gtksourceview/src/completionitem.hg
index cff61b9..dcc65a6 100644
--- a/gtksourceview/src/completionitem.hg
+++ b/gtksourceview/src/completionitem.hg
@@ -44,7 +44,14 @@ class CompletionItem
 protected:
   explicit CompletionItem(const Glib::ustring& label, const Glib::ustring& text, const Glib::RefPtr<const 
Gdk::Pixbuf>& icon, const Glib::ustring& info);
   explicit CompletionItem(const Markup& markup, const Glib::ustring& text, const Glib::RefPtr<const 
Gdk::Pixbuf>& icon, const Glib::ustring& info);
+
+#ifndef GTKSOURCEVIEWMM_DISABLE_DEPRECATED
+  /**
+   * @deprecated Use a constructor without a stock ID instead.
+   */
   explicit CompletionItem(const Glib::ustring& label, const Glib::ustring& text, const Gtk::StockID& stock, 
const Glib::ustring& info);
+#endif //GTKSOURCEVIEWMM_DISABLE_DEPRECATED
+
 public:
   /** Create a new CompletionItem with label @a label, icon @a icon and
    *  extra information @a info.
@@ -80,6 +87,7 @@ public:
    */
   _WRAP_CREATE(const Markup& markup, const Glib::ustring& text, const Glib::RefPtr<const Gdk::Pixbuf>& icon, 
const Glib::ustring& info)
 
+#ifndef GTKSOURCEVIEWMM_DISABLE_DEPRECATED
   /** Creates a new CompletionItem from a stock item.
    *
    * If @a label is empty, then stock label will be used.
@@ -92,8 +100,11 @@ public:
    * @return New CompletionInfo.
    *
    * @newin{2,10}
+   *
+   * @deprecated Use a create() method without a stock ID instead.
    */
   _WRAP_CREATE(const Glib::ustring& label, const Glib::ustring& text, const Gtk::StockID& stock, const 
Glib::ustring& info)
+#endif //GTKSOURCEVIEWMM_DISABLE_DEPRECATED
 
   _WRAP_PROPERTY("icon", Glib::RefPtr<Gdk::Pixbuf>)
   _WRAP_PROPERTY("info", Glib::ustring)
diff --git a/gtksourceview/src/gutter.hg b/gtksourceview/src/gutter.hg
index c431de0..8ee6df1 100644
--- a/gtksourceview/src/gutter.hg
+++ b/gtksourceview/src/gutter.hg
@@ -111,8 +111,8 @@ public:
 
   _WRAP_PROPERTY("view", View*)
   _WRAP_PROPERTY("window-type", Gtk::TextWindowType)
-  _WRAP_PROPERTY("xpad", int)
-  _WRAP_PROPERTY("ypad", int)
+  _WRAP_PROPERTY("xpad", int, deprecated "Use GutterRenderer's xpad property instead.")
+  _WRAP_PROPERTY("ypad", int, deprecated "Use GutterRenderer's ypad property instead.")
 };
 
 } // namespace Gsv
diff --git a/gtksourceview/src/gutterrendererpixbuf.hg b/gtksourceview/src/gutterrendererpixbuf.hg
index b559fc1..8f4b365 100644
--- a/gtksourceview/src/gutterrendererpixbuf.hg
+++ b/gtksourceview/src/gutterrendererpixbuf.hg
@@ -69,7 +69,7 @@ public:
   _WRAP_METHOD(void set_icon_name(const std::string& icon_name), 
gtk_source_gutter_renderer_pixbuf_set_icon_name)
 
   _WRAP_PROPERTY("pixbuf", Glib::RefPtr<Gdk::Pixbuf>)
-  _WRAP_PROPERTY("stock-id", std::string)
+  _WRAP_PROPERTY("stock-id", std::string, deprecated "This should not be used in newly-written code.")
   _WRAP_PROPERTY("icon-name", std::string)
   _WRAP_PROPERTY("gicon", Glib::RefPtr<Gio::Icon>)
 };
diff --git a/gtksourceview/src/markattributes.hg b/gtksourceview/src/markattributes.hg
index 92c63c4..14d2fc1 100644
--- a/gtksourceview/src/markattributes.hg
+++ b/gtksourceview/src/markattributes.hg
@@ -107,7 +107,7 @@ public:
 
   _WRAP_PROPERTY("background", Gdk::RGBA)
 
-  _WRAP_PROPERTY("stock-id", std::string)
+  _WRAP_PROPERTY("stock-id", std::string, deprecated "This should not be used in newly-written code.")
 
   _WRAP_PROPERTY("pixbuf", Glib::RefPtr<Gdk::Pixbuf>)
 


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