Add missing accessibility states
[platform/upstream/atk.git] / atk / atkeditabletext.c
index e6316e6..d44f8bf 100755 (executable)
  * Boston, MA 02111-1307, USA.
  */
 
-#include "atkeditabletext.h"
-
+#include "config.h"
 
-struct _AtkEditableTextIfaceClass
-{
-  GObjectClass parent;
-};
+#include "atkeditabletext.h"
 
-typedef struct _AtkEditableTextIfaceClass AtkEditableTextIfaceClass;
+/**
+ * SECTION:atkeditabletext
+ * @Short_description: The ATK interface implemented by components
+ *  containing user-editable text content.
+ * @Title:AtkEditableText
+ *
+ * #AtkEditableText should be implemented by UI components which
+ * contain text which the user can edit, via the #AtkObject
+ * corresponding to that component (see #AtkObject).
+ *
+ * #AtkEditableText is a subclass of #AtkText, and as such, an object
+ * which implements #AtkEditableText is by definition an #AtkText
+ * implementor as well.
+ *
+ * See also: #AtkText
+ */
 
 GType
-atk_editable_text_get_type ()
+atk_editable_text_get_type (void)
 {
   static GType type = 0;
 
@@ -54,7 +65,10 @@ atk_editable_text_get_type ()
  *@start_offset: start of range in which to set attributes
  *@end_offset: end of range in which to set attributes
  *
- *Sets the attributes for a specified range.
+ *Sets the attributes for a specified range. See the ATK_ATTRIBUTE
+ *macros (such as #ATK_ATTRIBUTE_LEFT_MARGIN) for examples of attributes 
+ *that can be set. Note that other attributes that do not have corresponding
+ *ATK_ATTRIBUTE macros may also be set for certain text widgets.
  *
  *Returns: %TRUE if attributes successfully set for the specified
  *range, otherwise %FALSE
@@ -67,7 +81,6 @@ atk_editable_text_set_run_attributes (AtkEditableText *text,
 {
   AtkEditableTextIface *iface;
 
-  g_return_val_if_fail (text != NULL, FALSE);
   g_return_val_if_fail (ATK_IS_EDITABLE_TEXT (text), FALSE);
 
   iface = ATK_EDITABLE_TEXT_GET_IFACE (text);
@@ -96,7 +109,6 @@ atk_editable_text_set_text_contents (AtkEditableText  *text,
 {
   AtkEditableTextIface *iface;
 
-  g_return_if_fail (text != NULL);
   g_return_if_fail (ATK_IS_EDITABLE_TEXT (text));
 
   iface = ATK_EDITABLE_TEXT_GET_IFACE (text);
@@ -124,7 +136,6 @@ atk_editable_text_insert_text (AtkEditableText  *text,
 {
   AtkEditableTextIface *iface;
 
-  g_return_if_fail (text != NULL);
   g_return_if_fail (ATK_IS_EDITABLE_TEXT (text));
 
   iface = ATK_EDITABLE_TEXT_GET_IFACE (text);
@@ -149,7 +160,6 @@ atk_editable_text_copy_text (AtkEditableText  *text,
 {
   AtkEditableTextIface *iface;
 
-  g_return_if_fail (text != NULL);
   g_return_if_fail (ATK_IS_EDITABLE_TEXT (text));
 
   iface = ATK_EDITABLE_TEXT_GET_IFACE (text);
@@ -174,7 +184,6 @@ atk_editable_text_cut_text  (AtkEditableText  *text,
 {
   AtkEditableTextIface *iface;
 
-  g_return_if_fail (text != NULL);
   g_return_if_fail (ATK_IS_EDITABLE_TEXT (text));
 
   iface = ATK_EDITABLE_TEXT_GET_IFACE (text);
@@ -198,7 +207,6 @@ atk_editable_text_delete_text (AtkEditableText  *text,
 {
   AtkEditableTextIface *iface;
 
-  g_return_if_fail (text != NULL);
   g_return_if_fail (ATK_IS_EDITABLE_TEXT (text));
 
   iface = ATK_EDITABLE_TEXT_GET_IFACE (text);
@@ -220,7 +228,6 @@ atk_editable_text_paste_text (AtkEditableText  *text,
 {
   AtkEditableTextIface *iface;
 
-  g_return_if_fail (text != NULL);
   g_return_if_fail (ATK_IS_EDITABLE_TEXT (text));
 
   iface = ATK_EDITABLE_TEXT_GET_IFACE (text);