σ kŒZc@ΰsiddlmZddlmZddlmZddlmZddlmZddlZddlZddlm Z ddl m Z d d l m Z ejjd kr½dd lmZndd lmZeZe ddƒ7d ejkrddlmZnddlmZWdQXddddd„Zdefd„ƒYZd„ZedkreeƒndS(i(twith_statement(tabsolute_import(tdivision(tprint_function(tunicode_literalsN(tcontextmanager(tescapei(tLibtoolImporteri(tStringIOu UNINSTALLED_INTROSPECTION_SRCDIR(tcollect_attributesu cCΰs’|dkrg}nd|f}|dk rht|tƒrO|jdƒ}ndt|ƒ|f}nd}t||||t|ƒt|ƒƒ}|||S(Nu<%suUTF-8u>%su/>(tNonet isinstancetbytestdecodeRR tlen(ttag_namet attributestdatat self_indenttself_indent_chartprefixtsuffixtattrs((ss/home/vagrant/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/xmlwriter.pyt build_xml_tag1s    t XMLWritercBΰs˜eZd„Zdd„Zd„Zd„Zd„Zd„Zd„Z de e d„Z d „Z dd „Zdd „Zd „Zedd „ƒZRS(cCΰsEtƒ|_|jjdƒg|_d|_d|_|jƒdS(Nu ii(Rt_datatwritet _tag_stackt_indentt _indent_unittenable_whitespace(tself((ss/home/vagrant/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/xmlwriter.pyt__init__Fs     cCΰsX|dkrg}nt|||j|jt|ƒdƒ}|jd||fƒdS(Niu<%s%s>(R R Rt _indent_charRt write_line(RRRR((ss/home/vagrant/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/xmlwriter.pyt _open_tagTs    cCΰs|jd|fƒdS(Nu(R"(RR((ss/home/vagrant/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/xmlwriter.pyt _close_tag[scCΰsd|_d|_dS(Nu u (R!t _newline_char(R((ss/home/vagrant/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/xmlwriter.pyR`s cCΰsd|_d|_dS(Nu(R!R%(R((ss/home/vagrant/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/xmlwriter.pytdisable_whitespaceds cCΰs |jjƒS(u,Returns a unicode string containing the XML.(Rtgetvalue(R((ss/home/vagrant/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/xmlwriter.pytget_xmlhscCΰs|jjƒjdƒS(u8Returns a utf-8 encoded bytes object containing the XML.uutf-8(RR'tencode(R((ss/home/vagrant/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/xmlwriter.pytget_encoded_xmllsucCΰsŠt|tƒr!|jdƒ}n|r6t|ƒ}n|ri|jjd|j|j||jfƒn|jjd||jfƒdS(Nuutf-8u%s%s%su%s%s( R R R RRRR!RR%(Rtlinetindentt do_escape((ss/home/vagrant/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/xmlwriter.pyR"pscCΰs|jd|fƒdS(Nu (R"(Rttext((ss/home/vagrant/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/xmlwriter.pyt write_comment}scCΰs)|jt||||j|jƒƒdS(N(R"RRR!(RRRR((ss/home/vagrant/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/xmlwriter.pyt write_tag€scCΰsK|dkrg}n|j||ƒ|jj|ƒ|j|j7_dS(N(R R#RtappendRR(RRR((ss/home/vagrant/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/xmlwriter.pytpush_tag„s   cCΰs2|j|j8_|jjƒ}|j|ƒ|S(N(RRRtpopR$(RR((ss/home/vagrant/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/xmlwriter.pytpop_tag‹s ccΰs+|j||ƒz dVWd|jƒXdS(N(R2R4(RRR((ss/home/vagrant/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/xmlwriter.pyt tagcontext‘s N(t__name__t __module__R R R#R$RR&R(R*tTruetFalseR"R/R0R2R4RR5(((ss/home/vagrant/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/xmlwriter.pyRDs           cCΰs’tƒ}|jdƒ|jdƒ|jdƒ|jdddddgƒ|jƒ|jƒ|jƒ|jƒ}|jd ƒ}d dl}|j|ƒdS(Nu repositoryu namespaceu enumerationumemberunameuwestuvalueu7u c:identifieruGTK_ANCHOR_WESTu glib:nicku i(unameuwest(uvalueu7(u c:identifieruGTK_ANCHOR_WEST(u glib:nickuwest(RR2R4R(tsplittpprint(twtxtlinesR;((ss/home/vagrant/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/xmlwriter.pyttestšs"            u__main__(t __future__RRRRRtostsyst contextlibRtxml.sax.saxutilsRtlibtoolimporterRt version_infotmajorRtiotstrtunicodeR tenviront _giscannerR tgiscanner._giscannerRtobjectRR?R6(((ss/home/vagrant/ruby-gnome2.win32/gobject-introspection/vendor/local/lib/gobject-introspection/giscanner/xmlwriter.pyts.    V