| Server IP : 39.108.156.168 / Your IP : 216.73.216.104 Web Server : nginx/1.24.0 System : Linux e2.ksyuki.com 6.11.0-25-generic #25~24.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Apr 15 17:20:50 UTC 2 x86_64 User : root ( 0) PHP Version : 8.3.6 Disable Function : NONE MySQL : OFF | cURL : OFF | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /usr/lib/python3/dist-packages/orca/__pycache__/ |
Upload File : |
�
g
fB8 � � � d Z dZdZdZdZdZddlZddlZ ej dd � dd
l m
Z
ddlmZ dd
l
mZ ddlmZ G d� d� Zy)a�
Utilities for obtaining position-related information about accessible objects.
These utilities are app-type- and toolkit-agnostic. Utilities that might have
different implementations or results depending on the type of app (e.g. terminal,
chat, web) or toolkit (e.g. Qt, Gtk) should be in script_utilities.py file(s).
N.B. There are currently utilities that should never have custom implementations
that live in script_utilities.py files. These will be moved over time.
z$Id$z
$Revision$z$Date$zGCopyright (c) 2024 Igalia, S.L.Copyright (c) 2024 GNOME Foundation Inc.�LGPL� N�Atspiz2.0)r � )�debug)�AXObject)�AXUtilitiesc � � e Zd ZdZed� � Zed� � Zed� � Zed� � Zed� � Z ed� � Z
ed� � Zed � � Zed
� � Z
ed� � Zed� � Zed
� � Zed� � Zed� � Zedd�� Zed� � Zed� � Zed� � Zed� � Zed� � Zed� � Zed� � Zed� � Zed� � Zy)�AXComponentzNUtilities for obtaining position-related information about accessible objects.c � � t j | � }|j |j dz z |j |j
dz z fS )z;Returns the center point of obj with respect to its window.� )r
�get_rect�x�width�y�height��obj�rects �3/usr/lib/python3/dist-packages/orca/ax_component.py�get_center_pointzAXComponent.get_center_point5 sA � � �#�#�C�(���v�v��
�
�Q��&�������q��(@�@�@� c �P � t j | � sy t j j | t j
j � }|j |j fS # t $ r4}d|� �}t j t j |d� Y d}~yd}~ww xY w)zBReturns the x, y position tuple of obj with respect to its window.����r �(AXComponent: Exception in get_position: TN)
r �supports_componentr � Component�get_position� CoordType�WINDOW� Exceptionr �printMessage�
LEVEL_INFOr r �r �point�error�msgs r r zAXComponent.get_position<