+
    <iJ  c                   s   ^ RI Ht ^ RI5 ^ RI5 ^ RI5 . ROt ! R R]4      t]! ^ 4      t]! ^4      t	]! ^4      t
]! ^4      t]! ^4      t]! ^4      t]! ^4      t ! R R]4      t]! ^4      t]! ^4      t]! ^4      t]! ^ 4      t ! R R	]4      t]! ^ 4      t]! ^4      t]! ^4      t]! ^4      t]! ^4      t ! R
 R]4      tR tR tR# )i    )Atspi)Z*TextTEXT_BOUNDARY_TYPETEXT_CLIP_TYPEc                   s6    ] tR t^.t^ R^R^R^R^R^R^R/tRtR	# )
r   TEXT_BOUNDARY_CHARTEXT_BOUNDARY_WORD_STARTTEXT_BOUNDARY_WORD_ENDTEXT_BOUNDARY_SENTENCE_STARTTEXT_BOUNDARY_SENTENCE_ENDTEXT_BOUNDARY_LINE_STARTTEXT_BOUNDARY_LINE_END N__name__
__module____qualname____firstlineno__Z_enum_lookup__static_attributes__r       1/usr/lib/python3.14/site-packages/pyatspi/text.pyr   r   .   s3    &,*0.,*
r   c                   s*    ] tR t^Ct^ R^R^R^R/tRtR# )r   TEXT_CLIP_NONETEXT_CLIP_MINTEXT_CLIP_MAXTEXT_CLIP_BOTHr   Nr   r   r   r   r   r   C   s    "//"	
r   c            
       s.    ] tR t^Rt^ R^R^R^R^R/tRtR# )TEXT_GRANULARITY_TYPETEXT_GRANULARITY_CHARTEXT_GRANULARITY_WORDTEXT_GRANULARITY_SENTENCETEXT_GRANULARITY_LINETEXT_GRANULARITY_PARAGRAPHr   Nr   r   r   r   r   r   R   s'    ))-).
r   r   c                   s   a  ] tR t^ct o RtR tR R ltR tR tR t	R t
R tR	 tR
 tR tR tR tR tR tR tR tR tR tR tR tR tR tRt]! ]]R7      tR tRt]! ]]R7      t R t!R t"Rt#V t$R# )!r   a  
The text interface should be implemented by objects which place
textual information onscreen as character strings or glyphs.
The text interface allows access to textual content, including
display attributes and semantic hints associated with runs of
text, and access to bounding box information for glyphs and substrings.
It also allows portions of textual content to be selected, if
the object's StateSet includes STATE_SELECTABLE_TEXT.
In some cases a Text object may have, as its content, an empty
string. In particular this can occur in the case of Hypertext
objects which do not display explicitly textual information onscreen,
as Hypertext is derived from the Text interface. 
Typographic and semantic attributes of onscreen textual content,
for instance typeface, weight, language, and such qualities as
'emphasis' or 'blockquote', are represented as text attributes.
Contiguous sequences of characters over which these attributes
are unchanged are referred to as "attribute runs", and are available
via Text::getAttributeRun. Where possible, implementing clients
will report textual attributes which are the same over the entire
text object, for instance those inherited from a default or document-scope
style, via getDefaultAttributes instead of reporting them explicitly
for each character. Therefore, for any span of text, the attributes
in effect are the union of the set returned by Text::getDefaultAttributes,
and the set returned at a particular character offset via Text::getAttributeRun.
c                V    \         P                  P                  V P                  W4      # )a2  
The result of calling addSelection on objects which already have
one selection present, and which do not include STATE_MULTISELECTABLE,
is undefined, other than the return value. 
@return True of the selection was successfully added, False otherwise.
Selection may fail if the object does not support selection of
text (see STATE_SELECTABLE_TEXT), if the object does not support
multiple selections and a selection is already defined, or for
other reasons (for instance if the user does not have permission
to copy the text into the relevant selection buffer).
)r    r   Zadd_selectionobjselfstartOffset	endOffset   &&&r   addSelectionZText.addSelection~   s     zz//+QQr   c                s    \         P                  P                  V P                  W4      w  r4pVP	                  4        UUu. uF  w  rgVR,           V,           NK  	  pppWV.# u uppi )aS
  
