Index: spi-private.h
===================================================================
RCS file: /cvs/gnome/at-spi/cspi/spi-private.h,v
retrieving revision 1.17
diff -u -r1.17 spi-private.h
--- spi-private.h	16 Jan 2006 14:16:43 -0000	1.17
+++ spi-private.h	10 Jul 2006 19:59:49 -0000
@@ -81,9 +81,10 @@
 					       const char  *interface_name);
 AccessibleRole         cspi_role_from_spi_role (Accessibility_Role role);
 void                   cspi_streams_close_all (void);
-gboolean              _cspi_exception_throw (CORBA_Environment *ev, char *desc_prefix);
-
+gboolean               cspi_exception_throw (CORBA_Environment *ev, char *desc_prefix);
 
+AccessibleAttributeSet 
+                     *cspi_attribute_set_from_sequence (const Accessibility_AttributeSet *seq);
 #define cspi_return_if_fail(val)		\
 	if (!(val))				\
 		return
Index: spi_text.c
===================================================================
RCS file: /cvs/gnome/at-spi/cspi/spi_text.c,v
retrieving revision 1.27
diff -u -r1.27 spi_text.c
--- spi_text.c	27 Mar 2006 18:05:31 -0000	1.27
+++ spi_text.c	10 Jul 2006 19:59:49 -0000
@@ -912,4 +912,94 @@
 }
 
 
+/**
+ * AccessibleText_getAttributeRun:
+ * @obj: a pointer to the #AccessibleText object to query.
+ * @offset: a long integer indicating the offset from which the attribute
+ *        search is based.
+ * @startOffset: a #long indicating the start of the desired text range.
+ * @endOffset: a #long indicating the first character past the desired range.
+ * @includeDefaults: a #bool if False, the call should only return those 
+ *                 attributes which are explicitly set on the current attribute 
+ *                 run, omitting any attributes which are inherited from the 
+ *                 default values.
+ *
+ *  @Since: AT-SPI 1.7
+ *
+ * Returns: the AttributeSet defined at offset, optionally including the 'default' attributes.
+ **/
 
+AccessibleAttributeSet *
+AccessibleText_getAttributeRun (AccessibleText *obj,
+				long int offset,
+				long int *startOffset,
+				long int *endOffset,
+			        long int includeDefaults){
+
+  CORBA_long retStartOffset, retEndOffset;
+  AccessibleAttributeSet *retval;
+  Accessibility_AttributeSet *attributes;
+
+  if (obj == NULL)
+  {
+       *startOffset = *endOffset = -1;
+       return NULL;
+  }
+
+  attributes = Accessibility_Text_getAttributeRun (CSPI_OBJREF (obj),
+					       offset,
+					       &retStartOffset,
+					       &retEndOffset,
+					       (includeDefaults)? TRUE : FALSE,
+					       cspi_ev ());
+
+  if (!cspi_check_ev ("getAttributeRun"))
+    {
+      *startOffset = *endOffset = -1;
+      retval = NULL;
+    }
+  else 
+  {
+      *startOffset = retStartOffset;
+      *endOffset   = retEndOffset;
+  }
+
+  retval =  cspi_attribute_set_from_sequence (attributes);
+
+  return retval;
+				     
+}
+
+/**
+ * AccessibleText_getDefaultAttributeSet:
+ * @obj: a pointer to the #AccessibleText object to query.
+ *
+ *
+ *  @Since: AT-SPI 1.7
+ *
+ * Returns: an AttributeSet containing the text attributes 
+ * which apply to all text in the object by virtue of the
+ * default settings of the document, view, or user agent; e.g.
+ * those attributes which are implied rather than explicitly 
+ * applied to the text object. For instance, an object whose 
+ * entire text content has been explicitly marked as 'bold' 
+ * will report the 'bold' attribute via getAttributeRun(), 
+ * whereas an object whose text weight is inspecified may 
+ * report the default or implied text weight in the default AttributeSet.
+ *
+ **/
+
+AccessibleAttributeSet *
+AccessibleText_getDefaultAttributeSet (AccessibleText *obj){
+   AccessibleAttributeSet *retval;
+   Accessibility_AttributeSet *attributes;
+
+   cspi_return_val_if_fail (obj != NULL, NULL);
+
+  attributes = Accessibility_Text_getDefaultAttributeSet (CSPI_OBJREF (obj), cspi_ev ());
+  cspi_return_val_if_ev ("getDefaultAttributeSet", NULL);
+  
+  retval = cspi_attribute_set_from_sequence (attributes);
+  retval = NULL;
+  return retval;
+}
Index: spi.h
===================================================================
RCS file: /cvs/gnome/at-spi/cspi/spi.h,v
retrieving revision 1.72
diff -u -r1.72 spi.h
--- spi.h	9 Jun 2006 16:00:23 -0000	1.72
+++ spi.h	10 Jul 2006 19:59:50 -0000
@@ -1066,6 +1083,14 @@
 			     long int selectionNum,
 			     long int startOffset,
 			     long int endOffset);
+AccessibleAttributeSet *
+AccessibleText_getAttributeRun  (AccessibleText *obj,
+				 long int offset,
+				 long int *startOffset,
+				 long int *endOffset,
+				 long int includeDefaults);
+AccessibleAttributeSet *
+AccessibleText_getDefaultAttributeSet (AccessibleText *obj);
 
 /* AccessibleValue Function Prototypes:  */
 
