%PDF- %PDF-
Direktori : /lib/python3/dist-packages/xdg/__pycache__/ |
Current File : //lib/python3/dist-packages/xdg/__pycache__/Locale.cpython-312.pyc |
� �u�co � �H � d Z ddlZddlmZ dZd� Zdd�Zdd�Zg a e� y) z� Helper Module for Locale settings This module is based on a ROX module (LGPL): http://cvs.sourceforge.net/viewcvs.py/rox/ROX-Lib2/python/rox/i18n.py?rev=1.3&view=log � N)� normalizez>(\[([a-zA-Z]+)(_[a-zA-Z]+)?(\.[a-zA-Z0-9-]+)?(@[a-zA-Z]+)?\])?c �� � t | � } d}d}d}d}| j d� }|dk\ r| |d }| d | } ||z }nd}| j d� }d}|dk\ r| d | } | j d� }|dk\ r| |d }| d | } ||z }nd}| } g } t |dz � D ]: }|| z r� | }||z r||z }||z r||z }||z r||z }| j |� �< | j � | S ) N� � � r �@� �.�_)r �find�range�append�reverse) �locale�COMPONENT_CODESET�COMPONENT_MODIFIER�COMPONENT_TERRITORY�mask�pos�modifier�codeset� territory�language�ret�i�vals �,/usr/lib/python3/dist-packages/xdg/Locale.py�_expand_langr s< � � �v� �F� �� �� ���D� �+�+�c� �C� �a�x��#�$�<��������"�"���� �+�+�c� �C��G� �a�x������ �+�+�c� �C� �a�x��3�4�L� �������#�#��� ��H� �C� �4��6�]� ���T�E� ��C��&�&��y�(8���$�$��w����%�%��x����J�J�s�O� � �K�K�M��J� c �� � | �=g } dD ]6 }t j j |� }|s�%|j d� } n g }| D ]( }t |� D ] }||vs�|j |� � �* |S )N)�LANGUAGE�LC_ALL�LC_MESSAGES�LANG�:)�os�environ�get�splitr r )� languages�envarr �nelangs�lang�nelangs r �expand_languagesr/ 3 s� � ���� �B� �E��*�*�.�.��'�C���I�I�c�N� �� � �G�� '��"�4�(� '�F��W�$����v�&� '�'� �Nr c �6 � | r t | g� ay t � ay �N)r/ �langs)r s r �updater3 G s � �� �(��,�� �"�r r1 ) �__doc__r&