Query a particular text object for the text attributes defined
at a given offset, obtaining the start and end of the "attribute
run" over which these attributes are currently invariant. Text
attributes are those presentational, typographic, or semantic
attributes or qualitites which apply to a range of text specifyable
by starting and ending offsets. Attributes relevant to localization
should be provided in accordance with the w3c "Internationalization
and Localization Markup Requirements", http://www.w3.org/TR/2005/WD-itsreq-20051122/
Other text attributes should choose their names and value semantics
in accordance with relevant standards such as CSS level 2 (http://www.w3.org/TR/1998/REC-CSS2-19980512),
XHTML 1.0 (http://www.w3.org/TR/2002/REC-xhtml1-20020801), and
WICD (http://www.w3.org/TR/2005/WD-WICD-20051121/). Those attributes
from the aforementioned specifications and recommendations which
do not concern typographic, presentational, or semantic aspects
of text should be exposed via the more general Accessible::getAttributes()
API (if at all).
For example, CSS attributes which should be exposed on text (either
as default attributes, or as explicitly-set attributes when non-default
values are specified in the content view) include the Font attributes
(i.e. "css2:font-weight", "css2:font-style"), the "css2:color"
and "css2:background-color" attributes, and "css2:text-decoration"
attribute.
If includeDefaults is TRUE, then this AttributeSet should include
the default attributes as well as those which are explicitly
assigned to the attribute run in question. startOffset and endOffset
will be back-filled to indicate the start and end of the attribute
run which contains 'offset' - an attribute run is a contiguous
section of text whose attributes are homogeneous. 
@param : offset
the offset of the character whose attributes will be reported.
@param : startOffset
backfilled with the starting offset of the character range over
which all text attributes match those of offset, i.e. the start
of the homogeneous attribute run including offset. 
@param : endOffset
backfilled with the offset of the first character past the character
range over which all text attributes match those of offset, i.e.
the character immediately after the homogeneous attribute run
including offset. 
@param : includeDefaults
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. See also
Text::getDefaultAttributes.
@return the AttributeSet defined at offset, optionally including
the 'default' attributes.
:)r    r   Zget_attribute_runr   items)	r!   offsetZincludeDefaultsattrsr"   r#   keyvalueZdicts	   &&&      r   getAttributeRunZText.getAttributeRun   s^    b 38**2N2NtxxY_2q/Y<AKKMJMjcc	E))MJ955 Ks   A#c                r   )a  
Get the string value of a named attribute at a given offset,
if defined. 
@param : offset
the offset of the character for which the attribute run is to
be obtained. 
@param : attributeName
the name of the attribute for which the value is to be returned,
if defined. 
@param : startOffset
back-filled with the offset of the first character in the attribute
run containing the character at offset. 
@param : endOffset
back-filled with the offset of the first character past the end
of the attribute run containing the character at offset. 
@param : defined
back-filled with True if the attributeName has a defined value
at offset, False otherwise. 
@return the value of attribute (name-value pair) corresponding
to "name", if defined.
)r    r   Zget_text_attribute_valuer   )r!   r(   ZattributeNamer$   r   getAttributeValueZText.getAttributeValue   s    , zz::488V[[r   c                s    \         P                  P                  V P                  V4      w  r#pVP	                  4        UUu. uF  w  rVVR,           V,           NK  	  pppRP                  V4      pWV.# u uppi )z
getAttributes is deprecated in favor of getAttributeRun. 
@return the attributes at offset, as a semicolon-delimited set
of colon-delimited name-value pairs.
r&   ;)r    r   Zget_text_attributesr   r'   join)	r!   r(   r)   r"   r#   r*   r+   ZarrZstrs	   &&       r   getAttributesZText.getAttributes   sm     38**2P2PQUQYQY[a2b/Y;@;;=I=ZSsSy5((=Ihhn)44 Js   A4c           
     s\    \         P                  P                  V P                  WW4WVV4      # )a-  
Return the text content within a bounding box, as a list of Range
structures. Depending on the TEXT_CLIP_TYPE parameters, glyphs
which are clipped by the bounding box (i.e. which lie partially
inside and partially outside it) may or may not be included in
the ranges returned. 
@param : x
the minimum x ( i.e. leftmost) coordinate of the bounding box.
@param : y
the minimum y coordinate of the bounding box. 
@param : width
the horizontal size of the bounding box. The rightmost bound
of the bounding box is (x + width); 
@param : height
the vertical size of the bounding box. The maximum y value of
the bounding box is (y + height); 
@param : coordType
If 0, the above coordinates are interpreted as pixels relative
to corner of the screen; if 1, the coordinates are interpreted
as pixels relative to the corner of the containing toplevel window.
@param : xClipType
determines whether text which intersects the bounding box in
the x direction is included. 
@param : yClipType
determines whether text which intersects the bounding box in
the y direction is included.
)r    r   Zget_bounded_rangesr   )r!   xyZwidthZheight	coordTypeZ	xClipTypeZ	yClipTypes   &&&&&&&&r   getBoundedRangesZText.getBoundedRanges   s'    8 zz44TXXqUT]jsttr   c                V    \         P                  P                  V P                  V4      # )z
@param : offset
position
@return an unsigned long integer whose value corresponds to the
UCS-4 representation of the character at the specified text offset,
or 0 if offset is out of range.
)r    r   Zget_character_at_offsetr   r!   r(      &&r   getCharacterAtOffsetZText.getCharacterAtOffset  s     zz99$((FKKr   c                l    \         P                  P                  V P                  W4      p\	        V4      # )a  
Obtain a the bounding box, as x, y, width, and height, of the
character or glyph at a particular character offset in this object's
text content. The coordinate system in which the results are
reported is specified by coordType. If an onscreen glyph corresponds
to multiple character offsets, for instance if the glyph is a
ligature, the bounding box reported will include the entire glyph
and therefore may apply to more than one character offset. 
The returned values are meaningful only if the Text has
both STATE_VISIBLE and STATE_SHOWING.
@param : offset
the character offset of the character or glyph being queried.
@param : coordType
If 0, the results will be reported in screen coordinates, i.e.
in pixels relative to the upper-left corner of the screen, with
the x axis pointing right and the y axis pointing down. If 1,
the results will be reported relative to the containing toplevel
window, with the x axis pointing right and the y axis pointing
down.
)r    r   Zget_character_extentsr   
rectToList)r!   r(   r3   ret   &&& r   getCharacterExtentsZText.getCharacterExtents  s(    * jj66txxS!#&r   c                T    \         P                  P                  V P                  4      # )a  
Return 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.
)r    r   get_default_attributesr   Zget_default_attribute_setZvaluesr!   r;   r*   r+      &   r   getDefaultAttributeSetZText.getDefaultAttributeSet$  s     zz88BBr   c                s    \         P                  P                  V P                  4      pRP	                  VP                  4        UUu. uF  w  r#VR,           V,           NK  	  upp4      # u uppi )z
Deprecated in favor of getDefaultAttributeSet. 
@return the attributes which apply to the entire text content,
but which were not explicitly specified by the content creator.
r.   r&   )r    r   r?   r   r/   r'   r@   rA   r   getDefaultAttributesZText.getDefaultAttributes4  sQ     jj77AxxSYY[ Q[zssU!2!2[ QRR Qs   A+
c                r>   )a  
Obtain the number of separate, contiguous selections in the current
Text object. Text objects which do not implement selection of
discontiguous text regions will always return '0' or '1'. Note
that "contiguous" is defined by continuity of the offsets, i.e.
a text 'selection' is defined by a start/end offset pair. In
the case of bidirectional text, this means that a continguous
selection may appear visually discontiguous, and vice-versa.
@return the number of contiguous selections in the current Text
object.
)r    r   Zget_n_selectionsr   r!      &r   getNSelectionsZText.getNSelections=  s     zz22488<<r   c                X    \         P                  P                  V P                  WV4      # )a
  
