%PDF- %PDF-
Direktori : /lib/python3/dist-packages/orca/__pycache__/ |
Current File : //lib/python3/dist-packages/orca/__pycache__/ax_hypertext.cpython-312.pyc |
� 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'