| Server IP : 93.86.61.54 / Your IP : 216.73.216.60 Web Server : Apache/2.4.62 (Ubuntu) System : Linux rasin.ddns.net 6.8.0-124-generic #124~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue May 26 21:05:19 UTC x86_64 User : www-data ( 33) PHP Version : 8.4.22 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /usr/share/ibus-table/engine/__pycache__/ |
Upload File : |
o
��aW6 � @ s
d dl mZ d dl mZ d dlZd dlZd dlZd dlZd dlmZmZm Z d dl
Z
d dlZ
d dlm
Z
e
dd� d dlmZ d d lmZ d dlZd dlZe
�d
�Zed �Zzeee�d���ZW n eefyp ed �ZY nw ej�e�� d�Zej�e�� d
�Z ej�e�� d�Z!ej�e�"� d�Z#ej�e�$� d�Z%defdd�Z&e&� Z'e'j(r�d dl)Z)d dl*Z*d dl+Z+e)�,� Z-e'j.r�d dl/m0Z0 d dl1m2Z2m3Z3m4Z4 nd dl5Z5G dd� d�Z6de6ddfdd�Z7d$dededdfdd�Z8d%dd �Z9d%d!d"�Z:e;d#k�re:� dS dS )&� )�Any)�UnionN)�signal�SIGTERM�SIGINT)�require_version�IBusz1.0)r )�GLib�
ibus-table�IBUS_TABLE_DEBUG_LEVEL�tablesz
byo-tables�iconszibus-setup-tablez debug.log�returnc C s� t �� } | jdddtdddd� | jdd d
ddd
d� | jddd
dddd� | jddd
dddd� | jddddddt d d� | jddd
d dd!d� | �� S )"z Parse the command line argumentsz--tablez-t�store�db� z,Set the IME table file, default: %(default)s)�action�type�dest�default�helpz--daemonz-d�
store_true�daemonFz#Run as daemon, default: %(default)s)r r r r z--ibusz-i�ibusz+Set the IME icon file, default: %(default)sz--xmlz-x�xmlz1output the engines xml part, default: %(default)sz
--no-debugz-n�store_false�debugTzWrite log file to z, default: %(default)sz --profilez-p�profilezlPrint profiling information into the debug log. Works only when --no-debug is not used. default: %(default)s)�argparse�ArgumentParser�add_argument�str�LOGFILE�
parse_args)�parser� r% �$/usr/share/ibus-table/engine/main.pyr# 6 sZ ����
��r# )�getdefaultlocale)�Element�
SubElement�tostringc @ sJ e Zd Zdededdfdd�Zddd�Zdd d
�Zddeddfdd
�Z dS )�IMApp�dbfile�exec_by_ibusr Nc C s� t dkr
t�d|� t�� | _t�� | _| j� d| j
� t�| j|�| _
d| _|r2| j�dd� d S tjdddd d
ddd
�| _d}d}d}d}d}d}d} d}
d}d}| j
jr�tj�| j
jj��dd�}d| }| j
jj�d�}| j
jj�d�}| j
jj�d�}| j
jj�d�}| j
jj�d�} | j
jj�d�}
| j
jj�d�}| j
jj�d�}|
r�tj�t|
�}
t�|
tj�s�d}
d�t|�}
tj |||||| |
|||
d�
}| j�!|� | j�"| j� d S )N� z IMApp.__init__(exec_by_ibus=%s)
�disconnectedFzorg.freedesktop.IBus.Tabler zTable Componentz0.1.0�GPLzYuwei Yu <acevery@gmail.com>zhttp://code.google.com/p/ibus/r
)�name�description�version�license�author�homepage�
textdomainr �en�us�.db�table:r1 r2 � languages�creditr5 �icon�layout�symbol�{} --engine-name {})
r1 �longnamer2 �languager4 r5 r>