Get the offset of the character at a given onscreen coordinate.
The coordinate system used to interpret x and y is determined
by parameter coordType. 
@param : x
@param : y
@param : coordType
if 0, the input coordinates are interpreted relative to the entire
screen, if 1, they are relative to the toplevel window containing
this Text object. 
@return the text offset (as an offset into the character array)
of the glyph whose onscreen bounds contain the point x,y, or
-1 if the point is outside the bounds of any glyph.
)r    r   Zget_offset_at_pointr   )r!   r1   r2   r3      &&&&r   getOffsetAtPointZText.getOffsetAtPointK  s!     zz55dhhiPPr   c                sn    \         P                  P                  V P                  WV4      p\	        V4      # )a  
Obtain the bounding box which entirely contains a given text
range. Negative values may be returned for the bounding box parameters
in the event that all or part of the text range is offscreen
or not mapped to the screen. 
The returned values are meaningful only if the Text has
both STATE_VISIBLE and STATE_SHOWING.
@param : startOffset
the offset of the first character in the specified range. 
@param : endOffset
the offset of the character immediately after the last character
in the specified range. 
@param : x
an integer parameter which is back-filled with the minimum horizontal
coordinate of the resulting bounding box. 
@param : y
an integer parameter which is back-filled with the minimum vertical
coordinate of the resulting bounding box. 
@param : width
an integer parameter which is back-filled with the horizontal
extent of the bounding box. 
@param : height
an integer parameter which is back-filled with the vertical extent
of the bounding box. 
@param : coordType
If 0, the above coordinates are reported in pixels relative to
corner of the screen; if 1, the coordinates are reported relative
to the corner of the containing toplevel window.
)r    r   Zget_range_extentsr   r:   )r!   r"   r#   r3   r;   s   &&&& r   getRangeExtentsZText.getRangeExtents\  s+    < jj22488[U^_!#&r   c                sl    \         P                  P                  V P                  V4      p\	        V4      # )a  
The result of calling getSelection with an out-of-range selectionNum
(i.e. for a selection which does not exist) is not strictly defined,
but should set endOffset equal to startOffset.
@param : selectionNum
indicates which of a set of non-contiguous selections to modify.
@param : startOffset
back-filled with the starting offset of the resulting substring,
if one exists. 
@param : endOffset
back-filled with the offset of the character immediately following
the resulting substring, if one exists. 
)r    r   Zget_selectionr   rangeToList)r!   selectionNumr;   s   && r   getSelectionZText.getSelection}  s)     jj..txxF"3''r   c                r   )a1  
Obtain all or part of the onscreen textual content of a Text
object. If endOffset is specified as "-1", then this method will
return the entire onscreen textual contents of the Text object.
@param : startOffset
back-filled with the starting offset of the resulting substring,
if one exists. 
@param : endOffset
back-filled with the offset of the character immediately following
the resulting substring, if one exists. 
@return the textual content of the current Text object beginning
startOffset (inclusive) up to but not including the character
at endOffset.
)r    r   Zget_textr   r    r$   r   getTextZText.getText  s     zz**488[LLr   c                r9   )aX  
Deprecated in favor of getStringAtOffset.
Obtain a subset of the text content of an object which entirely
follows offset, delimited by character, word, line, or sentence
boundaries as specified by type. The starting and ending offsets
of the resulting substring are returned in startOffset and endOffset.
By definition, if such a substring exists, startOffset must be
greater than offset. 
@param : offset
the offset from which the substring search begins, and which
must lie before the returned substring. 
@param : type
the text-boundary delimiter which determines whether the returned
text constitures a character, word, line, or sentence (and possibly
attendant whitespace), and whether the start or ending of such
a substring forms the boundary condition. 
@param : startOffset
back-filled with the starting offset of the resulting substring,
if one exists. 
@param : endOffset
back-filled with the offset of the character immediately following
the resulting substring, if one exists. 
@return a string which is a substring of the text content of
the object, delimited by the specified boundary condition.
)r    r   Zget_text_after_offsetr   textRangeToListr!   r(   Ztyper;   r<   r   getTextAfterOffsetZText.getTextAfterOffset  s)    4 jj66txxN&s++r   c                r9   )a
  
