ó žz2Tc@sƒddlZddlmZddlmZddlmZdZdZdZ d „Z d „Z d „Z d e fd „ƒYZdS(iÿÿÿÿN(tparsei(tast(tCOMPATIBLE_GIR_VERSIONs)http://www.gtk.org/introspection/core/1.0s&http://www.gtk.org/introspection/c/1.0s)http://www.gtk.org/introspection/glib/1.0cCsdt|fS(Ns{%s}%s(tCORE_NS(ttag((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyt_corens!scCsdt|fS(Ns{%s}%s(tGLIB_NS(R((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyt_glibns%scCsdt|fS(Ns{%s}%s(tC_NS(R((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyt_cns)st GIRParsercBs+eZed„Zd„Zd„Zd„Zd„Zd„Zd„Z d„Z d„Z d „Z d „Z d „Zd „Zd „Zd„Zd„Zd„Zdd„Zd„Zd„Zed„Zed„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Z d„Z!d„Z"RS( cCs||_d|_g|_dS(N(t _types_onlytNonet _namespacet_filename_stack(tselft types_only((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyt__init__/s  cCsLtjj|ƒ}|jj|ƒt|ƒ}|j|ƒ|jjƒdS(N(tostpathtabspathRtappendRt parse_treetpop(Rtfilenamettree((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyR6s   cCsMd|_tƒ|_tƒ|_tƒ|_d|_|j|jƒƒdS(N( R R tsett_pkgconfig_packagest _includest _c_includest _c_prefixt _parse_apitgetroot(RR((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyR=s      cCs|jS(N(R (R((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyt get_namespaceEscCsjt|tƒr<xT|jƒD]}|j|kr|SqWn*x'|jƒD]}|j|krI|SqIWdS(N(t isinstancetstrt getchildrenRR (Rtnodet name_or_namestchild((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyt_find_first_childJs cCs,g|jƒD]}|j|kr |^q S(N(R$R(RR%tnameR'((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyt_find_childrenUscCsN|js dStjƒtj}|jd}|j|ƒrJ|t|ƒS|S(Niÿÿÿÿ(RR Rtgetcwdtsept startswithtlen(Rtcwdtcurfile((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyt_get_current_fileXs  c CsÎ|jd}|tkr;td|jƒ|tfƒ‚nxƒ|jƒD]u}|jtdƒkrs|j|ƒqH|jtdƒkr˜|j|ƒqH|jt dƒkrH|j |ƒqHqHW|j tdƒƒ}|jj t dƒƒ}|r|j dƒ}n|jj t dƒƒ}|r6|j dƒ}ntj|jd |jdd |d |ƒ|_d |jkr“|jd j dƒ|j_n|j|j_|j|j_|j|j_i |jtd ƒ6|jtdƒ6|jtdƒ6|jtdƒ6|jtdƒ6|jtdƒ6|jtdƒ6|jtdƒ6|jtdƒ6}|j sˆ|j!|tdƒ<|j"|tdƒR<tabstractt0t is_abstracts type-structt fundamentalsref-funcs unref-funcsset-value-funcsget-value-funct-t_t implementst prerequisiteRCR]svirtual-methodtinvokert constructortpropertytsignal()RDRJR ttype_from_nameR RR RRRt InterfacetClasstAssertionErrorRctglib_type_structtTrueRxt__dict__treplaceR RR*t interfacest prerequisitest_parse_function_commontFunctiontstatic_methodst is_methodtmethodst VFunctionR}tvirtual_methodstis_constructort constructorstfieldstextendt _parse_fieldst propertiest_parse_propertytsignalstSignal(RR%RoRpt ctor_kwargstklassRwRnt type_structtis_fundamentaltfunc_idt func_nametifacet func_nodetfuncR]tctortpropR€((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyRTÇsz         ''    &cCs)|j|tjƒ}|jj|ƒdS(N(R‹RtCallbackR R(RR%R;((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyRS scCs)|j|tjƒ}|jj|ƒdS(N(R‹RRŒR R(RR%RC((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyRYsc CsË|j|ƒ}tj|jjdƒ||jjdƒp?tj|jjdƒ|jjdƒdk|jjdƒdk|jjdƒdk|jjdƒ|jjd ƒdkƒ }|j||ƒ|S( NR)t directionstransfer-ownershiptnullablet1toptionals allow-nonetscopescaller-allocates(RaRt ParameterRDRJtPARAM_DIRECTION_INRc(RR%Rdtparam((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyt_parse_parameterscCsÓ|jd}|jtdƒƒ}|s>td|fƒ‚n|jjdƒ}|jjdƒdk}tj|j|ƒ||ƒ}|j||ƒg} |jjdƒdk} |tj krð|||| | |jjt dƒƒƒ} n |tj kr2|jjt d ƒƒ} |||| | | ƒ} nÉ|tj krY|||| | ƒ} n¢|tj krû|||| d |jjd ƒd |jjd d ƒdkd|jjdd ƒdkd|jjdd ƒdkd|jjdd ƒdkƒ} n|jjddƒ| _|jjddƒ| _|jjddƒ| _|| _|jtdƒƒ} | dk r™|j| tdƒƒ}|r |j|ƒ| _nx6|j| tdƒƒD]}| j|j|ƒƒq¹Wx½t|j| tdƒƒƒD]š\}}| |}|j| ||jƒ|jjdƒ}|r[t|ƒ}| |j|_n|jjdƒ}|røt|ƒ}| |j|_qøqøWn|j| ||jƒ|j|| ƒ|jj | ƒ| S(NR)s return-valuesnode %r has no return-valuestransfer-ownershipR¨R©tthrowsR`t identifiertwhent no_recurses no-recurseRvtdetailedtactiontno_hookssno-hookstshadowss shadowed-bysmoved-tot parameterssinstance-parametert parametertclosuretdestroy(!RDRIRt ValueErrorRJRtReturnRaRcR¦R RŒRRšR R·t shadowed_bytmoved_toRoR(R¯tinstance_parameterR*Rt enumeratet_parse_type_array_lengthR`Rhtargnamet closure_namet destroy_nameR ttrack(RR%RœRoR)t returnnodettransferR¨tretvalR¸R°R£R±tparameters_nodet paramnodetiR®RºtidxR»((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyR‹#sh !     cCs|g}tdƒtdƒtdƒtdƒf}xE|jƒD]7}|j|kr=|j||ƒ}|j|ƒq=q=W|S(NtfieldR?R@R;(RR$Rt _parse_fieldR(RR%RntrestnamesR'tfieldobj((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyR–ds*c Cs2||jjdƒd|jjtdƒƒd|jjdƒdkd|jjtdƒƒd|jjtd ƒƒd |jjtd ƒƒƒ}|jjd ƒdkr´t|_n|j||ƒ|js.|jj |j ||ƒƒxQ|j |t d ƒƒD]7}|j |tj|ƒ}t|_|jj|ƒqWxRt|j |t dƒƒƒD]2\}}|j|}|j|j||jƒq\WxB|j |t dƒƒD](}|jj|j |tj|ƒƒq«WxT|j |t dƒƒD]7} |j | tj|ƒ}t|_|jj|ƒqðWn|S(NR)RtR`t disguisedR©Rqs type-nameRrsget-typeRss symbol-prefixtforeignR]RÎRCR~(RDRJR RR†RÔRcR R”R•R–R*RR‹RRŒRŽRRRÁRÂR`RR’R“( RtclsR%tcompoundR]R£RÌt fieldnodeRÎR¤((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyt_parse_compoundms4   +   cCsn|jtj|ƒ}|jjtdƒƒ}|dk rQ|jj|ƒ|_ n|sj|jj |ƒn|S(Nsis-gtype-struct-for( RØRtRecordRDRJRR R Rtis_gtype_struct_forR(RR%t anonymouststructRÚ((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyRU‰s cCs2|jtj|ƒ}|s.|jj|ƒn|S(N(RØRtUnionR R(RR%RÛR@((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyRV’scCsœ|jtdƒkrM|jj|jdƒ}|jjtdƒƒ|_|S|jtdƒkr|jjdƒ}|j|ƒ}|jjtdƒƒ}t j ||d|ƒ}|jjdƒ}|rã|dkrãt |_ n|jjdƒ}|r t |ƒ|_n|S|jtd ƒkr0t jƒS|jtdƒkr˜|jjdƒ} |jjtdƒƒ} | dkr¡| dkr‘t jƒSt jd| ƒS| dkr|j|ttdƒƒ} | dk ræ|j|ƒ}n t j}t j| |d| ƒS| d kr‚|j|tdƒƒ} t|j| ƒ} x&t| ƒd krc| jt jƒq>Wt j| d| dd| ƒS|jj| | ƒSndS(NR;R)R`tarrayRtszero-terminatedRvs fixed-sizetvarargss GLib.Lists GLib.SListsGLib.HashTableiii(s GLib.Lists GLib.SList(scallbacksarrayRßstype(RRR RRDRJR RtRaRtArraytFalsetzeroterminatedRhtsizetVarargsR t TypeUnknowntTypeR(tmaptTYPE_ANYtListR*t_parse_type_simpleR.RtMap(RttypenodeRdt array_typet element_typet array_ctypetrettzerot fixed_sizeR)Rttsubchildt subchildrentsubchildren_types((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyRê˜sR           cCsFx?ttdƒD].}|j|ƒ}|dk r|j|ƒSqWdS(NR;RÞRßR`(scallbacksarraysvarargsstype(RçRRIR Rê(RR%R)Rì((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyRaÊs  cCs|jtdƒƒ}|dkr%dS|jjdƒ}|dk r‹t|ƒ}t||tjƒrx||j |_ q‹||j |_ ndS(sYA hack necessary to handle the integer parameter/field indexes on array types.RÞNtlength( RIRR RDRJRhR"RtFieldR)tlength_param_nameRÃ(RtsiblingsR%RdRìtlenidxRÍ((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyRÂÑs   c Csytj|jtdƒd|jtdƒd|jtdƒd|jjtdƒƒƒ}|j||ƒ|jr‡|jj |ƒdSxQ|j |t dƒƒD]7}|j |tj |ƒ}t|_|jj |ƒq WxB|j |t d ƒƒD](}|jj |j |tj |ƒƒqôWxB|j |t d ƒƒD](}|jj |j |tj|ƒƒq9W|jj |ƒdS( NR)Rqs type-nameRrsget-typeRss symbol-prefixR]R~R;(RtBoxedRDRRJR RcR R RR*RR‹RŒR†RŽRR“R”R¦(RR%RnR]R£R¤R;((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyRWàs&    cCsd}d}|jttd ƒkr-|}n|j|tdƒƒ}|dk rÛ|jtdƒkr~|j|tjƒ}qê|jtdƒkr«|j|dt ƒ}qê|jtdƒkrê|j |dt ƒ}qên|j |ƒ}tj |j jdƒ||j jdƒdk|j jdƒd k|j jd ƒd |ƒ}|j jd ƒd k|_||_|j||ƒ|S(NR?R@R;RÛR)treadableRvtwritableR©tbitstanonymous_nodetprivate(srecordsunion(R RRçRR(R‹RR¦RUR†RVRaR÷RDRJRRoRc(RR%Rot type_nodeRÿt anonymous_eltRÎ((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyRÏ÷s0    c Cs¢tj|jd|j|ƒ|jjdƒdk|jjdƒdk|jjdƒdk|jjdƒdk|jjdƒƒ}|j||ƒ||_|S( NR)RüRvRýR©t constructsconstruct-onlystransfer-ownership(RtPropertyRDRaRJRcRo(RR%RoR¥((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyR˜s  cCs^tj|jd|jd|jjtdƒƒ|jjtdƒƒƒ}|j||ƒ|S(NR)tvalueR±tnick(RtMemberRDRJR RRc(RR%tmember((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyt _parse_member!s  cCsk|j|ƒ}tj|jd||jd|jjtdƒƒƒ}|j||ƒ|jj|ƒdS(NR)RR`( RaRtConstantRDRJR RcR R(RR%RRB((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyRX)s c Cs¯|jjdƒ}|jjtdƒƒ}|jjtdƒƒ}|jjtdƒƒ}|jjtdƒƒ}|jtdƒkr“tj}n tj}g}|||d|d|d |ƒ} || _ || _ |j || ƒ|j r|j j| ƒdSxE|j|td ƒƒD]+} |j| ƒ} | | _|j| ƒqWxN|j|td ƒƒD]4} |j| tjƒ} | | _| jj| ƒqcW|j j| ƒdS( NR)R`sget-types type-names error-domainR:tmembersRqRrRRC(RDRJR RRRRtBitfieldtEnumt error_domainRtRcR R RR*R RoR‹RŒR(RR%R)RtRrt type_nametglib_error_domainRœR Rnt member_nodeRR¢R£((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyRR2s8         N(#t__name__t __module__RáRRRR!R(R*R1RRFRGRHRQRcRTRSRYR¯R R‹R–RØRURVRêRaRÂRWRÏR˜R RXRR(((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyR -s>      5     ! F    A   2      (Rtxml.etree.cElementTreeRtRt girwriterRRRRRRR tobjectR (((sy/home/kou/work/ruby/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/girparser.pyts