[gtksourceview] typebuiltins: warn when #included in external code
- From: Sébastien Wilmet <swilmet src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtksourceview] typebuiltins: warn when #included in external code
- Date: Sat, 25 Jun 2016 10:36:31 +0000 (UTC)
commit 25a6655af9b6c67c5ffc26f36259d33e574e3508
Author: Sébastien Wilmet <swilmet gnome org>
Date: Sat Jun 25 12:12:12 2016 +0200
typebuiltins: warn when #included in external code
gtksourceview/gtksource.h | 1 +
gtksourceview/gtksourceview-typebuiltins.h | 39 +++++++++++++++++++++++++++-
2 files changed, 39 insertions(+), 1 deletions(-)
---
diff --git a/gtksourceview/gtksource.h b/gtksourceview/gtksource.h
index 3d330d6..ad1642e 100644
--- a/gtksourceview/gtksource.h
+++ b/gtksourceview/gtksource.h
@@ -59,6 +59,7 @@
#include <gtksourceview/gtksourceversion.h>
#include <gtksourceview/gtksourceview.h>
#include <gtksourceview/gtksourceview-enumtypes.h>
+#include <gtksourceview/gtksourceview-typebuiltins.h>
#include <gtksourceview/gtksourceautocleanups.h>
#undef GTK_SOURCE_H_INSIDE
diff --git a/gtksourceview/gtksourceview-typebuiltins.h b/gtksourceview/gtksourceview-typebuiltins.h
index ef618f2..75b8d11 100644
--- a/gtksourceview/gtksourceview-typebuiltins.h
+++ b/gtksourceview/gtksourceview-typebuiltins.h
@@ -1,2 +1,39 @@
-/* Deprecated: 3.22: #include <gtksourceview/gtksource.h> instead. */
+/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8; coding: utf-8 -*-
+ *
+ * This file is part of GtkSourceView
+ *
+ * Copyright (C) 2016 - Sébastien Wilmet <swilmet gnome org>
+ *
+ * GtkSourceView is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * GtkSourceView 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
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+/* Deprecated: 3.22: This header is deprecated. For internal GtkSourceView code,
+ * include gtksourceview-enumtypes.h. For external code, include gtksource.h.
+ */
+
+#ifndef GTK_SOURCE_VIEW_TYPE_BUILTINS_H
+#define GTK_SOURCE_VIEW_TYPE_BUILTINS_H
+
+#if !defined (GTK_SOURCE_H_INSIDE) && !defined (GTK_SOURCE_COMPILATION)
+# if defined (__GNUC__)
+# warning "Only <gtksourceview/gtksource.h> can be included directly."
+# elif defined (G_OS_WIN32)
+# pragma message("Only <gtksourceview/gtksource.h> can be included directly.")
+# endif
+#endif
+
#include <gtksourceview/gtksourceview-enumtypes.h>
+
+#endif /* GTK_SOURCE_VIEW_TYPE_BUILTINS_H */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]