Deprecated in favor of getStringAtOffset.
Obtain a subset of the text content of an object which includes
the specified offset, delimited by character, word, line, or
sentence boundaries as specified by type. The starting and ending
offsets of the resulting substring are returned in startOffset
and endOffset. 
@param : offset
the offset from which the substring search begins, and which
must lie within the returned substring. 
@param : type
the text-boundary delimiter which determines whether the returned
text constitures a character, word, line, or sentence (and possibly
attendant whitespace), and whether the start or ending of such
a substring forms the boundary condition. 
@param : startOffset
back-filled with the starting offset of the resulting substring,
if one exists. 
@param : endOffset
back-filled with the offset of the character immediately following
the resulting substring, if one exists. 
@return a string which is a substring of the text content of
the object, delimited by the specified boundary condition.
)r    r   Zget_text_at_offsetr   rO   rP   r<   r   getTextAtOffsetZText.getTextAtOffset  s)    2 jj33DHHfK&s++r   c                r9   )a)  
Deprecated in favor of getStringAtOffset.
Obtain a subset of the text content of an object which entirely
precedes offset, delimited by character, word, line, or sentence
boundaries as specified by type. The starting and ending offsets
of the resulting substring are returned in startOffset and endOffset.
By definition, if such a substring exists, endOffset is less
than or equal to offset. 
@param : offset
the offset from which the substring search begins. 
@param : type
the text-boundary delimiter which determines whether the returned
text constitures a character, word, line, or sentence (and possibly
attendant whitespace), and whether the start or ending of such
a substring forms the boundary condition. 
@param : startOffset
back-filled with the starting offset of the resulting substring,
if one exists. 
@param : endOffset
back-filled with the offset of the character immediately following
the resulting substring, if one exists. 
@return a string which is a substring of the text content of
the object, delimited by the specified boundary condition.
)r    r   Zget_text_before_offsetr   rO   rP   r<   r   getTextBeforeOffsetZText.getTextBeforeOffset  s)    2 jj77&O&s++r   c                r9   )a5  
Obtain a subset of the text content of an object which includes
the specified offset, delimited by character, word, line, sentence
or paragraph granularity as specified by type. The starting and ending
offsets of the resulting substring are returned in startOffset
and endOffset.
@param : offset
the offset from which the substring search begins, and which
must lie within the returned substring.
@param : type
the text granularity which determines whether the  returned text
constitures a character, word, line, sentence or paragraph (and
possibly attendant  whitespace). For all of those cases, boundaries
will always be defined from the start of the current substring to
the start of the following one for the same granularity.
@param : startOffset
back-filled with the starting offset of the resulting substring,
if one exists.
@param : endOffset
back-filled with the offset of the character immediately following
the resulting substring, if one exists.
@return a string which is a substring of the text content of
the object, delimited by the specified text granularity.
)r    r   Zget_string_at_offsetr   rO   rP   r<   r   getStringAtOffsetZText.getStringAtOffset  s)    2 jj55dhhM&s++r   c                r5   )aE  
Deselect the text contained in the specified selectionNum, if
such a selection exists, otherwise do nothing. Removal of a non-existant
selectionNum has no effect. 
@param : selectionNum
indicates which of a set of non-contiguous selections to modify.
@return True if the selection was successfully removed, False
otherwise.
)r    r   Zremove_selectionr   )r!   rL   r7   r   removeSelectionZText.removeSelection  s     zz22488\JJr   c                r5   )a  
Programmatically move the text caret (visible or virtual, as
above) to a given position. 
@param : offset
a long int indicating the desired character offset. Not all implementations
of Text will honor setCaretOffset requests, so the return value
below should be checked by the client. 
@return TRUE if the request was carried out, or FALSE if the
caret could not be moved to the requested position.
)r    r   Zset_caret_offsetr   r6   r7   r   setCaretOffsetZText.setCaretOffset  s     zz22488VDDr   c                rG   )aP  
Modify an existing selection's start or ending offset.
Calling setSelection for a selectionNum that is not already defined
has no effect. The result of calling setSelection with a selectionNum
greater than 0 for objects that do not include STATE_MULTISELECTABLE
is undefined. 
@param : selectionNum
indicates which of a set of non-contiguous selections to modify.
@param : startOffset
the new starting offset for the selection 
@param : endOffset
the new ending offset for the selection 
@return True if the selection corresponding to selectionNum is
successfully modified, False otherwise.
)r    r   Zset_selectionr   )r!   rL   r"   r#   rH   r   setSelectionZText.setSelection)  s"      zz//,U^__r   c                r>   N)r    r   Zget_caret_offsetr   rD   rE   r   get_caretOffsetZText.get_caretOffset;  s    zz22488<<r   a  
                The current offset of the text caret in the Text object. This
                caret may be virtual, e.g. non-visual and notional-only, but
                if an onscreen representation of the caret position is visible,
                it will correspond to this offset. The caret offset is given
                as a character offset, as opposed to a byte offset into a text
                buffer or a column offset.
                )ZfgetZdocc                r>   rX   )r    r   Zget_character_countr   rD   rE   r   get_characterCountZText.get_characterCountH  s    zz55dhh??r   z
                The total current number of characters in the Text object, including
                whitespace and non-spacing characters.
                c                rG   z
