Commit 0cb19e56 authored by Mike Wey's avatar Mike Wey
Browse files

Update Atk to 2.34

parent e4fd0f31
......@@ -101,7 +101,7 @@ Glib | 2.64
GObject | 2.64
Gio | 2.64
Pango | 1.43
Atk | 2.32
Atk | 2.34
Gdk-pixbuf | 2.38
Cairo | 1.12.2
LibRsvg | 2.44
......
......@@ -206,14 +206,14 @@ public template ComponentT(TStruct)
*/
public ObjectAtk refAccessibleAtPoint(int x, int y, AtkCoordType coordType)
{
auto p = atk_component_ref_accessible_at_point(getComponentStruct(), x, y, coordType);
auto __p = atk_component_ref_accessible_at_point(getComponentStruct(), x, y, coordType);
if(p is null)
if(__p is null)
{
return null;
}
return ObjectG.getDObject!(ObjectAtk)(cast(AtkObject*) p, true);
return ObjectG.getDObject!(ObjectAtk)(cast(AtkObject*) __p, true);
}
/**
......
......@@ -56,13 +56,15 @@ public interface DocumentIF{
}
/**
* Retrieves the value of the given @attribute_name inside @document.
*
* Params:
* attributeName = a character string representing the name of the attribute
* whose value is being queried.
*
* Returns: a string value associated with the named
* attribute for this document, or NULL if a value for
* #attribute_name has not been specified for this document.
* attribute for this document, or %NULL if a value for
* @attribute_name has not been specified for this document.
*
* Since: 1.12
*/
......@@ -81,8 +83,10 @@ public interface DocumentIF{
public AtkAttributeSet* getAttributes();
/**
* Returns: current page number inside @document. -1 if not
* implemented, not know by the implementor or irrelevant.
* Retrieves the current page number inside @document.
*
* Returns: the current page number inside @document, or -1 if
* not implemented, not know by the implementor, or irrelevant.
*
* Since: 2.12
*/
......@@ -127,22 +131,26 @@ public interface DocumentIF{
public string getLocale();
/**
* Returns: total page count of @document. -1 if not implemented, not
* know by the implementor or irrelevant.
* Retrieves the total number of pages inside @document.
*
* Returns: total page count of @document, or -1 if not implemented,
* not know by the implementor or irrelevant.
*
* Since: 2.12
*/
public int getPageCount();
/**
* Sets the value for the given @attribute_name inside @document.
*
* Params:
* attributeName = a character string representing the name of the attribute
* whose value is being set.
* attributeValue = a string value to be associated with #attribute_name.
* Returns: TRUE if #value is successfully associated with #attribute_name
* for this document, FALSE otherwise (e.g. if the document does not
* allow the attribute to be modified).
* attributeValue = a string value to be associated with @attribute_name.
*
* Returns: %TRUE if @attribute_value is successfully associated
* with @attribute_name for this @document, and %FALSE if if the
* document does not allow the attribute to be modified
*
* Since: 1.12
*/
......
......@@ -53,13 +53,15 @@ public template DocumentT(TStruct)
/**
* Retrieves the value of the given @attribute_name inside @document.
*
* Params:
* attributeName = a character string representing the name of the attribute
* whose value is being queried.
*
* Returns: a string value associated with the named
* attribute for this document, or NULL if a value for
* #attribute_name has not been specified for this document.
* attribute for this document, or %NULL if a value for
* @attribute_name has not been specified for this document.
*
* Since: 1.12
*/
......@@ -84,8 +86,10 @@ public template DocumentT(TStruct)
}
/**
* Returns: current page number inside @document. -1 if not
* implemented, not know by the implementor or irrelevant.
* Retrieves the current page number inside @document.
*
* Returns: the current page number inside @document, or -1 if
* not implemented, not know by the implementor, or irrelevant.
*
* Since: 2.12
*/
......@@ -142,8 +146,10 @@ public template DocumentT(TStruct)
}
/**
* Returns: total page count of @document. -1 if not implemented, not
* know by the implementor or irrelevant.
* Retrieves the total number of pages inside @document.
*
* Returns: total page count of @document, or -1 if not implemented,
* not know by the implementor or irrelevant.
*
* Since: 2.12
*/
......@@ -153,14 +159,16 @@ public template DocumentT(TStruct)
}
/**
* Sets the value for the given @attribute_name inside @document.
*
* Params:
* attributeName = a character string representing the name of the attribute
* whose value is being set.
* attributeValue = a string value to be associated with #attribute_name.
* Returns: TRUE if #value is successfully associated with #attribute_name
* for this document, FALSE otherwise (e.g. if the document does not
* allow the attribute to be modified).
* attributeValue = a string value to be associated with @attribute_name.
*
* Returns: %TRUE if @attribute_value is successfully associated
* with @attribute_name for this @document, and %FALSE if if the
* document does not allow the attribute to be modified
*
* Since: 1.12
*/
......
......@@ -83,14 +83,14 @@ public class GObjectAccessible : ObjectAtk
*/
public static ObjectAtk forObject(ObjectG obj)
{
auto p = atk_gobject_accessible_for_object((obj is null) ? null : obj.getObjectGStruct());
auto __p = atk_gobject_accessible_for_object((obj is null) ? null : obj.getObjectGStruct());
if(p is null)
if(__p is null)
{
return null;
}
return ObjectG.getDObject!(ObjectAtk)(cast(AtkObject*) p);
return ObjectG.getDObject!(ObjectAtk)(cast(AtkObject*) __p);
}
/**
......@@ -101,13 +101,13 @@ public class GObjectAccessible : ObjectAtk
*/
public ObjectG getObject()
{
auto p = atk_gobject_accessible_get_object(atkGObjectAccessible);
auto __p = atk_gobject_accessible_get_object(atkGObjectAccessible);
if(p is null)
if(__p is null)
{
return null;
}
return ObjectG.getDObject!(ObjectG)(cast(GObject*) p);
return ObjectG.getDObject!(ObjectG)(cast(GObject*) __p);
}
}
......@@ -118,14 +118,14 @@ public class Hyperlink : ObjectG, ActionIF
*/
public ObjectAtk getObject(int i)
{
auto p = atk_hyperlink_get_object(atkHyperlink, i);
auto __p = atk_hyperlink_get_object(atkHyperlink, i);
if(p is null)
if(__p is null)
{
return null;
}
return ObjectG.getDObject!(ObjectAtk)(cast(AtkObject*) p);
return ObjectG.getDObject!(ObjectAtk)(cast(AtkObject*) __p);
}
/**
......
......@@ -82,13 +82,13 @@ public template HyperlinkImplT(TStruct)
*/
public Hyperlink getHyperlink()
{
auto p = atk_hyperlink_impl_get_hyperlink(getHyperlinkImplStruct());
auto __p = atk_hyperlink_impl_get_hyperlink(getHyperlinkImplStruct());
if(p is null)
if(__p is null)
{
return null;
}
return ObjectG.getDObject!(Hyperlink)(cast(AtkHyperlink*) p, true);
return ObjectG.getDObject!(Hyperlink)(cast(AtkHyperlink*) __p, true);
}
}
......@@ -66,14 +66,14 @@ public template HypertextT(TStruct)
*/
public Hyperlink getLink(int linkIndex)
{
auto p = atk_hypertext_get_link(getHypertextStruct(), linkIndex);
auto __p = atk_hypertext_get_link(getHypertextStruct(), linkIndex);
if(p is null)
if(__p is null)
{
return null;
}
return ObjectG.getDObject!(Hyperlink)(cast(AtkHyperlink*) p);
return ObjectG.getDObject!(Hyperlink)(cast(AtkHyperlink*) __p);
}
/**
......
......@@ -67,9 +67,11 @@ public interface ImageIF{
public string getImageDescription();
/**
* Retrieves the locale identifier associated to the #AtkImage.
*
* Returns: a string corresponding to the POSIX
* LC_MESSAGES locale used by the image description, or %NULL if the
* image does not specify a locale.
* `LC_MESSAGES` locale used by the image description, or
* %NULL if the image does not specify a locale.
*
* Since: 1.12
*/
......
......@@ -67,9 +67,11 @@ public template ImageT(TStruct)
}
/**
* Retrieves the locale identifier associated to the #AtkImage.
*
* Returns: a string corresponding to the POSIX
* LC_MESSAGES locale used by the image description, or %NULL if the
* image does not specify a locale.
* `LC_MESSAGES` locale used by the image description, or
* %NULL if the image does not specify a locale.
*
* Since: 1.12
*/
......
......@@ -52,13 +52,13 @@ public template ImplementorT(TStruct)
*/
public ObjectAtk refAccessible()
{
auto p = atk_implementor_ref_accessible(getImplementorStruct());
auto __p = atk_implementor_ref_accessible(getImplementorStruct());
if(p is null)
if(__p is null)
{
return null;
}
return ObjectG.getDObject!(ObjectAtk)(cast(AtkObject*) p, true);
return ObjectG.getDObject!(ObjectAtk)(cast(AtkObject*) __p, true);
}
}
......@@ -80,14 +80,14 @@ public class Misc : ObjectG
*/
public static Misc getInstance()
{
auto p = atk_misc_get_instance();
auto __p = atk_misc_get_instance();
if(p is null)
if(__p is null)
{
return null;
}
return ObjectG.getDObject!(Misc)(cast(AtkMisc*) p);
return ObjectG.getDObject!(Misc)(cast(AtkMisc*) __p);
}
/**
......
......@@ -162,13 +162,13 @@ public class NoOpObject : ObjectAtk, ActionIF, ComponentIF, DocumentIF, Editable
*/
public this(ObjectG obj)
{
auto p = atk_no_op_object_new((obj is null) ? null : obj.getObjectGStruct());
auto __p = atk_no_op_object_new((obj is null) ? null : obj.getObjectGStruct());
if(p is null)
if(__p is null)
{
throw new ConstructionException("null returned by new");
}
this(cast(AtkNoOpObject*) p, true);
this(cast(AtkNoOpObject*) __p, true);
}
}
......@@ -82,13 +82,13 @@ public class NoOpObjectFactory : ObjectFactory
*/
public this()
{
auto p = atk_no_op_object_factory_new();
auto __p = atk_no_op_object_factory_new();
if(p is null)
if(__p is null)
{
throw new ConstructionException("null returned by new");
}
this(cast(AtkNoOpObjectFactory*) p, true);
this(cast(AtkNoOpObjectFactory*) __p, true);
}
}
......@@ -107,10 +107,10 @@ public class ObjectAtk : ObjectG
}
/**
* Calls @handler on property changes.
*
*
* Deprecated: Since 2.12. Connect directly to property-change or
* notify signals.
* Deprecated: Connect directly to #AtkObject::property-change or
* the relevant #GObject::notify signal for each desired property.
*
* Params:
* handler = a function to be called when a property changes its value
......@@ -123,6 +123,19 @@ public class ObjectAtk : ObjectG
return atk_object_connect_property_change_handler(atkObject, handler);
}
/**
* Gets the accessible id of the accessible.
*
* Returns: a character string representing the accessible id of the object, or
* NULL if no such string was set.
*
* Since: 2.34
*/
public string getAccessibleId()
{
return Str.toString(atk_object_get_accessible_id(atkObject));
}
/**
* Get a list of properties applied to this object as a whole, as an #AtkAttributeSet consisting of
* name-value pairs. As such these attributes may be considered weakly-typed properties or annotations,
......@@ -241,14 +254,14 @@ public class ObjectAtk : ObjectG
*/
public ObjectAtk getParent()
{
auto p = atk_object_get_parent(atkObject);
auto __p = atk_object_get_parent(atkObject);
if(p is null)
if(__p is null)
{
return null;
}
return ObjectG.getDObject!(ObjectAtk)(cast(AtkObject*) p);
return ObjectG.getDObject!(ObjectAtk)(cast(AtkObject*) __p);
}
/**
......@@ -304,14 +317,14 @@ public class ObjectAtk : ObjectG
*/
public ObjectAtk peekParent()
{
auto p = atk_object_peek_parent(atkObject);
auto __p = atk_object_peek_parent(atkObject);
if(p is null)
if(__p is null)
{
return null;
}
return ObjectG.getDObject!(ObjectAtk)(cast(AtkObject*) p);
return ObjectG.getDObject!(ObjectAtk)(cast(AtkObject*) __p);
}
/**
......@@ -327,14 +340,14 @@ public class ObjectAtk : ObjectG
*/
public ObjectAtk refAccessibleChild(int i)
{
auto p = atk_object_ref_accessible_child(atkObject, i);
auto __p = atk_object_ref_accessible_child(atkObject, i);
if(p is null)
if(__p is null)
{
return null;
}
return ObjectG.getDObject!(ObjectAtk)(cast(AtkObject*) p, true);
return ObjectG.getDObject!(ObjectAtk)(cast(AtkObject*) __p, true);
}
/**
......@@ -345,14 +358,14 @@ public class ObjectAtk : ObjectG
*/
public RelationSet refRelationSet()
{
auto p = atk_object_ref_relation_set(atkObject);
auto __p = atk_object_ref_relation_set(atkObject);
if(p is null)
if(__p is null)
{
return null;
}
return ObjectG.getDObject!(RelationSet)(cast(AtkRelationSet*) p, true);
return ObjectG.getDObject!(RelationSet)(cast(AtkRelationSet*) __p, true);
}
/**
......@@ -364,23 +377,21 @@ public class ObjectAtk : ObjectG
*/
public StateSet refStateSet()
{
auto p = atk_object_ref_state_set(atkObject);
auto __p = atk_object_ref_state_set(atkObject);
if(p is null)
if(__p is null)
{
return null;
}
return ObjectG.getDObject!(StateSet)(cast(AtkStateSet*) p, true);
return ObjectG.getDObject!(StateSet)(cast(AtkStateSet*) __p, true);
}
/**
*
*
* Deprecated: Since 2.12.
*
* Removes a property change handler.
*
* Deprecated: See atk_object_connect_property_change_handler()
*
* Params:
* handlerId = a guint which identifies the handler to be removed.
*/
......@@ -403,6 +414,23 @@ public class ObjectAtk : ObjectG
return atk_object_remove_relationship(atkObject, relationship, (target is null) ? null : target.getObjectAtkStruct()) != 0;
}
/**
* Sets the accessible ID of the accessible. This is not meant to be presented
* to the user, but to be an ID which is stable over application development.
* Typically, this is the gtkbuilder ID. Such an ID will be available for
* instance to identify a given well-known accessible object for tailored screen
* reading, or for automatic regression testing.
*
* Params:
* name = a character string to be set as the accessible id
*
* Since: 2.34
*/
public void setAccessibleId(string name)
{
atk_object_set_accessible_id(atkObject, Str.toStringz(name));
}
/**
* Sets the accessible description of the accessible. You can't set
* the description to NULL. This is reserved for the initial value. In
......
......@@ -85,14 +85,14 @@ public class ObjectFactory : ObjectG
*/
public ObjectAtk createAccessible(ObjectG obj)
{
auto p = atk_object_factory_create_accessible(atkObjectFactory, (obj is null) ? null : obj.getObjectGStruct());
auto __p = atk_object_factory_create_accessible(atkObjectFactory, (obj is null) ? null : obj.getObjectGStruct());
if(p is null)
if(__p is null)
{
return null;
}
return ObjectG.getDObject!(ObjectAtk)(cast(AtkObject*) p, true);
return ObjectG.getDObject!(ObjectAtk)(cast(AtkObject*) __p, true);
}
/**
......
......@@ -76,17 +76,25 @@ public class Plug : ObjectAtk, ComponentIF
return atk_plug_get_type();
}
/** */
/**
* Creates a new #AtkPlug instance.
*
* Returns: the newly created #AtkPlug
*
* Since: 1.30
*
* Throws: ConstructionException GTK+ fails to create the object.
*/
public this()
{
auto p = atk_plug_new();
auto __p = atk_plug_new();
if(p is null)
if(__p is null)
{
throw new ConstructionException("null returned by new");
}
this(cast(AtkPlug*) p, true);
this(cast(AtkPlug*) __p, true);
}
/**
......
......@@ -98,14 +98,14 @@ public class Range
*/
public this(double lowerLimit, double upperLimit, string description)
{
auto p = atk_range_new(lowerLimit, upperLimit, Str.toStringz(description));
auto __p = atk_range_new(lowerLimit, upperLimit, Str.toStringz(description));
if(p is null)
if(__p is null)
{
throw new ConstructionException("null returned by new");
}
this(cast(AtkRange*) p);
this(cast(AtkRange*) __p);
}
/**
......@@ -117,14 +117,14 @@ public class Range
*/
public Range copy()
{
auto p = atk_range_copy(atkRange);
auto __p = atk_range_copy(atkRange);
if(p is null)
if(__p is null)
{
return null;
}
return ObjectG.getDObject!(Range)(cast(AtkRange*) p, true);
return ObjectG.getDObject!(Range)(cast(AtkRange*) __p, true);
}
/**
......
......@@ -86,14 +86,14 @@ public class Registry : ObjectG
*/
public ObjectFactory getFactory(GType type)
{
auto p = atk_registry_get_factory(atkRegistry, type);
auto __p = atk_registry_get_factory(atkRegistry, type);
if(p is null)
if(__p is null)
{
return null;
}
return ObjectG.getDObject!(ObjectFactory)(cast(AtkObjectFactory*) p);
return ObjectG.getDObject!(ObjectFactory)(cast(AtkObjectFactory*) __p);
}
/**
......@@ -141,13 +141,13 @@ public class Registry : ObjectG
*/
public static Registry getDefaultRegistry()
{
auto p = atk_get_default_registry();
auto __p = atk_get_default_registry();
if(p is null)
if(__p is null)
{
return null;
}
return ObjectG.getDObject!(Registry)(cast(AtkRegistry*) p, true);
return ObjectG.getDObject!(Registry)(cast(AtkRegistry*) __p, true);
}