| 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 : /lib/python3/dist-packages/orca/__pycache__/ |
Upload File : |
�
g
f � � � d Z dZdZdZdZdZddlZddlZddlm Z ddl
Z
e
j d d
� ddlm
Z
dd
lmZ ddlmZ G d� d� Zy)a�
Utilities for obtaining information about accessible hypertext and hyperlinks
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$zCopyright (c) 2024 Igalia, S.L.�LGPL� N)�urlparse�Atspiz2.0)r � )�debug)�AXObjectc � � e Zd ZdZed� � Zed� � Zed� � Zed� � Zed
d�� Z ed� � Z
ed� � Zedd �� Zed
� � Z
ed� � Zy)�AXHypertextzNUtilities for obtaining information about accessible hypertext and hyperlinks.c �N � t j | � sy t j j | � }d| d|� d�g}t
j t j |d� |S # t
$ r4}d|� �}t
j t j |d� Y d}~yd}~ww xY w)z(Returns the number of hyperlinks in obj.r z+AXHypertext: Exception in _get_link_count: TNzAXHypertext:zreports z hyperlinks)
r �supports_hypertextr � Hypertext�get_n_links� Exceptionr �printMessage�
LEVEL_INFO�printTokens)�obj�count�error�msg�tokenss �3/usr/lib/python3/dist-packages/orca/ax_hypertext.py�_get_link_countzAXHypertext._get_link_count3 s� � � �*�*�3�/�� ��O�O�/�/��4�E� !�#��%���'D�E��
���%�*�*�F�D�9���� � �?��w�G�C����u�/�/��d�;��� �s �A'