[gtksourceview/wip/chergert/snippets: 2/119] build: branch for GtkSourceView 5 targeting GTK 4



commit 56086c7970f5ba0fb243c82bf29ef4492c2b3d45
Author: Christian Hergert <chergert redhat com>
Date:   Wed Jan 8 15:15:42 2020 -0800

    build: branch for GtkSourceView 5 targeting GTK 4

 README.md                           |  4 +++-
 gtksourceview/gtksourceversion.h.in | 18 ++++++++++++++++++
 meson.build                         |  4 ++--
 3 files changed, 23 insertions(+), 3 deletions(-)
---
diff --git a/README.md b/README.md
index 1515e87e..e28a8c7c 100644
--- a/README.md
+++ b/README.md
@@ -1,7 +1,9 @@
 GtkSourceView
 =============
 
-This is version 4.4.0 of GtkSourceView.
+This is version 4.99.0 of GtkSourceView.
+
+This is a development branch to progress towards GTK 4 support.
 
 GtkSourceView is a GNOME library that extends GtkTextView, the standard GTK+
 widget for multiline text editing. GtkSourceView adds support for syntax
diff --git a/gtksourceview/gtksourceversion.h.in b/gtksourceview/gtksourceversion.h.in
index 032bc3bd..43ebf272 100644
--- a/gtksourceview/gtksourceversion.h.in
+++ b/gtksourceview/gtksourceversion.h.in
@@ -226,6 +226,16 @@ G_BEGIN_DECLS
  */
 #define GTK_SOURCE_VERSION_4_0 (G_ENCODE_VERSION (4, 0))
 
+/**
+ * GTK_SOURCE_VERSION_5_0:
+ *
+ * A macro that evaluates to the 5.0 version of GtkSourceView,
+ * in a format that can be used by the C pre-processor.
+ *
+ * Since: 5.0
+ */
+#define GTK_SOURCE_VERSION_5_0 (G_ENCODE_VERSION (5, 0))
+
 /* Define GTK_SOURCE_VERSION_CUR_STABLE */
 #ifndef __GTK_DOC_IGNORE__
 #  if (GTK_SOURCE_MINOR_VERSION % 2)
@@ -559,6 +569,14 @@ G_BEGIN_DECLS
 #endif
 #endif /* __GTK_DOC_IGNORE__ */
 
+#ifndef __GTK_DOC_IGNORE__
+#if GTK_SOURCE_VERSION_MAX_ALLOWED < GTK_SOURCE_VERSION_5_0
+#define GTK_SOURCE_AVAILABLE_IN_5_0 G_UNAVAILABLE(5, 0) _GTK_SOURCE_EXTERN
+#else
+#define GTK_SOURCE_AVAILABLE_IN_5_0 _GTK_SOURCE_EXTERN
+#endif
+#endif /* __GTK_DOC_IGNORE__ */
+
 GTK_SOURCE_AVAILABLE_IN_3_20
 guint          gtk_source_get_major_version            (void);
 
diff --git a/meson.build b/meson.build
index 3baae99c..b71db895 100644
--- a/meson.build
+++ b/meson.build
@@ -1,5 +1,5 @@
 project('gtksourceview', 'c',
-          version: '4.5.1',
+          version: '4.99.0',
           license: 'LGPL-2.1-or-later',
     meson_version: '>= 0.50.0',
   default_options: [ 'c_std=gnu99',
@@ -18,7 +18,7 @@ version_major = version_arr[0].to_int()
 version_minor = version_arr[1].to_int()
 version_micro = version_arr[2].to_int()
 
-api_version = '4'
+api_version = '5'
 
 lib_version = '0.0.0'
 lib_version_arr = lib_version.split('.')


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