a
ƒÆb] ã , @ sô d dl mZmZmZmZmZmZmZ dadd„ Z dd„ Z
dd„ Zeje
ejeejeejeejeejeejeejeejeejeejeejeejeejeejeej e!ej"e!ej#e!ej$dej%dej&dej'diZ(d d
„ Z)dd„ Z*d
d„ Z+dd„ Z,e e,ƒ dS )é )Ú VFuncInfoÚFunctionInfoÚCallableInfoÚ
ObjectInfoÚ
StructInfoÚ DirectionÚTypeTagNc C s | a dS )zSet doc string generator function
:param callable func:
Callable which takes a GIInfoStruct and returns documentation for it.
N©Ú_generate_doc_string_func)Úfunc© r ú2/usr/lib64/python3.9/site-packages/gi/docstring.pyÚset_doc_string_generator% s r c C s t S )z6Returns the currently registered doc string generator.r r r r r
Úget_doc_string_generator/ s r c C s t | ƒS )aE Generate a doc string given a GIInfoStruct.
:param gi.types.BaseInfo info:
GI info instance to generate documentation for.
:returns:
Generated documentation as a string.
:rtype: str
This passes the info struct to the currently registered doc string
generator and returns the result.
r ©Úinfor r r
Úgenerate_doc_string4 s r c C sf | ¡ }t |d ¡}|r(t|dƒr(|jS |tjkr^| ¡ }| ¡ }|sN| ¡ S d|
¡ |f S | ¡ S )NÚ__name__z%s.%s)Zget_tagÚ_type_tag_to_py_typeÚgetÚhasattrr r Ú INTERFACEZ
get_interfaceÚget_nameZget_tag_as_stringZ
get_namespace)Zgi_typeZtype_tagZpy_typeZifaceZ info_namer r r
Ú_get_pytype_hint\ s
r c
C sò g }t | tƒrdg}nt | tƒr.| ¡ r.dg}| ¡ }d}tƒ }tƒ }|D ]2}| | ¡ ¡ | | ¡ ¡ ¡ | |
¡ ¡ qJt|ƒD ]~\}}| ¡ t
jkržq†||v r¨q†| ¡ }t| ¡ ƒ} | |vrÐ|d| 7 }| ¡ sà||v rê|d7 }n| ¡ rú|d7 }| |¡ q†d |¡}
g }t| ¡ ƒ}| ¡ sZ|rZ||vrZ|}| ¡ rP|d7 }| |¡ t|ƒD ]`\}}| ¡ t
jkr~qb||v rŒqb| ¡ }t| ¡ ƒ} | |vr¶|d| 7 }| |¡ qb|ràd| j|
d |¡f S d | j|
f S d S )
NÚself)Zvoidú:z=Nonez=