[vala] atk: switch to GIR
- From: Evan Nemerson <evann src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vala] atk: switch to GIR
- Date: Fri, 23 Sep 2011 20:08:04 +0000 (UTC)
commit 23284a363946e89d9f7459a9c4dd712e18317ed0
Author: Evan Nemerson <evan coeus-group com>
Date: Fri Sep 23 12:13:19 2011 -0700
atk: switch to GIR
Fixes bug 654402.
vapi/Makefile.am | 2 +-
vapi/atk.vapi | 429 ++++---
vapi/metadata/Atk-1.0-custom.vala | 81 +
vapi/metadata/Atk-1.0.metadata | 63 +
vapi/packages/atk/atk.files | 2 -
vapi/packages/atk/atk.gi | 3035 -------------------------------------
vapi/packages/atk/atk.metadata | 4 -
vapi/packages/atk/atk.namespace | 1 -
8 files changed, 404 insertions(+), 3213 deletions(-)
---
diff --git a/vapi/Makefile.am b/vapi/Makefile.am
index 1d3f1a8..fe2e638 100644
--- a/vapi/Makefile.am
+++ b/vapi/Makefile.am
@@ -256,7 +256,7 @@ GEDIT_GIRDIR=$$($(PKG_CONFIG) gedit --variable=prefix)/share/gedit/gir-1.0
all-bindings: $(BINDINGS)
atk:
- $(GENVAPI) --library $(srcdir)/atk $(PACKAGESDIR)/atk/atk.gi
+ $(GENVAPI) --library $(srcdir)/atk --metadatadir $(METADATADIR) $(METADATADIR)/Atk-1.0-custom.vala $(GIRDIR)/Atk-1.0.gir
clutter-1.0:
$(GENVAPI) --library $(srcdir)/clutter-1.0 --metadatadir $(METADATADIR) $(METADATADIR)/Clutter-1.0-custom.vala --pkg atk --pkg cairo --pkg pango --pkg cogl-1.0 --pkg json-glib-1.0 $(GIRDIR)/Clutter-1.0.gir
diff --git a/vapi/atk.vapi b/vapi/atk.vapi
index 8ee37e7..a57d93b 100644
--- a/vapi/atk.vapi
+++ b/vapi/atk.vapi
@@ -1,25 +1,15 @@
/* atk.vapi generated by vapigen, do not modify. */
-[CCode (gir_namespace = "Atk", gir_version = "1.0")]
+[CCode (cprefix = "Atk", gir_namespace = "Atk", gir_version = "1.0", lower_case_cprefix = "atk_")]
namespace Atk {
- [CCode (cheader_filename = "atk/atk.h")]
- [Compact]
- public class Attribute {
- public weak string name;
- public weak string value;
- }
- [CCode (cheader_filename = "atk/atk.h")]
- [Compact]
- public class AttributeSet {
- }
- [CCode (cheader_filename = "atk/atk.h")]
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_gobject_accessible_get_type ()")]
public class GObjectAccessible : Atk.Object {
[CCode (has_construct_function = false)]
protected GObjectAccessible ();
public static unowned Atk.Object for_object (GLib.Object obj);
public unowned GLib.Object get_object ();
}
- [CCode (cheader_filename = "atk/atk.h")]
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_hyperlink_get_type ()")]
public class Hyperlink : GLib.Object, Atk.Action {
[CCode (has_construct_function = false)]
protected Hyperlink ();
@@ -27,8 +17,9 @@ namespace Atk {
public virtual int get_n_anchors ();
public virtual unowned Atk.Object get_object (int i);
public virtual int get_start_index ();
- public virtual unowned string get_uri (int i);
+ public virtual string get_uri (int i);
public bool is_inline ();
+ [NoWrapper]
public virtual bool is_selected_link ();
public virtual bool is_valid ();
[NoWrapper]
@@ -41,19 +32,7 @@ namespace Atk {
public int start_index { get; }
public virtual signal void link_activated ();
}
- [CCode (cheader_filename = "atk/atk.h")]
- [Compact]
- public class KeyEventStruct {
- public uint16 keycode;
- public uint keyval;
- public int length;
- public uint state;
- [CCode (cname = "string")]
- public weak string str;
- public uint32 timestamp;
- public int type;
- }
- [CCode (cheader_filename = "atk/atk.h")]
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_misc_get_type ()")]
public class Misc : GLib.Object {
[CCode (has_construct_function = false)]
protected Misc ();
@@ -61,17 +40,17 @@ namespace Atk {
public virtual void threads_enter ();
public virtual void threads_leave ();
}
- [CCode (cheader_filename = "atk/atk.h")]
- public class NoOpObject : Atk.Object, Atk.Component, Atk.Action, Atk.EditableText, Atk.Image, Atk.Selection, Atk.Table, Atk.Text, Atk.Hypertext, Atk.Value, Atk.Document {
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_no_op_object_get_type ()")]
+ public class NoOpObject : Atk.Object, Atk.Action, Atk.Component, Atk.Document, Atk.EditableText, Atk.Hypertext, Atk.Image, Atk.Selection, Atk.Table, Atk.Text, Atk.Value, Atk.Window {
[CCode (has_construct_function = false, type = "AtkObject*")]
public NoOpObject (GLib.Object obj);
}
- [CCode (cheader_filename = "atk/atk.h")]
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_no_op_object_factory_get_type ()")]
public class NoOpObjectFactory : Atk.ObjectFactory {
[CCode (has_construct_function = false, type = "AtkObjectFactory*")]
public NoOpObjectFactory ();
}
- [CCode (cheader_filename = "atk/atk.h")]
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_object_get_type ()")]
public class Object : GLib.Object {
public weak string description;
public Atk.Layer layer;
@@ -82,10 +61,12 @@ namespace Atk {
protected Object ();
public bool add_relationship (Atk.RelationType relationship, Atk.Object target);
public virtual uint connect_property_change_handler (Atk.PropertyChangeHandler handler);
- public virtual unowned Atk.AttributeSet get_attributes ();
+ public virtual unowned GLib.SList<Atk.Attribute?> get_attributes ();
public virtual unowned string get_description ();
public virtual int get_index_in_parent ();
+ [NoWrapper]
public virtual Atk.Layer get_layer ();
+ [NoWrapper]
public virtual int get_mdi_zorder ();
public int get_n_accessible_children ();
[NoWrapper]
@@ -95,11 +76,9 @@ namespace Atk {
public virtual Atk.Role get_role ();
public virtual void initialize (void* data);
public void notify_state_change (Atk.State state, bool value);
- public unowned Atk.Object ref_accessible_child (int i);
- [NoWrapper]
- public virtual unowned Atk.Object ref_child (int i);
- public virtual unowned Atk.RelationSet ref_relation_set ();
- public virtual unowned Atk.StateSet ref_state_set ();
+ public Atk.Object ref_accessible_child (int i);
+ public virtual Atk.RelationSet ref_relation_set ();
+ public virtual Atk.StateSet ref_state_set ();
public virtual void remove_property_change_handler (uint handler_id);
public bool remove_relationship (Atk.RelationType relationship, Atk.Object target);
public virtual void set_description (string description);
@@ -139,39 +118,44 @@ namespace Atk {
public virtual signal void active_descendant_changed (void* child);
public virtual signal void children_changed (uint change_index, void* changed_child);
public virtual signal void focus_event (bool focus_in);
- public virtual signal void property_change (void* values);
+ public signal void property_change (void* object);
public virtual signal void state_change (string name, bool state_set);
public virtual signal void visible_data_changed ();
}
- [CCode (cheader_filename = "atk/atk.h")]
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_object_factory_get_type ()")]
public class ObjectFactory : GLib.Object {
[CCode (has_construct_function = false)]
protected ObjectFactory ();
- public virtual unowned Atk.Object create_accessible (GLib.Object obj);
- public virtual GLib.Type get_accessible_type ();
+ public Atk.Object create_accessible (GLib.Object obj);
+ public GLib.Type get_accessible_type ();
public virtual void invalidate ();
}
- [CCode (cheader_filename = "atk/atk.h")]
- public class Plug : Atk.Object {
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_plug_get_type ()")]
+ public class Plug : Atk.Object, Atk.Component {
[CCode (has_construct_function = false, type = "AtkObject*")]
public Plug ();
- public unowned string get_id ();
+ public string get_id ();
[NoWrapper]
- public virtual unowned string get_object_id ();
+ public virtual string get_object_id ();
}
- [CCode (cheader_filename = "atk/atk.h")]
+ [CCode (cheader_filename = "atk/atk.h", copy_function = "g_boxed_copy", free_function = "g_boxed_free", type_id = "atk_rectangle_get_type ()")]
[Compact]
- public class PropertyValues {
- public GLib.Value new_value;
- public GLib.Value old_value;
- public weak string property_name;
+ public class Rectangle {
+ public int height;
+ public int width;
+ public int x;
+ public int y;
}
[CCode (cheader_filename = "atk/atk.h")]
public class Registry : GLib.Object {
- public weak GLib.HashTable factory_singleton_cache;
- public weak GLib.HashTable factory_type_registry;
+ [Deprecated]
+ public weak GLib.HashTable<GLib.Type,Atk.ObjectFactory> factory_singleton_cache;
+ [Deprecated]
+ public weak GLib.HashTable<GLib.Type,GLib.Type> factory_type_registry;
[CCode (has_construct_function = false)]
protected Registry ();
+ [CCode (cheader_filename = "atk/atk.h", cname = "atk_get_default_registry")]
+ public static Atk.Registry get_default ();
public unowned Atk.ObjectFactory get_factory (GLib.Type type);
public GLib.Type get_factory_type (GLib.Type type);
public void set_factory_type (GLib.Type type, GLib.Type factory_type);
@@ -180,22 +164,26 @@ namespace Atk {
public class Relation : GLib.Object {
public Atk.RelationType relationship;
[CCode (has_construct_function = false)]
- public Relation (Atk.Object[] targets, Atk.RelationType relationship);
+ public Relation ([CCode (array_length_cname = "n_targets", array_length_pos = 1.5, type = "AtkObject**")] Atk.Object[] targets, Atk.RelationType relationship);
public void add_target (Atk.Object target);
public Atk.RelationType get_relation_type ();
- public unowned GLib.PtrArray get_target ();
+ public unowned GLib.GenericArray<Atk.Object> get_target ();
public bool remove_target (Atk.Object target);
+ [Deprecated (replacement = "RelationType.for_name", since = "vala-0.16")]
public static Atk.RelationType type_for_name (string name);
+ [Deprecated (replacement = "RelationType.get_name", since = "vala-0.16")]
public static unowned string type_get_name (Atk.RelationType type);
+ [Deprecated (replacement = "RelationType.register", since = "vala-0.16")]
public static Atk.RelationType type_register (string name);
[NoAccessorMethod]
public Atk.RelationType relation_type { get; set; }
[NoAccessorMethod]
public GLib.ValueArray target { owned get; set; }
}
- [CCode (cheader_filename = "atk/atk.h")]
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_relation_set_get_type ()")]
public class RelationSet : GLib.Object {
- public weak GLib.PtrArray relations;
+ [Deprecated]
+ public weak GLib.GenericArray<Atk.Relation> relations;
[CCode (has_construct_function = false)]
public RelationSet ();
public void add (Atk.Relation relation);
@@ -206,66 +194,71 @@ namespace Atk {
public unowned Atk.Relation get_relation_by_type (Atk.RelationType relationship);
public void remove (Atk.Relation relation);
}
- [CCode (cheader_filename = "atk/atk.h")]
- public class Socket : Atk.Object {
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_socket_get_type ()")]
+ public class Socket : Atk.Object, Atk.Component {
+ [Deprecated]
public weak string embedded_plug_id;
[CCode (has_construct_function = false, type = "AtkObject*")]
public Socket ();
public virtual void embed (string plug_id);
public bool is_occupied ();
}
- [CCode (cheader_filename = "atk/atk.h")]
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_state_set_get_type ()")]
public class StateSet : GLib.Object {
[CCode (has_construct_function = false)]
public StateSet ();
public bool add_state (Atk.StateType type);
- public void add_states (Atk.StateType[] types);
- public unowned Atk.StateSet and_sets (Atk.StateSet compare_set);
+ public void add_states ([CCode (array_length_cname = "n_types", array_length_pos = 1.1, type = "AtkStateType*")] Atk.StateType[] types);
+ public Atk.StateSet and_sets (Atk.StateSet compare_set);
public void clear_states ();
public bool contains_state (Atk.StateType type);
- public bool contains_states (Atk.StateType[] types);
+ public bool contains_states ([CCode (array_length_cname = "n_types", array_length_pos = 1.1, type = "AtkStateType*")] Atk.StateType[] types);
public bool is_empty ();
- public unowned Atk.StateSet or_sets (Atk.StateSet compare_set);
+ public Atk.StateSet or_sets (Atk.StateSet compare_set);
public bool remove_state (Atk.StateType type);
- public unowned Atk.StateSet xor_sets (Atk.StateSet compare_set);
+ public Atk.StateSet xor_sets (Atk.StateSet compare_set);
}
- [CCode (cheader_filename = "atk/atk.h")]
+ [CCode (cheader_filename = "atk/atk.h", copy_function = "g_boxed_copy", free_function = "g_boxed_free", has_destroy_function = false, type_id = "atk_text_range_get_type ()")]
[Compact]
public class TextRange {
- public weak Atk.TextRectangle bounds;
- public weak string content;
+ public Atk.TextRectangle bounds;
+ public string content;
public int end_offset;
public int start_offset;
}
- [CCode (cheader_filename = "atk/atk.h")]
- [Compact]
- public class TextRectangle {
- public int height;
- public int width;
- public int x;
- public int y;
- }
- [CCode (cheader_filename = "atk/atk.h")]
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_util_get_type ()")]
public class Util : GLib.Object {
[CCode (has_construct_function = false)]
protected Util ();
- [NoWrapper]
- public virtual uint add_global_event_listener (GLib.SignalEmissionHook listener, string event_type);
- [NoWrapper]
- public virtual uint add_key_event_listener (Atk.KeySnoopFunc listener, void* data);
- [NoWrapper]
- public virtual unowned Atk.Object get_root ();
- [NoWrapper]
- public virtual unowned string get_toolkit_name ();
- [NoWrapper]
- public virtual unowned string get_toolkit_version ();
- [NoWrapper]
- public virtual void remove_global_event_listener (uint listener_id);
- [NoWrapper]
- public virtual void remove_key_event_listener (uint listener_id);
- }
- [CCode (cheader_filename = "atk/atk.h")]
- public interface Action {
+ [CCode (cheader_filename = "atk/atk.h", cname = "atk_add_focus_tracker")]
+ public static uint add_focus_tracker (Atk.EventListener focus_tracker);
+ [CCode (cheader_filename = "atk/atk.h", cname = "atk_add_global_event_listener")]
+ public static uint add_global_event_listener (GLib.SignalEmissionHook listener, string event_type);
+ [CCode (cheader_filename = "atk/atk.h", cname = "atk_add_key_event_listener")]
+ public static uint add_key_event_listener (Atk.KeySnoopFunc listener);
+ [CCode (cheader_filename = "atk/atk.h", cname = "atk_focus_tracker_init")]
+ public static void focus_tracker_init (Atk.EventListenerInit init);
+ [CCode (cheader_filename = "atk/atk.h", cname = "atk_focus_tracker_notify")]
+ public static void focus_tracker_notify (Atk.Object object);
+ [CCode (cheader_filename = "atk/atk.h", cname = "atk_get_focus_object")]
+ public static unowned Atk.Object get_focus_object ();
+ [CCode (cheader_filename = "atk/atk.h", cname = "atk_get_root")]
+ public static unowned Atk.Object get_root ();
+ [CCode (cheader_filename = "atk/atk.h", cname = "atk_get_toolkit_name")]
+ public static unowned string get_toolkit_name ();
+ [CCode (cheader_filename = "atk/atk.h", cname = "atk_get_toolkit_version")]
+ public static unowned string get_toolkit_version ();
+ [CCode (cheader_filename = "atk/atk.h", cname = "atk_get_version")]
+ public static unowned string get_version ();
+ [CCode (cheader_filename = "atk/atk.h", cname = "atk_remove_focus_tracker")]
+ public static void remove_focus_tracker (uint tracker_id);
+ [CCode (cheader_filename = "atk/atk.h", cname = "atk_remove_global_event_listener")]
+ public static void remove_global_event_listener (uint listener_id);
+ [CCode (cheader_filename = "atk/atk.h", cname = "atk_remove_key_event_listener")]
+ public static void remove_key_event_listener (uint listener_id);
+ }
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_action_get_type ()")]
+ public interface Action : GLib.Object {
public abstract bool do_action (int i);
public abstract unowned string get_description (int i);
public abstract unowned string get_keybinding (int i);
@@ -274,9 +267,8 @@ namespace Atk {
public abstract unowned string get_name (int i);
public abstract bool set_description (int i, string desc);
}
- [CCode (cheader_filename = "atk/atk.h")]
- public interface Component {
- public abstract uint add_focus_handler (Atk.FocusHandler handler);
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_component_get_type ()")]
+ public interface Component : GLib.Object {
public abstract bool contains (int x, int y, Atk.CoordType coord_type);
public abstract double get_alpha ();
public abstract void get_extents (int x, int y, int width, int height, Atk.CoordType coord_type);
@@ -285,23 +277,22 @@ namespace Atk {
public abstract void get_position (int x, int y, Atk.CoordType coord_type);
public abstract void get_size (int width, int height);
public abstract bool grab_focus ();
- public abstract unowned Atk.Object ref_accessible_at_point (int x, int y, Atk.CoordType coord_type);
+ public abstract Atk.Object ref_accessible_at_point (int x, int y, Atk.CoordType coord_type);
public abstract void remove_focus_handler (uint handler_id);
public abstract bool set_extents (int x, int y, int width, int height, Atk.CoordType coord_type);
public abstract bool set_position (int x, int y, Atk.CoordType coord_type);
public abstract bool set_size (int width, int height);
- public signal void bounds_changed (Atk.Rectangle bounds);
+ public virtual signal void bounds_changed (Atk.Rectangle bounds);
}
- [CCode (cheader_filename = "atk/atk.h")]
- public interface Document {
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_document_get_type ()")]
+ public interface Document : GLib.Object {
public unowned string get_attribute_value (string attribute_name);
- public unowned Atk.AttributeSet get_attributes ();
+ [CCode (vfunc_name = "get_document_attributes")]
+ public virtual unowned GLib.SList<Atk.Attribute?> get_attributes ();
public abstract void* get_document ();
[NoWrapper]
public abstract unowned string get_document_attribute_value (string attribute_name);
[NoWrapper]
- public abstract unowned Atk.AttributeSet get_document_attributes ();
- [NoWrapper]
public abstract unowned string get_document_locale ();
public abstract unowned string get_document_type ();
public unowned string get_locale ();
@@ -312,29 +303,29 @@ namespace Atk {
public signal void load_stopped ();
public signal void reload ();
}
- [CCode (cheader_filename = "atk/atk.h")]
- public interface EditableText {
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_editable_text_get_type ()")]
+ public interface EditableText : GLib.Object {
public abstract void copy_text (int start_pos, int end_pos);
public abstract void cut_text (int start_pos, int end_pos);
public abstract void delete_text (int start_pos, int end_pos);
- public abstract void insert_text (string str, int length, int position);
+ public abstract void insert_text (string string, int length, int position);
public abstract void paste_text (int position);
- public abstract bool set_run_attributes (Atk.AttributeSet attrib_set, int start_offset, int end_offset);
- public abstract void set_text_contents (string str);
+ public abstract bool set_run_attributes ([CCode (type = "AtkAttributeSet*")] GLib.SList<Atk.Attribute?> attrib_set, int start_offset, int end_offset);
+ public abstract void set_text_contents (string string);
}
- [CCode (cheader_filename = "atk/atk.h")]
- public interface HyperlinkImpl {
- public abstract unowned Atk.Hyperlink get_hyperlink ();
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_hyperlink_impl_get_type ()")]
+ public interface HyperlinkImpl : GLib.Object {
+ public abstract Atk.Hyperlink get_hyperlink ();
}
- [CCode (cheader_filename = "atk/atk.h")]
- public interface Hypertext {
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_hypertext_get_type ()")]
+ public interface Hypertext : GLib.Object {
public abstract unowned Atk.Hyperlink get_link (int link_index);
public abstract int get_link_index (int char_index);
public abstract int get_n_links ();
- public signal void link_selected (int link_index);
+ public virtual signal void link_selected (int link_index);
}
- [CCode (cheader_filename = "atk/atk.h")]
- public interface Image {
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_image_get_type ()")]
+ public interface Image : GLib.Object {
public abstract unowned string get_image_description ();
public abstract unowned string get_image_locale ();
public abstract void get_image_position (int x, int y, Atk.CoordType coord_type);
@@ -342,29 +333,32 @@ namespace Atk {
public abstract bool set_image_description (string description);
}
[CCode (cheader_filename = "atk/atk.h")]
- public interface Implementor {
+ public interface Implementor : GLib.Object {
public abstract unowned Atk.Object ref_accessible ();
}
- [CCode (cheader_filename = "atk/atk.h")]
- public interface Selection {
+ [CCode (cheader_filename = "atk/atk.h", lower_case_csuffix = "implementor", type_id = "atk_implementor_get_type ()")]
+ public interface ImplementorIface : GLib.Object {
+ }
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_selection_get_type ()")]
+ public interface Selection : GLib.Object {
public abstract bool add_selection (int i);
public abstract bool clear_selection ();
public abstract int get_selection_count ();
public abstract bool is_child_selected (int i);
- public abstract unowned Atk.Object ref_selection (int i);
+ public abstract Atk.Object ref_selection (int i);
public abstract bool remove_selection (int i);
public abstract bool select_all_selection ();
- public signal void selection_changed ();
+ public virtual signal void selection_changed ();
}
- [CCode (cheader_filename = "atk/atk.h")]
- public interface StreamableContent {
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_streamable_content_get_type ()")]
+ public interface StreamableContent : GLib.Object {
public abstract unowned string get_mime_type (int i);
public abstract int get_n_mime_types ();
- public abstract unowned GLib.IOChannel get_stream (string mime_type);
+ public abstract GLib.IOChannel get_stream (string mime_type);
public abstract unowned string get_uri (string mime_type);
}
- [CCode (cheader_filename = "atk/atk.h")]
- public interface Table {
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_table_get_type ()")]
+ public interface Table : GLib.Object {
public abstract bool add_column_selection (int column);
public abstract bool add_row_selection (int row);
public abstract unowned Atk.Object get_caption ();
@@ -381,11 +375,11 @@ namespace Atk {
public abstract unowned Atk.Object get_row_header (int row);
public abstract int get_selected_columns (int selected);
public abstract int get_selected_rows (int selected);
- public abstract unowned Atk.Object get_summary ();
+ public abstract Atk.Object get_summary ();
public abstract bool is_column_selected (int column);
public abstract bool is_row_selected (int row);
public abstract bool is_selected (int row, int column);
- public abstract unowned Atk.Object ref_at (int row, int column);
+ public abstract Atk.Object ref_at (int row, int column);
public abstract bool remove_column_selection (int column);
public abstract bool remove_row_selection (int row);
public abstract void set_caption (Atk.Object caption);
@@ -394,67 +388,106 @@ namespace Atk {
public abstract void set_row_description (int row, string description);
public abstract void set_row_header (int row, Atk.Object header);
public abstract void set_summary (Atk.Object accessible);
- public signal void column_deleted (int column, int num_deleted);
- public signal void column_inserted (int column, int num_inserted);
- public signal void column_reordered ();
- public signal void model_changed ();
- public signal void row_deleted (int row, int num_deleted);
- public signal void row_inserted (int row, int num_inserted);
- public signal void row_reordered ();
+ public virtual signal void column_deleted (int column, int num_deleted);
+ public virtual signal void column_inserted (int column, int num_inserted);
+ public virtual signal void column_reordered ();
+ public virtual signal void model_changed ();
+ public virtual signal void row_deleted (int row, int num_deleted);
+ public virtual signal void row_inserted (int row, int num_inserted);
+ public virtual signal void row_reordered ();
}
[CCode (cheader_filename = "atk/atk.h")]
- public interface Text {
+ public interface Text : GLib.Object {
public abstract bool add_selection (int start_offset, int end_offset);
+ [Deprecated (replacement = "TextAttribute.for_name", since = "vala-0.16")]
public static Atk.TextAttribute attribute_for_name (string name);
+ [Deprecated (replacement = "TextAttribute.get_name", since = "vala-0.16")]
public static unowned string attribute_get_name (Atk.TextAttribute attr);
+ [Deprecated (replacement = "TextAttribute.get_value", since = "vala-0.16")]
public static unowned string attribute_get_value (Atk.TextAttribute attr, int index_);
+ [Deprecated (replacement = "TextAttribute.register", since = "vala-0.16")]
public static Atk.TextAttribute attribute_register (string name);
- public static void free_ranges (out unowned Atk.TextRange ranges);
- public abstract unowned Atk.TextRange get_bounded_ranges (Atk.TextRectangle rect, Atk.CoordType coord_type, Atk.TextClipType x_clip_type, Atk.TextClipType y_clip_type);
+ public static void free_ranges ([CCode (array_length = false, type = "AtkTextRange**")] Atk.TextRange[] ranges);
+ [CCode (array_length = false, array_null_terminated = true)]
+ public virtual Atk.TextRange[] get_bounded_ranges (Atk.TextRectangle rect, Atk.CoordType coord_type, Atk.TextClipType x_clip_type, Atk.TextClipType y_clip_type);
public abstract int get_caret_offset ();
public abstract unichar get_character_at_offset (int offset);
public abstract int get_character_count ();
public abstract void get_character_extents (int offset, int x, int y, int width, int height, Atk.CoordType coords);
- public abstract unowned Atk.AttributeSet get_default_attributes ();
+ public abstract GLib.SList<Atk.Attribute?> get_default_attributes ();
public abstract int get_n_selections ();
public abstract int get_offset_at_point (int x, int y, Atk.CoordType coords);
public abstract void get_range_extents (int start_offset, int end_offset, Atk.CoordType coord_type, Atk.TextRectangle rect);
- public abstract unowned Atk.AttributeSet get_run_attributes (int offset, int start_offset, int end_offset);
- public abstract unowned string get_selection (int selection_num, int start_offset, int end_offset);
- public abstract unowned string get_text (int start_offset, int end_offset);
- public abstract unowned string get_text_after_offset (int offset, Atk.TextBoundary boundary_type, int start_offset, int end_offset);
- public abstract unowned string get_text_at_offset (int offset, Atk.TextBoundary boundary_type, int start_offset, int end_offset);
- public abstract unowned string get_text_before_offset (int offset, Atk.TextBoundary boundary_type, int start_offset, int end_offset);
+ public abstract GLib.SList<Atk.Attribute?> get_run_attributes (int offset, out int start_offset, out int end_offset);
+ public abstract string get_selection (int selection_num, out int start_offset, out int end_offset);
+ public abstract string get_text (int start_offset, int end_offset);
+ public abstract string get_text_after_offset (int offset, Atk.TextBoundary boundary_type, out int start_offset, out int end_offset);
+ public abstract string get_text_at_offset (int offset, Atk.TextBoundary boundary_type, out int start_offset, out int end_offset);
+ public abstract string get_text_before_offset (int offset, Atk.TextBoundary boundary_type, out int start_offset, out int end_offset);
public abstract bool remove_selection (int selection_num);
public abstract bool set_caret_offset (int offset);
public abstract bool set_selection (int selection_num, int start_offset, int end_offset);
- public signal void text_attributes_changed ();
- public signal void text_caret_moved (int location);
- public signal void text_changed (int position, int length);
- public signal void text_selection_changed ();
- }
- [CCode (cheader_filename = "atk/atk.h")]
- public interface Value {
+ public virtual signal void text_attributes_changed ();
+ public virtual signal void text_caret_moved (int location);
+ public virtual signal void text_changed (int position, int length);
+ public signal void text_insert (int object, int p0, string p1);
+ public signal void text_remove (int object, int p0, string p1);
+ public virtual signal void text_selection_changed ();
+ public signal void text_update (int object, int p0, int p1, string p2);
+ }
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_value_get_type ()")]
+ public interface Value : GLib.Object {
public abstract void get_current_value (GLib.Value value);
public abstract void get_maximum_value (GLib.Value value);
public abstract void get_minimum_increment (GLib.Value value);
public abstract void get_minimum_value (GLib.Value value);
public abstract bool set_current_value (GLib.Value value);
}
+ [CCode (cheader_filename = "atk/atk.h", type_id = "atk_window_get_type ()")]
+ public interface Window : Atk.Object {
+ public signal void activate ();
+ public signal void create ();
+ public signal void deactivate ();
+ public signal void destroy ();
+ public signal void maximize ();
+ public signal void minimize ();
+ public signal void move ();
+ public signal void resize ();
+ public signal void restore ();
+ }
+ [CCode (cheader_filename = "atk/atk.h", has_destroy_function = false)]
+ public struct Attribute {
+ public string name;
+ public string value;
+ }
+ [CCode (cheader_filename = "atk/atk.h")]
+ public struct KeyEventStruct {
+ public int type;
+ public uint state;
+ public uint keyval;
+ public int length;
+ public weak string str;
+ public uint16 keycode;
+ public uint32 timestamp;
+ }
+ [CCode (cheader_filename = "atk/atk.h", cname = "_AtkPropertyValues")]
+ [GIR (name = "_PropertyValues")]
+ public struct PropertyValues {
+ public weak string property_name;
+ public GLib.Value old_value;
+ public GLib.Value new_value;
+ }
+ [CCode (cheader_filename = "atk/atk.h")]
+ [SimpleType]
+ public struct State : uint64 {
+ }
[CCode (cheader_filename = "atk/atk.h")]
- public struct Rectangle {
+ public struct TextRectangle {
public int x;
public int y;
public int width;
public int height;
}
- [CCode (cheader_filename = "atk/atk.h")]
- [SimpleType]
- public struct State : uint64 {
- public static Atk.StateType type_for_name (string name);
- public static unowned string type_get_name (Atk.StateType type);
- public static Atk.StateType type_register (string name);
- }
[CCode (cheader_filename = "atk/atk.h", cprefix = "ATK_XY_")]
public enum CoordType {
SCREEN,
@@ -501,7 +534,13 @@ namespace Atk {
DESCRIBED_BY,
DESCRIPTION_FOR,
NODE_PARENT_OF,
- LAST_DEFINED
+ LAST_DEFINED;
+ [CCode (cheader_filename = "atk/atk.h")]
+ public static Atk.RelationType for_name (string name);
+ [CCode (cheader_filename = "atk/atk.h")]
+ public static unowned string get_name (Atk.RelationType type);
+ [CCode (cheader_filename = "atk/atk.h")]
+ public static Atk.RelationType register (string name);
}
[CCode (cheader_filename = "atk/atk.h", cprefix = "ATK_ROLE_")]
public enum Role {
@@ -593,7 +632,28 @@ namespace Atk {
FORM,
LINK,
INPUT_METHOD_WINDOW,
- LAST_DEFINED
+ TABLE_ROW,
+ TREE_ITEM,
+ DOCUMENT_SPREADSHEET,
+ DOCUMENT_PRESENTATION,
+ DOCUMENT_TEXT,
+ DOCUMENT_WEB,
+ DOCUMENT_EMAIL,
+ COMMENT,
+ LIST_BOX,
+ GROUPING,
+ IMAGE_MAP,
+ NOTIFICATION,
+ INFO_BAR,
+ LAST_DEFINED;
+ [CCode (cheader_filename = "atk/atk.h")]
+ public static Atk.Role for_name (string name);
+ [CCode (cheader_filename = "atk/atk.h")]
+ public static unowned string get_localized_name (Atk.Role role);
+ [CCode (cheader_filename = "atk/atk.h")]
+ public static unowned string get_name (Atk.Role role);
+ [CCode (cheader_filename = "atk/atk.h")]
+ public static Atk.Role register (string name);
}
[CCode (cheader_filename = "atk/atk.h", cprefix = "ATK_STATE_")]
public enum StateType {
@@ -636,7 +696,13 @@ namespace Atk {
DEFAULT,
ANIMATED,
VISITED,
- LAST_DEFINED
+ LAST_DEFINED;
+ [CCode (cheader_filename = "atk/atk.h")]
+ public static Atk.StateType for_name (string name);
+ [CCode (cheader_filename = "atk/atk.h")]
+ public static unowned string get_name (Atk.StateType type);
+ [CCode (cheader_filename = "atk/atk.h")]
+ public static Atk.StateType register (string name);
}
[CCode (cheader_filename = "atk/atk.h", cprefix = "ATK_TEXT_ATTR_")]
public enum TextAttribute {
@@ -668,7 +734,15 @@ namespace Atk {
STRETCH,
VARIANT,
STYLE,
- LAST_DEFINED
+ LAST_DEFINED;
+ [CCode (cheader_filename = "atk/atk.h")]
+ public static Atk.TextAttribute for_name (string name);
+ [CCode (cheader_filename = "atk/atk.h")]
+ public static unowned string get_name (Atk.TextAttribute attr);
+ [CCode (cheader_filename = "atk/atk.h")]
+ public static unowned string get_value (Atk.TextAttribute attr, int index_);
+ [CCode (cheader_filename = "atk/atk.h")]
+ public static Atk.TextAttribute register (string name);
}
[CCode (cheader_filename = "atk/atk.h", cprefix = "ATK_TEXT_BOUNDARY_")]
public enum TextBoundary {
@@ -692,47 +766,62 @@ namespace Atk {
[CCode (cheader_filename = "atk/atk.h", has_target = false)]
public delegate void EventListenerInit ();
[CCode (cheader_filename = "atk/atk.h", has_target = false)]
- public delegate void FocusHandler (Atk.Object p1, bool p2);
+ public delegate void FocusHandler (Atk.Object arg0, bool arg1);
[CCode (cheader_filename = "atk/atk.h")]
public delegate bool Function ();
+ [CCode (cheader_filename = "atk/atk.h")]
+ public delegate int KeySnoopFunc (Atk.KeyEventStruct event);
[CCode (cheader_filename = "atk/atk.h", has_target = false)]
- public delegate int KeySnoopFunc (Atk.KeyEventStruct event, void* func_data);
- [CCode (cheader_filename = "atk/atk.h", has_target = false)]
- public delegate void PropertyChangeHandler (Atk.Object p1, Atk.PropertyValues p2);
+ public delegate void PropertyChangeHandler (Atk.Object Param1, Atk.PropertyValues Param2);
[CCode (cheader_filename = "atk/atk.h")]
+ [Deprecated (replacement = "Atk.Util.add_focus_tracker", since = "vala-0.16")]
public static uint add_focus_tracker (Atk.EventListener focus_tracker);
[CCode (cheader_filename = "atk/atk.h")]
+ [Deprecated (replacement = "Atk.Util.add_global_event_listener", since = "vala-0.16")]
public static uint add_global_event_listener (GLib.SignalEmissionHook listener, string event_type);
[CCode (cheader_filename = "atk/atk.h")]
- public static uint add_key_event_listener (Atk.KeySnoopFunc listener, void* data);
- [CCode (cheader_filename = "atk/atk.h")]
+ [Deprecated (replacement = "Atk.Util.focus_tracker_init", since = "vala-0.16")]
public static void focus_tracker_init (Atk.EventListenerInit init);
[CCode (cheader_filename = "atk/atk.h")]
+ [Deprecated (replacement = "Atk.Util.focus_tracker_notify", since = "vala-0.16")]
public static void focus_tracker_notify (Atk.Object object);
[CCode (cheader_filename = "atk/atk.h")]
+ [Deprecated (replacement = "Atk.Registry.get_default.", since = "vala-0.16")]
public static unowned Atk.Registry get_default_registry ();
[CCode (cheader_filename = "atk/atk.h")]
+ [Deprecated (replacement = "Atk.Util.get_focus_object", since = "vala-0.16")]
public static unowned Atk.Object get_focus_object ();
[CCode (cheader_filename = "atk/atk.h")]
+ [Deprecated (replacement = "Atk.Util.get_root", since = "vala-0.16")]
public static unowned Atk.Object get_root ();
[CCode (cheader_filename = "atk/atk.h")]
+ [Deprecated (replacement = "Atk.Util.get_toolkit_name", since = "vala-0.16")]
public static unowned string get_toolkit_name ();
[CCode (cheader_filename = "atk/atk.h")]
+ [Deprecated (replacement = "Atk.Util.get_toolkit_version", since = "vala-0.16")]
public static unowned string get_toolkit_version ();
[CCode (cheader_filename = "atk/atk.h")]
+ [Deprecated (replacement = "Atk.Util.get_version", since = "vala-0.16")]
public static unowned string get_version ();
[CCode (cheader_filename = "atk/atk.h")]
+ [Deprecated (replacement = "Atk.Util.remove_focus_tracker", since = "vala-0.16")]
public static void remove_focus_tracker (uint tracker_id);
[CCode (cheader_filename = "atk/atk.h")]
+ [Deprecated (replacement = "Atk.Util.remove_global_event_listener", since = "vala-0.16")]
public static void remove_global_event_listener (uint listener_id);
[CCode (cheader_filename = "atk/atk.h")]
+ [Deprecated (replacement = "Atk.Util.remove_key_event_listener", since = "vala-0.16")]
public static void remove_key_event_listener (uint listener_id);
[CCode (cheader_filename = "atk/atk.h")]
+ [Deprecated (replacement = "Atk.Role.for_name", since = "vala-0.16")]
public static Atk.Role role_for_name (string name);
[CCode (cheader_filename = "atk/atk.h")]
+ [Deprecated (replacement = "Atk.Role.get_localized_name", since = "vala-0.16")]
public static unowned string role_get_localized_name (Atk.Role role);
[CCode (cheader_filename = "atk/atk.h")]
+ [Deprecated (replacement = "Atk.Role.get_name", since = "vala-0.16")]
public static unowned string role_get_name (Atk.Role role);
[CCode (cheader_filename = "atk/atk.h")]
+ [Deprecated (replacement = "Atk.Role.register", since = "vala-0.16")]
public static Atk.Role role_register (string name);
}
diff --git a/vapi/metadata/Atk-1.0-custom.vala b/vapi/metadata/Atk-1.0-custom.vala
new file mode 100644
index 0000000..d2d721f
--- /dev/null
+++ b/vapi/metadata/Atk-1.0-custom.vala
@@ -0,0 +1,81 @@
+namespace Atk {
+ [CCode (cheader_filename = "atk/atk.h", has_destroy_function = false)]
+ public struct Attribute {
+ public string name;
+ public string value;
+ }
+ public interface Implementor : GLib.Object {
+ public abstract unowned Atk.Object ref_accessible ();
+ }
+ public class Registry : GLib.Object {
+ [Deprecated]
+ public weak GLib.HashTable<GLib.Type,Atk.ObjectFactory> factory_singleton_cache;
+ [Deprecated]
+ public weak GLib.HashTable<GLib.Type,GLib.Type> factory_type_registry;
+ }
+ public class Relation : GLib.Object {
+ [Deprecated (replacement = "RelationType.for_name", since = "vala-0.16")]
+ public static Atk.RelationType type_for_name (string name);
+ [Deprecated (replacement = "RelationType.get_name", since = "vala-0.16")]
+ public static unowned string type_get_name (Atk.RelationType type);
+ [Deprecated (replacement = "RelationType.register", since = "vala-0.16")]
+ public static Atk.RelationType type_register (string name);
+ }
+ [CCode (copy_function = "g_boxed_copy", free_function = "g_boxed_free", type_id = "atk_text_range_get_type ()", has_destroy_function = false)]
+ [Compact]
+ public class TextRange {
+ public string content;
+ }
+ public interface Text : GLib.Object {
+ [Deprecated (replacement = "TextAttribute.for_name", since = "vala-0.16")]
+ public static Atk.TextAttribute attribute_for_name (string name);
+ [Deprecated (replacement = "TextAttribute.get_name", since = "vala-0.16")]
+ public static unowned string attribute_get_name (Atk.TextAttribute attr);
+ [Deprecated (replacement = "TextAttribute.get_value", since = "vala-0.16")]
+ public static unowned string attribute_get_value (Atk.TextAttribute attr, int index_);
+ [Deprecated (replacement = "TextAttribute.register", since = "vala-0.16")]
+ public static Atk.TextAttribute attribute_register (string name);
+ [CCode (array_length = false, array_null_terminated = true)]
+ public virtual Atk.TextRange[] get_bounded_ranges (Atk.TextRectangle rect, Atk.CoordType coord_type, Atk.TextClipType x_clip_type, Atk.TextClipType y_clip_type);
+ }
+
+ public delegate bool Function ();
+ public delegate int KeySnoopFunc (Atk.KeyEventStruct event);
+ [CCode (has_target = false)]
+ public delegate void PropertyChangeHandler (Atk.Object Param1, Atk.PropertyValues Param2);
+
+ [Deprecated (replacement = "Atk.Util.add_focus_tracker", since = "vala-0.16")]
+ public static uint add_focus_tracker (Atk.EventListener focus_tracker);
+ [Deprecated (replacement = "Atk.Util.add_global_event_listener", since = "vala-0.16")]
+ public static uint add_global_event_listener (GLib.SignalEmissionHook listener, string event_type);
+ [Deprecated (replacement = "Atk.Util.focus_tracker_init", since = "vala-0.16")]
+ public static void focus_tracker_init (Atk.EventListenerInit init);
+ [Deprecated (replacement = "Atk.Util.focus_tracker_notify", since = "vala-0.16")]
+ public static void focus_tracker_notify (Atk.Object object);
+ [Deprecated (replacement = "Atk.Registry.get_default.", since = "vala-0.16")]
+ public static unowned Atk.Registry get_default_registry ();
+ [Deprecated (replacement = "Atk.Util.get_focus_object", since = "vala-0.16")]
+ public static unowned Atk.Object get_focus_object ();
+ [Deprecated (replacement = "Atk.Util.get_root", since = "vala-0.16")]
+ public static unowned Atk.Object get_root ();
+ [Deprecated (replacement = "Atk.Util.get_toolkit_name", since = "vala-0.16")]
+ public static unowned string get_toolkit_name ();
+ [Deprecated (replacement = "Atk.Util.get_toolkit_version", since = "vala-0.16")]
+ public static unowned string get_toolkit_version ();
+ [Deprecated (replacement = "Atk.Util.get_version", since = "vala-0.16")]
+ public static unowned string get_version ();
+ [Deprecated (replacement = "Atk.Util.remove_focus_tracker", since = "vala-0.16")]
+ public static void remove_focus_tracker (uint tracker_id);
+ [Deprecated (replacement = "Atk.Util.remove_global_event_listener", since = "vala-0.16")]
+ public static void remove_global_event_listener (uint listener_id);
+ [Deprecated (replacement = "Atk.Util.remove_key_event_listener", since = "vala-0.16")]
+ public static void remove_key_event_listener (uint listener_id);
+ [Deprecated (replacement = "Atk.Role.for_name", since = "vala-0.16")]
+ public static Atk.Role role_for_name (string name);
+ [Deprecated (replacement = "Atk.Role.get_localized_name", since = "vala-0.16")]
+ public static unowned string role_get_localized_name (Atk.Role role);
+ [Deprecated (replacement = "Atk.Role.get_name", since = "vala-0.16")]
+ public static unowned string role_get_name (Atk.Role role);
+ [Deprecated (replacement = "Atk.Role.register", since = "vala-0.16")]
+ public static Atk.Role role_register (string name);
+}
diff --git a/vapi/metadata/Atk-1.0.metadata b/vapi/metadata/Atk-1.0.metadata
new file mode 100644
index 0000000..90fcdd7
--- /dev/null
+++ b/vapi/metadata/Atk-1.0.metadata
@@ -0,0 +1,63 @@
+* cheader_filename="atk/atk.h"
+
+// Handle AttributeSet properly
+AttributeSet skip
+Attribute skip
+attribute_set_free skip
+Document.get_attributes type="unowned GLib.SList<Attribute?>"
+EditableText.set_run_attributes.attrib_set type="GLib.SList<Attribute?>"
+Object.get_attributes type="unowned GLib.SList<Attribute?>"
+Text
+ .get_default_attributes type="GLib.SList<Attribute?>"
+ .get_run_attributes type="GLib.SList<Attribute?>"
+
+KeyEventStruct.string name="str"
+TextRange.content skip
+Text.get_bounded_ranges skip
+
+// Move static methods into classes (mostly Util)
+add_focus_tracker parent="Atk.Util"
+add_global_event_listener parent="Atk.Util"
+add_key_event_listener parent="Atk.Util"
+focus_tracker_init parent="Atk.Util"
+focus_tracker_notify parent="Atk.Util"
+get_default_registry parent="Atk.Registry" name="get_default"
+get_focus_object parent="Atk.Util"
+get_version parent="Atk.Util"
+get_root parent="Atk.Util"
+get_toolkit_name parent="Atk.Util"
+get_toolkit_version parent="Atk.Util"
+remove_focus_tracker parent="Atk.Util"
+remove_global_event_listener parent="Atk.Util"
+remove_key_event_listener parent="Atk.Util"
+text_free_ranges skip
+
+// Deprecated fields
+Socket.embedded_plug_id skip=false deprecated
+RelationSet.relations type_arguments="Atk.Relation" deprecated
+
+// GObject Introspection bug #581525
+_PropertyValues name="PropertyValues"
+_Registry* skip
+
+// Should be fixed upstream
+Implementor skip // g-ir-scanner doesn't realize this is an interface
+Document.get_attributes vfunc_name="get_document_attributes"
+Object.connect_property_change_handler skip=false
+Relation.get_target type_arguments="Atk.Object"
+Relation.new.targets array array_length_idx=1
+StateSet.add_states.types array array_length_idx=1
+StateSet.contains_states.types array array_length_idx=1
+Text
+ .free_ranges.ranges array
+ .get_run_attributes.*_offset out
+ .get_selection.*_offset out
+ .get_text_after_offset.*_offset out
+ .get_text_at_offset.*_offset out
+ .get_text_before_offset.*_offset out
+Function skip
+KeySnoopFunc skip
+add_focus_tracker skip=false
+add_global_event_listener skip=false
+add_key_event_listener skip=false
+focus_tracker_init skip=false
\ No newline at end of file
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]