Makes the text range visible on the screen at a given position by
scrolling all necessary parents.
@return True if scrolling was successful.
)r    r   Zscroll_substring_tor   )r!   r"   r#   Zscroll_typerH   r   scrollSubstringToZText.scrollSubstringToQ  s"     zz55dhhXcddr   c                sZ    \         P                  P                  V P                  WW4V4      # r[   )r    r   Zscroll_substring_to_pointr   )r!   r"   r#   Z
coord_typer1   r2   s   &&&&&&r   scrollSubstringToPointZText.scrollSubstringToPointY  s%     zz;;DHHk^hmnoor   r   N)T)%r   r   r   r   Z__doc__r%   r,   r-   r0   r4   r8   r=   rB   rC   rF   rI   rJ   rM   rN   rQ   rR   rS   rT   rU   rV   rW   rY   Z_caretOffsetDocZpropertyZcaretOffsetrZ   Z_characterCountDocZcharacterCountr\   r]   r   Z__classdictcell__)Z__classdict__s   @r   r   r   c   s     	4	R3	6j	\0		5	u<	L	'0	J 	S	=	Q"	'B	("	M"	,:	,8	,8	,8
	K	E	`$	= 	 OI	@ 	
 "'9?QR	e	p 	pr   c                 s2    V P                   V P                  3# rX   )start_offset
end_offsetZrrE   r   rK   rK   a  s    --r   c                 sH    V P                   V P                  V P                  3# rX   )Zcontentr^   r_   r`   rE   r   rO   rO   d  s    		1>>1<<88r   N)r   r   r   r   r   r   r   r	   r
   r   r   r   r   r   r   r   r   r   r   )Zgi.repositoryr    Zpyatspi.atspienumZpyatspi.utilsZpyatspi.interfaceZ__all__Z	AtspiEnumr   r   r
   r	   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   Z	interfacer   rK   rO   r   r   r   <module>ra      s        0	
 	
 (* +A. -a0 /2 1!4 +A. -a0 
Y 
  "q!q!"
I 
 .a0 -a0 1!4 -a0 215 |p9 |p|.9r   