%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /usr/share/hplip/__pycache__/
Upload File :
Create Path :
Current File : //usr/share/hplip/__pycache__/sendfax.cpython-312.pyc

�

=	f|V��,�dZdZdZdZddlZddlZddlZddlZddlZddl	Z	ddl
Z
ddlZddl�ddl
mZddlmZmZmZddlmZmZ	dd	lmZej<ZgZgZ gZ!dZ"ejFeeeede$e%fe&e'e(f�Z)e)jUejVejXzgd�d
dg��e)j[dgd�d��\Z.Z/Z0Z1Z2Z3e.D]�\Z4Z5e4dk(rejmd��e4dvr-ejoe5�ejqejr��Ne4dk(re5Z0�Ve4dvr!ejue5jwd���{e4dvr!e jue5jwd����e4dvs��e!jue5jwd����ejxs#ej{d�ej|d�e)je0e/de
j�dfidg� �\ZAZ0Z/eAsej|d�e1e$k(rte2d!k(r8ej��s^ej{d"ez�ej|d�n7ej��s&ej{d#ez�ej|d�e1e$k(�re2d!k(�rvdZDdZE	ddlF�dd$lGmHZHeIej��ZDe3�PeKj�d&d'd(�Z3e3j��d(k(r*eNeOj���Z3ej7d)e3z�e3j��d*k7r�d+Z	e3jwd,�\ZQZRd,j�eQeg�Z3ej7d-e3z�eUd�ZVd.eQzZWej7d/eWz�eVj�eWej��ZZeZreDj�eV�nd*Z3e3d*k(rej7d0�n^ej7d1e3z�e\j�e\e3��e3e_P	ePj�ePj�ePj�e3��ej��dk(rWej{d2�ecj�dd3d4ecj�ecj�ecj��ej|d�eHe/e0e)j��ZEeDj�eE�ej��Zjej7d5ejz�eEj��	ej7d6�eDj���n^ej�e2�\ZIZoeeod7z�ZpeIej��ZDepj�de0e/e)j��Zrerj��	ej7d6�eDj���
n�ej��dk(r&ej{d8ez�ej|d�	ddluZudd9lvmwZwdd:lmxZxdd;lmZdd<lymzZzdd=lm{Z{	dd>l|m|Z|e|j��Z~	ddlZddl�Z�e��jdAe��e�j�\Z�Z�Z�e�re��#ej{dB�ej|d�gZ�ej7dCez�e�je�Zej7dDez�eD]4Z�e�D]-Z�e�dEvs�ej{dFe�z�ej|d��/�6ej7dGe!z�e�je!�Z!ej7dDe!z�e!D]EZ�e~�je��Z�e�se�jdHe�z��-e�D]Ze �je���Gej7dIe z�e�je �Z ej7dDe z�e D]�Z�e~j�e����ej{dJe�z�e~�j#�Z�e�j'e�j)dK��e�D].Z5e~j�e5�Z�e�j'e5�dLe�dM�dN���0e��ej|d���e D]HZ�e~j�e��Z5e5dMs�e��je5�ej7dOe5dP�dQe5dM����JeD]1Z�e��je�edR�dS��ej7dTe�z��3ej7dUe�z�e�se)�j1dVg�W�ez�j2�Z�e)j�D]�Z�e�j6�j9e��Z�ej7e��e�j6�j;e��r%e{�j<e��Z�ej7e��n&ej{dXe�z�ej|d�e�e�vs��ej{dYe��dZe��d[��ej|d���e�j'e�j)d\e0�d]e/�dN���e)�j?e0�	ez�j@e0�Z�e��oe�j6�j;e��rRe�e�d^��jGd_��jId`�dak(r&ej{dbe0z�ej|d�e)j�se)�j1dcg�W�gZ�e)j�D�]jZ�e�j6�j9e��Z�ej7e��e{�j<e��Z�e�ddk(r�e�j'dee�z�e�e�d^�Z�e��jGe|�jN�Z�e��jS�eu�jTdfe��\
Z�Z�Z�Z�Z�Z�Z�Z�Z�Z�e�dgk7r&ej{dhe�z�ej|d�e��je�e�didie�f���dZ�diZ�dZ�dZ�ez�jr�e�djvre"rez�jtdk�e�dkDrez�jtdle�z�	ez�jv�Z�ez�jzZ�e�D] Z�e��j~e0k(s�e��j�Z��"ej7dme�z�e�ez�j�k(r|ej7dne0�doe����ee�dp�Z�ez�j�e0e�e�j6�j�e���Z�e�j'dqe�e�fz�ej7dre�z�nOe�ez�j�k(rej7dse0z�n(ej{dte0e�fz�ej|d���3ez�jr�e	j�duzZ�e	j�e�kr�ej7dv�	e�e��j�e/ej<eī�Z�ej7e�eɫ�eNe�dx�Z�e�j'eΫe�rej7dye�z�e�dzZ�nae	�j�d�e	j�e�kr��ej{d{e�z�ez�j�eīej|d�e�e�d^�Z�e��jGe|�jN�Z�e�e��e|�jNk7r#ej{d|�ej|d�eu�jTdfe�de|�jN�\
Z�Z�Z�Z�Z�Z�Z�Z�Z�Z�ej7d}e�e�e�e�e�e�e�e�fz�e��je�e�die�e�f�e��jS���mdZ�ej7d~�	e|�j�e/e0�Z�	eӐjE�	eӐj�d��eӐj�e�kDrBeӐj�e�e�fvr1ej{d�eӐj�z�ej|d�eK�j�d�d�e�j^�ej7d��e�D]Z�ej7eNe����e��j�e/e0e�ej<ddi�ew�j��Z�ew�j��Z�e�j'd��eӐj�e�e�dididde0e�e�	sDej{d��e��j�e/e0e�ej<ddi�ej|d�	dZ�e�r0e�j���r	e�j�d�\Z�Z�Z�e�e|�j�k(rej7d���n�e�e|�j�k(re�j'd�e�z��n�e�e|�j�k(re�j'd�e�z��nfe�e|�j�k(re�j'd�e�z��n?e�e|�j�k(re�j'd�e�e�fz��ne�e|�j�k(re�j'd��n�e�e|�j�e|�j�e|�j�fvr�dZ�e�e|�j�k(r3ej{d��e��j�e/e0e�ej<ddi�n�e�e|�j�k(r3ej{d��e��j�e/e0e�ej<ddi�nCe�e|�j�k(r3e�j'd��e��j�e/e0e�ej<ddi�e�j��r��e�e	�j�d��e�r��0e��ej7d��eӁ4eӐj��ej7d��eӐjS�	e)�j��	e�j'di�e�j'd��y#e$r"Zej7e�dd
l
mZYdZ[��QdZ[wwxYw#e$r'ej{d%�ej|d�Y��>wxYw#eT$re3ZQd,j�e3eg�Z3Y���wxYw#ePj�$rY���wxYw#em$rY��wxYw#em$rej|d�Y��wxYw#e$r'ej{d?�ej|d�Y��~wxYw#e$r'ej{d@�ej|d�Y���wxYw#e�j��j�$r:ej{dw�ez�j�eīej|d�Y��4wxYw#ea$r(Ze�je�j��YdZ[���dZ[wwxYw#ea$r1Zej{d�e�j�z�e�e�_�YdZ[���dZ[wwxYw#ew�j�$rY���wxYw#em$rWe�j�e|�j�dididif�e��j�e/e0e�ej<ddi�ej{d��Y���wxYw#ej7d��eӁ4eӐj��ej7d��eӐjS�wwxYw#e)�j��wxYw#em$rej{d��Y���wxYw)�z9.0zPC Sendfax Utilityz
hp-sendfaxz7PC send fax for HPLIP supported multifunction printers.�N)�*)�device�tui�module)�
to_unicode�to_string_utf8)�
import_module)�dyn_import_modF))zSpecify the fax number(s):z]-f<number(s)> or --faxnum=<number(s)> or --fax-num=<number(s)>  or --num=<number(s)>(-n only)�optionF)zSpecify the recipient(s):z8-r<recipient(s)> or --recipient=<recipient(s)> (-n only)rF)zSpecify the groups(s):z3--group=<group(s)> or --groups=<group(s)> (-n only)rFzhp-faxsetupzhp-fab)�
extra_options�
see_also_listzf:r:g:)zfaxnum=zfax-num=z
recipient=zgroup=zgroups=�ggT)�supress_g_debug_flagz--gg�debug)z-zz	--logfilez--fax)z-fz--faxnumz	--fax-numz--num�,)z-rz--recipient)z-gz--groupz2Fax is disabled (turned off during build). Exiting�zfax-type�hpfax)�filter�back_end_filter�qt3z\%s requires GUI support (try running with --qt4). Also, try using non-interactive (-n) mode.z\%s requires GUI support (try running with --qt3). Also, try using non-interactive (-n) mode.)�FaxSendJobFormz,Unable to load Qt3 support. Is it installed?�ui�loc�systemzUsing system locale: %s�c�utf8�.z&Trying to load .qm file for %s locale.zhplip_%s.qmzName of .qm file: %szUsing default 'C' localezUsing locale: %sz)You must not be root to run this utility.zHP Device Manager - Send Faxz'You must not be root to run hp-sendfax.zpid=%dzStarting GUI loop...z.sendfaxdialogz%s cannot be run as root.)�queue)�PY3)r)�cups)�magic)�faxz1Fax address book disabled - Python 2.3+ required.z)PC send fax requires dBus and python-dbus�ignorezUUnable to initialize dBus. PC send fax requires dBus and hp-systray support. Exiting.zFaxnum list = %szUnique list=%sz0123456789-(+) *#zXInvalid character in fax number '%s'. Only the characters '0123456789-(+) *#' are valid.zGroup list = %szUnknown group name: %szRecipient list = %sz1Unknown fax recipient '%s' in the recipient list.z
Known recipients (entries):z (fax number: r"�)zName=�namez Number=�Unknown)r"r%z	Number=%szPhone num list = %szLNo recipients specified. Please use -f, -r, and/or -g to specify recipients.)�	error_msgzFile '%s' does not exist.zFile 'z"' has a non-allowed mime-type of '�'z
Using fax z (�rbi sHP Fax���z�Fax configuration error. The CUPS fax queue for '%s' is incorrectly configured. Please make sure that the CUPS fax queue is configured with the 'HP Fax' Model/Driver.zRNo files specfied to send. Please specify the file(s) to send on the command line.zapplication/hplip-faxz
Preparing fax file %s...z>8sBIHHBBBIIshplip_g3z#%s: Invalid file header. Bad magic.�)zapplication/x-cshellzapplication/x-perlzapplication/x-pythonzapplication/x-shellz
text/plain�prettyprintznumber-up=%dzPrinter state = %dzPrinter name = z file = zutf-8z 
Rendering file '%s' (job %d)...z	Job ID=%dz+Waiting for CUPS queue '%s' to become idle.zaThe CUPS queue for '%s' is in a stopped or busy state (%d). Please check the queue and try again.g^@zWaiting for fax...z0Cannot communicate with hp-systray. Canceling...�zFax file=%s�z3Timeout waiting for rendering. Canceling job #%d...z/Invalid fax file! (truncated header or no data)z>Magic=%s Ver=%d Pages=%d hDPI=%d vDPI=%d Size=%d Res=%d Enc=%dz
Checking device state...)�quickzQuery device error (%s).zzDevice is busy or in an error state (code=%d). Please wait for the device to become idle or clear the error and try again.�	last_used�
device_uriz
File list:z
Sending fax...z:Send fax is active. Please wait for operation to complete.�Idlez
Processing page %dz
Dialing %s...z
Connecting to %s...z
Sending page %d to %s...z
Cleaning up...zFax send error.z+Fax device is busy. Please try again later.z
Completed successfully.�z
Cancelling...z&Waiting for send fax thread to exit...zClosing device...z	User exitzDone.)��__version__�	__title__�__mod__�__doc__�sys�os�os.path�getopt�signal�time�operator�
subprocess�base.g�
base.utils�utils�baserrr�base.sixextrr�	importlibr	�ImportError�e�logrr
�prop�username�faxnum_list�recipient_list�
group_listr,�Module�GUI_MODE�NON_INTERACTIVE_MODE�UI_TOOLKIT_QT3�UI_TOOLKIT_QT4�UI_TOOLKIT_QT5�mod�setUsage�USAGE_FLAG_DEVICE_ARGS�USAGE_FLAG_SUPRESS_G_DEBUG_FLAG�parseStdOpts�optsr1�printer_name�mode�
ui_toolkitr�o�a�	set_level�set_logfile�	set_where�LOG_TO_CONSOLE_AND_FILE�extend�split�	fax_build�error�exit�getPrinterName�gt�sts�canEnterGUIMode�canEnterGUIMode4�app�sendfax�qt�ui.faxsendjobformr�QApplication�argv�	user_conf�get�lower�str�
QTextCodec�locale�l�x�join�
ValueError�QTranslator�trans�qm_file�load�localization_dir�loaded�installTranslator�QLocale�
setDefault�	setlocale�LC_ALL�	normalize�Error�geteuid�QMessageBox�critical�Ok�NoButton�args�
setMainWidget�getpid�pid�show�	exec_loop�KeyboardInterrupt�
import_dialog�
ui_packager�
SendFaxDialog�dlg�exec_�getuid�struct�base.sixext.movesrr�prntr r!r"�FaxAddressBook�db�dbus�warnings�simplefilter�DeprecationWarning�	init_dbus�
dbus_avail�service�session_bus�phone_num_list�
uniqueList�fr�g�
group_members�entries�warn�append�r�get_all_records�all_entries�info�bold�aa�print�p�usage�getAllowableMIMETypes�allowable_mime_types�path�realpath�exists�	mime_type�lockInstance�getPPD�ppd_file�open�read�find�	file_list�fax_file_fd�FILE_HEADER_SIZE�header�close�unpack�mg�version�pages�hort_dpi�vert_dpi�	page_size�
resolution�encoding�	reserved1�	reserved2�	all_pages�
page_range�page_set�nup�resetOptions�	addOption�getPrinters�
cups_printers�IPP_PRINTER_STATE_STOPPED�
printer_stater%�state�IPP_PRINTER_STATE_IDLE�	printFile�basename�sent_job_id�IPP_PRINTER_STATE_PROCESSING�end_time�list�CheckForWaitingFax�result�repr�
exceptions�
DBusException�	cancelJob�fax_file�title�sleep�len�total_pages�dev�getFaxDevice�msg�queryDevice�ERROR_STATE_ERROR�error_state�ERROR_STATE_MAX_OK�ERROR_STATE_LOW_SUPPLIES�ERROR_STATE_LOW_PAPER�set�	SendEvent�EVENT_START_FAX_JOB�Queue�update_queue�event_queue�	sendFaxes�EVENT_FAX_JOB_FAIL�cont�qsize�status�page_num�	phone_num�Empty�STATUS_IDLE�STATUS_PROCESSING_FILES�STATUS_DIALING�STATUS_CONNECTING�STATUS_SENDING�STATUS_CLEANUP�STATUS_ERROR�STATUS_BUSY�STATUS_COMPLETED�EVENT_END_FAX_JOB�update_spinner�cleanup_spinner�put�EVENT_FAX_SEND_CANCELED�EVENT_FAX_JOB_CANCELED�waitForSendFaxThread�unlockInstance���/usr/share/hplip/sendfax.py�<module>rs���2�� �	�
��
C���	��
�
������$�$�2�;�'��=�=������
�
����f�m�m�G�Y��W�d��3�4�#�^�^�D�F�����V�
*�
*�V�-S�-S�
S�i�!�(�+�
�-����X�'�+/��1�6��j�,��j�#�
�(�D�A�q��F�{��
�
�g��	
�!�	!�������
�
�c�1�1�2�	
�g����	
�6�	6����1�7�7�3�<�(�	
�#�	#����a�g�g�c�l�+�	
��	����!�'�'�#�,�'�%(�*�~�~��I�I�B�C��C�H�H�Q�K� #� 2� 2�<���h�k�k�1�-�.��	�!3�!K���\�:���C�H�H�Q�K��8���U��$�u�$�$�&��I�I�t�w~�~���C�H�H�Q�K�%�u�%�%�'��I�I�t�w~�~���C�H�H�Q�K��8���U������	��8��3�8�8�$���;��-�-��e�X�6�C��y�y�{�h�&��*�+�+�-�.���	�	�3�c�9�:��9�9�;�#���A�
)��y�y��~���1��h�h��1�v�&��

�I�I�>��D�E���%�E�#�a�'�G��I�I�,�w�6�7��Z�Z���)>�)>�?�F���%�%�e�,����#�:��I�I�0�1��I�I�(�3�.�/����w�s�|�,��D�K�
�� � �����0@�0@��0E�F�
�2�:�:�<�1���I�I�A�B�� � ��!?�!J�"-�.�.�"-�"6�"6�"-�"6�"6�
8�
�C�H�H�Q�K�!��!-�!$���+��	���'�"��b�i�i�k���	�	�(�S�.�!�����	��I�I�,�-��M�M�O�$7�5�#6�#6�z�#B� ��j�
�:�(8�8�
9���3�8�8�$�����t�\�:�s�x�x�H�����
�	��I�I�,�-��I�I�K��r�y�y�{�a���	�	�-��7�8�������r��+�#�+���	��!�c� � �"��	��
	�	����h�(:�;�+;�6�+;�+;�+=�(�
�G�[��W�_��I�I�m�n��C�H�H�Q�K����	�	�$�{�2�3�&�e�&�&�{�3���	�	�"�[�0�1��	 �A��
 ���/�/��I�I�x�{|�|�}��C�H�H�Q�K�
 �	 �	�	�	�#�j�0�1�%�U�%�%�j�1�
��	�	�"�Z�/�0��	-�A��&�&�q�)�G�����1�A�5�6� �-�A�"�)�)�!�,�-�	-�	�	�	�'�.�8�9�)��)�)�.�9���	�	�"�^�3�4��	�A��v�v�a�y� ��	�	�M�PQ�Q�R� �0�0�2��������"A�B�C�$�E�A������B��H�H�a��E��C�D�E���������	� �	G�A����q�	�A���x��%�%�a�(��	�	��6��A�e�H�E�F�		G��	'�A��!�!�!�Z�	�5J�"K�L��I�I�k�A�o�&�	'�	�	�	�'�.�8�9���I�I�!o� p�I�q�9�t�9�9�;�� ���
	�A��7�7�#�#�A�&�D��I�I�d�O��w�w�~�~�d�#�+�E�O�O�D�1�	��	�	�)�$��	�	�5��<�=�������� 4�4��	�	�T�S\�]�^�������
	�	�������z�J�K�L�	����&�q	!�"�t�{�{�<�0�H��#������x�(@���$�'�,�,�T�2�7�7�	�B�b�H��I�I�G�JV�V�W��C�H�H�Q�K��8�8��	�	�%y�$z�	�{��I��X�X�u
��
�w�w�'�'��*���	�	�$��+�E�O�O�D�1�	�� 7�7��H�H�9�A�=�>�"&�q�$�-�K�(�-�-�c�.B�.B�C�F��%�%�'�FS�V�]�]�Sa�ci�Ej�C�B����(�I�"�H�i���[�(��	�	�"G�!�"K�L� �������$�$�a��B��E�%B�C�!%�I�!#�J� �H��C�%�D�%�%�'� �%4�4�9D�&����}�5��Q�w�&����~��';�<��(8��(8�(8�(:�
�(,�(F�(F�
�!.�8�A� �v�v��5�01���
�8��	�	�"6��"F�G�(�D�,G�,G�G��I�I�|�UY�&Z�[�#-�d�G�#<�D�*8�$�.�.��t�R�W�W�M]�M]�^b�Mc�*d�K��H�H�%H�D�R]�K^�%^�_��I�I�k�K�&?�@�!�*�d�.O�.O�O��I�I�&S�Vb�&b�c��I�I�'J�NZ�\i�Mj�'j�k�$�C�H�H�Q�K�-�0&�D�%�%�'� )�t�y�y�{�U�2�H�#�$�)�)�+��0��	�	�"6�7�(�%)�'�*D�*D�Z�QU�Q^�Q^�`k�*l�%m�F��I�I�d�6�l�3�$'�v�a�y�>������*�#��I�I�m�h�&>�?�$*�1�I�E�!�"��
�
�1�
�)$�$�)�)�+��0�.�	�	�"W�Ze�"e�f�&����{�3� �������X�t�,�A��V�V�C�$8�$8�9�F��6�{�c�&:�&:�:��	�	�"S�T� ������&��
�
�n�f�=R�c�>R�>R�6S�T�C�B���h��)�"�H�i���I�I�^�!�7�K��8�Y�Xb�dl�m�n�o��$�$�h�	�2�u�k�%R�S��G�G�I�ku
�v�C��I�I�2�3�c
 �&�c�&�&�z�<�@��$��H�H�J�8��O�O�$�O�/�
�?�?�%7�7��O�O�,D�F[�+\�\��I�I�[�^a�^m�^m�m�n��C�H�H�Q�K��
�
�k�<����H��	�	�,�'�"�&�A��I�I�c�!�f�%�&��!�!�*�l�<O�QU�Q^�Q^�`a�ce�f�*�u�{�{�}��)�e�k�k�m�����+�,��}�}�^�Y��%'��u�l�%1�;�@��I�I�Z�[��%�%�j�,�@R�TX�Ta�Ta�cd�fh�i��C�H�H�Q�K�2/��D��*�0�0�2�&�>J�>N�>N�q�>Q� ;���)� &����8� #�	�	�&� 1�!'�3�+F�+F�!F� #���)?�(�)J� K�!'�3�+=�+=�!=� #���):�Y�)F� G�!'�3�+@�+@�!@� #���)@�9�)L� M�!'�3�+=�+=�!=� #���)E��S\�H]�)]� ^�!'�3�+=�+=�!=� #���);� <�!'�C�,<�,<�c�o�o�s�Oc�Oc�+d�!d�',��#)�c�.>�.>�#>�$'�I�I�.?�$@�$+�$5�$5�j�,�Pb�dh�dq�dq�st�vx�$y�%+�s���%>�$'�I�I�.[�$\�$+�$5�$5�j�,�Pb�dh�dq�dq�st�vx�$y�%+�s�/C�/C�%C�$'�H�H�-H�$I�$+�$5�$5�j�,�Pa�cg�cp�cp�rs�uw�$x�K+�0�0�2�N'�(�"��
�
�1�
�S�V$�%��	�	�B�C��?��,�,�.��I�I�1�2��I�I�K�
��� �
�����������]�;��I�I�a�L�:�:��;��Z�	��I�I�D�E��C�H�H�Q�K�	��$�
)����h�h��Q�x�(��
)��2�<�<�
��
��>!�	��	��.!�	��C�H�H�Q�K�	��*�	��I�I�I�J��C�H�H�Q�K�	���	��I�I�A�B��C�H�H�Q�K�	��P $���<�<�(��I�I�&X�Y�*�D�N�N�;�7�$�C�H�H�Q�K�(��f�$��H�H�Q�U�U�O�O��$��
�8��I�I�8�1�5�5�@�A�&7�C�O�O��8��L$)�;�;�&� %�&��R)�/��O�O�S�%@�%@�"�b�"�$M�N��%�%�j�,�@V�X\�Xe�Xe�gh�jl�m��I�I�o�.�/���	�	�B�C��?��,�,�.��I�I�1�2��I�I�K�#��
��� �����	�	�+���sw�AM<�AN&�
'AO�%+AO6�!AP�!AP�8"AX+�AP4�!AX+�3AQ#�7B AX+�DAX+�B0AX+�
EAX+�A'AX+�?H-AX�-E	AX�7;AR�2A AX�DAX�3AW	�AS*�AT�-EAW	�CAU*�CAU�C/G(AU*�KAU*�K7AU*�K>AAX�MAX+�M<AN#�NAN�NAN#�N&(AO�OAO�OAO3�O2AO3�O6AP	�PAP	�PAP�PAP�PAP1�P0AP1�P4(AQ �QAX+�QAQ �Q AX+�Q#(AR�RAX+�RAR�RAX+�RAAS'�S#AX�S&AS'�S'AX�S*AT�S/AT�TAW	�TAT�TAW	�TAU�T&AU�UAW	�UAU�UAW	�UAU'�U#AU*�U&AU'�U'AU*�U*AAW�WAW	�WAW�WAW	�W	A	AX�XAX�XAX(�X(AX+�X+AY�YAY

Zerion Mini Shell 1.0