[gtkmm] Drop dependency on Atkmm
- From: Kjell Ahlstedt <kjellahl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtkmm] Drop dependency on Atkmm
- Date: Tue, 4 Aug 2020 15:12:11 +0000 (UTC)
commit 0fc81d346f50bfc30f6fb78afe6a15331c5a8790
Author: Kjell Ahlstedt <kjellahlstedt gmail com>
Date: Tue Aug 4 17:08:14 2020 +0200
Drop dependency on Atkmm
Gtk no longer depends on atk. And now gtkmm does not depend on atk or atkmm.
Add the Gtk::Accessible interface, and make Widget implement it.
It's a replacement for atk/atkmm.
Gtk issue "Outline for the a11y rework":
https://gitlab.gnome.org/GNOME/gtk/-/issues/2833
Gtk commit "Remove ATK":
https://gitlab.gnome.org/GNOME/gtk/-/commit/c63087a5631e72cd1c45bdc5a41bf605195be64c
Gtk commit "Introduce GtkAccessible":
https://gitlab.gnome.org/GNOME/gtk/-/commit/14faec3ce2ce8b70f97aba3ebbd946d2a2c065f5
.gitignore | 8 +++
configure.ac | 13 ++---
demos/gtk-demo/example_builder.ui | 16 ------
docs/reference/Doxyfile.in | 3 +-
docs/reference/meson.build | 1 -
gdk/meson.build | 5 +-
gtk/gtkmm/init.cc | 6 ---
gtk/gtkmm/meson.build | 1 +
gtk/gtkmmconfig.h.in | 3 --
gtk/gtkmmconfig.h.meson | 3 --
gtk/src/accessible.ccg | 19 ++++++++
gtk/src/accessible.hg | 81 +++++++++++++++++++++++++++++++
gtk/src/application.ccg | 6 ---
gtk/src/filelist.am | 1 +
gtk/src/gtk_docs_override.xml | 6 +++
gtk/src/gtk_signals.defs | 12 +++++
gtk/src/gtk_vfuncs.defs | 5 --
gtk/src/widget.hg | 13 ++---
meson.build | 19 +-------
meson_options.txt | 2 -
tools/extra_defs_gen/generate_defs_gtk.cc | 1 +
tools/m4/convert_gtk.m4 | 5 +-
tools/m4/convert_gtkmm.m4 | 5 +-
23 files changed, 144 insertions(+), 90 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index a9266d8d..ff379b52 100644
--- a/.gitignore
+++ b/.gitignore
@@ -141,6 +141,8 @@ gtk/gtkmm/aboutdialog.cc
gtk/gtkmm/aboutdialog.h
gtk/gtkmm/accellabel.cc
gtk/gtkmm/accellabel.h
+gtk/gtkmm/accessible.cc
+gtk/gtkmm/accessible.h
gtk/gtkmm/actionable.cc
gtk/gtkmm/actionable.h
gtk/gtkmm/actionbar.cc
@@ -229,6 +231,10 @@ gtk/gtkmm/colorchooser.cc
gtk/gtkmm/colorchooser.h
gtk/gtkmm/colorchooserdialog.cc
gtk/gtkmm/colorchooserdialog.h
+gtk/gtkmm/columnview.cc
+gtk/gtkmm/columnview.h
+gtk/gtkmm/columnviewcolumn.cc
+gtk/gtkmm/columnviewcolumn.h
gtk/gtkmm/combobox.cc
gtk/gtkmm/combobox.h
gtk/gtkmm/comboboxtext.cc
@@ -507,6 +513,8 @@ gtk/gtkmm/sizegroup.cc
gtk/gtkmm/sizegroup.h
gtk/gtkmm/snapshot.cc
gtk/gtkmm/snapshot.h
+gtk/gtkmm/sorter.cc
+gtk/gtkmm/sorter.h
gtk/gtkmm/spinbutton.cc
gtk/gtkmm/spinbutton.h
gtk/gtkmm/spinner.cc
diff --git a/configure.ac b/configure.ac
index 6c868a69..2b8ee6bc 100644
--- a/configure.ac
+++ b/configure.ac
@@ -95,18 +95,12 @@ AS_IF([test "x$enable_static" = xyes],
# gdkmm really does need GTK, because part of Gdk::DragContext is in GTK.
# The extra gdk-pixbuf-2.0 check is because gdkmm requires a newer gdk-pixbuf than gtk4 requires.
# TODO: Remove the mention of cairomm once pangomm needs to depend on such a new version.
-AC_SUBST([GDKMM_MODULES], ['giomm-2.66 >= 2.65.1 pangomm-2.44 >= 2.43.1 cairomm-1.16 >= 1.15.4 gtk4 >=
3.98.0 gdk-pixbuf-2.0 >= 2.35.5'])
+AC_SUBST([GDKMM_MODULES], ['giomm-2.66 >= 2.65.1 pangomm-2.44 >= 2.43.1 cairomm-1.16 >= 1.15.4 gtk4 >=
3.99.0 gdk-pixbuf-2.0 >= 2.35.5'])
AS_IF([test "x$gtkmm_host_windows" = xyes],
[GTKMM_MODULES=$GDKMM_MODULES],
[GTKMM_MODULES="$GDKMM_MODULES gtk4-unix-print"])
-# Offer the ability to omit some API from the library, to reduce the code size.
-# Note that there are other options in glibmm, which affect gtkmm.
-GTKMM_ARG_ENABLE_API_ATKMM
-
-AS_IF([test "x$gtkmm_enable_api_atkmm" != xno],
- [GTKMM_MODULES="atkmm-2.30 >= 2.29.1 $GTKMM_MODULES"])
AC_SUBST([GTKMM_MODULES])
# gtkmm.pc.in can assume that GDKMM_MODULES is a subset of GTKMM_MODULES,
@@ -121,7 +115,7 @@ PKG_CHECK_MODULES([GTKMM_DEMOS_EXTRA], [$GTKMM_DEMOS_EXTRA_MODULES])
MM_PKG_CONFIG_SUBST([GTHREAD_CFLAGS], [--cflags-only-other gthread-2.0])
MM_PKG_CONFIG_SUBST([GTHREAD_LIBS], [--libs gthread-2.0])
MM_PKG_CONFIG_SUBST([GMMPROC_DIR], [--variable=gmmprocdir glibmm-2.66])
-MM_PKG_CONFIG_SUBST([GMMPROC_EXTRA_M4_DIR], [--variable=gmmprocm4dir pangomm-2.44 atkmm-2.30])
+MM_PKG_CONFIG_SUBST([GMMPROC_EXTRA_M4_DIR], [--variable=gmmprocm4dir pangomm-2.44])
MM_ARG_DISABLE_DEPRECATED_API([GDKMM GTKMM])
@@ -131,7 +125,6 @@ MM_ARG_WITH_TAGFILE_DOC([libsigc++-3.0.tag], [sigc++-3.0])
MM_ARG_WITH_TAGFILE_DOC([glibmm-2.66.tag], [glibmm-2.66])
MM_ARG_WITH_TAGFILE_DOC([cairomm-1.16.tag], [cairomm-1.16])
MM_ARG_WITH_TAGFILE_DOC([pangomm-2.44.tag], [pangomm-2.44])
-MM_ARG_WITH_TAGFILE_DOC([atkmm-2.30.tag], [atkmm-2.30])
# glib-compile-resources and C compiler are needed to generate and compile
# resource files in demo programs.
@@ -146,7 +139,7 @@ AC_CHECK_FUNCS([mkfifo])
MM_ARG_ENABLE_WARNINGS([GTKMM_WXXFLAGS],
[-Wall],
[-pedantic -Wall -Wextra -Wformat-security -Wshadow -Wsuggest-override -Wno-long-long
-DGSEAL_ENABLE],
- [G PANGO ATK GDK GDK_PIXBUF GTK GLIBMM ATKMM PANGOMM CAIROMM SIGCXX])
+ [G PANGO GDK GDK_PIXBUF GTK GLIBMM PANGOMM CAIROMM SIGCXX])
AC_CONFIG_FILES([Makefile
tools/Makefile
diff --git a/demos/gtk-demo/example_builder.ui b/demos/gtk-demo/example_builder.ui
index a6618116..9166cf23 100644
--- a/demos/gtk-demo/example_builder.ui
+++ b/demos/gtk-demo/example_builder.ui
@@ -95,9 +95,6 @@
<property name="program-name" translatable="yes">Gtk::Builder demo</property>
<property name="logo-icon-name" translatable="yes">gtk3-demo</property>
<property name="modal">True</property>
- <accessibility>
- <relation target="window1" type="subwindow-of"/>
- </accessibility>
</object>
<object class="GtkWindow" id="window1">
<property name="default-height">250</property>
@@ -113,11 +110,6 @@
</child>
<child>
<object class="GtkBox" id="toolbar1">
- <child internal-child="accessible">
- <object class="AtkObject" id="a11y-toolbar">
- <property name="AtkObject::accessible-name">The toolbar</property>
- </object>
- </child>
<child>
<object class="GtkButton">
<property name="label" translatable="yes">New</property>
@@ -174,14 +166,6 @@
<object class="GtkTreeView" id="treeview1">
<property name="model">liststore1</property>
<property name="tooltip-column">3</property>
- <child internal-child="accessible">
- <object class="AtkObject" id="a11y-treeview">
- <property name="AtkObject::accessible-name">Name list</property>
- <property name="AtkObject::accessible-description">
- A list of person with name, surname and age columns
- </property>
- </object>
- </child>
<child>
<object class="GtkTreeViewColumn" id="column1">
<property name="title">Name</property>
diff --git a/docs/reference/Doxyfile.in b/docs/reference/Doxyfile.in
index 6990139c..0a819b15 100644
--- a/docs/reference/Doxyfile.in
+++ b/docs/reference/Doxyfile.in
@@ -299,8 +299,7 @@ PREDEFINED = __cplusplus \
"G_GNUC_PURE=" \
GLIBMM_HAVE_WIDE_STREAM \
"GDKMM_API=" \
- "GTKMM_API=" \
- GTKMM_ATKMM_ENABLED
+ "GTKMM_API="
EXPAND_AS_DEFINED = GDKMM_MAJOR_VERSION \
GDKMM_MINOR_VERSION \
GDKMM_MICRO_VERSION \
diff --git a/docs/reference/meson.build b/docs/reference/meson.build
index 1e4c523d..075f475f 100644
--- a/docs/reference/meson.build
+++ b/docs/reference/meson.build
@@ -13,7 +13,6 @@ tag_file_modules = [
'glibmm-2.66',
'cairomm-1.16',
'pangomm-2.44',
- 'atkmm-2.30',
]
doxygen_tagfiles = ''
docinstall_flags = []
diff --git a/gdk/meson.build b/gdk/meson.build
index 09fba715..f3d67569 100644
--- a/gdk/meson.build
+++ b/gdk/meson.build
@@ -3,7 +3,7 @@
# Input: install_prefix, install_libdir, install_datadir, install_includedir,
# gtkmm_pcname, gtkmm_api_version, gtkmm_requires, build_deprecated_api,
# cpp_compiler, gtkmm_major_version, gtkmm_minor_version,
-# gtkmm_micro_version, build_atkmm_api, msvc14x_toolset_ver
+# gtkmm_micro_version, msvc14x_toolset_ver
# Output: pkg_conf_data, install_gdkmmconfigdir, gdkmmconfig_h
pkg_conf_data = configuration_data()
@@ -23,9 +23,6 @@ if not build_deprecated_api
pkg_conf_data.set('GDKMM_DISABLE_DEPRECATED', 1)
pkg_conf_data.set('GTKMM_DISABLE_DEPRECATED', 1)
endif
-if build_atkmm_api
- pkg_conf_data.set('GTKMM_ATKMM_ENABLED', 1)
-endif
pkg_conf_data.set('GDKMM_MAJOR_VERSION', gtkmm_major_version)
pkg_conf_data.set('GDKMM_MINOR_VERSION', gtkmm_minor_version)
pkg_conf_data.set('GDKMM_MICRO_VERSION', gtkmm_micro_version)
diff --git a/gtk/gtkmm/init.cc b/gtk/gtkmm/init.cc
index ddd30bbc..0347aaa0 100644
--- a/gtk/gtkmm/init.cc
+++ b/gtk/gtkmm/init.cc
@@ -18,9 +18,6 @@
#include <glibmm/init.h>
#include <giomm/init.h>
#include <pangomm/wrap_init.h>
-#ifdef GTKMM_ATKMM_ENABLED
-#include <atkmm/wrap_init.h>
-#endif //GTKMM_ATKMM_ENABLED
#include <gdkmm/wrap_init.h>
#include <gtkmm/wrap_init.h>
@@ -38,9 +35,6 @@ void init_gtkmm_internals()
// Populate the map of GTypes to C++ wrap_new() functions.
Pango::wrap_init();
-#ifdef GTKMM_ATKMM_ENABLED
- Atk::wrap_init();
-#endif //GTKMM_ATKMM_ENABLED
Gdk::wrap_init();
Gtk::wrap_init();
diff --git a/gtk/gtkmm/meson.build b/gtk/gtkmm/meson.build
index 06508cb8..cc0e9903 100644
--- a/gtk/gtkmm/meson.build
+++ b/gtk/gtkmm/meson.build
@@ -28,6 +28,7 @@ endforeach
gtkmm_any_hg_ccg_basenames = [
'aboutdialog',
'accellabel',
+ 'accessible',
'actionable',
'actionbar',
'adjustment',
diff --git a/gtk/gtkmmconfig.h.in b/gtk/gtkmmconfig.h.in
index 9a7b8d6a..94d0eaac 100644
--- a/gtk/gtkmmconfig.h.in
+++ b/gtk/gtkmmconfig.h.in
@@ -3,9 +3,6 @@
#include <gdkmmconfig.h>
-/* Defined when the --enable-api-atkmm configure argument was given */
-#undef GTKMM_ATKMM_ENABLED
-
/* Define to omit deprecated API from gtkmm. */
#undef GTKMM_DISABLE_DEPRECATED
diff --git a/gtk/gtkmmconfig.h.meson b/gtk/gtkmmconfig.h.meson
index 36a9317d..dd70c988 100644
--- a/gtk/gtkmmconfig.h.meson
+++ b/gtk/gtkmmconfig.h.meson
@@ -3,9 +3,6 @@
#include <gdkmmconfig.h>
-/* Defined when the -Dbuild-atkmm-api=true configure argument was given */
-#mesondefine GTKMM_ATKMM_ENABLED
-
/* Define to omit deprecated API from gtkmm. */
#mesondefine GTKMM_DISABLE_DEPRECATED
diff --git a/gtk/src/accessible.ccg b/gtk/src/accessible.ccg
new file mode 100644
index 00000000..5aa6fc64
--- /dev/null
+++ b/gtk/src/accessible.ccg
@@ -0,0 +1,19 @@
+/* Copyright (C) 2020 The gtkmm Development Team
+ *
+ * This library 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.
+ *
+ * This library 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, see <http://www.gnu.org/licenses/>.
+ */
+
+#include <gtk/gtk.h>
+
+using Role = Gtk::Accessible::Role;
diff --git a/gtk/src/accessible.hg b/gtk/src/accessible.hg
new file mode 100644
index 00000000..a16f360f
--- /dev/null
+++ b/gtk/src/accessible.hg
@@ -0,0 +1,81 @@
+/* Copyright (C) 2020 The gtkmm Development Team
+ *
+ * This library 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.
+ *
+ * This library 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, see <http://www.gnu.org/licenses/>.
+ */
+
+_CONFIGINCLUDE(gtkmmconfig.h)
+
+#include <glibmm/interface.h>
+#include <glibmm/value.h>
+
+_DEFS(gtkmm,gtk)
+_PINCLUDE(glibmm/private/interface_p.h)
+
+#ifndef DOXYGEN_SHOULD_SKIP_THIS
+extern "C"
+{
+typedef struct _GtkAccessibleInterface GtkAccessibleInterface;
+}
+#endif /* DOXYGEN_SHOULD_SKIP_THIS */
+
+namespace Gtk
+{
+/** %Accessible interface.
+ *
+ * %Gtk::Accessible provides an interface for describing a UI element, like a
+ * Gtk::Widget, in a way that can be consumed by Assistive Technologies, or
+ * “AT”. Every accessible implementation has:
+ *
+ * - a “role”, represented by a value of the Gtk::Accessible::Role enumeration
+ * - an “attribute”, represented by a set of Gtk::Accessible::State,
+ * Gtk::Accessible::Property and Gtk::Accessible::Relation values
+ *
+ * The role cannot be changed after instantiating a %Gtk::Accessible
+ * implementation.
+ *
+ * The attributes are updated every time a UI element's state changes in a way that
+ * should be reflected by assistive technologies. For instance, if a Gtk::Widget
+ * visibility changes, the Gtk::Accessible::State::HIDDEN state will also change
+ * to reflect Gtk::Widget::property_visible().
+ *
+ * @newin{3,98}
+ */
+class GTKMM_API Accessible : public Glib::Interface
+{
+ _CLASS_INTERFACE(Accessible, GtkAccessible, GTK_ACCESSIBLE, GtkAccessibleInterface, , , GTKMM_API)
+
+public:
+ _WRAP_ENUM(Role, GtkAccessibleRole, decl_prefix GTKMM_API)
+ _WRAP_ENUM(State, GtkAccessibleState, decl_prefix GTKMM_API)
+ _WRAP_ENUM(Property, GtkAccessibleProperty, decl_prefix GTKMM_API)
+ _WRAP_ENUM(Relation, GtkAccessibleRelation, decl_prefix GTKMM_API)
+
+ _WRAP_METHOD(Role get_accessible_role() const, gtk_accessible_get_accessible_role)
+
+ _IGNORE(gtk_accessible_update_state, gtk_accessible_update_property, gtk_accessible_update_relation)
+ _WRAP_METHOD(void update_state(State state, const Glib::ValueBase& value),
+ gtk_accessible_update_state_value)
+ _WRAP_METHOD(void update_property(Property property, const Glib::ValueBase& value),
+ gtk_accessible_update_property_value)
+ _WRAP_METHOD(void update_relation(Relation relation, const Glib::ValueBase& value),
+ gtk_accessible_update_relation_value)
+
+ _WRAP_METHOD(void reset_state(State state), gtk_accessible_reset_state)
+ _WRAP_METHOD(void reset_property(Property property), gtk_accessible_reset_property)
+ _WRAP_METHOD(void reset_relation(Relation relation), gtk_accessible_reset_relation)
+
+ _WRAP_PROPERTY("accessible-role", Role)
+};
+
+} // namespace Gtk
diff --git a/gtk/src/application.ccg b/gtk/src/application.ccg
index b7602ece..01891927 100644
--- a/gtk/src/application.ccg
+++ b/gtk/src/application.ccg
@@ -22,9 +22,6 @@
#include <glibmm/init.h>
#include <giomm/init.h>
#include <pangomm/wrap_init.h>
-#ifdef GTKMM_ATKMM_ENABLED
-#include <atkmm/wrap_init.h>
-#endif //GTKMM_ATKMM_ENABLED
#include <gdkmm/wrap_init.h>
#include <gtkmm/wrap_init.h>
#include <locale>
@@ -45,9 +42,6 @@ static void init_gtkmm_internals()
// Populate the map of GTypes to C++ wrap_new() functions.
Pango::wrap_init();
-#ifdef GTKMM_ATKMM_ENABLED
- Atk::wrap_init();
-#endif //GTKMM_ATKMM_ENABLED
Gdk::wrap_init();
Gtk::wrap_init();
diff --git a/gtk/src/filelist.am b/gtk/src/filelist.am
index c7063948..45a0a1fc 100644
--- a/gtk/src/filelist.am
+++ b/gtk/src/filelist.am
@@ -13,6 +13,7 @@ gtkmm_files_defs = \
gtkmm_files_any_hg = \
aboutdialog.hg \
accellabel.hg \
+ accessible.hg \
actionable.hg \
actionbar.hg \
adjustment.hg \
diff --git a/gtk/src/gtk_docs_override.xml b/gtk/src/gtk_docs_override.xml
index 1c16ae7a..d72f5738 100644
--- a/gtk/src/gtk_docs_override.xml
+++ b/gtk/src/gtk_docs_override.xml
@@ -45,6 +45,10 @@
<substitute_type_name from="GtkTreeViewColumnSizing" to="Gtk::TreeViewColumn::Sizing" />
<substitute_type_name from="GtkTreeViewDropPosition" to="Gtk::TreeView::DropPosition" />
<substitute_type_name from="GtkTreeViewGridLines" to="Gtk::TreeView::GridLines" />
+<substitute_type_name from="GtkAccessibleRole" to="Gtk::Accessible::Role" />
+<substitute_type_name from="GtkAccessibleState" to="Gtk::Accessible::State" />
+<substitute_type_name from="GtkAccessibleProperty" to="Gtk::Accessible::Property" />
+<substitute_type_name from="GtkAccessibleRelation" to="Gtk::Accessible::Relation" />
<substitute_enumerator_name from_prefix="GTK_LICENSE_" to_prefix="Gtk::License::" />
<substitute_enumerator_name from_prefix="GTK_ASSISTANT_PAGE_" to_prefix="Gtk::AssistantPage::Type::" />
@@ -126,6 +130,8 @@
<substitute_enumerator_name from_prefix="GTK_CONSTRAINT_RELATION_" to_prefix="Gtk::Constraint::Relation::" />
<substitute_enumerator_name from_prefix="GTK_CONSTRAINT_STRENGTH_" to_prefix="Gtk::Constraint::Strength::" />
<substitute_enumerator_name from_prefix="GTK_ORDERING_" to_prefix="Gtk::Ordering::" />
+<substitute_enumerator_name from_prefix="GTK_ACCESSIBLE_STATE_" to_prefix="Gtk::Accessible::State::" />
+<substitute_enumerator_name from_prefix="GTK_ACCESSIBLE_ROLE_" to_prefix="Gtk::Accessible::Role::" />
<!-- GdkWindowWindowClass is not wrapped in gtkmm. Don't substitute its enumerator names. -->
<substitute_enumerator_name from="GDK_INPUT_ONLY" to="GDK_INPUT_ONLY" />
<substitute_enumerator_name from="GDK_INPUT_OUTPUT" to="GDK_INPUT_OUTPUT" />
diff --git a/gtk/src/gtk_signals.defs b/gtk/src/gtk_signals.defs
index e979d6e2..8020f7d3 100644
--- a/gtk/src/gtk_signals.defs
+++ b/gtk/src/gtk_signals.defs
@@ -187,6 +187,18 @@
(default-value "FALSE")
)
+;; From GtkAccessible
+
+(define-property accessible-role
+ (of-object "GtkAccessible")
+ (prop-type "GParamEnum")
+ (docs "The role of the accessible object")
+ (readable #t)
+ (writable #t)
+ (construct-only #f)
+ (default-value "GTK_ACCESSIBLE_ROLE_NONE")
+)
+
;; From GtkActionable
(define-property action-name
diff --git a/gtk/src/gtk_vfuncs.defs b/gtk/src/gtk_vfuncs.defs
index 00d3a581..f82d1427 100644
--- a/gtk/src/gtk_vfuncs.defs
+++ b/gtk/src/gtk_vfuncs.defs
@@ -896,11 +896,6 @@
)
)
-(define-vfunc get_accessible
- (of-object "GtkWidget")
- (return-type "AtkObject*")
-)
-
(define-vfunc compute_expand
(of-object "GtkWidget")
(return-type "void")
diff --git a/gtk/src/widget.hg b/gtk/src/widget.hg
index e05046e1..0d847c2d 100644
--- a/gtk/src/widget.hg
+++ b/gtk/src/widget.hg
@@ -22,12 +22,8 @@ _CONFIGINCLUDE(gtkmmconfig.h)
#include <pangomm/context.h>
#include <pangomm/layout.h>
-#ifdef GTKMM_ATKMM_ENABLED
-#include <atkmm/object.h>
-#include <atkmm/implementor.h>
-#endif //GTKMM_ATKMM_ENABLED
-
#include <gtkmm/object.h>
+#include <gtkmm/accessible.h>
#include <gtkmm/buildable.h>
#include <gtkmm/constrainttarget.h>
#include <gdkmm/types.h>
@@ -100,21 +96,18 @@ typedef Gdk::Rectangle Allocation;
*/
class GTKMM_API Widget
: public Object,
+ public Accessible,
public Buildable,
public ConstraintTarget
-#ifdef GTKMM_ATKMM_ENABLED
- ,public Atk::Implementor
-#endif //GTKMM_ATKMM_ENABLED
{
_CLASS_GTKOBJECT(Widget,GtkWidget,GTK_WIDGET,Object,GObject,,,GTKMM_API)
+ _IMPLEMENTS_INTERFACE(Accessible)
_IMPLEMENTS_INTERFACE(Buildable)
_IMPLEMENTS_INTERFACE(ConstraintTarget)
- _IMPLEMENTS_INTERFACE(Atk::Implementor, ifdef GTKMM_ATKMM_ENABLED)
_IGNORE(gtk_widget_paintable_new)
public:
- friend class Main;
_CUSTOM_DTOR
_DOCUMENT_DTOR(Destroys the widget. The widget will be automatically removed from the parent container.)
diff --git a/meson.build b/meson.build
index 27a83c82..d5a019b8 100644
--- a/meson.build
+++ b/meson.build
@@ -74,7 +74,6 @@ else
warning_level = get_option('warnings')
endif
build_deprecated_api = get_option('build-deprecated-api')
-build_atkmm_api = get_option('build-atkmm-api')
build_documentation_opt = get_option('build-documentation')
build_documentation = build_documentation_opt == 'true' or \
(build_documentation_opt == 'if-maintainer-mode' and maintainer_mode)
@@ -98,7 +97,7 @@ install_pkgconfigdir = install_libdir / 'pkgconfig'
glibmm_req = '>= 2.65.1'
# Gtk supported pkg-config files on MSVC files for a good while, so just use that
-gtk_req = '>= 3.98.0'
+gtk_req = '>= 3.99.0'
gtk_dep = dependency('gtk4', version: gtk_req)
cairomm_req = '>= 1.15.4'
@@ -110,11 +109,6 @@ pangomm_dep = dependency('pangomm-2.44', version: pangomm_req)
gdk_pixbuf_req = '>= 2.35.5'
gdk_pixbuf_dep = dependency('gdk-pixbuf-2.0', version: gdk_pixbuf_req)
-# atkmm is required in maintainer mode even if atkmm API shall not be built.
-# gmmproc must be able to find atkmm's installed M4 files.
-atkmm_req = '>= 2.29.1'
-atkmm_dep = dependency('atkmm-2.30', version: atkmm_req, required: build_atkmm_api or maintainer_mode)
-
epoxy_req = '>= 1.2'
epoxy_dep = dependency('epoxy', version: epoxy_req, required: build_demos)
@@ -129,9 +123,6 @@ giomm_dep = dependency('giomm-2.@0@'.format(glibmm_req_minor_ver), version: glib
gmmproc_dir = glibmm_dep.get_pkgconfig_variable('gmmprocdir')
gmmproc_extra_m4_dirs = [pangomm_dep.get_pkgconfig_variable('gmmprocm4dir')]
-if atkmm_dep.found()
- gmmproc_extra_m4_dirs += [atkmm_dep.get_pkgconfig_variable('gmmprocm4dir')]
-endif
gdkmm_build_dep = [giomm_dep, gtk_dep, cairomm_dep, pangomm_dep, gdk_pixbuf_dep]
gdkmm_requires = [
@@ -145,11 +136,6 @@ gdkmm_requires = [
gtkmm_build_dep = gdkmm_build_dep
gtkmm_requires = gdkmm_requires
-if build_atkmm_api
- gtkmm_build_dep += [atkmm_dep]
- gtkmm_requires += ['atkmm-2.30', atkmm_req]
-endif
-
# not Windows
if host_machine.system() != 'windows'
gtk_unix_print_dep = dependency('gtk4-unix-print')
@@ -239,7 +225,7 @@ elif warning_level == 'max' or warning_level == 'fatal'
else
warning_flags += ['-Werror']
endif
- deprecations = 'G PANGO ATK GDK GDK_PIXBUF GTK GLIBMM ATKMM PANGOMM CAIROMM SIGCXX'.split()
+ deprecations = 'G PANGO GDK GDK_PIXBUF GTK GLIBMM PANGOMM CAIROMM SIGCXX'.split()
foreach d : deprecations
warning_flags += '-D@0@_DISABLE_DEPRECATED'.format(d)
endforeach
@@ -311,7 +297,6 @@ summary = [
' Maintainer mode: @0@@1@'.format(maintainer_mode_opt, real_maintainer_mode),
' Compiler warnings: @0@'.format(warning_level),
' Build deprecated API: @0@'.format(build_deprecated_api),
- ' Build atkmm API: @0@'.format(build_atkmm_api),
'Build HTML documentation: @0@@1@'.format(build_documentation_opt, real_build_documentation),
' Build demo programs: @0@'.format(build_demos),
' Build test programs: @0@'.format(build_tests),
diff --git a/meson_options.txt b/meson_options.txt
index 92724f20..2009c42d 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -6,8 +6,6 @@ option('dist-warnings', type: 'combo', choices: ['no', 'min', 'max', 'fatal'], v
description: 'Compiler warning level when a tarball is created')
option('build-deprecated-api', type: 'boolean', value: true,
description: 'Build deprecated API and include it in the library')
-option('build-atkmm-api', type: 'boolean', value: true,
- description: 'Build atkmm API and include it in the library')
option('build-documentation', type: 'combo', choices: ['false', 'if-maintainer-mode', 'true'],
value: 'if-maintainer-mode', description: 'Build and install the documentation')
option('build-demos', type: 'boolean', value: true, description: 'Build demo programs')
diff --git a/tools/extra_defs_gen/generate_defs_gtk.cc b/tools/extra_defs_gen/generate_defs_gtk.cc
index 7d5c337e..e7c0de08 100644
--- a/tools/extra_defs_gen/generate_defs_gtk.cc
+++ b/tools/extra_defs_gen/generate_defs_gtk.cc
@@ -44,6 +44,7 @@ int main(int /* argc */, char** /* argv */)
std::cout << get_defs( GTK_TYPE_ABOUT_DIALOG )
<< get_defs( GTK_TYPE_ACCEL_LABEL )
+ << get_defs( GTK_TYPE_ACCESSIBLE )
<< get_defs( GTK_TYPE_ACTIONABLE )
<< get_defs( GTK_TYPE_ACTION_BAR )
<< get_defs( GTK_TYPE_ADJUSTMENT )
diff --git a/tools/m4/convert_gtk.m4 b/tools/m4/convert_gtk.m4
index b5dadec3..a9105931 100644
--- a/tools/m4/convert_gtk.m4
+++ b/tools/m4/convert_gtk.m4
@@ -30,6 +30,10 @@ _CONVERSION(`ui_merge_id',`guint',`$3')
_CONVERSION(`guint',`ui_merge_id',`$3')
# Enums: TODO: It would be nice if gmmproc knew about these automatically.
+_CONV_INCLASS_ENUM(Gtk,Accessible,Role)
+_CONV_INCLASS_ENUM(Gtk,Accessible,State)
+_CONV_INCLASS_ENUM(Gtk,Accessible,Property)
+_CONV_INCLASS_ENUM(Gtk,Accessible,Relation)
_CONV_ENUM(Gtk,Align)
_CONV_ENUM(Gtk,ArrowType)
_CONV_INCLASS_ENUM(Gtk,AssistantPage,Type)
@@ -130,7 +134,6 @@ _CONV_ENUM(Gtk,InputHints)
_CONV_INCLASS_ENUM(Gtk,LevelBar,Mode)
_CONV_ENUM(Gtk,BaselinePosition)
-include(convert_atk.m4)
include(convert_pango.m4)
include(convert_gdk.m4)
diff --git a/tools/m4/convert_gtkmm.m4 b/tools/m4/convert_gtkmm.m4
index 9c5353c4..9e227a4e 100644
--- a/tools/m4/convert_gtkmm.m4
+++ b/tools/m4/convert_gtkmm.m4
@@ -21,10 +21,7 @@ include(convert_base.m4)
include(convert_gtk.m4)
include(convert_gdk.m4)
-# From atkmm: The path to this is obtained in configure.ac:
-include(convert_atk.m4)
-
-# From pangomm: The path to this is obtained in configure.ac:
+# From pangomm: The path to this is obtained in configure.ac or meson.build.
include(convert_pango.m4)
include(convert_glib.m4)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]