ccgo_linux_amd64.go 845 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476747774787479748074817482748374847485748674877488748974907491749274937494749574967497749874997500750175027503750475057506750775087509751075117512751375147515751675177518751975207521752275237524752575267527752875297530753175327533753475357536753775387539754075417542754375447545754675477548754975507551755275537554755575567557755875597560756175627563756475657566756775687569757075717572757375747575757675777578757975807581758275837584758575867587758875897590759175927593759475957596759775987599760076017602760376047605760676077608760976107611761276137614761576167617761876197620762176227623762476257626762776287629763076317632763376347635763676377638763976407641764276437644764576467647764876497650765176527653765476557656765776587659766076617662766376647665766676677668766976707671767276737674767576767677767876797680768176827683768476857686768776887689769076917692769376947695769676977698769977007701770277037704770577067707770877097710771177127713771477157716771777187719772077217722772377247725772677277728772977307731773277337734773577367737773877397740774177427743774477457746774777487749775077517752775377547755775677577758775977607761776277637764776577667767776877697770777177727773777477757776777777787779778077817782778377847785778677877788778977907791779277937794779577967797779877997800780178027803780478057806780778087809781078117812781378147815781678177818781978207821782278237824782578267827782878297830783178327833783478357836783778387839784078417842784378447845784678477848784978507851785278537854785578567857785878597860786178627863786478657866786778687869787078717872787378747875787678777878787978807881788278837884788578867887788878897890789178927893789478957896789778987899790079017902790379047905790679077908790979107911791279137914791579167917791879197920792179227923792479257926792779287929793079317932793379347935793679377938793979407941794279437944794579467947794879497950795179527953795479557956795779587959796079617962796379647965796679677968796979707971797279737974797579767977797879797980798179827983798479857986798779887989799079917992799379947995799679977998799980008001800280038004800580068007800880098010801180128013801480158016801780188019802080218022802380248025802680278028802980308031803280338034803580368037803880398040804180428043804480458046804780488049805080518052805380548055805680578058805980608061806280638064806580668067806880698070807180728073807480758076807780788079808080818082808380848085808680878088808980908091809280938094809580968097809880998100810181028103810481058106810781088109811081118112811381148115811681178118811981208121812281238124812581268127812881298130813181328133813481358136813781388139814081418142814381448145814681478148814981508151815281538154815581568157815881598160816181628163816481658166816781688169817081718172817381748175817681778178817981808181818281838184818581868187818881898190819181928193819481958196819781988199820082018202820382048205820682078208820982108211821282138214821582168217821882198220822182228223822482258226822782288229823082318232823382348235823682378238823982408241824282438244824582468247824882498250825182528253825482558256825782588259826082618262826382648265826682678268826982708271827282738274827582768277827882798280828182828283828482858286828782888289829082918292829382948295829682978298829983008301830283038304830583068307830883098310831183128313831483158316831783188319832083218322832383248325832683278328832983308331833283338334833583368337833883398340834183428343834483458346834783488349835083518352835383548355835683578358835983608361836283638364836583668367836883698370837183728373837483758376837783788379838083818382838383848385838683878388838983908391839283938394839583968397839883998400840184028403840484058406840784088409841084118412841384148415841684178418841984208421842284238424842584268427842884298430843184328433843484358436843784388439844084418442844384448445844684478448844984508451845284538454845584568457845884598460846184628463846484658466846784688469847084718472847384748475847684778478847984808481848284838484848584868487848884898490849184928493849484958496849784988499850085018502850385048505850685078508850985108511851285138514851585168517851885198520852185228523852485258526852785288529853085318532853385348535853685378538853985408541854285438544854585468547854885498550855185528553855485558556855785588559856085618562856385648565856685678568856985708571857285738574857585768577857885798580858185828583858485858586858785888589859085918592859385948595859685978598859986008601860286038604860586068607860886098610861186128613861486158616861786188619862086218622862386248625862686278628862986308631863286338634863586368637863886398640864186428643864486458646864786488649865086518652865386548655865686578658865986608661866286638664866586668667866886698670867186728673867486758676867786788679868086818682868386848685868686878688868986908691869286938694869586968697869886998700870187028703870487058706870787088709871087118712871387148715871687178718871987208721872287238724872587268727872887298730873187328733873487358736873787388739874087418742874387448745874687478748874987508751875287538754875587568757875887598760876187628763876487658766876787688769877087718772877387748775877687778778877987808781878287838784878587868787878887898790879187928793879487958796879787988799880088018802880388048805880688078808880988108811881288138814881588168817881888198820882188228823882488258826882788288829883088318832883388348835883688378838883988408841884288438844884588468847884888498850885188528853885488558856885788588859886088618862886388648865886688678868886988708871887288738874887588768877887888798880888188828883888488858886888788888889889088918892889388948895889688978898889989008901890289038904890589068907890889098910891189128913891489158916891789188919892089218922892389248925892689278928892989308931893289338934893589368937893889398940894189428943894489458946894789488949895089518952895389548955895689578958895989608961896289638964896589668967896889698970897189728973897489758976897789788979898089818982898389848985898689878988898989908991899289938994899589968997899889999000900190029003900490059006900790089009901090119012901390149015901690179018901990209021902290239024902590269027902890299030903190329033903490359036903790389039904090419042904390449045904690479048904990509051905290539054905590569057905890599060906190629063906490659066906790689069907090719072907390749075907690779078907990809081908290839084908590869087908890899090909190929093909490959096909790989099910091019102910391049105910691079108910991109111911291139114911591169117911891199120912191229123912491259126912791289129913091319132913391349135913691379138913991409141914291439144914591469147914891499150915191529153915491559156915791589159916091619162916391649165916691679168916991709171917291739174917591769177917891799180918191829183918491859186918791889189919091919192919391949195919691979198919992009201920292039204920592069207920892099210921192129213921492159216921792189219922092219222922392249225922692279228922992309231923292339234923592369237923892399240924192429243924492459246924792489249925092519252925392549255925692579258925992609261926292639264926592669267926892699270927192729273927492759276927792789279928092819282928392849285928692879288928992909291929292939294929592969297929892999300930193029303930493059306930793089309931093119312931393149315931693179318931993209321932293239324932593269327932893299330933193329333933493359336933793389339934093419342934393449345934693479348934993509351935293539354935593569357935893599360936193629363936493659366936793689369937093719372937393749375937693779378937993809381938293839384938593869387938893899390939193929393939493959396939793989399940094019402940394049405940694079408940994109411941294139414941594169417941894199420942194229423942494259426942794289429943094319432943394349435943694379438943994409441944294439444944594469447944894499450945194529453945494559456945794589459946094619462946394649465946694679468946994709471947294739474947594769477947894799480948194829483948494859486948794889489949094919492949394949495949694979498949995009501950295039504950595069507950895099510951195129513951495159516951795189519952095219522952395249525952695279528952995309531953295339534953595369537953895399540954195429543954495459546954795489549955095519552955395549555955695579558955995609561956295639564956595669567956895699570957195729573957495759576957795789579958095819582958395849585958695879588958995909591959295939594959595969597959895999600960196029603960496059606960796089609961096119612961396149615961696179618961996209621962296239624962596269627962896299630963196329633963496359636963796389639964096419642964396449645964696479648964996509651965296539654965596569657965896599660966196629663966496659666966796689669967096719672967396749675967696779678967996809681968296839684968596869687968896899690969196929693969496959696969796989699970097019702970397049705970697079708970997109711971297139714971597169717971897199720972197229723972497259726972797289729973097319732973397349735973697379738973997409741974297439744974597469747974897499750975197529753975497559756975797589759976097619762976397649765976697679768976997709771977297739774977597769777977897799780978197829783978497859786978797889789979097919792979397949795979697979798979998009801980298039804980598069807980898099810981198129813981498159816981798189819982098219822982398249825982698279828982998309831983298339834983598369837983898399840984198429843984498459846984798489849985098519852985398549855985698579858985998609861986298639864986598669867986898699870987198729873987498759876987798789879988098819882988398849885988698879888988998909891989298939894989598969897989898999900990199029903990499059906990799089909991099119912991399149915991699179918991999209921992299239924992599269927992899299930993199329933993499359936993799389939994099419942994399449945994699479948994999509951995299539954995599569957995899599960996199629963996499659966996799689969997099719972997399749975997699779978997999809981998299839984998599869987998899899990999199929993999499959996999799989999100001000110002100031000410005100061000710008100091001010011100121001310014100151001610017100181001910020100211002210023100241002510026100271002810029100301003110032100331003410035100361003710038100391004010041100421004310044100451004610047100481004910050100511005210053100541005510056100571005810059100601006110062100631006410065100661006710068100691007010071100721007310074100751007610077100781007910080100811008210083100841008510086100871008810089100901009110092100931009410095100961009710098100991010010101101021010310104101051010610107101081010910110101111011210113101141011510116101171011810119101201012110122101231012410125101261012710128101291013010131101321013310134101351013610137101381013910140101411014210143101441014510146101471014810149101501015110152101531015410155101561015710158101591016010161101621016310164101651016610167101681016910170101711017210173101741017510176101771017810179101801018110182101831018410185101861018710188101891019010191101921019310194101951019610197101981019910200102011020210203102041020510206102071020810209102101021110212102131021410215102161021710218102191022010221102221022310224102251022610227102281022910230102311023210233102341023510236102371023810239102401024110242102431024410245102461024710248102491025010251102521025310254102551025610257102581025910260102611026210263102641026510266102671026810269102701027110272102731027410275102761027710278102791028010281102821028310284102851028610287102881028910290102911029210293102941029510296102971029810299103001030110302103031030410305103061030710308103091031010311103121031310314103151031610317103181031910320103211032210323103241032510326103271032810329103301033110332103331033410335103361033710338103391034010341103421034310344103451034610347103481034910350103511035210353103541035510356103571035810359103601036110362103631036410365103661036710368103691037010371103721037310374103751037610377103781037910380103811038210383103841038510386103871038810389103901039110392103931039410395103961039710398103991040010401104021040310404104051040610407104081040910410104111041210413104141041510416104171041810419104201042110422104231042410425104261042710428104291043010431104321043310434104351043610437104381043910440104411044210443104441044510446104471044810449104501045110452104531045410455104561045710458104591046010461104621046310464104651046610467104681046910470104711047210473104741047510476104771047810479104801048110482104831048410485104861048710488104891049010491104921049310494104951049610497104981049910500105011050210503105041050510506105071050810509105101051110512105131051410515105161051710518105191052010521105221052310524105251052610527105281052910530105311053210533105341053510536105371053810539105401054110542105431054410545105461054710548105491055010551105521055310554105551055610557105581055910560105611056210563105641056510566105671056810569105701057110572105731057410575105761057710578105791058010581105821058310584105851058610587105881058910590105911059210593105941059510596105971059810599106001060110602106031060410605106061060710608106091061010611106121061310614106151061610617106181061910620106211062210623106241062510626106271062810629106301063110632106331063410635106361063710638106391064010641106421064310644106451064610647106481064910650106511065210653106541065510656106571065810659106601066110662106631066410665106661066710668106691067010671106721067310674106751067610677106781067910680106811068210683106841068510686106871068810689106901069110692106931069410695106961069710698106991070010701107021070310704107051070610707107081070910710107111071210713107141071510716107171071810719107201072110722107231072410725107261072710728107291073010731107321073310734107351073610737107381073910740107411074210743107441074510746107471074810749107501075110752107531075410755107561075710758107591076010761107621076310764107651076610767107681076910770107711077210773107741077510776107771077810779107801078110782107831078410785107861078710788107891079010791107921079310794107951079610797107981079910800108011080210803108041080510806108071080810809108101081110812108131081410815108161081710818108191082010821108221082310824108251082610827108281082910830108311083210833108341083510836108371083810839108401084110842108431084410845108461084710848108491085010851108521085310854108551085610857108581085910860108611086210863108641086510866108671086810869108701087110872108731087410875108761087710878108791088010881108821088310884108851088610887108881088910890108911089210893108941089510896108971089810899109001090110902109031090410905109061090710908109091091010911109121091310914109151091610917109181091910920109211092210923109241092510926109271092810929109301093110932109331093410935109361093710938109391094010941109421094310944109451094610947109481094910950109511095210953109541095510956109571095810959109601096110962109631096410965109661096710968109691097010971109721097310974109751097610977109781097910980109811098210983109841098510986109871098810989109901099110992109931099410995109961099710998109991100011001110021100311004110051100611007110081100911010110111101211013110141101511016110171101811019110201102111022110231102411025110261102711028110291103011031110321103311034110351103611037110381103911040110411104211043110441104511046110471104811049110501105111052110531105411055110561105711058110591106011061110621106311064110651106611067110681106911070110711107211073110741107511076110771107811079110801108111082110831108411085110861108711088110891109011091110921109311094110951109611097110981109911100111011110211103111041110511106111071110811109111101111111112111131111411115111161111711118111191112011121111221112311124111251112611127111281112911130111311113211133111341113511136111371113811139111401114111142111431114411145111461114711148111491115011151111521115311154111551115611157111581115911160111611116211163111641116511166111671116811169111701117111172111731117411175111761117711178111791118011181111821118311184111851118611187111881118911190111911119211193111941119511196111971119811199112001120111202112031120411205112061120711208112091121011211112121121311214112151121611217112181121911220112211122211223112241122511226112271122811229112301123111232112331123411235112361123711238112391124011241112421124311244112451124611247112481124911250112511125211253112541125511256112571125811259112601126111262112631126411265112661126711268112691127011271112721127311274112751127611277112781127911280112811128211283112841128511286112871128811289112901129111292112931129411295112961129711298112991130011301113021130311304113051130611307113081130911310113111131211313113141131511316113171131811319113201132111322113231132411325113261132711328113291133011331113321133311334113351133611337113381133911340113411134211343113441134511346113471134811349113501135111352113531135411355113561135711358113591136011361113621136311364113651136611367113681136911370113711137211373113741137511376113771137811379113801138111382113831138411385113861138711388113891139011391113921139311394113951139611397113981139911400114011140211403114041140511406114071140811409114101141111412114131141411415114161141711418114191142011421114221142311424114251142611427114281142911430114311143211433114341143511436114371143811439114401144111442114431144411445114461144711448114491145011451114521145311454114551145611457114581145911460114611146211463114641146511466114671146811469114701147111472114731147411475114761147711478114791148011481114821148311484114851148611487114881148911490114911149211493114941149511496114971149811499115001150111502115031150411505115061150711508115091151011511115121151311514115151151611517115181151911520115211152211523115241152511526115271152811529115301153111532115331153411535115361153711538115391154011541115421154311544115451154611547115481154911550115511155211553115541155511556115571155811559115601156111562115631156411565115661156711568115691157011571115721157311574115751157611577115781157911580115811158211583115841158511586115871158811589115901159111592115931159411595115961159711598115991160011601116021160311604116051160611607116081160911610116111161211613116141161511616116171161811619116201162111622116231162411625116261162711628116291163011631116321163311634116351163611637116381163911640116411164211643116441164511646116471164811649116501165111652116531165411655116561165711658116591166011661116621166311664116651166611667116681166911670116711167211673116741167511676116771167811679116801168111682116831168411685116861168711688116891169011691116921169311694116951169611697116981169911700117011170211703117041170511706117071170811709117101171111712117131171411715117161171711718117191172011721117221172311724117251172611727117281172911730117311173211733117341173511736117371173811739117401174111742117431174411745117461174711748117491175011751117521175311754117551175611757117581175911760117611176211763117641176511766117671176811769117701177111772117731177411775117761177711778117791178011781117821178311784117851178611787117881178911790117911179211793117941179511796117971179811799118001180111802118031180411805118061180711808118091181011811118121181311814118151181611817118181181911820118211182211823118241182511826118271182811829118301183111832118331183411835118361183711838118391184011841118421184311844118451184611847118481184911850118511185211853118541185511856118571185811859118601186111862118631186411865118661186711868118691187011871118721187311874118751187611877118781187911880118811188211883118841188511886118871188811889118901189111892118931189411895118961189711898118991190011901119021190311904119051190611907119081190911910119111191211913119141191511916119171191811919119201192111922119231192411925119261192711928119291193011931119321193311934119351193611937119381193911940119411194211943119441194511946119471194811949119501195111952119531195411955119561195711958119591196011961119621196311964119651196611967119681196911970119711197211973119741197511976119771197811979119801198111982119831198411985119861198711988119891199011991119921199311994119951199611997119981199912000120011200212003120041200512006120071200812009120101201112012120131201412015120161201712018120191202012021120221202312024120251202612027120281202912030120311203212033120341203512036120371203812039120401204112042120431204412045120461204712048120491205012051120521205312054120551205612057120581205912060120611206212063120641206512066120671206812069120701207112072120731207412075120761207712078120791208012081120821208312084120851208612087120881208912090120911209212093120941209512096120971209812099121001210112102121031210412105121061210712108121091211012111121121211312114121151211612117121181211912120121211212212123121241212512126121271212812129121301213112132121331213412135121361213712138121391214012141121421214312144121451214612147121481214912150121511215212153121541215512156121571215812159121601216112162121631216412165121661216712168121691217012171121721217312174121751217612177121781217912180121811218212183121841218512186121871218812189121901219112192121931219412195121961219712198121991220012201122021220312204122051220612207122081220912210122111221212213122141221512216122171221812219122201222112222122231222412225122261222712228122291223012231122321223312234122351223612237122381223912240122411224212243122441224512246122471224812249122501225112252122531225412255122561225712258122591226012261122621226312264122651226612267122681226912270122711227212273122741227512276122771227812279122801228112282122831228412285122861228712288122891229012291122921229312294122951229612297122981229912300123011230212303123041230512306123071230812309123101231112312123131231412315123161231712318123191232012321123221232312324123251232612327123281232912330123311233212333123341233512336123371233812339123401234112342123431234412345123461234712348123491235012351123521235312354123551235612357123581235912360123611236212363123641236512366123671236812369123701237112372123731237412375123761237712378123791238012381123821238312384123851238612387123881238912390123911239212393123941239512396123971239812399124001240112402124031240412405124061240712408124091241012411124121241312414124151241612417124181241912420124211242212423124241242512426124271242812429124301243112432124331243412435124361243712438124391244012441124421244312444124451244612447124481244912450124511245212453124541245512456124571245812459124601246112462124631246412465124661246712468124691247012471124721247312474124751247612477124781247912480124811248212483124841248512486124871248812489124901249112492124931249412495124961249712498124991250012501125021250312504125051250612507125081250912510125111251212513125141251512516125171251812519125201252112522125231252412525125261252712528125291253012531125321253312534125351253612537125381253912540125411254212543125441254512546125471254812549125501255112552125531255412555125561255712558125591256012561125621256312564125651256612567125681256912570125711257212573125741257512576125771257812579125801258112582125831258412585125861258712588125891259012591125921259312594125951259612597125981259912600126011260212603126041260512606126071260812609126101261112612126131261412615126161261712618126191262012621126221262312624126251262612627126281262912630126311263212633126341263512636126371263812639126401264112642126431264412645126461264712648126491265012651126521265312654126551265612657126581265912660126611266212663126641266512666126671266812669126701267112672126731267412675126761267712678126791268012681126821268312684126851268612687126881268912690126911269212693126941269512696126971269812699127001270112702127031270412705127061270712708127091271012711127121271312714127151271612717127181271912720127211272212723127241272512726127271272812729127301273112732127331273412735127361273712738127391274012741127421274312744127451274612747127481274912750127511275212753127541275512756127571275812759127601276112762127631276412765127661276712768127691277012771127721277312774127751277612777127781277912780127811278212783127841278512786127871278812789127901279112792127931279412795127961279712798127991280012801128021280312804128051280612807128081280912810128111281212813128141281512816128171281812819128201282112822128231282412825128261282712828128291283012831128321283312834128351283612837128381283912840128411284212843128441284512846128471284812849128501285112852128531285412855128561285712858128591286012861128621286312864128651286612867128681286912870128711287212873128741287512876128771287812879128801288112882128831288412885128861288712888128891289012891128921289312894128951289612897128981289912900129011290212903129041290512906129071290812909129101291112912129131291412915129161291712918129191292012921129221292312924129251292612927129281292912930129311293212933129341293512936129371293812939129401294112942129431294412945129461294712948129491295012951129521295312954129551295612957129581295912960129611296212963129641296512966129671296812969129701297112972129731297412975129761297712978129791298012981129821298312984129851298612987129881298912990129911299212993129941299512996129971299812999130001300113002130031300413005130061300713008130091301013011130121301313014130151301613017130181301913020130211302213023130241302513026130271302813029130301303113032130331303413035130361303713038130391304013041130421304313044130451304613047130481304913050130511305213053130541305513056130571305813059130601306113062130631306413065130661306713068130691307013071130721307313074130751307613077130781307913080130811308213083130841308513086130871308813089130901309113092130931309413095130961309713098130991310013101131021310313104131051310613107131081310913110131111311213113131141311513116131171311813119131201312113122131231312413125131261312713128131291313013131131321313313134131351313613137131381313913140131411314213143131441314513146131471314813149131501315113152131531315413155131561315713158131591316013161131621316313164131651316613167131681316913170131711317213173131741317513176131771317813179131801318113182131831318413185131861318713188131891319013191131921319313194131951319613197131981319913200132011320213203132041320513206132071320813209132101321113212132131321413215132161321713218132191322013221132221322313224132251322613227132281322913230132311323213233132341323513236132371323813239132401324113242132431324413245132461324713248132491325013251132521325313254132551325613257132581325913260132611326213263132641326513266132671326813269132701327113272132731327413275132761327713278132791328013281132821328313284132851328613287132881328913290132911329213293132941329513296132971329813299133001330113302133031330413305133061330713308133091331013311133121331313314133151331613317133181331913320133211332213323133241332513326133271332813329133301333113332133331333413335133361333713338133391334013341133421334313344133451334613347133481334913350133511335213353133541335513356133571335813359133601336113362133631336413365133661336713368133691337013371133721337313374133751337613377133781337913380133811338213383133841338513386133871338813389133901339113392133931339413395133961339713398133991340013401134021340313404134051340613407134081340913410134111341213413134141341513416134171341813419134201342113422134231342413425134261342713428134291343013431134321343313434134351343613437134381343913440134411344213443134441344513446134471344813449134501345113452134531345413455134561345713458134591346013461134621346313464134651346613467134681346913470134711347213473134741347513476134771347813479134801348113482134831348413485134861348713488134891349013491134921349313494134951349613497134981349913500135011350213503135041350513506135071350813509135101351113512135131351413515135161351713518135191352013521135221352313524135251352613527135281352913530135311353213533135341353513536135371353813539135401354113542135431354413545135461354713548135491355013551135521355313554135551355613557135581355913560135611356213563135641356513566135671356813569135701357113572135731357413575135761357713578135791358013581135821358313584135851358613587135881358913590135911359213593135941359513596135971359813599136001360113602136031360413605136061360713608136091361013611136121361313614136151361613617136181361913620136211362213623136241362513626136271362813629136301363113632136331363413635136361363713638136391364013641136421364313644136451364613647136481364913650136511365213653136541365513656136571365813659136601366113662136631366413665136661366713668136691367013671136721367313674136751367613677136781367913680136811368213683136841368513686136871368813689136901369113692136931369413695136961369713698136991370013701137021370313704137051370613707137081370913710137111371213713137141371513716137171371813719137201372113722137231372413725137261372713728137291373013731137321373313734137351373613737137381373913740137411374213743137441374513746137471374813749137501375113752137531375413755137561375713758137591376013761137621376313764137651376613767137681376913770137711377213773137741377513776137771377813779137801378113782137831378413785137861378713788137891379013791137921379313794137951379613797137981379913800138011380213803138041380513806138071380813809138101381113812138131381413815138161381713818138191382013821138221382313824138251382613827138281382913830138311383213833138341383513836138371383813839138401384113842138431384413845138461384713848138491385013851138521385313854138551385613857138581385913860138611386213863138641386513866138671386813869138701387113872138731387413875138761387713878138791388013881138821388313884138851388613887138881388913890138911389213893138941389513896138971389813899139001390113902139031390413905139061390713908139091391013911139121391313914139151391613917139181391913920139211392213923139241392513926139271392813929139301393113932139331393413935139361393713938139391394013941139421394313944139451394613947139481394913950139511395213953139541395513956139571395813959139601396113962139631396413965139661396713968139691397013971139721397313974139751397613977139781397913980139811398213983139841398513986139871398813989139901399113992139931399413995139961399713998139991400014001140021400314004140051400614007140081400914010140111401214013140141401514016140171401814019140201402114022140231402414025140261402714028140291403014031140321403314034140351403614037140381403914040140411404214043140441404514046140471404814049140501405114052140531405414055140561405714058140591406014061140621406314064140651406614067140681406914070140711407214073140741407514076140771407814079140801408114082140831408414085140861408714088140891409014091140921409314094140951409614097140981409914100141011410214103141041410514106141071410814109141101411114112141131411414115141161411714118141191412014121141221412314124141251412614127141281412914130141311413214133141341413514136141371413814139141401414114142141431414414145141461414714148141491415014151141521415314154141551415614157141581415914160141611416214163141641416514166141671416814169141701417114172141731417414175141761417714178141791418014181141821418314184141851418614187141881418914190141911419214193141941419514196141971419814199142001420114202142031420414205142061420714208142091421014211142121421314214142151421614217142181421914220142211422214223142241422514226142271422814229142301423114232142331423414235142361423714238142391424014241142421424314244142451424614247142481424914250142511425214253142541425514256142571425814259142601426114262142631426414265142661426714268142691427014271142721427314274142751427614277142781427914280142811428214283142841428514286142871428814289142901429114292142931429414295142961429714298142991430014301143021430314304143051430614307143081430914310143111431214313143141431514316143171431814319143201432114322143231432414325143261432714328143291433014331143321433314334143351433614337143381433914340143411434214343143441434514346143471434814349143501435114352143531435414355143561435714358143591436014361143621436314364143651436614367143681436914370143711437214373143741437514376143771437814379143801438114382143831438414385143861438714388143891439014391143921439314394143951439614397143981439914400144011440214403144041440514406144071440814409144101441114412144131441414415144161441714418144191442014421144221442314424144251442614427144281442914430144311443214433144341443514436144371443814439144401444114442144431444414445144461444714448144491445014451144521445314454144551445614457144581445914460144611446214463144641446514466144671446814469144701447114472144731447414475144761447714478144791448014481144821448314484144851448614487144881448914490144911449214493144941449514496144971449814499145001450114502145031450414505145061450714508145091451014511145121451314514145151451614517145181451914520145211452214523145241452514526145271452814529145301453114532145331453414535145361453714538145391454014541145421454314544145451454614547145481454914550145511455214553145541455514556145571455814559145601456114562145631456414565145661456714568145691457014571145721457314574145751457614577145781457914580145811458214583145841458514586145871458814589145901459114592145931459414595145961459714598145991460014601146021460314604146051460614607146081460914610146111461214613146141461514616146171461814619146201462114622146231462414625146261462714628146291463014631146321463314634146351463614637146381463914640146411464214643146441464514646146471464814649146501465114652146531465414655146561465714658146591466014661146621466314664146651466614667146681466914670146711467214673146741467514676146771467814679146801468114682146831468414685146861468714688146891469014691146921469314694146951469614697146981469914700147011470214703147041470514706147071470814709147101471114712147131471414715147161471714718147191472014721147221472314724147251472614727147281472914730147311473214733147341473514736147371473814739147401474114742147431474414745147461474714748147491475014751147521475314754147551475614757147581475914760147611476214763147641476514766147671476814769147701477114772147731477414775147761477714778147791478014781147821478314784147851478614787147881478914790147911479214793147941479514796147971479814799148001480114802148031480414805148061480714808148091481014811148121481314814148151481614817148181481914820148211482214823148241482514826148271482814829148301483114832148331483414835148361483714838148391484014841148421484314844148451484614847148481484914850148511485214853148541485514856148571485814859148601486114862148631486414865148661486714868148691487014871148721487314874148751487614877148781487914880148811488214883148841488514886148871488814889148901489114892148931489414895148961489714898148991490014901149021490314904149051490614907149081490914910149111491214913149141491514916149171491814919149201492114922149231492414925149261492714928149291493014931149321493314934149351493614937149381493914940149411494214943149441494514946149471494814949149501495114952149531495414955149561495714958149591496014961149621496314964149651496614967149681496914970149711497214973149741497514976149771497814979149801498114982149831498414985149861498714988149891499014991149921499314994149951499614997149981499915000150011500215003150041500515006150071500815009150101501115012150131501415015150161501715018150191502015021150221502315024150251502615027150281502915030150311503215033150341503515036150371503815039150401504115042150431504415045150461504715048150491505015051150521505315054150551505615057150581505915060150611506215063150641506515066150671506815069150701507115072150731507415075150761507715078150791508015081150821508315084150851508615087150881508915090150911509215093150941509515096150971509815099151001510115102151031510415105151061510715108151091511015111151121511315114151151511615117151181511915120151211512215123151241512515126151271512815129151301513115132151331513415135151361513715138151391514015141151421514315144151451514615147151481514915150151511515215153151541515515156151571515815159151601516115162151631516415165151661516715168151691517015171151721517315174151751517615177151781517915180151811518215183151841518515186151871518815189151901519115192151931519415195151961519715198151991520015201152021520315204152051520615207152081520915210152111521215213152141521515216152171521815219152201522115222152231522415225152261522715228152291523015231152321523315234152351523615237152381523915240152411524215243152441524515246152471524815249152501525115252152531525415255152561525715258152591526015261152621526315264152651526615267152681526915270152711527215273152741527515276152771527815279152801528115282152831528415285152861528715288152891529015291152921529315294152951529615297152981529915300153011530215303153041530515306153071530815309153101531115312153131531415315153161531715318153191532015321153221532315324153251532615327153281532915330153311533215333153341533515336153371533815339153401534115342153431534415345153461534715348153491535015351153521535315354153551535615357153581535915360153611536215363153641536515366153671536815369153701537115372153731537415375153761537715378153791538015381153821538315384153851538615387153881538915390153911539215393153941539515396153971539815399154001540115402154031540415405154061540715408154091541015411154121541315414154151541615417154181541915420154211542215423154241542515426154271542815429154301543115432154331543415435154361543715438154391544015441154421544315444154451544615447154481544915450154511545215453154541545515456154571545815459154601546115462154631546415465154661546715468154691547015471154721547315474154751547615477154781547915480154811548215483154841548515486154871548815489154901549115492154931549415495154961549715498154991550015501155021550315504155051550615507155081550915510155111551215513155141551515516155171551815519155201552115522155231552415525155261552715528155291553015531155321553315534155351553615537155381553915540155411554215543155441554515546155471554815549155501555115552155531555415555155561555715558155591556015561155621556315564155651556615567155681556915570155711557215573155741557515576155771557815579155801558115582155831558415585155861558715588155891559015591155921559315594155951559615597155981559915600156011560215603156041560515606156071560815609156101561115612156131561415615156161561715618156191562015621156221562315624156251562615627156281562915630156311563215633156341563515636156371563815639156401564115642156431564415645156461564715648156491565015651156521565315654156551565615657156581565915660156611566215663156641566515666156671566815669156701567115672156731567415675156761567715678156791568015681156821568315684156851568615687156881568915690156911569215693156941569515696156971569815699157001570115702157031570415705157061570715708157091571015711157121571315714157151571615717157181571915720157211572215723157241572515726157271572815729157301573115732157331573415735157361573715738157391574015741157421574315744157451574615747157481574915750157511575215753157541575515756157571575815759157601576115762157631576415765157661576715768157691577015771157721577315774157751577615777157781577915780157811578215783157841578515786157871578815789157901579115792157931579415795157961579715798157991580015801158021580315804158051580615807158081580915810158111581215813158141581515816158171581815819158201582115822158231582415825158261582715828158291583015831158321583315834158351583615837158381583915840158411584215843158441584515846158471584815849158501585115852158531585415855158561585715858158591586015861158621586315864158651586615867158681586915870158711587215873158741587515876158771587815879158801588115882158831588415885158861588715888158891589015891158921589315894158951589615897158981589915900159011590215903159041590515906159071590815909159101591115912159131591415915159161591715918159191592015921159221592315924159251592615927159281592915930159311593215933159341593515936159371593815939159401594115942159431594415945159461594715948159491595015951159521595315954159551595615957159581595915960159611596215963159641596515966159671596815969159701597115972159731597415975159761597715978159791598015981159821598315984159851598615987159881598915990159911599215993159941599515996159971599815999160001600116002160031600416005160061600716008160091601016011160121601316014160151601616017160181601916020160211602216023160241602516026160271602816029160301603116032160331603416035160361603716038160391604016041160421604316044160451604616047160481604916050160511605216053160541605516056160571605816059160601606116062160631606416065160661606716068160691607016071160721607316074160751607616077160781607916080160811608216083160841608516086160871608816089160901609116092160931609416095160961609716098160991610016101161021610316104161051610616107161081610916110161111611216113161141611516116161171611816119161201612116122161231612416125161261612716128161291613016131161321613316134161351613616137161381613916140161411614216143161441614516146161471614816149161501615116152161531615416155161561615716158161591616016161161621616316164161651616616167161681616916170161711617216173161741617516176161771617816179161801618116182161831618416185161861618716188161891619016191161921619316194161951619616197161981619916200162011620216203162041620516206162071620816209162101621116212162131621416215162161621716218162191622016221162221622316224162251622616227162281622916230162311623216233162341623516236162371623816239162401624116242162431624416245162461624716248162491625016251162521625316254162551625616257162581625916260162611626216263162641626516266162671626816269162701627116272162731627416275162761627716278162791628016281162821628316284162851628616287162881628916290162911629216293162941629516296162971629816299163001630116302163031630416305163061630716308163091631016311163121631316314163151631616317163181631916320163211632216323163241632516326163271632816329163301633116332163331633416335163361633716338163391634016341163421634316344163451634616347163481634916350163511635216353163541635516356163571635816359163601636116362163631636416365163661636716368163691637016371163721637316374163751637616377163781637916380163811638216383163841638516386163871638816389163901639116392163931639416395163961639716398163991640016401164021640316404164051640616407164081640916410164111641216413164141641516416164171641816419164201642116422164231642416425164261642716428164291643016431164321643316434164351643616437164381643916440164411644216443164441644516446164471644816449164501645116452164531645416455164561645716458164591646016461164621646316464164651646616467164681646916470164711647216473164741647516476164771647816479164801648116482164831648416485164861648716488164891649016491164921649316494164951649616497164981649916500165011650216503165041650516506165071650816509165101651116512165131651416515165161651716518165191652016521165221652316524165251652616527165281652916530165311653216533165341653516536165371653816539165401654116542165431654416545165461654716548165491655016551165521655316554165551655616557165581655916560165611656216563165641656516566165671656816569165701657116572165731657416575165761657716578165791658016581165821658316584165851658616587165881658916590165911659216593165941659516596165971659816599166001660116602166031660416605166061660716608166091661016611166121661316614166151661616617166181661916620166211662216623166241662516626166271662816629166301663116632166331663416635166361663716638166391664016641166421664316644166451664616647166481664916650166511665216653166541665516656166571665816659166601666116662166631666416665166661666716668166691667016671166721667316674166751667616677166781667916680166811668216683166841668516686166871668816689166901669116692166931669416695166961669716698166991670016701167021670316704167051670616707167081670916710167111671216713167141671516716167171671816719167201672116722167231672416725167261672716728167291673016731167321673316734167351673616737167381673916740167411674216743167441674516746167471674816749167501675116752167531675416755167561675716758167591676016761167621676316764167651676616767167681676916770167711677216773167741677516776167771677816779167801678116782167831678416785167861678716788167891679016791167921679316794167951679616797167981679916800168011680216803168041680516806168071680816809168101681116812168131681416815168161681716818168191682016821168221682316824168251682616827168281682916830168311683216833168341683516836168371683816839168401684116842168431684416845168461684716848168491685016851168521685316854168551685616857168581685916860168611686216863168641686516866168671686816869168701687116872168731687416875168761687716878168791688016881168821688316884168851688616887168881688916890168911689216893168941689516896168971689816899169001690116902169031690416905169061690716908169091691016911169121691316914169151691616917169181691916920169211692216923169241692516926169271692816929169301693116932169331693416935169361693716938169391694016941169421694316944169451694616947169481694916950169511695216953169541695516956169571695816959169601696116962169631696416965169661696716968169691697016971169721697316974169751697616977169781697916980169811698216983169841698516986169871698816989169901699116992169931699416995169961699716998169991700017001170021700317004170051700617007170081700917010170111701217013170141701517016170171701817019170201702117022170231702417025170261702717028170291703017031170321703317034170351703617037170381703917040170411704217043170441704517046170471704817049170501705117052170531705417055170561705717058170591706017061170621706317064170651706617067170681706917070170711707217073170741707517076170771707817079170801708117082170831708417085170861708717088170891709017091170921709317094170951709617097170981709917100171011710217103171041710517106171071710817109171101711117112171131711417115171161711717118171191712017121171221712317124171251712617127171281712917130171311713217133171341713517136171371713817139171401714117142171431714417145171461714717148171491715017151171521715317154171551715617157171581715917160171611716217163171641716517166171671716817169171701717117172171731717417175171761717717178171791718017181171821718317184171851718617187171881718917190171911719217193171941719517196171971719817199172001720117202172031720417205172061720717208172091721017211172121721317214172151721617217172181721917220172211722217223172241722517226172271722817229172301723117232172331723417235172361723717238172391724017241172421724317244172451724617247172481724917250172511725217253172541725517256172571725817259172601726117262172631726417265172661726717268172691727017271172721727317274172751727617277172781727917280172811728217283172841728517286172871728817289172901729117292172931729417295172961729717298172991730017301173021730317304173051730617307173081730917310173111731217313173141731517316173171731817319173201732117322173231732417325173261732717328173291733017331173321733317334173351733617337173381733917340173411734217343173441734517346173471734817349173501735117352173531735417355173561735717358173591736017361173621736317364173651736617367173681736917370173711737217373173741737517376173771737817379173801738117382173831738417385173861738717388173891739017391173921739317394173951739617397173981739917400174011740217403174041740517406174071740817409174101741117412174131741417415174161741717418174191742017421174221742317424174251742617427174281742917430174311743217433174341743517436174371743817439174401744117442174431744417445174461744717448174491745017451174521745317454174551745617457174581745917460174611746217463174641746517466174671746817469174701747117472174731747417475174761747717478174791748017481174821748317484174851748617487174881748917490174911749217493174941749517496174971749817499175001750117502175031750417505175061750717508175091751017511175121751317514175151751617517175181751917520175211752217523175241752517526175271752817529175301753117532175331753417535175361753717538175391754017541175421754317544175451754617547175481754917550175511755217553175541755517556175571755817559175601756117562175631756417565175661756717568175691757017571175721757317574175751757617577175781757917580175811758217583175841758517586175871758817589175901759117592175931759417595175961759717598175991760017601176021760317604176051760617607176081760917610176111761217613176141761517616176171761817619176201762117622176231762417625176261762717628176291763017631176321763317634176351763617637176381763917640176411764217643176441764517646176471764817649176501765117652176531765417655176561765717658176591766017661176621766317664176651766617667176681766917670176711767217673176741767517676176771767817679176801768117682176831768417685176861768717688176891769017691176921769317694176951769617697176981769917700177011770217703177041770517706177071770817709177101771117712177131771417715177161771717718177191772017721177221772317724177251772617727177281772917730177311773217733177341773517736177371773817739177401774117742177431774417745177461774717748177491775017751177521775317754177551775617757177581775917760177611776217763177641776517766177671776817769177701777117772177731777417775177761777717778177791778017781177821778317784177851778617787177881778917790177911779217793177941779517796177971779817799178001780117802178031780417805178061780717808178091781017811178121781317814178151781617817178181781917820178211782217823178241782517826178271782817829178301783117832178331783417835178361783717838178391784017841178421784317844178451784617847178481784917850178511785217853178541785517856178571785817859178601786117862178631786417865178661786717868178691787017871178721787317874178751787617877178781787917880178811788217883178841788517886178871788817889178901789117892178931789417895178961789717898178991790017901179021790317904179051790617907179081790917910179111791217913179141791517916179171791817919179201792117922179231792417925179261792717928179291793017931179321793317934179351793617937179381793917940179411794217943179441794517946179471794817949179501795117952179531795417955179561795717958179591796017961179621796317964179651796617967179681796917970179711797217973179741797517976179771797817979179801798117982179831798417985179861798717988179891799017991179921799317994179951799617997179981799918000180011800218003180041800518006180071800818009180101801118012180131801418015180161801718018180191802018021180221802318024180251802618027180281802918030180311803218033180341803518036180371803818039180401804118042180431804418045180461804718048180491805018051180521805318054180551805618057180581805918060180611806218063180641806518066180671806818069180701807118072180731807418075180761807718078180791808018081180821808318084180851808618087180881808918090180911809218093180941809518096180971809818099181001810118102181031810418105181061810718108181091811018111181121811318114181151811618117181181811918120181211812218123181241812518126181271812818129181301813118132181331813418135181361813718138181391814018141181421814318144181451814618147181481814918150181511815218153181541815518156181571815818159181601816118162181631816418165181661816718168181691817018171181721817318174181751817618177181781817918180181811818218183181841818518186181871818818189181901819118192181931819418195181961819718198181991820018201182021820318204182051820618207182081820918210182111821218213182141821518216182171821818219182201822118222182231822418225182261822718228182291823018231182321823318234182351823618237182381823918240182411824218243182441824518246182471824818249182501825118252182531825418255182561825718258182591826018261182621826318264182651826618267182681826918270182711827218273182741827518276182771827818279182801828118282182831828418285182861828718288182891829018291182921829318294182951829618297182981829918300183011830218303183041830518306183071830818309183101831118312183131831418315183161831718318183191832018321183221832318324183251832618327183281832918330183311833218333183341833518336183371833818339183401834118342183431834418345183461834718348183491835018351183521835318354183551835618357183581835918360183611836218363183641836518366183671836818369183701837118372183731837418375183761837718378183791838018381183821838318384183851838618387183881838918390183911839218393183941839518396183971839818399184001840118402184031840418405184061840718408184091841018411184121841318414184151841618417184181841918420184211842218423184241842518426184271842818429184301843118432184331843418435184361843718438184391844018441184421844318444184451844618447184481844918450184511845218453184541845518456184571845818459184601846118462184631846418465184661846718468184691847018471184721847318474184751847618477184781847918480184811848218483184841848518486184871848818489184901849118492184931849418495184961849718498184991850018501185021850318504185051850618507185081850918510185111851218513185141851518516185171851818519185201852118522185231852418525185261852718528185291853018531185321853318534185351853618537185381853918540185411854218543185441854518546185471854818549185501855118552185531855418555185561855718558185591856018561185621856318564185651856618567185681856918570185711857218573185741857518576185771857818579185801858118582185831858418585185861858718588185891859018591185921859318594185951859618597185981859918600186011860218603186041860518606186071860818609186101861118612186131861418615186161861718618186191862018621186221862318624186251862618627186281862918630186311863218633186341863518636186371863818639186401864118642186431864418645186461864718648186491865018651186521865318654186551865618657186581865918660186611866218663186641866518666186671866818669186701867118672186731867418675186761867718678186791868018681186821868318684186851868618687186881868918690186911869218693186941869518696186971869818699187001870118702187031870418705187061870718708187091871018711187121871318714187151871618717187181871918720187211872218723187241872518726187271872818729187301873118732187331873418735187361873718738187391874018741187421874318744187451874618747187481874918750187511875218753187541875518756187571875818759187601876118762187631876418765187661876718768187691877018771187721877318774187751877618777187781877918780187811878218783187841878518786187871878818789187901879118792187931879418795187961879718798187991880018801188021880318804188051880618807188081880918810188111881218813188141881518816188171881818819188201882118822188231882418825188261882718828188291883018831188321883318834188351883618837188381883918840188411884218843188441884518846188471884818849188501885118852188531885418855188561885718858188591886018861188621886318864188651886618867188681886918870188711887218873188741887518876188771887818879188801888118882188831888418885188861888718888188891889018891188921889318894188951889618897188981889918900189011890218903189041890518906189071890818909189101891118912189131891418915189161891718918189191892018921189221892318924189251892618927189281892918930189311893218933189341893518936189371893818939189401894118942189431894418945189461894718948189491895018951189521895318954189551895618957189581895918960189611896218963189641896518966189671896818969189701897118972189731897418975189761897718978189791898018981189821898318984189851898618987189881898918990189911899218993189941899518996189971899818999190001900119002190031900419005190061900719008190091901019011190121901319014190151901619017190181901919020190211902219023190241902519026190271902819029190301903119032190331903419035190361903719038190391904019041190421904319044190451904619047190481904919050190511905219053190541905519056190571905819059190601906119062190631906419065190661906719068190691907019071190721907319074190751907619077190781907919080190811908219083190841908519086190871908819089190901909119092190931909419095190961909719098190991910019101191021910319104191051910619107191081910919110191111911219113191141911519116191171911819119191201912119122191231912419125191261912719128191291913019131191321913319134191351913619137191381913919140191411914219143191441914519146191471914819149191501915119152191531915419155191561915719158191591916019161191621916319164191651916619167191681916919170191711917219173191741917519176191771917819179191801918119182191831918419185191861918719188191891919019191191921919319194191951919619197191981919919200192011920219203192041920519206192071920819209192101921119212192131921419215192161921719218192191922019221192221922319224192251922619227192281922919230192311923219233192341923519236192371923819239192401924119242192431924419245192461924719248192491925019251192521925319254192551925619257192581925919260192611926219263192641926519266192671926819269192701927119272192731927419275192761927719278192791928019281192821928319284192851928619287192881928919290192911929219293192941929519296192971929819299193001930119302193031930419305193061930719308193091931019311193121931319314193151931619317193181931919320193211932219323193241932519326193271932819329193301933119332193331933419335193361933719338193391934019341193421934319344193451934619347193481934919350193511935219353193541935519356193571935819359193601936119362193631936419365193661936719368193691937019371193721937319374193751937619377193781937919380193811938219383193841938519386193871938819389193901939119392193931939419395193961939719398193991940019401194021940319404194051940619407194081940919410194111941219413194141941519416194171941819419194201942119422194231942419425194261942719428194291943019431194321943319434194351943619437194381943919440194411944219443194441944519446194471944819449194501945119452194531945419455194561945719458194591946019461194621946319464194651946619467194681946919470194711947219473194741947519476194771947819479194801948119482194831948419485194861948719488194891949019491194921949319494194951949619497194981949919500195011950219503195041950519506195071950819509195101951119512195131951419515195161951719518195191952019521195221952319524195251952619527195281952919530195311953219533195341953519536195371953819539195401954119542195431954419545195461954719548195491955019551195521955319554195551955619557195581955919560195611956219563195641956519566195671956819569195701957119572195731957419575195761957719578195791958019581195821958319584195851958619587195881958919590195911959219593195941959519596195971959819599196001960119602196031960419605196061960719608196091961019611196121961319614196151961619617196181961919620196211962219623196241962519626196271962819629196301963119632196331963419635196361963719638196391964019641196421964319644196451964619647196481964919650196511965219653196541965519656196571965819659196601966119662196631966419665196661966719668196691967019671196721967319674196751967619677196781967919680196811968219683196841968519686196871968819689196901969119692196931969419695196961969719698196991970019701197021970319704197051970619707197081970919710197111971219713197141971519716197171971819719197201972119722197231972419725197261972719728197291973019731197321973319734197351973619737197381973919740197411974219743197441974519746197471974819749197501975119752197531975419755197561975719758197591976019761197621976319764197651976619767197681976919770197711977219773197741977519776197771977819779197801978119782197831978419785197861978719788197891979019791197921979319794197951979619797197981979919800198011980219803198041980519806198071980819809198101981119812198131981419815198161981719818198191982019821198221982319824198251982619827198281982919830198311983219833198341983519836198371983819839198401984119842198431984419845198461984719848198491985019851198521985319854198551985619857198581985919860198611986219863198641986519866198671986819869198701987119872198731987419875198761987719878198791988019881198821988319884198851988619887198881988919890198911989219893198941989519896198971989819899199001990119902199031990419905199061990719908199091991019911199121991319914199151991619917199181991919920199211992219923199241992519926199271992819929199301993119932199331993419935199361993719938199391994019941199421994319944199451994619947199481994919950199511995219953199541995519956199571995819959199601996119962199631996419965199661996719968199691997019971199721997319974199751997619977199781997919980199811998219983199841998519986199871998819989199901999119992199931999419995199961999719998199992000020001200022000320004200052000620007200082000920010200112001220013200142001520016200172001820019200202002120022200232002420025200262002720028200292003020031200322003320034200352003620037200382003920040200412004220043200442004520046200472004820049200502005120052200532005420055200562005720058200592006020061200622006320064200652006620067200682006920070200712007220073200742007520076200772007820079200802008120082200832008420085200862008720088200892009020091200922009320094200952009620097200982009920100201012010220103201042010520106201072010820109201102011120112201132011420115201162011720118201192012020121201222012320124201252012620127201282012920130201312013220133201342013520136201372013820139201402014120142201432014420145201462014720148201492015020151201522015320154201552015620157201582015920160201612016220163201642016520166201672016820169201702017120172201732017420175201762017720178201792018020181201822018320184201852018620187201882018920190201912019220193201942019520196201972019820199202002020120202202032020420205202062020720208202092021020211202122021320214202152021620217202182021920220202212022220223202242022520226202272022820229202302023120232202332023420235202362023720238202392024020241202422024320244202452024620247202482024920250202512025220253202542025520256202572025820259202602026120262202632026420265202662026720268202692027020271202722027320274202752027620277202782027920280202812028220283202842028520286202872028820289202902029120292202932029420295202962029720298202992030020301203022030320304203052030620307203082030920310203112031220313203142031520316203172031820319203202032120322203232032420325203262032720328203292033020331203322033320334203352033620337203382033920340203412034220343203442034520346203472034820349203502035120352203532035420355203562035720358203592036020361203622036320364203652036620367203682036920370203712037220373203742037520376203772037820379203802038120382203832038420385203862038720388203892039020391203922039320394203952039620397203982039920400204012040220403204042040520406204072040820409204102041120412204132041420415204162041720418204192042020421204222042320424204252042620427204282042920430204312043220433204342043520436204372043820439204402044120442204432044420445204462044720448204492045020451204522045320454204552045620457204582045920460204612046220463204642046520466204672046820469204702047120472204732047420475204762047720478204792048020481204822048320484204852048620487204882048920490204912049220493204942049520496204972049820499205002050120502205032050420505205062050720508205092051020511205122051320514205152051620517205182051920520205212052220523205242052520526205272052820529205302053120532205332053420535205362053720538205392054020541205422054320544205452054620547205482054920550205512055220553205542055520556205572055820559205602056120562205632056420565205662056720568205692057020571205722057320574205752057620577205782057920580205812058220583205842058520586205872058820589205902059120592205932059420595205962059720598205992060020601206022060320604206052060620607206082060920610206112061220613206142061520616206172061820619206202062120622206232062420625206262062720628206292063020631206322063320634206352063620637206382063920640206412064220643206442064520646206472064820649206502065120652206532065420655206562065720658206592066020661206622066320664206652066620667206682066920670206712067220673206742067520676206772067820679206802068120682206832068420685206862068720688206892069020691206922069320694206952069620697206982069920700207012070220703207042070520706207072070820709207102071120712207132071420715207162071720718207192072020721207222072320724207252072620727207282072920730207312073220733207342073520736207372073820739207402074120742207432074420745207462074720748207492075020751207522075320754207552075620757207582075920760207612076220763207642076520766207672076820769207702077120772207732077420775207762077720778207792078020781207822078320784207852078620787207882078920790207912079220793207942079520796207972079820799208002080120802208032080420805208062080720808208092081020811208122081320814208152081620817208182081920820208212082220823208242082520826208272082820829208302083120832208332083420835208362083720838208392084020841208422084320844208452084620847208482084920850208512085220853208542085520856208572085820859208602086120862208632086420865208662086720868208692087020871208722087320874208752087620877208782087920880208812088220883208842088520886208872088820889208902089120892208932089420895208962089720898208992090020901209022090320904209052090620907209082090920910209112091220913209142091520916209172091820919209202092120922209232092420925209262092720928209292093020931209322093320934209352093620937209382093920940209412094220943209442094520946209472094820949209502095120952209532095420955209562095720958209592096020961209622096320964209652096620967209682096920970209712097220973209742097520976209772097820979209802098120982209832098420985209862098720988209892099020991209922099320994209952099620997209982099921000210012100221003210042100521006210072100821009210102101121012210132101421015210162101721018210192102021021210222102321024210252102621027210282102921030210312103221033210342103521036210372103821039210402104121042210432104421045210462104721048210492105021051210522105321054210552105621057210582105921060210612106221063210642106521066210672106821069210702107121072210732107421075210762107721078210792108021081210822108321084210852108621087210882108921090210912109221093210942109521096210972109821099211002110121102211032110421105211062110721108211092111021111211122111321114211152111621117211182111921120211212112221123211242112521126211272112821129211302113121132211332113421135211362113721138211392114021141211422114321144211452114621147211482114921150211512115221153211542115521156211572115821159211602116121162211632116421165211662116721168211692117021171211722117321174211752117621177211782117921180211812118221183211842118521186211872118821189211902119121192211932119421195211962119721198211992120021201212022120321204212052120621207212082120921210212112121221213212142121521216212172121821219212202122121222212232122421225212262122721228212292123021231212322123321234212352123621237212382123921240212412124221243212442124521246212472124821249212502125121252212532125421255212562125721258212592126021261212622126321264212652126621267212682126921270212712127221273212742127521276212772127821279212802128121282212832128421285212862128721288212892129021291212922129321294212952129621297212982129921300213012130221303213042130521306213072130821309213102131121312213132131421315213162131721318213192132021321213222132321324213252132621327213282132921330213312133221333213342133521336213372133821339213402134121342213432134421345213462134721348213492135021351213522135321354213552135621357213582135921360213612136221363213642136521366213672136821369213702137121372213732137421375213762137721378213792138021381213822138321384213852138621387213882138921390213912139221393213942139521396213972139821399214002140121402214032140421405214062140721408214092141021411214122141321414214152141621417214182141921420214212142221423214242142521426214272142821429214302143121432214332143421435214362143721438214392144021441214422144321444214452144621447214482144921450214512145221453214542145521456214572145821459214602146121462214632146421465214662146721468214692147021471214722147321474214752147621477214782147921480214812148221483214842148521486214872148821489214902149121492214932149421495214962149721498214992150021501215022150321504215052150621507215082150921510215112151221513215142151521516215172151821519215202152121522215232152421525215262152721528215292153021531215322153321534215352153621537215382153921540215412154221543215442154521546215472154821549215502155121552215532155421555215562155721558215592156021561215622156321564215652156621567215682156921570215712157221573215742157521576215772157821579215802158121582215832158421585215862158721588215892159021591215922159321594215952159621597215982159921600216012160221603216042160521606216072160821609216102161121612216132161421615216162161721618216192162021621216222162321624216252162621627216282162921630216312163221633216342163521636216372163821639216402164121642216432164421645216462164721648216492165021651216522165321654216552165621657216582165921660216612166221663216642166521666216672166821669216702167121672216732167421675216762167721678216792168021681216822168321684216852168621687216882168921690216912169221693216942169521696216972169821699217002170121702217032170421705217062170721708217092171021711217122171321714217152171621717217182171921720217212172221723217242172521726217272172821729217302173121732217332173421735217362173721738217392174021741217422174321744217452174621747217482174921750217512175221753217542175521756217572175821759217602176121762217632176421765217662176721768217692177021771217722177321774217752177621777217782177921780217812178221783217842178521786217872178821789217902179121792217932179421795217962179721798217992180021801218022180321804218052180621807218082180921810218112181221813218142181521816218172181821819218202182121822218232182421825218262182721828218292183021831218322183321834218352183621837218382183921840218412184221843218442184521846218472184821849218502185121852218532185421855218562185721858218592186021861218622186321864218652186621867218682186921870218712187221873218742187521876218772187821879218802188121882218832188421885218862188721888218892189021891218922189321894218952189621897218982189921900219012190221903219042190521906219072190821909219102191121912219132191421915219162191721918219192192021921219222192321924219252192621927219282192921930219312193221933219342193521936219372193821939219402194121942219432194421945219462194721948219492195021951219522195321954219552195621957219582195921960219612196221963219642196521966219672196821969219702197121972219732197421975219762197721978219792198021981219822198321984219852198621987219882198921990219912199221993219942199521996219972199821999220002200122002220032200422005220062200722008220092201022011220122201322014220152201622017220182201922020220212202222023220242202522026220272202822029220302203122032220332203422035220362203722038220392204022041220422204322044220452204622047220482204922050220512205222053220542205522056220572205822059220602206122062220632206422065220662206722068220692207022071220722207322074220752207622077220782207922080220812208222083220842208522086220872208822089220902209122092220932209422095220962209722098220992210022101221022210322104221052210622107221082210922110221112211222113221142211522116221172211822119221202212122122221232212422125221262212722128221292213022131221322213322134221352213622137221382213922140221412214222143221442214522146221472214822149221502215122152221532215422155221562215722158221592216022161221622216322164221652216622167221682216922170221712217222173221742217522176221772217822179221802218122182221832218422185221862218722188221892219022191221922219322194221952219622197221982219922200222012220222203222042220522206222072220822209222102221122212222132221422215222162221722218222192222022221222222222322224222252222622227222282222922230222312223222233222342223522236222372223822239222402224122242222432224422245222462224722248222492225022251
  1. // Code generated for linux/amd64 by 'generator --prefix-enumerator=_ --prefix-external=x_ --prefix-field=F --prefix-macro=m_ --prefix-static-internal=_ --prefix-static-none=_ --prefix-tagged-enum=_ --prefix-tagged-struct=T --prefix-tagged-union=T --prefix-typename=T --prefix-undefined=_ -extended-errors -ignore-unsupported-alignment -I /home/jnml/src/modernc.org/builder/.exclude/modernc.org/libXau/include/linux/amd64 -I /home/jnml/src/modernc.org/builder/.exclude/modernc.org/libXdmcp/include/linux/amd64 -lXau -lXdmcp -o libxcb.go --package-name libxcb src/.libs/libxcb.a', DO NOT EDIT.
  2. //go:build linux && amd64
  3. package libxcb
  4. import (
  5. "reflect"
  6. "unsafe"
  7. "modernc.org/libXau"
  8. "modernc.org/libXdmcp"
  9. "modernc.org/libc"
  10. )
  11. var _ reflect.Type
  12. var _ unsafe.Pointer
  13. const m_AF_ALG = "PF_ALG"
  14. const m_AF_APPLETALK = "PF_APPLETALK"
  15. const m_AF_ASH = "PF_ASH"
  16. const m_AF_ATMPVC = "PF_ATMPVC"
  17. const m_AF_ATMSVC = "PF_ATMSVC"
  18. const m_AF_AX25 = "PF_AX25"
  19. const m_AF_BLUETOOTH = "PF_BLUETOOTH"
  20. const m_AF_BRIDGE = "PF_BRIDGE"
  21. const m_AF_CAIF = "PF_CAIF"
  22. const m_AF_CAN = "PF_CAN"
  23. const m_AF_DECnet = "PF_DECnet"
  24. const m_AF_ECONET = "PF_ECONET"
  25. const m_AF_FILE = "AF_LOCAL"
  26. const m_AF_IB = "PF_IB"
  27. const m_AF_IEEE802154 = "PF_IEEE802154"
  28. const m_AF_INET = "PF_INET"
  29. const m_AF_INET6 = "PF_INET6"
  30. const m_AF_IPX = "PF_IPX"
  31. const m_AF_IRDA = "PF_IRDA"
  32. const m_AF_ISDN = "PF_ISDN"
  33. const m_AF_IUCV = "PF_IUCV"
  34. const m_AF_KCM = "PF_KCM"
  35. const m_AF_KEY = "PF_KEY"
  36. const m_AF_LLC = "PF_LLC"
  37. const m_AF_LOCAL = "PF_LOCAL"
  38. const m_AF_MAX = "PF_MAX"
  39. const m_AF_MPLS = "PF_MPLS"
  40. const m_AF_NETBEUI = "PF_NETBEUI"
  41. const m_AF_NETLINK = "PF_NETLINK"
  42. const m_AF_NETROM = "PF_NETROM"
  43. const m_AF_NFC = "PF_NFC"
  44. const m_AF_PACKET = "PF_PACKET"
  45. const m_AF_PHONET = "PF_PHONET"
  46. const m_AF_PPPOX = "PF_PPPOX"
  47. const m_AF_QIPCRTR = "PF_QIPCRTR"
  48. const m_AF_RDS = "PF_RDS"
  49. const m_AF_ROSE = "PF_ROSE"
  50. const m_AF_ROUTE = "PF_ROUTE"
  51. const m_AF_RXRPC = "PF_RXRPC"
  52. const m_AF_SECURITY = "PF_SECURITY"
  53. const m_AF_SMC = "PF_SMC"
  54. const m_AF_SNA = "PF_SNA"
  55. const m_AF_TIPC = "PF_TIPC"
  56. const m_AF_UNIX = "AF_LOCAL"
  57. const m_AF_UNSPEC = "PF_UNSPEC"
  58. const m_AF_VSOCK = "PF_VSOCK"
  59. const m_AF_WANPIPE = "PF_WANPIPE"
  60. const m_AF_X25 = "PF_X25"
  61. const m_AF_XDP = "PF_XDP"
  62. const m_ARG_MAX = 131072
  63. const m_AT_EACCESS = 0x200
  64. const m_AT_EMPTY_PATH = 0x1000
  65. const m_AT_NO_AUTOMOUNT = 0x800
  66. const m_AT_RECURSIVE = 0x8000
  67. const m_AT_REMOVEDIR = 0x200
  68. const m_AT_STATX_DONT_SYNC = 0x4000
  69. const m_AT_STATX_FORCE_SYNC = 0x2000
  70. const m_AT_STATX_SYNC_AS_STAT = 0x0000
  71. const m_AT_STATX_SYNC_TYPE = 0x6000
  72. const m_AT_SYMLINK_FOLLOW = 0x400
  73. const m_AT_SYMLINK_NOFOLLOW = 0x100
  74. const m_BC_BASE_MAX = 99
  75. const m_BC_DIM_MAX = 2048
  76. const m_BC_SCALE_MAX = 99
  77. const m_BC_STRING_MAX = 1000
  78. const m_BIG_ENDIAN = "__BIG_ENDIAN"
  79. const m_BUFSIZ = 1024
  80. const m_BYTE_ORDER = "__BYTE_ORDER"
  81. const m_CHARCLASS_NAME_MAX = 14
  82. const m_CHAR_BIT = 8
  83. const m_CHAR_MAX = 255
  84. const m_CHAR_MIN = 0
  85. const m_CLOCKS_PER_SEC = 1000000
  86. const m_CLOCK_BOOTTIME = 7
  87. const m_CLOCK_BOOTTIME_ALARM = 9
  88. const m_CLOCK_MONOTONIC = 1
  89. const m_CLOCK_MONOTONIC_COARSE = 6
  90. const m_CLOCK_MONOTONIC_RAW = 4
  91. const m_CLOCK_PROCESS_CPUTIME_ID = 2
  92. const m_CLOCK_REALTIME = 0
  93. const m_CLOCK_REALTIME_ALARM = 8
  94. const m_CLOCK_REALTIME_COARSE = 5
  95. const m_CLOCK_SGI_CYCLE = 10
  96. const m_CLOCK_TAI = 11
  97. const m_CLOCK_THREAD_CPUTIME_ID = 3
  98. const m_CLONE_CHILD_CLEARTID = 0x00200000
  99. const m_CLONE_CHILD_SETTID = 0x01000000
  100. const m_CLONE_DETACHED = 0x00400000
  101. const m_CLONE_FILES = 0x00000400
  102. const m_CLONE_FS = 0x00000200
  103. const m_CLONE_IO = 0x80000000
  104. const m_CLONE_NEWCGROUP = 0x02000000
  105. const m_CLONE_NEWIPC = 0x08000000
  106. const m_CLONE_NEWNET = 0x40000000
  107. const m_CLONE_NEWNS = 0x00020000
  108. const m_CLONE_NEWPID = 0x20000000
  109. const m_CLONE_NEWTIME = 0x00000080
  110. const m_CLONE_NEWUSER = 0x10000000
  111. const m_CLONE_NEWUTS = 0x04000000
  112. const m_CLONE_PARENT = 0x00008000
  113. const m_CLONE_PARENT_SETTID = 0x00100000
  114. const m_CLONE_PIDFD = 0x00001000
  115. const m_CLONE_PTRACE = 0x00002000
  116. const m_CLONE_SETTLS = 0x00080000
  117. const m_CLONE_SIGHAND = 0x00000800
  118. const m_CLONE_SYSVSEM = 0x00040000
  119. const m_CLONE_THREAD = 0x00010000
  120. const m_CLONE_UNTRACED = 0x00800000
  121. const m_CLONE_VFORK = 0x00004000
  122. const m_CLONE_VM = 0x00000100
  123. const m_COLL_WEIGHTS_MAX = 2
  124. const m_CPU_SETSIZE = 1024
  125. const m_CSIGNAL = 0x000000ff
  126. const m_DELAYTIMER_MAX = 0x7fffffff
  127. const m_DN_ACCESS = 0x00000001
  128. const m_DN_ATTRIB = 0x00000020
  129. const m_DN_CREATE = 0x00000004
  130. const m_DN_DELETE = 0x00000008
  131. const m_DN_MODIFY = 0x00000002
  132. const m_DN_MULTISHOT = 0x80000000
  133. const m_DN_RENAME = 0x00000010
  134. const m_E2BIG = 7
  135. const m_EACCES = 13
  136. const m_EADDRINUSE = 98
  137. const m_EADDRNOTAVAIL = 99
  138. const m_EADV = 68
  139. const m_EAFNOSUPPORT = 97
  140. const m_EAGAIN = 11
  141. const m_EALREADY = 114
  142. const m_EBADE = 52
  143. const m_EBADF = 9
  144. const m_EBADFD = 77
  145. const m_EBADMSG = 74
  146. const m_EBADR = 53
  147. const m_EBADRQC = 56
  148. const m_EBADSLT = 57
  149. const m_EBFONT = 59
  150. const m_EBUSY = 16
  151. const m_ECANCELED = 125
  152. const m_ECHILD = 10
  153. const m_ECHRNG = 44
  154. const m_ECOMM = 70
  155. const m_ECONNABORTED = 103
  156. const m_ECONNREFUSED = 111
  157. const m_ECONNRESET = 104
  158. const m_EDEADLK = 35
  159. const m_EDEADLOCK = "EDEADLK"
  160. const m_EDESTADDRREQ = 89
  161. const m_EDOM = 33
  162. const m_EDOTDOT = 73
  163. const m_EDQUOT = 122
  164. const m_EEXIST = 17
  165. const m_EFAULT = 14
  166. const m_EFBIG = 27
  167. const m_EHOSTDOWN = 112
  168. const m_EHOSTUNREACH = 113
  169. const m_EHWPOISON = 133
  170. const m_EIDRM = 43
  171. const m_EILSEQ = 84
  172. const m_EINPROGRESS = 115
  173. const m_EINTR = 4
  174. const m_EINVAL = 22
  175. const m_EIO = 5
  176. const m_EISCONN = 106
  177. const m_EISDIR = 21
  178. const m_EISNAM = 120
  179. const m_EKEYEXPIRED = 127
  180. const m_EKEYREJECTED = 129
  181. const m_EKEYREVOKED = 128
  182. const m_EL2HLT = 51
  183. const m_EL2NSYNC = 45
  184. const m_EL3HLT = 46
  185. const m_EL3RST = 47
  186. const m_ELIBACC = 79
  187. const m_ELIBBAD = 80
  188. const m_ELIBEXEC = 83
  189. const m_ELIBMAX = 82
  190. const m_ELIBSCN = 81
  191. const m_ELNRNG = 48
  192. const m_ELOOP = 40
  193. const m_EMEDIUMTYPE = 124
  194. const m_EMFILE = 24
  195. const m_EMLINK = 31
  196. const m_EMSGSIZE = 90
  197. const m_EMULTIHOP = 72
  198. const m_ENAMETOOLONG = 36
  199. const m_ENAVAIL = 119
  200. const m_ENETDOWN = 100
  201. const m_ENETRESET = 102
  202. const m_ENETUNREACH = 101
  203. const m_ENFILE = 23
  204. const m_ENOANO = 55
  205. const m_ENOBUFS = 105
  206. const m_ENOCSI = 50
  207. const m_ENODATA = 61
  208. const m_ENODEV = 19
  209. const m_ENOENT = 2
  210. const m_ENOEXEC = 8
  211. const m_ENOKEY = 126
  212. const m_ENOLCK = 37
  213. const m_ENOLINK = 67
  214. const m_ENOMEDIUM = 123
  215. const m_ENOMEM = 12
  216. const m_ENOMSG = 42
  217. const m_ENONET = 64
  218. const m_ENOPKG = 65
  219. const m_ENOPROTOOPT = 92
  220. const m_ENOSPC = 28
  221. const m_ENOSR = 63
  222. const m_ENOSTR = 60
  223. const m_ENOSYS = 38
  224. const m_ENOTBLK = 15
  225. const m_ENOTCONN = 107
  226. const m_ENOTDIR = 20
  227. const m_ENOTEMPTY = 39
  228. const m_ENOTNAM = 118
  229. const m_ENOTRECOVERABLE = 131
  230. const m_ENOTSOCK = 88
  231. const m_ENOTSUP = "EOPNOTSUPP"
  232. const m_ENOTTY = 25
  233. const m_ENOTUNIQ = 76
  234. const m_ENXIO = 6
  235. const m_EOPNOTSUPP = 95
  236. const m_EOVERFLOW = 75
  237. const m_EOWNERDEAD = 130
  238. const m_EPERM = 1
  239. const m_EPFNOSUPPORT = 96
  240. const m_EPIPE = 32
  241. const m_EPROTO = 71
  242. const m_EPROTONOSUPPORT = 93
  243. const m_EPROTOTYPE = 91
  244. const m_ERANGE = 34
  245. const m_EREMCHG = 78
  246. const m_EREMOTE = 66
  247. const m_EREMOTEIO = 121
  248. const m_ERESTART = 85
  249. const m_ERFKILL = 132
  250. const m_EROFS = 30
  251. const m_ESHUTDOWN = 108
  252. const m_ESOCKTNOSUPPORT = 94
  253. const m_ESPIPE = 29
  254. const m_ESRCH = 3
  255. const m_ESRMNT = 69
  256. const m_ESTALE = 116
  257. const m_ESTRPIPE = 86
  258. const m_ETIME = 62
  259. const m_ETIMEDOUT = 110
  260. const m_ETOOMANYREFS = 109
  261. const m_ETXTBSY = 26
  262. const m_EUCLEAN = 117
  263. const m_EUNATCH = 49
  264. const m_EUSERS = 87
  265. const m_EWOULDBLOCK = "EAGAIN"
  266. const m_EXDEV = 18
  267. const m_EXFULL = 54
  268. const m_EXIT_FAILURE = 1
  269. const m_EXIT_SUCCESS = 0
  270. const m_EXPR_NEST_MAX = 32
  271. const m_FALLOC_FL_KEEP_SIZE = 1
  272. const m_FALLOC_FL_PUNCH_HOLE = 2
  273. const m_FAPPEND = "O_APPEND"
  274. const m_FASYNC = "O_ASYNC"
  275. const m_FD_CLOEXEC = 1
  276. const m_FD_SETSIZE = 1024
  277. const m_FFSYNC = "O_SYNC"
  278. const m_FILENAME_MAX = 4096
  279. const m_FILESIZEBITS = 64
  280. const m_FNDELAY = "O_NDELAY"
  281. const m_FNONBLOCK = "O_NONBLOCK"
  282. const m_FOPEN_MAX = 1000
  283. const m_F_ADD_SEALS = 1033
  284. const m_F_CANCELLK = 1029
  285. const m_F_DUPFD = 0
  286. const m_F_DUPFD_CLOEXEC = 1030
  287. const m_F_GETFD = 1
  288. const m_F_GETFL = 3
  289. const m_F_GETLEASE = 1025
  290. const m_F_GETLK = 5
  291. const m_F_GETOWN = 9
  292. const m_F_GETOWNER_UIDS = 17
  293. const m_F_GETOWN_EX = 16
  294. const m_F_GETPIPE_SZ = 1032
  295. const m_F_GETSIG = 11
  296. const m_F_GET_FILE_RW_HINT = 1037
  297. const m_F_GET_RW_HINT = 1035
  298. const m_F_GET_SEALS = 1034
  299. const m_F_LOCK = 1
  300. const m_F_NOTIFY = 1026
  301. const m_F_OFD_GETLK = 36
  302. const m_F_OFD_SETLK = 37
  303. const m_F_OFD_SETLKW = 38
  304. const m_F_OK = 0
  305. const m_F_OWNER_GID = 2
  306. const m_F_OWNER_PGRP = 2
  307. const m_F_OWNER_PID = 1
  308. const m_F_OWNER_TID = 0
  309. const m_F_RDLCK = 0
  310. const m_F_SEAL_FUTURE_WRITE = 0x0010
  311. const m_F_SEAL_GROW = 0x0004
  312. const m_F_SEAL_SEAL = 0x0001
  313. const m_F_SEAL_SHRINK = 0x0002
  314. const m_F_SEAL_WRITE = 0x0008
  315. const m_F_SETFD = 2
  316. const m_F_SETFL = 4
  317. const m_F_SETLEASE = 1024
  318. const m_F_SETLK = 6
  319. const m_F_SETLKW = 7
  320. const m_F_SETOWN = 8
  321. const m_F_SETOWN_EX = 15
  322. const m_F_SETPIPE_SZ = 1031
  323. const m_F_SETSIG = 10
  324. const m_F_SET_FILE_RW_HINT = 1038
  325. const m_F_SET_RW_HINT = 1036
  326. const m_F_TEST = 3
  327. const m_F_TLOCK = 2
  328. const m_F_ULOCK = 0
  329. const m_F_UNLCK = 2
  330. const m_F_WRLCK = 1
  331. const m_HASXDMAUTH = 1
  332. const m_HAVE_ABSTRACT_SOCKETS = 1
  333. const m_HAVE_CONFIG_H = 1
  334. const m_HAVE_DLFCN_H = 1
  335. const m_HAVE_GETADDRINFO = 1
  336. const m_HAVE_INTTYPES_H = 1
  337. const m_HAVE_SENDMSG = 1
  338. const m_HAVE_STDINT_H = 1
  339. const m_HAVE_STDIO_H = 1
  340. const m_HAVE_STDLIB_H = 1
  341. const m_HAVE_STRINGS_H = 1
  342. const m_HAVE_STRING_H = 1
  343. const m_HAVE_SYS_STAT_H = 1
  344. const m_HAVE_SYS_TYPES_H = 1
  345. const m_HAVE_UNISTD_H = 1
  346. const m_HAVE_WCHAR_H = 1
  347. const m_HOST_NAME_MAX = 255
  348. const m_INET6_ADDRSTRLEN = 46
  349. const m_INET_ADDRSTRLEN = 16
  350. const m_INT16_MAX = 0x7fff
  351. const m_INT32_MAX = 0x7fffffff
  352. const m_INT64_MAX = 0x7fffffffffffffff
  353. const m_INT8_MAX = 0x7f
  354. const m_INTMAX_MAX = "INT64_MAX"
  355. const m_INTMAX_MIN = "INT64_MIN"
  356. const m_INTPTR_MAX = "INT64_MAX"
  357. const m_INTPTR_MIN = "INT64_MIN"
  358. const m_INT_FAST16_MAX = "INT32_MAX"
  359. const m_INT_FAST16_MIN = "INT32_MIN"
  360. const m_INT_FAST32_MAX = "INT32_MAX"
  361. const m_INT_FAST32_MIN = "INT32_MIN"
  362. const m_INT_FAST64_MAX = "INT64_MAX"
  363. const m_INT_FAST64_MIN = "INT64_MIN"
  364. const m_INT_FAST8_MAX = "INT8_MAX"
  365. const m_INT_FAST8_MIN = "INT8_MIN"
  366. const m_INT_LEAST16_MAX = "INT16_MAX"
  367. const m_INT_LEAST16_MIN = "INT16_MIN"
  368. const m_INT_LEAST32_MAX = "INT32_MAX"
  369. const m_INT_LEAST32_MIN = "INT32_MIN"
  370. const m_INT_LEAST64_MAX = "INT64_MAX"
  371. const m_INT_LEAST64_MIN = "INT64_MIN"
  372. const m_INT_LEAST8_MAX = "INT8_MAX"
  373. const m_INT_LEAST8_MIN = "INT8_MIN"
  374. const m_INT_MAX = 0x7fffffff
  375. const m_IN_CLASSA_MAX = 128
  376. const m_IN_CLASSA_NET = 0xff000000
  377. const m_IN_CLASSA_NSHIFT = 24
  378. const m_IN_CLASSB_MAX = 65536
  379. const m_IN_CLASSB_NET = 0xffff0000
  380. const m_IN_CLASSB_NSHIFT = 16
  381. const m_IN_CLASSC_NET = 0xffffff00
  382. const m_IN_CLASSC_NSHIFT = 8
  383. const m_IN_LOOPBACKNET = 127
  384. const m_IOV_MAX = 1024
  385. const m_IPPORT_RESERVED = 1024
  386. const m_IPPROTO_AH = 51
  387. const m_IPPROTO_BEETPH = 94
  388. const m_IPPROTO_COMP = 108
  389. const m_IPPROTO_DCCP = 33
  390. const m_IPPROTO_DSTOPTS = 60
  391. const m_IPPROTO_EGP = 8
  392. const m_IPPROTO_ENCAP = 98
  393. const m_IPPROTO_ESP = 50
  394. const m_IPPROTO_ETHERNET = 143
  395. const m_IPPROTO_FRAGMENT = 44
  396. const m_IPPROTO_GRE = 47
  397. const m_IPPROTO_HOPOPTS = 0
  398. const m_IPPROTO_ICMP = 1
  399. const m_IPPROTO_ICMPV6 = 58
  400. const m_IPPROTO_IDP = 22
  401. const m_IPPROTO_IGMP = 2
  402. const m_IPPROTO_IP = 0
  403. const m_IPPROTO_IPIP = 4
  404. const m_IPPROTO_IPV6 = 41
  405. const m_IPPROTO_MAX = 263
  406. const m_IPPROTO_MH = 135
  407. const m_IPPROTO_MPLS = 137
  408. const m_IPPROTO_MPTCP = 262
  409. const m_IPPROTO_MTP = 92
  410. const m_IPPROTO_NONE = 59
  411. const m_IPPROTO_PIM = 103
  412. const m_IPPROTO_PUP = 12
  413. const m_IPPROTO_RAW = 255
  414. const m_IPPROTO_ROUTING = 43
  415. const m_IPPROTO_RSVP = 46
  416. const m_IPPROTO_SCTP = 132
  417. const m_IPPROTO_TCP = 6
  418. const m_IPPROTO_TP = 29
  419. const m_IPPROTO_UDP = 17
  420. const m_IPPROTO_UDPLITE = 136
  421. const m_IPV6_2292DSTOPTS = 4
  422. const m_IPV6_2292HOPLIMIT = 8
  423. const m_IPV6_2292HOPOPTS = 3
  424. const m_IPV6_2292PKTINFO = 2
  425. const m_IPV6_2292PKTOPTIONS = 6
  426. const m_IPV6_2292RTHDR = 5
  427. const m_IPV6_ADDRFORM = 1
  428. const m_IPV6_ADDR_PREFERENCES = 72
  429. const m_IPV6_ADD_MEMBERSHIP = "IPV6_JOIN_GROUP"
  430. const m_IPV6_AUTHHDR = 10
  431. const m_IPV6_AUTOFLOWLABEL = 70
  432. const m_IPV6_CHECKSUM = 7
  433. const m_IPV6_DONTFRAG = 62
  434. const m_IPV6_DROP_MEMBERSHIP = "IPV6_LEAVE_GROUP"
  435. const m_IPV6_DSTOPTS = 59
  436. const m_IPV6_FREEBIND = 78
  437. const m_IPV6_HDRINCL = 36
  438. const m_IPV6_HOPLIMIT = 52
  439. const m_IPV6_HOPOPTS = 54
  440. const m_IPV6_IPSEC_POLICY = 34
  441. const m_IPV6_JOIN_ANYCAST = 27
  442. const m_IPV6_JOIN_GROUP = 20
  443. const m_IPV6_LEAVE_ANYCAST = 28
  444. const m_IPV6_LEAVE_GROUP = 21
  445. const m_IPV6_MINHOPCOUNT = 73
  446. const m_IPV6_MTU = 24
  447. const m_IPV6_MTU_DISCOVER = 23
  448. const m_IPV6_MULTICAST_ALL = 29
  449. const m_IPV6_MULTICAST_HOPS = 18
  450. const m_IPV6_MULTICAST_IF = 17
  451. const m_IPV6_MULTICAST_LOOP = 19
  452. const m_IPV6_NEXTHOP = 9
  453. const m_IPV6_ORIGDSTADDR = 74
  454. const m_IPV6_PATHMTU = 61
  455. const m_IPV6_PKTINFO = 50
  456. const m_IPV6_PMTUDISC_DO = 2
  457. const m_IPV6_PMTUDISC_DONT = 0
  458. const m_IPV6_PMTUDISC_INTERFACE = 4
  459. const m_IPV6_PMTUDISC_OMIT = 5
  460. const m_IPV6_PMTUDISC_PROBE = 3
  461. const m_IPV6_PMTUDISC_WANT = 1
  462. const m_IPV6_PREFER_SRC_CGA = 0x0008
  463. const m_IPV6_PREFER_SRC_COA = 0x0004
  464. const m_IPV6_PREFER_SRC_HOME = 0x0400
  465. const m_IPV6_PREFER_SRC_NONCGA = 0x0800
  466. const m_IPV6_PREFER_SRC_PUBLIC = 0x0002
  467. const m_IPV6_PREFER_SRC_PUBTMP_DEFAULT = 0x0100
  468. const m_IPV6_PREFER_SRC_TMP = 0x0001
  469. const m_IPV6_RECVDSTOPTS = 58
  470. const m_IPV6_RECVERR = 25
  471. const m_IPV6_RECVFRAGSIZE = 77
  472. const m_IPV6_RECVHOPLIMIT = 51
  473. const m_IPV6_RECVHOPOPTS = 53
  474. const m_IPV6_RECVORIGDSTADDR = "IPV6_ORIGDSTADDR"
  475. const m_IPV6_RECVPATHMTU = 60
  476. const m_IPV6_RECVPKTINFO = 49
  477. const m_IPV6_RECVRTHDR = 56
  478. const m_IPV6_RECVTCLASS = 66
  479. const m_IPV6_ROUTER_ALERT = 22
  480. const m_IPV6_ROUTER_ALERT_ISOLATE = 30
  481. const m_IPV6_RTHDR = 57
  482. const m_IPV6_RTHDRDSTOPTS = 55
  483. const m_IPV6_RTHDR_LOOSE = 0
  484. const m_IPV6_RTHDR_STRICT = 1
  485. const m_IPV6_RTHDR_TYPE_0 = 0
  486. const m_IPV6_RXDSTOPTS = "IPV6_DSTOPTS"
  487. const m_IPV6_RXHOPOPTS = "IPV6_HOPOPTS"
  488. const m_IPV6_TCLASS = 67
  489. const m_IPV6_TRANSPARENT = 75
  490. const m_IPV6_UNICAST_HOPS = 16
  491. const m_IPV6_UNICAST_IF = 76
  492. const m_IPV6_V6ONLY = 26
  493. const m_IPV6_XFRM_POLICY = 35
  494. const m_IP_ADD_MEMBERSHIP = 35
  495. const m_IP_ADD_SOURCE_MEMBERSHIP = 39
  496. const m_IP_BIND_ADDRESS_NO_PORT = 24
  497. const m_IP_BLOCK_SOURCE = 38
  498. const m_IP_CHECKSUM = 23
  499. const m_IP_DEFAULT_MULTICAST_LOOP = 1
  500. const m_IP_DEFAULT_MULTICAST_TTL = 1
  501. const m_IP_DROP_MEMBERSHIP = 36
  502. const m_IP_DROP_SOURCE_MEMBERSHIP = 40
  503. const m_IP_FREEBIND = 15
  504. const m_IP_HDRINCL = 3
  505. const m_IP_IPSEC_POLICY = 16
  506. const m_IP_MAX_MEMBERSHIPS = 20
  507. const m_IP_MINTTL = 21
  508. const m_IP_MSFILTER = 41
  509. const m_IP_MTU = 14
  510. const m_IP_MTU_DISCOVER = 10
  511. const m_IP_MULTICAST_ALL = 49
  512. const m_IP_MULTICAST_IF = 32
  513. const m_IP_MULTICAST_LOOP = 34
  514. const m_IP_MULTICAST_TTL = 33
  515. const m_IP_NODEFRAG = 22
  516. const m_IP_OPTIONS = 4
  517. const m_IP_ORIGDSTADDR = 20
  518. const m_IP_PASSSEC = 18
  519. const m_IP_PKTINFO = 8
  520. const m_IP_PKTOPTIONS = 9
  521. const m_IP_PMTUDISC = 10
  522. const m_IP_PMTUDISC_DO = 2
  523. const m_IP_PMTUDISC_DONT = 0
  524. const m_IP_PMTUDISC_INTERFACE = 4
  525. const m_IP_PMTUDISC_OMIT = 5
  526. const m_IP_PMTUDISC_PROBE = 3
  527. const m_IP_PMTUDISC_WANT = 1
  528. const m_IP_RECVERR = 11
  529. const m_IP_RECVERR_RFC4884 = 26
  530. const m_IP_RECVFRAGSIZE = 25
  531. const m_IP_RECVOPTS = 6
  532. const m_IP_RECVORIGDSTADDR = "IP_ORIGDSTADDR"
  533. const m_IP_RECVRETOPTS = "IP_RETOPTS"
  534. const m_IP_RECVTOS = 13
  535. const m_IP_RECVTTL = 12
  536. const m_IP_RETOPTS = 7
  537. const m_IP_ROUTER_ALERT = 5
  538. const m_IP_TOS = 1
  539. const m_IP_TRANSPARENT = 19
  540. const m_IP_TTL = 2
  541. const m_IP_UNBLOCK_SOURCE = 37
  542. const m_IP_UNICAST_IF = 50
  543. const m_IP_XFRM_POLICY = 17
  544. const m_LINE_MAX = 4096
  545. const m_LITTLE_ENDIAN = "__LITTLE_ENDIAN"
  546. const m_LLONG_MAX = 0x7fffffffffffffff
  547. const m_LOGIN_NAME_MAX = 256
  548. const m_LONG_BIT = 64
  549. const m_LONG_MAX = "__LONG_MAX"
  550. const m_LT_OBJDIR = ".libs/"
  551. const m_L_INCR = 1
  552. const m_L_SET = 0
  553. const m_L_XTND = 2
  554. const m_L_ctermid = 20
  555. const m_L_cuserid = 20
  556. const m_L_tmpnam = 20
  557. const m_MAX_HANDLE_SZ = 128
  558. const m_MB_LEN_MAX = 4
  559. const m_MCAST_BLOCK_SOURCE = 43
  560. const m_MCAST_EXCLUDE = 0
  561. const m_MCAST_INCLUDE = 1
  562. const m_MCAST_JOIN_GROUP = 42
  563. const m_MCAST_JOIN_SOURCE_GROUP = 46
  564. const m_MCAST_LEAVE_GROUP = 45
  565. const m_MCAST_LEAVE_SOURCE_GROUP = 47
  566. const m_MCAST_MSFILTER = 48
  567. const m_MCAST_UNBLOCK_SOURCE = 44
  568. const m_MQ_PRIO_MAX = 32768
  569. const m_MSG_BATCH = 0x40000
  570. const m_MSG_CMSG_CLOEXEC = 0x40000000
  571. const m_MSG_CONFIRM = 0x0800
  572. const m_MSG_CTRUNC = 0x0008
  573. const m_MSG_DONTROUTE = 0x0004
  574. const m_MSG_DONTWAIT = 0x0040
  575. const m_MSG_EOR = 0x0080
  576. const m_MSG_ERRQUEUE = 0x2000
  577. const m_MSG_FASTOPEN = 0x20000000
  578. const m_MSG_FIN = 0x0200
  579. const m_MSG_MORE = 0x8000
  580. const m_MSG_NOSIGNAL = 0x4000
  581. const m_MSG_OOB = 0x0001
  582. const m_MSG_PEEK = 0x0002
  583. const m_MSG_PROXY = 0x0010
  584. const m_MSG_RST = 0x1000
  585. const m_MSG_SYN = 0x0400
  586. const m_MSG_TRUNC = 0x0020
  587. const m_MSG_WAITALL = 0x0100
  588. const m_MSG_WAITFORONE = 0x10000
  589. const m_MSG_ZEROCOPY = 0x4000000
  590. const m_NAME_MAX = 255
  591. const m_NDEBUG = 1
  592. const m_NGROUPS_MAX = 32
  593. const m_NL_ARGMAX = 9
  594. const m_NL_LANGMAX = 32
  595. const m_NL_MSGMAX = 32767
  596. const m_NL_NMAX = 16
  597. const m_NL_SETMAX = 255
  598. const m_NL_TEXTMAX = 2048
  599. const m_NZERO = 20
  600. const m_O_APPEND = 02000
  601. const m_O_ASYNC = 020000
  602. const m_O_CLOEXEC = 02000000
  603. const m_O_CREAT = 0100
  604. const m_O_DIRECT = 040000
  605. const m_O_DIRECTORY = 0200000
  606. const m_O_DSYNC = 010000
  607. const m_O_EXCL = 0200
  608. const m_O_EXEC = "O_PATH"
  609. const m_O_LARGEFILE = 0100000
  610. const m_O_NDELAY = "O_NONBLOCK"
  611. const m_O_NOATIME = 01000000
  612. const m_O_NOCTTY = 0400
  613. const m_O_NOFOLLOW = 0400000
  614. const m_O_NONBLOCK = 2048
  615. const m_O_PATH = 010000000
  616. const m_O_RDONLY = 00
  617. const m_O_RDWR = 02
  618. const m_O_RSYNC = 04010000
  619. const m_O_SEARCH = "O_PATH"
  620. const m_O_SYNC = 04010000
  621. const m_O_TMPFILE = 020200000
  622. const m_O_TRUNC = 01000
  623. const m_O_TTY_INIT = 0
  624. const m_O_WRONLY = 01
  625. const m_PACKAGE = "libxcb"
  626. const m_PACKAGE_BUGREPORT = "https://gitlab.freedesktop.org/xorg/lib/libxcb/issues"
  627. const m_PACKAGE_NAME = "libxcb"
  628. const m_PACKAGE_STRING = "libxcb 1.15"
  629. const m_PACKAGE_TARNAME = "libxcb"
  630. const m_PACKAGE_URL = ""
  631. const m_PACKAGE_VERSION = "1.15"
  632. const m_PACKAGE_VERSION_MAJOR = 1
  633. const m_PACKAGE_VERSION_MINOR = 15
  634. const m_PACKAGE_VERSION_PATCHLEVEL = 0
  635. const m_PAGESIZE = 4096
  636. const m_PAGE_SIZE = "PAGESIZE"
  637. const m_PATH_MAX = 4096
  638. const m_PDP_ENDIAN = "__PDP_ENDIAN"
  639. const m_PF_ALG = 38
  640. const m_PF_APPLETALK = 5
  641. const m_PF_ASH = 18
  642. const m_PF_ATMPVC = 8
  643. const m_PF_ATMSVC = 20
  644. const m_PF_AX25 = 3
  645. const m_PF_BLUETOOTH = 31
  646. const m_PF_BRIDGE = 7
  647. const m_PF_CAIF = 37
  648. const m_PF_CAN = 29
  649. const m_PF_DECnet = 12
  650. const m_PF_ECONET = 19
  651. const m_PF_FILE = "PF_LOCAL"
  652. const m_PF_IB = 27
  653. const m_PF_IEEE802154 = 36
  654. const m_PF_INET = 2
  655. const m_PF_INET6 = 10
  656. const m_PF_IPX = 4
  657. const m_PF_IRDA = 23
  658. const m_PF_ISDN = 34
  659. const m_PF_IUCV = 32
  660. const m_PF_KCM = 41
  661. const m_PF_KEY = 15
  662. const m_PF_LLC = 26
  663. const m_PF_LOCAL = 1
  664. const m_PF_MAX = 45
  665. const m_PF_MPLS = 28
  666. const m_PF_NETBEUI = 13
  667. const m_PF_NETLINK = 16
  668. const m_PF_NETROM = 6
  669. const m_PF_NFC = 39
  670. const m_PF_PACKET = 17
  671. const m_PF_PHONET = 35
  672. const m_PF_PPPOX = 24
  673. const m_PF_QIPCRTR = 42
  674. const m_PF_RDS = 21
  675. const m_PF_ROSE = 11
  676. const m_PF_ROUTE = "PF_NETLINK"
  677. const m_PF_RXRPC = 33
  678. const m_PF_SECURITY = 14
  679. const m_PF_SMC = 43
  680. const m_PF_SNA = 22
  681. const m_PF_TIPC = 30
  682. const m_PF_UNIX = "PF_LOCAL"
  683. const m_PF_UNSPEC = 0
  684. const m_PF_VSOCK = 40
  685. const m_PF_WANPIPE = 25
  686. const m_PF_X25 = 9
  687. const m_PF_XDP = 44
  688. const m_PIPE_BUF = 4096
  689. const m_POLLERR = 0x008
  690. const m_POLLHUP = 0x010
  691. const m_POLLIN = 1
  692. const m_POLLMSG = 0x400
  693. const m_POLLNVAL = 0x020
  694. const m_POLLOUT = 4
  695. const m_POLLPRI = 0x002
  696. const m_POLLRDBAND = 0x080
  697. const m_POLLRDHUP = 0x2000
  698. const m_POLLRDNORM = 0x040
  699. const m_POLLWRBAND = 0x200
  700. const m_POLLWRNORM = 0x100
  701. const m_POSIX_CLOSE_RESTART = 0
  702. const m_POSIX_FADV_DONTNEED = 4
  703. const m_POSIX_FADV_NOREUSE = 5
  704. const m_POSIX_FADV_NORMAL = 0
  705. const m_POSIX_FADV_RANDOM = 1
  706. const m_POSIX_FADV_SEQUENTIAL = 2
  707. const m_POSIX_FADV_WILLNEED = 3
  708. const m_PRIX16 = "X"
  709. const m_PRIX32 = "X"
  710. const m_PRIX8 = "X"
  711. const m_PRIXFAST16 = "X"
  712. const m_PRIXFAST32 = "X"
  713. const m_PRIXFAST8 = "X"
  714. const m_PRIXLEAST16 = "X"
  715. const m_PRIXLEAST32 = "X"
  716. const m_PRIXLEAST8 = "X"
  717. const m_PRId16 = "d"
  718. const m_PRId32 = "d"
  719. const m_PRId8 = "d"
  720. const m_PRIdFAST16 = "d"
  721. const m_PRIdFAST32 = "d"
  722. const m_PRIdFAST8 = "d"
  723. const m_PRIdLEAST16 = "d"
  724. const m_PRIdLEAST32 = "d"
  725. const m_PRIdLEAST8 = "d"
  726. const m_PRIi16 = "i"
  727. const m_PRIi32 = "i"
  728. const m_PRIi8 = "i"
  729. const m_PRIiFAST16 = "i"
  730. const m_PRIiFAST32 = "i"
  731. const m_PRIiFAST8 = "i"
  732. const m_PRIiLEAST16 = "i"
  733. const m_PRIiLEAST32 = "i"
  734. const m_PRIiLEAST8 = "i"
  735. const m_PRIo16 = "o"
  736. const m_PRIo32 = "o"
  737. const m_PRIo8 = "o"
  738. const m_PRIoFAST16 = "o"
  739. const m_PRIoFAST32 = "o"
  740. const m_PRIoFAST8 = "o"
  741. const m_PRIoLEAST16 = "o"
  742. const m_PRIoLEAST32 = "o"
  743. const m_PRIoLEAST8 = "o"
  744. const m_PRIu16 = "u"
  745. const m_PRIu32 = "u"
  746. const m_PRIu8 = "u"
  747. const m_PRIuFAST16 = "u"
  748. const m_PRIuFAST32 = "u"
  749. const m_PRIuFAST8 = "u"
  750. const m_PRIuLEAST16 = "u"
  751. const m_PRIuLEAST32 = "u"
  752. const m_PRIuLEAST8 = "u"
  753. const m_PRIx16 = "x"
  754. const m_PRIx32 = "x"
  755. const m_PRIx8 = "x"
  756. const m_PRIxFAST16 = "x"
  757. const m_PRIxFAST32 = "x"
  758. const m_PRIxFAST8 = "x"
  759. const m_PRIxLEAST16 = "x"
  760. const m_PRIxLEAST32 = "x"
  761. const m_PRIxLEAST8 = "x"
  762. const m_PTHREAD_CANCEL_ASYNCHRONOUS = 1
  763. const m_PTHREAD_CANCEL_DEFERRED = 0
  764. const m_PTHREAD_CANCEL_DISABLE = 1
  765. const m_PTHREAD_CANCEL_ENABLE = 0
  766. const m_PTHREAD_CANCEL_MASKED = 2
  767. const m_PTHREAD_CREATE_DETACHED = 1
  768. const m_PTHREAD_CREATE_JOINABLE = 0
  769. const m_PTHREAD_DESTRUCTOR_ITERATIONS = 4
  770. const m_PTHREAD_EXPLICIT_SCHED = 1
  771. const m_PTHREAD_INHERIT_SCHED = 0
  772. const m_PTHREAD_KEYS_MAX = 128
  773. const m_PTHREAD_MUTEX_DEFAULT = 0
  774. const m_PTHREAD_MUTEX_ERRORCHECK = 2
  775. const m_PTHREAD_MUTEX_NORMAL = 0
  776. const m_PTHREAD_MUTEX_RECURSIVE = 1
  777. const m_PTHREAD_MUTEX_ROBUST = 1
  778. const m_PTHREAD_MUTEX_STALLED = 0
  779. const m_PTHREAD_ONCE_INIT = 0
  780. const m_PTHREAD_PRIO_INHERIT = 1
  781. const m_PTHREAD_PRIO_NONE = 0
  782. const m_PTHREAD_PRIO_PROTECT = 2
  783. const m_PTHREAD_PROCESS_PRIVATE = 0
  784. const m_PTHREAD_PROCESS_SHARED = 1
  785. const m_PTHREAD_SCOPE_PROCESS = 1
  786. const m_PTHREAD_SCOPE_SYSTEM = 0
  787. const m_PTHREAD_STACK_MIN = 2048
  788. const m_PTRDIFF_MAX = "INT64_MAX"
  789. const m_PTRDIFF_MIN = "INT64_MIN"
  790. const m_P_tmpdir = "/tmp"
  791. const m_RAND_MAX = 0x7fffffff
  792. const m_RE_DUP_MAX = 255
  793. const m_RWF_APPEND = 0x00000010
  794. const m_RWF_DSYNC = 0x00000002
  795. const m_RWF_HIPRI = 0x00000001
  796. const m_RWF_NOWAIT = 0x00000008
  797. const m_RWF_SYNC = 0x00000004
  798. const m_RWF_WRITE_LIFE_NOT_SET = 0
  799. const m_RWH_WRITE_LIFE_EXTREME = 5
  800. const m_RWH_WRITE_LIFE_LONG = 4
  801. const m_RWH_WRITE_LIFE_MEDIUM = 3
  802. const m_RWH_WRITE_LIFE_NONE = 1
  803. const m_RWH_WRITE_LIFE_SHORT = 2
  804. const m_R_OK = 4
  805. const m_SCHAR_MAX = 127
  806. const m_SCHED_BATCH = 3
  807. const m_SCHED_DEADLINE = 6
  808. const m_SCHED_FIFO = 1
  809. const m_SCHED_IDLE = 5
  810. const m_SCHED_OTHER = 0
  811. const m_SCHED_RESET_ON_FORK = 0x40000000
  812. const m_SCHED_RR = 2
  813. const m_SCM_CREDENTIALS = 0x02
  814. const m_SCM_RIGHTS = 1
  815. const m_SCM_TIMESTAMP = "SO_TIMESTAMP"
  816. const m_SCM_TIMESTAMPING = "SO_TIMESTAMPING"
  817. const m_SCM_TIMESTAMPING_OPT_STATS = 54
  818. const m_SCM_TIMESTAMPING_PKTINFO = 58
  819. const m_SCM_TIMESTAMPNS = "SO_TIMESTAMPNS"
  820. const m_SCM_TXTIME = "SO_TXTIME"
  821. const m_SCM_WIFI_STATUS = "SO_WIFI_STATUS"
  822. const m_SCNd16 = "hd"
  823. const m_SCNd32 = "d"
  824. const m_SCNd8 = "hhd"
  825. const m_SCNdFAST16 = "d"
  826. const m_SCNdFAST32 = "d"
  827. const m_SCNdFAST8 = "hhd"
  828. const m_SCNdLEAST16 = "hd"
  829. const m_SCNdLEAST32 = "d"
  830. const m_SCNdLEAST8 = "hhd"
  831. const m_SCNi16 = "hi"
  832. const m_SCNi32 = "i"
  833. const m_SCNi8 = "hhi"
  834. const m_SCNiFAST16 = "i"
  835. const m_SCNiFAST32 = "i"
  836. const m_SCNiFAST8 = "hhi"
  837. const m_SCNiLEAST16 = "hi"
  838. const m_SCNiLEAST32 = "i"
  839. const m_SCNiLEAST8 = "hhi"
  840. const m_SCNo16 = "ho"
  841. const m_SCNo32 = "o"
  842. const m_SCNo8 = "hho"
  843. const m_SCNoFAST16 = "o"
  844. const m_SCNoFAST32 = "o"
  845. const m_SCNoFAST8 = "hho"
  846. const m_SCNoLEAST16 = "ho"
  847. const m_SCNoLEAST32 = "o"
  848. const m_SCNoLEAST8 = "hho"
  849. const m_SCNu16 = "hu"
  850. const m_SCNu32 = "u"
  851. const m_SCNu8 = "hhu"
  852. const m_SCNuFAST16 = "u"
  853. const m_SCNuFAST32 = "u"
  854. const m_SCNuFAST8 = "hhu"
  855. const m_SCNuLEAST16 = "hu"
  856. const m_SCNuLEAST32 = "u"
  857. const m_SCNuLEAST8 = "hhu"
  858. const m_SCNx16 = "hx"
  859. const m_SCNx32 = "x"
  860. const m_SCNx8 = "hhx"
  861. const m_SCNxFAST16 = "x"
  862. const m_SCNxFAST32 = "x"
  863. const m_SCNxFAST8 = "hhx"
  864. const m_SCNxLEAST16 = "hx"
  865. const m_SCNxLEAST32 = "x"
  866. const m_SCNxLEAST8 = "hhx"
  867. const m_SEEK_DATA = 3
  868. const m_SEEK_HOLE = 4
  869. const m_SEM_NSEMS_MAX = 256
  870. const m_SEM_VALUE_MAX = 0x7fffffff
  871. const m_SHRT_MAX = 0x7fff
  872. const m_SHUT_RD = 0
  873. const m_SHUT_RDWR = 2
  874. const m_SHUT_WR = 1
  875. const m_SIG_ATOMIC_MAX = "INT32_MAX"
  876. const m_SIG_ATOMIC_MIN = "INT32_MIN"
  877. const m_SIZE_MAX = "UINT64_MAX"
  878. const m_SOCK_CLOEXEC = 02000000
  879. const m_SOCK_DCCP = 6
  880. const m_SOCK_DGRAM = 2
  881. const m_SOCK_NONBLOCK = 04000
  882. const m_SOCK_PACKET = 10
  883. const m_SOCK_RAW = 3
  884. const m_SOCK_RDM = 4
  885. const m_SOCK_SEQPACKET = 5
  886. const m_SOCK_STREAM = 1
  887. const m_SOL_AAL = 265
  888. const m_SOL_ALG = 279
  889. const m_SOL_ATM = 264
  890. const m_SOL_BLUETOOTH = 274
  891. const m_SOL_CAIF = 278
  892. const m_SOL_DCCP = 269
  893. const m_SOL_DECNET = 261
  894. const m_SOL_ICMPV6 = 58
  895. const m_SOL_IP = 0
  896. const m_SOL_IPV6 = 41
  897. const m_SOL_IRDA = 266
  898. const m_SOL_IUCV = 277
  899. const m_SOL_KCM = 281
  900. const m_SOL_LLC = 268
  901. const m_SOL_NETBEUI = 267
  902. const m_SOL_NETLINK = 270
  903. const m_SOL_NFC = 280
  904. const m_SOL_PACKET = 263
  905. const m_SOL_PNPIPE = 275
  906. const m_SOL_PPPOL2TP = 273
  907. const m_SOL_RAW = 255
  908. const m_SOL_RDS = 276
  909. const m_SOL_RXRPC = 272
  910. const m_SOL_SOCKET = 1
  911. const m_SOL_TIPC = 271
  912. const m_SOL_TLS = 282
  913. const m_SOL_X25 = 262
  914. const m_SOL_XDP = 283
  915. const m_SOMAXCONN = 128
  916. const m_SO_ACCEPTCONN = 30
  917. const m_SO_ATTACH_BPF = 50
  918. const m_SO_ATTACH_FILTER = 26
  919. const m_SO_ATTACH_REUSEPORT_CBPF = 51
  920. const m_SO_ATTACH_REUSEPORT_EBPF = 52
  921. const m_SO_BINDTODEVICE = 25
  922. const m_SO_BINDTOIFINDEX = 62
  923. const m_SO_BPF_EXTENSIONS = 48
  924. const m_SO_BROADCAST = 6
  925. const m_SO_BSDCOMPAT = 14
  926. const m_SO_BUSY_POLL = 46
  927. const m_SO_BUSY_POLL_BUDGET = 70
  928. const m_SO_CNX_ADVICE = 53
  929. const m_SO_COOKIE = 57
  930. const m_SO_DEBUG = 1
  931. const m_SO_DETACH_BPF = "SO_DETACH_FILTER"
  932. const m_SO_DETACH_FILTER = 27
  933. const m_SO_DETACH_REUSEPORT_BPF = 68
  934. const m_SO_DOMAIN = 39
  935. const m_SO_DONTROUTE = 5
  936. const m_SO_ERROR = 4
  937. const m_SO_GET_FILTER = "SO_ATTACH_FILTER"
  938. const m_SO_INCOMING_CPU = 49
  939. const m_SO_INCOMING_NAPI_ID = 56
  940. const m_SO_KEEPALIVE = 9
  941. const m_SO_LINGER = 13
  942. const m_SO_LOCK_FILTER = 44
  943. const m_SO_MARK = 36
  944. const m_SO_MAX_PACING_RATE = 47
  945. const m_SO_MEMINFO = 55
  946. const m_SO_NOFCS = 43
  947. const m_SO_NO_CHECK = 11
  948. const m_SO_OOBINLINE = 10
  949. const m_SO_PASSCRED = 16
  950. const m_SO_PASSSEC = 34
  951. const m_SO_PEEK_OFF = 42
  952. const m_SO_PEERCRED = 17
  953. const m_SO_PEERGROUPS = 59
  954. const m_SO_PEERNAME = 28
  955. const m_SO_PEERSEC = 31
  956. const m_SO_PREFER_BUSY_POLL = 69
  957. const m_SO_PRIORITY = 12
  958. const m_SO_PROTOCOL = 38
  959. const m_SO_RCVBUF = 8
  960. const m_SO_RCVBUFFORCE = 33
  961. const m_SO_RCVLOWAT = 18
  962. const m_SO_RCVTIMEO = 20
  963. const m_SO_REUSEADDR = 2
  964. const m_SO_REUSEPORT = 15
  965. const m_SO_RXQ_OVFL = 40
  966. const m_SO_SECURITY_AUTHENTICATION = 22
  967. const m_SO_SECURITY_ENCRYPTION_NETWORK = 24
  968. const m_SO_SECURITY_ENCRYPTION_TRANSPORT = 23
  969. const m_SO_SELECT_ERR_QUEUE = 45
  970. const m_SO_SNDBUF = 7
  971. const m_SO_SNDBUFFORCE = 32
  972. const m_SO_SNDLOWAT = 19
  973. const m_SO_SNDTIMEO = 21
  974. const m_SO_TIMESTAMP = 29
  975. const m_SO_TIMESTAMPING = 37
  976. const m_SO_TIMESTAMPNS = 35
  977. const m_SO_TXTIME = 61
  978. const m_SO_TYPE = 3
  979. const m_SO_WIFI_STATUS = 41
  980. const m_SO_ZEROCOPY = 60
  981. const m_SPLICE_F_GIFT = 8
  982. const m_SPLICE_F_MORE = 4
  983. const m_SPLICE_F_MOVE = 1
  984. const m_SPLICE_F_NONBLOCK = 2
  985. const m_SSIZE_MAX = "LONG_MAX"
  986. const m_STDC_HEADERS = 1
  987. const m_STDERR_FILENO = 2
  988. const m_STDIN_FILENO = 0
  989. const m_STDOUT_FILENO = 1
  990. const m_SYMLOOP_MAX = 40
  991. const m_SYNC_FILE_RANGE_WAIT_AFTER = 4
  992. const m_SYNC_FILE_RANGE_WAIT_BEFORE = 1
  993. const m_SYNC_FILE_RANGE_WRITE = 2
  994. const m_S_IRGRP = 0040
  995. const m_S_IROTH = 0004
  996. const m_S_IRUSR = 0400
  997. const m_S_IRWXG = 0070
  998. const m_S_IRWXO = 0007
  999. const m_S_IRWXU = 0700
  1000. const m_S_ISGID = 02000
  1001. const m_S_ISUID = 04000
  1002. const m_S_ISVTX = 01000
  1003. const m_S_IWGRP = 0020
  1004. const m_S_IWOTH = 0002
  1005. const m_S_IWUSR = 0200
  1006. const m_S_IXGRP = 0010
  1007. const m_S_IXOTH = 0001
  1008. const m_S_IXUSR = 0100
  1009. const m_TIMER_ABSTIME = 1
  1010. const m_TIME_UTC = 1
  1011. const m_TMP_MAX = 10000
  1012. const m_TTY_NAME_MAX = 32
  1013. const m_TZNAME_MAX = 6
  1014. const m_UCHAR_MAX = 255
  1015. const m_UINT16_MAX = 0xffff
  1016. const m_UINT32_MAX = "0xffffffffu"
  1017. const m_UINT64_MAX = "0xffffffffffffffffu"
  1018. const m_UINT8_MAX = 0xff
  1019. const m_UINTMAX_MAX = "UINT64_MAX"
  1020. const m_UINTPTR_MAX = "UINT64_MAX"
  1021. const m_UINT_FAST16_MAX = "UINT32_MAX"
  1022. const m_UINT_FAST32_MAX = "UINT32_MAX"
  1023. const m_UINT_FAST64_MAX = "UINT64_MAX"
  1024. const m_UINT_FAST8_MAX = "UINT8_MAX"
  1025. const m_UINT_LEAST16_MAX = "UINT16_MAX"
  1026. const m_UINT_LEAST32_MAX = "UINT32_MAX"
  1027. const m_UINT_LEAST64_MAX = "UINT64_MAX"
  1028. const m_UINT_LEAST8_MAX = "UINT8_MAX"
  1029. const m_UINT_MAX = 0xffffffff
  1030. const m_UIO_MAXIOV = 1024
  1031. const m_USE_POLL = 1
  1032. const m_USHRT_MAX = 0xffff
  1033. const m_VERSION = "1.15"
  1034. const m_WINT_MAX = "UINT32_MAX"
  1035. const m_WINT_MIN = 0
  1036. const m_WNOHANG = 1
  1037. const m_WORD_BIT = 32
  1038. const m_WUNTRACED = 2
  1039. const m_W_OK = 2
  1040. const m_XCB_ACCESS = 10
  1041. const m_XCB_ALLOC = 11
  1042. const m_XCB_ALLOC_COLOR = 84
  1043. const m_XCB_ALLOC_COLOR_CELLS = 86
  1044. const m_XCB_ALLOC_COLOR_PLANES = 87
  1045. const m_XCB_ALLOC_NAMED_COLOR = 85
  1046. const m_XCB_ALLOW_EVENTS = 35
  1047. const m_XCB_ATOM = 5
  1048. const m_XCB_BELL = 104
  1049. const m_XCB_BIGREQUESTS_MAJOR_VERSION = 0
  1050. const m_XCB_BIGREQUESTS_MINOR_VERSION = 0
  1051. const m_XCB_BIG_REQUESTS_ENABLE = 0
  1052. const m_XCB_BUTTON_PRESS = 4
  1053. const m_XCB_BUTTON_RELEASE = 5
  1054. const m_XCB_CHANGE_ACTIVE_POINTER_GRAB = 30
  1055. const m_XCB_CHANGE_GC = 56
  1056. const m_XCB_CHANGE_HOSTS = 109
  1057. const m_XCB_CHANGE_KEYBOARD_CONTROL = 102
  1058. const m_XCB_CHANGE_KEYBOARD_MAPPING = 100
  1059. const m_XCB_CHANGE_POINTER_CONTROL = 105
  1060. const m_XCB_CHANGE_PROPERTY = 18
  1061. const m_XCB_CHANGE_SAVE_SET = 6
  1062. const m_XCB_CHANGE_WINDOW_ATTRIBUTES = 2
  1063. const m_XCB_CIRCULATE_NOTIFY = 26
  1064. const m_XCB_CIRCULATE_REQUEST = 27
  1065. const m_XCB_CIRCULATE_WINDOW = 13
  1066. const m_XCB_CLEAR_AREA = 61
  1067. const m_XCB_CLIENT_MESSAGE = 33
  1068. const m_XCB_CLOSE_FONT = 46
  1069. const m_XCB_COLORMAP = 12
  1070. const m_XCB_COLORMAP_NOTIFY = 32
  1071. const m_XCB_CONFIGURE_NOTIFY = 22
  1072. const m_XCB_CONFIGURE_REQUEST = 23
  1073. const m_XCB_CONFIGURE_WINDOW = 12
  1074. const m_XCB_CONN_CLOSED_EXT_NOTSUPPORTED = 2
  1075. const m_XCB_CONN_CLOSED_FDPASSING_FAILED = 7
  1076. const m_XCB_CONN_CLOSED_INVALID_SCREEN = 6
  1077. const m_XCB_CONN_CLOSED_MEM_INSUFFICIENT = 3
  1078. const m_XCB_CONN_CLOSED_PARSE_ERR = 5
  1079. const m_XCB_CONN_CLOSED_REQ_LEN_EXCEED = 4
  1080. const m_XCB_CONN_ERROR = 1
  1081. const m_XCB_CONVERT_SELECTION = 24
  1082. const m_XCB_COPY_AREA = 62
  1083. const m_XCB_COPY_COLORMAP_AND_FREE = 80
  1084. const m_XCB_COPY_FROM_PARENT = 0
  1085. const m_XCB_COPY_GC = 57
  1086. const m_XCB_COPY_PLANE = 63
  1087. const m_XCB_CREATE_COLORMAP = 78
  1088. const m_XCB_CREATE_CURSOR = 93
  1089. const m_XCB_CREATE_GC = 55
  1090. const m_XCB_CREATE_GLYPH_CURSOR = 94
  1091. const m_XCB_CREATE_NOTIFY = 16
  1092. const m_XCB_CREATE_PIXMAP = 53
  1093. const m_XCB_CREATE_WINDOW = 1
  1094. const m_XCB_CURRENT_TIME = 0
  1095. const m_XCB_CURSOR = 6
  1096. const m_XCB_DELETE_PROPERTY = 19
  1097. const m_XCB_DESTROY_NOTIFY = 17
  1098. const m_XCB_DESTROY_SUBWINDOWS = 5
  1099. const m_XCB_DESTROY_WINDOW = 4
  1100. const m_XCB_DRAWABLE = 9
  1101. const m_XCB_ENTER_NOTIFY = 7
  1102. const m_XCB_EXPOSE = 12
  1103. const m_XCB_FILL_POLY = 69
  1104. const m_XCB_FOCUS_IN = 9
  1105. const m_XCB_FOCUS_OUT = 10
  1106. const m_XCB_FONT = 7
  1107. const m_XCB_FORCE_SCREEN_SAVER = 115
  1108. const m_XCB_FREE_COLORMAP = 79
  1109. const m_XCB_FREE_COLORS = 88
  1110. const m_XCB_FREE_CURSOR = 95
  1111. const m_XCB_FREE_GC = 60
  1112. const m_XCB_FREE_PIXMAP = 54
  1113. const m_XCB_GET_ATOM_NAME = 17
  1114. const m_XCB_GET_FONT_PATH = 52
  1115. const m_XCB_GET_GEOMETRY = 14
  1116. const m_XCB_GET_IMAGE = 73
  1117. const m_XCB_GET_INPUT_FOCUS = 43
  1118. const m_XCB_GET_KEYBOARD_CONTROL = 103
  1119. const m_XCB_GET_KEYBOARD_MAPPING = 101
  1120. const m_XCB_GET_MODIFIER_MAPPING = 119
  1121. const m_XCB_GET_MOTION_EVENTS = 39
  1122. const m_XCB_GET_POINTER_CONTROL = 106
  1123. const m_XCB_GET_POINTER_MAPPING = 117
  1124. const m_XCB_GET_PROPERTY = 20
  1125. const m_XCB_GET_SCREEN_SAVER = 108
  1126. const m_XCB_GET_SELECTION_OWNER = 23
  1127. const m_XCB_GET_WINDOW_ATTRIBUTES = 3
  1128. const m_XCB_GE_GENERIC = 35
  1129. const m_XCB_GRAB_BUTTON = 28
  1130. const m_XCB_GRAB_KEY = 33
  1131. const m_XCB_GRAB_KEYBOARD = 31
  1132. const m_XCB_GRAB_POINTER = 26
  1133. const m_XCB_GRAB_SERVER = 36
  1134. const m_XCB_GRAPHICS_EXPOSURE = 13
  1135. const m_XCB_GRAVITY_NOTIFY = 24
  1136. const m_XCB_G_CONTEXT = 13
  1137. const m_XCB_ID_CHOICE = 14
  1138. const m_XCB_IMAGE_TEXT_16 = 77
  1139. const m_XCB_IMAGE_TEXT_8 = 76
  1140. const m_XCB_IMPLEMENTATION = 17
  1141. const m_XCB_INSTALL_COLORMAP = 81
  1142. const m_XCB_INTERN_ATOM = 16
  1143. const m_XCB_KEYMAP_NOTIFY = 11
  1144. const m_XCB_KEY_PRESS = 2
  1145. const m_XCB_KEY_RELEASE = 3
  1146. const m_XCB_KILL_CLIENT = 113
  1147. const m_XCB_LEAVE_NOTIFY = 8
  1148. const m_XCB_LENGTH = 16
  1149. const m_XCB_LIST_EXTENSIONS = 99
  1150. const m_XCB_LIST_FONTS = 49
  1151. const m_XCB_LIST_FONTS_WITH_INFO = 50
  1152. const m_XCB_LIST_HOSTS = 110
  1153. const m_XCB_LIST_INSTALLED_COLORMAPS = 83
  1154. const m_XCB_LIST_PROPERTIES = 21
  1155. const m_XCB_LOOKUP_COLOR = 92
  1156. const m_XCB_MAPPING_NOTIFY = 34
  1157. const m_XCB_MAP_NOTIFY = 19
  1158. const m_XCB_MAP_REQUEST = 20
  1159. const m_XCB_MAP_SUBWINDOWS = 9
  1160. const m_XCB_MAP_WINDOW = 8
  1161. const m_XCB_MATCH = 8
  1162. const m_XCB_MAX_PASS_FD = 16
  1163. const m_XCB_MOTION_NOTIFY = 6
  1164. const m_XCB_NAME = 15
  1165. const m_XCB_NONE = 0
  1166. const m_XCB_NO_EXPOSURE = 14
  1167. const m_XCB_NO_OPERATION = 127
  1168. const m_XCB_NO_SYMBOL = 0
  1169. const m_XCB_OPEN_FONT = 45
  1170. const m_XCB_PIXMAP = 4
  1171. const m_XCB_POLY_ARC = 68
  1172. const m_XCB_POLY_FILL_ARC = 71
  1173. const m_XCB_POLY_FILL_RECTANGLE = 70
  1174. const m_XCB_POLY_LINE = 65
  1175. const m_XCB_POLY_POINT = 64
  1176. const m_XCB_POLY_RECTANGLE = 67
  1177. const m_XCB_POLY_SEGMENT = 66
  1178. const m_XCB_POLY_TEXT_16 = 75
  1179. const m_XCB_POLY_TEXT_8 = 74
  1180. const m_XCB_PROPERTY_NOTIFY = 28
  1181. const m_XCB_PUT_IMAGE = 72
  1182. const m_XCB_QUERY_BEST_SIZE = 97
  1183. const m_XCB_QUERY_COLORS = 91
  1184. const m_XCB_QUERY_EXTENSION = 98
  1185. const m_XCB_QUERY_FONT = 47
  1186. const m_XCB_QUERY_KEYMAP = 44
  1187. const m_XCB_QUERY_POINTER = 38
  1188. const m_XCB_QUERY_TEXT_EXTENTS = 48
  1189. const m_XCB_QUERY_TREE = 15
  1190. const m_XCB_QUEUE_BUFFER_SIZE = 16384
  1191. const m_XCB_RECOLOR_CURSOR = 96
  1192. const m_XCB_REPARENT_NOTIFY = 21
  1193. const m_XCB_REPARENT_WINDOW = 7
  1194. const m_XCB_REQUEST = 1
  1195. const m_XCB_RESIZE_REQUEST = 25
  1196. const m_XCB_ROTATE_PROPERTIES = 114
  1197. const m_XCB_SELECTION_CLEAR = 29
  1198. const m_XCB_SELECTION_NOTIFY = 31
  1199. const m_XCB_SELECTION_REQUEST = 30
  1200. const m_XCB_SEND_EVENT = 25
  1201. const m_XCB_SET_ACCESS_CONTROL = 111
  1202. const m_XCB_SET_CLIP_RECTANGLES = 59
  1203. const m_XCB_SET_CLOSE_DOWN_MODE = 112
  1204. const m_XCB_SET_DASHES = 58
  1205. const m_XCB_SET_FONT_PATH = 51
  1206. const m_XCB_SET_INPUT_FOCUS = 42
  1207. const m_XCB_SET_MODIFIER_MAPPING = 118
  1208. const m_XCB_SET_POINTER_MAPPING = 116
  1209. const m_XCB_SET_SCREEN_SAVER = 107
  1210. const m_XCB_SET_SELECTION_OWNER = 22
  1211. const m_XCB_STORE_COLORS = 89
  1212. const m_XCB_STORE_NAMED_COLOR = 90
  1213. const m_XCB_TRANSLATE_COORDINATES = 40
  1214. const m_XCB_UNGRAB_BUTTON = 29
  1215. const m_XCB_UNGRAB_KEY = 34
  1216. const m_XCB_UNGRAB_KEYBOARD = 32
  1217. const m_XCB_UNGRAB_POINTER = 27
  1218. const m_XCB_UNGRAB_SERVER = 37
  1219. const m_XCB_UNINSTALL_COLORMAP = 82
  1220. const m_XCB_UNMAP_NOTIFY = 18
  1221. const m_XCB_UNMAP_SUBWINDOWS = 11
  1222. const m_XCB_UNMAP_WINDOW = 10
  1223. const m_XCB_VALUE = 2
  1224. const m_XCB_VISIBILITY_NOTIFY = 15
  1225. const m_XCB_WARP_POINTER = 41
  1226. const m_XCB_WINDOW = 3
  1227. const m_X_OK = 1
  1228. const m_X_PROTOCOL = 11
  1229. const m_X_PROTOCOL_REVISION = 0
  1230. const m_X_TCP_PORT = 6000
  1231. const m__ALL_SOURCE = 1
  1232. const m__CS_GNU_LIBC_VERSION = 2
  1233. const m__CS_GNU_LIBPTHREAD_VERSION = 3
  1234. const m__CS_PATH = 0
  1235. const m__CS_POSIX_V5_WIDTH_RESTRICTED_ENVS = 4
  1236. const m__CS_POSIX_V6_ILP32_OFF32_CFLAGS = 1116
  1237. const m__CS_POSIX_V6_ILP32_OFF32_LDFLAGS = 1117
  1238. const m__CS_POSIX_V6_ILP32_OFF32_LIBS = 1118
  1239. const m__CS_POSIX_V6_ILP32_OFF32_LINTFLAGS = 1119
  1240. const m__CS_POSIX_V6_ILP32_OFFBIG_CFLAGS = 1120
  1241. const m__CS_POSIX_V6_ILP32_OFFBIG_LDFLAGS = 1121
  1242. const m__CS_POSIX_V6_ILP32_OFFBIG_LIBS = 1122
  1243. const m__CS_POSIX_V6_ILP32_OFFBIG_LINTFLAGS = 1123
  1244. const m__CS_POSIX_V6_LP64_OFF64_CFLAGS = 1124
  1245. const m__CS_POSIX_V6_LP64_OFF64_LDFLAGS = 1125
  1246. const m__CS_POSIX_V6_LP64_OFF64_LIBS = 1126
  1247. const m__CS_POSIX_V6_LP64_OFF64_LINTFLAGS = 1127
  1248. const m__CS_POSIX_V6_LPBIG_OFFBIG_CFLAGS = 1128
  1249. const m__CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS = 1129
  1250. const m__CS_POSIX_V6_LPBIG_OFFBIG_LIBS = 1130
  1251. const m__CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS = 1131
  1252. const m__CS_POSIX_V6_WIDTH_RESTRICTED_ENVS = 1
  1253. const m__CS_POSIX_V7_ILP32_OFF32_CFLAGS = 1132
  1254. const m__CS_POSIX_V7_ILP32_OFF32_LDFLAGS = 1133
  1255. const m__CS_POSIX_V7_ILP32_OFF32_LIBS = 1134
  1256. const m__CS_POSIX_V7_ILP32_OFF32_LINTFLAGS = 1135
  1257. const m__CS_POSIX_V7_ILP32_OFFBIG_CFLAGS = 1136
  1258. const m__CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS = 1137
  1259. const m__CS_POSIX_V7_ILP32_OFFBIG_LIBS = 1138
  1260. const m__CS_POSIX_V7_ILP32_OFFBIG_LINTFLAGS = 1139
  1261. const m__CS_POSIX_V7_LP64_OFF64_CFLAGS = 1140
  1262. const m__CS_POSIX_V7_LP64_OFF64_LDFLAGS = 1141
  1263. const m__CS_POSIX_V7_LP64_OFF64_LIBS = 1142
  1264. const m__CS_POSIX_V7_LP64_OFF64_LINTFLAGS = 1143
  1265. const m__CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS = 1144
  1266. const m__CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS = 1145
  1267. const m__CS_POSIX_V7_LPBIG_OFFBIG_LIBS = 1146
  1268. const m__CS_POSIX_V7_LPBIG_OFFBIG_LINTFLAGS = 1147
  1269. const m__CS_POSIX_V7_THREADS_CFLAGS = 1150
  1270. const m__CS_POSIX_V7_THREADS_LDFLAGS = 1151
  1271. const m__CS_POSIX_V7_WIDTH_RESTRICTED_ENVS = 5
  1272. const m__CS_V6_ENV = 1148
  1273. const m__CS_V7_ENV = 1149
  1274. const m__DARWIN_C_SOURCE = 1
  1275. const m__GNU_SOURCE = 1
  1276. const m__HPUX_ALT_XOPEN_SOCKET_API = 1
  1277. const m__IOFBF = 0
  1278. const m__IOLBF = 1
  1279. const m__IONBF = 2
  1280. const m__LP64 = 1
  1281. const m__NETBSD_SOURCE = 1
  1282. const m__OPENBSD_SOURCE = 1
  1283. const m__PC_2_SYMLINKS = 20
  1284. const m__PC_ALLOC_SIZE_MIN = 18
  1285. const m__PC_ASYNC_IO = 10
  1286. const m__PC_CHOWN_RESTRICTED = 6
  1287. const m__PC_FILESIZEBITS = 13
  1288. const m__PC_LINK_MAX = 0
  1289. const m__PC_MAX_CANON = 1
  1290. const m__PC_MAX_INPUT = 2
  1291. const m__PC_NAME_MAX = 3
  1292. const m__PC_NO_TRUNC = 7
  1293. const m__PC_PATH_MAX = 4
  1294. const m__PC_PIPE_BUF = 5
  1295. const m__PC_PRIO_IO = 11
  1296. const m__PC_REC_INCR_XFER_SIZE = 14
  1297. const m__PC_REC_MAX_XFER_SIZE = 15
  1298. const m__PC_REC_MIN_XFER_SIZE = 16
  1299. const m__PC_REC_XFER_ALIGN = 17
  1300. const m__PC_SOCK_MAXBUF = 12
  1301. const m__PC_SYMLINK_MAX = 19
  1302. const m__PC_SYNC_IO = 9
  1303. const m__PC_VDISABLE = 8
  1304. const m__POSIX2_BC_BASE_MAX = 99
  1305. const m__POSIX2_BC_DIM_MAX = 2048
  1306. const m__POSIX2_BC_SCALE_MAX = 99
  1307. const m__POSIX2_BC_STRING_MAX = 1000
  1308. const m__POSIX2_CHARCLASS_NAME_MAX = 14
  1309. const m__POSIX2_COLL_WEIGHTS_MAX = 2
  1310. const m__POSIX2_C_BIND = "_POSIX_VERSION"
  1311. const m__POSIX2_EXPR_NEST_MAX = 32
  1312. const m__POSIX2_LINE_MAX = 2048
  1313. const m__POSIX2_RE_DUP_MAX = 255
  1314. const m__POSIX2_VERSION = "_POSIX_VERSION"
  1315. const m__POSIX_ADVISORY_INFO = "_POSIX_VERSION"
  1316. const m__POSIX_AIO_LISTIO_MAX = 2
  1317. const m__POSIX_AIO_MAX = 1
  1318. const m__POSIX_ARG_MAX = 4096
  1319. const m__POSIX_ASYNCHRONOUS_IO = "_POSIX_VERSION"
  1320. const m__POSIX_BARRIERS = "_POSIX_VERSION"
  1321. const m__POSIX_CHILD_MAX = 25
  1322. const m__POSIX_CHOWN_RESTRICTED = 1
  1323. const m__POSIX_CLOCKRES_MIN = 20000000
  1324. const m__POSIX_CLOCK_SELECTION = "_POSIX_VERSION"
  1325. const m__POSIX_CPUTIME = "_POSIX_VERSION"
  1326. const m__POSIX_DELAYTIMER_MAX = 32
  1327. const m__POSIX_FSYNC = "_POSIX_VERSION"
  1328. const m__POSIX_HOST_NAME_MAX = 255
  1329. const m__POSIX_IPV6 = "_POSIX_VERSION"
  1330. const m__POSIX_JOB_CONTROL = 1
  1331. const m__POSIX_LINK_MAX = 8
  1332. const m__POSIX_LOGIN_NAME_MAX = 9
  1333. const m__POSIX_MAPPED_FILES = "_POSIX_VERSION"
  1334. const m__POSIX_MAX_CANON = 255
  1335. const m__POSIX_MAX_INPUT = 255
  1336. const m__POSIX_MEMLOCK = "_POSIX_VERSION"
  1337. const m__POSIX_MEMLOCK_RANGE = "_POSIX_VERSION"
  1338. const m__POSIX_MEMORY_PROTECTION = "_POSIX_VERSION"
  1339. const m__POSIX_MESSAGE_PASSING = "_POSIX_VERSION"
  1340. const m__POSIX_MONOTONIC_CLOCK = "_POSIX_VERSION"
  1341. const m__POSIX_MQ_OPEN_MAX = 8
  1342. const m__POSIX_MQ_PRIO_MAX = 32
  1343. const m__POSIX_NAME_MAX = 14
  1344. const m__POSIX_NGROUPS_MAX = 8
  1345. const m__POSIX_NO_TRUNC = 1
  1346. const m__POSIX_OPEN_MAX = 20
  1347. const m__POSIX_PATH_MAX = 256
  1348. const m__POSIX_PIPE_BUF = 512
  1349. const m__POSIX_PTHREAD_SEMANTICS = 1
  1350. const m__POSIX_RAW_SOCKETS = "_POSIX_VERSION"
  1351. const m__POSIX_READER_WRITER_LOCKS = "_POSIX_VERSION"
  1352. const m__POSIX_REALTIME_SIGNALS = "_POSIX_VERSION"
  1353. const m__POSIX_REGEXP = 1
  1354. const m__POSIX_RE_DUP_MAX = 255
  1355. const m__POSIX_RTSIG_MAX = 8
  1356. const m__POSIX_SAVED_IDS = 1
  1357. const m__POSIX_SEMAPHORES = "_POSIX_VERSION"
  1358. const m__POSIX_SEM_NSEMS_MAX = 256
  1359. const m__POSIX_SEM_VALUE_MAX = 32767
  1360. const m__POSIX_SHARED_MEMORY_OBJECTS = "_POSIX_VERSION"
  1361. const m__POSIX_SHELL = 1
  1362. const m__POSIX_SIGQUEUE_MAX = 32
  1363. const m__POSIX_SPAWN = "_POSIX_VERSION"
  1364. const m__POSIX_SPIN_LOCKS = "_POSIX_VERSION"
  1365. const m__POSIX_SSIZE_MAX = 32767
  1366. const m__POSIX_SS_REPL_MAX = 4
  1367. const m__POSIX_STREAM_MAX = 8
  1368. const m__POSIX_SYMLINK_MAX = 255
  1369. const m__POSIX_SYMLOOP_MAX = 8
  1370. const m__POSIX_THREADS = "_POSIX_VERSION"
  1371. const m__POSIX_THREAD_ATTR_STACKADDR = "_POSIX_VERSION"
  1372. const m__POSIX_THREAD_ATTR_STACKSIZE = "_POSIX_VERSION"
  1373. const m__POSIX_THREAD_CPUTIME = "_POSIX_VERSION"
  1374. const m__POSIX_THREAD_DESTRUCTOR_ITERATIONS = 4
  1375. const m__POSIX_THREAD_KEYS_MAX = 128
  1376. const m__POSIX_THREAD_PRIORITY_SCHEDULING = "_POSIX_VERSION"
  1377. const m__POSIX_THREAD_PROCESS_SHARED = "_POSIX_VERSION"
  1378. const m__POSIX_THREAD_SAFE_FUNCTIONS = "_POSIX_VERSION"
  1379. const m__POSIX_THREAD_THREADS_MAX = 64
  1380. const m__POSIX_TIMEOUTS = "_POSIX_VERSION"
  1381. const m__POSIX_TIMERS = "_POSIX_VERSION"
  1382. const m__POSIX_TIMER_MAX = 32
  1383. const m__POSIX_TRACE_EVENT_NAME_MAX = 30
  1384. const m__POSIX_TRACE_NAME_MAX = 8
  1385. const m__POSIX_TRACE_SYS_MAX = 8
  1386. const m__POSIX_TRACE_USER_EVENT_MAX = 32
  1387. const m__POSIX_TTY_NAME_MAX = 9
  1388. const m__POSIX_TZNAME_MAX = 6
  1389. const m__POSIX_V6_LP64_OFF64 = 1
  1390. const m__POSIX_V7_LP64_OFF64 = 1
  1391. const m__POSIX_VDISABLE = 0
  1392. const m__POSIX_VERSION = 200809
  1393. const m__SC_2_CHAR_TERM = 95
  1394. const m__SC_2_C_BIND = 47
  1395. const m__SC_2_C_DEV = 48
  1396. const m__SC_2_FORT_DEV = 49
  1397. const m__SC_2_FORT_RUN = 50
  1398. const m__SC_2_LOCALEDEF = 52
  1399. const m__SC_2_PBS = 168
  1400. const m__SC_2_PBS_ACCOUNTING = 169
  1401. const m__SC_2_PBS_CHECKPOINT = 175
  1402. const m__SC_2_PBS_LOCATE = 170
  1403. const m__SC_2_PBS_MESSAGE = 171
  1404. const m__SC_2_PBS_TRACK = 172
  1405. const m__SC_2_SW_DEV = 51
  1406. const m__SC_2_UPE = 97
  1407. const m__SC_2_VERSION = 46
  1408. const m__SC_ADVISORY_INFO = 132
  1409. const m__SC_AIO_LISTIO_MAX = 23
  1410. const m__SC_AIO_MAX = 24
  1411. const m__SC_AIO_PRIO_DELTA_MAX = 25
  1412. const m__SC_ARG_MAX = 0
  1413. const m__SC_ASYNCHRONOUS_IO = 12
  1414. const m__SC_ATEXIT_MAX = 87
  1415. const m__SC_AVPHYS_PAGES = 86
  1416. const m__SC_BARRIERS = 133
  1417. const m__SC_BC_BASE_MAX = 36
  1418. const m__SC_BC_DIM_MAX = 37
  1419. const m__SC_BC_SCALE_MAX = 38
  1420. const m__SC_BC_STRING_MAX = 39
  1421. const m__SC_CHILD_MAX = 1
  1422. const m__SC_CLK_TCK = 2
  1423. const m__SC_CLOCK_SELECTION = 137
  1424. const m__SC_COLL_WEIGHTS_MAX = 40
  1425. const m__SC_CPUTIME = 138
  1426. const m__SC_DELAYTIMER_MAX = 26
  1427. const m__SC_EXPR_NEST_MAX = 42
  1428. const m__SC_FSYNC = 15
  1429. const m__SC_GETGR_R_SIZE_MAX = 69
  1430. const m__SC_GETPW_R_SIZE_MAX = 70
  1431. const m__SC_HOST_NAME_MAX = 180
  1432. const m__SC_IOV_MAX = 60
  1433. const m__SC_IPV6 = 235
  1434. const m__SC_JOB_CONTROL = 7
  1435. const m__SC_LINE_MAX = 43
  1436. const m__SC_LOGIN_NAME_MAX = 71
  1437. const m__SC_MAPPED_FILES = 16
  1438. const m__SC_MEMLOCK = 17
  1439. const m__SC_MEMLOCK_RANGE = 18
  1440. const m__SC_MEMORY_PROTECTION = 19
  1441. const m__SC_MESSAGE_PASSING = 20
  1442. const m__SC_MINSIGSTKSZ = 249
  1443. const m__SC_MONOTONIC_CLOCK = 149
  1444. const m__SC_MQ_OPEN_MAX = 27
  1445. const m__SC_MQ_PRIO_MAX = 28
  1446. const m__SC_NGROUPS_MAX = 3
  1447. const m__SC_NPROCESSORS_CONF = 83
  1448. const m__SC_NPROCESSORS_ONLN = 84
  1449. const m__SC_NZERO = 109
  1450. const m__SC_OPEN_MAX = 4
  1451. const m__SC_PAGESIZE = 30
  1452. const m__SC_PAGE_SIZE = 30
  1453. const m__SC_PASS_MAX = 88
  1454. const m__SC_PHYS_PAGES = 85
  1455. const m__SC_PRIORITIZED_IO = 13
  1456. const m__SC_PRIORITY_SCHEDULING = 10
  1457. const m__SC_RAW_SOCKETS = 236
  1458. const m__SC_READER_WRITER_LOCKS = 153
  1459. const m__SC_REALTIME_SIGNALS = 9
  1460. const m__SC_REGEXP = 155
  1461. const m__SC_RE_DUP_MAX = 44
  1462. const m__SC_RTSIG_MAX = 31
  1463. const m__SC_SAVED_IDS = 8
  1464. const m__SC_SEMAPHORES = 21
  1465. const m__SC_SEM_NSEMS_MAX = 32
  1466. const m__SC_SEM_VALUE_MAX = 33
  1467. const m__SC_SHARED_MEMORY_OBJECTS = 22
  1468. const m__SC_SHELL = 157
  1469. const m__SC_SIGQUEUE_MAX = 34
  1470. const m__SC_SIGSTKSZ = 250
  1471. const m__SC_SPAWN = 159
  1472. const m__SC_SPIN_LOCKS = 154
  1473. const m__SC_SPORADIC_SERVER = 160
  1474. const m__SC_SS_REPL_MAX = 241
  1475. const m__SC_STREAMS = 174
  1476. const m__SC_STREAM_MAX = 5
  1477. const m__SC_SYMLOOP_MAX = 173
  1478. const m__SC_SYNCHRONIZED_IO = 14
  1479. const m__SC_THREADS = 67
  1480. const m__SC_THREAD_ATTR_STACKADDR = 77
  1481. const m__SC_THREAD_ATTR_STACKSIZE = 78
  1482. const m__SC_THREAD_CPUTIME = 139
  1483. const m__SC_THREAD_DESTRUCTOR_ITERATIONS = 73
  1484. const m__SC_THREAD_KEYS_MAX = 74
  1485. const m__SC_THREAD_PRIORITY_SCHEDULING = 79
  1486. const m__SC_THREAD_PRIO_INHERIT = 80
  1487. const m__SC_THREAD_PRIO_PROTECT = 81
  1488. const m__SC_THREAD_PROCESS_SHARED = 82
  1489. const m__SC_THREAD_ROBUST_PRIO_INHERIT = 247
  1490. const m__SC_THREAD_ROBUST_PRIO_PROTECT = 248
  1491. const m__SC_THREAD_SAFE_FUNCTIONS = 68
  1492. const m__SC_THREAD_SPORADIC_SERVER = 161
  1493. const m__SC_THREAD_STACK_MIN = 75
  1494. const m__SC_THREAD_THREADS_MAX = 76
  1495. const m__SC_TIMEOUTS = 164
  1496. const m__SC_TIMERS = 11
  1497. const m__SC_TIMER_MAX = 35
  1498. const m__SC_TRACE = 181
  1499. const m__SC_TRACE_EVENT_FILTER = 182
  1500. const m__SC_TRACE_EVENT_NAME_MAX = 242
  1501. const m__SC_TRACE_INHERIT = 183
  1502. const m__SC_TRACE_LOG = 184
  1503. const m__SC_TRACE_NAME_MAX = 243
  1504. const m__SC_TRACE_SYS_MAX = 244
  1505. const m__SC_TRACE_USER_EVENT_MAX = 245
  1506. const m__SC_TTY_NAME_MAX = 72
  1507. const m__SC_TYPED_MEMORY_OBJECTS = 165
  1508. const m__SC_TZNAME_MAX = 6
  1509. const m__SC_UIO_MAXIOV = 60
  1510. const m__SC_V6_ILP32_OFF32 = 176
  1511. const m__SC_V6_ILP32_OFFBIG = 177
  1512. const m__SC_V6_LP64_OFF64 = 178
  1513. const m__SC_V6_LPBIG_OFFBIG = 179
  1514. const m__SC_V7_ILP32_OFF32 = 237
  1515. const m__SC_V7_ILP32_OFFBIG = 238
  1516. const m__SC_V7_LP64_OFF64 = 239
  1517. const m__SC_V7_LPBIG_OFFBIG = 240
  1518. const m__SC_VERSION = 29
  1519. const m__SC_XBS5_ILP32_OFF32 = 125
  1520. const m__SC_XBS5_ILP32_OFFBIG = 126
  1521. const m__SC_XBS5_LP64_OFF64 = 127
  1522. const m__SC_XBS5_LPBIG_OFFBIG = 128
  1523. const m__SC_XOPEN_CRYPT = 92
  1524. const m__SC_XOPEN_ENH_I18N = 93
  1525. const m__SC_XOPEN_LEGACY = 129
  1526. const m__SC_XOPEN_REALTIME = 130
  1527. const m__SC_XOPEN_REALTIME_THREADS = 131
  1528. const m__SC_XOPEN_SHM = 94
  1529. const m__SC_XOPEN_STREAMS = 246
  1530. const m__SC_XOPEN_UNIX = 91
  1531. const m__SC_XOPEN_VERSION = 89
  1532. const m__SC_XOPEN_XCU_VERSION = 90
  1533. const m__SC_XOPEN_XPG2 = 98
  1534. const m__SC_XOPEN_XPG3 = 99
  1535. const m__SC_XOPEN_XPG4 = 100
  1536. const m__STDC_PREDEF_H = 1
  1537. const m__TANDEM_SOURCE = 1
  1538. const m__XOPEN_ENH_I18N = 1
  1539. const m__XOPEN_IOV_MAX = 16
  1540. const m__XOPEN_NAME_MAX = 255
  1541. const m__XOPEN_PATH_MAX = 1024
  1542. const m__XOPEN_UNIX = 1
  1543. const m__XOPEN_VERSION = 700
  1544. const m___ATOMIC_ACQUIRE = 2
  1545. const m___ATOMIC_ACQ_REL = 4
  1546. const m___ATOMIC_CONSUME = 1
  1547. const m___ATOMIC_HLE_ACQUIRE = 65536
  1548. const m___ATOMIC_HLE_RELEASE = 131072
  1549. const m___ATOMIC_RELAXED = 0
  1550. const m___ATOMIC_RELEASE = 3
  1551. const m___ATOMIC_SEQ_CST = 5
  1552. const m___BIGGEST_ALIGNMENT__ = 16
  1553. const m___BIG_ENDIAN = 4321
  1554. const m___BYTE_ORDER = 1234
  1555. const m___BYTE_ORDER__ = "__ORDER_LITTLE_ENDIAN__"
  1556. const m___CCGO__ = 1
  1557. const m___CHAR_BIT__ = 8
  1558. const m___DBL_DECIMAL_DIG__ = 17
  1559. const m___DBL_DIG__ = 15
  1560. const m___DBL_HAS_DENORM__ = 1
  1561. const m___DBL_HAS_INFINITY__ = 1
  1562. const m___DBL_HAS_QUIET_NAN__ = 1
  1563. const m___DBL_IS_IEC_60559__ = 2
  1564. const m___DBL_MANT_DIG__ = 53
  1565. const m___DBL_MAX_10_EXP__ = 308
  1566. const m___DBL_MAX_EXP__ = 1024
  1567. const m___DEC128_EPSILON__ = 1e-33
  1568. const m___DEC128_MANT_DIG__ = 34
  1569. const m___DEC128_MAX_EXP__ = 6145
  1570. const m___DEC128_MAX__ = "9.999999999999999999999999999999999E6144"
  1571. const m___DEC128_MIN__ = 1e-6143
  1572. const m___DEC128_SUBNORMAL_MIN__ = 0.000000000000000000000000000000001e-6143
  1573. const m___DEC32_EPSILON__ = 1e-6
  1574. const m___DEC32_MANT_DIG__ = 7
  1575. const m___DEC32_MAX_EXP__ = 97
  1576. const m___DEC32_MAX__ = 9.999999e96
  1577. const m___DEC32_MIN__ = 1e-95
  1578. const m___DEC32_SUBNORMAL_MIN__ = 0.000001e-95
  1579. const m___DEC64_EPSILON__ = 1e-15
  1580. const m___DEC64_MANT_DIG__ = 16
  1581. const m___DEC64_MAX_EXP__ = 385
  1582. const m___DEC64_MAX__ = "9.999999999999999E384"
  1583. const m___DEC64_MIN__ = 1e-383
  1584. const m___DEC64_SUBNORMAL_MIN__ = 0.000000000000001e-383
  1585. const m___DECIMAL_BID_FORMAT__ = 1
  1586. const m___DECIMAL_DIG__ = 17
  1587. const m___DEC_EVAL_METHOD__ = 2
  1588. const m___ELF__ = 1
  1589. const m___EXTENSIONS__ = 1
  1590. const m___FINITE_MATH_ONLY__ = 0
  1591. const m___FLOAT_WORD_ORDER__ = "__ORDER_LITTLE_ENDIAN__"
  1592. const m___FLT128_DECIMAL_DIG__ = 36
  1593. const m___FLT128_DENORM_MIN__ = 6.47517511943802511092443895822764655e-4966
  1594. const m___FLT128_DIG__ = 33
  1595. const m___FLT128_EPSILON__ = 1.92592994438723585305597794258492732e-34
  1596. const m___FLT128_HAS_DENORM__ = 1
  1597. const m___FLT128_HAS_INFINITY__ = 1
  1598. const m___FLT128_HAS_QUIET_NAN__ = 1
  1599. const m___FLT128_IS_IEC_60559__ = 2
  1600. const m___FLT128_MANT_DIG__ = 113
  1601. const m___FLT128_MAX_10_EXP__ = 4932
  1602. const m___FLT128_MAX_EXP__ = 16384
  1603. const m___FLT128_MAX__ = "1.18973149535723176508575932662800702e+4932"
  1604. const m___FLT128_MIN__ = 3.36210314311209350626267781732175260e-4932
  1605. const m___FLT128_NORM_MAX__ = "1.18973149535723176508575932662800702e+4932"
  1606. const m___FLT16_DECIMAL_DIG__ = 5
  1607. const m___FLT16_DENORM_MIN__ = 5.96046447753906250000000000000000000e-8
  1608. const m___FLT16_DIG__ = 3
  1609. const m___FLT16_EPSILON__ = 9.76562500000000000000000000000000000e-4
  1610. const m___FLT16_HAS_DENORM__ = 1
  1611. const m___FLT16_HAS_INFINITY__ = 1
  1612. const m___FLT16_HAS_QUIET_NAN__ = 1
  1613. const m___FLT16_IS_IEC_60559__ = 2
  1614. const m___FLT16_MANT_DIG__ = 11
  1615. const m___FLT16_MAX_10_EXP__ = 4
  1616. const m___FLT16_MAX_EXP__ = 16
  1617. const m___FLT16_MAX__ = 6.55040000000000000000000000000000000e+4
  1618. const m___FLT16_MIN__ = 6.10351562500000000000000000000000000e-5
  1619. const m___FLT16_NORM_MAX__ = 6.55040000000000000000000000000000000e+4
  1620. const m___FLT32X_DECIMAL_DIG__ = 17
  1621. const m___FLT32X_DENORM_MIN__ = 4.94065645841246544176568792868221372e-324
  1622. const m___FLT32X_DIG__ = 15
  1623. const m___FLT32X_EPSILON__ = 2.22044604925031308084726333618164062e-16
  1624. const m___FLT32X_HAS_DENORM__ = 1
  1625. const m___FLT32X_HAS_INFINITY__ = 1
  1626. const m___FLT32X_HAS_QUIET_NAN__ = 1
  1627. const m___FLT32X_IS_IEC_60559__ = 2
  1628. const m___FLT32X_MANT_DIG__ = 53
  1629. const m___FLT32X_MAX_10_EXP__ = 308
  1630. const m___FLT32X_MAX_EXP__ = 1024
  1631. const m___FLT32X_MAX__ = 1.79769313486231570814527423731704357e+308
  1632. const m___FLT32X_MIN__ = 2.22507385850720138309023271733240406e-308
  1633. const m___FLT32X_NORM_MAX__ = 1.79769313486231570814527423731704357e+308
  1634. const m___FLT32_DECIMAL_DIG__ = 9
  1635. const m___FLT32_DENORM_MIN__ = 1.40129846432481707092372958328991613e-45
  1636. const m___FLT32_DIG__ = 6
  1637. const m___FLT32_EPSILON__ = 1.19209289550781250000000000000000000e-7
  1638. const m___FLT32_HAS_DENORM__ = 1
  1639. const m___FLT32_HAS_INFINITY__ = 1
  1640. const m___FLT32_HAS_QUIET_NAN__ = 1
  1641. const m___FLT32_IS_IEC_60559__ = 2
  1642. const m___FLT32_MANT_DIG__ = 24
  1643. const m___FLT32_MAX_10_EXP__ = 38
  1644. const m___FLT32_MAX_EXP__ = 128
  1645. const m___FLT32_MAX__ = 3.40282346638528859811704183484516925e+38
  1646. const m___FLT32_MIN__ = 1.17549435082228750796873653722224568e-38
  1647. const m___FLT32_NORM_MAX__ = 3.40282346638528859811704183484516925e+38
  1648. const m___FLT64X_DECIMAL_DIG__ = 36
  1649. const m___FLT64X_DENORM_MIN__ = 6.47517511943802511092443895822764655e-4966
  1650. const m___FLT64X_DIG__ = 33
  1651. const m___FLT64X_EPSILON__ = 1.92592994438723585305597794258492732e-34
  1652. const m___FLT64X_HAS_DENORM__ = 1
  1653. const m___FLT64X_HAS_INFINITY__ = 1
  1654. const m___FLT64X_HAS_QUIET_NAN__ = 1
  1655. const m___FLT64X_IS_IEC_60559__ = 2
  1656. const m___FLT64X_MANT_DIG__ = 113
  1657. const m___FLT64X_MAX_10_EXP__ = 4932
  1658. const m___FLT64X_MAX_EXP__ = 16384
  1659. const m___FLT64X_MAX__ = "1.18973149535723176508575932662800702e+4932"
  1660. const m___FLT64X_MIN__ = 3.36210314311209350626267781732175260e-4932
  1661. const m___FLT64X_NORM_MAX__ = "1.18973149535723176508575932662800702e+4932"
  1662. const m___FLT64_DECIMAL_DIG__ = 17
  1663. const m___FLT64_DENORM_MIN__ = 4.94065645841246544176568792868221372e-324
  1664. const m___FLT64_DIG__ = 15
  1665. const m___FLT64_EPSILON__ = 2.22044604925031308084726333618164062e-16
  1666. const m___FLT64_HAS_DENORM__ = 1
  1667. const m___FLT64_HAS_INFINITY__ = 1
  1668. const m___FLT64_HAS_QUIET_NAN__ = 1
  1669. const m___FLT64_IS_IEC_60559__ = 2
  1670. const m___FLT64_MANT_DIG__ = 53
  1671. const m___FLT64_MAX_10_EXP__ = 308
  1672. const m___FLT64_MAX_EXP__ = 1024
  1673. const m___FLT64_MAX__ = 1.79769313486231570814527423731704357e+308
  1674. const m___FLT64_MIN__ = 2.22507385850720138309023271733240406e-308
  1675. const m___FLT64_NORM_MAX__ = 1.79769313486231570814527423731704357e+308
  1676. const m___FLT_DECIMAL_DIG__ = 9
  1677. const m___FLT_DENORM_MIN__ = 1.40129846432481707092372958328991613e-45
  1678. const m___FLT_DIG__ = 6
  1679. const m___FLT_EPSILON__ = 1.19209289550781250000000000000000000e-7
  1680. const m___FLT_EVAL_METHOD_TS_18661_3__ = 0
  1681. const m___FLT_EVAL_METHOD__ = 0
  1682. const m___FLT_HAS_DENORM__ = 1
  1683. const m___FLT_HAS_INFINITY__ = 1
  1684. const m___FLT_HAS_QUIET_NAN__ = 1
  1685. const m___FLT_IS_IEC_60559__ = 2
  1686. const m___FLT_MANT_DIG__ = 24
  1687. const m___FLT_MAX_10_EXP__ = 38
  1688. const m___FLT_MAX_EXP__ = 128
  1689. const m___FLT_MAX__ = 3.40282346638528859811704183484516925e+38
  1690. const m___FLT_MIN__ = 1.17549435082228750796873653722224568e-38
  1691. const m___FLT_NORM_MAX__ = 3.40282346638528859811704183484516925e+38
  1692. const m___FLT_RADIX__ = 2
  1693. const m___FUNCTION__ = "__func__"
  1694. const m___FXSR__ = 1
  1695. const m___GCC_ASM_FLAG_OUTPUTS__ = 1
  1696. const m___GCC_ATOMIC_BOOL_LOCK_FREE = 2
  1697. const m___GCC_ATOMIC_CHAR16_T_LOCK_FREE = 2
  1698. const m___GCC_ATOMIC_CHAR32_T_LOCK_FREE = 2
  1699. const m___GCC_ATOMIC_CHAR_LOCK_FREE = 2
  1700. const m___GCC_ATOMIC_INT_LOCK_FREE = 2
  1701. const m___GCC_ATOMIC_LLONG_LOCK_FREE = 2
  1702. const m___GCC_ATOMIC_LONG_LOCK_FREE = 2
  1703. const m___GCC_ATOMIC_POINTER_LOCK_FREE = 2
  1704. const m___GCC_ATOMIC_SHORT_LOCK_FREE = 2
  1705. const m___GCC_ATOMIC_TEST_AND_SET_TRUEVAL = 1
  1706. const m___GCC_ATOMIC_WCHAR_T_LOCK_FREE = 2
  1707. const m___GCC_CONSTRUCTIVE_SIZE = 64
  1708. const m___GCC_DESTRUCTIVE_SIZE = 64
  1709. const m___GCC_HAVE_DWARF2_CFI_ASM = 1
  1710. const m___GCC_HAVE_SYNC_COMPARE_AND_SWAP_1 = 1
  1711. const m___GCC_HAVE_SYNC_COMPARE_AND_SWAP_2 = 1
  1712. const m___GCC_HAVE_SYNC_COMPARE_AND_SWAP_4 = 1
  1713. const m___GCC_HAVE_SYNC_COMPARE_AND_SWAP_8 = 1
  1714. const m___GCC_IEC_559 = 2
  1715. const m___GCC_IEC_559_COMPLEX = 2
  1716. const m___GNUC_EXECUTION_CHARSET_NAME = "UTF-8"
  1717. const m___GNUC_MINOR__ = 2
  1718. const m___GNUC_PATCHLEVEL__ = 0
  1719. const m___GNUC_STDC_INLINE__ = 1
  1720. const m___GNUC_WIDE_EXECUTION_CHARSET_NAME = "UTF-32LE"
  1721. const m___GNUC__ = 12
  1722. const m___GXX_ABI_VERSION = 1017
  1723. const m___HAVE_SPECULATION_SAFE_VALUE = 1
  1724. const m___INT16_MAX__ = 0x7fff
  1725. const m___INT32_MAX__ = 0x7fffffff
  1726. const m___INT32_TYPE__ = "int"
  1727. const m___INT64_MAX__ = 0x7fffffffffffffff
  1728. const m___INT8_MAX__ = 0x7f
  1729. const m___INTMAX_MAX__ = 0x7fffffffffffffff
  1730. const m___INTMAX_WIDTH__ = 64
  1731. const m___INTPTR_MAX__ = 0x7fffffffffffffff
  1732. const m___INTPTR_WIDTH__ = 64
  1733. const m___INT_FAST16_MAX__ = 0x7fffffffffffffff
  1734. const m___INT_FAST16_WIDTH__ = 64
  1735. const m___INT_FAST32_MAX__ = 0x7fffffffffffffff
  1736. const m___INT_FAST32_WIDTH__ = 64
  1737. const m___INT_FAST64_MAX__ = 0x7fffffffffffffff
  1738. const m___INT_FAST64_WIDTH__ = 64
  1739. const m___INT_FAST8_MAX__ = 0x7f
  1740. const m___INT_FAST8_WIDTH__ = 8
  1741. const m___INT_LEAST16_MAX__ = 0x7fff
  1742. const m___INT_LEAST16_WIDTH__ = 16
  1743. const m___INT_LEAST32_MAX__ = 0x7fffffff
  1744. const m___INT_LEAST32_TYPE__ = "int"
  1745. const m___INT_LEAST32_WIDTH__ = 32
  1746. const m___INT_LEAST64_MAX__ = 0x7fffffffffffffff
  1747. const m___INT_LEAST64_WIDTH__ = 64
  1748. const m___INT_LEAST8_MAX__ = 0x7f
  1749. const m___INT_LEAST8_WIDTH__ = 8
  1750. const m___INT_MAX__ = 0x7fffffff
  1751. const m___INT_WIDTH__ = 32
  1752. const m___LDBL_DECIMAL_DIG__ = 17
  1753. const m___LDBL_DENORM_MIN__ = 4.94065645841246544176568792868221372e-324
  1754. const m___LDBL_DIG__ = 15
  1755. const m___LDBL_EPSILON__ = 2.22044604925031308084726333618164062e-16
  1756. const m___LDBL_HAS_DENORM__ = 1
  1757. const m___LDBL_HAS_INFINITY__ = 1
  1758. const m___LDBL_HAS_QUIET_NAN__ = 1
  1759. const m___LDBL_IS_IEC_60559__ = 2
  1760. const m___LDBL_MANT_DIG__ = 53
  1761. const m___LDBL_MAX_10_EXP__ = 308
  1762. const m___LDBL_MAX_EXP__ = 1024
  1763. const m___LDBL_MAX__ = 1.79769313486231570814527423731704357e+308
  1764. const m___LDBL_MIN__ = 2.22507385850720138309023271733240406e-308
  1765. const m___LDBL_NORM_MAX__ = 1.79769313486231570814527423731704357e+308
  1766. const m___LITTLE_ENDIAN = 1234
  1767. const m___LONG_DOUBLE_64__ = 1
  1768. const m___LONG_LONG_MAX__ = 0x7fffffffffffffff
  1769. const m___LONG_LONG_WIDTH__ = 64
  1770. const m___LONG_MAX = 0x7fffffffffffffff
  1771. const m___LONG_MAX__ = 0x7fffffffffffffff
  1772. const m___LONG_WIDTH__ = 64
  1773. const m___LP64__ = 1
  1774. const m___MMX_WITH_SSE__ = 1
  1775. const m___MMX__ = 1
  1776. const m___NO_INLINE__ = 1
  1777. const m___ORDER_BIG_ENDIAN__ = 4321
  1778. const m___ORDER_LITTLE_ENDIAN__ = 1234
  1779. const m___ORDER_PDP_ENDIAN__ = 3412
  1780. const m___PDP_ENDIAN = 3412
  1781. const m___PIC__ = 2
  1782. const m___PIE__ = 2
  1783. const m___PRAGMA_REDEFINE_EXTNAME = 1
  1784. const m___PRETTY_FUNCTION__ = "__func__"
  1785. const m___PRI64 = "l"
  1786. const m___PRIPTR = "l"
  1787. const m___PTRDIFF_MAX__ = 0x7fffffffffffffff
  1788. const m___PTRDIFF_WIDTH__ = 64
  1789. const m___SCHAR_MAX__ = 0x7f
  1790. const m___SCHAR_WIDTH__ = 8
  1791. const m___SEG_FS = 1
  1792. const m___SEG_GS = 1
  1793. const m___SHRT_MAX__ = 0x7fff
  1794. const m___SHRT_WIDTH__ = 16
  1795. const m___SIG_ATOMIC_MAX__ = 0x7fffffff
  1796. const m___SIG_ATOMIC_TYPE__ = "int"
  1797. const m___SIG_ATOMIC_WIDTH__ = 32
  1798. const m___SIZEOF_DOUBLE__ = 8
  1799. const m___SIZEOF_FLOAT128__ = 16
  1800. const m___SIZEOF_FLOAT80__ = 16
  1801. const m___SIZEOF_FLOAT__ = 4
  1802. const m___SIZEOF_INT128__ = 16
  1803. const m___SIZEOF_INT__ = 4
  1804. const m___SIZEOF_LONG_DOUBLE__ = 8
  1805. const m___SIZEOF_LONG_LONG__ = 8
  1806. const m___SIZEOF_LONG__ = 8
  1807. const m___SIZEOF_POINTER__ = 8
  1808. const m___SIZEOF_PTRDIFF_T__ = 8
  1809. const m___SIZEOF_SHORT__ = 2
  1810. const m___SIZEOF_SIZE_T__ = 8
  1811. const m___SIZEOF_WCHAR_T__ = 4
  1812. const m___SIZEOF_WINT_T__ = 4
  1813. const m___SIZE_MAX__ = 0xffffffffffffffff
  1814. const m___SIZE_WIDTH__ = 64
  1815. const m___SSE2_MATH__ = 1
  1816. const m___SSE2__ = 1
  1817. const m___SSE_MATH__ = 1
  1818. const m___SSE__ = 1
  1819. const m___STDC_HOSTED__ = 1
  1820. const m___STDC_IEC_559_COMPLEX__ = 1
  1821. const m___STDC_IEC_559__ = 1
  1822. const m___STDC_IEC_60559_BFP__ = 201404
  1823. const m___STDC_IEC_60559_COMPLEX__ = 201404
  1824. const m___STDC_ISO_10646__ = 201706
  1825. const m___STDC_UTF_16__ = 1
  1826. const m___STDC_UTF_32__ = 1
  1827. const m___STDC_VERSION__ = 201710
  1828. const m___STDC_WANT_IEC_60559_ATTRIBS_EXT__ = 1
  1829. const m___STDC_WANT_IEC_60559_BFP_EXT__ = 1
  1830. const m___STDC_WANT_IEC_60559_DFP_EXT__ = 1
  1831. const m___STDC_WANT_IEC_60559_FUNCS_EXT__ = 1
  1832. const m___STDC_WANT_IEC_60559_TYPES_EXT__ = 1
  1833. const m___STDC_WANT_LIB_EXT2__ = 1
  1834. const m___STDC_WANT_MATH_SPEC_FUNCS__ = 1
  1835. const m___STDC__ = 1
  1836. const m___UAPI_DEF_IN6_ADDR = 0
  1837. const m___UAPI_DEF_IN6_ADDR_ALT = 0
  1838. const m___UAPI_DEF_IN6_PKTINFO = 0
  1839. const m___UAPI_DEF_IN_ADDR = 0
  1840. const m___UAPI_DEF_IN_CLASS = 0
  1841. const m___UAPI_DEF_IN_IPPROTO = 0
  1842. const m___UAPI_DEF_IN_PKTINFO = 0
  1843. const m___UAPI_DEF_IP6_MTUINFO = 0
  1844. const m___UAPI_DEF_IPPROTO_V6 = 0
  1845. const m___UAPI_DEF_IPV6_MREQ = 0
  1846. const m___UAPI_DEF_IPV6_OPTIONS = 0
  1847. const m___UAPI_DEF_IP_MREQ = 0
  1848. const m___UAPI_DEF_SOCKADDR_IN = 0
  1849. const m___UAPI_DEF_SOCKADDR_IN6 = 0
  1850. const m___UINT16_MAX__ = 0xffff
  1851. const m___UINT32_MAX__ = 0xffffffff
  1852. const m___UINT64_MAX__ = 0xffffffffffffffff
  1853. const m___UINT8_MAX__ = 0xff
  1854. const m___UINTMAX_MAX__ = 0xffffffffffffffff
  1855. const m___UINTPTR_MAX__ = 0xffffffffffffffff
  1856. const m___UINT_FAST16_MAX__ = 0xffffffffffffffff
  1857. const m___UINT_FAST32_MAX__ = 0xffffffffffffffff
  1858. const m___UINT_FAST64_MAX__ = 0xffffffffffffffff
  1859. const m___UINT_FAST8_MAX__ = 0xff
  1860. const m___UINT_LEAST16_MAX__ = 0xffff
  1861. const m___UINT_LEAST32_MAX__ = 0xffffffff
  1862. const m___UINT_LEAST64_MAX__ = 0xffffffffffffffff
  1863. const m___UINT_LEAST8_MAX__ = 0xff
  1864. const m___USE_TIME_BITS64 = 1
  1865. const m___VERSION__ = "12.2.0"
  1866. const m___WCHAR_MAX__ = 0x7fffffff
  1867. const m___WCHAR_TYPE__ = "int"
  1868. const m___WCHAR_WIDTH__ = 32
  1869. const m___WINT_MAX__ = 0xffffffff
  1870. const m___WINT_MIN__ = 0
  1871. const m___WINT_WIDTH__ = 32
  1872. const m___amd64 = 1
  1873. const m___amd64__ = 1
  1874. const m___code_model_small__ = 1
  1875. const m___gnu_linux__ = 1
  1876. const m___inline = "inline"
  1877. const m___k8 = 1
  1878. const m___k8__ = 1
  1879. const m___linux = 1
  1880. const m___linux__ = 1
  1881. const m___pic__ = 2
  1882. const m___pie__ = 2
  1883. const m___restrict = "restrict"
  1884. const m___restrict_arr = "restrict"
  1885. const m___tm_gmtoff = "tm_gmtoff"
  1886. const m___tm_zone = "tm_zone"
  1887. const m___unix = 1
  1888. const m___unix__ = 1
  1889. const m___x86_64 = 1
  1890. const m___x86_64__ = 1
  1891. const m_alloca = "__builtin_alloca"
  1892. const m_linux = 1
  1893. const m_loff_t = "off_t"
  1894. const m_static_assert = "_Static_assert"
  1895. const m_unix = 1
  1896. type t__builtin_va_list = uintptr
  1897. type t__predefined_size_t = uint64
  1898. type t__predefined_wchar_t = int32
  1899. type t__predefined_ptrdiff_t = int64
  1900. type Tsize_t = uint64
  1901. type Tlocale_t = uintptr
  1902. type Tssize_t = int64
  1903. type Toff_t = int64
  1904. type Tva_list = uintptr
  1905. type t__isoc_va_list = uintptr
  1906. type Tfpos_t = struct {
  1907. F__lldata [0]int64
  1908. F__align [0]float64
  1909. F__opaque [16]int8
  1910. }
  1911. type T_G_fpos64_t = Tfpos_t
  1912. type Tcookie_io_functions_t = struct {
  1913. Fread uintptr
  1914. Fwrite uintptr
  1915. Fseek uintptr
  1916. Fclose1 uintptr
  1917. }
  1918. type T_IO_cookie_io_functions_t = Tcookie_io_functions_t
  1919. type Twchar_t = int32
  1920. type Tdiv_t = struct {
  1921. Fquot int32
  1922. Frem int32
  1923. }
  1924. type Tldiv_t = struct {
  1925. Fquot int64
  1926. Frem int64
  1927. }
  1928. type Tlldiv_t = struct {
  1929. Fquot int64
  1930. Frem int64
  1931. }
  1932. type Tmode_t = uint32
  1933. type Tpid_t = int32
  1934. type Tiovec = struct {
  1935. Fiov_base uintptr
  1936. Fiov_len Tsize_t
  1937. }
  1938. type Tflock = struct {
  1939. Fl_type int16
  1940. Fl_whence int16
  1941. Fl_start Toff_t
  1942. Fl_len Toff_t
  1943. Fl_pid Tpid_t
  1944. }
  1945. type Tfile_handle = struct {
  1946. Fhandle_bytes uint32
  1947. Fhandle_type int32
  1948. }
  1949. type Tf_owner_ex = struct {
  1950. Ftype1 int32
  1951. Fpid Tpid_t
  1952. }
  1953. type Tregister_t = int64
  1954. type Ttime_t = int64
  1955. type Tsuseconds_t = int64
  1956. type Tint8_t = int8
  1957. type Tint16_t = int16
  1958. type Tint32_t = int32
  1959. type Tint64_t = int64
  1960. type Tu_int64_t = uint64
  1961. type Tnlink_t = uint64
  1962. type Tino_t = uint64
  1963. type Tdev_t = uint64
  1964. type Tblksize_t = int64
  1965. type Tblkcnt_t = int64
  1966. type Tfsblkcnt_t = uint64
  1967. type Tfsfilcnt_t = uint64
  1968. type Ttimer_t = uintptr
  1969. type Tclockid_t = int32
  1970. type Tclock_t = int64
  1971. type Tid_t = uint32
  1972. type Tuid_t = uint32
  1973. type Tgid_t = uint32
  1974. type Tkey_t = int32
  1975. type Tuseconds_t = uint32
  1976. type Tpthread_t = uintptr
  1977. type Tpthread_once_t = int32
  1978. type Tpthread_key_t = uint32
  1979. type Tpthread_spinlock_t = int32
  1980. type Tpthread_mutexattr_t = struct {
  1981. F__attr uint32
  1982. }
  1983. type Tpthread_condattr_t = struct {
  1984. F__attr uint32
  1985. }
  1986. type Tpthread_barrierattr_t = struct {
  1987. F__attr uint32
  1988. }
  1989. type Tpthread_rwlockattr_t = struct {
  1990. F__attr [2]uint32
  1991. }
  1992. type Tpthread_attr_t = struct {
  1993. F__u struct {
  1994. F__vi [0][14]int32
  1995. F__s [0][7]uint64
  1996. F__i [14]int32
  1997. }
  1998. }
  1999. type Tpthread_mutex_t = struct {
  2000. F__u struct {
  2001. F__vi [0][10]int32
  2002. F__p [0][5]uintptr
  2003. F__i [10]int32
  2004. }
  2005. }
  2006. type Tpthread_cond_t = struct {
  2007. F__u struct {
  2008. F__vi [0][12]int32
  2009. F__p [0][6]uintptr
  2010. F__i [12]int32
  2011. }
  2012. }
  2013. type Tpthread_rwlock_t = struct {
  2014. F__u struct {
  2015. F__vi [0][14]int32
  2016. F__p [0][7]uintptr
  2017. F__i [14]int32
  2018. }
  2019. }
  2020. type Tpthread_barrier_t = struct {
  2021. F__u struct {
  2022. F__vi [0][8]int32
  2023. F__p [0][4]uintptr
  2024. F__i [8]int32
  2025. }
  2026. }
  2027. type Tu_int8_t = uint8
  2028. type Tu_int16_t = uint16
  2029. type Tu_int32_t = uint32
  2030. type Tcaddr_t = uintptr
  2031. type Tu_char = uint8
  2032. type Tu_short = uint16
  2033. type Tushort = uint16
  2034. type Tu_int = uint32
  2035. type Tuint = uint32
  2036. type Tu_long = uint64
  2037. type Tulong = uint64
  2038. type Tquad_t = int64
  2039. type Tu_quad_t = uint64
  2040. type Tuint16_t = uint16
  2041. type Tuint32_t = uint32
  2042. type Tuint64_t = uint64
  2043. type Ttimeval = struct {
  2044. Ftv_sec Ttime_t
  2045. Ftv_usec Tsuseconds_t
  2046. }
  2047. type Ttimespec = struct {
  2048. Ftv_sec Ttime_t
  2049. Ftv_nsec int64
  2050. }
  2051. type Tsigset_t = struct {
  2052. F__bits [16]uint64
  2053. }
  2054. type t__sigset_t = Tsigset_t
  2055. type Tfd_mask = uint64
  2056. type Tfd_set = struct {
  2057. Ffds_bits [16]uint64
  2058. }
  2059. type Tuintptr_t = uint64
  2060. type Tintptr_t = int64
  2061. type Tintmax_t = int64
  2062. type Tuint8_t = uint8
  2063. type Tuintmax_t = uint64
  2064. type Tint_fast8_t = int8
  2065. type Tint_fast64_t = int64
  2066. type Tint_least8_t = int8
  2067. type Tint_least16_t = int16
  2068. type Tint_least32_t = int32
  2069. type Tint_least64_t = int64
  2070. type Tuint_fast8_t = uint8
  2071. type Tuint_fast64_t = uint64
  2072. type Tuint_least8_t = uint8
  2073. type Tuint_least16_t = uint16
  2074. type Tuint_least32_t = uint32
  2075. type Tuint_least64_t = uint64
  2076. type Tint_fast16_t = int32
  2077. type Tint_fast32_t = int32
  2078. type Tuint_fast16_t = uint32
  2079. type Tuint_fast32_t = uint32
  2080. type Tsched_param = struct {
  2081. Fsched_priority int32
  2082. F__reserved1 int32
  2083. F__reserved2 [2]struct {
  2084. F__reserved1 Ttime_t
  2085. F__reserved2 int64
  2086. }
  2087. F__reserved3 int32
  2088. }
  2089. type Tcpu_set_t = struct {
  2090. F__bits [16]uint64
  2091. }
  2092. type Ttm = struct {
  2093. Ftm_sec int32
  2094. Ftm_min int32
  2095. Ftm_hour int32
  2096. Ftm_mday int32
  2097. Ftm_mon int32
  2098. Ftm_year int32
  2099. Ftm_wday int32
  2100. Ftm_yday int32
  2101. Ftm_isdst int32
  2102. Ftm_gmtoff int64
  2103. Ftm_zone uintptr
  2104. }
  2105. type Titimerspec = struct {
  2106. Fit_interval Ttimespec
  2107. Fit_value Ttimespec
  2108. }
  2109. type t__ptcb = struct {
  2110. F__f uintptr
  2111. F__x uintptr
  2112. F__next uintptr
  2113. }
  2114. type Tcpu_set_t1 = struct {
  2115. F__bits [16]uint64
  2116. }
  2117. type Txcb_connection_t = struct {
  2118. Fhas_error int32
  2119. Fsetup uintptr
  2120. Ffd int32
  2121. Fiolock Tpthread_mutex_t
  2122. Fin T_xcb_in
  2123. Fout T_xcb_out
  2124. Fext T_xcb_ext
  2125. Fxid T_xcb_xid
  2126. }
  2127. type Txcb_generic_iterator_t = struct {
  2128. Fdata uintptr
  2129. Frem int32
  2130. Findex int32
  2131. }
  2132. type Txcb_generic_reply_t = struct {
  2133. Fresponse_type Tuint8_t
  2134. Fpad0 Tuint8_t
  2135. Fsequence Tuint16_t
  2136. Flength Tuint32_t
  2137. }
  2138. type Txcb_generic_event_t = struct {
  2139. Fresponse_type Tuint8_t
  2140. Fpad0 Tuint8_t
  2141. Fsequence Tuint16_t
  2142. Fpad [7]Tuint32_t
  2143. Ffull_sequence Tuint32_t
  2144. }
  2145. type Txcb_raw_generic_event_t = struct {
  2146. Fresponse_type Tuint8_t
  2147. Fpad0 Tuint8_t
  2148. Fsequence Tuint16_t
  2149. Fpad [7]Tuint32_t
  2150. }
  2151. type Txcb_ge_event_t = struct {
  2152. Fresponse_type Tuint8_t
  2153. Fpad0 Tuint8_t
  2154. Fsequence Tuint16_t
  2155. Flength Tuint32_t
  2156. Fevent_type Tuint16_t
  2157. Fpad1 Tuint16_t
  2158. Fpad [5]Tuint32_t
  2159. Ffull_sequence Tuint32_t
  2160. }
  2161. type Txcb_generic_error_t = struct {
  2162. Fresponse_type Tuint8_t
  2163. Ferror_code Tuint8_t
  2164. Fsequence Tuint16_t
  2165. Fresource_id Tuint32_t
  2166. Fminor_code Tuint16_t
  2167. Fmajor_code Tuint8_t
  2168. Fpad0 Tuint8_t
  2169. Fpad [5]Tuint32_t
  2170. Ffull_sequence Tuint32_t
  2171. }
  2172. type Txcb_void_cookie_t = struct {
  2173. Fsequence uint32
  2174. }
  2175. type Txcb_char2b_t = struct {
  2176. Fbyte1 Tuint8_t
  2177. Fbyte2 Tuint8_t
  2178. }
  2179. type Txcb_char2b_iterator_t = struct {
  2180. Fdata uintptr
  2181. Frem int32
  2182. Findex int32
  2183. }
  2184. type Txcb_window_t = uint32
  2185. type Txcb_window_iterator_t = struct {
  2186. Fdata uintptr
  2187. Frem int32
  2188. Findex int32
  2189. }
  2190. type Txcb_pixmap_t = uint32
  2191. type Txcb_pixmap_iterator_t = struct {
  2192. Fdata uintptr
  2193. Frem int32
  2194. Findex int32
  2195. }
  2196. type Txcb_cursor_t = uint32
  2197. type Txcb_cursor_iterator_t = struct {
  2198. Fdata uintptr
  2199. Frem int32
  2200. Findex int32
  2201. }
  2202. type Txcb_font_t = uint32
  2203. type Txcb_font_iterator_t = struct {
  2204. Fdata uintptr
  2205. Frem int32
  2206. Findex int32
  2207. }
  2208. type Txcb_gcontext_t = uint32
  2209. type Txcb_gcontext_iterator_t = struct {
  2210. Fdata uintptr
  2211. Frem int32
  2212. Findex int32
  2213. }
  2214. type Txcb_colormap_t = uint32
  2215. type Txcb_colormap_iterator_t = struct {
  2216. Fdata uintptr
  2217. Frem int32
  2218. Findex int32
  2219. }
  2220. type Txcb_atom_t = uint32
  2221. type Txcb_atom_iterator_t = struct {
  2222. Fdata uintptr
  2223. Frem int32
  2224. Findex int32
  2225. }
  2226. type Txcb_drawable_t = uint32
  2227. type Txcb_drawable_iterator_t = struct {
  2228. Fdata uintptr
  2229. Frem int32
  2230. Findex int32
  2231. }
  2232. type Txcb_fontable_t = uint32
  2233. type Txcb_fontable_iterator_t = struct {
  2234. Fdata uintptr
  2235. Frem int32
  2236. Findex int32
  2237. }
  2238. type Txcb_bool32_t = uint32
  2239. type Txcb_bool32_iterator_t = struct {
  2240. Fdata uintptr
  2241. Frem int32
  2242. Findex int32
  2243. }
  2244. type Txcb_visualid_t = uint32
  2245. type Txcb_visualid_iterator_t = struct {
  2246. Fdata uintptr
  2247. Frem int32
  2248. Findex int32
  2249. }
  2250. type Txcb_timestamp_t = uint32
  2251. type Txcb_timestamp_iterator_t = struct {
  2252. Fdata uintptr
  2253. Frem int32
  2254. Findex int32
  2255. }
  2256. type Txcb_keysym_t = uint32
  2257. type Txcb_keysym_iterator_t = struct {
  2258. Fdata uintptr
  2259. Frem int32
  2260. Findex int32
  2261. }
  2262. type Txcb_keycode_t = uint8
  2263. type Txcb_keycode_iterator_t = struct {
  2264. Fdata uintptr
  2265. Frem int32
  2266. Findex int32
  2267. }
  2268. type Txcb_keycode32_t = uint32
  2269. type Txcb_keycode32_iterator_t = struct {
  2270. Fdata uintptr
  2271. Frem int32
  2272. Findex int32
  2273. }
  2274. type Txcb_button_t = uint8
  2275. type Txcb_button_iterator_t = struct {
  2276. Fdata uintptr
  2277. Frem int32
  2278. Findex int32
  2279. }
  2280. type Txcb_point_t = struct {
  2281. Fx Tint16_t
  2282. Fy Tint16_t
  2283. }
  2284. type Txcb_point_iterator_t = struct {
  2285. Fdata uintptr
  2286. Frem int32
  2287. Findex int32
  2288. }
  2289. type Txcb_rectangle_t = struct {
  2290. Fx Tint16_t
  2291. Fy Tint16_t
  2292. Fwidth Tuint16_t
  2293. Fheight Tuint16_t
  2294. }
  2295. type Txcb_rectangle_iterator_t = struct {
  2296. Fdata uintptr
  2297. Frem int32
  2298. Findex int32
  2299. }
  2300. type Txcb_arc_t = struct {
  2301. Fx Tint16_t
  2302. Fy Tint16_t
  2303. Fwidth Tuint16_t
  2304. Fheight Tuint16_t
  2305. Fangle1 Tint16_t
  2306. Fangle2 Tint16_t
  2307. }
  2308. type Txcb_arc_iterator_t = struct {
  2309. Fdata uintptr
  2310. Frem int32
  2311. Findex int32
  2312. }
  2313. type Txcb_format_t = struct {
  2314. Fdepth Tuint8_t
  2315. Fbits_per_pixel Tuint8_t
  2316. Fscanline_pad Tuint8_t
  2317. Fpad0 [5]Tuint8_t
  2318. }
  2319. type Txcb_format_iterator_t = struct {
  2320. Fdata uintptr
  2321. Frem int32
  2322. Findex int32
  2323. }
  2324. type Txcb_visual_class_t = int32
  2325. type _xcb_visual_class_t = int32
  2326. const _XCB_VISUAL_CLASS_STATIC_GRAY = 0
  2327. const _XCB_VISUAL_CLASS_GRAY_SCALE = 1
  2328. const _XCB_VISUAL_CLASS_STATIC_COLOR = 2
  2329. const _XCB_VISUAL_CLASS_PSEUDO_COLOR = 3
  2330. const _XCB_VISUAL_CLASS_TRUE_COLOR = 4
  2331. const _XCB_VISUAL_CLASS_DIRECT_COLOR = 5
  2332. type Txcb_visualtype_t = struct {
  2333. Fvisual_id Txcb_visualid_t
  2334. F_class Tuint8_t
  2335. Fbits_per_rgb_value Tuint8_t
  2336. Fcolormap_entries Tuint16_t
  2337. Fred_mask Tuint32_t
  2338. Fgreen_mask Tuint32_t
  2339. Fblue_mask Tuint32_t
  2340. Fpad0 [4]Tuint8_t
  2341. }
  2342. type Txcb_visualtype_iterator_t = struct {
  2343. Fdata uintptr
  2344. Frem int32
  2345. Findex int32
  2346. }
  2347. type Txcb_depth_t = struct {
  2348. Fdepth Tuint8_t
  2349. Fpad0 Tuint8_t
  2350. Fvisuals_len Tuint16_t
  2351. Fpad1 [4]Tuint8_t
  2352. }
  2353. type Txcb_depth_iterator_t = struct {
  2354. Fdata uintptr
  2355. Frem int32
  2356. Findex int32
  2357. }
  2358. type Txcb_event_mask_t = int32
  2359. type _xcb_event_mask_t = int32
  2360. const _XCB_EVENT_MASK_NO_EVENT = 0
  2361. const _XCB_EVENT_MASK_KEY_PRESS = 1
  2362. const _XCB_EVENT_MASK_KEY_RELEASE = 2
  2363. const _XCB_EVENT_MASK_BUTTON_PRESS = 4
  2364. const _XCB_EVENT_MASK_BUTTON_RELEASE = 8
  2365. const _XCB_EVENT_MASK_ENTER_WINDOW = 16
  2366. const _XCB_EVENT_MASK_LEAVE_WINDOW = 32
  2367. const _XCB_EVENT_MASK_POINTER_MOTION = 64
  2368. const _XCB_EVENT_MASK_POINTER_MOTION_HINT = 128
  2369. const _XCB_EVENT_MASK_BUTTON_1_MOTION = 256
  2370. const _XCB_EVENT_MASK_BUTTON_2_MOTION = 512
  2371. const _XCB_EVENT_MASK_BUTTON_3_MOTION = 1024
  2372. const _XCB_EVENT_MASK_BUTTON_4_MOTION = 2048
  2373. const _XCB_EVENT_MASK_BUTTON_5_MOTION = 4096
  2374. const _XCB_EVENT_MASK_BUTTON_MOTION = 8192
  2375. const _XCB_EVENT_MASK_KEYMAP_STATE = 16384
  2376. const _XCB_EVENT_MASK_EXPOSURE = 32768
  2377. const _XCB_EVENT_MASK_VISIBILITY_CHANGE = 65536
  2378. const _XCB_EVENT_MASK_STRUCTURE_NOTIFY = 131072
  2379. const _XCB_EVENT_MASK_RESIZE_REDIRECT = 262144
  2380. const _XCB_EVENT_MASK_SUBSTRUCTURE_NOTIFY = 524288
  2381. const _XCB_EVENT_MASK_SUBSTRUCTURE_REDIRECT = 1048576
  2382. const _XCB_EVENT_MASK_FOCUS_CHANGE = 2097152
  2383. const _XCB_EVENT_MASK_PROPERTY_CHANGE = 4194304
  2384. const _XCB_EVENT_MASK_COLOR_MAP_CHANGE = 8388608
  2385. const _XCB_EVENT_MASK_OWNER_GRAB_BUTTON = 16777216
  2386. type Txcb_backing_store_t = int32
  2387. type _xcb_backing_store_t = int32
  2388. const _XCB_BACKING_STORE_NOT_USEFUL = 0
  2389. const _XCB_BACKING_STORE_WHEN_MAPPED = 1
  2390. const _XCB_BACKING_STORE_ALWAYS = 2
  2391. type Txcb_screen_t = struct {
  2392. Froot Txcb_window_t
  2393. Fdefault_colormap Txcb_colormap_t
  2394. Fwhite_pixel Tuint32_t
  2395. Fblack_pixel Tuint32_t
  2396. Fcurrent_input_masks Tuint32_t
  2397. Fwidth_in_pixels Tuint16_t
  2398. Fheight_in_pixels Tuint16_t
  2399. Fwidth_in_millimeters Tuint16_t
  2400. Fheight_in_millimeters Tuint16_t
  2401. Fmin_installed_maps Tuint16_t
  2402. Fmax_installed_maps Tuint16_t
  2403. Froot_visual Txcb_visualid_t
  2404. Fbacking_stores Tuint8_t
  2405. Fsave_unders Tuint8_t
  2406. Froot_depth Tuint8_t
  2407. Fallowed_depths_len Tuint8_t
  2408. }
  2409. type Txcb_screen_iterator_t = struct {
  2410. Fdata uintptr
  2411. Frem int32
  2412. Findex int32
  2413. }
  2414. type Txcb_setup_request_t = struct {
  2415. Fbyte_order Tuint8_t
  2416. Fpad0 Tuint8_t
  2417. Fprotocol_major_version Tuint16_t
  2418. Fprotocol_minor_version Tuint16_t
  2419. Fauthorization_protocol_name_len Tuint16_t
  2420. Fauthorization_protocol_data_len Tuint16_t
  2421. Fpad1 [2]Tuint8_t
  2422. }
  2423. type Txcb_setup_request_iterator_t = struct {
  2424. Fdata uintptr
  2425. Frem int32
  2426. Findex int32
  2427. }
  2428. type Txcb_setup_failed_t = struct {
  2429. Fstatus Tuint8_t
  2430. Freason_len Tuint8_t
  2431. Fprotocol_major_version Tuint16_t
  2432. Fprotocol_minor_version Tuint16_t
  2433. Flength Tuint16_t
  2434. }
  2435. type Txcb_setup_failed_iterator_t = struct {
  2436. Fdata uintptr
  2437. Frem int32
  2438. Findex int32
  2439. }
  2440. type Txcb_setup_authenticate_t = struct {
  2441. Fstatus Tuint8_t
  2442. Fpad0 [5]Tuint8_t
  2443. Flength Tuint16_t
  2444. }
  2445. type Txcb_setup_authenticate_iterator_t = struct {
  2446. Fdata uintptr
  2447. Frem int32
  2448. Findex int32
  2449. }
  2450. type Txcb_image_order_t = int32
  2451. type _xcb_image_order_t = int32
  2452. const _XCB_IMAGE_ORDER_LSB_FIRST = 0
  2453. const _XCB_IMAGE_ORDER_MSB_FIRST = 1
  2454. type Txcb_setup_t = struct {
  2455. Fstatus Tuint8_t
  2456. Fpad0 Tuint8_t
  2457. Fprotocol_major_version Tuint16_t
  2458. Fprotocol_minor_version Tuint16_t
  2459. Flength Tuint16_t
  2460. Frelease_number Tuint32_t
  2461. Fresource_id_base Tuint32_t
  2462. Fresource_id_mask Tuint32_t
  2463. Fmotion_buffer_size Tuint32_t
  2464. Fvendor_len Tuint16_t
  2465. Fmaximum_request_length Tuint16_t
  2466. Froots_len Tuint8_t
  2467. Fpixmap_formats_len Tuint8_t
  2468. Fimage_byte_order Tuint8_t
  2469. Fbitmap_format_bit_order Tuint8_t
  2470. Fbitmap_format_scanline_unit Tuint8_t
  2471. Fbitmap_format_scanline_pad Tuint8_t
  2472. Fmin_keycode Txcb_keycode_t
  2473. Fmax_keycode Txcb_keycode_t
  2474. Fpad1 [4]Tuint8_t
  2475. }
  2476. type Txcb_setup_iterator_t = struct {
  2477. Fdata uintptr
  2478. Frem int32
  2479. Findex int32
  2480. }
  2481. type Txcb_mod_mask_t = int32
  2482. type _xcb_mod_mask_t = int32
  2483. const _XCB_MOD_MASK_SHIFT = 1
  2484. const _XCB_MOD_MASK_LOCK = 2
  2485. const _XCB_MOD_MASK_CONTROL = 4
  2486. const _XCB_MOD_MASK_1 = 8
  2487. const _XCB_MOD_MASK_2 = 16
  2488. const _XCB_MOD_MASK_3 = 32
  2489. const _XCB_MOD_MASK_4 = 64
  2490. const _XCB_MOD_MASK_5 = 128
  2491. const _XCB_MOD_MASK_ANY = 32768
  2492. type Txcb_key_but_mask_t = int32
  2493. type _xcb_key_but_mask_t = int32
  2494. const _XCB_KEY_BUT_MASK_SHIFT = 1
  2495. const _XCB_KEY_BUT_MASK_LOCK = 2
  2496. const _XCB_KEY_BUT_MASK_CONTROL = 4
  2497. const _XCB_KEY_BUT_MASK_MOD_1 = 8
  2498. const _XCB_KEY_BUT_MASK_MOD_2 = 16
  2499. const _XCB_KEY_BUT_MASK_MOD_3 = 32
  2500. const _XCB_KEY_BUT_MASK_MOD_4 = 64
  2501. const _XCB_KEY_BUT_MASK_MOD_5 = 128
  2502. const _XCB_KEY_BUT_MASK_BUTTON_1 = 256
  2503. const _XCB_KEY_BUT_MASK_BUTTON_2 = 512
  2504. const _XCB_KEY_BUT_MASK_BUTTON_3 = 1024
  2505. const _XCB_KEY_BUT_MASK_BUTTON_4 = 2048
  2506. const _XCB_KEY_BUT_MASK_BUTTON_5 = 4096
  2507. type Txcb_window_enum_t = int32
  2508. type _xcb_window_enum_t = int32
  2509. const _XCB_WINDOW_NONE = 0
  2510. type Txcb_key_press_event_t = struct {
  2511. Fresponse_type Tuint8_t
  2512. Fdetail Txcb_keycode_t
  2513. Fsequence Tuint16_t
  2514. Ftime Txcb_timestamp_t
  2515. Froot Txcb_window_t
  2516. Fevent Txcb_window_t
  2517. Fchild Txcb_window_t
  2518. Froot_x Tint16_t
  2519. Froot_y Tint16_t
  2520. Fevent_x Tint16_t
  2521. Fevent_y Tint16_t
  2522. Fstate Tuint16_t
  2523. Fsame_screen Tuint8_t
  2524. Fpad0 Tuint8_t
  2525. }
  2526. type Txcb_key_release_event_t = struct {
  2527. Fresponse_type Tuint8_t
  2528. Fdetail Txcb_keycode_t
  2529. Fsequence Tuint16_t
  2530. Ftime Txcb_timestamp_t
  2531. Froot Txcb_window_t
  2532. Fevent Txcb_window_t
  2533. Fchild Txcb_window_t
  2534. Froot_x Tint16_t
  2535. Froot_y Tint16_t
  2536. Fevent_x Tint16_t
  2537. Fevent_y Tint16_t
  2538. Fstate Tuint16_t
  2539. Fsame_screen Tuint8_t
  2540. Fpad0 Tuint8_t
  2541. }
  2542. type Txcb_key_press_event_t1 = Txcb_key_release_event_t
  2543. type Txcb_button_mask_t = int32
  2544. type _xcb_button_mask_t = int32
  2545. const _XCB_BUTTON_MASK_1 = 256
  2546. const _XCB_BUTTON_MASK_2 = 512
  2547. const _XCB_BUTTON_MASK_3 = 1024
  2548. const _XCB_BUTTON_MASK_4 = 2048
  2549. const _XCB_BUTTON_MASK_5 = 4096
  2550. const _XCB_BUTTON_MASK_ANY = 32768
  2551. type Txcb_button_press_event_t = struct {
  2552. Fresponse_type Tuint8_t
  2553. Fdetail Txcb_button_t
  2554. Fsequence Tuint16_t
  2555. Ftime Txcb_timestamp_t
  2556. Froot Txcb_window_t
  2557. Fevent Txcb_window_t
  2558. Fchild Txcb_window_t
  2559. Froot_x Tint16_t
  2560. Froot_y Tint16_t
  2561. Fevent_x Tint16_t
  2562. Fevent_y Tint16_t
  2563. Fstate Tuint16_t
  2564. Fsame_screen Tuint8_t
  2565. Fpad0 Tuint8_t
  2566. }
  2567. type Txcb_button_release_event_t = struct {
  2568. Fresponse_type Tuint8_t
  2569. Fdetail Txcb_button_t
  2570. Fsequence Tuint16_t
  2571. Ftime Txcb_timestamp_t
  2572. Froot Txcb_window_t
  2573. Fevent Txcb_window_t
  2574. Fchild Txcb_window_t
  2575. Froot_x Tint16_t
  2576. Froot_y Tint16_t
  2577. Fevent_x Tint16_t
  2578. Fevent_y Tint16_t
  2579. Fstate Tuint16_t
  2580. Fsame_screen Tuint8_t
  2581. Fpad0 Tuint8_t
  2582. }
  2583. type Txcb_button_press_event_t1 = Txcb_button_release_event_t
  2584. type Txcb_motion_t = int32
  2585. type _xcb_motion_t = int32
  2586. const _XCB_MOTION_NORMAL = 0
  2587. const _XCB_MOTION_HINT = 1
  2588. type Txcb_motion_notify_event_t = struct {
  2589. Fresponse_type Tuint8_t
  2590. Fdetail Tuint8_t
  2591. Fsequence Tuint16_t
  2592. Ftime Txcb_timestamp_t
  2593. Froot Txcb_window_t
  2594. Fevent Txcb_window_t
  2595. Fchild Txcb_window_t
  2596. Froot_x Tint16_t
  2597. Froot_y Tint16_t
  2598. Fevent_x Tint16_t
  2599. Fevent_y Tint16_t
  2600. Fstate Tuint16_t
  2601. Fsame_screen Tuint8_t
  2602. Fpad0 Tuint8_t
  2603. }
  2604. type Txcb_notify_detail_t = int32
  2605. type _xcb_notify_detail_t = int32
  2606. const _XCB_NOTIFY_DETAIL_ANCESTOR = 0
  2607. const _XCB_NOTIFY_DETAIL_VIRTUAL = 1
  2608. const _XCB_NOTIFY_DETAIL_INFERIOR = 2
  2609. const _XCB_NOTIFY_DETAIL_NONLINEAR = 3
  2610. const _XCB_NOTIFY_DETAIL_NONLINEAR_VIRTUAL = 4
  2611. const _XCB_NOTIFY_DETAIL_POINTER = 5
  2612. const _XCB_NOTIFY_DETAIL_POINTER_ROOT = 6
  2613. const _XCB_NOTIFY_DETAIL_NONE = 7
  2614. type Txcb_notify_mode_t = int32
  2615. type _xcb_notify_mode_t = int32
  2616. const _XCB_NOTIFY_MODE_NORMAL = 0
  2617. const _XCB_NOTIFY_MODE_GRAB = 1
  2618. const _XCB_NOTIFY_MODE_UNGRAB = 2
  2619. const _XCB_NOTIFY_MODE_WHILE_GRABBED = 3
  2620. type Txcb_enter_notify_event_t = struct {
  2621. Fresponse_type Tuint8_t
  2622. Fdetail Tuint8_t
  2623. Fsequence Tuint16_t
  2624. Ftime Txcb_timestamp_t
  2625. Froot Txcb_window_t
  2626. Fevent Txcb_window_t
  2627. Fchild Txcb_window_t
  2628. Froot_x Tint16_t
  2629. Froot_y Tint16_t
  2630. Fevent_x Tint16_t
  2631. Fevent_y Tint16_t
  2632. Fstate Tuint16_t
  2633. Fmode Tuint8_t
  2634. Fsame_screen_focus Tuint8_t
  2635. }
  2636. type Txcb_leave_notify_event_t = struct {
  2637. Fresponse_type Tuint8_t
  2638. Fdetail Tuint8_t
  2639. Fsequence Tuint16_t
  2640. Ftime Txcb_timestamp_t
  2641. Froot Txcb_window_t
  2642. Fevent Txcb_window_t
  2643. Fchild Txcb_window_t
  2644. Froot_x Tint16_t
  2645. Froot_y Tint16_t
  2646. Fevent_x Tint16_t
  2647. Fevent_y Tint16_t
  2648. Fstate Tuint16_t
  2649. Fmode Tuint8_t
  2650. Fsame_screen_focus Tuint8_t
  2651. }
  2652. type Txcb_enter_notify_event_t1 = Txcb_leave_notify_event_t
  2653. type Txcb_focus_in_event_t = struct {
  2654. Fresponse_type Tuint8_t
  2655. Fdetail Tuint8_t
  2656. Fsequence Tuint16_t
  2657. Fevent Txcb_window_t
  2658. Fmode Tuint8_t
  2659. Fpad0 [3]Tuint8_t
  2660. }
  2661. type Txcb_focus_out_event_t = struct {
  2662. Fresponse_type Tuint8_t
  2663. Fdetail Tuint8_t
  2664. Fsequence Tuint16_t
  2665. Fevent Txcb_window_t
  2666. Fmode Tuint8_t
  2667. Fpad0 [3]Tuint8_t
  2668. }
  2669. type Txcb_focus_in_event_t1 = Txcb_focus_out_event_t
  2670. type Txcb_keymap_notify_event_t = struct {
  2671. Fresponse_type Tuint8_t
  2672. Fkeys [31]Tuint8_t
  2673. }
  2674. type Txcb_expose_event_t = struct {
  2675. Fresponse_type Tuint8_t
  2676. Fpad0 Tuint8_t
  2677. Fsequence Tuint16_t
  2678. Fwindow Txcb_window_t
  2679. Fx Tuint16_t
  2680. Fy Tuint16_t
  2681. Fwidth Tuint16_t
  2682. Fheight Tuint16_t
  2683. Fcount Tuint16_t
  2684. Fpad1 [2]Tuint8_t
  2685. }
  2686. type Txcb_graphics_exposure_event_t = struct {
  2687. Fresponse_type Tuint8_t
  2688. Fpad0 Tuint8_t
  2689. Fsequence Tuint16_t
  2690. Fdrawable Txcb_drawable_t
  2691. Fx Tuint16_t
  2692. Fy Tuint16_t
  2693. Fwidth Tuint16_t
  2694. Fheight Tuint16_t
  2695. Fminor_opcode Tuint16_t
  2696. Fcount Tuint16_t
  2697. Fmajor_opcode Tuint8_t
  2698. Fpad1 [3]Tuint8_t
  2699. }
  2700. type Txcb_no_exposure_event_t = struct {
  2701. Fresponse_type Tuint8_t
  2702. Fpad0 Tuint8_t
  2703. Fsequence Tuint16_t
  2704. Fdrawable Txcb_drawable_t
  2705. Fminor_opcode Tuint16_t
  2706. Fmajor_opcode Tuint8_t
  2707. Fpad1 Tuint8_t
  2708. }
  2709. type Txcb_visibility_t = int32
  2710. type _xcb_visibility_t = int32
  2711. const _XCB_VISIBILITY_UNOBSCURED = 0
  2712. const _XCB_VISIBILITY_PARTIALLY_OBSCURED = 1
  2713. const _XCB_VISIBILITY_FULLY_OBSCURED = 2
  2714. type Txcb_visibility_notify_event_t = struct {
  2715. Fresponse_type Tuint8_t
  2716. Fpad0 Tuint8_t
  2717. Fsequence Tuint16_t
  2718. Fwindow Txcb_window_t
  2719. Fstate Tuint8_t
  2720. Fpad1 [3]Tuint8_t
  2721. }
  2722. type Txcb_create_notify_event_t = struct {
  2723. Fresponse_type Tuint8_t
  2724. Fpad0 Tuint8_t
  2725. Fsequence Tuint16_t
  2726. Fparent Txcb_window_t
  2727. Fwindow Txcb_window_t
  2728. Fx Tint16_t
  2729. Fy Tint16_t
  2730. Fwidth Tuint16_t
  2731. Fheight Tuint16_t
  2732. Fborder_width Tuint16_t
  2733. Foverride_redirect Tuint8_t
  2734. Fpad1 Tuint8_t
  2735. }
  2736. type Txcb_destroy_notify_event_t = struct {
  2737. Fresponse_type Tuint8_t
  2738. Fpad0 Tuint8_t
  2739. Fsequence Tuint16_t
  2740. Fevent Txcb_window_t
  2741. Fwindow Txcb_window_t
  2742. }
  2743. type Txcb_unmap_notify_event_t = struct {
  2744. Fresponse_type Tuint8_t
  2745. Fpad0 Tuint8_t
  2746. Fsequence Tuint16_t
  2747. Fevent Txcb_window_t
  2748. Fwindow Txcb_window_t
  2749. Ffrom_configure Tuint8_t
  2750. Fpad1 [3]Tuint8_t
  2751. }
  2752. type Txcb_map_notify_event_t = struct {
  2753. Fresponse_type Tuint8_t
  2754. Fpad0 Tuint8_t
  2755. Fsequence Tuint16_t
  2756. Fevent Txcb_window_t
  2757. Fwindow Txcb_window_t
  2758. Foverride_redirect Tuint8_t
  2759. Fpad1 [3]Tuint8_t
  2760. }
  2761. type Txcb_map_request_event_t = struct {
  2762. Fresponse_type Tuint8_t
  2763. Fpad0 Tuint8_t
  2764. Fsequence Tuint16_t
  2765. Fparent Txcb_window_t
  2766. Fwindow Txcb_window_t
  2767. }
  2768. type Txcb_reparent_notify_event_t = struct {
  2769. Fresponse_type Tuint8_t
  2770. Fpad0 Tuint8_t
  2771. Fsequence Tuint16_t
  2772. Fevent Txcb_window_t
  2773. Fwindow Txcb_window_t
  2774. Fparent Txcb_window_t
  2775. Fx Tint16_t
  2776. Fy Tint16_t
  2777. Foverride_redirect Tuint8_t
  2778. Fpad1 [3]Tuint8_t
  2779. }
  2780. type Txcb_configure_notify_event_t = struct {
  2781. Fresponse_type Tuint8_t
  2782. Fpad0 Tuint8_t
  2783. Fsequence Tuint16_t
  2784. Fevent Txcb_window_t
  2785. Fwindow Txcb_window_t
  2786. Fabove_sibling Txcb_window_t
  2787. Fx Tint16_t
  2788. Fy Tint16_t
  2789. Fwidth Tuint16_t
  2790. Fheight Tuint16_t
  2791. Fborder_width Tuint16_t
  2792. Foverride_redirect Tuint8_t
  2793. Fpad1 Tuint8_t
  2794. }
  2795. type Txcb_configure_request_event_t = struct {
  2796. Fresponse_type Tuint8_t
  2797. Fstack_mode Tuint8_t
  2798. Fsequence Tuint16_t
  2799. Fparent Txcb_window_t
  2800. Fwindow Txcb_window_t
  2801. Fsibling Txcb_window_t
  2802. Fx Tint16_t
  2803. Fy Tint16_t
  2804. Fwidth Tuint16_t
  2805. Fheight Tuint16_t
  2806. Fborder_width Tuint16_t
  2807. Fvalue_mask Tuint16_t
  2808. }
  2809. type Txcb_gravity_notify_event_t = struct {
  2810. Fresponse_type Tuint8_t
  2811. Fpad0 Tuint8_t
  2812. Fsequence Tuint16_t
  2813. Fevent Txcb_window_t
  2814. Fwindow Txcb_window_t
  2815. Fx Tint16_t
  2816. Fy Tint16_t
  2817. }
  2818. type Txcb_resize_request_event_t = struct {
  2819. Fresponse_type Tuint8_t
  2820. Fpad0 Tuint8_t
  2821. Fsequence Tuint16_t
  2822. Fwindow Txcb_window_t
  2823. Fwidth Tuint16_t
  2824. Fheight Tuint16_t
  2825. }
  2826. type Txcb_place_t = int32
  2827. type _xcb_place_t = int32
  2828. const _XCB_PLACE_ON_TOP = 0
  2829. const _XCB_PLACE_ON_BOTTOM = 1
  2830. type Txcb_circulate_notify_event_t = struct {
  2831. Fresponse_type Tuint8_t
  2832. Fpad0 Tuint8_t
  2833. Fsequence Tuint16_t
  2834. Fevent Txcb_window_t
  2835. Fwindow Txcb_window_t
  2836. Fpad1 [4]Tuint8_t
  2837. Fplace Tuint8_t
  2838. Fpad2 [3]Tuint8_t
  2839. }
  2840. type Txcb_circulate_request_event_t = struct {
  2841. Fresponse_type Tuint8_t
  2842. Fpad0 Tuint8_t
  2843. Fsequence Tuint16_t
  2844. Fevent Txcb_window_t
  2845. Fwindow Txcb_window_t
  2846. Fpad1 [4]Tuint8_t
  2847. Fplace Tuint8_t
  2848. Fpad2 [3]Tuint8_t
  2849. }
  2850. type Txcb_circulate_notify_event_t1 = Txcb_circulate_request_event_t
  2851. type Txcb_property_t = int32
  2852. type _xcb_property_t = int32
  2853. const _XCB_PROPERTY_NEW_VALUE = 0
  2854. const _XCB_PROPERTY_DELETE = 1
  2855. type Txcb_property_notify_event_t = struct {
  2856. Fresponse_type Tuint8_t
  2857. Fpad0 Tuint8_t
  2858. Fsequence Tuint16_t
  2859. Fwindow Txcb_window_t
  2860. Fatom Txcb_atom_t
  2861. Ftime Txcb_timestamp_t
  2862. Fstate Tuint8_t
  2863. Fpad1 [3]Tuint8_t
  2864. }
  2865. type Txcb_selection_clear_event_t = struct {
  2866. Fresponse_type Tuint8_t
  2867. Fpad0 Tuint8_t
  2868. Fsequence Tuint16_t
  2869. Ftime Txcb_timestamp_t
  2870. Fowner Txcb_window_t
  2871. Fselection Txcb_atom_t
  2872. }
  2873. type Txcb_time_t = int32
  2874. type _xcb_time_t = int32
  2875. const _XCB_TIME_CURRENT_TIME = 0
  2876. type Txcb_atom_enum_t = int32
  2877. type _xcb_atom_enum_t = int32
  2878. const _XCB_ATOM_NONE = 0
  2879. const _XCB_ATOM_ANY = 0
  2880. const _XCB_ATOM_PRIMARY = 1
  2881. const _XCB_ATOM_SECONDARY = 2
  2882. const _XCB_ATOM_ARC = 3
  2883. const _XCB_ATOM_ATOM = 4
  2884. const _XCB_ATOM_BITMAP = 5
  2885. const _XCB_ATOM_CARDINAL = 6
  2886. const _XCB_ATOM_COLORMAP = 7
  2887. const _XCB_ATOM_CURSOR = 8
  2888. const _XCB_ATOM_CUT_BUFFER0 = 9
  2889. const _XCB_ATOM_CUT_BUFFER1 = 10
  2890. const _XCB_ATOM_CUT_BUFFER2 = 11
  2891. const _XCB_ATOM_CUT_BUFFER3 = 12
  2892. const _XCB_ATOM_CUT_BUFFER4 = 13
  2893. const _XCB_ATOM_CUT_BUFFER5 = 14
  2894. const _XCB_ATOM_CUT_BUFFER6 = 15
  2895. const _XCB_ATOM_CUT_BUFFER7 = 16
  2896. const _XCB_ATOM_DRAWABLE = 17
  2897. const _XCB_ATOM_FONT = 18
  2898. const _XCB_ATOM_INTEGER = 19
  2899. const _XCB_ATOM_PIXMAP = 20
  2900. const _XCB_ATOM_POINT = 21
  2901. const _XCB_ATOM_RECTANGLE = 22
  2902. const _XCB_ATOM_RESOURCE_MANAGER = 23
  2903. const _XCB_ATOM_RGB_COLOR_MAP = 24
  2904. const _XCB_ATOM_RGB_BEST_MAP = 25
  2905. const _XCB_ATOM_RGB_BLUE_MAP = 26
  2906. const _XCB_ATOM_RGB_DEFAULT_MAP = 27
  2907. const _XCB_ATOM_RGB_GRAY_MAP = 28
  2908. const _XCB_ATOM_RGB_GREEN_MAP = 29
  2909. const _XCB_ATOM_RGB_RED_MAP = 30
  2910. const _XCB_ATOM_STRING = 31
  2911. const _XCB_ATOM_VISUALID = 32
  2912. const _XCB_ATOM_WINDOW = 33
  2913. const _XCB_ATOM_WM_COMMAND = 34
  2914. const _XCB_ATOM_WM_HINTS = 35
  2915. const _XCB_ATOM_WM_CLIENT_MACHINE = 36
  2916. const _XCB_ATOM_WM_ICON_NAME = 37
  2917. const _XCB_ATOM_WM_ICON_SIZE = 38
  2918. const _XCB_ATOM_WM_NAME = 39
  2919. const _XCB_ATOM_WM_NORMAL_HINTS = 40
  2920. const _XCB_ATOM_WM_SIZE_HINTS = 41
  2921. const _XCB_ATOM_WM_ZOOM_HINTS = 42
  2922. const _XCB_ATOM_MIN_SPACE = 43
  2923. const _XCB_ATOM_NORM_SPACE = 44
  2924. const _XCB_ATOM_MAX_SPACE = 45
  2925. const _XCB_ATOM_END_SPACE = 46
  2926. const _XCB_ATOM_SUPERSCRIPT_X = 47
  2927. const _XCB_ATOM_SUPERSCRIPT_Y = 48
  2928. const _XCB_ATOM_SUBSCRIPT_X = 49
  2929. const _XCB_ATOM_SUBSCRIPT_Y = 50
  2930. const _XCB_ATOM_UNDERLINE_POSITION = 51
  2931. const _XCB_ATOM_UNDERLINE_THICKNESS = 52
  2932. const _XCB_ATOM_STRIKEOUT_ASCENT = 53
  2933. const _XCB_ATOM_STRIKEOUT_DESCENT = 54
  2934. const _XCB_ATOM_ITALIC_ANGLE = 55
  2935. const _XCB_ATOM_X_HEIGHT = 56
  2936. const _XCB_ATOM_QUAD_WIDTH = 57
  2937. const _XCB_ATOM_WEIGHT = 58
  2938. const _XCB_ATOM_POINT_SIZE = 59
  2939. const _XCB_ATOM_RESOLUTION = 60
  2940. const _XCB_ATOM_COPYRIGHT = 61
  2941. const _XCB_ATOM_NOTICE = 62
  2942. const _XCB_ATOM_FONT_NAME = 63
  2943. const _XCB_ATOM_FAMILY_NAME = 64
  2944. const _XCB_ATOM_FULL_NAME = 65
  2945. const _XCB_ATOM_CAP_HEIGHT = 66
  2946. const _XCB_ATOM_WM_CLASS = 67
  2947. const _XCB_ATOM_WM_TRANSIENT_FOR = 68
  2948. type Txcb_selection_request_event_t = struct {
  2949. Fresponse_type Tuint8_t
  2950. Fpad0 Tuint8_t
  2951. Fsequence Tuint16_t
  2952. Ftime Txcb_timestamp_t
  2953. Fowner Txcb_window_t
  2954. Frequestor Txcb_window_t
  2955. Fselection Txcb_atom_t
  2956. Ftarget Txcb_atom_t
  2957. Fproperty Txcb_atom_t
  2958. }
  2959. type Txcb_selection_notify_event_t = struct {
  2960. Fresponse_type Tuint8_t
  2961. Fpad0 Tuint8_t
  2962. Fsequence Tuint16_t
  2963. Ftime Txcb_timestamp_t
  2964. Frequestor Txcb_window_t
  2965. Fselection Txcb_atom_t
  2966. Ftarget Txcb_atom_t
  2967. Fproperty Txcb_atom_t
  2968. }
  2969. type Txcb_colormap_state_t = int32
  2970. type _xcb_colormap_state_t = int32
  2971. const _XCB_COLORMAP_STATE_UNINSTALLED = 0
  2972. const _XCB_COLORMAP_STATE_INSTALLED = 1
  2973. type Txcb_colormap_enum_t = int32
  2974. type _xcb_colormap_enum_t = int32
  2975. const _XCB_COLORMAP_NONE = 0
  2976. type Txcb_colormap_notify_event_t = struct {
  2977. Fresponse_type Tuint8_t
  2978. Fpad0 Tuint8_t
  2979. Fsequence Tuint16_t
  2980. Fwindow Txcb_window_t
  2981. Fcolormap Txcb_colormap_t
  2982. F_new Tuint8_t
  2983. Fstate Tuint8_t
  2984. Fpad1 [2]Tuint8_t
  2985. }
  2986. type Txcb_client_message_data_t = struct {
  2987. Fdata16 [0][10]Tuint16_t
  2988. Fdata32 [0][5]Tuint32_t
  2989. Fdata8 [20]Tuint8_t
  2990. }
  2991. type Txcb_client_message_data_iterator_t = struct {
  2992. Fdata uintptr
  2993. Frem int32
  2994. Findex int32
  2995. }
  2996. type Txcb_client_message_event_t = struct {
  2997. Fresponse_type Tuint8_t
  2998. Fformat Tuint8_t
  2999. Fsequence Tuint16_t
  3000. Fwindow Txcb_window_t
  3001. Ftype1 Txcb_atom_t
  3002. Fdata Txcb_client_message_data_t
  3003. }
  3004. type Txcb_mapping_t = int32
  3005. type _xcb_mapping_t = int32
  3006. const _XCB_MAPPING_MODIFIER = 0
  3007. const _XCB_MAPPING_KEYBOARD = 1
  3008. const _XCB_MAPPING_POINTER = 2
  3009. type Txcb_mapping_notify_event_t = struct {
  3010. Fresponse_type Tuint8_t
  3011. Fpad0 Tuint8_t
  3012. Fsequence Tuint16_t
  3013. Frequest Tuint8_t
  3014. Ffirst_keycode Txcb_keycode_t
  3015. Fcount Tuint8_t
  3016. Fpad1 Tuint8_t
  3017. }
  3018. type Txcb_ge_generic_event_t = struct {
  3019. Fresponse_type Tuint8_t
  3020. Fextension Tuint8_t
  3021. Fsequence Tuint16_t
  3022. Flength Tuint32_t
  3023. Fevent_type Tuint16_t
  3024. Fpad0 [22]Tuint8_t
  3025. Ffull_sequence Tuint32_t
  3026. }
  3027. type Txcb_request_error_t = struct {
  3028. Fresponse_type Tuint8_t
  3029. Ferror_code Tuint8_t
  3030. Fsequence Tuint16_t
  3031. Fbad_value Tuint32_t
  3032. Fminor_opcode Tuint16_t
  3033. Fmajor_opcode Tuint8_t
  3034. Fpad0 Tuint8_t
  3035. }
  3036. type Txcb_value_error_t = struct {
  3037. Fresponse_type Tuint8_t
  3038. Ferror_code Tuint8_t
  3039. Fsequence Tuint16_t
  3040. Fbad_value Tuint32_t
  3041. Fminor_opcode Tuint16_t
  3042. Fmajor_opcode Tuint8_t
  3043. Fpad0 Tuint8_t
  3044. }
  3045. type Txcb_window_error_t = struct {
  3046. Fresponse_type Tuint8_t
  3047. Ferror_code Tuint8_t
  3048. Fsequence Tuint16_t
  3049. Fbad_value Tuint32_t
  3050. Fminor_opcode Tuint16_t
  3051. Fmajor_opcode Tuint8_t
  3052. Fpad0 Tuint8_t
  3053. }
  3054. type Txcb_value_error_t1 = Txcb_window_error_t
  3055. type Txcb_pixmap_error_t = struct {
  3056. Fresponse_type Tuint8_t
  3057. Ferror_code Tuint8_t
  3058. Fsequence Tuint16_t
  3059. Fbad_value Tuint32_t
  3060. Fminor_opcode Tuint16_t
  3061. Fmajor_opcode Tuint8_t
  3062. Fpad0 Tuint8_t
  3063. }
  3064. type Txcb_atom_error_t = struct {
  3065. Fresponse_type Tuint8_t
  3066. Ferror_code Tuint8_t
  3067. Fsequence Tuint16_t
  3068. Fbad_value Tuint32_t
  3069. Fminor_opcode Tuint16_t
  3070. Fmajor_opcode Tuint8_t
  3071. Fpad0 Tuint8_t
  3072. }
  3073. type Txcb_cursor_error_t = struct {
  3074. Fresponse_type Tuint8_t
  3075. Ferror_code Tuint8_t
  3076. Fsequence Tuint16_t
  3077. Fbad_value Tuint32_t
  3078. Fminor_opcode Tuint16_t
  3079. Fmajor_opcode Tuint8_t
  3080. Fpad0 Tuint8_t
  3081. }
  3082. type Txcb_font_error_t = struct {
  3083. Fresponse_type Tuint8_t
  3084. Ferror_code Tuint8_t
  3085. Fsequence Tuint16_t
  3086. Fbad_value Tuint32_t
  3087. Fminor_opcode Tuint16_t
  3088. Fmajor_opcode Tuint8_t
  3089. Fpad0 Tuint8_t
  3090. }
  3091. type Txcb_match_error_t = struct {
  3092. Fresponse_type Tuint8_t
  3093. Ferror_code Tuint8_t
  3094. Fsequence Tuint16_t
  3095. Fbad_value Tuint32_t
  3096. Fminor_opcode Tuint16_t
  3097. Fmajor_opcode Tuint8_t
  3098. Fpad0 Tuint8_t
  3099. }
  3100. type Txcb_request_error_t1 = Txcb_match_error_t
  3101. type Txcb_drawable_error_t = struct {
  3102. Fresponse_type Tuint8_t
  3103. Ferror_code Tuint8_t
  3104. Fsequence Tuint16_t
  3105. Fbad_value Tuint32_t
  3106. Fminor_opcode Tuint16_t
  3107. Fmajor_opcode Tuint8_t
  3108. Fpad0 Tuint8_t
  3109. }
  3110. type Txcb_access_error_t = struct {
  3111. Fresponse_type Tuint8_t
  3112. Ferror_code Tuint8_t
  3113. Fsequence Tuint16_t
  3114. Fbad_value Tuint32_t
  3115. Fminor_opcode Tuint16_t
  3116. Fmajor_opcode Tuint8_t
  3117. Fpad0 Tuint8_t
  3118. }
  3119. type Txcb_alloc_error_t = struct {
  3120. Fresponse_type Tuint8_t
  3121. Ferror_code Tuint8_t
  3122. Fsequence Tuint16_t
  3123. Fbad_value Tuint32_t
  3124. Fminor_opcode Tuint16_t
  3125. Fmajor_opcode Tuint8_t
  3126. Fpad0 Tuint8_t
  3127. }
  3128. type Txcb_colormap_error_t = struct {
  3129. Fresponse_type Tuint8_t
  3130. Ferror_code Tuint8_t
  3131. Fsequence Tuint16_t
  3132. Fbad_value Tuint32_t
  3133. Fminor_opcode Tuint16_t
  3134. Fmajor_opcode Tuint8_t
  3135. Fpad0 Tuint8_t
  3136. }
  3137. type Txcb_g_context_error_t = struct {
  3138. Fresponse_type Tuint8_t
  3139. Ferror_code Tuint8_t
  3140. Fsequence Tuint16_t
  3141. Fbad_value Tuint32_t
  3142. Fminor_opcode Tuint16_t
  3143. Fmajor_opcode Tuint8_t
  3144. Fpad0 Tuint8_t
  3145. }
  3146. type Txcb_id_choice_error_t = struct {
  3147. Fresponse_type Tuint8_t
  3148. Ferror_code Tuint8_t
  3149. Fsequence Tuint16_t
  3150. Fbad_value Tuint32_t
  3151. Fminor_opcode Tuint16_t
  3152. Fmajor_opcode Tuint8_t
  3153. Fpad0 Tuint8_t
  3154. }
  3155. type Txcb_name_error_t = struct {
  3156. Fresponse_type Tuint8_t
  3157. Ferror_code Tuint8_t
  3158. Fsequence Tuint16_t
  3159. Fbad_value Tuint32_t
  3160. Fminor_opcode Tuint16_t
  3161. Fmajor_opcode Tuint8_t
  3162. Fpad0 Tuint8_t
  3163. }
  3164. type Txcb_length_error_t = struct {
  3165. Fresponse_type Tuint8_t
  3166. Ferror_code Tuint8_t
  3167. Fsequence Tuint16_t
  3168. Fbad_value Tuint32_t
  3169. Fminor_opcode Tuint16_t
  3170. Fmajor_opcode Tuint8_t
  3171. Fpad0 Tuint8_t
  3172. }
  3173. type Txcb_implementation_error_t = struct {
  3174. Fresponse_type Tuint8_t
  3175. Ferror_code Tuint8_t
  3176. Fsequence Tuint16_t
  3177. Fbad_value Tuint32_t
  3178. Fminor_opcode Tuint16_t
  3179. Fmajor_opcode Tuint8_t
  3180. Fpad0 Tuint8_t
  3181. }
  3182. type Txcb_window_class_t = int32
  3183. type _xcb_window_class_t = int32
  3184. const _XCB_WINDOW_CLASS_COPY_FROM_PARENT = 0
  3185. const _XCB_WINDOW_CLASS_INPUT_OUTPUT = 1
  3186. const _XCB_WINDOW_CLASS_INPUT_ONLY = 2
  3187. type Txcb_cw_t = int32
  3188. type _xcb_cw_t = int32
  3189. const _XCB_CW_BACK_PIXMAP = 1
  3190. const _XCB_CW_BACK_PIXEL = 2
  3191. const _XCB_CW_BORDER_PIXMAP = 4
  3192. const _XCB_CW_BORDER_PIXEL = 8
  3193. const _XCB_CW_BIT_GRAVITY = 16
  3194. const _XCB_CW_WIN_GRAVITY = 32
  3195. const _XCB_CW_BACKING_STORE = 64
  3196. const _XCB_CW_BACKING_PLANES = 128
  3197. const _XCB_CW_BACKING_PIXEL = 256
  3198. const _XCB_CW_OVERRIDE_REDIRECT = 512
  3199. const _XCB_CW_SAVE_UNDER = 1024
  3200. const _XCB_CW_EVENT_MASK = 2048
  3201. const _XCB_CW_DONT_PROPAGATE = 4096
  3202. const _XCB_CW_COLORMAP = 8192
  3203. const _XCB_CW_CURSOR = 16384
  3204. type Txcb_back_pixmap_t = int32
  3205. type _xcb_back_pixmap_t = int32
  3206. const _XCB_BACK_PIXMAP_NONE = 0
  3207. const _XCB_BACK_PIXMAP_PARENT_RELATIVE = 1
  3208. type Txcb_gravity_t = int32
  3209. type _xcb_gravity_t = int32
  3210. const _XCB_GRAVITY_BIT_FORGET = 0
  3211. const _XCB_GRAVITY_WIN_UNMAP = 0
  3212. const _XCB_GRAVITY_NORTH_WEST = 1
  3213. const _XCB_GRAVITY_NORTH = 2
  3214. const _XCB_GRAVITY_NORTH_EAST = 3
  3215. const _XCB_GRAVITY_WEST = 4
  3216. const _XCB_GRAVITY_CENTER = 5
  3217. const _XCB_GRAVITY_EAST = 6
  3218. const _XCB_GRAVITY_SOUTH_WEST = 7
  3219. const _XCB_GRAVITY_SOUTH = 8
  3220. const _XCB_GRAVITY_SOUTH_EAST = 9
  3221. const _XCB_GRAVITY_STATIC = 10
  3222. type Txcb_create_window_value_list_t = struct {
  3223. Fbackground_pixmap Txcb_pixmap_t
  3224. Fbackground_pixel Tuint32_t
  3225. Fborder_pixmap Txcb_pixmap_t
  3226. Fborder_pixel Tuint32_t
  3227. Fbit_gravity Tuint32_t
  3228. Fwin_gravity Tuint32_t
  3229. Fbacking_store Tuint32_t
  3230. Fbacking_planes Tuint32_t
  3231. Fbacking_pixel Tuint32_t
  3232. Foverride_redirect Txcb_bool32_t
  3233. Fsave_under Txcb_bool32_t
  3234. Fevent_mask Tuint32_t
  3235. Fdo_not_propogate_mask Tuint32_t
  3236. Fcolormap Txcb_colormap_t
  3237. Fcursor Txcb_cursor_t
  3238. }
  3239. type Txcb_create_window_request_t = struct {
  3240. Fmajor_opcode Tuint8_t
  3241. Fdepth Tuint8_t
  3242. Flength Tuint16_t
  3243. Fwid Txcb_window_t
  3244. Fparent Txcb_window_t
  3245. Fx Tint16_t
  3246. Fy Tint16_t
  3247. Fwidth Tuint16_t
  3248. Fheight Tuint16_t
  3249. Fborder_width Tuint16_t
  3250. F_class Tuint16_t
  3251. Fvisual Txcb_visualid_t
  3252. Fvalue_mask Tuint32_t
  3253. }
  3254. type Txcb_change_window_attributes_value_list_t = struct {
  3255. Fbackground_pixmap Txcb_pixmap_t
  3256. Fbackground_pixel Tuint32_t
  3257. Fborder_pixmap Txcb_pixmap_t
  3258. Fborder_pixel Tuint32_t
  3259. Fbit_gravity Tuint32_t
  3260. Fwin_gravity Tuint32_t
  3261. Fbacking_store Tuint32_t
  3262. Fbacking_planes Tuint32_t
  3263. Fbacking_pixel Tuint32_t
  3264. Foverride_redirect Txcb_bool32_t
  3265. Fsave_under Txcb_bool32_t
  3266. Fevent_mask Tuint32_t
  3267. Fdo_not_propogate_mask Tuint32_t
  3268. Fcolormap Txcb_colormap_t
  3269. Fcursor Txcb_cursor_t
  3270. }
  3271. type Txcb_change_window_attributes_request_t = struct {
  3272. Fmajor_opcode Tuint8_t
  3273. Fpad0 Tuint8_t
  3274. Flength Tuint16_t
  3275. Fwindow Txcb_window_t
  3276. Fvalue_mask Tuint32_t
  3277. }
  3278. type Txcb_map_state_t = int32
  3279. type _xcb_map_state_t = int32
  3280. const _XCB_MAP_STATE_UNMAPPED = 0
  3281. const _XCB_MAP_STATE_UNVIEWABLE = 1
  3282. const _XCB_MAP_STATE_VIEWABLE = 2
  3283. type Txcb_get_window_attributes_cookie_t = struct {
  3284. Fsequence uint32
  3285. }
  3286. type Txcb_get_window_attributes_request_t = struct {
  3287. Fmajor_opcode Tuint8_t
  3288. Fpad0 Tuint8_t
  3289. Flength Tuint16_t
  3290. Fwindow Txcb_window_t
  3291. }
  3292. type Txcb_get_window_attributes_reply_t = struct {
  3293. Fresponse_type Tuint8_t
  3294. Fbacking_store Tuint8_t
  3295. Fsequence Tuint16_t
  3296. Flength Tuint32_t
  3297. Fvisual Txcb_visualid_t
  3298. F_class Tuint16_t
  3299. Fbit_gravity Tuint8_t
  3300. Fwin_gravity Tuint8_t
  3301. Fbacking_planes Tuint32_t
  3302. Fbacking_pixel Tuint32_t
  3303. Fsave_under Tuint8_t
  3304. Fmap_is_installed Tuint8_t
  3305. Fmap_state Tuint8_t
  3306. Foverride_redirect Tuint8_t
  3307. Fcolormap Txcb_colormap_t
  3308. Fall_event_masks Tuint32_t
  3309. Fyour_event_mask Tuint32_t
  3310. Fdo_not_propagate_mask Tuint16_t
  3311. Fpad0 [2]Tuint8_t
  3312. }
  3313. type Txcb_destroy_window_request_t = struct {
  3314. Fmajor_opcode Tuint8_t
  3315. Fpad0 Tuint8_t
  3316. Flength Tuint16_t
  3317. Fwindow Txcb_window_t
  3318. }
  3319. type Txcb_destroy_subwindows_request_t = struct {
  3320. Fmajor_opcode Tuint8_t
  3321. Fpad0 Tuint8_t
  3322. Flength Tuint16_t
  3323. Fwindow Txcb_window_t
  3324. }
  3325. type Txcb_set_mode_t = int32
  3326. type _xcb_set_mode_t = int32
  3327. const _XCB_SET_MODE_INSERT = 0
  3328. const _XCB_SET_MODE_DELETE = 1
  3329. type Txcb_change_save_set_request_t = struct {
  3330. Fmajor_opcode Tuint8_t
  3331. Fmode Tuint8_t
  3332. Flength Tuint16_t
  3333. Fwindow Txcb_window_t
  3334. }
  3335. type Txcb_reparent_window_request_t = struct {
  3336. Fmajor_opcode Tuint8_t
  3337. Fpad0 Tuint8_t
  3338. Flength Tuint16_t
  3339. Fwindow Txcb_window_t
  3340. Fparent Txcb_window_t
  3341. Fx Tint16_t
  3342. Fy Tint16_t
  3343. }
  3344. type Txcb_map_window_request_t = struct {
  3345. Fmajor_opcode Tuint8_t
  3346. Fpad0 Tuint8_t
  3347. Flength Tuint16_t
  3348. Fwindow Txcb_window_t
  3349. }
  3350. type Txcb_map_subwindows_request_t = struct {
  3351. Fmajor_opcode Tuint8_t
  3352. Fpad0 Tuint8_t
  3353. Flength Tuint16_t
  3354. Fwindow Txcb_window_t
  3355. }
  3356. type Txcb_unmap_window_request_t = struct {
  3357. Fmajor_opcode Tuint8_t
  3358. Fpad0 Tuint8_t
  3359. Flength Tuint16_t
  3360. Fwindow Txcb_window_t
  3361. }
  3362. type Txcb_unmap_subwindows_request_t = struct {
  3363. Fmajor_opcode Tuint8_t
  3364. Fpad0 Tuint8_t
  3365. Flength Tuint16_t
  3366. Fwindow Txcb_window_t
  3367. }
  3368. type Txcb_config_window_t = int32
  3369. type _xcb_config_window_t = int32
  3370. const _XCB_CONFIG_WINDOW_X = 1
  3371. const _XCB_CONFIG_WINDOW_Y = 2
  3372. const _XCB_CONFIG_WINDOW_WIDTH = 4
  3373. const _XCB_CONFIG_WINDOW_HEIGHT = 8
  3374. const _XCB_CONFIG_WINDOW_BORDER_WIDTH = 16
  3375. const _XCB_CONFIG_WINDOW_SIBLING = 32
  3376. const _XCB_CONFIG_WINDOW_STACK_MODE = 64
  3377. type Txcb_stack_mode_t = int32
  3378. type _xcb_stack_mode_t = int32
  3379. const _XCB_STACK_MODE_ABOVE = 0
  3380. const _XCB_STACK_MODE_BELOW = 1
  3381. const _XCB_STACK_MODE_TOP_IF = 2
  3382. const _XCB_STACK_MODE_BOTTOM_IF = 3
  3383. const _XCB_STACK_MODE_OPPOSITE = 4
  3384. type Txcb_configure_window_value_list_t = struct {
  3385. Fx Tint32_t
  3386. Fy Tint32_t
  3387. Fwidth Tuint32_t
  3388. Fheight Tuint32_t
  3389. Fborder_width Tuint32_t
  3390. Fsibling Txcb_window_t
  3391. Fstack_mode Tuint32_t
  3392. }
  3393. type Txcb_configure_window_request_t = struct {
  3394. Fmajor_opcode Tuint8_t
  3395. Fpad0 Tuint8_t
  3396. Flength Tuint16_t
  3397. Fwindow Txcb_window_t
  3398. Fvalue_mask Tuint16_t
  3399. Fpad1 [2]Tuint8_t
  3400. }
  3401. type Txcb_circulate_t = int32
  3402. type _xcb_circulate_t = int32
  3403. const _XCB_CIRCULATE_RAISE_LOWEST = 0
  3404. const _XCB_CIRCULATE_LOWER_HIGHEST = 1
  3405. type Txcb_circulate_window_request_t = struct {
  3406. Fmajor_opcode Tuint8_t
  3407. Fdirection Tuint8_t
  3408. Flength Tuint16_t
  3409. Fwindow Txcb_window_t
  3410. }
  3411. type Txcb_get_geometry_cookie_t = struct {
  3412. Fsequence uint32
  3413. }
  3414. type Txcb_get_geometry_request_t = struct {
  3415. Fmajor_opcode Tuint8_t
  3416. Fpad0 Tuint8_t
  3417. Flength Tuint16_t
  3418. Fdrawable Txcb_drawable_t
  3419. }
  3420. type Txcb_get_geometry_reply_t = struct {
  3421. Fresponse_type Tuint8_t
  3422. Fdepth Tuint8_t
  3423. Fsequence Tuint16_t
  3424. Flength Tuint32_t
  3425. Froot Txcb_window_t
  3426. Fx Tint16_t
  3427. Fy Tint16_t
  3428. Fwidth Tuint16_t
  3429. Fheight Tuint16_t
  3430. Fborder_width Tuint16_t
  3431. Fpad0 [2]Tuint8_t
  3432. }
  3433. type Txcb_query_tree_cookie_t = struct {
  3434. Fsequence uint32
  3435. }
  3436. type Txcb_query_tree_request_t = struct {
  3437. Fmajor_opcode Tuint8_t
  3438. Fpad0 Tuint8_t
  3439. Flength Tuint16_t
  3440. Fwindow Txcb_window_t
  3441. }
  3442. type Txcb_query_tree_reply_t = struct {
  3443. Fresponse_type Tuint8_t
  3444. Fpad0 Tuint8_t
  3445. Fsequence Tuint16_t
  3446. Flength Tuint32_t
  3447. Froot Txcb_window_t
  3448. Fparent Txcb_window_t
  3449. Fchildren_len Tuint16_t
  3450. Fpad1 [14]Tuint8_t
  3451. }
  3452. type Txcb_intern_atom_cookie_t = struct {
  3453. Fsequence uint32
  3454. }
  3455. type Txcb_intern_atom_request_t = struct {
  3456. Fmajor_opcode Tuint8_t
  3457. Fonly_if_exists Tuint8_t
  3458. Flength Tuint16_t
  3459. Fname_len Tuint16_t
  3460. Fpad0 [2]Tuint8_t
  3461. }
  3462. type Txcb_intern_atom_reply_t = struct {
  3463. Fresponse_type Tuint8_t
  3464. Fpad0 Tuint8_t
  3465. Fsequence Tuint16_t
  3466. Flength Tuint32_t
  3467. Fatom Txcb_atom_t
  3468. }
  3469. type Txcb_get_atom_name_cookie_t = struct {
  3470. Fsequence uint32
  3471. }
  3472. type Txcb_get_atom_name_request_t = struct {
  3473. Fmajor_opcode Tuint8_t
  3474. Fpad0 Tuint8_t
  3475. Flength Tuint16_t
  3476. Fatom Txcb_atom_t
  3477. }
  3478. type Txcb_get_atom_name_reply_t = struct {
  3479. Fresponse_type Tuint8_t
  3480. Fpad0 Tuint8_t
  3481. Fsequence Tuint16_t
  3482. Flength Tuint32_t
  3483. Fname_len Tuint16_t
  3484. Fpad1 [22]Tuint8_t
  3485. }
  3486. type Txcb_prop_mode_t = int32
  3487. type _xcb_prop_mode_t = int32
  3488. const _XCB_PROP_MODE_REPLACE = 0
  3489. const _XCB_PROP_MODE_PREPEND = 1
  3490. const _XCB_PROP_MODE_APPEND = 2
  3491. type Txcb_change_property_request_t = struct {
  3492. Fmajor_opcode Tuint8_t
  3493. Fmode Tuint8_t
  3494. Flength Tuint16_t
  3495. Fwindow Txcb_window_t
  3496. Fproperty Txcb_atom_t
  3497. Ftype1 Txcb_atom_t
  3498. Fformat Tuint8_t
  3499. Fpad0 [3]Tuint8_t
  3500. Fdata_len Tuint32_t
  3501. }
  3502. type Txcb_delete_property_request_t = struct {
  3503. Fmajor_opcode Tuint8_t
  3504. Fpad0 Tuint8_t
  3505. Flength Tuint16_t
  3506. Fwindow Txcb_window_t
  3507. Fproperty Txcb_atom_t
  3508. }
  3509. type Txcb_get_property_type_t = int32
  3510. type _xcb_get_property_type_t = int32
  3511. const _XCB_GET_PROPERTY_TYPE_ANY = 0
  3512. type Txcb_get_property_cookie_t = struct {
  3513. Fsequence uint32
  3514. }
  3515. type Txcb_get_property_request_t = struct {
  3516. Fmajor_opcode Tuint8_t
  3517. F_delete Tuint8_t
  3518. Flength Tuint16_t
  3519. Fwindow Txcb_window_t
  3520. Fproperty Txcb_atom_t
  3521. Ftype1 Txcb_atom_t
  3522. Flong_offset Tuint32_t
  3523. Flong_length Tuint32_t
  3524. }
  3525. type Txcb_get_property_reply_t = struct {
  3526. Fresponse_type Tuint8_t
  3527. Fformat Tuint8_t
  3528. Fsequence Tuint16_t
  3529. Flength Tuint32_t
  3530. Ftype1 Txcb_atom_t
  3531. Fbytes_after Tuint32_t
  3532. Fvalue_len Tuint32_t
  3533. Fpad0 [12]Tuint8_t
  3534. }
  3535. type Txcb_list_properties_cookie_t = struct {
  3536. Fsequence uint32
  3537. }
  3538. type Txcb_list_properties_request_t = struct {
  3539. Fmajor_opcode Tuint8_t
  3540. Fpad0 Tuint8_t
  3541. Flength Tuint16_t
  3542. Fwindow Txcb_window_t
  3543. }
  3544. type Txcb_list_properties_reply_t = struct {
  3545. Fresponse_type Tuint8_t
  3546. Fpad0 Tuint8_t
  3547. Fsequence Tuint16_t
  3548. Flength Tuint32_t
  3549. Fatoms_len Tuint16_t
  3550. Fpad1 [22]Tuint8_t
  3551. }
  3552. type Txcb_set_selection_owner_request_t = struct {
  3553. Fmajor_opcode Tuint8_t
  3554. Fpad0 Tuint8_t
  3555. Flength Tuint16_t
  3556. Fowner Txcb_window_t
  3557. Fselection Txcb_atom_t
  3558. Ftime Txcb_timestamp_t
  3559. }
  3560. type Txcb_get_selection_owner_cookie_t = struct {
  3561. Fsequence uint32
  3562. }
  3563. type Txcb_get_selection_owner_request_t = struct {
  3564. Fmajor_opcode Tuint8_t
  3565. Fpad0 Tuint8_t
  3566. Flength Tuint16_t
  3567. Fselection Txcb_atom_t
  3568. }
  3569. type Txcb_get_selection_owner_reply_t = struct {
  3570. Fresponse_type Tuint8_t
  3571. Fpad0 Tuint8_t
  3572. Fsequence Tuint16_t
  3573. Flength Tuint32_t
  3574. Fowner Txcb_window_t
  3575. }
  3576. type Txcb_convert_selection_request_t = struct {
  3577. Fmajor_opcode Tuint8_t
  3578. Fpad0 Tuint8_t
  3579. Flength Tuint16_t
  3580. Frequestor Txcb_window_t
  3581. Fselection Txcb_atom_t
  3582. Ftarget Txcb_atom_t
  3583. Fproperty Txcb_atom_t
  3584. Ftime Txcb_timestamp_t
  3585. }
  3586. type Txcb_send_event_dest_t = int32
  3587. type _xcb_send_event_dest_t = int32
  3588. const _XCB_SEND_EVENT_DEST_POINTER_WINDOW = 0
  3589. const _XCB_SEND_EVENT_DEST_ITEM_FOCUS = 1
  3590. type Txcb_send_event_request_t = struct {
  3591. Fmajor_opcode Tuint8_t
  3592. Fpropagate Tuint8_t
  3593. Flength Tuint16_t
  3594. Fdestination Txcb_window_t
  3595. Fevent_mask Tuint32_t
  3596. Fevent [32]int8
  3597. }
  3598. type Txcb_grab_mode_t = int32
  3599. type _xcb_grab_mode_t = int32
  3600. const _XCB_GRAB_MODE_SYNC = 0
  3601. const _XCB_GRAB_MODE_ASYNC = 1
  3602. type Txcb_grab_status_t = int32
  3603. type _xcb_grab_status_t = int32
  3604. const _XCB_GRAB_STATUS_SUCCESS = 0
  3605. const _XCB_GRAB_STATUS_ALREADY_GRABBED = 1
  3606. const _XCB_GRAB_STATUS_INVALID_TIME = 2
  3607. const _XCB_GRAB_STATUS_NOT_VIEWABLE = 3
  3608. const _XCB_GRAB_STATUS_FROZEN = 4
  3609. type Txcb_cursor_enum_t = int32
  3610. type _xcb_cursor_enum_t = int32
  3611. const _XCB_CURSOR_NONE = 0
  3612. type Txcb_grab_pointer_cookie_t = struct {
  3613. Fsequence uint32
  3614. }
  3615. type Txcb_grab_pointer_request_t = struct {
  3616. Fmajor_opcode Tuint8_t
  3617. Fowner_events Tuint8_t
  3618. Flength Tuint16_t
  3619. Fgrab_window Txcb_window_t
  3620. Fevent_mask Tuint16_t
  3621. Fpointer_mode Tuint8_t
  3622. Fkeyboard_mode Tuint8_t
  3623. Fconfine_to Txcb_window_t
  3624. Fcursor Txcb_cursor_t
  3625. Ftime Txcb_timestamp_t
  3626. }
  3627. type Txcb_grab_pointer_reply_t = struct {
  3628. Fresponse_type Tuint8_t
  3629. Fstatus Tuint8_t
  3630. Fsequence Tuint16_t
  3631. Flength Tuint32_t
  3632. }
  3633. type Txcb_ungrab_pointer_request_t = struct {
  3634. Fmajor_opcode Tuint8_t
  3635. Fpad0 Tuint8_t
  3636. Flength Tuint16_t
  3637. Ftime Txcb_timestamp_t
  3638. }
  3639. type Txcb_button_index_t = int32
  3640. type _xcb_button_index_t = int32
  3641. const _XCB_BUTTON_INDEX_ANY = 0
  3642. const _XCB_BUTTON_INDEX_1 = 1
  3643. const _XCB_BUTTON_INDEX_2 = 2
  3644. const _XCB_BUTTON_INDEX_3 = 3
  3645. const _XCB_BUTTON_INDEX_4 = 4
  3646. const _XCB_BUTTON_INDEX_5 = 5
  3647. type Txcb_grab_button_request_t = struct {
  3648. Fmajor_opcode Tuint8_t
  3649. Fowner_events Tuint8_t
  3650. Flength Tuint16_t
  3651. Fgrab_window Txcb_window_t
  3652. Fevent_mask Tuint16_t
  3653. Fpointer_mode Tuint8_t
  3654. Fkeyboard_mode Tuint8_t
  3655. Fconfine_to Txcb_window_t
  3656. Fcursor Txcb_cursor_t
  3657. Fbutton Tuint8_t
  3658. Fpad0 Tuint8_t
  3659. Fmodifiers Tuint16_t
  3660. }
  3661. type Txcb_ungrab_button_request_t = struct {
  3662. Fmajor_opcode Tuint8_t
  3663. Fbutton Tuint8_t
  3664. Flength Tuint16_t
  3665. Fgrab_window Txcb_window_t
  3666. Fmodifiers Tuint16_t
  3667. Fpad0 [2]Tuint8_t
  3668. }
  3669. type Txcb_change_active_pointer_grab_request_t = struct {
  3670. Fmajor_opcode Tuint8_t
  3671. Fpad0 Tuint8_t
  3672. Flength Tuint16_t
  3673. Fcursor Txcb_cursor_t
  3674. Ftime Txcb_timestamp_t
  3675. Fevent_mask Tuint16_t
  3676. Fpad1 [2]Tuint8_t
  3677. }
  3678. type Txcb_grab_keyboard_cookie_t = struct {
  3679. Fsequence uint32
  3680. }
  3681. type Txcb_grab_keyboard_request_t = struct {
  3682. Fmajor_opcode Tuint8_t
  3683. Fowner_events Tuint8_t
  3684. Flength Tuint16_t
  3685. Fgrab_window Txcb_window_t
  3686. Ftime Txcb_timestamp_t
  3687. Fpointer_mode Tuint8_t
  3688. Fkeyboard_mode Tuint8_t
  3689. Fpad0 [2]Tuint8_t
  3690. }
  3691. type Txcb_grab_keyboard_reply_t = struct {
  3692. Fresponse_type Tuint8_t
  3693. Fstatus Tuint8_t
  3694. Fsequence Tuint16_t
  3695. Flength Tuint32_t
  3696. }
  3697. type Txcb_ungrab_keyboard_request_t = struct {
  3698. Fmajor_opcode Tuint8_t
  3699. Fpad0 Tuint8_t
  3700. Flength Tuint16_t
  3701. Ftime Txcb_timestamp_t
  3702. }
  3703. type Txcb_grab_t = int32
  3704. type _xcb_grab_t = int32
  3705. const _XCB_GRAB_ANY = 0
  3706. type Txcb_grab_key_request_t = struct {
  3707. Fmajor_opcode Tuint8_t
  3708. Fowner_events Tuint8_t
  3709. Flength Tuint16_t
  3710. Fgrab_window Txcb_window_t
  3711. Fmodifiers Tuint16_t
  3712. Fkey Txcb_keycode_t
  3713. Fpointer_mode Tuint8_t
  3714. Fkeyboard_mode Tuint8_t
  3715. Fpad0 [3]Tuint8_t
  3716. }
  3717. type Txcb_ungrab_key_request_t = struct {
  3718. Fmajor_opcode Tuint8_t
  3719. Fkey Txcb_keycode_t
  3720. Flength Tuint16_t
  3721. Fgrab_window Txcb_window_t
  3722. Fmodifiers Tuint16_t
  3723. Fpad0 [2]Tuint8_t
  3724. }
  3725. type Txcb_allow_t = int32
  3726. type _xcb_allow_t = int32
  3727. const _XCB_ALLOW_ASYNC_POINTER = 0
  3728. const _XCB_ALLOW_SYNC_POINTER = 1
  3729. const _XCB_ALLOW_REPLAY_POINTER = 2
  3730. const _XCB_ALLOW_ASYNC_KEYBOARD = 3
  3731. const _XCB_ALLOW_SYNC_KEYBOARD = 4
  3732. const _XCB_ALLOW_REPLAY_KEYBOARD = 5
  3733. const _XCB_ALLOW_ASYNC_BOTH = 6
  3734. const _XCB_ALLOW_SYNC_BOTH = 7
  3735. type Txcb_allow_events_request_t = struct {
  3736. Fmajor_opcode Tuint8_t
  3737. Fmode Tuint8_t
  3738. Flength Tuint16_t
  3739. Ftime Txcb_timestamp_t
  3740. }
  3741. type Txcb_grab_server_request_t = struct {
  3742. Fmajor_opcode Tuint8_t
  3743. Fpad0 Tuint8_t
  3744. Flength Tuint16_t
  3745. }
  3746. type Txcb_ungrab_server_request_t = struct {
  3747. Fmajor_opcode Tuint8_t
  3748. Fpad0 Tuint8_t
  3749. Flength Tuint16_t
  3750. }
  3751. type Txcb_query_pointer_cookie_t = struct {
  3752. Fsequence uint32
  3753. }
  3754. type Txcb_query_pointer_request_t = struct {
  3755. Fmajor_opcode Tuint8_t
  3756. Fpad0 Tuint8_t
  3757. Flength Tuint16_t
  3758. Fwindow Txcb_window_t
  3759. }
  3760. type Txcb_query_pointer_reply_t = struct {
  3761. Fresponse_type Tuint8_t
  3762. Fsame_screen Tuint8_t
  3763. Fsequence Tuint16_t
  3764. Flength Tuint32_t
  3765. Froot Txcb_window_t
  3766. Fchild Txcb_window_t
  3767. Froot_x Tint16_t
  3768. Froot_y Tint16_t
  3769. Fwin_x Tint16_t
  3770. Fwin_y Tint16_t
  3771. Fmask Tuint16_t
  3772. Fpad0 [2]Tuint8_t
  3773. }
  3774. type Txcb_timecoord_t = struct {
  3775. Ftime Txcb_timestamp_t
  3776. Fx Tint16_t
  3777. Fy Tint16_t
  3778. }
  3779. type Txcb_timecoord_iterator_t = struct {
  3780. Fdata uintptr
  3781. Frem int32
  3782. Findex int32
  3783. }
  3784. type Txcb_get_motion_events_cookie_t = struct {
  3785. Fsequence uint32
  3786. }
  3787. type Txcb_get_motion_events_request_t = struct {
  3788. Fmajor_opcode Tuint8_t
  3789. Fpad0 Tuint8_t
  3790. Flength Tuint16_t
  3791. Fwindow Txcb_window_t
  3792. Fstart Txcb_timestamp_t
  3793. Fstop Txcb_timestamp_t
  3794. }
  3795. type Txcb_get_motion_events_reply_t = struct {
  3796. Fresponse_type Tuint8_t
  3797. Fpad0 Tuint8_t
  3798. Fsequence Tuint16_t
  3799. Flength Tuint32_t
  3800. Fevents_len Tuint32_t
  3801. Fpad1 [20]Tuint8_t
  3802. }
  3803. type Txcb_translate_coordinates_cookie_t = struct {
  3804. Fsequence uint32
  3805. }
  3806. type Txcb_translate_coordinates_request_t = struct {
  3807. Fmajor_opcode Tuint8_t
  3808. Fpad0 Tuint8_t
  3809. Flength Tuint16_t
  3810. Fsrc_window Txcb_window_t
  3811. Fdst_window Txcb_window_t
  3812. Fsrc_x Tint16_t
  3813. Fsrc_y Tint16_t
  3814. }
  3815. type Txcb_translate_coordinates_reply_t = struct {
  3816. Fresponse_type Tuint8_t
  3817. Fsame_screen Tuint8_t
  3818. Fsequence Tuint16_t
  3819. Flength Tuint32_t
  3820. Fchild Txcb_window_t
  3821. Fdst_x Tint16_t
  3822. Fdst_y Tint16_t
  3823. }
  3824. type Txcb_warp_pointer_request_t = struct {
  3825. Fmajor_opcode Tuint8_t
  3826. Fpad0 Tuint8_t
  3827. Flength Tuint16_t
  3828. Fsrc_window Txcb_window_t
  3829. Fdst_window Txcb_window_t
  3830. Fsrc_x Tint16_t
  3831. Fsrc_y Tint16_t
  3832. Fsrc_width Tuint16_t
  3833. Fsrc_height Tuint16_t
  3834. Fdst_x Tint16_t
  3835. Fdst_y Tint16_t
  3836. }
  3837. type Txcb_input_focus_t = int32
  3838. type _xcb_input_focus_t = int32
  3839. const _XCB_INPUT_FOCUS_NONE = 0
  3840. const _XCB_INPUT_FOCUS_POINTER_ROOT = 1
  3841. const _XCB_INPUT_FOCUS_PARENT = 2
  3842. const _XCB_INPUT_FOCUS_FOLLOW_KEYBOARD = 3
  3843. type Txcb_set_input_focus_request_t = struct {
  3844. Fmajor_opcode Tuint8_t
  3845. Frevert_to Tuint8_t
  3846. Flength Tuint16_t
  3847. Ffocus Txcb_window_t
  3848. Ftime Txcb_timestamp_t
  3849. }
  3850. type Txcb_get_input_focus_cookie_t = struct {
  3851. Fsequence uint32
  3852. }
  3853. type Txcb_get_input_focus_request_t = struct {
  3854. Fmajor_opcode Tuint8_t
  3855. Fpad0 Tuint8_t
  3856. Flength Tuint16_t
  3857. }
  3858. type Txcb_get_input_focus_reply_t = struct {
  3859. Fresponse_type Tuint8_t
  3860. Frevert_to Tuint8_t
  3861. Fsequence Tuint16_t
  3862. Flength Tuint32_t
  3863. Ffocus Txcb_window_t
  3864. }
  3865. type Txcb_query_keymap_cookie_t = struct {
  3866. Fsequence uint32
  3867. }
  3868. type Txcb_query_keymap_request_t = struct {
  3869. Fmajor_opcode Tuint8_t
  3870. Fpad0 Tuint8_t
  3871. Flength Tuint16_t
  3872. }
  3873. type Txcb_query_keymap_reply_t = struct {
  3874. Fresponse_type Tuint8_t
  3875. Fpad0 Tuint8_t
  3876. Fsequence Tuint16_t
  3877. Flength Tuint32_t
  3878. Fkeys [32]Tuint8_t
  3879. }
  3880. type Txcb_open_font_request_t = struct {
  3881. Fmajor_opcode Tuint8_t
  3882. Fpad0 Tuint8_t
  3883. Flength Tuint16_t
  3884. Ffid Txcb_font_t
  3885. Fname_len Tuint16_t
  3886. Fpad1 [2]Tuint8_t
  3887. }
  3888. type Txcb_close_font_request_t = struct {
  3889. Fmajor_opcode Tuint8_t
  3890. Fpad0 Tuint8_t
  3891. Flength Tuint16_t
  3892. Ffont Txcb_font_t
  3893. }
  3894. type Txcb_font_draw_t = int32
  3895. type _xcb_font_draw_t = int32
  3896. const _XCB_FONT_DRAW_LEFT_TO_RIGHT = 0
  3897. const _XCB_FONT_DRAW_RIGHT_TO_LEFT = 1
  3898. type Txcb_fontprop_t = struct {
  3899. Fname Txcb_atom_t
  3900. Fvalue Tuint32_t
  3901. }
  3902. type Txcb_fontprop_iterator_t = struct {
  3903. Fdata uintptr
  3904. Frem int32
  3905. Findex int32
  3906. }
  3907. type Txcb_charinfo_t = struct {
  3908. Fleft_side_bearing Tint16_t
  3909. Fright_side_bearing Tint16_t
  3910. Fcharacter_width Tint16_t
  3911. Fascent Tint16_t
  3912. Fdescent Tint16_t
  3913. Fattributes Tuint16_t
  3914. }
  3915. type Txcb_charinfo_iterator_t = struct {
  3916. Fdata uintptr
  3917. Frem int32
  3918. Findex int32
  3919. }
  3920. type Txcb_query_font_cookie_t = struct {
  3921. Fsequence uint32
  3922. }
  3923. type Txcb_query_font_request_t = struct {
  3924. Fmajor_opcode Tuint8_t
  3925. Fpad0 Tuint8_t
  3926. Flength Tuint16_t
  3927. Ffont Txcb_fontable_t
  3928. }
  3929. type Txcb_query_font_reply_t = struct {
  3930. Fresponse_type Tuint8_t
  3931. Fpad0 Tuint8_t
  3932. Fsequence Tuint16_t
  3933. Flength Tuint32_t
  3934. Fmin_bounds Txcb_charinfo_t
  3935. Fpad1 [4]Tuint8_t
  3936. Fmax_bounds Txcb_charinfo_t
  3937. Fpad2 [4]Tuint8_t
  3938. Fmin_char_or_byte2 Tuint16_t
  3939. Fmax_char_or_byte2 Tuint16_t
  3940. Fdefault_char Tuint16_t
  3941. Fproperties_len Tuint16_t
  3942. Fdraw_direction Tuint8_t
  3943. Fmin_byte1 Tuint8_t
  3944. Fmax_byte1 Tuint8_t
  3945. Fall_chars_exist Tuint8_t
  3946. Ffont_ascent Tint16_t
  3947. Ffont_descent Tint16_t
  3948. Fchar_infos_len Tuint32_t
  3949. }
  3950. type Txcb_query_text_extents_cookie_t = struct {
  3951. Fsequence uint32
  3952. }
  3953. type Txcb_query_text_extents_request_t = struct {
  3954. Fmajor_opcode Tuint8_t
  3955. Fodd_length Tuint8_t
  3956. Flength Tuint16_t
  3957. Ffont Txcb_fontable_t
  3958. }
  3959. type Txcb_query_text_extents_reply_t = struct {
  3960. Fresponse_type Tuint8_t
  3961. Fdraw_direction Tuint8_t
  3962. Fsequence Tuint16_t
  3963. Flength Tuint32_t
  3964. Ffont_ascent Tint16_t
  3965. Ffont_descent Tint16_t
  3966. Foverall_ascent Tint16_t
  3967. Foverall_descent Tint16_t
  3968. Foverall_width Tint32_t
  3969. Foverall_left Tint32_t
  3970. Foverall_right Tint32_t
  3971. }
  3972. type Txcb_str_t = struct {
  3973. Fname_len Tuint8_t
  3974. }
  3975. type Txcb_str_iterator_t = struct {
  3976. Fdata uintptr
  3977. Frem int32
  3978. Findex int32
  3979. }
  3980. type Txcb_list_fonts_cookie_t = struct {
  3981. Fsequence uint32
  3982. }
  3983. type Txcb_list_fonts_request_t = struct {
  3984. Fmajor_opcode Tuint8_t
  3985. Fpad0 Tuint8_t
  3986. Flength Tuint16_t
  3987. Fmax_names Tuint16_t
  3988. Fpattern_len Tuint16_t
  3989. }
  3990. type Txcb_list_fonts_reply_t = struct {
  3991. Fresponse_type Tuint8_t
  3992. Fpad0 Tuint8_t
  3993. Fsequence Tuint16_t
  3994. Flength Tuint32_t
  3995. Fnames_len Tuint16_t
  3996. Fpad1 [22]Tuint8_t
  3997. }
  3998. type Txcb_list_fonts_with_info_cookie_t = struct {
  3999. Fsequence uint32
  4000. }
  4001. type Txcb_list_fonts_with_info_request_t = struct {
  4002. Fmajor_opcode Tuint8_t
  4003. Fpad0 Tuint8_t
  4004. Flength Tuint16_t
  4005. Fmax_names Tuint16_t
  4006. Fpattern_len Tuint16_t
  4007. }
  4008. type Txcb_list_fonts_with_info_reply_t = struct {
  4009. Fresponse_type Tuint8_t
  4010. Fname_len Tuint8_t
  4011. Fsequence Tuint16_t
  4012. Flength Tuint32_t
  4013. Fmin_bounds Txcb_charinfo_t
  4014. Fpad0 [4]Tuint8_t
  4015. Fmax_bounds Txcb_charinfo_t
  4016. Fpad1 [4]Tuint8_t
  4017. Fmin_char_or_byte2 Tuint16_t
  4018. Fmax_char_or_byte2 Tuint16_t
  4019. Fdefault_char Tuint16_t
  4020. Fproperties_len Tuint16_t
  4021. Fdraw_direction Tuint8_t
  4022. Fmin_byte1 Tuint8_t
  4023. Fmax_byte1 Tuint8_t
  4024. Fall_chars_exist Tuint8_t
  4025. Ffont_ascent Tint16_t
  4026. Ffont_descent Tint16_t
  4027. Freplies_hint Tuint32_t
  4028. }
  4029. type Txcb_set_font_path_request_t = struct {
  4030. Fmajor_opcode Tuint8_t
  4031. Fpad0 Tuint8_t
  4032. Flength Tuint16_t
  4033. Ffont_qty Tuint16_t
  4034. Fpad1 [2]Tuint8_t
  4035. }
  4036. type Txcb_get_font_path_cookie_t = struct {
  4037. Fsequence uint32
  4038. }
  4039. type Txcb_get_font_path_request_t = struct {
  4040. Fmajor_opcode Tuint8_t
  4041. Fpad0 Tuint8_t
  4042. Flength Tuint16_t
  4043. }
  4044. type Txcb_get_font_path_reply_t = struct {
  4045. Fresponse_type Tuint8_t
  4046. Fpad0 Tuint8_t
  4047. Fsequence Tuint16_t
  4048. Flength Tuint32_t
  4049. Fpath_len Tuint16_t
  4050. Fpad1 [22]Tuint8_t
  4051. }
  4052. type Txcb_create_pixmap_request_t = struct {
  4053. Fmajor_opcode Tuint8_t
  4054. Fdepth Tuint8_t
  4055. Flength Tuint16_t
  4056. Fpid Txcb_pixmap_t
  4057. Fdrawable Txcb_drawable_t
  4058. Fwidth Tuint16_t
  4059. Fheight Tuint16_t
  4060. }
  4061. type Txcb_free_pixmap_request_t = struct {
  4062. Fmajor_opcode Tuint8_t
  4063. Fpad0 Tuint8_t
  4064. Flength Tuint16_t
  4065. Fpixmap Txcb_pixmap_t
  4066. }
  4067. type Txcb_gc_t = int32
  4068. type _xcb_gc_t = int32
  4069. const _XCB_GC_FUNCTION = 1
  4070. const _XCB_GC_PLANE_MASK = 2
  4071. const _XCB_GC_FOREGROUND = 4
  4072. const _XCB_GC_BACKGROUND = 8
  4073. const _XCB_GC_LINE_WIDTH = 16
  4074. const _XCB_GC_LINE_STYLE = 32
  4075. const _XCB_GC_CAP_STYLE = 64
  4076. const _XCB_GC_JOIN_STYLE = 128
  4077. const _XCB_GC_FILL_STYLE = 256
  4078. const _XCB_GC_FILL_RULE = 512
  4079. const _XCB_GC_TILE = 1024
  4080. const _XCB_GC_STIPPLE = 2048
  4081. const _XCB_GC_TILE_STIPPLE_ORIGIN_X = 4096
  4082. const _XCB_GC_TILE_STIPPLE_ORIGIN_Y = 8192
  4083. const _XCB_GC_FONT = 16384
  4084. const _XCB_GC_SUBWINDOW_MODE = 32768
  4085. const _XCB_GC_GRAPHICS_EXPOSURES = 65536
  4086. const _XCB_GC_CLIP_ORIGIN_X = 131072
  4087. const _XCB_GC_CLIP_ORIGIN_Y = 262144
  4088. const _XCB_GC_CLIP_MASK = 524288
  4089. const _XCB_GC_DASH_OFFSET = 1048576
  4090. const _XCB_GC_DASH_LIST = 2097152
  4091. const _XCB_GC_ARC_MODE = 4194304
  4092. type Txcb_gx_t = int32
  4093. type _xcb_gx_t = int32
  4094. const _XCB_GX_CLEAR = 0
  4095. const _XCB_GX_AND = 1
  4096. const _XCB_GX_AND_REVERSE = 2
  4097. const _XCB_GX_COPY = 3
  4098. const _XCB_GX_AND_INVERTED = 4
  4099. const _XCB_GX_NOOP = 5
  4100. const _XCB_GX_XOR = 6
  4101. const _XCB_GX_OR = 7
  4102. const _XCB_GX_NOR = 8
  4103. const _XCB_GX_EQUIV = 9
  4104. const _XCB_GX_INVERT = 10
  4105. const _XCB_GX_OR_REVERSE = 11
  4106. const _XCB_GX_COPY_INVERTED = 12
  4107. const _XCB_GX_OR_INVERTED = 13
  4108. const _XCB_GX_NAND = 14
  4109. const _XCB_GX_SET = 15
  4110. type Txcb_line_style_t = int32
  4111. type _xcb_line_style_t = int32
  4112. const _XCB_LINE_STYLE_SOLID = 0
  4113. const _XCB_LINE_STYLE_ON_OFF_DASH = 1
  4114. const _XCB_LINE_STYLE_DOUBLE_DASH = 2
  4115. type Txcb_cap_style_t = int32
  4116. type _xcb_cap_style_t = int32
  4117. const _XCB_CAP_STYLE_NOT_LAST = 0
  4118. const _XCB_CAP_STYLE_BUTT = 1
  4119. const _XCB_CAP_STYLE_ROUND = 2
  4120. const _XCB_CAP_STYLE_PROJECTING = 3
  4121. type Txcb_join_style_t = int32
  4122. type _xcb_join_style_t = int32
  4123. const _XCB_JOIN_STYLE_MITER = 0
  4124. const _XCB_JOIN_STYLE_ROUND = 1
  4125. const _XCB_JOIN_STYLE_BEVEL = 2
  4126. type Txcb_fill_style_t = int32
  4127. type _xcb_fill_style_t = int32
  4128. const _XCB_FILL_STYLE_SOLID = 0
  4129. const _XCB_FILL_STYLE_TILED = 1
  4130. const _XCB_FILL_STYLE_STIPPLED = 2
  4131. const _XCB_FILL_STYLE_OPAQUE_STIPPLED = 3
  4132. type Txcb_fill_rule_t = int32
  4133. type _xcb_fill_rule_t = int32
  4134. const _XCB_FILL_RULE_EVEN_ODD = 0
  4135. const _XCB_FILL_RULE_WINDING = 1
  4136. type Txcb_subwindow_mode_t = int32
  4137. type _xcb_subwindow_mode_t = int32
  4138. const _XCB_SUBWINDOW_MODE_CLIP_BY_CHILDREN = 0
  4139. const _XCB_SUBWINDOW_MODE_INCLUDE_INFERIORS = 1
  4140. type Txcb_arc_mode_t = int32
  4141. type _xcb_arc_mode_t = int32
  4142. const _XCB_ARC_MODE_CHORD = 0
  4143. const _XCB_ARC_MODE_PIE_SLICE = 1
  4144. type Txcb_create_gc_value_list_t = struct {
  4145. Ffunction Tuint32_t
  4146. Fplane_mask Tuint32_t
  4147. Fforeground Tuint32_t
  4148. Fbackground Tuint32_t
  4149. Fline_width Tuint32_t
  4150. Fline_style Tuint32_t
  4151. Fcap_style Tuint32_t
  4152. Fjoin_style Tuint32_t
  4153. Ffill_style Tuint32_t
  4154. Ffill_rule Tuint32_t
  4155. Ftile Txcb_pixmap_t
  4156. Fstipple Txcb_pixmap_t
  4157. Ftile_stipple_x_origin Tint32_t
  4158. Ftile_stipple_y_origin Tint32_t
  4159. Ffont Txcb_font_t
  4160. Fsubwindow_mode Tuint32_t
  4161. Fgraphics_exposures Txcb_bool32_t
  4162. Fclip_x_origin Tint32_t
  4163. Fclip_y_origin Tint32_t
  4164. Fclip_mask Txcb_pixmap_t
  4165. Fdash_offset Tuint32_t
  4166. Fdashes Tuint32_t
  4167. Farc_mode Tuint32_t
  4168. }
  4169. type Txcb_create_gc_request_t = struct {
  4170. Fmajor_opcode Tuint8_t
  4171. Fpad0 Tuint8_t
  4172. Flength Tuint16_t
  4173. Fcid Txcb_gcontext_t
  4174. Fdrawable Txcb_drawable_t
  4175. Fvalue_mask Tuint32_t
  4176. }
  4177. type Txcb_change_gc_value_list_t = struct {
  4178. Ffunction Tuint32_t
  4179. Fplane_mask Tuint32_t
  4180. Fforeground Tuint32_t
  4181. Fbackground Tuint32_t
  4182. Fline_width Tuint32_t
  4183. Fline_style Tuint32_t
  4184. Fcap_style Tuint32_t
  4185. Fjoin_style Tuint32_t
  4186. Ffill_style Tuint32_t
  4187. Ffill_rule Tuint32_t
  4188. Ftile Txcb_pixmap_t
  4189. Fstipple Txcb_pixmap_t
  4190. Ftile_stipple_x_origin Tint32_t
  4191. Ftile_stipple_y_origin Tint32_t
  4192. Ffont Txcb_font_t
  4193. Fsubwindow_mode Tuint32_t
  4194. Fgraphics_exposures Txcb_bool32_t
  4195. Fclip_x_origin Tint32_t
  4196. Fclip_y_origin Tint32_t
  4197. Fclip_mask Txcb_pixmap_t
  4198. Fdash_offset Tuint32_t
  4199. Fdashes Tuint32_t
  4200. Farc_mode Tuint32_t
  4201. }
  4202. type Txcb_change_gc_request_t = struct {
  4203. Fmajor_opcode Tuint8_t
  4204. Fpad0 Tuint8_t
  4205. Flength Tuint16_t
  4206. Fgc Txcb_gcontext_t
  4207. Fvalue_mask Tuint32_t
  4208. }
  4209. type Txcb_copy_gc_request_t = struct {
  4210. Fmajor_opcode Tuint8_t
  4211. Fpad0 Tuint8_t
  4212. Flength Tuint16_t
  4213. Fsrc_gc Txcb_gcontext_t
  4214. Fdst_gc Txcb_gcontext_t
  4215. Fvalue_mask Tuint32_t
  4216. }
  4217. type Txcb_set_dashes_request_t = struct {
  4218. Fmajor_opcode Tuint8_t
  4219. Fpad0 Tuint8_t
  4220. Flength Tuint16_t
  4221. Fgc Txcb_gcontext_t
  4222. Fdash_offset Tuint16_t
  4223. Fdashes_len Tuint16_t
  4224. }
  4225. type Txcb_clip_ordering_t = int32
  4226. type _xcb_clip_ordering_t = int32
  4227. const _XCB_CLIP_ORDERING_UNSORTED = 0
  4228. const _XCB_CLIP_ORDERING_Y_SORTED = 1
  4229. const _XCB_CLIP_ORDERING_YX_SORTED = 2
  4230. const _XCB_CLIP_ORDERING_YX_BANDED = 3
  4231. type Txcb_set_clip_rectangles_request_t = struct {
  4232. Fmajor_opcode Tuint8_t
  4233. Fordering Tuint8_t
  4234. Flength Tuint16_t
  4235. Fgc Txcb_gcontext_t
  4236. Fclip_x_origin Tint16_t
  4237. Fclip_y_origin Tint16_t
  4238. }
  4239. type Txcb_free_gc_request_t = struct {
  4240. Fmajor_opcode Tuint8_t
  4241. Fpad0 Tuint8_t
  4242. Flength Tuint16_t
  4243. Fgc Txcb_gcontext_t
  4244. }
  4245. type Txcb_clear_area_request_t = struct {
  4246. Fmajor_opcode Tuint8_t
  4247. Fexposures Tuint8_t
  4248. Flength Tuint16_t
  4249. Fwindow Txcb_window_t
  4250. Fx Tint16_t
  4251. Fy Tint16_t
  4252. Fwidth Tuint16_t
  4253. Fheight Tuint16_t
  4254. }
  4255. type Txcb_copy_area_request_t = struct {
  4256. Fmajor_opcode Tuint8_t
  4257. Fpad0 Tuint8_t
  4258. Flength Tuint16_t
  4259. Fsrc_drawable Txcb_drawable_t
  4260. Fdst_drawable Txcb_drawable_t
  4261. Fgc Txcb_gcontext_t
  4262. Fsrc_x Tint16_t
  4263. Fsrc_y Tint16_t
  4264. Fdst_x Tint16_t
  4265. Fdst_y Tint16_t
  4266. Fwidth Tuint16_t
  4267. Fheight Tuint16_t
  4268. }
  4269. type Txcb_copy_plane_request_t = struct {
  4270. Fmajor_opcode Tuint8_t
  4271. Fpad0 Tuint8_t
  4272. Flength Tuint16_t
  4273. Fsrc_drawable Txcb_drawable_t
  4274. Fdst_drawable Txcb_drawable_t
  4275. Fgc Txcb_gcontext_t
  4276. Fsrc_x Tint16_t
  4277. Fsrc_y Tint16_t
  4278. Fdst_x Tint16_t
  4279. Fdst_y Tint16_t
  4280. Fwidth Tuint16_t
  4281. Fheight Tuint16_t
  4282. Fbit_plane Tuint32_t
  4283. }
  4284. type Txcb_coord_mode_t = int32
  4285. type _xcb_coord_mode_t = int32
  4286. const _XCB_COORD_MODE_ORIGIN = 0
  4287. const _XCB_COORD_MODE_PREVIOUS = 1
  4288. type Txcb_poly_point_request_t = struct {
  4289. Fmajor_opcode Tuint8_t
  4290. Fcoordinate_mode Tuint8_t
  4291. Flength Tuint16_t
  4292. Fdrawable Txcb_drawable_t
  4293. Fgc Txcb_gcontext_t
  4294. }
  4295. type Txcb_poly_line_request_t = struct {
  4296. Fmajor_opcode Tuint8_t
  4297. Fcoordinate_mode Tuint8_t
  4298. Flength Tuint16_t
  4299. Fdrawable Txcb_drawable_t
  4300. Fgc Txcb_gcontext_t
  4301. }
  4302. type Txcb_segment_t = struct {
  4303. Fx1 Tint16_t
  4304. Fy1 Tint16_t
  4305. Fx2 Tint16_t
  4306. Fy2 Tint16_t
  4307. }
  4308. type Txcb_segment_iterator_t = struct {
  4309. Fdata uintptr
  4310. Frem int32
  4311. Findex int32
  4312. }
  4313. type Txcb_poly_segment_request_t = struct {
  4314. Fmajor_opcode Tuint8_t
  4315. Fpad0 Tuint8_t
  4316. Flength Tuint16_t
  4317. Fdrawable Txcb_drawable_t
  4318. Fgc Txcb_gcontext_t
  4319. }
  4320. type Txcb_poly_rectangle_request_t = struct {
  4321. Fmajor_opcode Tuint8_t
  4322. Fpad0 Tuint8_t
  4323. Flength Tuint16_t
  4324. Fdrawable Txcb_drawable_t
  4325. Fgc Txcb_gcontext_t
  4326. }
  4327. type Txcb_poly_arc_request_t = struct {
  4328. Fmajor_opcode Tuint8_t
  4329. Fpad0 Tuint8_t
  4330. Flength Tuint16_t
  4331. Fdrawable Txcb_drawable_t
  4332. Fgc Txcb_gcontext_t
  4333. }
  4334. type Txcb_poly_shape_t = int32
  4335. type _xcb_poly_shape_t = int32
  4336. const _XCB_POLY_SHAPE_COMPLEX = 0
  4337. const _XCB_POLY_SHAPE_NONCONVEX = 1
  4338. const _XCB_POLY_SHAPE_CONVEX = 2
  4339. type Txcb_fill_poly_request_t = struct {
  4340. Fmajor_opcode Tuint8_t
  4341. Fpad0 Tuint8_t
  4342. Flength Tuint16_t
  4343. Fdrawable Txcb_drawable_t
  4344. Fgc Txcb_gcontext_t
  4345. Fshape Tuint8_t
  4346. Fcoordinate_mode Tuint8_t
  4347. Fpad1 [2]Tuint8_t
  4348. }
  4349. type Txcb_poly_fill_rectangle_request_t = struct {
  4350. Fmajor_opcode Tuint8_t
  4351. Fpad0 Tuint8_t
  4352. Flength Tuint16_t
  4353. Fdrawable Txcb_drawable_t
  4354. Fgc Txcb_gcontext_t
  4355. }
  4356. type Txcb_poly_fill_arc_request_t = struct {
  4357. Fmajor_opcode Tuint8_t
  4358. Fpad0 Tuint8_t
  4359. Flength Tuint16_t
  4360. Fdrawable Txcb_drawable_t
  4361. Fgc Txcb_gcontext_t
  4362. }
  4363. type Txcb_image_format_t = int32
  4364. type _xcb_image_format_t = int32
  4365. const _XCB_IMAGE_FORMAT_XY_BITMAP = 0
  4366. const _XCB_IMAGE_FORMAT_XY_PIXMAP = 1
  4367. const _XCB_IMAGE_FORMAT_Z_PIXMAP = 2
  4368. type Txcb_put_image_request_t = struct {
  4369. Fmajor_opcode Tuint8_t
  4370. Fformat Tuint8_t
  4371. Flength Tuint16_t
  4372. Fdrawable Txcb_drawable_t
  4373. Fgc Txcb_gcontext_t
  4374. Fwidth Tuint16_t
  4375. Fheight Tuint16_t
  4376. Fdst_x Tint16_t
  4377. Fdst_y Tint16_t
  4378. Fleft_pad Tuint8_t
  4379. Fdepth Tuint8_t
  4380. Fpad0 [2]Tuint8_t
  4381. }
  4382. type Txcb_get_image_cookie_t = struct {
  4383. Fsequence uint32
  4384. }
  4385. type Txcb_get_image_request_t = struct {
  4386. Fmajor_opcode Tuint8_t
  4387. Fformat Tuint8_t
  4388. Flength Tuint16_t
  4389. Fdrawable Txcb_drawable_t
  4390. Fx Tint16_t
  4391. Fy Tint16_t
  4392. Fwidth Tuint16_t
  4393. Fheight Tuint16_t
  4394. Fplane_mask Tuint32_t
  4395. }
  4396. type Txcb_get_image_reply_t = struct {
  4397. Fresponse_type Tuint8_t
  4398. Fdepth Tuint8_t
  4399. Fsequence Tuint16_t
  4400. Flength Tuint32_t
  4401. Fvisual Txcb_visualid_t
  4402. Fpad0 [20]Tuint8_t
  4403. }
  4404. type Txcb_poly_text_8_request_t = struct {
  4405. Fmajor_opcode Tuint8_t
  4406. Fpad0 Tuint8_t
  4407. Flength Tuint16_t
  4408. Fdrawable Txcb_drawable_t
  4409. Fgc Txcb_gcontext_t
  4410. Fx Tint16_t
  4411. Fy Tint16_t
  4412. }
  4413. type Txcb_poly_text_16_request_t = struct {
  4414. Fmajor_opcode Tuint8_t
  4415. Fpad0 Tuint8_t
  4416. Flength Tuint16_t
  4417. Fdrawable Txcb_drawable_t
  4418. Fgc Txcb_gcontext_t
  4419. Fx Tint16_t
  4420. Fy Tint16_t
  4421. }
  4422. type Txcb_image_text_8_request_t = struct {
  4423. Fmajor_opcode Tuint8_t
  4424. Fstring_len Tuint8_t
  4425. Flength Tuint16_t
  4426. Fdrawable Txcb_drawable_t
  4427. Fgc Txcb_gcontext_t
  4428. Fx Tint16_t
  4429. Fy Tint16_t
  4430. }
  4431. type Txcb_image_text_16_request_t = struct {
  4432. Fmajor_opcode Tuint8_t
  4433. Fstring_len Tuint8_t
  4434. Flength Tuint16_t
  4435. Fdrawable Txcb_drawable_t
  4436. Fgc Txcb_gcontext_t
  4437. Fx Tint16_t
  4438. Fy Tint16_t
  4439. }
  4440. type Txcb_colormap_alloc_t = int32
  4441. type _xcb_colormap_alloc_t = int32
  4442. const _XCB_COLORMAP_ALLOC_NONE = 0
  4443. const _XCB_COLORMAP_ALLOC_ALL = 1
  4444. type Txcb_create_colormap_request_t = struct {
  4445. Fmajor_opcode Tuint8_t
  4446. Falloc Tuint8_t
  4447. Flength Tuint16_t
  4448. Fmid Txcb_colormap_t
  4449. Fwindow Txcb_window_t
  4450. Fvisual Txcb_visualid_t
  4451. }
  4452. type Txcb_free_colormap_request_t = struct {
  4453. Fmajor_opcode Tuint8_t
  4454. Fpad0 Tuint8_t
  4455. Flength Tuint16_t
  4456. Fcmap Txcb_colormap_t
  4457. }
  4458. type Txcb_copy_colormap_and_free_request_t = struct {
  4459. Fmajor_opcode Tuint8_t
  4460. Fpad0 Tuint8_t
  4461. Flength Tuint16_t
  4462. Fmid Txcb_colormap_t
  4463. Fsrc_cmap Txcb_colormap_t
  4464. }
  4465. type Txcb_install_colormap_request_t = struct {
  4466. Fmajor_opcode Tuint8_t
  4467. Fpad0 Tuint8_t
  4468. Flength Tuint16_t
  4469. Fcmap Txcb_colormap_t
  4470. }
  4471. type Txcb_uninstall_colormap_request_t = struct {
  4472. Fmajor_opcode Tuint8_t
  4473. Fpad0 Tuint8_t
  4474. Flength Tuint16_t
  4475. Fcmap Txcb_colormap_t
  4476. }
  4477. type Txcb_list_installed_colormaps_cookie_t = struct {
  4478. Fsequence uint32
  4479. }
  4480. type Txcb_list_installed_colormaps_request_t = struct {
  4481. Fmajor_opcode Tuint8_t
  4482. Fpad0 Tuint8_t
  4483. Flength Tuint16_t
  4484. Fwindow Txcb_window_t
  4485. }
  4486. type Txcb_list_installed_colormaps_reply_t = struct {
  4487. Fresponse_type Tuint8_t
  4488. Fpad0 Tuint8_t
  4489. Fsequence Tuint16_t
  4490. Flength Tuint32_t
  4491. Fcmaps_len Tuint16_t
  4492. Fpad1 [22]Tuint8_t
  4493. }
  4494. type Txcb_alloc_color_cookie_t = struct {
  4495. Fsequence uint32
  4496. }
  4497. type Txcb_alloc_color_request_t = struct {
  4498. Fmajor_opcode Tuint8_t
  4499. Fpad0 Tuint8_t
  4500. Flength Tuint16_t
  4501. Fcmap Txcb_colormap_t
  4502. Fred Tuint16_t
  4503. Fgreen Tuint16_t
  4504. Fblue Tuint16_t
  4505. Fpad1 [2]Tuint8_t
  4506. }
  4507. type Txcb_alloc_color_reply_t = struct {
  4508. Fresponse_type Tuint8_t
  4509. Fpad0 Tuint8_t
  4510. Fsequence Tuint16_t
  4511. Flength Tuint32_t
  4512. Fred Tuint16_t
  4513. Fgreen Tuint16_t
  4514. Fblue Tuint16_t
  4515. Fpad1 [2]Tuint8_t
  4516. Fpixel Tuint32_t
  4517. }
  4518. type Txcb_alloc_named_color_cookie_t = struct {
  4519. Fsequence uint32
  4520. }
  4521. type Txcb_alloc_named_color_request_t = struct {
  4522. Fmajor_opcode Tuint8_t
  4523. Fpad0 Tuint8_t
  4524. Flength Tuint16_t
  4525. Fcmap Txcb_colormap_t
  4526. Fname_len Tuint16_t
  4527. Fpad1 [2]Tuint8_t
  4528. }
  4529. type Txcb_alloc_named_color_reply_t = struct {
  4530. Fresponse_type Tuint8_t
  4531. Fpad0 Tuint8_t
  4532. Fsequence Tuint16_t
  4533. Flength Tuint32_t
  4534. Fpixel Tuint32_t
  4535. Fexact_red Tuint16_t
  4536. Fexact_green Tuint16_t
  4537. Fexact_blue Tuint16_t
  4538. Fvisual_red Tuint16_t
  4539. Fvisual_green Tuint16_t
  4540. Fvisual_blue Tuint16_t
  4541. }
  4542. type Txcb_alloc_color_cells_cookie_t = struct {
  4543. Fsequence uint32
  4544. }
  4545. type Txcb_alloc_color_cells_request_t = struct {
  4546. Fmajor_opcode Tuint8_t
  4547. Fcontiguous Tuint8_t
  4548. Flength Tuint16_t
  4549. Fcmap Txcb_colormap_t
  4550. Fcolors Tuint16_t
  4551. Fplanes Tuint16_t
  4552. }
  4553. type Txcb_alloc_color_cells_reply_t = struct {
  4554. Fresponse_type Tuint8_t
  4555. Fpad0 Tuint8_t
  4556. Fsequence Tuint16_t
  4557. Flength Tuint32_t
  4558. Fpixels_len Tuint16_t
  4559. Fmasks_len Tuint16_t
  4560. Fpad1 [20]Tuint8_t
  4561. }
  4562. type Txcb_alloc_color_planes_cookie_t = struct {
  4563. Fsequence uint32
  4564. }
  4565. type Txcb_alloc_color_planes_request_t = struct {
  4566. Fmajor_opcode Tuint8_t
  4567. Fcontiguous Tuint8_t
  4568. Flength Tuint16_t
  4569. Fcmap Txcb_colormap_t
  4570. Fcolors Tuint16_t
  4571. Freds Tuint16_t
  4572. Fgreens Tuint16_t
  4573. Fblues Tuint16_t
  4574. }
  4575. type Txcb_alloc_color_planes_reply_t = struct {
  4576. Fresponse_type Tuint8_t
  4577. Fpad0 Tuint8_t
  4578. Fsequence Tuint16_t
  4579. Flength Tuint32_t
  4580. Fpixels_len Tuint16_t
  4581. Fpad1 [2]Tuint8_t
  4582. Fred_mask Tuint32_t
  4583. Fgreen_mask Tuint32_t
  4584. Fblue_mask Tuint32_t
  4585. Fpad2 [8]Tuint8_t
  4586. }
  4587. type Txcb_free_colors_request_t = struct {
  4588. Fmajor_opcode Tuint8_t
  4589. Fpad0 Tuint8_t
  4590. Flength Tuint16_t
  4591. Fcmap Txcb_colormap_t
  4592. Fplane_mask Tuint32_t
  4593. }
  4594. type Txcb_color_flag_t = int32
  4595. type _xcb_color_flag_t = int32
  4596. const _XCB_COLOR_FLAG_RED = 1
  4597. const _XCB_COLOR_FLAG_GREEN = 2
  4598. const _XCB_COLOR_FLAG_BLUE = 4
  4599. type Txcb_coloritem_t = struct {
  4600. Fpixel Tuint32_t
  4601. Fred Tuint16_t
  4602. Fgreen Tuint16_t
  4603. Fblue Tuint16_t
  4604. Fflags Tuint8_t
  4605. Fpad0 Tuint8_t
  4606. }
  4607. type Txcb_coloritem_iterator_t = struct {
  4608. Fdata uintptr
  4609. Frem int32
  4610. Findex int32
  4611. }
  4612. type Txcb_store_colors_request_t = struct {
  4613. Fmajor_opcode Tuint8_t
  4614. Fpad0 Tuint8_t
  4615. Flength Tuint16_t
  4616. Fcmap Txcb_colormap_t
  4617. }
  4618. type Txcb_store_named_color_request_t = struct {
  4619. Fmajor_opcode Tuint8_t
  4620. Fflags Tuint8_t
  4621. Flength Tuint16_t
  4622. Fcmap Txcb_colormap_t
  4623. Fpixel Tuint32_t
  4624. Fname_len Tuint16_t
  4625. Fpad0 [2]Tuint8_t
  4626. }
  4627. type Txcb_rgb_t = struct {
  4628. Fred Tuint16_t
  4629. Fgreen Tuint16_t
  4630. Fblue Tuint16_t
  4631. Fpad0 [2]Tuint8_t
  4632. }
  4633. type Txcb_rgb_iterator_t = struct {
  4634. Fdata uintptr
  4635. Frem int32
  4636. Findex int32
  4637. }
  4638. type Txcb_query_colors_cookie_t = struct {
  4639. Fsequence uint32
  4640. }
  4641. type Txcb_query_colors_request_t = struct {
  4642. Fmajor_opcode Tuint8_t
  4643. Fpad0 Tuint8_t
  4644. Flength Tuint16_t
  4645. Fcmap Txcb_colormap_t
  4646. }
  4647. type Txcb_query_colors_reply_t = struct {
  4648. Fresponse_type Tuint8_t
  4649. Fpad0 Tuint8_t
  4650. Fsequence Tuint16_t
  4651. Flength Tuint32_t
  4652. Fcolors_len Tuint16_t
  4653. Fpad1 [22]Tuint8_t
  4654. }
  4655. type Txcb_lookup_color_cookie_t = struct {
  4656. Fsequence uint32
  4657. }
  4658. type Txcb_lookup_color_request_t = struct {
  4659. Fmajor_opcode Tuint8_t
  4660. Fpad0 Tuint8_t
  4661. Flength Tuint16_t
  4662. Fcmap Txcb_colormap_t
  4663. Fname_len Tuint16_t
  4664. Fpad1 [2]Tuint8_t
  4665. }
  4666. type Txcb_lookup_color_reply_t = struct {
  4667. Fresponse_type Tuint8_t
  4668. Fpad0 Tuint8_t
  4669. Fsequence Tuint16_t
  4670. Flength Tuint32_t
  4671. Fexact_red Tuint16_t
  4672. Fexact_green Tuint16_t
  4673. Fexact_blue Tuint16_t
  4674. Fvisual_red Tuint16_t
  4675. Fvisual_green Tuint16_t
  4676. Fvisual_blue Tuint16_t
  4677. }
  4678. type Txcb_pixmap_enum_t = int32
  4679. type _xcb_pixmap_enum_t = int32
  4680. const _XCB_PIXMAP_NONE = 0
  4681. type Txcb_create_cursor_request_t = struct {
  4682. Fmajor_opcode Tuint8_t
  4683. Fpad0 Tuint8_t
  4684. Flength Tuint16_t
  4685. Fcid Txcb_cursor_t
  4686. Fsource Txcb_pixmap_t
  4687. Fmask Txcb_pixmap_t
  4688. Ffore_red Tuint16_t
  4689. Ffore_green Tuint16_t
  4690. Ffore_blue Tuint16_t
  4691. Fback_red Tuint16_t
  4692. Fback_green Tuint16_t
  4693. Fback_blue Tuint16_t
  4694. Fx Tuint16_t
  4695. Fy Tuint16_t
  4696. }
  4697. type Txcb_font_enum_t = int32
  4698. type _xcb_font_enum_t = int32
  4699. const _XCB_FONT_NONE = 0
  4700. type Txcb_create_glyph_cursor_request_t = struct {
  4701. Fmajor_opcode Tuint8_t
  4702. Fpad0 Tuint8_t
  4703. Flength Tuint16_t
  4704. Fcid Txcb_cursor_t
  4705. Fsource_font Txcb_font_t
  4706. Fmask_font Txcb_font_t
  4707. Fsource_char Tuint16_t
  4708. Fmask_char Tuint16_t
  4709. Ffore_red Tuint16_t
  4710. Ffore_green Tuint16_t
  4711. Ffore_blue Tuint16_t
  4712. Fback_red Tuint16_t
  4713. Fback_green Tuint16_t
  4714. Fback_blue Tuint16_t
  4715. }
  4716. type Txcb_free_cursor_request_t = struct {
  4717. Fmajor_opcode Tuint8_t
  4718. Fpad0 Tuint8_t
  4719. Flength Tuint16_t
  4720. Fcursor Txcb_cursor_t
  4721. }
  4722. type Txcb_recolor_cursor_request_t = struct {
  4723. Fmajor_opcode Tuint8_t
  4724. Fpad0 Tuint8_t
  4725. Flength Tuint16_t
  4726. Fcursor Txcb_cursor_t
  4727. Ffore_red Tuint16_t
  4728. Ffore_green Tuint16_t
  4729. Ffore_blue Tuint16_t
  4730. Fback_red Tuint16_t
  4731. Fback_green Tuint16_t
  4732. Fback_blue Tuint16_t
  4733. }
  4734. type Txcb_query_shape_of_t = int32
  4735. type _xcb_query_shape_of_t = int32
  4736. const _XCB_QUERY_SHAPE_OF_LARGEST_CURSOR = 0
  4737. const _XCB_QUERY_SHAPE_OF_FASTEST_TILE = 1
  4738. const _XCB_QUERY_SHAPE_OF_FASTEST_STIPPLE = 2
  4739. type Txcb_query_best_size_cookie_t = struct {
  4740. Fsequence uint32
  4741. }
  4742. type Txcb_query_best_size_request_t = struct {
  4743. Fmajor_opcode Tuint8_t
  4744. F_class Tuint8_t
  4745. Flength Tuint16_t
  4746. Fdrawable Txcb_drawable_t
  4747. Fwidth Tuint16_t
  4748. Fheight Tuint16_t
  4749. }
  4750. type Txcb_query_best_size_reply_t = struct {
  4751. Fresponse_type Tuint8_t
  4752. Fpad0 Tuint8_t
  4753. Fsequence Tuint16_t
  4754. Flength Tuint32_t
  4755. Fwidth Tuint16_t
  4756. Fheight Tuint16_t
  4757. }
  4758. type Txcb_query_extension_cookie_t = struct {
  4759. Fsequence uint32
  4760. }
  4761. type Txcb_query_extension_request_t = struct {
  4762. Fmajor_opcode Tuint8_t
  4763. Fpad0 Tuint8_t
  4764. Flength Tuint16_t
  4765. Fname_len Tuint16_t
  4766. Fpad1 [2]Tuint8_t
  4767. }
  4768. type Txcb_query_extension_reply_t = struct {
  4769. Fresponse_type Tuint8_t
  4770. Fpad0 Tuint8_t
  4771. Fsequence Tuint16_t
  4772. Flength Tuint32_t
  4773. Fpresent Tuint8_t
  4774. Fmajor_opcode Tuint8_t
  4775. Ffirst_event Tuint8_t
  4776. Ffirst_error Tuint8_t
  4777. }
  4778. type Txcb_list_extensions_cookie_t = struct {
  4779. Fsequence uint32
  4780. }
  4781. type Txcb_list_extensions_request_t = struct {
  4782. Fmajor_opcode Tuint8_t
  4783. Fpad0 Tuint8_t
  4784. Flength Tuint16_t
  4785. }
  4786. type Txcb_list_extensions_reply_t = struct {
  4787. Fresponse_type Tuint8_t
  4788. Fnames_len Tuint8_t
  4789. Fsequence Tuint16_t
  4790. Flength Tuint32_t
  4791. Fpad0 [24]Tuint8_t
  4792. }
  4793. type Txcb_change_keyboard_mapping_request_t = struct {
  4794. Fmajor_opcode Tuint8_t
  4795. Fkeycode_count Tuint8_t
  4796. Flength Tuint16_t
  4797. Ffirst_keycode Txcb_keycode_t
  4798. Fkeysyms_per_keycode Tuint8_t
  4799. Fpad0 [2]Tuint8_t
  4800. }
  4801. type Txcb_get_keyboard_mapping_cookie_t = struct {
  4802. Fsequence uint32
  4803. }
  4804. type Txcb_get_keyboard_mapping_request_t = struct {
  4805. Fmajor_opcode Tuint8_t
  4806. Fpad0 Tuint8_t
  4807. Flength Tuint16_t
  4808. Ffirst_keycode Txcb_keycode_t
  4809. Fcount Tuint8_t
  4810. }
  4811. type Txcb_get_keyboard_mapping_reply_t = struct {
  4812. Fresponse_type Tuint8_t
  4813. Fkeysyms_per_keycode Tuint8_t
  4814. Fsequence Tuint16_t
  4815. Flength Tuint32_t
  4816. Fpad0 [24]Tuint8_t
  4817. }
  4818. type Txcb_kb_t = int32
  4819. type _xcb_kb_t = int32
  4820. const _XCB_KB_KEY_CLICK_PERCENT = 1
  4821. const _XCB_KB_BELL_PERCENT = 2
  4822. const _XCB_KB_BELL_PITCH = 4
  4823. const _XCB_KB_BELL_DURATION = 8
  4824. const _XCB_KB_LED = 16
  4825. const _XCB_KB_LED_MODE = 32
  4826. const _XCB_KB_KEY = 64
  4827. const _XCB_KB_AUTO_REPEAT_MODE = 128
  4828. type Txcb_led_mode_t = int32
  4829. type _xcb_led_mode_t = int32
  4830. const _XCB_LED_MODE_OFF = 0
  4831. const _XCB_LED_MODE_ON = 1
  4832. type Txcb_auto_repeat_mode_t = int32
  4833. type _xcb_auto_repeat_mode_t = int32
  4834. const _XCB_AUTO_REPEAT_MODE_OFF = 0
  4835. const _XCB_AUTO_REPEAT_MODE_ON = 1
  4836. const _XCB_AUTO_REPEAT_MODE_DEFAULT = 2
  4837. type Txcb_change_keyboard_control_value_list_t = struct {
  4838. Fkey_click_percent Tint32_t
  4839. Fbell_percent Tint32_t
  4840. Fbell_pitch Tint32_t
  4841. Fbell_duration Tint32_t
  4842. Fled Tuint32_t
  4843. Fled_mode Tuint32_t
  4844. Fkey Txcb_keycode32_t
  4845. Fauto_repeat_mode Tuint32_t
  4846. }
  4847. type Txcb_change_keyboard_control_request_t = struct {
  4848. Fmajor_opcode Tuint8_t
  4849. Fpad0 Tuint8_t
  4850. Flength Tuint16_t
  4851. Fvalue_mask Tuint32_t
  4852. }
  4853. type Txcb_get_keyboard_control_cookie_t = struct {
  4854. Fsequence uint32
  4855. }
  4856. type Txcb_get_keyboard_control_request_t = struct {
  4857. Fmajor_opcode Tuint8_t
  4858. Fpad0 Tuint8_t
  4859. Flength Tuint16_t
  4860. }
  4861. type Txcb_get_keyboard_control_reply_t = struct {
  4862. Fresponse_type Tuint8_t
  4863. Fglobal_auto_repeat Tuint8_t
  4864. Fsequence Tuint16_t
  4865. Flength Tuint32_t
  4866. Fled_mask Tuint32_t
  4867. Fkey_click_percent Tuint8_t
  4868. Fbell_percent Tuint8_t
  4869. Fbell_pitch Tuint16_t
  4870. Fbell_duration Tuint16_t
  4871. Fpad0 [2]Tuint8_t
  4872. Fauto_repeats [32]Tuint8_t
  4873. }
  4874. type Txcb_bell_request_t = struct {
  4875. Fmajor_opcode Tuint8_t
  4876. Fpercent Tint8_t
  4877. Flength Tuint16_t
  4878. }
  4879. type Txcb_change_pointer_control_request_t = struct {
  4880. Fmajor_opcode Tuint8_t
  4881. Fpad0 Tuint8_t
  4882. Flength Tuint16_t
  4883. Facceleration_numerator Tint16_t
  4884. Facceleration_denominator Tint16_t
  4885. Fthreshold Tint16_t
  4886. Fdo_acceleration Tuint8_t
  4887. Fdo_threshold Tuint8_t
  4888. }
  4889. type Txcb_get_pointer_control_cookie_t = struct {
  4890. Fsequence uint32
  4891. }
  4892. type Txcb_get_pointer_control_request_t = struct {
  4893. Fmajor_opcode Tuint8_t
  4894. Fpad0 Tuint8_t
  4895. Flength Tuint16_t
  4896. }
  4897. type Txcb_get_pointer_control_reply_t = struct {
  4898. Fresponse_type Tuint8_t
  4899. Fpad0 Tuint8_t
  4900. Fsequence Tuint16_t
  4901. Flength Tuint32_t
  4902. Facceleration_numerator Tuint16_t
  4903. Facceleration_denominator Tuint16_t
  4904. Fthreshold Tuint16_t
  4905. Fpad1 [18]Tuint8_t
  4906. }
  4907. type Txcb_blanking_t = int32
  4908. type _xcb_blanking_t = int32
  4909. const _XCB_BLANKING_NOT_PREFERRED = 0
  4910. const _XCB_BLANKING_PREFERRED = 1
  4911. const _XCB_BLANKING_DEFAULT = 2
  4912. type Txcb_exposures_t = int32
  4913. type _xcb_exposures_t = int32
  4914. const _XCB_EXPOSURES_NOT_ALLOWED = 0
  4915. const _XCB_EXPOSURES_ALLOWED = 1
  4916. const _XCB_EXPOSURES_DEFAULT = 2
  4917. type Txcb_set_screen_saver_request_t = struct {
  4918. Fmajor_opcode Tuint8_t
  4919. Fpad0 Tuint8_t
  4920. Flength Tuint16_t
  4921. Ftimeout Tint16_t
  4922. Finterval Tint16_t
  4923. Fprefer_blanking Tuint8_t
  4924. Fallow_exposures Tuint8_t
  4925. }
  4926. type Txcb_get_screen_saver_cookie_t = struct {
  4927. Fsequence uint32
  4928. }
  4929. type Txcb_get_screen_saver_request_t = struct {
  4930. Fmajor_opcode Tuint8_t
  4931. Fpad0 Tuint8_t
  4932. Flength Tuint16_t
  4933. }
  4934. type Txcb_get_screen_saver_reply_t = struct {
  4935. Fresponse_type Tuint8_t
  4936. Fpad0 Tuint8_t
  4937. Fsequence Tuint16_t
  4938. Flength Tuint32_t
  4939. Ftimeout Tuint16_t
  4940. Finterval Tuint16_t
  4941. Fprefer_blanking Tuint8_t
  4942. Fallow_exposures Tuint8_t
  4943. Fpad1 [18]Tuint8_t
  4944. }
  4945. type Txcb_host_mode_t = int32
  4946. type _xcb_host_mode_t = int32
  4947. const _XCB_HOST_MODE_INSERT = 0
  4948. const _XCB_HOST_MODE_DELETE = 1
  4949. type Txcb_family_t = int32
  4950. type _xcb_family_t = int32
  4951. const _XCB_FAMILY_INTERNET = 0
  4952. const _XCB_FAMILY_DECNET = 1
  4953. const _XCB_FAMILY_CHAOS = 2
  4954. const _XCB_FAMILY_SERVER_INTERPRETED = 5
  4955. const _XCB_FAMILY_INTERNET_6 = 6
  4956. type Txcb_change_hosts_request_t = struct {
  4957. Fmajor_opcode Tuint8_t
  4958. Fmode Tuint8_t
  4959. Flength Tuint16_t
  4960. Ffamily Tuint8_t
  4961. Fpad0 Tuint8_t
  4962. Faddress_len Tuint16_t
  4963. }
  4964. type Txcb_host_t = struct {
  4965. Ffamily Tuint8_t
  4966. Fpad0 Tuint8_t
  4967. Faddress_len Tuint16_t
  4968. }
  4969. type Txcb_host_iterator_t = struct {
  4970. Fdata uintptr
  4971. Frem int32
  4972. Findex int32
  4973. }
  4974. type Txcb_list_hosts_cookie_t = struct {
  4975. Fsequence uint32
  4976. }
  4977. type Txcb_list_hosts_request_t = struct {
  4978. Fmajor_opcode Tuint8_t
  4979. Fpad0 Tuint8_t
  4980. Flength Tuint16_t
  4981. }
  4982. type Txcb_list_hosts_reply_t = struct {
  4983. Fresponse_type Tuint8_t
  4984. Fmode Tuint8_t
  4985. Fsequence Tuint16_t
  4986. Flength Tuint32_t
  4987. Fhosts_len Tuint16_t
  4988. Fpad0 [22]Tuint8_t
  4989. }
  4990. type Txcb_access_control_t = int32
  4991. type _xcb_access_control_t = int32
  4992. const _XCB_ACCESS_CONTROL_DISABLE = 0
  4993. const _XCB_ACCESS_CONTROL_ENABLE = 1
  4994. type Txcb_set_access_control_request_t = struct {
  4995. Fmajor_opcode Tuint8_t
  4996. Fmode Tuint8_t
  4997. Flength Tuint16_t
  4998. }
  4999. type Txcb_close_down_t = int32
  5000. type _xcb_close_down_t = int32
  5001. const _XCB_CLOSE_DOWN_DESTROY_ALL = 0
  5002. const _XCB_CLOSE_DOWN_RETAIN_PERMANENT = 1
  5003. const _XCB_CLOSE_DOWN_RETAIN_TEMPORARY = 2
  5004. type Txcb_set_close_down_mode_request_t = struct {
  5005. Fmajor_opcode Tuint8_t
  5006. Fmode Tuint8_t
  5007. Flength Tuint16_t
  5008. }
  5009. type Txcb_kill_t = int32
  5010. type _xcb_kill_t = int32
  5011. const _XCB_KILL_ALL_TEMPORARY = 0
  5012. type Txcb_kill_client_request_t = struct {
  5013. Fmajor_opcode Tuint8_t
  5014. Fpad0 Tuint8_t
  5015. Flength Tuint16_t
  5016. Fresource Tuint32_t
  5017. }
  5018. type Txcb_rotate_properties_request_t = struct {
  5019. Fmajor_opcode Tuint8_t
  5020. Fpad0 Tuint8_t
  5021. Flength Tuint16_t
  5022. Fwindow Txcb_window_t
  5023. Fatoms_len Tuint16_t
  5024. Fdelta Tint16_t
  5025. }
  5026. type Txcb_screen_saver_t = int32
  5027. type _xcb_screen_saver_t = int32
  5028. const _XCB_SCREEN_SAVER_RESET = 0
  5029. const _XCB_SCREEN_SAVER_ACTIVE = 1
  5030. type Txcb_force_screen_saver_request_t = struct {
  5031. Fmajor_opcode Tuint8_t
  5032. Fmode Tuint8_t
  5033. Flength Tuint16_t
  5034. }
  5035. type Txcb_mapping_status_t = int32
  5036. type _xcb_mapping_status_t = int32
  5037. const _XCB_MAPPING_STATUS_SUCCESS = 0
  5038. const _XCB_MAPPING_STATUS_BUSY = 1
  5039. const _XCB_MAPPING_STATUS_FAILURE = 2
  5040. type Txcb_set_pointer_mapping_cookie_t = struct {
  5041. Fsequence uint32
  5042. }
  5043. type Txcb_set_pointer_mapping_request_t = struct {
  5044. Fmajor_opcode Tuint8_t
  5045. Fmap_len Tuint8_t
  5046. Flength Tuint16_t
  5047. }
  5048. type Txcb_set_pointer_mapping_reply_t = struct {
  5049. Fresponse_type Tuint8_t
  5050. Fstatus Tuint8_t
  5051. Fsequence Tuint16_t
  5052. Flength Tuint32_t
  5053. }
  5054. type Txcb_get_pointer_mapping_cookie_t = struct {
  5055. Fsequence uint32
  5056. }
  5057. type Txcb_get_pointer_mapping_request_t = struct {
  5058. Fmajor_opcode Tuint8_t
  5059. Fpad0 Tuint8_t
  5060. Flength Tuint16_t
  5061. }
  5062. type Txcb_get_pointer_mapping_reply_t = struct {
  5063. Fresponse_type Tuint8_t
  5064. Fmap_len Tuint8_t
  5065. Fsequence Tuint16_t
  5066. Flength Tuint32_t
  5067. Fpad0 [24]Tuint8_t
  5068. }
  5069. type Txcb_map_index_t = int32
  5070. type _xcb_map_index_t = int32
  5071. const _XCB_MAP_INDEX_SHIFT = 0
  5072. const _XCB_MAP_INDEX_LOCK = 1
  5073. const _XCB_MAP_INDEX_CONTROL = 2
  5074. const _XCB_MAP_INDEX_1 = 3
  5075. const _XCB_MAP_INDEX_2 = 4
  5076. const _XCB_MAP_INDEX_3 = 5
  5077. const _XCB_MAP_INDEX_4 = 6
  5078. const _XCB_MAP_INDEX_5 = 7
  5079. type Txcb_set_modifier_mapping_cookie_t = struct {
  5080. Fsequence uint32
  5081. }
  5082. type Txcb_set_modifier_mapping_request_t = struct {
  5083. Fmajor_opcode Tuint8_t
  5084. Fkeycodes_per_modifier Tuint8_t
  5085. Flength Tuint16_t
  5086. }
  5087. type Txcb_set_modifier_mapping_reply_t = struct {
  5088. Fresponse_type Tuint8_t
  5089. Fstatus Tuint8_t
  5090. Fsequence Tuint16_t
  5091. Flength Tuint32_t
  5092. }
  5093. type Txcb_get_modifier_mapping_cookie_t = struct {
  5094. Fsequence uint32
  5095. }
  5096. type Txcb_get_modifier_mapping_request_t = struct {
  5097. Fmajor_opcode Tuint8_t
  5098. Fpad0 Tuint8_t
  5099. Flength Tuint16_t
  5100. }
  5101. type Txcb_get_modifier_mapping_reply_t = struct {
  5102. Fresponse_type Tuint8_t
  5103. Fkeycodes_per_modifier Tuint8_t
  5104. Fsequence Tuint16_t
  5105. Flength Tuint32_t
  5106. Fpad0 [24]Tuint8_t
  5107. }
  5108. type Txcb_no_operation_request_t = struct {
  5109. Fmajor_opcode Tuint8_t
  5110. Fpad0 Tuint8_t
  5111. Flength Tuint16_t
  5112. }
  5113. type Txcb_auth_info_t = struct {
  5114. Fnamelen int32
  5115. Fname uintptr
  5116. Fdatalen int32
  5117. Fdata uintptr
  5118. }
  5119. type Txcb_big_requests_enable_cookie_t = struct {
  5120. Fsequence uint32
  5121. }
  5122. type Txcb_big_requests_enable_request_t = struct {
  5123. Fmajor_opcode Tuint8_t
  5124. Fminor_opcode Tuint8_t
  5125. Flength Tuint16_t
  5126. }
  5127. type Txcb_big_requests_enable_reply_t = struct {
  5128. Fresponse_type Tuint8_t
  5129. Fpad0 Tuint8_t
  5130. Fsequence Tuint16_t
  5131. Flength Tuint32_t
  5132. Fmaximum_request_length Tuint32_t
  5133. }
  5134. type _workarounds = int32
  5135. const _WORKAROUND_NONE = 0
  5136. const _WORKAROUND_GLX_GET_FB_CONFIGS_BUG = 1
  5137. const _WORKAROUND_EXTERNAL_SOCKET_OWNER = 2
  5138. type _lazy_reply_tag = int32
  5139. const _LAZY_NONE = 0
  5140. const _LAZY_COOKIE = 1
  5141. const _LAZY_FORCED = 2
  5142. type Txcb_list_free_func_t = uintptr
  5143. type T_xcb_fd = struct {
  5144. Ffd [16]int32
  5145. Fnfd int32
  5146. Fifd int32
  5147. }
  5148. type T_xcb_out = struct {
  5149. Fcond Tpthread_cond_t
  5150. Fwriting int32
  5151. Fsocket_cond Tpthread_cond_t
  5152. Freturn_socket uintptr
  5153. Fsocket_closure uintptr
  5154. Fsocket_moving int32
  5155. Fqueue [16384]int8
  5156. Fqueue_len int32
  5157. Frequest Tuint64_t
  5158. Frequest_written Tuint64_t
  5159. Frequest_expected_written Tuint64_t
  5160. Ftotal_written Tuint64_t
  5161. Freqlenlock Tpthread_mutex_t
  5162. Fmaximum_request_length_tag _lazy_reply_tag
  5163. Fmaximum_request_length struct {
  5164. Fvalue [0]Tuint32_t
  5165. Fcookie Txcb_big_requests_enable_cookie_t
  5166. }
  5167. Fout_fd T_xcb_fd
  5168. }
  5169. type T_xcb_in = struct {
  5170. Fevent_cond Tpthread_cond_t
  5171. Freading int32
  5172. Fqueue [4096]int8
  5173. Fqueue_len int32
  5174. Frequest_expected Tuint64_t
  5175. Frequest_read Tuint64_t
  5176. Frequest_completed Tuint64_t
  5177. Ftotal_read Tuint64_t
  5178. Fcurrent_reply uintptr
  5179. Fcurrent_reply_tail uintptr
  5180. Freplies uintptr
  5181. Fevents uintptr
  5182. Fevents_tail uintptr
  5183. Freaders uintptr
  5184. Fspecial_waiters uintptr
  5185. Fpending_replies uintptr
  5186. Fpending_replies_tail uintptr
  5187. Fin_fd T_xcb_fd
  5188. Fspecial_events uintptr
  5189. }
  5190. type T_xcb_xid = struct {
  5191. Flock Tpthread_mutex_t
  5192. Flast Tuint32_t
  5193. Fbase Tuint32_t
  5194. Fmax Tuint32_t
  5195. Finc Tuint32_t
  5196. }
  5197. type T_xcb_ext = struct {
  5198. Flock Tpthread_mutex_t
  5199. Fextensions uintptr
  5200. Fextensions_size int32
  5201. }
  5202. type Txcb_connection_t1 = struct {
  5203. Fhas_error int32
  5204. Fsetup uintptr
  5205. Ffd int32
  5206. Fiolock Tpthread_mutex_t
  5207. Fin T_xcb_in
  5208. Fout T_xcb_out
  5209. Fext T_xcb_ext
  5210. Fxid T_xcb_xid
  5211. }
  5212. type Tnfds_t = uint64
  5213. type Tpollfd = struct {
  5214. Ffd int32
  5215. Fevents int16
  5216. Frevents int16
  5217. }
  5218. type Tsocklen_t = uint32
  5219. type Tsa_family_t = uint16
  5220. type Tmsghdr = struct {
  5221. Fmsg_name uintptr
  5222. Fmsg_namelen Tsocklen_t
  5223. Fmsg_iov uintptr
  5224. Fmsg_iovlen int32
  5225. F__pad1 int32
  5226. Fmsg_control uintptr
  5227. Fmsg_controllen Tsocklen_t
  5228. F__pad2 int32
  5229. Fmsg_flags int32
  5230. }
  5231. type Tcmsghdr = struct {
  5232. Fcmsg_len Tsocklen_t
  5233. F__pad1 int32
  5234. Fcmsg_level int32
  5235. Fcmsg_type int32
  5236. }
  5237. type Tucred = struct {
  5238. Fpid Tpid_t
  5239. Fuid Tuid_t
  5240. Fgid Tgid_t
  5241. }
  5242. type Tmmsghdr = struct {
  5243. Fmsg_hdr Tmsghdr
  5244. Fmsg_len uint32
  5245. }
  5246. type Tlinger = struct {
  5247. Fl_onoff int32
  5248. Fl_linger int32
  5249. }
  5250. type Tsockaddr = struct {
  5251. Fsa_family Tsa_family_t
  5252. Fsa_data [14]int8
  5253. }
  5254. type Tsockaddr_storage = struct {
  5255. Fss_family Tsa_family_t
  5256. F__ss_padding [118]int8
  5257. F__ss_align uint64
  5258. }
  5259. type Timaxdiv_t = struct {
  5260. Fquot Tintmax_t
  5261. Frem Tintmax_t
  5262. }
  5263. type Tin_port_t = uint16
  5264. type Tin_addr_t = uint32
  5265. type Tin_addr = struct {
  5266. Fs_addr Tin_addr_t
  5267. }
  5268. type Tsockaddr_in = struct {
  5269. Fsin_family Tsa_family_t
  5270. Fsin_port Tin_port_t
  5271. Fsin_addr Tin_addr
  5272. Fsin_zero [8]Tuint8_t
  5273. }
  5274. type Tin6_addr = struct {
  5275. F__in6_union struct {
  5276. F__s6_addr16 [0][8]Tuint16_t
  5277. F__s6_addr32 [0][4]Tuint32_t
  5278. F__s6_addr [16]Tuint8_t
  5279. }
  5280. }
  5281. type Tsockaddr_in6 = struct {
  5282. Fsin6_family Tsa_family_t
  5283. Fsin6_port Tin_port_t
  5284. Fsin6_flowinfo Tuint32_t
  5285. Fsin6_addr Tin6_addr
  5286. Fsin6_scope_id Tuint32_t
  5287. }
  5288. type Tipv6_mreq = struct {
  5289. Fipv6mr_multiaddr Tin6_addr
  5290. Fipv6mr_interface uint32
  5291. }
  5292. type Tip_opts = struct {
  5293. Fip_dst Tin_addr
  5294. Fip_opts [40]int8
  5295. }
  5296. type Tip_mreq = struct {
  5297. Fimr_multiaddr Tin_addr
  5298. Fimr_interface Tin_addr
  5299. }
  5300. type Tip_mreqn = struct {
  5301. Fimr_multiaddr Tin_addr
  5302. Fimr_address Tin_addr
  5303. Fimr_ifindex int32
  5304. }
  5305. type Tip_mreq_source = struct {
  5306. Fimr_multiaddr Tin_addr
  5307. Fimr_interface Tin_addr
  5308. Fimr_sourceaddr Tin_addr
  5309. }
  5310. type Tip_msfilter = struct {
  5311. Fimsf_multiaddr Tin_addr
  5312. Fimsf_interface Tin_addr
  5313. Fimsf_fmode Tuint32_t
  5314. Fimsf_numsrc Tuint32_t
  5315. Fimsf_slist [1]Tin_addr
  5316. }
  5317. type Tgroup_req = struct {
  5318. Fgr_interface Tuint32_t
  5319. Fgr_group Tsockaddr_storage
  5320. }
  5321. type Tgroup_source_req = struct {
  5322. Fgsr_interface Tuint32_t
  5323. Fgsr_group Tsockaddr_storage
  5324. Fgsr_source Tsockaddr_storage
  5325. }
  5326. type Tgroup_filter = struct {
  5327. Fgf_interface Tuint32_t
  5328. Fgf_group Tsockaddr_storage
  5329. Fgf_fmode Tuint32_t
  5330. Fgf_numsrc Tuint32_t
  5331. Fgf_slist [1]Tsockaddr_storage
  5332. }
  5333. type Tin_pktinfo = struct {
  5334. Fipi_ifindex int32
  5335. Fipi_spec_dst Tin_addr
  5336. Fipi_addr Tin_addr
  5337. }
  5338. type Tin6_pktinfo = struct {
  5339. Fipi6_addr Tin6_addr
  5340. Fipi6_ifindex uint32
  5341. }
  5342. type Tip6_mtuinfo = struct {
  5343. Fip6m_addr Tsockaddr_in6
  5344. Fip6m_mtu Tuint32_t
  5345. }
  5346. /* SHUT_RDWR is fairly recent and is not available on all platforms */
  5347. type Txcb_setup_generic_t = struct {
  5348. Fstatus Tuint8_t
  5349. Fpad0 [5]Tuint8_t
  5350. Flength Tuint16_t
  5351. }
  5352. var _xcb_error_setup = Txcb_setup_t{}
  5353. // C documentation
  5354. //
  5355. // /* Keep this list in sync with is_static_error_conn()! */
  5356. var _xcb_con_error = int32(m_XCB_CONN_ERROR)
  5357. var _xcb_con_closed_mem_er = int32(m_XCB_CONN_CLOSED_MEM_INSUFFICIENT)
  5358. var _xcb_con_closed_parse_er = int32(m_XCB_CONN_CLOSED_PARSE_ERR)
  5359. var _xcb_con_closed_screen_er = int32(m_XCB_CONN_CLOSED_INVALID_SCREEN)
  5360. func _is_static_error_conn(tls *libc.TLS, c uintptr) (r int32) {
  5361. return libc.BoolInt32(c == uintptr(unsafe.Pointer(&_xcb_con_error)) || c == uintptr(unsafe.Pointer(&_xcb_con_closed_mem_er)) || c == uintptr(unsafe.Pointer(&_xcb_con_closed_parse_er)) || c == uintptr(unsafe.Pointer(&_xcb_con_closed_screen_er)))
  5362. }
  5363. func _set_fd_flags(tls *libc.TLS, fd int32) (r int32) {
  5364. bp := tls.Alloc(16)
  5365. defer tls.Free(16)
  5366. var flags int32
  5367. _ = flags
  5368. /* Win32 doesn't have file descriptors and the fcntl function. This block sets the socket in non-blocking mode */
  5369. flags = libc.Xfcntl(tls, fd, int32(m_F_GETFL), libc.VaList(bp+8, 0))
  5370. if flags == -int32(1) {
  5371. return 0
  5372. }
  5373. flags |= int32(m_O_NONBLOCK)
  5374. if libc.Xfcntl(tls, fd, int32(m_F_SETFL), libc.VaList(bp+8, flags)) == -int32(1) {
  5375. return 0
  5376. }
  5377. if libc.Xfcntl(tls, fd, int32(m_F_SETFD), libc.VaList(bp+8, int32(m_FD_CLOEXEC))) == -int32(1) {
  5378. return 0
  5379. }
  5380. return int32(1)
  5381. }
  5382. func _write_setup(tls *libc.TLS, c uintptr, auth_info uintptr) (r int32) {
  5383. bp := tls.Alloc(112)
  5384. defer tls.Free(112)
  5385. var count, ret, v1, v2, v4, v5, v7, v8 int32
  5386. var v3, v6 Tuint16_t
  5387. var _ /* out at bp+0 */ Txcb_setup_request_t
  5388. var _ /* parts at bp+16 */ [6]Tiovec
  5389. _, _, _, _, _, _, _, _, _, _ = count, ret, v1, v2, v3, v4, v5, v6, v7, v8
  5390. count = 0
  5391. libc.Xmemset(tls, bp, 0, uint64(12))
  5392. /* B = 0x42 = MSB first, l = 0x6c = LSB first */
  5393. if libc.Xhtonl(tls, _endian) == _endian {
  5394. (*(*Txcb_setup_request_t)(unsafe.Pointer(bp))).Fbyte_order = uint8(0x42)
  5395. } else {
  5396. (*(*Txcb_setup_request_t)(unsafe.Pointer(bp))).Fbyte_order = uint8(0x6c)
  5397. }
  5398. (*(*Txcb_setup_request_t)(unsafe.Pointer(bp))).Fprotocol_major_version = uint16(m_X_PROTOCOL)
  5399. (*(*Txcb_setup_request_t)(unsafe.Pointer(bp))).Fprotocol_minor_version = uint16(m_X_PROTOCOL_REVISION)
  5400. (*(*Txcb_setup_request_t)(unsafe.Pointer(bp))).Fauthorization_protocol_name_len = uint16(0)
  5401. (*(*Txcb_setup_request_t)(unsafe.Pointer(bp))).Fauthorization_protocol_data_len = uint16(0)
  5402. (*(*[6]Tiovec)(unsafe.Pointer(bp + 16)))[count].Fiov_len = uint64(12)
  5403. v1 = count
  5404. count++
  5405. (*(*[6]Tiovec)(unsafe.Pointer(bp + 16)))[v1].Fiov_base = bp
  5406. (*(*[6]Tiovec)(unsafe.Pointer(bp + 16)))[count].Fiov_len = -libc.Uint64FromInt64(12) & libc.Uint64FromInt32(3)
  5407. v2 = count
  5408. count++
  5409. (*(*[6]Tiovec)(unsafe.Pointer(bp + 16)))[v2].Fiov_base = uintptr(unsafe.Pointer(&_pad))
  5410. if auth_info != 0 {
  5411. v3 = libc.Uint16FromInt32((*Txcb_auth_info_t)(unsafe.Pointer(auth_info)).Fnamelen)
  5412. (*(*Txcb_setup_request_t)(unsafe.Pointer(bp))).Fauthorization_protocol_name_len = v3
  5413. (*(*[6]Tiovec)(unsafe.Pointer(bp + 16)))[count].Fiov_len = uint64(v3)
  5414. v4 = count
  5415. count++
  5416. (*(*[6]Tiovec)(unsafe.Pointer(bp + 16)))[v4].Fiov_base = (*Txcb_auth_info_t)(unsafe.Pointer(auth_info)).Fname
  5417. (*(*[6]Tiovec)(unsafe.Pointer(bp + 16)))[count].Fiov_len = libc.Uint64FromInt32(-libc.Int32FromUint16((*(*Txcb_setup_request_t)(unsafe.Pointer(bp))).Fauthorization_protocol_name_len) & libc.Int32FromInt32(3))
  5418. v5 = count
  5419. count++
  5420. (*(*[6]Tiovec)(unsafe.Pointer(bp + 16)))[v5].Fiov_base = uintptr(unsafe.Pointer(&_pad))
  5421. v6 = libc.Uint16FromInt32((*Txcb_auth_info_t)(unsafe.Pointer(auth_info)).Fdatalen)
  5422. (*(*Txcb_setup_request_t)(unsafe.Pointer(bp))).Fauthorization_protocol_data_len = v6
  5423. (*(*[6]Tiovec)(unsafe.Pointer(bp + 16)))[count].Fiov_len = uint64(v6)
  5424. v7 = count
  5425. count++
  5426. (*(*[6]Tiovec)(unsafe.Pointer(bp + 16)))[v7].Fiov_base = (*Txcb_auth_info_t)(unsafe.Pointer(auth_info)).Fdata
  5427. (*(*[6]Tiovec)(unsafe.Pointer(bp + 16)))[count].Fiov_len = libc.Uint64FromInt32(-libc.Int32FromUint16((*(*Txcb_setup_request_t)(unsafe.Pointer(bp))).Fauthorization_protocol_data_len) & libc.Int32FromInt32(3))
  5428. v8 = count
  5429. count++
  5430. (*(*[6]Tiovec)(unsafe.Pointer(bp + 16)))[v8].Fiov_base = uintptr(unsafe.Pointer(&_pad))
  5431. }
  5432. libc.Xpthread_mutex_lock(tls, c+24)
  5433. ret = X_xcb_out_send(tls, c, bp+16, count)
  5434. libc.Xpthread_mutex_unlock(tls, c+24)
  5435. return ret
  5436. }
  5437. var _pad [3]int8
  5438. var _endian = uint32(0x01020304)
  5439. func _read_setup(tls *libc.TLS, c uintptr) (r int32) {
  5440. bp := tls.Alloc(16)
  5441. defer tls.Free(16)
  5442. var setup, setup1, tmp uintptr
  5443. var _ /* newline at bp+0 */ int8
  5444. _, _, _ = setup, setup1, tmp
  5445. *(*int8)(unsafe.Pointer(bp)) = int8('\n')
  5446. /* Read the server response */
  5447. (*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup = libc.Xmalloc(tls, uint64(8))
  5448. if !((*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup != 0) {
  5449. return 0
  5450. }
  5451. if libc.Uint64FromInt32(X_xcb_in_read_block(tls, c, (*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup, int32(8))) != uint64(8) {
  5452. return 0
  5453. }
  5454. tmp = libc.Xrealloc(tls, (*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup, libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_setup_t)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup)).Flength)*int32(4))+uint64(8))
  5455. if !(tmp != 0) {
  5456. return 0
  5457. }
  5458. (*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup = tmp
  5459. if X_xcb_in_read_block(tls, c, (*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup+uintptr(8), libc.Int32FromUint16((*Txcb_setup_t)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup)).Flength)*int32(4)) <= 0 {
  5460. return 0
  5461. }
  5462. /* 0 = failed, 2 = authenticate, 1 = success */
  5463. switch libc.Int32FromUint8((*Txcb_setup_t)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup)).Fstatus) {
  5464. case 0: /* failed */
  5465. setup = (*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup
  5466. libc.Xwrite(tls, int32(m_STDERR_FILENO), Xxcb_setup_failed_reason(tls, setup), libc.Uint64FromInt32(Xxcb_setup_failed_reason_length(tls, setup)))
  5467. libc.Xwrite(tls, int32(m_STDERR_FILENO), bp, uint64(1))
  5468. return 0
  5469. case int32(2): /* authenticate */
  5470. setup1 = (*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup
  5471. libc.Xwrite(tls, int32(m_STDERR_FILENO), Xxcb_setup_authenticate_reason(tls, setup1), libc.Uint64FromInt32(Xxcb_setup_authenticate_reason_length(tls, setup1)))
  5472. libc.Xwrite(tls, int32(m_STDERR_FILENO), bp, uint64(1))
  5473. return 0
  5474. }
  5475. return int32(1)
  5476. }
  5477. // C documentation
  5478. //
  5479. // /* precondition: there must be something for us to write. */
  5480. func _write_vec(tls *libc.TLS, c uintptr, vector uintptr, count uintptr) (r int32) {
  5481. bp := tls.Alloc(144)
  5482. defer tls.Free(144)
  5483. var cur, i, n int32
  5484. var hdr, v1 uintptr
  5485. var _ /* cmsgbuf at bp+0 */ struct {
  5486. Fbuf [0][80]int8
  5487. Fcmsghdr Tcmsghdr
  5488. F__ccgo_pad2 [64]byte
  5489. }
  5490. var _ /* msg at bp+80 */ Tmsghdr
  5491. _, _, _, _, _ = cur, hdr, i, n, v1
  5492. n = *(*int32)(unsafe.Pointer(count))
  5493. if n > int32(m_IOV_MAX) {
  5494. n = int32(m_IOV_MAX)
  5495. }
  5496. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fout_fd.Fnfd != 0 {
  5497. *(*Tmsghdr)(unsafe.Pointer(bp + 80)) = Tmsghdr{
  5498. Fmsg_iov: *(*uintptr)(unsafe.Pointer(vector)),
  5499. Fmsg_iovlen: n,
  5500. Fmsg_control: bp,
  5501. Fmsg_controllen: uint32((libc.Uint64FromInt64(16)+libc.Uint64FromInt64(8)-libc.Uint64FromInt32(1)) & ^(libc.Uint64FromInt64(8)-libc.Uint64FromInt32(1)) + libc.Uint64FromInt32((*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fout_fd.Fnfd)*libc.Uint64FromInt64(4)),
  5502. }
  5503. if uint64((*Tmsghdr)(unsafe.Pointer(bp+80)).Fmsg_controllen) >= uint64(16) {
  5504. v1 = (*Tmsghdr)(unsafe.Pointer(bp + 80)).Fmsg_control
  5505. } else {
  5506. v1 = libc.UintptrFromInt32(0)
  5507. }
  5508. hdr = v1
  5509. (*Tcmsghdr)(unsafe.Pointer(hdr)).Fcmsg_len = (*(*Tmsghdr)(unsafe.Pointer(bp + 80))).Fmsg_controllen
  5510. (*Tcmsghdr)(unsafe.Pointer(hdr)).Fcmsg_level = int32(m_SOL_SOCKET)
  5511. (*Tcmsghdr)(unsafe.Pointer(hdr)).Fcmsg_type = int32(m_SCM_RIGHTS)
  5512. libc.Xmemcpy(tls, hdr+libc.UintptrFromInt32(1)*16, c+4400+16592, libc.Uint64FromInt32((*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fout_fd.Fnfd)*uint64(4))
  5513. n = int32(libc.Xsendmsg(tls, (*Txcb_connection_t)(unsafe.Pointer(c)).Ffd, bp+80, 0))
  5514. if n < 0 && *(*int32)(unsafe.Pointer(libc.X__errno_location(tls))) == int32(m_EAGAIN) {
  5515. return int32(1)
  5516. }
  5517. i = 0
  5518. for {
  5519. if !(i < (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fout_fd.Fnfd) {
  5520. break
  5521. }
  5522. libc.Xclose(tls, *(*int32)(unsafe.Pointer(c + 4400 + 16592 + uintptr(i)*4)))
  5523. goto _2
  5524. _2:
  5525. ;
  5526. i++
  5527. }
  5528. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fout_fd.Fnfd = 0
  5529. } else {
  5530. n = int32(libc.Xwritev(tls, (*Txcb_connection_t)(unsafe.Pointer(c)).Ffd, *(*uintptr)(unsafe.Pointer(vector)), n))
  5531. if n < 0 && *(*int32)(unsafe.Pointer(libc.X__errno_location(tls))) == int32(m_EAGAIN) {
  5532. return int32(1)
  5533. }
  5534. }
  5535. if n <= 0 {
  5536. X_xcb_conn_shutdown(tls, c, int32(m_XCB_CONN_ERROR))
  5537. return 0
  5538. }
  5539. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Ftotal_written += libc.Uint64FromInt32(n)
  5540. for {
  5541. if !(*(*int32)(unsafe.Pointer(count)) != 0) {
  5542. break
  5543. }
  5544. cur = libc.Int32FromUint64((*Tiovec)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(vector)))).Fiov_len)
  5545. if cur > n {
  5546. cur = n
  5547. }
  5548. *(*Tsize_t)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(vector)) + 8)) -= libc.Uint64FromInt32(cur)
  5549. (*Tiovec)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(vector)))).Fiov_base = (*Tiovec)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(vector)))).Fiov_base + uintptr(cur)
  5550. n -= cur
  5551. if (*Tiovec)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(vector)))).Fiov_len != 0 {
  5552. break
  5553. }
  5554. goto _3
  5555. _3:
  5556. ;
  5557. *(*int32)(unsafe.Pointer(count))--
  5558. *(*uintptr)(unsafe.Pointer(vector)) += 16
  5559. }
  5560. if !(*(*int32)(unsafe.Pointer(count)) != 0) {
  5561. *(*uintptr)(unsafe.Pointer(vector)) = uintptr(0)
  5562. }
  5563. return int32(1)
  5564. }
  5565. /* Public interface */
  5566. func Xxcb_get_setup(tls *libc.TLS, c uintptr) (r uintptr) {
  5567. if _is_static_error_conn(tls, c) != 0 {
  5568. return uintptr(unsafe.Pointer(&_xcb_error_setup))
  5569. }
  5570. /* doesn't need locking because it's never written to. */
  5571. return (*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup
  5572. }
  5573. func Xxcb_get_file_descriptor(tls *libc.TLS, c uintptr) (r int32) {
  5574. if _is_static_error_conn(tls, c) != 0 {
  5575. return -int32(1)
  5576. }
  5577. /* doesn't need locking because it's never written to. */
  5578. return (*Txcb_connection_t)(unsafe.Pointer(c)).Ffd
  5579. }
  5580. func Xxcb_connection_has_error(tls *libc.TLS, c uintptr) (r int32) {
  5581. /* doesn't need locking because it's read and written atomically. */
  5582. return (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error
  5583. }
  5584. func Xxcb_connect_to_fd(tls *libc.TLS, fd int32, auth_info uintptr) (r uintptr) {
  5585. var c uintptr
  5586. _ = c
  5587. c = libc.Xcalloc(tls, uint64(1), uint64(21176))
  5588. if !(c != 0) {
  5589. libc.Xclose(tls, fd)
  5590. return X_xcb_conn_ret_error(tls, int32(m_XCB_CONN_CLOSED_MEM_INSUFFICIENT))
  5591. }
  5592. (*Txcb_connection_t)(unsafe.Pointer(c)).Ffd = fd
  5593. if !(_set_fd_flags(tls, fd) != 0 && libc.Xpthread_mutex_init(tls, c+24, uintptr(0)) == 0 && X_xcb_in_init(tls, c+64) != 0 && X_xcb_out_init(tls, c+4400) != 0 && _write_setup(tls, c, auth_info) != 0 && _read_setup(tls, c) != 0 && X_xcb_ext_init(tls, c) != 0 && X_xcb_xid_init(tls, c) != 0) {
  5594. Xxcb_disconnect(tls, c)
  5595. return X_xcb_conn_ret_error(tls, int32(m_XCB_CONN_ERROR))
  5596. }
  5597. return c
  5598. }
  5599. func Xxcb_disconnect(tls *libc.TLS, c uintptr) {
  5600. if c == libc.UintptrFromInt32(0) || _is_static_error_conn(tls, c) != 0 {
  5601. return
  5602. }
  5603. libc.Xfree(tls, (*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup)
  5604. /* disallow further sends and receives */
  5605. libc.Xshutdown(tls, (*Txcb_connection_t)(unsafe.Pointer(c)).Ffd, int32(m_SHUT_RDWR))
  5606. libc.Xclose(tls, (*Txcb_connection_t)(unsafe.Pointer(c)).Ffd)
  5607. libc.Xpthread_mutex_destroy(tls, c+24)
  5608. X_xcb_in_destroy(tls, c+64)
  5609. X_xcb_out_destroy(tls, c+4400)
  5610. X_xcb_ext_destroy(tls, c)
  5611. X_xcb_xid_destroy(tls, c)
  5612. libc.Xfree(tls, c)
  5613. }
  5614. /* Private interface */
  5615. func X_xcb_conn_shutdown(tls *libc.TLS, c uintptr, err int32) {
  5616. (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error = err
  5617. }
  5618. // C documentation
  5619. //
  5620. // /* Return connection error state.
  5621. // * To make thread-safe, I need a seperate static
  5622. // * variable for every possible error.
  5623. // * has_error is the first field in xcb_connection_t, so just
  5624. // * return a casted int here; checking has_error (and only
  5625. // * has_error) will be safe.
  5626. // */
  5627. func X_xcb_conn_ret_error(tls *libc.TLS, err int32) (r uintptr) {
  5628. switch err {
  5629. case int32(m_XCB_CONN_CLOSED_MEM_INSUFFICIENT):
  5630. return uintptr(unsafe.Pointer(&_xcb_con_closed_mem_er))
  5631. case int32(m_XCB_CONN_CLOSED_PARSE_ERR):
  5632. return uintptr(unsafe.Pointer(&_xcb_con_closed_parse_er))
  5633. case int32(m_XCB_CONN_CLOSED_INVALID_SCREEN):
  5634. return uintptr(unsafe.Pointer(&_xcb_con_closed_screen_er))
  5635. case int32(m_XCB_CONN_ERROR):
  5636. fallthrough
  5637. default:
  5638. return uintptr(unsafe.Pointer(&_xcb_con_error))
  5639. }
  5640. return r
  5641. }
  5642. func X_xcb_conn_wait(tls *libc.TLS, c uintptr, cond uintptr, vector uintptr, count uintptr) (r int32) {
  5643. bp := tls.Alloc(16)
  5644. defer tls.Free(16)
  5645. var may_read, ret, v1 int32
  5646. var p2 uintptr
  5647. var _ /* fd at bp+0 */ Tpollfd
  5648. _, _, _, _ = may_read, ret, v1, p2
  5649. /* If the thing I should be doing is already being done, wait for it. */
  5650. if count != 0 {
  5651. v1 = (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fwriting
  5652. } else {
  5653. v1 = (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Freading
  5654. }
  5655. if v1 != 0 {
  5656. libc.Xpthread_cond_wait(tls, cond, c+24)
  5657. return int32(1)
  5658. }
  5659. libc.Xmemset(tls, bp, 0, uint64(8))
  5660. (*(*Tpollfd)(unsafe.Pointer(bp))).Ffd = (*Txcb_connection_t)(unsafe.Pointer(c)).Ffd
  5661. (*(*Tpollfd)(unsafe.Pointer(bp))).Fevents = int16(m_POLLIN)
  5662. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Freading++
  5663. if count != 0 {
  5664. p2 = bp + 4
  5665. *(*int16)(unsafe.Pointer(p2)) = int16(int32(*(*int16)(unsafe.Pointer(p2))) | libc.Int32FromInt32(m_POLLOUT))
  5666. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fwriting++
  5667. }
  5668. libc.Xpthread_mutex_unlock(tls, c+24)
  5669. for cond1 := true; cond1; cond1 = ret == -int32(1) && *(*int32)(unsafe.Pointer(libc.X__errno_location(tls))) == int32(m_EINTR) {
  5670. ret = libc.Xpoll(tls, bp, uint64(1), -int32(1))
  5671. /* If poll() returns an event we didn't expect, such as POLLNVAL, treat
  5672. * it as if it failed. */
  5673. if ret >= 0 && int32((*(*Tpollfd)(unsafe.Pointer(bp))).Frevents) & ^int32((*(*Tpollfd)(unsafe.Pointer(bp))).Fevents) != 0 {
  5674. ret = -int32(1)
  5675. break
  5676. }
  5677. }
  5678. if ret < 0 {
  5679. X_xcb_conn_shutdown(tls, c, int32(m_XCB_CONN_ERROR))
  5680. ret = 0
  5681. }
  5682. libc.Xpthread_mutex_lock(tls, c+24)
  5683. if ret != 0 {
  5684. /* The code allows two threads to call select()/poll() at the same time.
  5685. * First thread just wants to read, a second thread wants to write, too.
  5686. * We have to make sure that we don't steal the reading thread's reply
  5687. * and let it get stuck in select()/poll().
  5688. * So a thread may read if either:
  5689. * - There is no other thread that wants to read (the above situation
  5690. * did not occur).
  5691. * - It is the reading thread (above situation occurred).
  5692. */
  5693. may_read = libc.BoolInt32((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Freading == int32(1) || !(count != 0))
  5694. if may_read != 0 && int32((*(*Tpollfd)(unsafe.Pointer(bp))).Frevents)&int32(m_POLLIN) != 0 {
  5695. ret = libc.BoolInt32(ret != 0 && X_xcb_in_read(tls, c) != 0)
  5696. }
  5697. if int32((*(*Tpollfd)(unsafe.Pointer(bp))).Frevents)&int32(m_POLLOUT) != 0 {
  5698. ret = libc.BoolInt32(ret != 0 && _write_vec(tls, c, vector, count) != 0)
  5699. }
  5700. }
  5701. if count != 0 {
  5702. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fwriting--
  5703. }
  5704. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Freading--
  5705. return ret
  5706. }
  5707. func Xxcb_total_read(tls *libc.TLS, c uintptr) (r Tuint64_t) {
  5708. var n Tuint64_t
  5709. _ = n
  5710. if Xxcb_connection_has_error(tls, c) != 0 {
  5711. return uint64(0)
  5712. }
  5713. libc.Xpthread_mutex_lock(tls, c+24)
  5714. n = (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Ftotal_read
  5715. libc.Xpthread_mutex_unlock(tls, c+24)
  5716. return n
  5717. }
  5718. func Xxcb_total_written(tls *libc.TLS, c uintptr) (r Tuint64_t) {
  5719. var n Tuint64_t
  5720. _ = n
  5721. if Xxcb_connection_has_error(tls, c) != 0 {
  5722. return uint64(0)
  5723. }
  5724. libc.Xpthread_mutex_lock(tls, c+24)
  5725. n = (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Ftotal_written
  5726. libc.Xpthread_mutex_unlock(tls, c+24)
  5727. return n
  5728. }
  5729. const m_SEEK_CUR = 1
  5730. const m_SEEK_END = 2
  5731. const m_SEEK_SET = 0
  5732. type Txcb_extension_t = struct {
  5733. Fname uintptr
  5734. Fglobal_id int32
  5735. }
  5736. type Txcb_extension_t1 = struct {
  5737. Fname uintptr
  5738. Fglobal_id int32
  5739. }
  5740. type Txcb_protocol_request_t = struct {
  5741. Fcount Tsize_t
  5742. Fext uintptr
  5743. Fopcode Tuint8_t
  5744. Fisvoid Tuint8_t
  5745. }
  5746. type _xcb_send_request_flags_t = int32
  5747. const _XCB_REQUEST_CHECKED = 1
  5748. const _XCB_REQUEST_RAW = 2
  5749. const _XCB_REQUEST_DISCARD_REPLY = 4
  5750. const _XCB_REQUEST_REPLY_FDS = 8
  5751. /*
  5752. * This file generated automatically from bigreq.xml by c_client.py.
  5753. * Edit at your peril.
  5754. */
  5755. /**
  5756. * @defgroup XCB_BigRequests_API XCB BigRequests API
  5757. * @brief BigRequests XCB Protocol Implementation.
  5758. * @{
  5759. **/
  5760. /**
  5761. * @}
  5762. */
  5763. func _send_request(tls *libc.TLS, c uintptr, isvoid int32, workaround _workarounds, flags int32, vector uintptr, count int32) {
  5764. var p1 uintptr
  5765. _ = p1
  5766. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  5767. return
  5768. }
  5769. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest++
  5770. if !(isvoid != 0) {
  5771. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_expected = (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest
  5772. }
  5773. if workaround != int32(_WORKAROUND_NONE) || flags != 0 {
  5774. X_xcb_in_expect_reply(tls, c, (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest, workaround, flags)
  5775. }
  5776. for count != 0 && libc.Uint64FromInt32((*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fqueue_len)+(*(*Tiovec)(unsafe.Pointer(vector))).Fiov_len <= uint64(16384) {
  5777. libc.Xmemcpy(tls, c+4400+124+uintptr((*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fqueue_len), (*(*Tiovec)(unsafe.Pointer(vector))).Fiov_base, (*(*Tiovec)(unsafe.Pointer(vector))).Fiov_len)
  5778. p1 = c + 4400 + 16508
  5779. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + (*(*Tiovec)(unsafe.Pointer(vector))).Fiov_len)
  5780. (*(*Tiovec)(unsafe.Pointer(vector))).Fiov_base = (*(*Tiovec)(unsafe.Pointer(vector))).Fiov_base + uintptr((*(*Tiovec)(unsafe.Pointer(vector))).Fiov_len)
  5781. (*(*Tiovec)(unsafe.Pointer(vector))).Fiov_len = uint64(0)
  5782. vector += 16
  5783. count--
  5784. }
  5785. if !(count != 0) {
  5786. return
  5787. }
  5788. vector -= 16
  5789. count++
  5790. (*(*Tiovec)(unsafe.Pointer(vector))).Fiov_base = c + 4400 + 124
  5791. (*(*Tiovec)(unsafe.Pointer(vector))).Fiov_len = libc.Uint64FromInt32((*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fqueue_len)
  5792. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fqueue_len = 0
  5793. X_xcb_out_send(tls, c, vector, count)
  5794. }
  5795. func _send_sync(tls *libc.TLS, c uintptr) {
  5796. bp := tls.Alloc(32)
  5797. defer tls.Free(32)
  5798. var _ /* vector at bp+0 */ [2]Tiovec
  5799. (*(*[2]Tiovec)(unsafe.Pointer(bp)))[int32(1)].Fiov_base = uintptr(unsafe.Pointer(&_sync_req))
  5800. (*(*[2]Tiovec)(unsafe.Pointer(bp)))[int32(1)].Fiov_len = uint64(4)
  5801. _send_request(tls, c, 0, int32(_WORKAROUND_NONE), int32(_XCB_REQUEST_DISCARD_REPLY), bp+uintptr(1)*16, int32(1))
  5802. }
  5803. var _sync_req = *(*struct {
  5804. Fpacket [0]Tuint32_t
  5805. Ffields struct {
  5806. Fmajor Tuint8_t
  5807. Fpad Tuint8_t
  5808. Flen1 Tuint16_t
  5809. }
  5810. })(unsafe.Pointer(&struct {
  5811. Fmajor uint8
  5812. Fpad uint8
  5813. Flen1 uint16
  5814. }{
  5815. Fmajor: uint8(43),
  5816. Flen1: uint16(1),
  5817. }))
  5818. func _get_socket_back(tls *libc.TLS, c uintptr) {
  5819. for (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Freturn_socket != 0 && (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fsocket_moving != 0 {
  5820. libc.Xpthread_cond_wait(tls, c+4400+56, c+24)
  5821. }
  5822. if !((*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Freturn_socket != 0) {
  5823. return
  5824. }
  5825. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fsocket_moving = int32(1)
  5826. libc.Xpthread_mutex_unlock(tls, c+24)
  5827. (*(*func(*libc.TLS, uintptr))(unsafe.Pointer(&struct{ uintptr }{(*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Freturn_socket})))(tls, (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fsocket_closure)
  5828. libc.Xpthread_mutex_lock(tls, c+24)
  5829. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fsocket_moving = 0
  5830. libc.Xpthread_cond_broadcast(tls, c+4400+56)
  5831. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Freturn_socket = uintptr(0)
  5832. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fsocket_closure = uintptr(0)
  5833. X_xcb_in_replies_done(tls, c)
  5834. }
  5835. func _prepare_socket_request(tls *libc.TLS, c uintptr) {
  5836. /* We're about to append data to out.queue, so we need to
  5837. * atomically test for an external socket owner *and* some other
  5838. * thread currently writing.
  5839. *
  5840. * If we have an external socket owner, we have to get the socket back
  5841. * before we can use it again.
  5842. *
  5843. * If some other thread is writing to the socket, we assume it's
  5844. * writing from out.queue, and so we can't stick data there.
  5845. *
  5846. * We satisfy this condition by first calling get_socket_back
  5847. * (which may drop the lock, but will return when XCB owns the
  5848. * socket again) and then checking for another writing thread and
  5849. * escaping the loop if we're ready to go.
  5850. */
  5851. for {
  5852. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  5853. return
  5854. }
  5855. _get_socket_back(tls, c)
  5856. if !((*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fwriting != 0) {
  5857. break
  5858. }
  5859. libc.Xpthread_cond_wait(tls, c+4400, c+24)
  5860. goto _1
  5861. _1:
  5862. }
  5863. }
  5864. /* Public interface */
  5865. func Xxcb_prefetch_maximum_request_length(tls *libc.TLS, c uintptr) {
  5866. var ext uintptr
  5867. _ = ext
  5868. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  5869. return
  5870. }
  5871. libc.Xpthread_mutex_lock(tls, c+4400+16544)
  5872. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fmaximum_request_length_tag == int32(_LAZY_NONE) {
  5873. ext = Xxcb_get_extension_data(tls, c, uintptr(unsafe.Pointer(&Xxcb_big_requests_id)))
  5874. if ext != 0 && (*Txcb_query_extension_reply_t)(unsafe.Pointer(ext)).Fpresent != 0 {
  5875. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fmaximum_request_length_tag = int32(_LAZY_COOKIE)
  5876. *(*Txcb_big_requests_enable_cookie_t)(unsafe.Pointer(c + 4400 + 16588)) = Xxcb_big_requests_enable(tls, c)
  5877. } else {
  5878. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fmaximum_request_length_tag = int32(_LAZY_FORCED)
  5879. *(*Tuint32_t)(unsafe.Pointer(c + 4400 + 16588)) = uint32((*Txcb_setup_t)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup)).Fmaximum_request_length)
  5880. }
  5881. }
  5882. libc.Xpthread_mutex_unlock(tls, c+4400+16544)
  5883. }
  5884. func Xxcb_get_maximum_request_length(tls *libc.TLS, c uintptr) (r1 Tuint32_t) {
  5885. var r uintptr
  5886. _ = r
  5887. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  5888. return uint32(0)
  5889. }
  5890. Xxcb_prefetch_maximum_request_length(tls, c)
  5891. libc.Xpthread_mutex_lock(tls, c+4400+16544)
  5892. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fmaximum_request_length_tag == int32(_LAZY_COOKIE) {
  5893. r = Xxcb_big_requests_enable_reply(tls, c, *(*Txcb_big_requests_enable_cookie_t)(unsafe.Pointer(c + 4400 + 16588)), uintptr(0))
  5894. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fmaximum_request_length_tag = int32(_LAZY_FORCED)
  5895. if r != 0 {
  5896. *(*Tuint32_t)(unsafe.Pointer(c + 4400 + 16588)) = (*Txcb_big_requests_enable_reply_t)(unsafe.Pointer(r)).Fmaximum_request_length
  5897. libc.Xfree(tls, r)
  5898. } else {
  5899. *(*Tuint32_t)(unsafe.Pointer(c + 4400 + 16588)) = uint32((*Txcb_setup_t)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup)).Fmaximum_request_length)
  5900. }
  5901. }
  5902. libc.Xpthread_mutex_unlock(tls, c+4400+16544)
  5903. return *(*Tuint32_t)(unsafe.Pointer(c + 4400 + 16588))
  5904. }
  5905. func _close_fds(tls *libc.TLS, fds uintptr, num_fds uint32) {
  5906. var index uint32
  5907. _ = index
  5908. index = uint32(0)
  5909. for {
  5910. if !(index < num_fds) {
  5911. break
  5912. }
  5913. libc.Xclose(tls, *(*int32)(unsafe.Pointer(fds + uintptr(index)*4)))
  5914. goto _1
  5915. _1:
  5916. ;
  5917. index++
  5918. }
  5919. }
  5920. func _send_fds(tls *libc.TLS, c uintptr, fds uintptr, num_fds uint32) {
  5921. var v1 int32
  5922. var v2 uintptr
  5923. _, _ = v1, v2
  5924. /* Calling _xcb_out_flush_to() can drop the iolock and wait on a condition
  5925. * variable if another thread is currently writing (c->out.writing > 0).
  5926. * This call waits for writers to be done and thus _xcb_out_flush_to() will
  5927. * do the work itself (in which case we are a writer and
  5928. * prepare_socket_request() will wait for us to be done if another threads
  5929. * tries to send fds, too). Thanks to this, we can atomically write out FDs.
  5930. */
  5931. _prepare_socket_request(tls, c)
  5932. for num_fds > uint32(0) {
  5933. for (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fout_fd.Fnfd == int32(m_XCB_MAX_PASS_FD) && !((*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0) {
  5934. /* XXX: if c->out.writing > 0, this releases the iolock and
  5935. * potentially allows other threads to interfere with their own fds.
  5936. */
  5937. X_xcb_out_flush_to(tls, c, (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest)
  5938. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fout_fd.Fnfd == int32(m_XCB_MAX_PASS_FD) {
  5939. /* We need some request to send FDs with */
  5940. X_xcb_out_send_sync(tls, c)
  5941. }
  5942. }
  5943. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  5944. break
  5945. }
  5946. v2 = c + 4400 + 16592 + 64
  5947. v1 = *(*int32)(unsafe.Pointer(v2))
  5948. *(*int32)(unsafe.Pointer(v2))++
  5949. *(*int32)(unsafe.Pointer(c + 4400 + 16592 + uintptr(v1)*4)) = *(*int32)(unsafe.Pointer(fds))
  5950. fds += 4
  5951. num_fds--
  5952. }
  5953. _close_fds(tls, fds, num_fds)
  5954. }
  5955. func Xxcb_send_request_with_fds64(tls *libc.TLS, c uintptr, flags int32, vector uintptr, req uintptr, num_fds uint32, fds uintptr) (r Tuint64_t) {
  5956. bp := tls.Alloc(16)
  5957. defer tls.Free(16)
  5958. var extension uintptr
  5959. var i uint32
  5960. var longlen, v2 Tsize_t
  5961. var request Tuint64_t
  5962. var shortlen Tuint16_t
  5963. var veclen int32
  5964. var workaround _workarounds
  5965. var v3 uint64
  5966. var _ /* prefix at bp+0 */ [2]Tuint32_t
  5967. _, _, _, _, _, _, _, _, _ = extension, i, longlen, request, shortlen, veclen, workaround, v2, v3
  5968. veclen = libc.Int32FromUint64((*Txcb_protocol_request_t)(unsafe.Pointer(req)).Fcount)
  5969. workaround = int32(_WORKAROUND_NONE)
  5970. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  5971. _close_fds(tls, fds, num_fds)
  5972. return uint64(0)
  5973. }
  5974. if !(flags&int32(_XCB_REQUEST_RAW) != 0) {
  5975. shortlen = uint16(0)
  5976. longlen = uint64(0)
  5977. /* set the major opcode, and the minor opcode for extensions */
  5978. if (*Txcb_protocol_request_t)(unsafe.Pointer(req)).Fext != 0 {
  5979. extension = Xxcb_get_extension_data(tls, c, (*Txcb_protocol_request_t)(unsafe.Pointer(req)).Fext)
  5980. if !(extension != 0 && (*Txcb_query_extension_reply_t)(unsafe.Pointer(extension)).Fpresent != 0) {
  5981. _close_fds(tls, fds, num_fds)
  5982. X_xcb_conn_shutdown(tls, c, int32(m_XCB_CONN_CLOSED_EXT_NOTSUPPORTED))
  5983. return uint64(0)
  5984. }
  5985. *(*Tuint8_t)(unsafe.Pointer((*(*Tiovec)(unsafe.Pointer(vector))).Fiov_base)) = (*Txcb_query_extension_reply_t)(unsafe.Pointer(extension)).Fmajor_opcode
  5986. *(*Tuint8_t)(unsafe.Pointer((*(*Tiovec)(unsafe.Pointer(vector))).Fiov_base + 1)) = (*Txcb_protocol_request_t)(unsafe.Pointer(req)).Fopcode
  5987. } else {
  5988. *(*Tuint8_t)(unsafe.Pointer((*(*Tiovec)(unsafe.Pointer(vector))).Fiov_base)) = (*Txcb_protocol_request_t)(unsafe.Pointer(req)).Fopcode
  5989. }
  5990. /* put together the length field, possibly using BIGREQUESTS */
  5991. i = uint32(0)
  5992. for {
  5993. if !(uint64(i) < (*Txcb_protocol_request_t)(unsafe.Pointer(req)).Fcount) {
  5994. break
  5995. }
  5996. longlen += (*(*Tiovec)(unsafe.Pointer(vector + uintptr(i)*16))).Fiov_len
  5997. if !((*(*Tiovec)(unsafe.Pointer(vector + uintptr(i)*16))).Fiov_base != 0) {
  5998. (*(*Tiovec)(unsafe.Pointer(vector + uintptr(i)*16))).Fiov_base = uintptr(unsafe.Pointer(&_pad1))
  5999. }
  6000. goto _1
  6001. _1:
  6002. ;
  6003. i++
  6004. }
  6005. longlen >>= uint64(2)
  6006. if longlen <= uint64((*Txcb_setup_t)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup)).Fmaximum_request_length) {
  6007. /* we don't need BIGREQUESTS. */
  6008. shortlen = uint16(longlen)
  6009. longlen = uint64(0)
  6010. } else {
  6011. if longlen > uint64(Xxcb_get_maximum_request_length(tls, c)) {
  6012. _close_fds(tls, fds, num_fds)
  6013. X_xcb_conn_shutdown(tls, c, int32(m_XCB_CONN_CLOSED_REQ_LEN_EXCEED))
  6014. return uint64(0) /* server can't take this; maybe need BIGREQUESTS? */
  6015. }
  6016. }
  6017. /* set the length field. */
  6018. *(*Tuint16_t)(unsafe.Pointer((*(*Tiovec)(unsafe.Pointer(vector))).Fiov_base + 1*2)) = shortlen
  6019. if !(shortlen != 0) {
  6020. (*(*[2]Tuint32_t)(unsafe.Pointer(bp)))[0] = *(*Tuint32_t)(unsafe.Pointer((*(*Tiovec)(unsafe.Pointer(vector))).Fiov_base))
  6021. longlen++
  6022. v2 = longlen
  6023. (*(*[2]Tuint32_t)(unsafe.Pointer(bp)))[int32(1)] = uint32(v2)
  6024. (*(*Tiovec)(unsafe.Pointer(vector))).Fiov_base = (*(*Tiovec)(unsafe.Pointer(vector))).Fiov_base + uintptr(1)*4
  6025. (*(*Tiovec)(unsafe.Pointer(vector))).Fiov_len -= uint64(4)
  6026. vector -= 16
  6027. veclen++
  6028. (*(*Tiovec)(unsafe.Pointer(vector))).Fiov_base = bp
  6029. (*(*Tiovec)(unsafe.Pointer(vector))).Fiov_len = uint64(8)
  6030. }
  6031. }
  6032. flags &= ^int32(_XCB_REQUEST_RAW)
  6033. /* do we need to work around the X server bug described in glx.xml? */
  6034. /* XXX: GetFBConfigs won't use BIG-REQUESTS in any sane
  6035. * configuration, but that should be handled here anyway. */
  6036. if (*Txcb_protocol_request_t)(unsafe.Pointer(req)).Fext != 0 && !((*Txcb_protocol_request_t)(unsafe.Pointer(req)).Fisvoid != 0) && !(libc.Xstrcmp(tls, (*Txcb_extension_t)(unsafe.Pointer((*Txcb_protocol_request_t)(unsafe.Pointer(req)).Fext)).Fname, __ccgo_ts) != 0) && (libc.Int32FromUint8((*Txcb_protocol_request_t)(unsafe.Pointer(req)).Fopcode) == int32(17) && *(*Tuint32_t)(unsafe.Pointer((*(*Tiovec)(unsafe.Pointer(vector))).Fiov_base + 1*4)) == uint32(0x10004) || libc.Int32FromUint8((*Txcb_protocol_request_t)(unsafe.Pointer(req)).Fopcode) == int32(21)) {
  6037. workaround = int32(_WORKAROUND_GLX_GET_FB_CONFIGS_BUG)
  6038. }
  6039. /* get a sequence number and arrange for delivery. */
  6040. libc.Xpthread_mutex_lock(tls, c+24)
  6041. /* send FDs before establishing a good request number, because this might
  6042. * call send_sync(), too
  6043. */
  6044. _send_fds(tls, c, fds, num_fds)
  6045. _prepare_socket_request(tls, c)
  6046. /* send GetInputFocus (sync_req) when 64k-2 requests have been sent without
  6047. * a reply.
  6048. * Also send sync_req (could use NoOp) at 32-bit wrap to avoid having
  6049. * applications see sequence 0 as that is used to indicate
  6050. * an error in sending the request
  6051. */
  6052. for (*Txcb_protocol_request_t)(unsafe.Pointer(req)).Fisvoid != 0 && (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest == (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_expected+libc.Uint64FromInt32(libc.Int32FromInt32(1)<<libc.Int32FromInt32(16))-uint64(2) || uint32((*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest+libc.Uint64FromInt32(1)) == uint32(0) {
  6053. _send_sync(tls, c)
  6054. _prepare_socket_request(tls, c)
  6055. }
  6056. _send_request(tls, c, libc.Int32FromUint8((*Txcb_protocol_request_t)(unsafe.Pointer(req)).Fisvoid), workaround, flags, vector, veclen)
  6057. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  6058. v3 = uint64(0)
  6059. } else {
  6060. v3 = (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest
  6061. }
  6062. request = v3
  6063. libc.Xpthread_mutex_unlock(tls, c+24)
  6064. return request
  6065. }
  6066. var _pad1 [3]int8
  6067. // C documentation
  6068. //
  6069. // /* request number are actually uint64_t internally but keep API compat with unsigned int */
  6070. func Xxcb_send_request_with_fds(tls *libc.TLS, c uintptr, flags int32, vector uintptr, req uintptr, num_fds uint32, fds uintptr) (r uint32) {
  6071. return uint32(Xxcb_send_request_with_fds64(tls, c, flags, vector, req, num_fds, fds))
  6072. }
  6073. func Xxcb_send_request64(tls *libc.TLS, c uintptr, flags int32, vector uintptr, req uintptr) (r Tuint64_t) {
  6074. return Xxcb_send_request_with_fds64(tls, c, flags, vector, req, uint32(0), libc.UintptrFromInt32(0))
  6075. }
  6076. // C documentation
  6077. //
  6078. // /* request number are actually uint64_t internally but keep API compat with unsigned int */
  6079. func Xxcb_send_request(tls *libc.TLS, c uintptr, flags int32, vector uintptr, req uintptr) (r uint32) {
  6080. return uint32(Xxcb_send_request64(tls, c, flags, vector, req))
  6081. }
  6082. func Xxcb_send_fd(tls *libc.TLS, c uintptr, fd int32) {
  6083. bp := tls.Alloc(16)
  6084. defer tls.Free(16)
  6085. var _ /* fds at bp+0 */ [1]int32
  6086. *(*[1]int32)(unsafe.Pointer(bp)) = [1]int32{
  6087. 0: fd,
  6088. }
  6089. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  6090. libc.Xclose(tls, fd)
  6091. return
  6092. }
  6093. libc.Xpthread_mutex_lock(tls, c+24)
  6094. _send_fds(tls, c, bp, uint32(1))
  6095. libc.Xpthread_mutex_unlock(tls, c+24)
  6096. }
  6097. func Xxcb_take_socket(tls *libc.TLS, c uintptr, return_socket uintptr, closure uintptr, flags int32, sent uintptr) (r int32) {
  6098. var ret int32
  6099. _ = ret
  6100. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  6101. return 0
  6102. }
  6103. libc.Xpthread_mutex_lock(tls, c+24)
  6104. _get_socket_back(tls, c)
  6105. /* _xcb_out_flush may drop the iolock allowing other threads to
  6106. * write requests, so keep flushing until we're done
  6107. */
  6108. for cond := true; cond; cond = ret != 0 && (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest != (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest_written {
  6109. ret = X_xcb_out_flush_to(tls, c, (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest)
  6110. }
  6111. if ret != 0 {
  6112. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Freturn_socket = return_socket
  6113. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fsocket_closure = closure
  6114. if flags != 0 {
  6115. /* c->out.request + 1 will be the first request sent by the external
  6116. * socket owner. If the socket is returned before this request is sent
  6117. * it will be detected in _xcb_in_replies_done and this pending_reply
  6118. * will be discarded.
  6119. */
  6120. X_xcb_in_expect_reply(tls, c, (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest+uint64(1), int32(_WORKAROUND_EXTERNAL_SOCKET_OWNER), flags)
  6121. }
  6122. *(*Tuint64_t)(unsafe.Pointer(sent)) = (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest
  6123. }
  6124. libc.Xpthread_mutex_unlock(tls, c+24)
  6125. return ret
  6126. }
  6127. func Xxcb_writev(tls *libc.TLS, c uintptr, vector uintptr, count int32, requests Tuint64_t) (r int32) {
  6128. var ret int32
  6129. _ = ret
  6130. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  6131. return 0
  6132. }
  6133. libc.Xpthread_mutex_lock(tls, c+24)
  6134. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest += requests
  6135. ret = X_xcb_out_send(tls, c, vector, count)
  6136. libc.Xpthread_mutex_unlock(tls, c+24)
  6137. return ret
  6138. }
  6139. func Xxcb_flush(tls *libc.TLS, c uintptr) (r int32) {
  6140. var ret int32
  6141. _ = ret
  6142. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  6143. return 0
  6144. }
  6145. libc.Xpthread_mutex_lock(tls, c+24)
  6146. ret = X_xcb_out_flush_to(tls, c, (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest)
  6147. libc.Xpthread_mutex_unlock(tls, c+24)
  6148. return ret
  6149. }
  6150. /* Private interface */
  6151. func X_xcb_out_init(tls *libc.TLS, out uintptr) (r int32) {
  6152. if libc.Xpthread_cond_init(tls, out+56, uintptr(0)) != 0 {
  6153. return 0
  6154. }
  6155. (*T_xcb_out)(unsafe.Pointer(out)).Freturn_socket = uintptr(0)
  6156. (*T_xcb_out)(unsafe.Pointer(out)).Fsocket_closure = uintptr(0)
  6157. (*T_xcb_out)(unsafe.Pointer(out)).Fsocket_moving = 0
  6158. if libc.Xpthread_cond_init(tls, out, uintptr(0)) != 0 {
  6159. return 0
  6160. }
  6161. (*T_xcb_out)(unsafe.Pointer(out)).Fwriting = 0
  6162. (*T_xcb_out)(unsafe.Pointer(out)).Fqueue_len = 0
  6163. (*T_xcb_out)(unsafe.Pointer(out)).Frequest = uint64(0)
  6164. (*T_xcb_out)(unsafe.Pointer(out)).Frequest_written = uint64(0)
  6165. (*T_xcb_out)(unsafe.Pointer(out)).Frequest_expected_written = uint64(0)
  6166. if libc.Xpthread_mutex_init(tls, out+16544, uintptr(0)) != 0 {
  6167. return 0
  6168. }
  6169. (*T_xcb_out)(unsafe.Pointer(out)).Fmaximum_request_length_tag = int32(_LAZY_NONE)
  6170. return int32(1)
  6171. }
  6172. func X_xcb_out_destroy(tls *libc.TLS, out uintptr) {
  6173. libc.Xpthread_mutex_destroy(tls, out+16544)
  6174. libc.Xpthread_cond_destroy(tls, out)
  6175. libc.Xpthread_cond_destroy(tls, out+56)
  6176. }
  6177. func X_xcb_out_send(tls *libc.TLS, c uintptr, _vector uintptr, _count int32) (r int32) {
  6178. bp := tls.Alloc(16)
  6179. defer tls.Free(16)
  6180. *(*uintptr)(unsafe.Pointer(bp)) = _vector
  6181. *(*int32)(unsafe.Pointer(bp + 8)) = _count
  6182. var ret int32
  6183. _ = ret
  6184. ret = int32(1)
  6185. for ret != 0 && *(*int32)(unsafe.Pointer(bp + 8)) != 0 {
  6186. ret = X_xcb_conn_wait(tls, c, c+4400, bp, bp+8)
  6187. }
  6188. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest_written = (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest
  6189. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest_expected_written = (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_expected
  6190. libc.Xpthread_cond_broadcast(tls, c+4400)
  6191. X_xcb_in_wake_up_next_reader(tls, c)
  6192. return ret
  6193. }
  6194. func X_xcb_out_send_sync(tls *libc.TLS, c uintptr) {
  6195. _prepare_socket_request(tls, c)
  6196. _send_sync(tls, c)
  6197. }
  6198. func X_xcb_out_flush_to(tls *libc.TLS, c uintptr, request Tuint64_t) (r int32) {
  6199. bp := tls.Alloc(16)
  6200. defer tls.Free(16)
  6201. var _ /* vec at bp+0 */ Tiovec
  6202. if libc.Int64FromUint64((*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest_written-request) >= 0 {
  6203. return int32(1)
  6204. }
  6205. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fqueue_len != 0 {
  6206. (*(*Tiovec)(unsafe.Pointer(bp))).Fiov_base = c + 4400 + 124
  6207. (*(*Tiovec)(unsafe.Pointer(bp))).Fiov_len = libc.Uint64FromInt32((*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fqueue_len)
  6208. (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fqueue_len = 0
  6209. return X_xcb_out_send(tls, c, bp, int32(1))
  6210. }
  6211. for (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Fwriting != 0 {
  6212. libc.Xpthread_cond_wait(tls, c+4400, c+24)
  6213. }
  6214. return int32(1)
  6215. }
  6216. const m_INT32_MAX1 = 2147483647
  6217. const m_MSG_CTRUNC1 = 8
  6218. const m_MSG_TRUNC1 = 32
  6219. const m_POLLOUT1 = 0x004
  6220. const m_UINT32_MAX1 = 4294967295
  6221. const m_XCB_ERROR = 0
  6222. const m_XCB_REPLY = 1
  6223. const m_XCB_XGE_EVENT = 35
  6224. type Txcb_special_event_t = struct {
  6225. Fnext uintptr
  6226. Fextension Tuint8_t
  6227. Feid Tuint32_t
  6228. Fstamp uintptr
  6229. Fevents uintptr
  6230. Fevents_tail uintptr
  6231. Fspecial_event_cond Tpthread_cond_t
  6232. }
  6233. type Txcb_special_event = Txcb_special_event_t
  6234. type Tevent_list = struct {
  6235. Fevent uintptr
  6236. Fnext uintptr
  6237. }
  6238. type Treply_list = struct {
  6239. Freply uintptr
  6240. Fnext uintptr
  6241. }
  6242. type Tpending_reply = struct {
  6243. Ffirst_request Tuint64_t
  6244. Flast_request Tuint64_t
  6245. Fworkaround _workarounds
  6246. Fflags int32
  6247. Fnext uintptr
  6248. }
  6249. type Treader_list = struct {
  6250. Frequest Tuint64_t
  6251. Fdata uintptr
  6252. Fnext uintptr
  6253. }
  6254. type Tspecial_list = struct {
  6255. Fse uintptr
  6256. Fnext uintptr
  6257. }
  6258. func _remove_finished_readers(tls *libc.TLS, prev_reader uintptr, completed Tuint64_t) {
  6259. for *(*uintptr)(unsafe.Pointer(prev_reader)) != 0 && libc.Int64FromUint64((*Treader_list)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(prev_reader)))).Frequest-completed) <= 0 {
  6260. /* If you don't have what you're looking for now, you never
  6261. * will. Wake up and leave me alone. */
  6262. libc.Xpthread_cond_signal(tls, (*Treader_list)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(prev_reader)))).Fdata)
  6263. *(*uintptr)(unsafe.Pointer(prev_reader)) = (*Treader_list)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(prev_reader)))).Fnext
  6264. }
  6265. }
  6266. func _read_fds(tls *libc.TLS, c uintptr, fds uintptr, nfd int32) (r int32) {
  6267. var ifds uintptr
  6268. var infd int32
  6269. _, _ = ifds, infd
  6270. ifds = c + 64 + 4256 + uintptr((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fin_fd.Fifd)*4
  6271. infd = (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fin_fd.Fnfd - (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fin_fd.Fifd
  6272. if nfd > infd {
  6273. return 0
  6274. }
  6275. libc.Xmemcpy(tls, fds, ifds, libc.Uint64FromInt32(nfd)*uint64(4))
  6276. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fin_fd.Fifd += nfd
  6277. return int32(1)
  6278. }
  6279. type Txcb_ge_special_event_t = struct {
  6280. Fresponse_type Tuint8_t
  6281. Fextension Tuint8_t
  6282. Fsequence Tuint16_t
  6283. Flength Tuint32_t
  6284. Fevtype Tuint16_t
  6285. Fpad0 [2]Tuint8_t
  6286. Feid Tuint32_t
  6287. Fpad1 [16]Tuint8_t
  6288. }
  6289. func _event_special(tls *libc.TLS, c uintptr, event uintptr) (r int32) {
  6290. var ges, special_event uintptr
  6291. _, _ = ges, special_event
  6292. ges = (*Tevent_list)(unsafe.Pointer(event)).Fevent
  6293. /* Special events are always XGE events */
  6294. if libc.Int32FromUint8((*Txcb_ge_special_event_t1)(unsafe.Pointer(ges)).Fresponse_type)&int32(0x7f) != int32(m_XCB_XGE_EVENT) {
  6295. return 0
  6296. }
  6297. special_event = (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fspecial_events
  6298. for {
  6299. if !(special_event != 0) {
  6300. break
  6301. }
  6302. if libc.Int32FromUint8((*Txcb_ge_special_event_t1)(unsafe.Pointer(ges)).Fextension) == libc.Int32FromUint8((*Txcb_special_event)(unsafe.Pointer(special_event)).Fextension) && (*Txcb_ge_special_event_t1)(unsafe.Pointer(ges)).Feid == (*Txcb_special_event)(unsafe.Pointer(special_event)).Feid {
  6303. *(*uintptr)(unsafe.Pointer((*Txcb_special_event)(unsafe.Pointer(special_event)).Fevents_tail)) = event
  6304. (*Txcb_special_event)(unsafe.Pointer(special_event)).Fevents_tail = event + 8
  6305. if (*Txcb_special_event)(unsafe.Pointer(special_event)).Fstamp != 0 {
  6306. *(*Tuint32_t)(unsafe.Pointer((*Txcb_special_event)(unsafe.Pointer(special_event)).Fstamp))++
  6307. }
  6308. libc.Xpthread_cond_signal(tls, special_event+40)
  6309. return int32(1)
  6310. }
  6311. goto _1
  6312. _1:
  6313. ;
  6314. special_event = (*Txcb_special_event)(unsafe.Pointer(special_event)).Fnext
  6315. }
  6316. return 0
  6317. }
  6318. func _read_packet(tls *libc.TLS, c uintptr) (r int32) {
  6319. bp := tls.Alloc(16)
  6320. defer tls.Free(16)
  6321. var buf, cur, event, oldpend, p, pend uintptr
  6322. var bufsize, eventlength, lastread, length, new_length Tuint64_t
  6323. var nfd int32
  6324. var v1 uint64
  6325. var _ /* genrep at bp+0 */ Txcb_generic_reply_t
  6326. _, _, _, _, _, _, _, _, _, _, _, _, _ = buf, bufsize, cur, event, eventlength, lastread, length, new_length, nfd, oldpend, p, pend, v1
  6327. length = uint64(32)
  6328. eventlength = uint64(0) /* length after first 32 bytes for GenericEvents */
  6329. nfd = 0
  6330. pend = uintptr(0)
  6331. /* Wait for there to be enough data for us to read a whole packet */
  6332. if libc.Uint64FromInt32((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fqueue_len) < length {
  6333. return 0
  6334. }
  6335. /* Get the response type, length, and sequence number. */
  6336. libc.Xmemcpy(tls, bp, c+64+52, uint64(8))
  6337. /* Compute 32-bit sequence number of this packet. */
  6338. if libc.Int32FromUint8((*(*Txcb_generic_reply_t)(unsafe.Pointer(bp))).Fresponse_type)&int32(0x7f) != int32(m_XCB_KEYMAP_NOTIFY) {
  6339. lastread = (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_read
  6340. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_read = lastread&uint64(0xffffffffffff0000) | uint64((*(*Txcb_generic_reply_t)(unsafe.Pointer(bp))).Fsequence)
  6341. if libc.Int64FromUint64((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_read-lastread) < 0 {
  6342. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_read += uint64(0x10000)
  6343. }
  6344. if libc.Int64FromUint64((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_read-(*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_expected) > 0 {
  6345. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_expected = (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_read
  6346. }
  6347. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_read != lastread {
  6348. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fcurrent_reply != 0 {
  6349. X_xcb_map_put(tls, (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Freplies, lastread, (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fcurrent_reply)
  6350. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fcurrent_reply = uintptr(0)
  6351. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fcurrent_reply_tail = c + 64 + 4184
  6352. }
  6353. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_completed = (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_read - uint64(1)
  6354. }
  6355. for (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fpending_replies != 0 && (*Tpending_reply1)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fpending_replies)).Fworkaround != int32(_WORKAROUND_EXTERNAL_SOCKET_OWNER) && libc.Int64FromUint64((*Tpending_reply1)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fpending_replies)).Flast_request-(*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_completed) <= 0 {
  6356. oldpend = (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fpending_replies
  6357. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fpending_replies = (*Tpending_reply)(unsafe.Pointer(oldpend)).Fnext
  6358. if !((*Tpending_reply)(unsafe.Pointer(oldpend)).Fnext != 0) {
  6359. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fpending_replies_tail = c + 64 + 4240
  6360. }
  6361. libc.Xfree(tls, oldpend)
  6362. }
  6363. if libc.Int32FromUint8((*(*Txcb_generic_reply_t)(unsafe.Pointer(bp))).Fresponse_type) == m_XCB_ERROR {
  6364. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_completed = (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_read
  6365. }
  6366. _remove_finished_readers(tls, c+64+4224, (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_completed)
  6367. }
  6368. if libc.Int32FromUint8((*(*Txcb_generic_reply_t)(unsafe.Pointer(bp))).Fresponse_type) == m_XCB_ERROR || libc.Int32FromUint8((*(*Txcb_generic_reply_t)(unsafe.Pointer(bp))).Fresponse_type) == int32(m_XCB_REPLY) {
  6369. pend = (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fpending_replies
  6370. if pend != 0 && !(libc.Int64FromUint64((*Tpending_reply)(unsafe.Pointer(pend)).Ffirst_request-(*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_read) <= 0 && ((*Tpending_reply)(unsafe.Pointer(pend)).Fworkaround == int32(_WORKAROUND_EXTERNAL_SOCKET_OWNER) || libc.Int64FromUint64((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_read-(*Tpending_reply)(unsafe.Pointer(pend)).Flast_request) <= 0)) {
  6371. pend = uintptr(0)
  6372. }
  6373. }
  6374. /* For reply packets, check that the entire packet is available. */
  6375. if libc.Int32FromUint8((*(*Txcb_generic_reply_t)(unsafe.Pointer(bp))).Fresponse_type) == int32(m_XCB_REPLY) {
  6376. if pend != 0 && (*Tpending_reply)(unsafe.Pointer(pend)).Fworkaround == int32(_WORKAROUND_GLX_GET_FB_CONFIGS_BUG) {
  6377. p = c + 64 + 52
  6378. new_length = uint64(*(*Tuint32_t)(unsafe.Pointer(p + 2*4))) * uint64(*(*Tuint32_t)(unsafe.Pointer(p + 3*4)))
  6379. if new_length >= uint64(libc.Uint32FromUint32(0xffffffff)/libc.Uint32FromUint32(16)) {
  6380. X_xcb_conn_shutdown(tls, c, int32(m_XCB_CONN_CLOSED_MEM_INSUFFICIENT))
  6381. return 0
  6382. }
  6383. (*(*Txcb_generic_reply_t)(unsafe.Pointer(bp))).Flength = uint32(new_length * libc.Uint64FromUint64(2))
  6384. }
  6385. length += uint64((*(*Txcb_generic_reply_t)(unsafe.Pointer(bp))).Flength) * uint64(4)
  6386. /* XXX a bit of a hack -- we "know" that all FD replys place
  6387. * the number of fds in the pad0 byte */
  6388. if pend != 0 && (*Tpending_reply)(unsafe.Pointer(pend)).Fflags&int32(_XCB_REQUEST_REPLY_FDS) != 0 {
  6389. nfd = libc.Int32FromUint8((*(*Txcb_generic_reply_t)(unsafe.Pointer(bp))).Fpad0)
  6390. }
  6391. }
  6392. /* XGE events may have sizes > 32 */
  6393. if libc.Int32FromUint8((*(*Txcb_generic_reply_t)(unsafe.Pointer(bp))).Fresponse_type)&int32(0x7f) == int32(m_XCB_XGE_EVENT) {
  6394. eventlength = uint64((*(*Txcb_generic_reply_t)(unsafe.Pointer(bp))).Flength) * uint64(4)
  6395. }
  6396. if libc.Int32FromUint8((*(*Txcb_generic_reply_t)(unsafe.Pointer(bp))).Fresponse_type) == int32(m_XCB_REPLY) {
  6397. v1 = uint64(0)
  6398. } else {
  6399. v1 = uint64(4)
  6400. }
  6401. bufsize = length + eventlength + libc.Uint64FromInt32(nfd)*uint64(4) + v1
  6402. if bufsize < libc.Uint64FromInt32(libc.Int32FromInt32(m_INT32_MAX1)) {
  6403. buf = libc.Xmalloc(tls, bufsize)
  6404. } else {
  6405. buf = libc.UintptrFromInt32(0)
  6406. }
  6407. if !(buf != 0) {
  6408. X_xcb_conn_shutdown(tls, c, int32(m_XCB_CONN_CLOSED_MEM_INSUFFICIENT))
  6409. return 0
  6410. }
  6411. if X_xcb_in_read_block(tls, c, buf, libc.Int32FromUint64(length)) <= 0 {
  6412. libc.Xfree(tls, buf)
  6413. return 0
  6414. }
  6415. /* pull in XGE event data if available, append after event struct */
  6416. if eventlength != 0 {
  6417. if X_xcb_in_read_block(tls, c, buf+1*36, libc.Int32FromUint64(eventlength)) <= 0 {
  6418. libc.Xfree(tls, buf)
  6419. return 0
  6420. }
  6421. }
  6422. if nfd != 0 {
  6423. if !(_read_fds(tls, c, buf+uintptr(length), nfd) != 0) {
  6424. libc.Xfree(tls, buf)
  6425. return 0
  6426. }
  6427. }
  6428. if pend != 0 && (*Tpending_reply)(unsafe.Pointer(pend)).Fflags&int32(_XCB_REQUEST_DISCARD_REPLY) != 0 {
  6429. libc.Xfree(tls, buf)
  6430. return int32(1)
  6431. }
  6432. if libc.Int32FromUint8((*(*Txcb_generic_reply_t)(unsafe.Pointer(bp))).Fresponse_type) != int32(m_XCB_REPLY) {
  6433. (*Txcb_generic_event_t)(unsafe.Pointer(buf)).Ffull_sequence = uint32((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_read)
  6434. }
  6435. /* reply, or checked error */
  6436. if libc.Int32FromUint8((*(*Txcb_generic_reply_t)(unsafe.Pointer(bp))).Fresponse_type) == int32(m_XCB_REPLY) || libc.Int32FromUint8((*(*Txcb_generic_reply_t)(unsafe.Pointer(bp))).Fresponse_type) == m_XCB_ERROR && pend != 0 && (*Tpending_reply)(unsafe.Pointer(pend)).Fflags&int32(_XCB_REQUEST_CHECKED) != 0 {
  6437. cur = libc.Xmalloc(tls, uint64(16))
  6438. if !(cur != 0) {
  6439. X_xcb_conn_shutdown(tls, c, int32(m_XCB_CONN_CLOSED_MEM_INSUFFICIENT))
  6440. libc.Xfree(tls, buf)
  6441. return 0
  6442. }
  6443. (*Treply_list)(unsafe.Pointer(cur)).Freply = buf
  6444. (*Treply_list)(unsafe.Pointer(cur)).Fnext = uintptr(0)
  6445. *(*uintptr)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fcurrent_reply_tail)) = cur
  6446. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fcurrent_reply_tail = cur + 8
  6447. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Freaders != 0 && (*Treader_list1)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Freaders)).Frequest == (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_read {
  6448. libc.Xpthread_cond_signal(tls, (*Treader_list1)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Freaders)).Fdata)
  6449. }
  6450. return int32(1)
  6451. }
  6452. /* event, or unchecked error */
  6453. event = libc.Xmalloc(tls, uint64(16))
  6454. if !(event != 0) {
  6455. X_xcb_conn_shutdown(tls, c, int32(m_XCB_CONN_CLOSED_MEM_INSUFFICIENT))
  6456. libc.Xfree(tls, buf)
  6457. return 0
  6458. }
  6459. (*Tevent_list)(unsafe.Pointer(event)).Fevent = buf
  6460. (*Tevent_list)(unsafe.Pointer(event)).Fnext = uintptr(0)
  6461. if !(_event_special(tls, c, event) != 0) {
  6462. *(*uintptr)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fevents_tail)) = event
  6463. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fevents_tail = event + 8
  6464. libc.Xpthread_cond_signal(tls, c+64)
  6465. }
  6466. return int32(1) /* I have something for you... */
  6467. }
  6468. func _get_event(tls *libc.TLS, c uintptr) (r uintptr) {
  6469. var cur, ret uintptr
  6470. _, _ = cur, ret
  6471. cur = (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fevents
  6472. if !((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fevents != 0) {
  6473. return uintptr(0)
  6474. }
  6475. ret = (*Tevent_list)(unsafe.Pointer(cur)).Fevent
  6476. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fevents = (*Tevent_list)(unsafe.Pointer(cur)).Fnext
  6477. if !((*Tevent_list)(unsafe.Pointer(cur)).Fnext != 0) {
  6478. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fevents_tail = c + 64 + 4208
  6479. }
  6480. libc.Xfree(tls, cur)
  6481. return ret
  6482. }
  6483. func _free_reply_list(tls *libc.TLS, head uintptr) {
  6484. var cur uintptr
  6485. _ = cur
  6486. for head != 0 {
  6487. cur = head
  6488. head = (*Treply_list)(unsafe.Pointer(cur)).Fnext
  6489. libc.Xfree(tls, (*Treply_list)(unsafe.Pointer(cur)).Freply)
  6490. libc.Xfree(tls, cur)
  6491. }
  6492. }
  6493. func _read_block(tls *libc.TLS, fd int32, buf uintptr, len1 Tintptr_t) (r int32) {
  6494. bp := tls.Alloc(16)
  6495. defer tls.Free(16)
  6496. var done, ret int32
  6497. var _ /* pfd at bp+0 */ Tpollfd
  6498. _, _ = done, ret
  6499. done = 0
  6500. for int64(done) < len1 {
  6501. ret = int32(libc.Xrecv(tls, fd, buf+uintptr(done), libc.Uint64FromInt64(len1-int64(done)), 0))
  6502. if ret > 0 {
  6503. done += ret
  6504. }
  6505. if ret < 0 && *(*int32)(unsafe.Pointer(libc.X__errno_location(tls))) == int32(m_EAGAIN) {
  6506. (*(*Tpollfd)(unsafe.Pointer(bp))).Ffd = fd
  6507. (*(*Tpollfd)(unsafe.Pointer(bp))).Fevents = int16(m_POLLIN)
  6508. (*(*Tpollfd)(unsafe.Pointer(bp))).Frevents = 0
  6509. for cond := true; cond; cond = ret == -int32(1) && *(*int32)(unsafe.Pointer(libc.X__errno_location(tls))) == int32(m_EINTR) {
  6510. ret = libc.Xpoll(tls, bp, uint64(1), -int32(1))
  6511. }
  6512. }
  6513. if ret <= 0 {
  6514. return ret
  6515. }
  6516. }
  6517. return int32(len1)
  6518. }
  6519. func _poll_for_reply(tls *libc.TLS, c uintptr, request Tuint64_t, reply uintptr, error1 uintptr) (r int32) {
  6520. var head uintptr
  6521. _ = head
  6522. /* If an error occurred when issuing the request, fail immediately. */
  6523. if !(request != 0) {
  6524. head = uintptr(0)
  6525. } else {
  6526. if libc.Int64FromUint64(request-(*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_read) < 0 {
  6527. head = X_xcb_map_remove(tls, (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Freplies, request)
  6528. if head != 0 && (*Treply_list)(unsafe.Pointer(head)).Fnext != 0 {
  6529. X_xcb_map_put(tls, (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Freplies, request, (*Treply_list)(unsafe.Pointer(head)).Fnext)
  6530. }
  6531. } else {
  6532. if request == (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_read && (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fcurrent_reply != 0 {
  6533. head = (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fcurrent_reply
  6534. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fcurrent_reply = (*Treply_list)(unsafe.Pointer(head)).Fnext
  6535. if !((*Treply_list)(unsafe.Pointer(head)).Fnext != 0) {
  6536. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fcurrent_reply_tail = c + 64 + 4184
  6537. }
  6538. } else {
  6539. if request == (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_completed {
  6540. head = uintptr(0)
  6541. } else {
  6542. return 0
  6543. }
  6544. }
  6545. }
  6546. }
  6547. if error1 != 0 {
  6548. *(*uintptr)(unsafe.Pointer(error1)) = uintptr(0)
  6549. }
  6550. *(*uintptr)(unsafe.Pointer(reply)) = uintptr(0)
  6551. if head != 0 {
  6552. if libc.Int32FromUint8((*Txcb_generic_reply_t)(unsafe.Pointer((*Treply_list)(unsafe.Pointer(head)).Freply)).Fresponse_type) == m_XCB_ERROR {
  6553. if error1 != 0 {
  6554. *(*uintptr)(unsafe.Pointer(error1)) = (*Treply_list)(unsafe.Pointer(head)).Freply
  6555. } else {
  6556. libc.Xfree(tls, (*Treply_list)(unsafe.Pointer(head)).Freply)
  6557. }
  6558. } else {
  6559. *(*uintptr)(unsafe.Pointer(reply)) = (*Treply_list)(unsafe.Pointer(head)).Freply
  6560. }
  6561. libc.Xfree(tls, head)
  6562. }
  6563. return int32(1)
  6564. }
  6565. func _insert_reader(tls *libc.TLS, prev_reader uintptr, reader uintptr, request Tuint64_t, cond uintptr) {
  6566. for *(*uintptr)(unsafe.Pointer(prev_reader)) != 0 && libc.Int64FromUint64((*Treader_list)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(prev_reader)))).Frequest-request) <= 0 {
  6567. prev_reader = *(*uintptr)(unsafe.Pointer(prev_reader)) + 16
  6568. }
  6569. (*Treader_list)(unsafe.Pointer(reader)).Frequest = request
  6570. (*Treader_list)(unsafe.Pointer(reader)).Fdata = cond
  6571. (*Treader_list)(unsafe.Pointer(reader)).Fnext = *(*uintptr)(unsafe.Pointer(prev_reader))
  6572. *(*uintptr)(unsafe.Pointer(prev_reader)) = reader
  6573. }
  6574. func _remove_reader(tls *libc.TLS, prev_reader uintptr, reader uintptr) {
  6575. for *(*uintptr)(unsafe.Pointer(prev_reader)) != 0 && libc.Int64FromUint64((*Treader_list)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(prev_reader)))).Frequest-(*Treader_list)(unsafe.Pointer(reader)).Frequest) <= 0 {
  6576. if *(*uintptr)(unsafe.Pointer(prev_reader)) == reader {
  6577. *(*uintptr)(unsafe.Pointer(prev_reader)) = (*Treader_list)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(prev_reader)))).Fnext
  6578. break
  6579. }
  6580. }
  6581. }
  6582. func _insert_special(tls *libc.TLS, prev_special uintptr, special uintptr, se uintptr) {
  6583. (*Tspecial_list)(unsafe.Pointer(special)).Fse = se
  6584. (*Tspecial_list)(unsafe.Pointer(special)).Fnext = *(*uintptr)(unsafe.Pointer(prev_special))
  6585. *(*uintptr)(unsafe.Pointer(prev_special)) = special
  6586. }
  6587. func _remove_special(tls *libc.TLS, prev_special uintptr, special uintptr) {
  6588. for *(*uintptr)(unsafe.Pointer(prev_special)) != 0 {
  6589. if *(*uintptr)(unsafe.Pointer(prev_special)) == special {
  6590. *(*uintptr)(unsafe.Pointer(prev_special)) = (*Tspecial_list)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(prev_special)))).Fnext
  6591. break
  6592. }
  6593. prev_special = *(*uintptr)(unsafe.Pointer(prev_special)) + 8
  6594. }
  6595. }
  6596. func _wait_for_reply(tls *libc.TLS, c uintptr, request Tuint64_t, e uintptr) (r uintptr) {
  6597. bp := tls.Alloc(80)
  6598. defer tls.Free(80)
  6599. var _ /* cond at bp+8 */ Tpthread_cond_t
  6600. var _ /* reader at bp+56 */ Treader_list
  6601. var _ /* ret at bp+0 */ uintptr
  6602. *(*uintptr)(unsafe.Pointer(bp)) = uintptr(0)
  6603. /* If this request has not been written yet, write it. */
  6604. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Freturn_socket != 0 || X_xcb_out_flush_to(tls, c, request) != 0 {
  6605. *(*Tpthread_cond_t)(unsafe.Pointer(bp + 8)) = Tpthread_cond_t{}
  6606. *(*int32)(unsafe.Pointer(bp + 8)) = 0
  6607. _insert_reader(tls, c+64+4224, bp+56, request, bp+8)
  6608. for !(_poll_for_reply(tls, c, request, bp, e) != 0) {
  6609. if !(X_xcb_conn_wait(tls, c, bp+8, uintptr(0), uintptr(0)) != 0) {
  6610. break
  6611. }
  6612. }
  6613. _remove_reader(tls, c+64+4224, bp+56)
  6614. libc.Xpthread_cond_destroy(tls, bp+8)
  6615. }
  6616. X_xcb_in_wake_up_next_reader(tls, c)
  6617. return *(*uintptr)(unsafe.Pointer(bp))
  6618. }
  6619. func _widen(tls *libc.TLS, c uintptr, request uint32) (r Tuint64_t) {
  6620. var widened_request Tuint64_t
  6621. _ = widened_request
  6622. widened_request = (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest&uint64(0xffffffff00000000) | uint64(request)
  6623. if widened_request > (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest {
  6624. widened_request -= libc.Uint64FromUint64(1) << libc.Int32FromInt32(32)
  6625. }
  6626. return widened_request
  6627. }
  6628. /* Public interface */
  6629. func Xxcb_wait_for_reply(tls *libc.TLS, c uintptr, request uint32, e uintptr) (r uintptr) {
  6630. var ret uintptr
  6631. _ = ret
  6632. if e != 0 {
  6633. *(*uintptr)(unsafe.Pointer(e)) = uintptr(0)
  6634. }
  6635. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  6636. return uintptr(0)
  6637. }
  6638. libc.Xpthread_mutex_lock(tls, c+24)
  6639. ret = _wait_for_reply(tls, c, _widen(tls, c, request), e)
  6640. libc.Xpthread_mutex_unlock(tls, c+24)
  6641. return ret
  6642. }
  6643. func Xxcb_wait_for_reply64(tls *libc.TLS, c uintptr, request Tuint64_t, e uintptr) (r uintptr) {
  6644. var ret uintptr
  6645. _ = ret
  6646. if e != 0 {
  6647. *(*uintptr)(unsafe.Pointer(e)) = uintptr(0)
  6648. }
  6649. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  6650. return uintptr(0)
  6651. }
  6652. libc.Xpthread_mutex_lock(tls, c+24)
  6653. ret = _wait_for_reply(tls, c, request, e)
  6654. libc.Xpthread_mutex_unlock(tls, c+24)
  6655. return ret
  6656. }
  6657. func Xxcb_get_reply_fds(tls *libc.TLS, c uintptr, reply uintptr, reply_size Tsize_t) (r uintptr) {
  6658. return reply + uintptr(reply_size)
  6659. }
  6660. func _insert_pending_discard(tls *libc.TLS, c uintptr, prev_next uintptr, seq Tuint64_t) {
  6661. var pend uintptr
  6662. _ = pend
  6663. pend = libc.Xmalloc(tls, uint64(32))
  6664. if !(pend != 0) {
  6665. X_xcb_conn_shutdown(tls, c, int32(m_XCB_CONN_CLOSED_MEM_INSUFFICIENT))
  6666. return
  6667. }
  6668. (*Tpending_reply)(unsafe.Pointer(pend)).Ffirst_request = seq
  6669. (*Tpending_reply)(unsafe.Pointer(pend)).Flast_request = seq
  6670. (*Tpending_reply)(unsafe.Pointer(pend)).Fworkaround = 0
  6671. (*Tpending_reply)(unsafe.Pointer(pend)).Fflags = int32(_XCB_REQUEST_DISCARD_REPLY)
  6672. (*Tpending_reply)(unsafe.Pointer(pend)).Fnext = *(*uintptr)(unsafe.Pointer(prev_next))
  6673. *(*uintptr)(unsafe.Pointer(prev_next)) = pend
  6674. if !((*Tpending_reply)(unsafe.Pointer(pend)).Fnext != 0) {
  6675. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fpending_replies_tail = pend + 24
  6676. }
  6677. }
  6678. func _discard_reply(tls *libc.TLS, c uintptr, request Tuint64_t) {
  6679. bp := tls.Alloc(16)
  6680. defer tls.Free(16)
  6681. var prev_pend uintptr
  6682. var _ /* reply at bp+0 */ uintptr
  6683. _ = prev_pend
  6684. /* Free any replies or errors that we've already read. Stop if
  6685. * xcb_wait_for_reply would block or we've run out of replies. */
  6686. for _poll_for_reply(tls, c, request, bp, uintptr(0)) != 0 && *(*uintptr)(unsafe.Pointer(bp)) != 0 {
  6687. libc.Xfree(tls, *(*uintptr)(unsafe.Pointer(bp)))
  6688. }
  6689. /* If we've proven there are no more responses coming, we're done. */
  6690. if libc.Int64FromUint64(request-(*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_completed) <= 0 {
  6691. return
  6692. }
  6693. /* Walk the list of pending requests. Mark the first match for deletion. */
  6694. prev_pend = c + 64 + 4240
  6695. for {
  6696. if !(*(*uintptr)(unsafe.Pointer(prev_pend)) != 0) {
  6697. break
  6698. }
  6699. if libc.Int64FromUint64((*Tpending_reply)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(prev_pend)))).Ffirst_request-request) > 0 {
  6700. break
  6701. }
  6702. if (*Tpending_reply)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(prev_pend)))).Ffirst_request == request {
  6703. /* Pending reply found. Mark for discard: */
  6704. *(*int32)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(prev_pend)) + 20)) |= int32(_XCB_REQUEST_DISCARD_REPLY)
  6705. return
  6706. }
  6707. goto _1
  6708. _1:
  6709. ;
  6710. prev_pend = *(*uintptr)(unsafe.Pointer(prev_pend)) + 24
  6711. }
  6712. /* Pending reply not found (likely due to _unchecked request). Create one: */
  6713. _insert_pending_discard(tls, c, prev_pend, request)
  6714. }
  6715. func Xxcb_discard_reply(tls *libc.TLS, c uintptr, sequence uint32) {
  6716. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  6717. return
  6718. }
  6719. /* If an error occurred when issuing the request, fail immediately. */
  6720. if !(sequence != 0) {
  6721. return
  6722. }
  6723. libc.Xpthread_mutex_lock(tls, c+24)
  6724. _discard_reply(tls, c, _widen(tls, c, sequence))
  6725. libc.Xpthread_mutex_unlock(tls, c+24)
  6726. }
  6727. func Xxcb_discard_reply64(tls *libc.TLS, c uintptr, sequence Tuint64_t) {
  6728. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  6729. return
  6730. }
  6731. /* If an error occurred when issuing the request, fail immediately. */
  6732. if !(sequence != 0) {
  6733. return
  6734. }
  6735. libc.Xpthread_mutex_lock(tls, c+24)
  6736. _discard_reply(tls, c, sequence)
  6737. libc.Xpthread_mutex_unlock(tls, c+24)
  6738. }
  6739. func Xxcb_poll_for_reply(tls *libc.TLS, c uintptr, request uint32, reply uintptr, error1 uintptr) (r int32) {
  6740. var ret int32
  6741. _ = ret
  6742. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  6743. *(*uintptr)(unsafe.Pointer(reply)) = uintptr(0)
  6744. if error1 != 0 {
  6745. *(*uintptr)(unsafe.Pointer(error1)) = uintptr(0)
  6746. }
  6747. return int32(1) /* would not block */
  6748. }
  6749. libc.Xpthread_mutex_lock(tls, c+24)
  6750. ret = _poll_for_reply(tls, c, _widen(tls, c, request), reply, error1)
  6751. if !(ret != 0) && (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Freading == 0 && X_xcb_in_read(tls, c) != 0 { /* _xcb_in_read shuts down the connection on error */
  6752. ret = _poll_for_reply(tls, c, _widen(tls, c, request), reply, error1)
  6753. }
  6754. libc.Xpthread_mutex_unlock(tls, c+24)
  6755. return ret
  6756. }
  6757. func Xxcb_poll_for_reply64(tls *libc.TLS, c uintptr, request Tuint64_t, reply uintptr, error1 uintptr) (r int32) {
  6758. var ret int32
  6759. _ = ret
  6760. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  6761. *(*uintptr)(unsafe.Pointer(reply)) = uintptr(0)
  6762. if error1 != 0 {
  6763. *(*uintptr)(unsafe.Pointer(error1)) = uintptr(0)
  6764. }
  6765. return int32(1) /* would not block */
  6766. }
  6767. libc.Xpthread_mutex_lock(tls, c+24)
  6768. ret = _poll_for_reply(tls, c, request, reply, error1)
  6769. if !(ret != 0) && (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Freading == 0 && X_xcb_in_read(tls, c) != 0 { /* _xcb_in_read shuts down the connection on error */
  6770. ret = _poll_for_reply(tls, c, request, reply, error1)
  6771. }
  6772. libc.Xpthread_mutex_unlock(tls, c+24)
  6773. return ret
  6774. }
  6775. func Xxcb_wait_for_event(tls *libc.TLS, c uintptr) (r uintptr) {
  6776. var ret, v1 uintptr
  6777. _, _ = ret, v1
  6778. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  6779. return uintptr(0)
  6780. }
  6781. libc.Xpthread_mutex_lock(tls, c+24)
  6782. /* get_event returns 0 on empty list. */
  6783. for {
  6784. v1 = _get_event(tls, c)
  6785. ret = v1
  6786. if !!(v1 != 0) {
  6787. break
  6788. }
  6789. if !(X_xcb_conn_wait(tls, c, c+64, uintptr(0), uintptr(0)) != 0) {
  6790. break
  6791. }
  6792. }
  6793. X_xcb_in_wake_up_next_reader(tls, c)
  6794. libc.Xpthread_mutex_unlock(tls, c+24)
  6795. return ret
  6796. }
  6797. func _poll_for_next_event(tls *libc.TLS, c uintptr, queued int32) (r uintptr) {
  6798. var ret uintptr
  6799. _ = ret
  6800. ret = uintptr(0)
  6801. if !((*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0) {
  6802. libc.Xpthread_mutex_lock(tls, c+24)
  6803. /* FIXME: follow X meets Z architecture changes. */
  6804. ret = _get_event(tls, c)
  6805. if !(ret != 0) && !(queued != 0) && (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Freading == 0 && X_xcb_in_read(tls, c) != 0 { /* _xcb_in_read shuts down the connection on error */
  6806. ret = _get_event(tls, c)
  6807. }
  6808. libc.Xpthread_mutex_unlock(tls, c+24)
  6809. }
  6810. return ret
  6811. }
  6812. func Xxcb_poll_for_event(tls *libc.TLS, c uintptr) (r uintptr) {
  6813. return _poll_for_next_event(tls, c, 0)
  6814. }
  6815. func Xxcb_poll_for_queued_event(tls *libc.TLS, c uintptr) (r uintptr) {
  6816. return _poll_for_next_event(tls, c, int32(1))
  6817. }
  6818. func Xxcb_request_check(tls *libc.TLS, c uintptr, cookie Txcb_void_cookie_t) (r uintptr) {
  6819. bp := tls.Alloc(16)
  6820. defer tls.Free(16)
  6821. var reply uintptr
  6822. var request Tuint64_t
  6823. var _ /* ret at bp+0 */ uintptr
  6824. _, _ = reply, request
  6825. *(*uintptr)(unsafe.Pointer(bp)) = uintptr(0)
  6826. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  6827. return uintptr(0)
  6828. }
  6829. libc.Xpthread_mutex_lock(tls, c+24)
  6830. request = _widen(tls, c, cookie.Fsequence)
  6831. if libc.Int64FromUint64(request-(*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_completed) > 0 {
  6832. if libc.Int64FromUint64(request-(*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Frequest_expected) >= 0 {
  6833. X_xcb_out_send_sync(tls, c)
  6834. }
  6835. if libc.Int64FromUint64(request-(*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest_expected_written) >= 0 {
  6836. X_xcb_out_flush_to(tls, c, (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest)
  6837. }
  6838. }
  6839. reply = _wait_for_reply(tls, c, request, bp)
  6840. libc.Xpthread_mutex_unlock(tls, c+24)
  6841. return *(*uintptr)(unsafe.Pointer(bp))
  6842. }
  6843. func _get_special_event(tls *libc.TLS, c uintptr, se uintptr) (r uintptr) {
  6844. var event, events, v1, v2 uintptr
  6845. _, _, _, _ = event, events, v1, v2
  6846. event = libc.UintptrFromInt32(0)
  6847. v1 = (*Txcb_special_event_t)(unsafe.Pointer(se)).Fevents
  6848. events = v1
  6849. if v1 != libc.UintptrFromInt32(0) {
  6850. event = (*Tevent_list)(unsafe.Pointer(events)).Fevent
  6851. v2 = (*Tevent_list)(unsafe.Pointer(events)).Fnext
  6852. (*Txcb_special_event_t)(unsafe.Pointer(se)).Fevents = v2
  6853. if !(v2 != 0) {
  6854. (*Txcb_special_event_t)(unsafe.Pointer(se)).Fevents_tail = se + 24
  6855. }
  6856. libc.Xfree(tls, events)
  6857. }
  6858. return event
  6859. }
  6860. func Xxcb_poll_for_special_event(tls *libc.TLS, c uintptr, se uintptr) (r uintptr) {
  6861. var event uintptr
  6862. _ = event
  6863. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  6864. return uintptr(0)
  6865. }
  6866. libc.Xpthread_mutex_lock(tls, c+24)
  6867. event = _get_special_event(tls, c, se)
  6868. if !(event != 0) && (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Freading == 0 && X_xcb_in_read(tls, c) != 0 { /* _xcb_in_read shuts down the connection on error */
  6869. event = _get_special_event(tls, c, se)
  6870. }
  6871. libc.Xpthread_mutex_unlock(tls, c+24)
  6872. return event
  6873. }
  6874. func Xxcb_wait_for_special_event(tls *libc.TLS, c uintptr, se uintptr) (r uintptr) {
  6875. bp := tls.Alloc(16)
  6876. defer tls.Free(16)
  6877. var event, v1 uintptr
  6878. var _ /* special at bp+0 */ Tspecial_list
  6879. _, _ = event, v1
  6880. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  6881. return uintptr(0)
  6882. }
  6883. libc.Xpthread_mutex_lock(tls, c+24)
  6884. _insert_special(tls, c+64+4232, bp, se)
  6885. /* get_special_event returns 0 on empty list. */
  6886. for {
  6887. v1 = _get_special_event(tls, c, se)
  6888. event = v1
  6889. if !!(v1 != 0) {
  6890. break
  6891. }
  6892. if !(X_xcb_conn_wait(tls, c, se+40, uintptr(0), uintptr(0)) != 0) {
  6893. break
  6894. }
  6895. }
  6896. _remove_special(tls, c+64+4232, bp)
  6897. X_xcb_in_wake_up_next_reader(tls, c)
  6898. libc.Xpthread_mutex_unlock(tls, c+24)
  6899. return event
  6900. }
  6901. func Xxcb_register_for_special_xge(tls *libc.TLS, c uintptr, ext uintptr, eid Tuint32_t, stamp uintptr) (r uintptr) {
  6902. var ext_reply, se uintptr
  6903. _, _ = ext_reply, se
  6904. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  6905. return libc.UintptrFromInt32(0)
  6906. }
  6907. ext_reply = Xxcb_get_extension_data(tls, c, ext)
  6908. if !(ext_reply != 0) {
  6909. return libc.UintptrFromInt32(0)
  6910. }
  6911. libc.Xpthread_mutex_lock(tls, c+24)
  6912. se = (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fspecial_events
  6913. for {
  6914. if !(se != 0) {
  6915. break
  6916. }
  6917. if libc.Int32FromUint8((*Txcb_special_event_t)(unsafe.Pointer(se)).Fextension) == libc.Int32FromUint8((*Txcb_query_extension_reply_t)(unsafe.Pointer(ext_reply)).Fmajor_opcode) && (*Txcb_special_event_t)(unsafe.Pointer(se)).Feid == eid {
  6918. libc.Xpthread_mutex_unlock(tls, c+24)
  6919. return libc.UintptrFromInt32(0)
  6920. }
  6921. goto _1
  6922. _1:
  6923. ;
  6924. se = (*Txcb_special_event_t)(unsafe.Pointer(se)).Fnext
  6925. }
  6926. se = libc.Xcalloc(tls, uint64(1), uint64(88))
  6927. if !(se != 0) {
  6928. libc.Xpthread_mutex_unlock(tls, c+24)
  6929. return libc.UintptrFromInt32(0)
  6930. }
  6931. (*Txcb_special_event_t)(unsafe.Pointer(se)).Fextension = (*Txcb_query_extension_reply_t)(unsafe.Pointer(ext_reply)).Fmajor_opcode
  6932. (*Txcb_special_event_t)(unsafe.Pointer(se)).Feid = eid
  6933. (*Txcb_special_event_t)(unsafe.Pointer(se)).Fevents = libc.UintptrFromInt32(0)
  6934. (*Txcb_special_event_t)(unsafe.Pointer(se)).Fevents_tail = se + 24
  6935. (*Txcb_special_event_t)(unsafe.Pointer(se)).Fstamp = stamp
  6936. libc.Xpthread_cond_init(tls, se+40, uintptr(0))
  6937. (*Txcb_special_event_t)(unsafe.Pointer(se)).Fnext = (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fspecial_events
  6938. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fspecial_events = se
  6939. libc.Xpthread_mutex_unlock(tls, c+24)
  6940. return se
  6941. }
  6942. func Xxcb_unregister_for_special_event(tls *libc.TLS, c uintptr, se uintptr) {
  6943. var events, next, prev, s, v2 uintptr
  6944. _, _, _, _, _ = events, next, prev, s, v2
  6945. if !(se != 0) {
  6946. return
  6947. }
  6948. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  6949. return
  6950. }
  6951. libc.Xpthread_mutex_lock(tls, c+24)
  6952. prev = c + 64 + 4328
  6953. for {
  6954. v2 = *(*uintptr)(unsafe.Pointer(prev))
  6955. s = v2
  6956. if !(v2 != libc.UintptrFromInt32(0)) {
  6957. break
  6958. }
  6959. if s == se {
  6960. *(*uintptr)(unsafe.Pointer(prev)) = (*Txcb_special_event_t)(unsafe.Pointer(se)).Fnext
  6961. events = (*Txcb_special_event_t)(unsafe.Pointer(se)).Fevents
  6962. for {
  6963. if !(events != 0) {
  6964. break
  6965. }
  6966. next = (*Tevent_list)(unsafe.Pointer(events)).Fnext
  6967. libc.Xfree(tls, (*Tevent_list)(unsafe.Pointer(events)).Fevent)
  6968. libc.Xfree(tls, events)
  6969. goto _3
  6970. _3:
  6971. ;
  6972. events = next
  6973. }
  6974. libc.Xpthread_cond_destroy(tls, se+40)
  6975. libc.Xfree(tls, se)
  6976. break
  6977. }
  6978. goto _1
  6979. _1:
  6980. ;
  6981. prev = s
  6982. }
  6983. libc.Xpthread_mutex_unlock(tls, c+24)
  6984. }
  6985. /* Private interface */
  6986. func X_xcb_in_init(tls *libc.TLS, in uintptr) (r int32) {
  6987. if libc.Xpthread_cond_init(tls, in, uintptr(0)) != 0 {
  6988. return 0
  6989. }
  6990. (*T_xcb_in)(unsafe.Pointer(in)).Freading = 0
  6991. (*T_xcb_in)(unsafe.Pointer(in)).Fqueue_len = 0
  6992. (*T_xcb_in)(unsafe.Pointer(in)).Frequest_read = uint64(0)
  6993. (*T_xcb_in)(unsafe.Pointer(in)).Frequest_completed = uint64(0)
  6994. (*T_xcb_in)(unsafe.Pointer(in)).Freplies = X_xcb_map_new(tls)
  6995. if !((*T_xcb_in)(unsafe.Pointer(in)).Freplies != 0) {
  6996. return 0
  6997. }
  6998. (*T_xcb_in)(unsafe.Pointer(in)).Fcurrent_reply_tail = in + 4184
  6999. (*T_xcb_in)(unsafe.Pointer(in)).Fevents_tail = in + 4208
  7000. (*T_xcb_in)(unsafe.Pointer(in)).Fpending_replies_tail = in + 4240
  7001. return int32(1)
  7002. }
  7003. func X_xcb_in_destroy(tls *libc.TLS, in uintptr) {
  7004. var e, pend uintptr
  7005. _, _ = e, pend
  7006. libc.Xpthread_cond_destroy(tls, in)
  7007. _free_reply_list(tls, (*T_xcb_in)(unsafe.Pointer(in)).Fcurrent_reply)
  7008. X_xcb_map_delete(tls, (*T_xcb_in)(unsafe.Pointer(in)).Freplies, __ccgo_fp(_free_reply_list))
  7009. for (*T_xcb_in)(unsafe.Pointer(in)).Fevents != 0 {
  7010. e = (*T_xcb_in)(unsafe.Pointer(in)).Fevents
  7011. (*T_xcb_in)(unsafe.Pointer(in)).Fevents = (*Tevent_list)(unsafe.Pointer(e)).Fnext
  7012. libc.Xfree(tls, (*Tevent_list)(unsafe.Pointer(e)).Fevent)
  7013. libc.Xfree(tls, e)
  7014. }
  7015. for (*T_xcb_in)(unsafe.Pointer(in)).Fpending_replies != 0 {
  7016. pend = (*T_xcb_in)(unsafe.Pointer(in)).Fpending_replies
  7017. (*T_xcb_in)(unsafe.Pointer(in)).Fpending_replies = (*Tpending_reply)(unsafe.Pointer(pend)).Fnext
  7018. libc.Xfree(tls, pend)
  7019. }
  7020. }
  7021. func X_xcb_in_wake_up_next_reader(tls *libc.TLS, c uintptr) {
  7022. var pthreadret int32
  7023. _ = pthreadret
  7024. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Freaders != 0 {
  7025. pthreadret = libc.Xpthread_cond_signal(tls, (*Treader_list1)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Freaders)).Fdata)
  7026. } else {
  7027. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fspecial_waiters != 0 {
  7028. pthreadret = libc.Xpthread_cond_signal(tls, (*Tspecial_list1)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fspecial_waiters)).Fse+40)
  7029. } else {
  7030. pthreadret = libc.Xpthread_cond_signal(tls, c+64)
  7031. }
  7032. }
  7033. }
  7034. func X_xcb_in_expect_reply(tls *libc.TLS, c uintptr, request Tuint64_t, workaround _workarounds, flags int32) (r int32) {
  7035. var pend uintptr
  7036. var v1 Tuint64_t
  7037. _, _ = pend, v1
  7038. pend = libc.Xmalloc(tls, uint64(32))
  7039. if !(pend != 0) {
  7040. X_xcb_conn_shutdown(tls, c, int32(m_XCB_CONN_CLOSED_MEM_INSUFFICIENT))
  7041. return 0
  7042. }
  7043. v1 = request
  7044. (*Tpending_reply)(unsafe.Pointer(pend)).Flast_request = v1
  7045. (*Tpending_reply)(unsafe.Pointer(pend)).Ffirst_request = v1
  7046. (*Tpending_reply)(unsafe.Pointer(pend)).Fworkaround = workaround
  7047. (*Tpending_reply)(unsafe.Pointer(pend)).Fflags = flags
  7048. (*Tpending_reply)(unsafe.Pointer(pend)).Fnext = uintptr(0)
  7049. *(*uintptr)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fpending_replies_tail)) = pend
  7050. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fpending_replies_tail = pend + 24
  7051. return int32(1)
  7052. }
  7053. func X_xcb_in_replies_done(tls *libc.TLS, c uintptr) {
  7054. var pend, prev_next uintptr
  7055. _, _ = pend, prev_next
  7056. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fpending_replies_tail != c+64+4240 {
  7057. pend = (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fpending_replies_tail - uintptr(Tsize_t(libc.UintptrFromInt32(0)+24))
  7058. if (*Tpending_reply1)(unsafe.Pointer(pend)).Fworkaround == int32(_WORKAROUND_EXTERNAL_SOCKET_OWNER) {
  7059. if libc.Int64FromUint64((*Tpending_reply1)(unsafe.Pointer(pend)).Ffirst_request-(*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest) <= 0 {
  7060. (*Tpending_reply1)(unsafe.Pointer(pend)).Flast_request = (*Txcb_connection_t)(unsafe.Pointer(c)).Fout.Frequest
  7061. (*Tpending_reply1)(unsafe.Pointer(pend)).Fworkaround = int32(_WORKAROUND_NONE)
  7062. } else {
  7063. /* The socket was taken, but no requests were actually sent
  7064. * so just discard the pending_reply that was created.
  7065. */
  7066. prev_next = c + 64 + 4240
  7067. for *(*uintptr)(unsafe.Pointer(prev_next)) != pend {
  7068. prev_next = *(*uintptr)(unsafe.Pointer(prev_next)) + 24
  7069. }
  7070. *(*uintptr)(unsafe.Pointer(prev_next)) = libc.UintptrFromInt32(0)
  7071. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fpending_replies_tail = prev_next
  7072. libc.Xfree(tls, pend)
  7073. }
  7074. }
  7075. }
  7076. }
  7077. func X_xcb_in_read(tls *libc.TLS, c uintptr) (r int32) {
  7078. bp := tls.Alloc(160)
  7079. defer tls.Free(160)
  7080. var hdr, v2, v3 uintptr
  7081. var i, n, nfd int32
  7082. var _ /* cmsgbuf at bp+16 */ struct {
  7083. Fbuf [0][80]int8
  7084. Fcmsghdr Tcmsghdr
  7085. F__ccgo_pad2 [64]byte
  7086. }
  7087. var _ /* iov at bp+0 */ Tiovec
  7088. var _ /* msg at bp+96 */ Tmsghdr
  7089. _, _, _, _, _, _ = hdr, i, n, nfd, v2, v3
  7090. *(*Tiovec)(unsafe.Pointer(bp)) = Tiovec{
  7091. Fiov_base: c + 64 + 52 + uintptr((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fqueue_len),
  7092. Fiov_len: uint64(4096) - libc.Uint64FromInt32((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fqueue_len),
  7093. }
  7094. *(*Tmsghdr)(unsafe.Pointer(bp + 96)) = Tmsghdr{
  7095. Fmsg_iov: bp,
  7096. Fmsg_iovlen: int32(1),
  7097. Fmsg_control: bp + 16,
  7098. Fmsg_controllen: uint32((libc.Uint64FromInt64(4)*libc.Uint64FromInt32(libc.Int32FromInt32(m_XCB_MAX_PASS_FD)-(*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fin_fd.Fnfd)+libc.Uint64FromInt64(8)-libc.Uint64FromInt32(1)) & ^(libc.Uint64FromInt64(8)-libc.Uint64FromInt32(1)) + (libc.Uint64FromInt64(16)+libc.Uint64FromInt64(8)-libc.Uint64FromInt32(1)) & ^(libc.Uint64FromInt64(8)-libc.Uint64FromInt32(1))),
  7099. }
  7100. n = int32(libc.Xrecvmsg(tls, (*Txcb_connection_t)(unsafe.Pointer(c)).Ffd, bp+96, 0))
  7101. /* Check for truncation errors. Only MSG_CTRUNC is
  7102. * probably possible here, which would indicate that
  7103. * the sender tried to transmit more than XCB_MAX_PASS_FD
  7104. * file descriptors.
  7105. */
  7106. if (*(*Tmsghdr)(unsafe.Pointer(bp + 96))).Fmsg_flags&(libc.Int32FromInt32(m_MSG_TRUNC1)|libc.Int32FromInt32(m_MSG_CTRUNC1)) != 0 {
  7107. X_xcb_conn_shutdown(tls, c, int32(m_XCB_CONN_CLOSED_FDPASSING_FAILED))
  7108. return 0
  7109. }
  7110. if n > 0 {
  7111. if uint64((*(*Tmsghdr)(unsafe.Pointer(bp + 96))).Fmsg_controllen) >= uint64(16) {
  7112. if uint64((*Tmsghdr)(unsafe.Pointer(bp+96)).Fmsg_controllen) >= uint64(16) {
  7113. v2 = (*Tmsghdr)(unsafe.Pointer(bp + 96)).Fmsg_control
  7114. } else {
  7115. v2 = libc.UintptrFromInt32(0)
  7116. }
  7117. hdr = v2
  7118. for {
  7119. if !(hdr != 0) {
  7120. break
  7121. }
  7122. if (*Tcmsghdr)(unsafe.Pointer(hdr)).Fcmsg_level == int32(m_SOL_SOCKET) && (*Tcmsghdr)(unsafe.Pointer(hdr)).Fcmsg_type == int32(m_SCM_RIGHTS) {
  7123. nfd = libc.Int32FromUint64((uint64((*Tcmsghdr)(unsafe.Pointer(hdr)).Fcmsg_len) - ((libc.Uint64FromInt64(16)+libc.Uint64FromInt64(8)-libc.Uint64FromInt32(1)) & ^(libc.Uint64FromInt64(8)-libc.Uint64FromInt32(1)) + libc.Uint64FromInt32(libc.Int32FromInt32(0)))) / uint64(4))
  7124. libc.Xmemcpy(tls, c+64+4256+uintptr((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fin_fd.Fnfd)*4, hdr+libc.UintptrFromInt32(1)*16, libc.Uint64FromInt32(nfd)*uint64(4))
  7125. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fin_fd.Fnfd += nfd
  7126. }
  7127. goto _1
  7128. _1:
  7129. ;
  7130. if uint64((*Tcmsghdr)(unsafe.Pointer(hdr)).Fcmsg_len) < uint64(16) || (uint64((*Tcmsghdr)(unsafe.Pointer(hdr)).Fcmsg_len)+uint64(8)-uint64(1))&libc.Uint64FromInt64(^libc.Int64FromUint64(libc.Uint64FromInt64(8)-libc.Uint64FromInt32(1)))+uint64(16) >= libc.Uint64FromInt64(int64((*Tmsghdr)(unsafe.Pointer(bp+96)).Fmsg_control+uintptr((*Tmsghdr)(unsafe.Pointer(bp+96)).Fmsg_controllen))-int64(hdr)) {
  7131. v3 = uintptr(0)
  7132. } else {
  7133. v3 = hdr + uintptr((uint64((*Tcmsghdr)(unsafe.Pointer(hdr)).Fcmsg_len)+libc.Uint64FromInt64(8)-libc.Uint64FromInt32(1))&libc.Uint64FromInt64(^libc.Int64FromUint64(libc.Uint64FromInt64(8)-libc.Uint64FromInt32(1))))
  7134. }
  7135. hdr = v3
  7136. }
  7137. }
  7138. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Ftotal_read += libc.Uint64FromInt32(n)
  7139. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fqueue_len += n
  7140. }
  7141. for _read_packet(tls, c) != 0 {
  7142. /* empty */
  7143. }
  7144. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fin_fd.Fnfd != 0 {
  7145. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fin_fd.Fnfd -= (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fin_fd.Fifd
  7146. libc.Xmemmove(tls, c+64+4256, c+64+4256+uintptr((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fin_fd.Fifd)*4, libc.Uint64FromInt32((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fin_fd.Fnfd)*uint64(4))
  7147. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fin_fd.Fifd = 0
  7148. /* If we have any left-over file descriptors after emptying
  7149. * the input buffer, then the server sent some that we weren't
  7150. * expecting. Close them and mark the connection as broken;
  7151. */
  7152. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fqueue_len == 0 && (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fin_fd.Fnfd != 0 {
  7153. i = 0
  7154. for {
  7155. if !(i < (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fin_fd.Fnfd) {
  7156. break
  7157. }
  7158. libc.Xclose(tls, *(*int32)(unsafe.Pointer(c + 64 + 4256 + uintptr(i)*4)))
  7159. goto _4
  7160. _4:
  7161. ;
  7162. i++
  7163. }
  7164. X_xcb_conn_shutdown(tls, c, int32(m_XCB_CONN_CLOSED_FDPASSING_FAILED))
  7165. return 0
  7166. }
  7167. }
  7168. if n > 0 || n < 0 && (*(*int32)(unsafe.Pointer(libc.X__errno_location(tls))) == int32(m_EAGAIN) || *(*int32)(unsafe.Pointer(libc.X__errno_location(tls))) == int32(m_EINTR)) {
  7169. return int32(1)
  7170. }
  7171. X_xcb_conn_shutdown(tls, c, int32(m_XCB_CONN_ERROR))
  7172. return 0
  7173. }
  7174. func X_xcb_in_read_block(tls *libc.TLS, c uintptr, buf uintptr, len1 int32) (r int32) {
  7175. var done, ret int32
  7176. _, _ = done, ret
  7177. done = (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fqueue_len
  7178. if len1 < done {
  7179. done = len1
  7180. }
  7181. libc.Xmemcpy(tls, buf, c+64+52, libc.Uint64FromInt32(done))
  7182. (*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fqueue_len -= done
  7183. libc.Xmemmove(tls, c+64+52, c+64+52+uintptr(done), libc.Uint64FromInt32((*Txcb_connection_t)(unsafe.Pointer(c)).Fin.Fqueue_len))
  7184. if len1 > done {
  7185. ret = _read_block(tls, (*Txcb_connection_t)(unsafe.Pointer(c)).Ffd, buf+uintptr(done), int64(len1-done))
  7186. if ret <= 0 {
  7187. X_xcb_conn_shutdown(tls, c, int32(m_XCB_CONN_ERROR))
  7188. return ret
  7189. }
  7190. }
  7191. return len1
  7192. }
  7193. type Tpending_reply1 = struct {
  7194. Ffirst_request Tuint64_t
  7195. Flast_request Tuint64_t
  7196. Fworkaround _workarounds
  7197. Fflags int32
  7198. Fnext uintptr
  7199. }
  7200. type Treader_list1 = struct {
  7201. Frequest Tuint64_t
  7202. Fdata uintptr
  7203. Fnext uintptr
  7204. }
  7205. type Tspecial_list1 = struct {
  7206. Fse uintptr
  7207. Fnext uintptr
  7208. }
  7209. type Txcb_ge_special_event_t1 = struct {
  7210. Fresponse_type Tuint8_t
  7211. Fextension Tuint8_t
  7212. Fsequence Tuint16_t
  7213. Flength Tuint32_t
  7214. Fevtype Tuint16_t
  7215. Fpad0 [2]Tuint8_t
  7216. Feid Tuint32_t
  7217. Fpad1 [16]Tuint8_t
  7218. }
  7219. const m_INT32_MAX2 = 0x7fffffff
  7220. const m_UINT32_MAX2 = "0xffffffffu"
  7221. type Tlazyreply = struct {
  7222. Ftag _lazy_reply_tag
  7223. Fvalue struct {
  7224. Freply [0]uintptr
  7225. Fcookie Txcb_query_extension_cookie_t
  7226. F__ccgo_pad2 [4]byte
  7227. }
  7228. }
  7229. func _get_index(tls *libc.TLS, c uintptr, idx int32) (r uintptr) {
  7230. var new_extensions uintptr
  7231. var new_size int32
  7232. _, _ = new_extensions, new_size
  7233. if idx > (*Txcb_connection_t)(unsafe.Pointer(c)).Fext.Fextensions_size {
  7234. new_size = idx << int32(1)
  7235. new_extensions = libc.Xrealloc(tls, (*Txcb_connection_t)(unsafe.Pointer(c)).Fext.Fextensions, uint64(16)*libc.Uint64FromInt32(new_size))
  7236. if !(new_extensions != 0) {
  7237. return uintptr(0)
  7238. }
  7239. libc.Xmemset(tls, new_extensions+uintptr((*Txcb_connection_t)(unsafe.Pointer(c)).Fext.Fextensions_size)*16, 0, uint64(16)*libc.Uint64FromInt32(new_size-(*Txcb_connection_t)(unsafe.Pointer(c)).Fext.Fextensions_size))
  7240. (*Txcb_connection_t)(unsafe.Pointer(c)).Fext.Fextensions = new_extensions
  7241. (*Txcb_connection_t)(unsafe.Pointer(c)).Fext.Fextensions_size = new_size
  7242. }
  7243. return (*Txcb_connection_t)(unsafe.Pointer(c)).Fext.Fextensions + uintptr(idx)*16 - uintptr(1)*16
  7244. }
  7245. func _get_lazyreply(tls *libc.TLS, c uintptr, ext uintptr) (r uintptr) {
  7246. var data uintptr
  7247. var v1 int32
  7248. _, _ = data, v1
  7249. libc.Xpthread_mutex_lock(tls, uintptr(unsafe.Pointer(&_global_lock)))
  7250. if !((*Txcb_extension_t)(unsafe.Pointer(ext)).Fglobal_id != 0) {
  7251. _next_global_id++
  7252. v1 = _next_global_id
  7253. (*Txcb_extension_t)(unsafe.Pointer(ext)).Fglobal_id = v1
  7254. }
  7255. libc.Xpthread_mutex_unlock(tls, uintptr(unsafe.Pointer(&_global_lock)))
  7256. data = _get_index(tls, c, (*Txcb_extension_t)(unsafe.Pointer(ext)).Fglobal_id)
  7257. if data != 0 && (*Tlazyreply)(unsafe.Pointer(data)).Ftag == int32(_LAZY_NONE) {
  7258. /* cache miss: query the server */
  7259. (*Tlazyreply)(unsafe.Pointer(data)).Ftag = int32(_LAZY_COOKIE)
  7260. (*Tlazyreply)(unsafe.Pointer(data)).Fvalue.Fcookie = Xxcb_query_extension(tls, c, uint16(libc.Xstrlen(tls, (*Txcb_extension_t)(unsafe.Pointer(ext)).Fname)), (*Txcb_extension_t)(unsafe.Pointer(ext)).Fname)
  7261. }
  7262. return data
  7263. }
  7264. var _global_lock = Tpthread_mutex_t{}
  7265. var _next_global_id int32
  7266. /* Public interface */
  7267. // C documentation
  7268. //
  7269. // /* Do not free the returned xcb_query_extension_reply_t - on return, it's aliased
  7270. // * from the cache. */
  7271. func Xxcb_get_extension_data(tls *libc.TLS, c uintptr, ext uintptr) (r uintptr) {
  7272. var data, v1 uintptr
  7273. _, _ = data, v1
  7274. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  7275. return uintptr(0)
  7276. }
  7277. libc.Xpthread_mutex_lock(tls, c+21064)
  7278. data = _get_lazyreply(tls, c, ext)
  7279. if data != 0 && (*Tlazyreply)(unsafe.Pointer(data)).Ftag == int32(_LAZY_COOKIE) {
  7280. (*Tlazyreply)(unsafe.Pointer(data)).Ftag = int32(_LAZY_FORCED)
  7281. *(*uintptr)(unsafe.Pointer(data + 8)) = Xxcb_query_extension_reply(tls, c, (*Tlazyreply)(unsafe.Pointer(data)).Fvalue.Fcookie, uintptr(0))
  7282. }
  7283. libc.Xpthread_mutex_unlock(tls, c+21064)
  7284. if data != 0 {
  7285. v1 = *(*uintptr)(unsafe.Pointer(data + 8))
  7286. } else {
  7287. v1 = uintptr(0)
  7288. }
  7289. return v1
  7290. }
  7291. func Xxcb_prefetch_extension_data(tls *libc.TLS, c uintptr, ext uintptr) {
  7292. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  7293. return
  7294. }
  7295. libc.Xpthread_mutex_lock(tls, c+21064)
  7296. _get_lazyreply(tls, c, ext)
  7297. libc.Xpthread_mutex_unlock(tls, c+21064)
  7298. }
  7299. /* Private interface */
  7300. func X_xcb_ext_init(tls *libc.TLS, c uintptr) (r int32) {
  7301. if libc.Xpthread_mutex_init(tls, c+21064, uintptr(0)) != 0 {
  7302. return 0
  7303. }
  7304. return int32(1)
  7305. }
  7306. func X_xcb_ext_destroy(tls *libc.TLS, c uintptr) {
  7307. var v1 int32
  7308. var v2 uintptr
  7309. _, _ = v1, v2
  7310. libc.Xpthread_mutex_destroy(tls, c+21064)
  7311. for {
  7312. v2 = c + 21064 + 48
  7313. v1 = *(*int32)(unsafe.Pointer(v2))
  7314. *(*int32)(unsafe.Pointer(v2))--
  7315. if !(v1 > 0) {
  7316. break
  7317. }
  7318. if (*(*Tlazyreply1)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fext.Fextensions + uintptr((*Txcb_connection_t)(unsafe.Pointer(c)).Fext.Fextensions_size)*16))).Ftag == int32(_LAZY_FORCED) {
  7319. libc.Xfree(tls, *(*uintptr)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fext.Fextensions + uintptr((*Txcb_connection_t)(unsafe.Pointer(c)).Fext.Fextensions_size)*16 + 8)))
  7320. }
  7321. }
  7322. libc.Xfree(tls, (*Txcb_connection_t)(unsafe.Pointer(c)).Fext.Fextensions)
  7323. }
  7324. type Tlazyreply1 = struct {
  7325. Ftag _lazy_reply_tag
  7326. Fvalue struct {
  7327. Freply [0]uintptr
  7328. Fcookie Txcb_query_extension_cookie_t
  7329. F__ccgo_pad2 [4]byte
  7330. }
  7331. }
  7332. const m_XCB_XCMISC_MAJOR_VERSION = 1
  7333. const m_XCB_XCMISC_MINOR_VERSION = 1
  7334. const m_XCB_XC_MISC_GET_VERSION = 0
  7335. const m_XCB_XC_MISC_GET_XID_LIST = 2
  7336. const m_XCB_XC_MISC_GET_XID_RANGE = 1
  7337. type Txcb_xc_misc_get_version_cookie_t = struct {
  7338. Fsequence uint32
  7339. }
  7340. type Txcb_xc_misc_get_version_request_t = struct {
  7341. Fmajor_opcode Tuint8_t
  7342. Fminor_opcode Tuint8_t
  7343. Flength Tuint16_t
  7344. Fclient_major_version Tuint16_t
  7345. Fclient_minor_version Tuint16_t
  7346. }
  7347. type Txcb_xc_misc_get_version_reply_t = struct {
  7348. Fresponse_type Tuint8_t
  7349. Fpad0 Tuint8_t
  7350. Fsequence Tuint16_t
  7351. Flength Tuint32_t
  7352. Fserver_major_version Tuint16_t
  7353. Fserver_minor_version Tuint16_t
  7354. }
  7355. type Txcb_xc_misc_get_xid_range_cookie_t = struct {
  7356. Fsequence uint32
  7357. }
  7358. type Txcb_xc_misc_get_xid_range_request_t = struct {
  7359. Fmajor_opcode Tuint8_t
  7360. Fminor_opcode Tuint8_t
  7361. Flength Tuint16_t
  7362. }
  7363. type Txcb_xc_misc_get_xid_range_reply_t = struct {
  7364. Fresponse_type Tuint8_t
  7365. Fpad0 Tuint8_t
  7366. Fsequence Tuint16_t
  7367. Flength Tuint32_t
  7368. Fstart_id Tuint32_t
  7369. Fcount Tuint32_t
  7370. }
  7371. type Txcb_xc_misc_get_xid_list_cookie_t = struct {
  7372. Fsequence uint32
  7373. }
  7374. type Txcb_xc_misc_get_xid_list_request_t = struct {
  7375. Fmajor_opcode Tuint8_t
  7376. Fminor_opcode Tuint8_t
  7377. Flength Tuint16_t
  7378. Fcount Tuint32_t
  7379. }
  7380. type Txcb_xc_misc_get_xid_list_reply_t = struct {
  7381. Fresponse_type Tuint8_t
  7382. Fpad0 Tuint8_t
  7383. Fsequence Tuint16_t
  7384. Flength Tuint32_t
  7385. Fids_len Tuint32_t
  7386. Fpad1 [20]Tuint8_t
  7387. }
  7388. /**
  7389. * @}
  7390. */
  7391. /* Public interface */
  7392. func Xxcb_generate_id(tls *libc.TLS, c uintptr) (r Tuint32_t) {
  7393. var range1, xc_misc_reply uintptr
  7394. var ret Tuint32_t
  7395. _, _, _ = range1, ret, xc_misc_reply
  7396. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  7397. return libc.Uint32FromInt32(-libc.Int32FromInt32(1))
  7398. }
  7399. libc.Xpthread_mutex_lock(tls, c+21120)
  7400. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fxid.Flast >= (*Txcb_connection_t)(unsafe.Pointer(c)).Fxid.Fmax-(*Txcb_connection_t)(unsafe.Pointer(c)).Fxid.Finc+uint32(1) {
  7401. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fxid.Flast == uint32(0) {
  7402. /* finish setting up initial range */
  7403. (*Txcb_connection_t)(unsafe.Pointer(c)).Fxid.Fmax = (*Txcb_setup_t)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup)).Fresource_id_mask
  7404. } else {
  7405. /* check for extension */
  7406. xc_misc_reply = Xxcb_get_extension_data(tls, c, uintptr(unsafe.Pointer(&Xxcb_xc_misc_id)))
  7407. if !(xc_misc_reply != 0) || !((*Txcb_query_extension_reply_t)(unsafe.Pointer(xc_misc_reply)).Fpresent != 0) {
  7408. libc.Xpthread_mutex_unlock(tls, c+21120)
  7409. return libc.Uint32FromInt32(-libc.Int32FromInt32(1))
  7410. }
  7411. /* get new range */
  7412. range1 = Xxcb_xc_misc_get_xid_range_reply(tls, c, Xxcb_xc_misc_get_xid_range(tls, c), uintptr(0))
  7413. /* XXX The latter disjunct is what the server returns
  7414. when it is out of XIDs. Sweet. */
  7415. if !(range1 != 0) || (*Txcb_xc_misc_get_xid_range_reply_t)(unsafe.Pointer(range1)).Fstart_id == uint32(0) && (*Txcb_xc_misc_get_xid_range_reply_t)(unsafe.Pointer(range1)).Fcount == uint32(1) {
  7416. libc.Xpthread_mutex_unlock(tls, c+21120)
  7417. return libc.Uint32FromInt32(-libc.Int32FromInt32(1))
  7418. }
  7419. (*Txcb_connection_t)(unsafe.Pointer(c)).Fxid.Flast = (*Txcb_xc_misc_get_xid_range_reply_t)(unsafe.Pointer(range1)).Fstart_id
  7420. (*Txcb_connection_t)(unsafe.Pointer(c)).Fxid.Fmax = (*Txcb_xc_misc_get_xid_range_reply_t)(unsafe.Pointer(range1)).Fstart_id + ((*Txcb_xc_misc_get_xid_range_reply_t)(unsafe.Pointer(range1)).Fcount-uint32(1))*(*Txcb_connection_t)(unsafe.Pointer(c)).Fxid.Finc
  7421. libc.Xfree(tls, range1)
  7422. }
  7423. } else {
  7424. (*Txcb_connection_t)(unsafe.Pointer(c)).Fxid.Flast += (*Txcb_connection_t)(unsafe.Pointer(c)).Fxid.Finc
  7425. }
  7426. ret = (*Txcb_connection_t)(unsafe.Pointer(c)).Fxid.Flast | (*Txcb_connection_t)(unsafe.Pointer(c)).Fxid.Fbase
  7427. libc.Xpthread_mutex_unlock(tls, c+21120)
  7428. return ret
  7429. }
  7430. /* Private interface */
  7431. func X_xcb_xid_init(tls *libc.TLS, c uintptr) (r int32) {
  7432. if libc.Xpthread_mutex_init(tls, c+21120, uintptr(0)) != 0 {
  7433. return 0
  7434. }
  7435. (*Txcb_connection_t)(unsafe.Pointer(c)).Fxid.Flast = uint32(0)
  7436. (*Txcb_connection_t)(unsafe.Pointer(c)).Fxid.Fmax = uint32(0)
  7437. (*Txcb_connection_t)(unsafe.Pointer(c)).Fxid.Fbase = (*Txcb_setup_t)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup)).Fresource_id_base
  7438. (*Txcb_connection_t)(unsafe.Pointer(c)).Fxid.Finc = (*Txcb_setup_t)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup)).Fresource_id_mask & -(*Txcb_setup_t)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup)).Fresource_id_mask
  7439. return int32(1)
  7440. }
  7441. func X_xcb_xid_destroy(tls *libc.TLS, c uintptr) {
  7442. libc.Xpthread_mutex_destroy(tls, c+21120)
  7443. }
  7444. type T_xcb_map = struct {
  7445. Fhead uintptr
  7446. Ftail uintptr
  7447. }
  7448. type Tnode = struct {
  7449. Fnext uintptr
  7450. Fkey Tuint64_t
  7451. Fdata uintptr
  7452. }
  7453. type T_xcb_map1 = struct {
  7454. Fhead uintptr
  7455. Ftail uintptr
  7456. }
  7457. /* Private interface */
  7458. func X_xcb_map_new(tls *libc.TLS) (r uintptr) {
  7459. var list uintptr
  7460. _ = list
  7461. list = libc.Xmalloc(tls, uint64(16))
  7462. if !(list != 0) {
  7463. return uintptr(0)
  7464. }
  7465. (*T_xcb_map)(unsafe.Pointer(list)).Fhead = uintptr(0)
  7466. (*T_xcb_map)(unsafe.Pointer(list)).Ftail = list
  7467. return list
  7468. }
  7469. func X_xcb_map_delete(tls *libc.TLS, list uintptr, do_free Txcb_list_free_func_t) {
  7470. var cur uintptr
  7471. _ = cur
  7472. if !(list != 0) {
  7473. return
  7474. }
  7475. for (*T_xcb_map)(unsafe.Pointer(list)).Fhead != 0 {
  7476. cur = (*T_xcb_map)(unsafe.Pointer(list)).Fhead
  7477. if do_free != 0 {
  7478. (*(*func(*libc.TLS, uintptr))(unsafe.Pointer(&struct{ uintptr }{do_free})))(tls, (*Tnode)(unsafe.Pointer(cur)).Fdata)
  7479. }
  7480. (*T_xcb_map)(unsafe.Pointer(list)).Fhead = (*Tnode)(unsafe.Pointer(cur)).Fnext
  7481. libc.Xfree(tls, cur)
  7482. }
  7483. libc.Xfree(tls, list)
  7484. }
  7485. func X_xcb_map_put(tls *libc.TLS, list uintptr, key Tuint64_t, data uintptr) (r int32) {
  7486. var cur uintptr
  7487. _ = cur
  7488. cur = libc.Xmalloc(tls, uint64(24))
  7489. if !(cur != 0) {
  7490. return 0
  7491. }
  7492. (*Tnode)(unsafe.Pointer(cur)).Fkey = key
  7493. (*Tnode)(unsafe.Pointer(cur)).Fdata = data
  7494. (*Tnode)(unsafe.Pointer(cur)).Fnext = uintptr(0)
  7495. *(*uintptr)(unsafe.Pointer((*T_xcb_map)(unsafe.Pointer(list)).Ftail)) = cur
  7496. (*T_xcb_map)(unsafe.Pointer(list)).Ftail = cur
  7497. return int32(1)
  7498. }
  7499. func X_xcb_map_remove(tls *libc.TLS, list uintptr, key Tuint64_t) (r uintptr) {
  7500. var cur, ret, tmp uintptr
  7501. _, _, _ = cur, ret, tmp
  7502. cur = list
  7503. for {
  7504. if !(*(*uintptr)(unsafe.Pointer(cur)) != 0) {
  7505. break
  7506. }
  7507. if (*Tnode)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(cur)))).Fkey == key {
  7508. tmp = *(*uintptr)(unsafe.Pointer(cur))
  7509. ret = (*Tnode)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(cur)))).Fdata
  7510. *(*uintptr)(unsafe.Pointer(cur)) = (*Tnode)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(cur)))).Fnext
  7511. if !(*(*uintptr)(unsafe.Pointer(cur)) != 0) {
  7512. (*T_xcb_map)(unsafe.Pointer(list)).Ftail = cur
  7513. }
  7514. libc.Xfree(tls, tmp)
  7515. return ret
  7516. }
  7517. goto _1
  7518. _1:
  7519. ;
  7520. cur = *(*uintptr)(unsafe.Pointer(cur))
  7521. }
  7522. return uintptr(0)
  7523. }
  7524. const m_AI_ADDRCONFIG = 0x20
  7525. const m_AI_ALL = 0x10
  7526. const m_AI_CANONNAME = 0x02
  7527. const m_AI_NUMERICHOST = 4
  7528. const m_AI_NUMERICSERV = 1024
  7529. const m_AI_PASSIVE = 0x01
  7530. const m_AI_V4MAPPED = 0x08
  7531. const m_HOST_NOT_FOUND = 1
  7532. const m_MSG_CTRUNC2 = 0x0008
  7533. const m_MSG_TRUNC2 = 0x0020
  7534. const m_NI_DGRAM = 0x10
  7535. const m_NI_MAXHOST = 255
  7536. const m_NI_MAXSERV = 32
  7537. const m_NI_NAMEREQD = 0x08
  7538. const m_NI_NOFQDN = 0x04
  7539. const m_NI_NUMERICHOST = 0x01
  7540. const m_NI_NUMERICSCOPE = 0x100
  7541. const m_NI_NUMERICSERV = 0x02
  7542. const m_NO_ADDRESS = "NO_DATA"
  7543. const m_NO_DATA = 4
  7544. const m_NO_RECOVERY = 3
  7545. const m_O_NONBLOCK1 = 04000
  7546. const m_SCM_RIGHTS1 = 0x01
  7547. const m_SOCK_CLOEXEC1 = 524288
  7548. const m_SOL_TCP = 6
  7549. const m_TCPI_OPT_ECN = 8
  7550. const m_TCPI_OPT_SACK = 2
  7551. const m_TCPI_OPT_TIMESTAMPS = 1
  7552. const m_TCPI_OPT_WSCALE = 4
  7553. const m_TCPOLEN_MAXSEG = 4
  7554. const m_TCPOLEN_SACK_PERMITTED = 2
  7555. const m_TCPOLEN_TIMESTAMP = 10
  7556. const m_TCPOLEN_WINDOW = 3
  7557. const m_TCPOPT_EOL = 0
  7558. const m_TCPOPT_MAXSEG = 2
  7559. const m_TCPOPT_NOP = 1
  7560. const m_TCPOPT_SACK = 5
  7561. const m_TCPOPT_SACK_PERMITTED = 4
  7562. const m_TCPOPT_TIMESTAMP = 8
  7563. const m_TCPOPT_WINDOW = 3
  7564. const m_TCP_CA_CWR = 2
  7565. const m_TCP_CA_Disorder = 1
  7566. const m_TCP_CA_Loss = 4
  7567. const m_TCP_CA_Open = 0
  7568. const m_TCP_CA_Recovery = 3
  7569. const m_TCP_CC_INFO = 26
  7570. const m_TCP_CLOSE = 7
  7571. const m_TCP_CLOSE_WAIT = 8
  7572. const m_TCP_CLOSING = 11
  7573. const m_TCP_CM_INQ = "TCP_INQ"
  7574. const m_TCP_CONGESTION = 13
  7575. const m_TCP_CORK = 3
  7576. const m_TCP_DEFER_ACCEPT = 9
  7577. const m_TCP_ESTABLISHED = 1
  7578. const m_TCP_FASTOPEN = 23
  7579. const m_TCP_FASTOPEN_CONNECT = 30
  7580. const m_TCP_FASTOPEN_KEY = 33
  7581. const m_TCP_FASTOPEN_NO_COOKIE = 34
  7582. const m_TCP_FIN_WAIT1 = 4
  7583. const m_TCP_FIN_WAIT2 = 5
  7584. const m_TCP_INFO = 11
  7585. const m_TCP_INQ = 36
  7586. const m_TCP_KEEPCNT = 6
  7587. const m_TCP_KEEPIDLE = 4
  7588. const m_TCP_KEEPINTVL = 5
  7589. const m_TCP_LAST_ACK = 9
  7590. const m_TCP_LINGER2 = 8
  7591. const m_TCP_LISTEN = 10
  7592. const m_TCP_MAXSEG = 2
  7593. const m_TCP_MD5SIG = 14
  7594. const m_TCP_MD5SIG_EXT = 32
  7595. const m_TCP_MD5SIG_FLAG_IFINDEX = 0x2
  7596. const m_TCP_MD5SIG_FLAG_PREFIX = 0x1
  7597. const m_TCP_MD5SIG_MAXKEYLEN = 80
  7598. const m_TCP_NODELAY = 1
  7599. const m_TCP_NOTSENT_LOWAT = 25
  7600. const m_TCP_QUEUE_SEQ = 21
  7601. const m_TCP_QUICKACK = 12
  7602. const m_TCP_RECEIVE_ZEROCOPY_FLAG_TLB_CLEAN_HINT = 0x1
  7603. const m_TCP_REPAIR = 19
  7604. const m_TCP_REPAIR_OFF = 0
  7605. const m_TCP_REPAIR_ON = 1
  7606. const m_TCP_REPAIR_OPTIONS = 22
  7607. const m_TCP_REPAIR_QUEUE = 20
  7608. const m_TCP_REPAIR_WINDOW = 29
  7609. const m_TCP_SAVED_SYN = 28
  7610. const m_TCP_SAVE_SYN = 27
  7611. const m_TCP_SYNCNT = 7
  7612. const m_TCP_SYN_RECV = 3
  7613. const m_TCP_SYN_SENT = 2
  7614. const m_TCP_THIN_DUPACK = 17
  7615. const m_TCP_THIN_LINEAR_TIMEOUTS = 16
  7616. const m_TCP_TIMESTAMP = 24
  7617. const m_TCP_TIME_WAIT = 6
  7618. const m_TCP_TX_DELAY = 37
  7619. const m_TCP_ULP = 31
  7620. const m_TCP_USER_TIMEOUT = 18
  7621. const m_TCP_WINDOW_CLAMP = 10
  7622. const m_TCP_ZEROCOPY_RECEIVE = 35
  7623. const m_TH_ACK = 0x10
  7624. const m_TH_FIN = 0x01
  7625. const m_TH_PUSH = 0x08
  7626. const m_TH_RST = 0x04
  7627. const m_TH_SYN = 0x02
  7628. const m_TH_URG = 0x20
  7629. const m_TRY_AGAIN = 2
  7630. type Tmax_align_t = struct {
  7631. F__ll int64
  7632. F__ld float64
  7633. }
  7634. type Tptrdiff_t = int64
  7635. type Tsockaddr_un = struct {
  7636. Fsun_family Tsa_family_t
  7637. Fsun_path [108]int8
  7638. }
  7639. const _TCP_NLA_PAD = 0
  7640. const _TCP_NLA_BUSY = 1
  7641. const _TCP_NLA_RWND_LIMITED = 2
  7642. const _TCP_NLA_SNDBUF_LIMITED = 3
  7643. const _TCP_NLA_DATA_SEGS_OUT = 4
  7644. const _TCP_NLA_TOTAL_RETRANS = 5
  7645. const _TCP_NLA_PACING_RATE = 6
  7646. const _TCP_NLA_DELIVERY_RATE = 7
  7647. const _TCP_NLA_SND_CWND = 8
  7648. const _TCP_NLA_REORDERING = 9
  7649. const _TCP_NLA_MIN_RTT = 10
  7650. const _TCP_NLA_RECUR_RETRANS = 11
  7651. const _TCP_NLA_DELIVERY_RATE_APP_LMT = 12
  7652. const _TCP_NLA_SNDQ_SIZE = 13
  7653. const _TCP_NLA_CA_STATE = 14
  7654. const _TCP_NLA_SND_SSTHRESH = 15
  7655. const _TCP_NLA_DELIVERED = 16
  7656. const _TCP_NLA_DELIVERED_CE = 17
  7657. const _TCP_NLA_BYTES_SENT = 18
  7658. const _TCP_NLA_BYTES_RETRANS = 19
  7659. const _TCP_NLA_DSACK_DUPS = 20
  7660. const _TCP_NLA_REORD_SEEN = 21
  7661. const _TCP_NLA_SRTT = 22
  7662. const _TCP_NLA_TIMEOUT_REHASH = 23
  7663. const _TCP_NLA_BYTES_NOTSENT = 24
  7664. const _TCP_NLA_EDT = 25
  7665. const _TCP_NLA_TTL = 26
  7666. type Ttcp_seq = uint32
  7667. type Ttcphdr = struct {
  7668. F__ccgo0_0 struct {
  7669. F__ccgo1_0 [0]struct {
  7670. Fth_sport Tuint16_t
  7671. Fth_dport Tuint16_t
  7672. Fth_seq Tuint32_t
  7673. Fth_ack Tuint32_t
  7674. F__ccgo12 uint8
  7675. Fth_flags Tuint8_t
  7676. Fth_win Tuint16_t
  7677. Fth_sum Tuint16_t
  7678. Fth_urp Tuint16_t
  7679. }
  7680. F__ccgo0_0 struct {
  7681. Fsource Tuint16_t
  7682. Fdest Tuint16_t
  7683. Fseq Tuint32_t
  7684. Fack_seq Tuint32_t
  7685. F__ccgo12 uint16
  7686. Fwindow Tuint16_t
  7687. Fcheck Tuint16_t
  7688. Furg_ptr Tuint16_t
  7689. }
  7690. }
  7691. }
  7692. type _tcp_fastopen_client_fail = int32
  7693. const _TFO_STATUS_UNSPEC = 0
  7694. const _TFO_COOKIE_UNAVAILABLE = 1
  7695. const _TFO_DATA_NOT_ACKED = 2
  7696. const _TFO_SYN_RETRANSMITTED = 3
  7697. type Ttcp_info = struct {
  7698. Ftcpi_state Tuint8_t
  7699. Ftcpi_ca_state Tuint8_t
  7700. Ftcpi_retransmits Tuint8_t
  7701. Ftcpi_probes Tuint8_t
  7702. Ftcpi_backoff Tuint8_t
  7703. Ftcpi_options Tuint8_t
  7704. F__ccgo6 uint8
  7705. F__ccgo7 uint8
  7706. Ftcpi_rto Tuint32_t
  7707. Ftcpi_ato Tuint32_t
  7708. Ftcpi_snd_mss Tuint32_t
  7709. Ftcpi_rcv_mss Tuint32_t
  7710. Ftcpi_unacked Tuint32_t
  7711. Ftcpi_sacked Tuint32_t
  7712. Ftcpi_lost Tuint32_t
  7713. Ftcpi_retrans Tuint32_t
  7714. Ftcpi_fackets Tuint32_t
  7715. Ftcpi_last_data_sent Tuint32_t
  7716. Ftcpi_last_ack_sent Tuint32_t
  7717. Ftcpi_last_data_recv Tuint32_t
  7718. Ftcpi_last_ack_recv Tuint32_t
  7719. Ftcpi_pmtu Tuint32_t
  7720. Ftcpi_rcv_ssthresh Tuint32_t
  7721. Ftcpi_rtt Tuint32_t
  7722. Ftcpi_rttvar Tuint32_t
  7723. Ftcpi_snd_ssthresh Tuint32_t
  7724. Ftcpi_snd_cwnd Tuint32_t
  7725. Ftcpi_advmss Tuint32_t
  7726. Ftcpi_reordering Tuint32_t
  7727. Ftcpi_rcv_rtt Tuint32_t
  7728. Ftcpi_rcv_space Tuint32_t
  7729. Ftcpi_total_retrans Tuint32_t
  7730. Ftcpi_pacing_rate Tuint64_t
  7731. Ftcpi_max_pacing_rate Tuint64_t
  7732. Ftcpi_bytes_acked Tuint64_t
  7733. Ftcpi_bytes_received Tuint64_t
  7734. Ftcpi_segs_out Tuint32_t
  7735. Ftcpi_segs_in Tuint32_t
  7736. Ftcpi_notsent_bytes Tuint32_t
  7737. Ftcpi_min_rtt Tuint32_t
  7738. Ftcpi_data_segs_in Tuint32_t
  7739. Ftcpi_data_segs_out Tuint32_t
  7740. Ftcpi_delivery_rate Tuint64_t
  7741. Ftcpi_busy_time Tuint64_t
  7742. Ftcpi_rwnd_limited Tuint64_t
  7743. Ftcpi_sndbuf_limited Tuint64_t
  7744. Ftcpi_delivered Tuint32_t
  7745. Ftcpi_delivered_ce Tuint32_t
  7746. Ftcpi_bytes_sent Tuint64_t
  7747. Ftcpi_bytes_retrans Tuint64_t
  7748. Ftcpi_dsack_dups Tuint32_t
  7749. Ftcpi_reord_seen Tuint32_t
  7750. Ftcpi_rcv_ooopack Tuint32_t
  7751. Ftcpi_snd_wnd Tuint32_t
  7752. }
  7753. type Ttcp_md5sig = struct {
  7754. Ftcpm_addr Tsockaddr_storage
  7755. Ftcpm_flags Tuint8_t
  7756. Ftcpm_prefixlen Tuint8_t
  7757. Ftcpm_keylen Tuint16_t
  7758. Ftcpm_ifindex int32
  7759. Ftcpm_key [80]Tuint8_t
  7760. }
  7761. type Ttcp_diag_md5sig = struct {
  7762. Ftcpm_family Tuint8_t
  7763. Ftcpm_prefixlen Tuint8_t
  7764. Ftcpm_keylen Tuint16_t
  7765. Ftcpm_addr [4]Tuint32_t
  7766. Ftcpm_key [80]Tuint8_t
  7767. }
  7768. type Ttcp_repair_window = struct {
  7769. Fsnd_wl1 Tuint32_t
  7770. Fsnd_wnd Tuint32_t
  7771. Fmax_window Tuint32_t
  7772. Frcv_wnd Tuint32_t
  7773. Frcv_wup Tuint32_t
  7774. }
  7775. type Ttcp_zerocopy_receive = struct {
  7776. Faddress Tuint64_t
  7777. Flength Tuint32_t
  7778. Frecv_skip_hint Tuint32_t
  7779. Finq Tuint32_t
  7780. Ferr Tint32_t
  7781. Fcopybuf_address Tuint64_t
  7782. Fcopybuf_len Tint32_t
  7783. Fflags Tuint32_t
  7784. Fmsg_control Tuint64_t
  7785. Fmsg_controllen Tuint64_t
  7786. Fmsg_flags Tuint32_t
  7787. Freserved Tuint32_t
  7788. }
  7789. type Taddrinfo = struct {
  7790. Fai_flags int32
  7791. Fai_family int32
  7792. Fai_socktype int32
  7793. Fai_protocol int32
  7794. Fai_addrlen Tsocklen_t
  7795. Fai_addr uintptr
  7796. Fai_canonname uintptr
  7797. Fai_next uintptr
  7798. }
  7799. type Tnetent = struct {
  7800. Fn_name uintptr
  7801. Fn_aliases uintptr
  7802. Fn_addrtype int32
  7803. Fn_net Tuint32_t
  7804. }
  7805. type Thostent = struct {
  7806. Fh_name uintptr
  7807. Fh_aliases uintptr
  7808. Fh_addrtype int32
  7809. Fh_length int32
  7810. Fh_addr_list uintptr
  7811. }
  7812. type Tservent = struct {
  7813. Fs_name uintptr
  7814. Fs_aliases uintptr
  7815. Fs_port int32
  7816. Fs_proto uintptr
  7817. }
  7818. type Tprotoent = struct {
  7819. Fp_name uintptr
  7820. Fp_aliases uintptr
  7821. Fp_proto int32
  7822. }
  7823. func Xxcb_popcount(tls *libc.TLS, mask Tuint32_t) (r int32) {
  7824. var y Tuint32_t
  7825. _ = y
  7826. y = mask >> libc.Int32FromInt32(1) & uint32(033333333333)
  7827. y = mask - y - y>>libc.Int32FromInt32(1)&uint32(033333333333)
  7828. return libc.Int32FromUint32((y + y>>libc.Int32FromInt32(3)) & uint32(030707070707) % uint32(077))
  7829. }
  7830. func Xxcb_sumof(tls *libc.TLS, list uintptr, len1 int32) (r int32) {
  7831. var i, s int32
  7832. _, _ = i, s
  7833. s = 0
  7834. i = 0
  7835. for {
  7836. if !(i < len1) {
  7837. break
  7838. }
  7839. s += libc.Int32FromUint8(*(*Tuint8_t)(unsafe.Pointer(list)))
  7840. list++
  7841. goto _1
  7842. _1:
  7843. ;
  7844. i++
  7845. }
  7846. return s
  7847. }
  7848. func __xcb_parse_display(tls *libc.TLS, name uintptr, host uintptr, protocol uintptr, displayp uintptr, screenp uintptr) (r int32) {
  7849. bp := tls.Alloc(16)
  7850. defer tls.Free(16)
  7851. var colon, slash uintptr
  7852. var display, len1, screen int32
  7853. var _ /* dot at bp+0 */ uintptr
  7854. var _ /* end at bp+8 */ uintptr
  7855. _, _, _, _, _ = colon, display, len1, screen, slash
  7856. if !(name != 0) || !(*(*int8)(unsafe.Pointer(name)) != 0) {
  7857. name = libc.Xgetenv(tls, __ccgo_ts+4)
  7858. }
  7859. if !(name != 0) {
  7860. return 0
  7861. }
  7862. slash = libc.Xstrrchr(tls, name, int32('/'))
  7863. if slash != 0 {
  7864. len1 = int32(int64(slash) - int64(name))
  7865. if protocol != 0 {
  7866. *(*uintptr)(unsafe.Pointer(protocol)) = libc.Xmalloc(tls, libc.Uint64FromInt32(len1+int32(1)))
  7867. if !(*(*uintptr)(unsafe.Pointer(protocol)) != 0) {
  7868. return 0
  7869. }
  7870. libc.Xmemcpy(tls, *(*uintptr)(unsafe.Pointer(protocol)), name, libc.Uint64FromInt32(len1))
  7871. *(*int8)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(protocol)) + uintptr(len1))) = int8('\000')
  7872. }
  7873. name = slash + uintptr(1)
  7874. } else {
  7875. if protocol != 0 {
  7876. *(*uintptr)(unsafe.Pointer(protocol)) = libc.UintptrFromInt32(0)
  7877. }
  7878. }
  7879. colon = libc.Xstrrchr(tls, name, int32(':'))
  7880. if !(colon != 0) {
  7881. goto error_out
  7882. }
  7883. len1 = int32(int64(colon) - int64(name))
  7884. colon++
  7885. display = libc.Int32FromUint64(libc.Xstrtoul(tls, colon, bp, int32(10)))
  7886. if *(*uintptr)(unsafe.Pointer(bp)) == colon {
  7887. goto error_out
  7888. }
  7889. if int32(*(*int8)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(bp))))) == int32('\000') {
  7890. screen = 0
  7891. } else {
  7892. if int32(*(*int8)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(bp))))) != int32('.') {
  7893. goto error_out
  7894. }
  7895. *(*uintptr)(unsafe.Pointer(bp))++
  7896. screen = libc.Int32FromUint64(libc.Xstrtoul(tls, *(*uintptr)(unsafe.Pointer(bp)), bp+8, int32(10)))
  7897. if *(*uintptr)(unsafe.Pointer(bp + 8)) == *(*uintptr)(unsafe.Pointer(bp)) || int32(*(*int8)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(bp + 8))))) != int32('\000') {
  7898. goto error_out
  7899. }
  7900. }
  7901. /* At this point, the display string is fully parsed and valid, but
  7902. * the caller's memory is untouched. */
  7903. *(*uintptr)(unsafe.Pointer(host)) = libc.Xmalloc(tls, libc.Uint64FromInt32(len1+int32(1)))
  7904. if !(*(*uintptr)(unsafe.Pointer(host)) != 0) {
  7905. goto error_out
  7906. }
  7907. libc.Xmemcpy(tls, *(*uintptr)(unsafe.Pointer(host)), name, libc.Uint64FromInt32(len1))
  7908. *(*int8)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(host)) + uintptr(len1))) = int8('\000')
  7909. *(*int32)(unsafe.Pointer(displayp)) = display
  7910. if screenp != 0 {
  7911. *(*int32)(unsafe.Pointer(screenp)) = screen
  7912. }
  7913. return int32(1)
  7914. goto error_out
  7915. error_out:
  7916. ;
  7917. if protocol != 0 {
  7918. libc.Xfree(tls, *(*uintptr)(unsafe.Pointer(protocol)))
  7919. *(*uintptr)(unsafe.Pointer(protocol)) = libc.UintptrFromInt32(0)
  7920. }
  7921. return 0
  7922. }
  7923. func Xxcb_parse_display(tls *libc.TLS, name uintptr, host uintptr, displayp uintptr, screenp uintptr) (r int32) {
  7924. return __xcb_parse_display(tls, name, host, libc.UintptrFromInt32(0), displayp, screenp)
  7925. }
  7926. func __xcb_open(tls *libc.TLS, host uintptr, protocol uintptr, display int32) (r int32) {
  7927. bp := tls.Alloc(32)
  7928. defer tls.Free(32)
  7929. var actual_filelen, fd int32
  7930. var base, file uintptr
  7931. var filelen Tsize_t
  7932. var port, port1 uint16
  7933. var v1 uint64
  7934. _, _, _, _, _, _, _, _ = actual_filelen, base, fd, file, filelen, port, port1, v1
  7935. base = uintptr(unsafe.Pointer(&_unix_base))
  7936. file = libc.UintptrFromInt32(0)
  7937. /* If protocol or host is "unix", fall through to Unix socket code below */
  7938. if (!(protocol != 0) || libc.Xstrcmp(tls, __ccgo_ts+12, protocol) != 0) && int32(*(*int8)(unsafe.Pointer(host))) != int32('\000') && libc.Xstrcmp(tls, __ccgo_ts+12, host) != 0 {
  7939. /* display specifies TCP */
  7940. port = libc.Uint16FromInt32(int32(m_X_TCP_PORT) + display)
  7941. return __xcb_open_tcp(tls, host, protocol, port)
  7942. }
  7943. filelen = libc.Xstrlen(tls, base) + uint64(1) + libc.Uint64FromInt64(4)*libc.Uint64FromInt32(3) + uint64(1)
  7944. file = libc.Xmalloc(tls, filelen)
  7945. if file == libc.UintptrFromInt32(0) {
  7946. return -int32(1)
  7947. }
  7948. /* display specifies Unix socket */
  7949. actual_filelen = libc.X__builtin_snprintf(tls, file, filelen, __ccgo_ts+17, libc.VaList(bp+8, base, display))
  7950. if actual_filelen < 0 {
  7951. libc.Xfree(tls, file)
  7952. return -int32(1)
  7953. }
  7954. /* snprintf may truncate the file */
  7955. if libc.Uint64FromInt32(actual_filelen) < filelen-uint64(1) {
  7956. v1 = libc.Uint64FromInt32(actual_filelen)
  7957. } else {
  7958. v1 = filelen - uint64(1)
  7959. }
  7960. filelen = v1
  7961. fd = __xcb_open_abstract(tls, protocol, file, filelen)
  7962. if fd >= 0 || *(*int32)(unsafe.Pointer(libc.X__errno_location(tls))) != int32(m_ENOENT) && *(*int32)(unsafe.Pointer(libc.X__errno_location(tls))) != int32(m_ECONNREFUSED) {
  7963. libc.Xfree(tls, file)
  7964. return fd
  7965. }
  7966. fd = __xcb_open_unix(tls, protocol, file)
  7967. libc.Xfree(tls, file)
  7968. if fd < 0 && !(protocol != 0) && int32(*(*int8)(unsafe.Pointer(host))) == int32('\000') {
  7969. port1 = libc.Uint16FromInt32(int32(m_X_TCP_PORT) + display)
  7970. fd = __xcb_open_tcp(tls, host, protocol, port1)
  7971. }
  7972. return fd
  7973. return -int32(1) /* if control reaches here then something has gone wrong */
  7974. }
  7975. var _unix_base = [17]int8{'/', 't', 'm', 'p', '/', '.', 'X', '1', '1', '-', 'u', 'n', 'i', 'x', '/', 'X'}
  7976. func __xcb_socket(tls *libc.TLS, family int32, type1 int32, proto int32) (r int32) {
  7977. bp := tls.Alloc(16)
  7978. defer tls.Free(16)
  7979. var fd int32
  7980. _ = fd
  7981. fd = libc.Xsocket(tls, family, type1|int32(m_SOCK_CLOEXEC1), proto)
  7982. if fd == -int32(1) && *(*int32)(unsafe.Pointer(libc.X__errno_location(tls))) == int32(m_EINVAL) {
  7983. fd = libc.Xsocket(tls, family, type1, proto)
  7984. if fd >= 0 {
  7985. libc.Xfcntl(tls, fd, int32(m_F_SETFD), libc.VaList(bp+8, int32(m_FD_CLOEXEC)))
  7986. }
  7987. }
  7988. return fd
  7989. }
  7990. func __xcb_do_connect(tls *libc.TLS, fd int32, addr uintptr, addrlen int32) (r int32) {
  7991. bp := tls.Alloc(16)
  7992. defer tls.Free(16)
  7993. var _ /* on at bp+0 */ int32
  7994. *(*int32)(unsafe.Pointer(bp)) = int32(1)
  7995. if fd < 0 {
  7996. return -int32(1)
  7997. }
  7998. libc.Xsetsockopt(tls, fd, int32(m_IPPROTO_TCP), int32(m_TCP_NODELAY), bp, uint32(4))
  7999. libc.Xsetsockopt(tls, fd, int32(m_SOL_SOCKET), int32(m_SO_KEEPALIVE), bp, uint32(4))
  8000. return libc.Xconnect(tls, fd, addr, libc.Uint32FromInt32(addrlen))
  8001. }
  8002. func __xcb_open_tcp(tls *libc.TLS, host uintptr, protocol uintptr, port uint16) (r int32) {
  8003. bp := tls.Alloc(80)
  8004. defer tls.Free(80)
  8005. var addr, bracket, v1 uintptr
  8006. var fd int32
  8007. var v2 bool
  8008. var _ /* hints at bp+0 */ Taddrinfo
  8009. var _ /* results at bp+56 */ uintptr
  8010. var _ /* service at bp+48 */ [6]int8
  8011. _, _, _, _, _ = addr, bracket, fd, v1, v2
  8012. fd = -int32(1)
  8013. if protocol != 0 && libc.Xstrcmp(tls, __ccgo_ts+22, protocol) != 0 && libc.Xstrcmp(tls, __ccgo_ts+26, protocol) != 0 && libc.Xstrcmp(tls, __ccgo_ts+31, protocol) != 0 {
  8014. return -int32(1)
  8015. }
  8016. if int32(*(*int8)(unsafe.Pointer(host))) == int32('\000') {
  8017. host = __ccgo_ts + 37
  8018. }
  8019. libc.Xmemset(tls, bp, 0, uint64(48))
  8020. (*(*Taddrinfo)(unsafe.Pointer(bp))).Fai_flags |= int32(m_AI_NUMERICSERV)
  8021. (*(*Taddrinfo)(unsafe.Pointer(bp))).Fai_family = m_PF_UNSPEC
  8022. (*(*Taddrinfo)(unsafe.Pointer(bp))).Fai_socktype = int32(m_SOCK_STREAM)
  8023. /* Allow IPv6 addresses enclosed in brackets. */
  8024. if v2 = int32(*(*int8)(unsafe.Pointer(host))) == int32('['); v2 {
  8025. v1 = libc.Xstrrchr(tls, host, int32(']'))
  8026. bracket = v1
  8027. }
  8028. if v2 && v1 != 0 && int32(*(*int8)(unsafe.Pointer(bracket + 1))) == int32('\000') {
  8029. *(*int8)(unsafe.Pointer(bracket)) = int8('\000')
  8030. host++
  8031. (*(*Taddrinfo)(unsafe.Pointer(bp))).Fai_flags |= int32(m_AI_NUMERICHOST)
  8032. (*(*Taddrinfo)(unsafe.Pointer(bp))).Fai_family = int32(m_PF_INET6)
  8033. }
  8034. libc.X__builtin_snprintf(tls, bp+48, uint64(6), __ccgo_ts+47, libc.VaList(bp+72, libc.Int32FromUint16(port)))
  8035. if libc.Xgetaddrinfo(tls, host, bp+48, bp, bp+56) != 0 {
  8036. /* FIXME: use gai_strerror, and fill in error connection */
  8037. return -int32(1)
  8038. }
  8039. addr = *(*uintptr)(unsafe.Pointer(bp + 56))
  8040. for {
  8041. if !(addr != 0) {
  8042. break
  8043. }
  8044. fd = __xcb_socket(tls, (*Taddrinfo)(unsafe.Pointer(addr)).Fai_family, (*Taddrinfo)(unsafe.Pointer(addr)).Fai_socktype, (*Taddrinfo)(unsafe.Pointer(addr)).Fai_protocol)
  8045. if __xcb_do_connect(tls, fd, (*Taddrinfo)(unsafe.Pointer(addr)).Fai_addr, libc.Int32FromUint32((*Taddrinfo)(unsafe.Pointer(addr)).Fai_addrlen)) >= 0 {
  8046. break
  8047. }
  8048. libc.Xclose(tls, fd)
  8049. fd = -int32(1)
  8050. goto _3
  8051. _3:
  8052. ;
  8053. addr = (*Taddrinfo)(unsafe.Pointer(addr)).Fai_next
  8054. }
  8055. libc.Xfreeaddrinfo(tls, *(*uintptr)(unsafe.Pointer(bp + 56)))
  8056. return fd
  8057. }
  8058. func __xcb_open_unix(tls *libc.TLS, protocol uintptr, file uintptr) (r int32) {
  8059. bp := tls.Alloc(128)
  8060. defer tls.Free(128)
  8061. var fd int32
  8062. var _ /* addr at bp+0 */ Tsockaddr_un
  8063. var _ /* len at bp+112 */ Tsocklen_t
  8064. var _ /* val at bp+116 */ int32
  8065. _ = fd
  8066. *(*Tsocklen_t)(unsafe.Pointer(bp + 112)) = uint32(4)
  8067. if protocol != 0 && libc.Xstrcmp(tls, __ccgo_ts+12, protocol) != 0 {
  8068. return -int32(1)
  8069. }
  8070. libc.Xstrcpy(tls, bp+2, file)
  8071. (*(*Tsockaddr_un)(unsafe.Pointer(bp))).Fsun_family = uint16(m_PF_LOCAL)
  8072. fd = __xcb_socket(tls, int32(m_PF_LOCAL), int32(m_SOCK_STREAM), 0)
  8073. if fd == -int32(1) {
  8074. return -int32(1)
  8075. }
  8076. if libc.Xgetsockopt(tls, fd, int32(m_SOL_SOCKET), int32(m_SO_SNDBUF), bp+116, bp+112) == 0 && *(*int32)(unsafe.Pointer(bp + 116)) < libc.Int32FromInt32(64)*libc.Int32FromInt32(1024) {
  8077. *(*int32)(unsafe.Pointer(bp + 116)) = libc.Int32FromInt32(64) * libc.Int32FromInt32(1024)
  8078. libc.Xsetsockopt(tls, fd, int32(m_SOL_SOCKET), int32(m_SO_SNDBUF), bp+116, uint32(4))
  8079. }
  8080. if libc.Xconnect(tls, fd, bp, uint32(110)) == -int32(1) {
  8081. libc.Xclose(tls, fd)
  8082. return -int32(1)
  8083. }
  8084. return fd
  8085. }
  8086. func __xcb_open_abstract(tls *libc.TLS, protocol uintptr, file uintptr, filelen Tsize_t) (r int32) {
  8087. bp := tls.Alloc(112)
  8088. defer tls.Free(112)
  8089. var fd int32
  8090. var namelen Tsocklen_t
  8091. var _ /* addr at bp+0 */ Tsockaddr_un
  8092. _, _ = fd, namelen
  8093. *(*Tsockaddr_un)(unsafe.Pointer(bp)) = Tsockaddr_un{}
  8094. if protocol != 0 && libc.Xstrcmp(tls, __ccgo_ts+12, protocol) != 0 {
  8095. return -int32(1)
  8096. }
  8097. libc.Xstrcpy(tls, bp+2+uintptr(1), file)
  8098. (*(*Tsockaddr_un)(unsafe.Pointer(bp))).Fsun_family = uint16(m_PF_LOCAL)
  8099. namelen = uint32(uint64(libc.UintptrFromInt32(0)+2) + libc.Uint64FromInt32(1) + filelen)
  8100. fd = __xcb_socket(tls, int32(m_PF_LOCAL), int32(m_SOCK_STREAM), 0)
  8101. if fd == -int32(1) {
  8102. return -int32(1)
  8103. }
  8104. if libc.Xconnect(tls, fd, bp, namelen) == -int32(1) {
  8105. libc.Xclose(tls, fd)
  8106. return -int32(1)
  8107. }
  8108. return fd
  8109. }
  8110. func Xxcb_connect(tls *libc.TLS, displayname uintptr, screenp uintptr) (r uintptr) {
  8111. return Xxcb_connect_to_display_with_auth_info(tls, displayname, libc.UintptrFromInt32(0), screenp)
  8112. }
  8113. func Xxcb_connect_to_display_with_auth_info(tls *libc.TLS, displayname uintptr, auth uintptr, screenp uintptr) (r uintptr) {
  8114. bp := tls.Alloc(64)
  8115. defer tls.Free(64)
  8116. var c uintptr
  8117. var fd, parsed int32
  8118. var _ /* display at bp+0 */ int32
  8119. var _ /* host at bp+8 */ uintptr
  8120. var _ /* ourauth at bp+24 */ Txcb_auth_info_t
  8121. var _ /* protocol at bp+16 */ uintptr
  8122. _, _, _ = c, fd, parsed
  8123. *(*int32)(unsafe.Pointer(bp)) = 0
  8124. *(*uintptr)(unsafe.Pointer(bp + 8)) = libc.UintptrFromInt32(0)
  8125. *(*uintptr)(unsafe.Pointer(bp + 16)) = libc.UintptrFromInt32(0)
  8126. parsed = __xcb_parse_display(tls, displayname, bp+8, bp+16, bp, screenp)
  8127. if !(parsed != 0) {
  8128. c = X_xcb_conn_ret_error(tls, int32(m_XCB_CONN_CLOSED_PARSE_ERR))
  8129. goto out
  8130. }
  8131. fd = __xcb_open(tls, *(*uintptr)(unsafe.Pointer(bp + 8)), *(*uintptr)(unsafe.Pointer(bp + 16)), *(*int32)(unsafe.Pointer(bp)))
  8132. if fd == -int32(1) {
  8133. c = X_xcb_conn_ret_error(tls, int32(m_XCB_CONN_ERROR))
  8134. goto out
  8135. }
  8136. if auth != 0 {
  8137. c = Xxcb_connect_to_fd(tls, fd, auth)
  8138. goto out
  8139. }
  8140. if X_xcb_get_auth_info(tls, fd, bp+24, *(*int32)(unsafe.Pointer(bp))) != 0 {
  8141. c = Xxcb_connect_to_fd(tls, fd, bp+24)
  8142. libc.Xfree(tls, (*(*Txcb_auth_info_t)(unsafe.Pointer(bp + 24))).Fname)
  8143. libc.Xfree(tls, (*(*Txcb_auth_info_t)(unsafe.Pointer(bp + 24))).Fdata)
  8144. } else {
  8145. c = Xxcb_connect_to_fd(tls, fd, uintptr(0))
  8146. }
  8147. if (*Txcb_connection_t)(unsafe.Pointer(c)).Fhas_error != 0 {
  8148. goto out
  8149. }
  8150. /* Make sure requested screen number is in bounds for this server */
  8151. if screenp != libc.UintptrFromInt32(0) && *(*int32)(unsafe.Pointer(screenp)) >= libc.Int32FromUint8((*Txcb_setup_t)(unsafe.Pointer((*Txcb_connection_t)(unsafe.Pointer(c)).Fsetup)).Froots_len) {
  8152. Xxcb_disconnect(tls, c)
  8153. c = X_xcb_conn_ret_error(tls, int32(m_XCB_CONN_CLOSED_INVALID_SCREEN))
  8154. goto out
  8155. }
  8156. goto out
  8157. out:
  8158. ;
  8159. libc.Xfree(tls, *(*uintptr)(unsafe.Pointer(bp + 8)))
  8160. libc.Xfree(tls, *(*uintptr)(unsafe.Pointer(bp + 16)))
  8161. return c
  8162. }
  8163. const m_AUTH_PROTO_MIT_MAGIC_COOKIE = "MIT-MAGIC-COOKIE-1"
  8164. const m_AUTH_PROTO_XDM_AUTHORIZATION = "XDM-AUTHORIZATION-1"
  8165. const m_CANBSIZ = 255
  8166. const m_DEV_BSIZE = 512
  8167. const m_FALSE = 0
  8168. const m_FUNCPROTO = 15
  8169. const m_FamilyKrb5Principal = 253
  8170. const m_FamilyLocal = 256
  8171. const m_FamilyLocalHost = 252
  8172. const m_FamilyNetname = 254
  8173. const m_FamilyWild = 65535
  8174. const m_INITIAL_SOCKNAME_SLACK = 108
  8175. const m_ITIMER_PROF = 2
  8176. const m_ITIMER_REAL = 0
  8177. const m_ITIMER_VIRTUAL = 1
  8178. const m_LOCK_ERROR = 1
  8179. const m_LOCK_SUCCESS = 0
  8180. const m_LOCK_TIMEOUT = 2
  8181. const m_MAXHOSTNAMELEN = 64
  8182. const m_MAXNAMLEN = 255
  8183. const m_MAXPATHLEN = 4096
  8184. const m_MAXSYMLINKS = 20
  8185. const m_NBBY = 8
  8186. const m_NCARGS = 131072
  8187. const m_NGROUPS = 32
  8188. const m_NOFILE = 256
  8189. const m_NeedFunctionPrototypes = 1
  8190. const m_NeedNestedPrototypes = 1
  8191. const m_NeedVarargsPrototypes = 1
  8192. const m_NeedWidePrototypes = 0
  8193. const m_PRIO_MAX = 20
  8194. const m_PRIO_PGRP = 1
  8195. const m_PRIO_PROCESS = 0
  8196. const m_PRIO_USER = 2
  8197. const m_RLIMIT_AS = 9
  8198. const m_RLIMIT_CORE = 4
  8199. const m_RLIMIT_CPU = 0
  8200. const m_RLIMIT_DATA = 2
  8201. const m_RLIMIT_FSIZE = 1
  8202. const m_RLIMIT_LOCKS = 10
  8203. const m_RLIMIT_MEMLOCK = 8
  8204. const m_RLIMIT_MSGQUEUE = 12
  8205. const m_RLIMIT_NICE = 13
  8206. const m_RLIMIT_NLIMITS = 16
  8207. const m_RLIMIT_NOFILE = 7
  8208. const m_RLIMIT_NPROC = 6
  8209. const m_RLIMIT_RSS = 5
  8210. const m_RLIMIT_RTPRIO = 14
  8211. const m_RLIMIT_RTTIME = 15
  8212. const m_RLIMIT_SIGPENDING = 11
  8213. const m_RLIMIT_STACK = 3
  8214. const m_RLIM_NLIMITS = "RLIMIT_NLIMITS"
  8215. const m_RLIM_SAVED_CUR = "RLIM_INFINITY"
  8216. const m_RLIM_SAVED_MAX = "RLIM_INFINITY"
  8217. const m_RUSAGE_SELF = 0
  8218. const m_RUSAGE_THREAD = 1
  8219. const m_SOCK_CLOEXEC2 = 02000000
  8220. const m_TRUE = 1
  8221. const m_XDM_DEFAULT_MCAST_ADDR6 = "ff02:0:0:0:0:0:0:12b"
  8222. const m_XDM_KA_RTX_LIMIT = 4
  8223. const m_XDM_MAX_MSGLEN = 8192
  8224. const m_XDM_MAX_RTX = 32
  8225. const m_XDM_MIN_RTX = 2
  8226. const m_XDM_PROTOCOL_VERSION = 1
  8227. const m_XDM_RTX_LIMIT = 7
  8228. const m_XDM_UDP_PORT = 177
  8229. const m_XMD_H = 1
  8230. const m__X_INLINE = "inline"
  8231. const m__X_RESTRICT_KYWD = "restrict"
  8232. const m__Xconst = "const"
  8233. const m_prlimit64 = "prlimit"
  8234. type TXauth = struct {
  8235. Ffamily uint16
  8236. Faddress_length uint16
  8237. Faddress uintptr
  8238. Fnumber_length uint16
  8239. Fnumber uintptr
  8240. Fname_length uint16
  8241. Fname uintptr
  8242. Fdata_length uint16
  8243. Fdata uintptr
  8244. }
  8245. type Txauth = TXauth
  8246. type Titimerval = struct {
  8247. Fit_interval Ttimeval
  8248. Fit_value Ttimeval
  8249. }
  8250. type Ttimezone = struct {
  8251. Ftz_minuteswest int32
  8252. Ftz_dsttime int32
  8253. }
  8254. type Trlim_t = uint64
  8255. type Trlimit = struct {
  8256. Frlim_cur Trlim_t
  8257. Frlim_max Trlim_t
  8258. }
  8259. type Trusage = struct {
  8260. Fru_utime Ttimeval
  8261. Fru_stime Ttimeval
  8262. Fru_maxrss int64
  8263. Fru_ixrss int64
  8264. Fru_idrss int64
  8265. Fru_isrss int64
  8266. Fru_minflt int64
  8267. Fru_majflt int64
  8268. Fru_nswap int64
  8269. Fru_inblock int64
  8270. Fru_oublock int64
  8271. Fru_msgsnd int64
  8272. Fru_msgrcv int64
  8273. Fru_nsignals int64
  8274. Fru_nvcsw int64
  8275. Fru_nivcsw int64
  8276. F__reserved [16]int64
  8277. }
  8278. type TINT64 = int64
  8279. type TINT32 = int32
  8280. type TINT16 = int16
  8281. type TINT8 = int8
  8282. type TCARD64 = uint64
  8283. type TCARD32 = uint32
  8284. type TCARD16 = uint16
  8285. type TCARD8 = uint8
  8286. type TBITS32 = uint32
  8287. type TBITS16 = uint16
  8288. type TBYTE = uint8
  8289. type TBOOL = uint8
  8290. type TxdmOpCode = int32
  8291. const _BROADCAST_QUERY = 1
  8292. const _QUERY = 2
  8293. const _INDIRECT_QUERY = 3
  8294. const _FORWARD_QUERY = 4
  8295. const _WILLING = 5
  8296. const _UNWILLING = 6
  8297. const _REQUEST = 7
  8298. const _ACCEPT = 8
  8299. const _DECLINE = 9
  8300. const _MANAGE = 10
  8301. const _REFUSE = 11
  8302. const _FAILED = 12
  8303. const _KEEPALIVE = 13
  8304. const _ALIVE = 14
  8305. type Txdmcp_states = int32
  8306. const _XDM_QUERY = 0
  8307. const _XDM_BROADCAST = 1
  8308. const _XDM_INDIRECT = 2
  8309. const _XDM_COLLECT_QUERY = 3
  8310. const _XDM_COLLECT_BROADCAST_QUERY = 4
  8311. const _XDM_COLLECT_INDIRECT_QUERY = 5
  8312. const _XDM_START_CONNECTION = 6
  8313. const _XDM_AWAIT_REQUEST_RESPONSE = 7
  8314. const _XDM_AWAIT_MANAGE_RESPONSE = 8
  8315. const _XDM_MANAGE = 9
  8316. const _XDM_RUN_SESSION = 10
  8317. const _XDM_OFF = 11
  8318. const _XDM_AWAIT_USER_INPUT = 12
  8319. const _XDM_KEEPALIVE = 13
  8320. const _XDM_AWAIT_ALIVE_RESPONSE = 14
  8321. const _XDM_KEEP_ME_LAST = 15
  8322. type TCARD8Ptr = uintptr
  8323. type TCARD16Ptr = uintptr
  8324. type TCARD32Ptr = uintptr
  8325. type TARRAY8 = struct {
  8326. Flength TCARD16
  8327. Fdata TCARD8Ptr
  8328. }
  8329. type T_ARRAY8 = TARRAY8
  8330. type TARRAY8Ptr = uintptr
  8331. type TARRAY16 = struct {
  8332. Flength TCARD8
  8333. Fdata TCARD16Ptr
  8334. }
  8335. type T_ARRAY16 = TARRAY16
  8336. type TARRAY16Ptr = uintptr
  8337. type TARRAY32 = struct {
  8338. Flength TCARD8
  8339. Fdata TCARD32Ptr
  8340. }
  8341. type T_ARRAY32 = TARRAY32
  8342. type TARRAY32Ptr = uintptr
  8343. type TARRAYofARRAY8 = struct {
  8344. Flength TCARD8
  8345. Fdata TARRAY8Ptr
  8346. }
  8347. type T_ARRAYofARRAY8 = TARRAYofARRAY8
  8348. type TARRAYofARRAY8Ptr = uintptr
  8349. type TXdmcpHeader = struct {
  8350. Fversion TCARD16
  8351. Fopcode TCARD16
  8352. Flength TCARD16
  8353. }
  8354. type T_XdmcpHeader = TXdmcpHeader
  8355. type TXdmcpHeaderPtr = uintptr
  8356. type TXdmcpBuffer = struct {
  8357. Fdata uintptr
  8358. Fsize int32
  8359. Fpointer int32
  8360. Fcount int32
  8361. }
  8362. type T_XdmcpBuffer = TXdmcpBuffer
  8363. type TXdmcpBufferPtr = uintptr
  8364. type TXdmAuthKeyRec = struct {
  8365. Fdata [8]TBYTE
  8366. }
  8367. type T_XdmAuthKey = TXdmAuthKeyRec
  8368. type TXdmAuthKeyPtr = uintptr
  8369. type TXdmcpNetaddr = uintptr
  8370. type _auth_protos = int32
  8371. const _AUTH_XA1 = 0
  8372. const _AUTH_MC1 = 1
  8373. const _N_AUTH_PROTOS = 2
  8374. var _authnames = [2]uintptr{
  8375. 0: __ccgo_ts + 51,
  8376. 1: __ccgo_ts + 71,
  8377. }
  8378. var _authnameslen = [2]int32{
  8379. 0: libc.Int32FromUint64(libc.Uint64FromInt64(20) - libc.Uint64FromInt32(1)),
  8380. 1: libc.Int32FromUint64(libc.Uint64FromInt64(19) - libc.Uint64FromInt32(1)),
  8381. }
  8382. func _memdup(tls *libc.TLS, dst uintptr, src uintptr, len1 Tsize_t) (r Tsize_t) {
  8383. if len1 != 0 {
  8384. *(*uintptr)(unsafe.Pointer(dst)) = libc.Xmalloc(tls, len1)
  8385. } else {
  8386. *(*uintptr)(unsafe.Pointer(dst)) = uintptr(0)
  8387. }
  8388. if !(*(*uintptr)(unsafe.Pointer(dst)) != 0) {
  8389. return uint64(0)
  8390. }
  8391. libc.Xmemcpy(tls, *(*uintptr)(unsafe.Pointer(dst)), src, len1)
  8392. return len1
  8393. }
  8394. func _authname_match(tls *libc.TLS, kind _auth_protos, name uintptr, namelen Tsize_t) (r int32) {
  8395. if libc.Uint64FromInt32(_authnameslen[kind]) != namelen {
  8396. return 0
  8397. }
  8398. if libc.Xmemcmp(tls, _authnames[kind], name, namelen) != 0 {
  8399. return 0
  8400. }
  8401. return int32(1)
  8402. }
  8403. func _get_authptr(tls *libc.TLS, sockname uintptr, display int32) (r uintptr) {
  8404. bp := tls.Alloc(320)
  8405. defer tls.Free(320)
  8406. var addr uintptr
  8407. var addrlen, dispbuflen int32
  8408. var family uint16
  8409. var v1 uint64
  8410. var _ /* dispbuf at bp+256 */ [40]int8
  8411. var _ /* hostnamebuf at bp+0 */ [256]int8
  8412. _, _, _, _, _ = addr, addrlen, dispbuflen, family, v1
  8413. addr = uintptr(0)
  8414. addrlen = 0
  8415. family = libc.Uint16FromInt32(libc.Int32FromInt32(m_FamilyLocal)) /* 256 */
  8416. switch libc.Int32FromUint16((*Tsockaddr)(unsafe.Pointer(sockname)).Fsa_family) {
  8417. case int32(m_PF_INET6):
  8418. addr = sockname + 8
  8419. addrlen = int32(16)
  8420. if !(*(*Tuint32_t)(unsafe.Pointer(sockname + 8)) == uint32(0) && *(*Tuint32_t)(unsafe.Pointer(sockname + 8 + 1*4)) == uint32(0) && libc.Int32FromUint8(*(*Tuint8_t)(unsafe.Pointer(sockname + 8 + 8))) == 0 && libc.Int32FromUint8(*(*Tuint8_t)(unsafe.Pointer(sockname + 8 + 9))) == 0 && libc.Int32FromUint8(*(*Tuint8_t)(unsafe.Pointer(sockname + 8 + 10))) == int32(0xff) && libc.Int32FromUint8(*(*Tuint8_t)(unsafe.Pointer(sockname + 8 + 11))) == int32(0xff)) {
  8421. if !(*(*Tuint32_t)(unsafe.Pointer(sockname + 8)) == uint32(0) && *(*Tuint32_t)(unsafe.Pointer(sockname + 8 + 1*4)) == uint32(0) && *(*Tuint32_t)(unsafe.Pointer(sockname + 8 + 2*4)) == uint32(0) && libc.Int32FromUint8(*(*Tuint8_t)(unsafe.Pointer(sockname + 8 + 12))) == 0 && libc.Int32FromUint8(*(*Tuint8_t)(unsafe.Pointer(sockname + 8 + 13))) == 0 && libc.Int32FromUint8(*(*Tuint8_t)(unsafe.Pointer(sockname + 8 + 14))) == 0 && libc.Int32FromUint8(*(*Tuint8_t)(unsafe.Pointer(sockname + 8 + 15))) == int32(1)) {
  8422. family = uint16(_XCB_FAMILY_INTERNET_6)
  8423. }
  8424. break
  8425. }
  8426. addr += uintptr(12)
  8427. /* if v4-mapped, fall through. */
  8428. fallthrough
  8429. case int32(m_PF_INET):
  8430. if !(addr != 0) {
  8431. addr = sockname + 4
  8432. }
  8433. addrlen = int32(4)
  8434. if *(*Tin_addr_t)(unsafe.Pointer(addr)) != libc.Xhtonl(tls, libc.Uint32FromInt32(0x7f000001)) {
  8435. family = uint16(_XCB_FAMILY_INTERNET)
  8436. }
  8437. case int32(m_PF_LOCAL):
  8438. default:
  8439. return uintptr(0) /* cannot authenticate this family */
  8440. }
  8441. dispbuflen = libc.X__builtin_snprintf(tls, bp+256, uint64(40), __ccgo_ts+90, libc.VaList(bp+304, display))
  8442. if dispbuflen < 0 {
  8443. return uintptr(0)
  8444. }
  8445. /* snprintf may have truncate our text */
  8446. if libc.Uint64FromInt32(dispbuflen) < libc.Uint64FromInt64(40)-libc.Uint64FromInt32(1) {
  8447. v1 = libc.Uint64FromInt32(dispbuflen)
  8448. } else {
  8449. v1 = libc.Uint64FromInt64(40) - libc.Uint64FromInt32(1)
  8450. }
  8451. dispbuflen = libc.Int32FromUint64(v1)
  8452. if libc.Int32FromUint16(family) == int32(m_FamilyLocal) {
  8453. if libc.Xgethostname(tls, bp, uint64(256)) == -int32(1) {
  8454. return uintptr(0)
  8455. } /* do not know own hostname */
  8456. addr = bp
  8457. addrlen = libc.Int32FromUint64(libc.Xstrlen(tls, addr))
  8458. }
  8459. return libxau.XXauGetBestAuthByAddr(tls, family, libc.Uint16FromInt32(addrlen), addr, libc.Uint16FromInt32(dispbuflen), bp+256, int32(_N_AUTH_PROTOS), uintptr(unsafe.Pointer(&_authnames)), uintptr(unsafe.Pointer(&_authnameslen)))
  8460. }
  8461. func _next_nonce(tls *libc.TLS) (r int32) {
  8462. var ret, v1 int32
  8463. _, _ = ret, v1
  8464. libc.Xpthread_mutex_lock(tls, uintptr(unsafe.Pointer(&_nonce_mutex)))
  8465. v1 = _nonce
  8466. _nonce++
  8467. ret = v1
  8468. libc.Xpthread_mutex_unlock(tls, uintptr(unsafe.Pointer(&_nonce_mutex)))
  8469. return ret
  8470. }
  8471. var _nonce int32
  8472. var _nonce_mutex = Tpthread_mutex_t{}
  8473. func _do_append(tls *libc.TLS, buf uintptr, idxp uintptr, val uintptr, valsize Tsize_t) {
  8474. var p1 uintptr
  8475. _ = p1
  8476. libc.Xmemcpy(tls, buf+uintptr(*(*int32)(unsafe.Pointer(idxp))), val, valsize)
  8477. p1 = idxp
  8478. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + valsize)
  8479. }
  8480. func _compute_auth(tls *libc.TLS, info uintptr, authptr uintptr, sockname uintptr) (r int32) {
  8481. bp := tls.Alloc(32)
  8482. defer tls.Free(32)
  8483. var si, si6 uintptr
  8484. var v2 int32
  8485. var _ /* fakeaddr at bp+12 */ Tuint32_t
  8486. var _ /* fakeaddr at bp+4 */ Tuint32_t
  8487. var _ /* fakeport at bp+16 */ Tuint16_t
  8488. var _ /* fakeport at bp+8 */ Tuint16_t
  8489. var _ /* j at bp+0 */ int32
  8490. var _ /* now at bp+20 */ Tuint32_t
  8491. _, _, _ = si, si6, v2
  8492. if _authname_match(tls, int32(_AUTH_MC1), (*TXauth)(unsafe.Pointer(authptr)).Fname, uint64((*TXauth)(unsafe.Pointer(authptr)).Fname_length)) != 0 {
  8493. (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdatalen = libc.Int32FromUint64(_memdup(tls, info+24, (*TXauth)(unsafe.Pointer(authptr)).Fdata, uint64((*TXauth)(unsafe.Pointer(authptr)).Fdata_length)))
  8494. if !((*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdatalen != 0) {
  8495. return 0
  8496. }
  8497. return int32(1)
  8498. }
  8499. if _authname_match(tls, int32(_AUTH_XA1), (*TXauth)(unsafe.Pointer(authptr)).Fname, uint64((*TXauth)(unsafe.Pointer(authptr)).Fname_length)) != 0 {
  8500. (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdata = libc.Xmalloc(tls, libc.Uint64FromInt32(libc.Int32FromInt32(192)/libc.Int32FromInt32(8)))
  8501. if !((*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdata != 0) {
  8502. return 0
  8503. }
  8504. *(*int32)(unsafe.Pointer(bp)) = 0
  8505. for {
  8506. if !(*(*int32)(unsafe.Pointer(bp)) < int32(8)) {
  8507. break
  8508. }
  8509. *(*int8)(unsafe.Pointer((*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdata + uintptr(*(*int32)(unsafe.Pointer(bp))))) = *(*int8)(unsafe.Pointer((*TXauth)(unsafe.Pointer(authptr)).Fdata + uintptr(*(*int32)(unsafe.Pointer(bp)))))
  8510. goto _1
  8511. _1:
  8512. ;
  8513. *(*int32)(unsafe.Pointer(bp))++
  8514. }
  8515. switch libc.Int32FromUint16((*Tsockaddr)(unsafe.Pointer(sockname)).Fsa_family) {
  8516. case int32(m_PF_INET):
  8517. /*block*/
  8518. si = sockname
  8519. _do_append(tls, (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdata, bp, si+4, uint64(4))
  8520. _do_append(tls, (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdata, bp, si+2, uint64(2))
  8521. case int32(m_PF_INET6):
  8522. /*block*/
  8523. si6 = sockname
  8524. if *(*Tuint32_t)(unsafe.Pointer(sockname + 8)) == uint32(0) && *(*Tuint32_t)(unsafe.Pointer(sockname + 8 + 1*4)) == uint32(0) && libc.Int32FromUint8(*(*Tuint8_t)(unsafe.Pointer(sockname + 8 + 8))) == 0 && libc.Int32FromUint8(*(*Tuint8_t)(unsafe.Pointer(sockname + 8 + 9))) == 0 && libc.Int32FromUint8(*(*Tuint8_t)(unsafe.Pointer(sockname + 8 + 10))) == int32(0xff) && libc.Int32FromUint8(*(*Tuint8_t)(unsafe.Pointer(sockname + 8 + 11))) == int32(0xff) {
  8525. _do_append(tls, (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdata, bp, si6+8+12, uint64(4))
  8526. _do_append(tls, (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdata, bp, si6+2, uint64(2))
  8527. } else {
  8528. /* XDM-AUTHORIZATION-1 does not handle IPv6 correctly. Do the
  8529. same thing Xlib does: use all zeroes for the 4-byte address
  8530. and 2-byte port number. */
  8531. *(*Tuint32_t)(unsafe.Pointer(bp + 4)) = uint32(0)
  8532. *(*Tuint16_t)(unsafe.Pointer(bp + 8)) = uint16(0)
  8533. _do_append(tls, (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdata, bp, bp+4, uint64(4))
  8534. _do_append(tls, (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdata, bp, bp+8, uint64(2))
  8535. }
  8536. case int32(m_PF_LOCAL):
  8537. /*block*/
  8538. *(*Tuint32_t)(unsafe.Pointer(bp + 12)) = libc.Xhtonl(tls, uint32(0xffffffff)-libc.Uint32FromInt32(_next_nonce(tls)))
  8539. *(*Tuint16_t)(unsafe.Pointer(bp + 16)) = libc.Xhtons(tls, libc.Uint16FromInt32(libc.Xgetpid(tls)))
  8540. _do_append(tls, (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdata, bp, bp+12, uint64(4))
  8541. _do_append(tls, (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdata, bp, bp+16, uint64(2))
  8542. default:
  8543. libc.Xfree(tls, (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdata)
  8544. return 0 /* do not know how to build this */
  8545. }
  8546. *(*Tuint32_t)(unsafe.Pointer(bp + 20)) = libc.Xhtonl(tls, libc.Uint32FromInt64(libc.Xtime(tls, uintptr(0))))
  8547. _do_append(tls, (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdata, bp, bp+20, uint64(4))
  8548. for *(*int32)(unsafe.Pointer(bp)) < libc.Int32FromInt32(192)/libc.Int32FromInt32(8) {
  8549. v2 = *(*int32)(unsafe.Pointer(bp))
  8550. *(*int32)(unsafe.Pointer(bp))++
  8551. *(*int8)(unsafe.Pointer((*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdata + uintptr(v2))) = 0
  8552. }
  8553. (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdatalen = *(*int32)(unsafe.Pointer(bp))
  8554. libxdmcp.XXdmcpWrap(tls, (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdata, (*TXauth)(unsafe.Pointer(authptr)).Fdata+uintptr(8), (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdata, (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fdatalen)
  8555. return int32(1)
  8556. }
  8557. return 0 /* Unknown authorization type */
  8558. }
  8559. /* `sockaddr_un.sun_path' typical size usually ranges between 92 and 108 */
  8560. // C documentation
  8561. //
  8562. // /* Return a dynamically allocated socket address structure according
  8563. // to the value returned by either getpeername() or getsockname()
  8564. // (according to POSIX, applications should not assume a particular
  8565. // length for `sockaddr_un.sun_path') */
  8566. func _get_peer_sock_name(tls *libc.TLS, socket_func uintptr, fd int32) (r uintptr) {
  8567. bp := tls.Alloc(16)
  8568. defer tls.Free(16)
  8569. var new_sockname, sockname, v1 uintptr
  8570. var socknamelen Tsocklen_t
  8571. var _ /* actual_socknamelen at bp+0 */ Tsocklen_t
  8572. _, _, _, _ = new_sockname, sockname, socknamelen, v1
  8573. socknamelen = uint32(libc.Uint64FromInt64(16) + libc.Uint64FromInt32(m_INITIAL_SOCKNAME_SLACK))
  8574. *(*Tsocklen_t)(unsafe.Pointer(bp)) = socknamelen
  8575. sockname = libc.Xmalloc(tls, uint64(socknamelen))
  8576. if sockname == libc.UintptrFromInt32(0) {
  8577. return libc.UintptrFromInt32(0)
  8578. }
  8579. /* Both getpeername() and getsockname() truncates sockname if
  8580. there is not enough space and set the required length in
  8581. actual_socknamelen */
  8582. if (*(*func(*libc.TLS, int32, uintptr, uintptr) int32)(unsafe.Pointer(&struct{ uintptr }{socket_func})))(tls, fd, sockname, bp) == -int32(1) {
  8583. goto sock_or_realloc_error
  8584. }
  8585. if *(*Tsocklen_t)(unsafe.Pointer(bp)) > socknamelen {
  8586. new_sockname = libc.UintptrFromInt32(0)
  8587. socknamelen = *(*Tsocklen_t)(unsafe.Pointer(bp))
  8588. v1 = libc.Xrealloc(tls, sockname, uint64(*(*Tsocklen_t)(unsafe.Pointer(bp))))
  8589. new_sockname = v1
  8590. if v1 == libc.UintptrFromInt32(0) {
  8591. goto sock_or_realloc_error
  8592. }
  8593. sockname = new_sockname
  8594. if (*(*func(*libc.TLS, int32, uintptr, uintptr) int32)(unsafe.Pointer(&struct{ uintptr }{socket_func})))(tls, fd, sockname, bp) == -int32(1) || *(*Tsocklen_t)(unsafe.Pointer(bp)) > socknamelen {
  8595. goto sock_or_realloc_error
  8596. }
  8597. }
  8598. return sockname
  8599. goto sock_or_realloc_error
  8600. sock_or_realloc_error:
  8601. ;
  8602. libc.Xfree(tls, sockname)
  8603. return libc.UintptrFromInt32(0)
  8604. }
  8605. func X_xcb_get_auth_info(tls *libc.TLS, fd int32, info uintptr, display int32) (r int32) {
  8606. var authptr, sockname, v1, v2, v3 uintptr
  8607. var gotsockname, ret int32
  8608. _, _, _, _, _, _, _ = authptr, gotsockname, ret, sockname, v1, v2, v3
  8609. /* code adapted from Xlib/ConnDis.c, xtrans/Xtranssocket.c,
  8610. xtrans/Xtransutils.c */
  8611. sockname = libc.UintptrFromInt32(0)
  8612. gotsockname = 0
  8613. authptr = uintptr(0)
  8614. ret = int32(1)
  8615. /* Some systems like hpux or Hurd do not expose peer names
  8616. * for UNIX Domain Sockets, but this is irrelevant,
  8617. * since compute_auth() ignores the peer name in this
  8618. * case anyway.*/
  8619. v1 = _get_peer_sock_name(tls, __ccgo_fp(libc.Xgetpeername), fd)
  8620. sockname = v1
  8621. if v1 == libc.UintptrFromInt32(0) {
  8622. v2 = _get_peer_sock_name(tls, __ccgo_fp(libc.Xgetsockname), fd)
  8623. sockname = v2
  8624. if v2 == libc.UintptrFromInt32(0) {
  8625. return 0
  8626. } /* can only authenticate sockets */
  8627. if libc.Int32FromUint16((*Tsockaddr)(unsafe.Pointer(sockname)).Fsa_family) != int32(m_PF_LOCAL) {
  8628. libc.Xfree(tls, sockname)
  8629. return 0 /* except for AF_UNIX, sockets should have peernames */
  8630. }
  8631. gotsockname = int32(1)
  8632. }
  8633. authptr = _get_authptr(tls, sockname, display)
  8634. if authptr == uintptr(0) {
  8635. libc.Xfree(tls, sockname)
  8636. return 0 /* cannot find good auth data */
  8637. }
  8638. (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fnamelen = libc.Int32FromUint64(_memdup(tls, info+8, (*TXauth)(unsafe.Pointer(authptr)).Fname, uint64((*TXauth)(unsafe.Pointer(authptr)).Fname_length)))
  8639. if !((*Txcb_auth_info_t)(unsafe.Pointer(info)).Fnamelen != 0) {
  8640. goto no_auth
  8641. } /* out of memory */
  8642. if !(gotsockname != 0) {
  8643. libc.Xfree(tls, sockname)
  8644. v3 = _get_peer_sock_name(tls, __ccgo_fp(libc.Xgetsockname), fd)
  8645. sockname = v3
  8646. if v3 == libc.UintptrFromInt32(0) {
  8647. libc.Xfree(tls, (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fname)
  8648. goto no_auth /* can only authenticate sockets */
  8649. }
  8650. }
  8651. ret = _compute_auth(tls, info, authptr, sockname)
  8652. if !(ret != 0) {
  8653. libc.Xfree(tls, (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fname)
  8654. goto no_auth /* cannot build auth record */
  8655. }
  8656. libc.Xfree(tls, sockname)
  8657. sockname = libc.UintptrFromInt32(0)
  8658. libxau.XXauDisposeAuth(tls, authptr)
  8659. return ret
  8660. goto no_auth
  8661. no_auth:
  8662. ;
  8663. libc.Xfree(tls, sockname)
  8664. (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fname = uintptr(0)
  8665. (*Txcb_auth_info_t)(unsafe.Pointer(info)).Fnamelen = 0
  8666. libxau.XXauDisposeAuth(tls, authptr)
  8667. return 0
  8668. }
  8669. /*
  8670. * This file generated automatically from xproto.xml by c_client.py.
  8671. * Edit at your peril.
  8672. */
  8673. /**
  8674. * @defgroup XCB__API XCB API
  8675. * @brief XCB Protocol Implementation.
  8676. * @{
  8677. **/
  8678. /**
  8679. * @}
  8680. */
  8681. func Xxcb_char2b_next(tls *libc.TLS, i uintptr) {
  8682. var p1 uintptr
  8683. _ = p1
  8684. (*Txcb_char2b_iterator_t)(unsafe.Pointer(i)).Frem--
  8685. (*Txcb_char2b_iterator_t)(unsafe.Pointer(i)).Fdata += 2
  8686. p1 = i + 12
  8687. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(2))
  8688. }
  8689. func Xxcb_char2b_end(tls *libc.TLS, i Txcb_char2b_iterator_t) (r Txcb_generic_iterator_t) {
  8690. var ret Txcb_generic_iterator_t
  8691. _ = ret
  8692. ret.Fdata = i.Fdata + uintptr(i.Frem)*2
  8693. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8694. ret.Frem = 0
  8695. return ret
  8696. }
  8697. func Xxcb_window_next(tls *libc.TLS, i uintptr) {
  8698. var p1 uintptr
  8699. _ = p1
  8700. (*Txcb_window_iterator_t)(unsafe.Pointer(i)).Frem--
  8701. (*Txcb_window_iterator_t)(unsafe.Pointer(i)).Fdata += 4
  8702. p1 = i + 12
  8703. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(4))
  8704. }
  8705. func Xxcb_window_end(tls *libc.TLS, i Txcb_window_iterator_t) (r Txcb_generic_iterator_t) {
  8706. var ret Txcb_generic_iterator_t
  8707. _ = ret
  8708. ret.Fdata = i.Fdata + uintptr(i.Frem)*4
  8709. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8710. ret.Frem = 0
  8711. return ret
  8712. }
  8713. func Xxcb_pixmap_next(tls *libc.TLS, i uintptr) {
  8714. var p1 uintptr
  8715. _ = p1
  8716. (*Txcb_pixmap_iterator_t)(unsafe.Pointer(i)).Frem--
  8717. (*Txcb_pixmap_iterator_t)(unsafe.Pointer(i)).Fdata += 4
  8718. p1 = i + 12
  8719. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(4))
  8720. }
  8721. func Xxcb_pixmap_end(tls *libc.TLS, i Txcb_pixmap_iterator_t) (r Txcb_generic_iterator_t) {
  8722. var ret Txcb_generic_iterator_t
  8723. _ = ret
  8724. ret.Fdata = i.Fdata + uintptr(i.Frem)*4
  8725. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8726. ret.Frem = 0
  8727. return ret
  8728. }
  8729. func Xxcb_cursor_next(tls *libc.TLS, i uintptr) {
  8730. var p1 uintptr
  8731. _ = p1
  8732. (*Txcb_cursor_iterator_t)(unsafe.Pointer(i)).Frem--
  8733. (*Txcb_cursor_iterator_t)(unsafe.Pointer(i)).Fdata += 4
  8734. p1 = i + 12
  8735. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(4))
  8736. }
  8737. func Xxcb_cursor_end(tls *libc.TLS, i Txcb_cursor_iterator_t) (r Txcb_generic_iterator_t) {
  8738. var ret Txcb_generic_iterator_t
  8739. _ = ret
  8740. ret.Fdata = i.Fdata + uintptr(i.Frem)*4
  8741. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8742. ret.Frem = 0
  8743. return ret
  8744. }
  8745. func Xxcb_font_next(tls *libc.TLS, i uintptr) {
  8746. var p1 uintptr
  8747. _ = p1
  8748. (*Txcb_font_iterator_t)(unsafe.Pointer(i)).Frem--
  8749. (*Txcb_font_iterator_t)(unsafe.Pointer(i)).Fdata += 4
  8750. p1 = i + 12
  8751. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(4))
  8752. }
  8753. func Xxcb_font_end(tls *libc.TLS, i Txcb_font_iterator_t) (r Txcb_generic_iterator_t) {
  8754. var ret Txcb_generic_iterator_t
  8755. _ = ret
  8756. ret.Fdata = i.Fdata + uintptr(i.Frem)*4
  8757. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8758. ret.Frem = 0
  8759. return ret
  8760. }
  8761. func Xxcb_gcontext_next(tls *libc.TLS, i uintptr) {
  8762. var p1 uintptr
  8763. _ = p1
  8764. (*Txcb_gcontext_iterator_t)(unsafe.Pointer(i)).Frem--
  8765. (*Txcb_gcontext_iterator_t)(unsafe.Pointer(i)).Fdata += 4
  8766. p1 = i + 12
  8767. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(4))
  8768. }
  8769. func Xxcb_gcontext_end(tls *libc.TLS, i Txcb_gcontext_iterator_t) (r Txcb_generic_iterator_t) {
  8770. var ret Txcb_generic_iterator_t
  8771. _ = ret
  8772. ret.Fdata = i.Fdata + uintptr(i.Frem)*4
  8773. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8774. ret.Frem = 0
  8775. return ret
  8776. }
  8777. func Xxcb_colormap_next(tls *libc.TLS, i uintptr) {
  8778. var p1 uintptr
  8779. _ = p1
  8780. (*Txcb_colormap_iterator_t)(unsafe.Pointer(i)).Frem--
  8781. (*Txcb_colormap_iterator_t)(unsafe.Pointer(i)).Fdata += 4
  8782. p1 = i + 12
  8783. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(4))
  8784. }
  8785. func Xxcb_colormap_end(tls *libc.TLS, i Txcb_colormap_iterator_t) (r Txcb_generic_iterator_t) {
  8786. var ret Txcb_generic_iterator_t
  8787. _ = ret
  8788. ret.Fdata = i.Fdata + uintptr(i.Frem)*4
  8789. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8790. ret.Frem = 0
  8791. return ret
  8792. }
  8793. func Xxcb_atom_next(tls *libc.TLS, i uintptr) {
  8794. var p1 uintptr
  8795. _ = p1
  8796. (*Txcb_atom_iterator_t)(unsafe.Pointer(i)).Frem--
  8797. (*Txcb_atom_iterator_t)(unsafe.Pointer(i)).Fdata += 4
  8798. p1 = i + 12
  8799. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(4))
  8800. }
  8801. func Xxcb_atom_end(tls *libc.TLS, i Txcb_atom_iterator_t) (r Txcb_generic_iterator_t) {
  8802. var ret Txcb_generic_iterator_t
  8803. _ = ret
  8804. ret.Fdata = i.Fdata + uintptr(i.Frem)*4
  8805. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8806. ret.Frem = 0
  8807. return ret
  8808. }
  8809. func Xxcb_drawable_next(tls *libc.TLS, i uintptr) {
  8810. var p1 uintptr
  8811. _ = p1
  8812. (*Txcb_drawable_iterator_t)(unsafe.Pointer(i)).Frem--
  8813. (*Txcb_drawable_iterator_t)(unsafe.Pointer(i)).Fdata += 4
  8814. p1 = i + 12
  8815. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(4))
  8816. }
  8817. func Xxcb_drawable_end(tls *libc.TLS, i Txcb_drawable_iterator_t) (r Txcb_generic_iterator_t) {
  8818. var ret Txcb_generic_iterator_t
  8819. _ = ret
  8820. ret.Fdata = i.Fdata + uintptr(i.Frem)*4
  8821. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8822. ret.Frem = 0
  8823. return ret
  8824. }
  8825. func Xxcb_fontable_next(tls *libc.TLS, i uintptr) {
  8826. var p1 uintptr
  8827. _ = p1
  8828. (*Txcb_fontable_iterator_t)(unsafe.Pointer(i)).Frem--
  8829. (*Txcb_fontable_iterator_t)(unsafe.Pointer(i)).Fdata += 4
  8830. p1 = i + 12
  8831. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(4))
  8832. }
  8833. func Xxcb_fontable_end(tls *libc.TLS, i Txcb_fontable_iterator_t) (r Txcb_generic_iterator_t) {
  8834. var ret Txcb_generic_iterator_t
  8835. _ = ret
  8836. ret.Fdata = i.Fdata + uintptr(i.Frem)*4
  8837. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8838. ret.Frem = 0
  8839. return ret
  8840. }
  8841. func Xxcb_bool32_next(tls *libc.TLS, i uintptr) {
  8842. var p1 uintptr
  8843. _ = p1
  8844. (*Txcb_bool32_iterator_t)(unsafe.Pointer(i)).Frem--
  8845. (*Txcb_bool32_iterator_t)(unsafe.Pointer(i)).Fdata += 4
  8846. p1 = i + 12
  8847. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(4))
  8848. }
  8849. func Xxcb_bool32_end(tls *libc.TLS, i Txcb_bool32_iterator_t) (r Txcb_generic_iterator_t) {
  8850. var ret Txcb_generic_iterator_t
  8851. _ = ret
  8852. ret.Fdata = i.Fdata + uintptr(i.Frem)*4
  8853. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8854. ret.Frem = 0
  8855. return ret
  8856. }
  8857. func Xxcb_visualid_next(tls *libc.TLS, i uintptr) {
  8858. var p1 uintptr
  8859. _ = p1
  8860. (*Txcb_visualid_iterator_t)(unsafe.Pointer(i)).Frem--
  8861. (*Txcb_visualid_iterator_t)(unsafe.Pointer(i)).Fdata += 4
  8862. p1 = i + 12
  8863. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(4))
  8864. }
  8865. func Xxcb_visualid_end(tls *libc.TLS, i Txcb_visualid_iterator_t) (r Txcb_generic_iterator_t) {
  8866. var ret Txcb_generic_iterator_t
  8867. _ = ret
  8868. ret.Fdata = i.Fdata + uintptr(i.Frem)*4
  8869. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8870. ret.Frem = 0
  8871. return ret
  8872. }
  8873. func Xxcb_timestamp_next(tls *libc.TLS, i uintptr) {
  8874. var p1 uintptr
  8875. _ = p1
  8876. (*Txcb_timestamp_iterator_t)(unsafe.Pointer(i)).Frem--
  8877. (*Txcb_timestamp_iterator_t)(unsafe.Pointer(i)).Fdata += 4
  8878. p1 = i + 12
  8879. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(4))
  8880. }
  8881. func Xxcb_timestamp_end(tls *libc.TLS, i Txcb_timestamp_iterator_t) (r Txcb_generic_iterator_t) {
  8882. var ret Txcb_generic_iterator_t
  8883. _ = ret
  8884. ret.Fdata = i.Fdata + uintptr(i.Frem)*4
  8885. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8886. ret.Frem = 0
  8887. return ret
  8888. }
  8889. func Xxcb_keysym_next(tls *libc.TLS, i uintptr) {
  8890. var p1 uintptr
  8891. _ = p1
  8892. (*Txcb_keysym_iterator_t)(unsafe.Pointer(i)).Frem--
  8893. (*Txcb_keysym_iterator_t)(unsafe.Pointer(i)).Fdata += 4
  8894. p1 = i + 12
  8895. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(4))
  8896. }
  8897. func Xxcb_keysym_end(tls *libc.TLS, i Txcb_keysym_iterator_t) (r Txcb_generic_iterator_t) {
  8898. var ret Txcb_generic_iterator_t
  8899. _ = ret
  8900. ret.Fdata = i.Fdata + uintptr(i.Frem)*4
  8901. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8902. ret.Frem = 0
  8903. return ret
  8904. }
  8905. func Xxcb_keycode_next(tls *libc.TLS, i uintptr) {
  8906. var p1 uintptr
  8907. _ = p1
  8908. (*Txcb_keycode_iterator_t)(unsafe.Pointer(i)).Frem--
  8909. (*Txcb_keycode_iterator_t)(unsafe.Pointer(i)).Fdata++
  8910. p1 = i + 12
  8911. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(1))
  8912. }
  8913. func Xxcb_keycode_end(tls *libc.TLS, i Txcb_keycode_iterator_t) (r Txcb_generic_iterator_t) {
  8914. var ret Txcb_generic_iterator_t
  8915. _ = ret
  8916. ret.Fdata = i.Fdata + uintptr(i.Frem)
  8917. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8918. ret.Frem = 0
  8919. return ret
  8920. }
  8921. func Xxcb_keycode32_next(tls *libc.TLS, i uintptr) {
  8922. var p1 uintptr
  8923. _ = p1
  8924. (*Txcb_keycode32_iterator_t)(unsafe.Pointer(i)).Frem--
  8925. (*Txcb_keycode32_iterator_t)(unsafe.Pointer(i)).Fdata += 4
  8926. p1 = i + 12
  8927. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(4))
  8928. }
  8929. func Xxcb_keycode32_end(tls *libc.TLS, i Txcb_keycode32_iterator_t) (r Txcb_generic_iterator_t) {
  8930. var ret Txcb_generic_iterator_t
  8931. _ = ret
  8932. ret.Fdata = i.Fdata + uintptr(i.Frem)*4
  8933. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8934. ret.Frem = 0
  8935. return ret
  8936. }
  8937. func Xxcb_button_next(tls *libc.TLS, i uintptr) {
  8938. var p1 uintptr
  8939. _ = p1
  8940. (*Txcb_button_iterator_t)(unsafe.Pointer(i)).Frem--
  8941. (*Txcb_button_iterator_t)(unsafe.Pointer(i)).Fdata++
  8942. p1 = i + 12
  8943. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(1))
  8944. }
  8945. func Xxcb_button_end(tls *libc.TLS, i Txcb_button_iterator_t) (r Txcb_generic_iterator_t) {
  8946. var ret Txcb_generic_iterator_t
  8947. _ = ret
  8948. ret.Fdata = i.Fdata + uintptr(i.Frem)
  8949. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8950. ret.Frem = 0
  8951. return ret
  8952. }
  8953. func Xxcb_point_next(tls *libc.TLS, i uintptr) {
  8954. var p1 uintptr
  8955. _ = p1
  8956. (*Txcb_point_iterator_t)(unsafe.Pointer(i)).Frem--
  8957. (*Txcb_point_iterator_t)(unsafe.Pointer(i)).Fdata += 4
  8958. p1 = i + 12
  8959. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(4))
  8960. }
  8961. func Xxcb_point_end(tls *libc.TLS, i Txcb_point_iterator_t) (r Txcb_generic_iterator_t) {
  8962. var ret Txcb_generic_iterator_t
  8963. _ = ret
  8964. ret.Fdata = i.Fdata + uintptr(i.Frem)*4
  8965. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8966. ret.Frem = 0
  8967. return ret
  8968. }
  8969. func Xxcb_rectangle_next(tls *libc.TLS, i uintptr) {
  8970. var p1 uintptr
  8971. _ = p1
  8972. (*Txcb_rectangle_iterator_t)(unsafe.Pointer(i)).Frem--
  8973. (*Txcb_rectangle_iterator_t)(unsafe.Pointer(i)).Fdata += 8
  8974. p1 = i + 12
  8975. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(8))
  8976. }
  8977. func Xxcb_rectangle_end(tls *libc.TLS, i Txcb_rectangle_iterator_t) (r Txcb_generic_iterator_t) {
  8978. var ret Txcb_generic_iterator_t
  8979. _ = ret
  8980. ret.Fdata = i.Fdata + uintptr(i.Frem)*8
  8981. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8982. ret.Frem = 0
  8983. return ret
  8984. }
  8985. func Xxcb_arc_next(tls *libc.TLS, i uintptr) {
  8986. var p1 uintptr
  8987. _ = p1
  8988. (*Txcb_arc_iterator_t)(unsafe.Pointer(i)).Frem--
  8989. (*Txcb_arc_iterator_t)(unsafe.Pointer(i)).Fdata += 12
  8990. p1 = i + 12
  8991. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(12))
  8992. }
  8993. func Xxcb_arc_end(tls *libc.TLS, i Txcb_arc_iterator_t) (r Txcb_generic_iterator_t) {
  8994. var ret Txcb_generic_iterator_t
  8995. _ = ret
  8996. ret.Fdata = i.Fdata + uintptr(i.Frem)*12
  8997. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  8998. ret.Frem = 0
  8999. return ret
  9000. }
  9001. func Xxcb_format_next(tls *libc.TLS, i uintptr) {
  9002. var p1 uintptr
  9003. _ = p1
  9004. (*Txcb_format_iterator_t)(unsafe.Pointer(i)).Frem--
  9005. (*Txcb_format_iterator_t)(unsafe.Pointer(i)).Fdata += 8
  9006. p1 = i + 12
  9007. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(8))
  9008. }
  9009. func Xxcb_format_end(tls *libc.TLS, i Txcb_format_iterator_t) (r Txcb_generic_iterator_t) {
  9010. var ret Txcb_generic_iterator_t
  9011. _ = ret
  9012. ret.Fdata = i.Fdata + uintptr(i.Frem)*8
  9013. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  9014. ret.Frem = 0
  9015. return ret
  9016. }
  9017. func Xxcb_visualtype_next(tls *libc.TLS, i uintptr) {
  9018. var p1 uintptr
  9019. _ = p1
  9020. (*Txcb_visualtype_iterator_t)(unsafe.Pointer(i)).Frem--
  9021. (*Txcb_visualtype_iterator_t)(unsafe.Pointer(i)).Fdata += 24
  9022. p1 = i + 12
  9023. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(24))
  9024. }
  9025. func Xxcb_visualtype_end(tls *libc.TLS, i Txcb_visualtype_iterator_t) (r Txcb_generic_iterator_t) {
  9026. var ret Txcb_generic_iterator_t
  9027. _ = ret
  9028. ret.Fdata = i.Fdata + uintptr(i.Frem)*24
  9029. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  9030. ret.Frem = 0
  9031. return ret
  9032. }
  9033. func Xxcb_depth_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  9034. var _aux, xcb_tmp uintptr
  9035. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  9036. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  9037. xcb_tmp = _buffer
  9038. _aux = _buffer
  9039. xcb_buffer_len = uint32(0)
  9040. xcb_block_len = uint32(0)
  9041. xcb_pad = uint32(0)
  9042. xcb_align_to = uint32(0)
  9043. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(8))
  9044. xcb_tmp += uintptr(xcb_block_len)
  9045. xcb_buffer_len += xcb_block_len
  9046. xcb_block_len = uint32(0)
  9047. /* visuals */
  9048. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_depth_t)(unsafe.Pointer(_aux)).Fvisuals_len)*libc.Uint64FromInt64(24))
  9049. xcb_tmp += uintptr(xcb_block_len)
  9050. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9051. /* insert padding */
  9052. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  9053. xcb_buffer_len += xcb_block_len + xcb_pad
  9054. if uint32(0) != xcb_pad {
  9055. xcb_tmp += uintptr(xcb_pad)
  9056. xcb_pad = uint32(0)
  9057. }
  9058. xcb_block_len = uint32(0)
  9059. return libc.Int32FromUint32(xcb_buffer_len)
  9060. }
  9061. func Xxcb_depth_visuals(tls *libc.TLS, R uintptr) (r uintptr) {
  9062. return R + libc.UintptrFromInt32(1)*8
  9063. }
  9064. func Xxcb_depth_visuals_length(tls *libc.TLS, R uintptr) (r int32) {
  9065. return libc.Int32FromUint16((*Txcb_depth_t)(unsafe.Pointer(R)).Fvisuals_len)
  9066. }
  9067. func Xxcb_depth_visuals_iterator(tls *libc.TLS, R uintptr) (r Txcb_visualtype_iterator_t) {
  9068. var i Txcb_visualtype_iterator_t
  9069. _ = i
  9070. i.Fdata = R + libc.UintptrFromInt32(1)*8
  9071. i.Frem = libc.Int32FromUint16((*Txcb_depth_t)(unsafe.Pointer(R)).Fvisuals_len)
  9072. i.Findex = int32(int64(i.Fdata) - int64(R))
  9073. return i
  9074. }
  9075. func Xxcb_depth_next(tls *libc.TLS, i uintptr) {
  9076. var R uintptr
  9077. var child Txcb_generic_iterator_t
  9078. _, _ = R, child
  9079. R = (*Txcb_depth_iterator_t)(unsafe.Pointer(i)).Fdata
  9080. child.Fdata = R + uintptr(Xxcb_depth_sizeof(tls, R))
  9081. (*Txcb_depth_iterator_t)(unsafe.Pointer(i)).Findex = int32(int64(child.Fdata) - int64((*Txcb_depth_iterator_t)(unsafe.Pointer(i)).Fdata))
  9082. (*Txcb_depth_iterator_t)(unsafe.Pointer(i)).Frem--
  9083. (*Txcb_depth_iterator_t)(unsafe.Pointer(i)).Fdata = child.Fdata
  9084. }
  9085. func Xxcb_depth_end(tls *libc.TLS, _i Txcb_depth_iterator_t) (r Txcb_generic_iterator_t) {
  9086. bp := tls.Alloc(16)
  9087. defer tls.Free(16)
  9088. *(*Txcb_depth_iterator_t)(unsafe.Pointer(bp)) = _i
  9089. var ret Txcb_generic_iterator_t
  9090. _ = ret
  9091. for (*(*Txcb_depth_iterator_t)(unsafe.Pointer(bp))).Frem > 0 {
  9092. Xxcb_depth_next(tls, bp)
  9093. }
  9094. ret.Fdata = (*(*Txcb_depth_iterator_t)(unsafe.Pointer(bp))).Fdata
  9095. ret.Frem = (*(*Txcb_depth_iterator_t)(unsafe.Pointer(bp))).Frem
  9096. ret.Findex = (*(*Txcb_depth_iterator_t)(unsafe.Pointer(bp))).Findex
  9097. return ret
  9098. }
  9099. func Xxcb_screen_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  9100. var _aux, xcb_tmp uintptr
  9101. var i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp_len uint32
  9102. _, _, _, _, _, _, _, _ = _aux, i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp, xcb_tmp_len
  9103. xcb_tmp = _buffer
  9104. _aux = _buffer
  9105. xcb_buffer_len = uint32(0)
  9106. xcb_block_len = uint32(0)
  9107. xcb_pad = uint32(0)
  9108. xcb_align_to = uint32(0)
  9109. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(40))
  9110. xcb_tmp += uintptr(xcb_block_len)
  9111. xcb_buffer_len += xcb_block_len
  9112. xcb_block_len = uint32(0)
  9113. /* allowed_depths */
  9114. i = uint32(0)
  9115. for {
  9116. if !(i < uint32((*Txcb_screen_t)(unsafe.Pointer(_aux)).Fallowed_depths_len)) {
  9117. break
  9118. }
  9119. xcb_tmp_len = libc.Uint32FromInt32(Xxcb_depth_sizeof(tls, xcb_tmp))
  9120. xcb_block_len += xcb_tmp_len
  9121. xcb_tmp += uintptr(xcb_tmp_len)
  9122. goto _1
  9123. _1:
  9124. ;
  9125. i++
  9126. }
  9127. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 2))
  9128. /* insert padding */
  9129. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  9130. xcb_buffer_len += xcb_block_len + xcb_pad
  9131. if uint32(0) != xcb_pad {
  9132. xcb_tmp += uintptr(xcb_pad)
  9133. xcb_pad = uint32(0)
  9134. }
  9135. xcb_block_len = uint32(0)
  9136. return libc.Int32FromUint32(xcb_buffer_len)
  9137. }
  9138. func Xxcb_screen_allowed_depths_length(tls *libc.TLS, R uintptr) (r int32) {
  9139. return libc.Int32FromUint8((*Txcb_screen_t)(unsafe.Pointer(R)).Fallowed_depths_len)
  9140. }
  9141. func Xxcb_screen_allowed_depths_iterator(tls *libc.TLS, R uintptr) (r Txcb_depth_iterator_t) {
  9142. var i Txcb_depth_iterator_t
  9143. _ = i
  9144. i.Fdata = R + libc.UintptrFromInt32(1)*40
  9145. i.Frem = libc.Int32FromUint8((*Txcb_screen_t)(unsafe.Pointer(R)).Fallowed_depths_len)
  9146. i.Findex = int32(int64(i.Fdata) - int64(R))
  9147. return i
  9148. }
  9149. func Xxcb_screen_next(tls *libc.TLS, i uintptr) {
  9150. var R uintptr
  9151. var child Txcb_generic_iterator_t
  9152. _, _ = R, child
  9153. R = (*Txcb_screen_iterator_t)(unsafe.Pointer(i)).Fdata
  9154. child.Fdata = R + uintptr(Xxcb_screen_sizeof(tls, R))
  9155. (*Txcb_screen_iterator_t)(unsafe.Pointer(i)).Findex = int32(int64(child.Fdata) - int64((*Txcb_screen_iterator_t)(unsafe.Pointer(i)).Fdata))
  9156. (*Txcb_screen_iterator_t)(unsafe.Pointer(i)).Frem--
  9157. (*Txcb_screen_iterator_t)(unsafe.Pointer(i)).Fdata = child.Fdata
  9158. }
  9159. func Xxcb_screen_end(tls *libc.TLS, _i Txcb_screen_iterator_t) (r Txcb_generic_iterator_t) {
  9160. bp := tls.Alloc(16)
  9161. defer tls.Free(16)
  9162. *(*Txcb_screen_iterator_t)(unsafe.Pointer(bp)) = _i
  9163. var ret Txcb_generic_iterator_t
  9164. _ = ret
  9165. for (*(*Txcb_screen_iterator_t)(unsafe.Pointer(bp))).Frem > 0 {
  9166. Xxcb_screen_next(tls, bp)
  9167. }
  9168. ret.Fdata = (*(*Txcb_screen_iterator_t)(unsafe.Pointer(bp))).Fdata
  9169. ret.Frem = (*(*Txcb_screen_iterator_t)(unsafe.Pointer(bp))).Frem
  9170. ret.Findex = (*(*Txcb_screen_iterator_t)(unsafe.Pointer(bp))).Findex
  9171. return ret
  9172. }
  9173. func Xxcb_setup_request_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  9174. var _aux, xcb_tmp uintptr
  9175. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  9176. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  9177. xcb_tmp = _buffer
  9178. _aux = _buffer
  9179. xcb_buffer_len = uint32(0)
  9180. xcb_block_len = uint32(0)
  9181. xcb_pad = uint32(0)
  9182. xcb_align_to = uint32(0)
  9183. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  9184. xcb_tmp += uintptr(xcb_block_len)
  9185. xcb_buffer_len += xcb_block_len
  9186. xcb_block_len = uint32(0)
  9187. /* authorization_protocol_name */
  9188. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_setup_request_t)(unsafe.Pointer(_aux)).Fauthorization_protocol_name_len)*libc.Uint64FromInt64(1))
  9189. xcb_tmp += uintptr(xcb_block_len)
  9190. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  9191. xcb_align_to = uint32(4)
  9192. /* insert padding */
  9193. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  9194. xcb_buffer_len += xcb_block_len + xcb_pad
  9195. if uint32(0) != xcb_pad {
  9196. xcb_tmp += uintptr(xcb_pad)
  9197. xcb_pad = uint32(0)
  9198. }
  9199. xcb_block_len = uint32(0)
  9200. /* insert padding */
  9201. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  9202. xcb_buffer_len += xcb_block_len + xcb_pad
  9203. if uint32(0) != xcb_pad {
  9204. xcb_tmp += uintptr(xcb_pad)
  9205. xcb_pad = uint32(0)
  9206. }
  9207. xcb_block_len = uint32(0)
  9208. /* authorization_protocol_data */
  9209. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_setup_request_t)(unsafe.Pointer(_aux)).Fauthorization_protocol_data_len)*libc.Uint64FromInt64(1))
  9210. xcb_tmp += uintptr(xcb_block_len)
  9211. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  9212. xcb_align_to = uint32(4)
  9213. /* insert padding */
  9214. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  9215. xcb_buffer_len += xcb_block_len + xcb_pad
  9216. if uint32(0) != xcb_pad {
  9217. xcb_tmp += uintptr(xcb_pad)
  9218. xcb_pad = uint32(0)
  9219. }
  9220. xcb_block_len = uint32(0)
  9221. /* insert padding */
  9222. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  9223. xcb_buffer_len += xcb_block_len + xcb_pad
  9224. if uint32(0) != xcb_pad {
  9225. xcb_tmp += uintptr(xcb_pad)
  9226. xcb_pad = uint32(0)
  9227. }
  9228. xcb_block_len = uint32(0)
  9229. return libc.Int32FromUint32(xcb_buffer_len)
  9230. }
  9231. func Xxcb_setup_request_authorization_protocol_name(tls *libc.TLS, R uintptr) (r uintptr) {
  9232. return R + libc.UintptrFromInt32(1)*12
  9233. }
  9234. func Xxcb_setup_request_authorization_protocol_name_length(tls *libc.TLS, R uintptr) (r int32) {
  9235. return libc.Int32FromUint16((*Txcb_setup_request_t)(unsafe.Pointer(R)).Fauthorization_protocol_name_len)
  9236. }
  9237. func Xxcb_setup_request_authorization_protocol_name_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  9238. var i Txcb_generic_iterator_t
  9239. _ = i
  9240. i.Fdata = R + libc.UintptrFromInt32(1)*12 + uintptr((*Txcb_setup_request_t)(unsafe.Pointer(R)).Fauthorization_protocol_name_len)
  9241. i.Frem = 0
  9242. i.Findex = int32(int64(i.Fdata) - int64(R))
  9243. return i
  9244. }
  9245. func Xxcb_setup_request_authorization_protocol_data(tls *libc.TLS, R uintptr) (r uintptr) {
  9246. var prev Txcb_generic_iterator_t
  9247. _ = prev
  9248. prev = Xxcb_setup_request_authorization_protocol_name_end(tls, R)
  9249. return prev.Fdata + uintptr(-prev.Findex&(libc.Int32FromInt32(4)-libc.Int32FromInt32(1))) + libc.UintptrFromInt32(0)
  9250. }
  9251. func Xxcb_setup_request_authorization_protocol_data_length(tls *libc.TLS, R uintptr) (r int32) {
  9252. return libc.Int32FromUint16((*Txcb_setup_request_t)(unsafe.Pointer(R)).Fauthorization_protocol_data_len)
  9253. }
  9254. func Xxcb_setup_request_authorization_protocol_data_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  9255. var i, prev Txcb_generic_iterator_t
  9256. _, _ = i, prev
  9257. prev = Xxcb_setup_request_authorization_protocol_name_end(tls, R)
  9258. i.Fdata = prev.Fdata + uintptr(-prev.Findex&(libc.Int32FromInt32(4)-libc.Int32FromInt32(1))) + uintptr((*Txcb_setup_request_t)(unsafe.Pointer(R)).Fauthorization_protocol_data_len)
  9259. i.Frem = 0
  9260. i.Findex = int32(int64(i.Fdata) - int64(R))
  9261. return i
  9262. }
  9263. func Xxcb_setup_request_next(tls *libc.TLS, i uintptr) {
  9264. var R uintptr
  9265. var child Txcb_generic_iterator_t
  9266. _, _ = R, child
  9267. R = (*Txcb_setup_request_iterator_t)(unsafe.Pointer(i)).Fdata
  9268. child.Fdata = R + uintptr(Xxcb_setup_request_sizeof(tls, R))
  9269. (*Txcb_setup_request_iterator_t)(unsafe.Pointer(i)).Findex = int32(int64(child.Fdata) - int64((*Txcb_setup_request_iterator_t)(unsafe.Pointer(i)).Fdata))
  9270. (*Txcb_setup_request_iterator_t)(unsafe.Pointer(i)).Frem--
  9271. (*Txcb_setup_request_iterator_t)(unsafe.Pointer(i)).Fdata = child.Fdata
  9272. }
  9273. func Xxcb_setup_request_end(tls *libc.TLS, _i Txcb_setup_request_iterator_t) (r Txcb_generic_iterator_t) {
  9274. bp := tls.Alloc(16)
  9275. defer tls.Free(16)
  9276. *(*Txcb_setup_request_iterator_t)(unsafe.Pointer(bp)) = _i
  9277. var ret Txcb_generic_iterator_t
  9278. _ = ret
  9279. for (*(*Txcb_setup_request_iterator_t)(unsafe.Pointer(bp))).Frem > 0 {
  9280. Xxcb_setup_request_next(tls, bp)
  9281. }
  9282. ret.Fdata = (*(*Txcb_setup_request_iterator_t)(unsafe.Pointer(bp))).Fdata
  9283. ret.Frem = (*(*Txcb_setup_request_iterator_t)(unsafe.Pointer(bp))).Frem
  9284. ret.Findex = (*(*Txcb_setup_request_iterator_t)(unsafe.Pointer(bp))).Findex
  9285. return ret
  9286. }
  9287. func Xxcb_setup_failed_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  9288. var _aux, xcb_tmp uintptr
  9289. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  9290. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  9291. xcb_tmp = _buffer
  9292. _aux = _buffer
  9293. xcb_buffer_len = uint32(0)
  9294. xcb_block_len = uint32(0)
  9295. xcb_pad = uint32(0)
  9296. xcb_align_to = uint32(0)
  9297. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(8))
  9298. xcb_tmp += uintptr(xcb_block_len)
  9299. xcb_buffer_len += xcb_block_len
  9300. xcb_block_len = uint32(0)
  9301. /* reason */
  9302. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_setup_failed_t)(unsafe.Pointer(_aux)).Freason_len)*libc.Uint64FromInt64(1))
  9303. xcb_tmp += uintptr(xcb_block_len)
  9304. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  9305. /* insert padding */
  9306. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  9307. xcb_buffer_len += xcb_block_len + xcb_pad
  9308. if uint32(0) != xcb_pad {
  9309. xcb_tmp += uintptr(xcb_pad)
  9310. xcb_pad = uint32(0)
  9311. }
  9312. xcb_block_len = uint32(0)
  9313. return libc.Int32FromUint32(xcb_buffer_len)
  9314. }
  9315. func Xxcb_setup_failed_reason(tls *libc.TLS, R uintptr) (r uintptr) {
  9316. return R + libc.UintptrFromInt32(1)*8
  9317. }
  9318. func Xxcb_setup_failed_reason_length(tls *libc.TLS, R uintptr) (r int32) {
  9319. return libc.Int32FromUint8((*Txcb_setup_failed_t)(unsafe.Pointer(R)).Freason_len)
  9320. }
  9321. func Xxcb_setup_failed_reason_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  9322. var i Txcb_generic_iterator_t
  9323. _ = i
  9324. i.Fdata = R + libc.UintptrFromInt32(1)*8 + uintptr((*Txcb_setup_failed_t)(unsafe.Pointer(R)).Freason_len)
  9325. i.Frem = 0
  9326. i.Findex = int32(int64(i.Fdata) - int64(R))
  9327. return i
  9328. }
  9329. func Xxcb_setup_failed_next(tls *libc.TLS, i uintptr) {
  9330. var R uintptr
  9331. var child Txcb_generic_iterator_t
  9332. _, _ = R, child
  9333. R = (*Txcb_setup_failed_iterator_t)(unsafe.Pointer(i)).Fdata
  9334. child.Fdata = R + uintptr(Xxcb_setup_failed_sizeof(tls, R))
  9335. (*Txcb_setup_failed_iterator_t)(unsafe.Pointer(i)).Findex = int32(int64(child.Fdata) - int64((*Txcb_setup_failed_iterator_t)(unsafe.Pointer(i)).Fdata))
  9336. (*Txcb_setup_failed_iterator_t)(unsafe.Pointer(i)).Frem--
  9337. (*Txcb_setup_failed_iterator_t)(unsafe.Pointer(i)).Fdata = child.Fdata
  9338. }
  9339. func Xxcb_setup_failed_end(tls *libc.TLS, _i Txcb_setup_failed_iterator_t) (r Txcb_generic_iterator_t) {
  9340. bp := tls.Alloc(16)
  9341. defer tls.Free(16)
  9342. *(*Txcb_setup_failed_iterator_t)(unsafe.Pointer(bp)) = _i
  9343. var ret Txcb_generic_iterator_t
  9344. _ = ret
  9345. for (*(*Txcb_setup_failed_iterator_t)(unsafe.Pointer(bp))).Frem > 0 {
  9346. Xxcb_setup_failed_next(tls, bp)
  9347. }
  9348. ret.Fdata = (*(*Txcb_setup_failed_iterator_t)(unsafe.Pointer(bp))).Fdata
  9349. ret.Frem = (*(*Txcb_setup_failed_iterator_t)(unsafe.Pointer(bp))).Frem
  9350. ret.Findex = (*(*Txcb_setup_failed_iterator_t)(unsafe.Pointer(bp))).Findex
  9351. return ret
  9352. }
  9353. func Xxcb_setup_authenticate_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  9354. var _aux, xcb_tmp uintptr
  9355. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  9356. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  9357. xcb_tmp = _buffer
  9358. _aux = _buffer
  9359. xcb_buffer_len = uint32(0)
  9360. xcb_block_len = uint32(0)
  9361. xcb_pad = uint32(0)
  9362. xcb_align_to = uint32(0)
  9363. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(8))
  9364. xcb_tmp += uintptr(xcb_block_len)
  9365. xcb_buffer_len += xcb_block_len
  9366. xcb_block_len = uint32(0)
  9367. /* reason */
  9368. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_setup_authenticate_t)(unsafe.Pointer(_aux)).Flength)*libc.Int32FromInt32(4))*libc.Uint64FromInt64(1))
  9369. xcb_tmp += uintptr(xcb_block_len)
  9370. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  9371. /* insert padding */
  9372. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  9373. xcb_buffer_len += xcb_block_len + xcb_pad
  9374. if uint32(0) != xcb_pad {
  9375. xcb_tmp += uintptr(xcb_pad)
  9376. xcb_pad = uint32(0)
  9377. }
  9378. xcb_block_len = uint32(0)
  9379. return libc.Int32FromUint32(xcb_buffer_len)
  9380. }
  9381. func Xxcb_setup_authenticate_reason(tls *libc.TLS, R uintptr) (r uintptr) {
  9382. return R + libc.UintptrFromInt32(1)*8
  9383. }
  9384. func Xxcb_setup_authenticate_reason_length(tls *libc.TLS, R uintptr) (r int32) {
  9385. return libc.Int32FromUint16((*Txcb_setup_authenticate_t)(unsafe.Pointer(R)).Flength) * int32(4)
  9386. }
  9387. func Xxcb_setup_authenticate_reason_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  9388. var i Txcb_generic_iterator_t
  9389. _ = i
  9390. i.Fdata = R + libc.UintptrFromInt32(1)*8 + uintptr(libc.Int32FromUint16((*Txcb_setup_authenticate_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4))
  9391. i.Frem = 0
  9392. i.Findex = int32(int64(i.Fdata) - int64(R))
  9393. return i
  9394. }
  9395. func Xxcb_setup_authenticate_next(tls *libc.TLS, i uintptr) {
  9396. var R uintptr
  9397. var child Txcb_generic_iterator_t
  9398. _, _ = R, child
  9399. R = (*Txcb_setup_authenticate_iterator_t)(unsafe.Pointer(i)).Fdata
  9400. child.Fdata = R + uintptr(Xxcb_setup_authenticate_sizeof(tls, R))
  9401. (*Txcb_setup_authenticate_iterator_t)(unsafe.Pointer(i)).Findex = int32(int64(child.Fdata) - int64((*Txcb_setup_authenticate_iterator_t)(unsafe.Pointer(i)).Fdata))
  9402. (*Txcb_setup_authenticate_iterator_t)(unsafe.Pointer(i)).Frem--
  9403. (*Txcb_setup_authenticate_iterator_t)(unsafe.Pointer(i)).Fdata = child.Fdata
  9404. }
  9405. func Xxcb_setup_authenticate_end(tls *libc.TLS, _i Txcb_setup_authenticate_iterator_t) (r Txcb_generic_iterator_t) {
  9406. bp := tls.Alloc(16)
  9407. defer tls.Free(16)
  9408. *(*Txcb_setup_authenticate_iterator_t)(unsafe.Pointer(bp)) = _i
  9409. var ret Txcb_generic_iterator_t
  9410. _ = ret
  9411. for (*(*Txcb_setup_authenticate_iterator_t)(unsafe.Pointer(bp))).Frem > 0 {
  9412. Xxcb_setup_authenticate_next(tls, bp)
  9413. }
  9414. ret.Fdata = (*(*Txcb_setup_authenticate_iterator_t)(unsafe.Pointer(bp))).Fdata
  9415. ret.Frem = (*(*Txcb_setup_authenticate_iterator_t)(unsafe.Pointer(bp))).Frem
  9416. ret.Findex = (*(*Txcb_setup_authenticate_iterator_t)(unsafe.Pointer(bp))).Findex
  9417. return ret
  9418. }
  9419. func Xxcb_setup_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  9420. var _aux, xcb_tmp uintptr
  9421. var i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp_len uint32
  9422. _, _, _, _, _, _, _, _ = _aux, i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp, xcb_tmp_len
  9423. xcb_tmp = _buffer
  9424. _aux = _buffer
  9425. xcb_buffer_len = uint32(0)
  9426. xcb_block_len = uint32(0)
  9427. xcb_pad = uint32(0)
  9428. xcb_align_to = uint32(0)
  9429. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(40))
  9430. xcb_tmp += uintptr(xcb_block_len)
  9431. xcb_buffer_len += xcb_block_len
  9432. xcb_block_len = uint32(0)
  9433. /* vendor */
  9434. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_setup_t)(unsafe.Pointer(_aux)).Fvendor_len)*libc.Uint64FromInt64(1))
  9435. xcb_tmp += uintptr(xcb_block_len)
  9436. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  9437. xcb_align_to = uint32(4)
  9438. /* insert padding */
  9439. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  9440. xcb_buffer_len += xcb_block_len + xcb_pad
  9441. if uint32(0) != xcb_pad {
  9442. xcb_tmp += uintptr(xcb_pad)
  9443. xcb_pad = uint32(0)
  9444. }
  9445. xcb_block_len = uint32(0)
  9446. /* insert padding */
  9447. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  9448. xcb_buffer_len += xcb_block_len + xcb_pad
  9449. if uint32(0) != xcb_pad {
  9450. xcb_tmp += uintptr(xcb_pad)
  9451. xcb_pad = uint32(0)
  9452. }
  9453. xcb_block_len = uint32(0)
  9454. /* pixmap_formats */
  9455. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_setup_t)(unsafe.Pointer(_aux)).Fpixmap_formats_len)*libc.Uint64FromInt64(8))
  9456. xcb_tmp += uintptr(xcb_block_len)
  9457. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  9458. /* insert padding */
  9459. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  9460. xcb_buffer_len += xcb_block_len + xcb_pad
  9461. if uint32(0) != xcb_pad {
  9462. xcb_tmp += uintptr(xcb_pad)
  9463. xcb_pad = uint32(0)
  9464. }
  9465. xcb_block_len = uint32(0)
  9466. /* roots */
  9467. i = uint32(0)
  9468. for {
  9469. if !(i < uint32((*Txcb_setup_t)(unsafe.Pointer(_aux)).Froots_len)) {
  9470. break
  9471. }
  9472. xcb_tmp_len = libc.Uint32FromInt32(Xxcb_screen_sizeof(tls, xcb_tmp))
  9473. xcb_block_len += xcb_tmp_len
  9474. xcb_tmp += uintptr(xcb_tmp_len)
  9475. goto _1
  9476. _1:
  9477. ;
  9478. i++
  9479. }
  9480. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9481. /* insert padding */
  9482. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  9483. xcb_buffer_len += xcb_block_len + xcb_pad
  9484. if uint32(0) != xcb_pad {
  9485. xcb_tmp += uintptr(xcb_pad)
  9486. xcb_pad = uint32(0)
  9487. }
  9488. xcb_block_len = uint32(0)
  9489. return libc.Int32FromUint32(xcb_buffer_len)
  9490. }
  9491. func Xxcb_setup_vendor(tls *libc.TLS, R uintptr) (r uintptr) {
  9492. return R + libc.UintptrFromInt32(1)*40
  9493. }
  9494. func Xxcb_setup_vendor_length(tls *libc.TLS, R uintptr) (r int32) {
  9495. return libc.Int32FromUint16((*Txcb_setup_t)(unsafe.Pointer(R)).Fvendor_len)
  9496. }
  9497. func Xxcb_setup_vendor_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  9498. var i Txcb_generic_iterator_t
  9499. _ = i
  9500. i.Fdata = R + libc.UintptrFromInt32(1)*40 + uintptr((*Txcb_setup_t)(unsafe.Pointer(R)).Fvendor_len)
  9501. i.Frem = 0
  9502. i.Findex = int32(int64(i.Fdata) - int64(R))
  9503. return i
  9504. }
  9505. func Xxcb_setup_pixmap_formats(tls *libc.TLS, R uintptr) (r uintptr) {
  9506. var prev Txcb_generic_iterator_t
  9507. _ = prev
  9508. prev = Xxcb_setup_vendor_end(tls, R)
  9509. return prev.Fdata + uintptr(-prev.Findex&(libc.Int32FromInt32(4)-libc.Int32FromInt32(1))) + libc.UintptrFromInt32(0)
  9510. }
  9511. func Xxcb_setup_pixmap_formats_length(tls *libc.TLS, R uintptr) (r int32) {
  9512. return libc.Int32FromUint8((*Txcb_setup_t)(unsafe.Pointer(R)).Fpixmap_formats_len)
  9513. }
  9514. func Xxcb_setup_pixmap_formats_iterator(tls *libc.TLS, R uintptr) (r Txcb_format_iterator_t) {
  9515. var i Txcb_format_iterator_t
  9516. var prev Txcb_generic_iterator_t
  9517. _, _ = i, prev
  9518. prev = Xxcb_setup_vendor_end(tls, R)
  9519. i.Fdata = prev.Fdata + uintptr(-prev.Findex&(libc.Int32FromInt32(4)-libc.Int32FromInt32(1)))
  9520. i.Frem = libc.Int32FromUint8((*Txcb_setup_t)(unsafe.Pointer(R)).Fpixmap_formats_len)
  9521. i.Findex = int32(int64(i.Fdata) - int64(R))
  9522. return i
  9523. }
  9524. func Xxcb_setup_roots_length(tls *libc.TLS, R uintptr) (r int32) {
  9525. return libc.Int32FromUint8((*Txcb_setup_t)(unsafe.Pointer(R)).Froots_len)
  9526. }
  9527. func Xxcb_setup_roots_iterator(tls *libc.TLS, R uintptr) (r Txcb_screen_iterator_t) {
  9528. var i Txcb_screen_iterator_t
  9529. var prev Txcb_generic_iterator_t
  9530. _, _ = i, prev
  9531. prev = Xxcb_format_end(tls, Xxcb_setup_pixmap_formats_iterator(tls, R))
  9532. i.Fdata = prev.Fdata + uintptr(libc.Uint64FromInt32(-prev.Findex)&libc.Uint64FromInt32(3))
  9533. i.Frem = libc.Int32FromUint8((*Txcb_setup_t)(unsafe.Pointer(R)).Froots_len)
  9534. i.Findex = int32(int64(i.Fdata) - int64(R))
  9535. return i
  9536. }
  9537. func Xxcb_setup_next(tls *libc.TLS, i uintptr) {
  9538. var R uintptr
  9539. var child Txcb_generic_iterator_t
  9540. _, _ = R, child
  9541. R = (*Txcb_setup_iterator_t)(unsafe.Pointer(i)).Fdata
  9542. child.Fdata = R + uintptr(Xxcb_setup_sizeof(tls, R))
  9543. (*Txcb_setup_iterator_t)(unsafe.Pointer(i)).Findex = int32(int64(child.Fdata) - int64((*Txcb_setup_iterator_t)(unsafe.Pointer(i)).Fdata))
  9544. (*Txcb_setup_iterator_t)(unsafe.Pointer(i)).Frem--
  9545. (*Txcb_setup_iterator_t)(unsafe.Pointer(i)).Fdata = child.Fdata
  9546. }
  9547. func Xxcb_setup_end(tls *libc.TLS, _i Txcb_setup_iterator_t) (r Txcb_generic_iterator_t) {
  9548. bp := tls.Alloc(16)
  9549. defer tls.Free(16)
  9550. *(*Txcb_setup_iterator_t)(unsafe.Pointer(bp)) = _i
  9551. var ret Txcb_generic_iterator_t
  9552. _ = ret
  9553. for (*(*Txcb_setup_iterator_t)(unsafe.Pointer(bp))).Frem > 0 {
  9554. Xxcb_setup_next(tls, bp)
  9555. }
  9556. ret.Fdata = (*(*Txcb_setup_iterator_t)(unsafe.Pointer(bp))).Fdata
  9557. ret.Frem = (*(*Txcb_setup_iterator_t)(unsafe.Pointer(bp))).Frem
  9558. ret.Findex = (*(*Txcb_setup_iterator_t)(unsafe.Pointer(bp))).Findex
  9559. return ret
  9560. }
  9561. func Xxcb_client_message_data_next(tls *libc.TLS, i uintptr) {
  9562. var p1 uintptr
  9563. _ = p1
  9564. (*Txcb_client_message_data_iterator_t)(unsafe.Pointer(i)).Frem--
  9565. (*Txcb_client_message_data_iterator_t)(unsafe.Pointer(i)).Fdata += 20
  9566. p1 = i + 12
  9567. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(20))
  9568. }
  9569. func Xxcb_client_message_data_end(tls *libc.TLS, i Txcb_client_message_data_iterator_t) (r Txcb_generic_iterator_t) {
  9570. var ret Txcb_generic_iterator_t
  9571. _ = ret
  9572. ret.Fdata = i.Fdata + uintptr(i.Frem)*20
  9573. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  9574. ret.Frem = 0
  9575. return ret
  9576. }
  9577. func Xxcb_create_window_value_list_serialize(tls *libc.TLS, _buffer uintptr, value_mask Tuint32_t, _aux uintptr) (r int32) {
  9578. bp := tls.Alloc(16)
  9579. defer tls.Free(16)
  9580. var i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset, xcb_parts_idx uint32
  9581. var xcb_out, xcb_tmp uintptr
  9582. var xcb_parts [16]Tiovec
  9583. var _ /* xcb_pad0 at bp+0 */ [3]int8
  9584. _, _, _, _, _, _, _, _, _, _ = i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_out, xcb_pad, xcb_padding_offset, xcb_parts, xcb_parts_idx, xcb_tmp
  9585. xcb_out = *(*uintptr)(unsafe.Pointer(_buffer))
  9586. xcb_buffer_len = uint32(0)
  9587. xcb_align_to = uint32(0)
  9588. xcb_padding_offset = uint32(0)
  9589. xcb_pad = uint32(0)
  9590. *(*[3]int8)(unsafe.Pointer(bp)) = [3]int8{}
  9591. xcb_parts_idx = uint32(0)
  9592. xcb_block_len = uint32(0)
  9593. if value_mask&uint32(_XCB_CW_BACK_PIXMAP) != 0 {
  9594. /* xcb_create_window_value_list_t.background_pixmap */
  9595. xcb_parts[xcb_parts_idx].Fiov_base = _aux
  9596. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9597. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  9598. xcb_parts_idx++
  9599. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9600. }
  9601. if value_mask&uint32(_XCB_CW_BACK_PIXEL) != 0 {
  9602. /* xcb_create_window_value_list_t.background_pixel */
  9603. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 4
  9604. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9605. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  9606. xcb_parts_idx++
  9607. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9608. }
  9609. if value_mask&uint32(_XCB_CW_BORDER_PIXMAP) != 0 {
  9610. /* xcb_create_window_value_list_t.border_pixmap */
  9611. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 8
  9612. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9613. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  9614. xcb_parts_idx++
  9615. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9616. }
  9617. if value_mask&uint32(_XCB_CW_BORDER_PIXEL) != 0 {
  9618. /* xcb_create_window_value_list_t.border_pixel */
  9619. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 12
  9620. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9621. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  9622. xcb_parts_idx++
  9623. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9624. }
  9625. if value_mask&uint32(_XCB_CW_BIT_GRAVITY) != 0 {
  9626. /* xcb_create_window_value_list_t.bit_gravity */
  9627. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 16
  9628. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9629. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  9630. xcb_parts_idx++
  9631. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9632. }
  9633. if value_mask&uint32(_XCB_CW_WIN_GRAVITY) != 0 {
  9634. /* xcb_create_window_value_list_t.win_gravity */
  9635. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 20
  9636. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9637. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  9638. xcb_parts_idx++
  9639. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9640. }
  9641. if value_mask&uint32(_XCB_CW_BACKING_STORE) != 0 {
  9642. /* xcb_create_window_value_list_t.backing_store */
  9643. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 24
  9644. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9645. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  9646. xcb_parts_idx++
  9647. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9648. }
  9649. if value_mask&uint32(_XCB_CW_BACKING_PLANES) != 0 {
  9650. /* xcb_create_window_value_list_t.backing_planes */
  9651. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 28
  9652. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9653. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  9654. xcb_parts_idx++
  9655. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9656. }
  9657. if value_mask&uint32(_XCB_CW_BACKING_PIXEL) != 0 {
  9658. /* xcb_create_window_value_list_t.backing_pixel */
  9659. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 32
  9660. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9661. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  9662. xcb_parts_idx++
  9663. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9664. }
  9665. if value_mask&uint32(_XCB_CW_OVERRIDE_REDIRECT) != 0 {
  9666. /* xcb_create_window_value_list_t.override_redirect */
  9667. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 36
  9668. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9669. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  9670. xcb_parts_idx++
  9671. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9672. }
  9673. if value_mask&uint32(_XCB_CW_SAVE_UNDER) != 0 {
  9674. /* xcb_create_window_value_list_t.save_under */
  9675. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 40
  9676. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9677. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  9678. xcb_parts_idx++
  9679. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9680. }
  9681. if value_mask&uint32(_XCB_CW_EVENT_MASK) != 0 {
  9682. /* xcb_create_window_value_list_t.event_mask */
  9683. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 44
  9684. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9685. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  9686. xcb_parts_idx++
  9687. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9688. }
  9689. if value_mask&uint32(_XCB_CW_DONT_PROPAGATE) != 0 {
  9690. /* xcb_create_window_value_list_t.do_not_propogate_mask */
  9691. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 48
  9692. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9693. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  9694. xcb_parts_idx++
  9695. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9696. }
  9697. if value_mask&uint32(_XCB_CW_COLORMAP) != 0 {
  9698. /* xcb_create_window_value_list_t.colormap */
  9699. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 52
  9700. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9701. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  9702. xcb_parts_idx++
  9703. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9704. }
  9705. if value_mask&uint32(_XCB_CW_CURSOR) != 0 {
  9706. /* xcb_create_window_value_list_t.cursor */
  9707. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 56
  9708. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9709. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  9710. xcb_parts_idx++
  9711. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9712. }
  9713. /* insert padding */
  9714. xcb_pad = -(xcb_block_len + xcb_padding_offset) & (xcb_align_to - uint32(1))
  9715. xcb_buffer_len += xcb_block_len + xcb_pad
  9716. if uint32(0) != xcb_pad {
  9717. xcb_parts[xcb_parts_idx].Fiov_base = bp
  9718. xcb_parts[xcb_parts_idx].Fiov_len = uint64(xcb_pad)
  9719. xcb_parts_idx++
  9720. xcb_pad = uint32(0)
  9721. }
  9722. xcb_block_len = uint32(0)
  9723. xcb_padding_offset = uint32(0)
  9724. if libc.UintptrFromInt32(0) == xcb_out {
  9725. /* allocate memory */
  9726. xcb_out = libc.Xmalloc(tls, uint64(xcb_buffer_len))
  9727. *(*uintptr)(unsafe.Pointer(_buffer)) = xcb_out
  9728. }
  9729. xcb_tmp = xcb_out
  9730. i = uint32(0)
  9731. for {
  9732. if !(i < xcb_parts_idx) {
  9733. break
  9734. }
  9735. if uintptr(0) != xcb_parts[i].Fiov_base && uint64(0) != xcb_parts[i].Fiov_len {
  9736. libc.Xmemcpy(tls, xcb_tmp, xcb_parts[i].Fiov_base, xcb_parts[i].Fiov_len)
  9737. }
  9738. if uint64(0) != xcb_parts[i].Fiov_len {
  9739. xcb_tmp += uintptr(xcb_parts[i].Fiov_len)
  9740. }
  9741. goto _1
  9742. _1:
  9743. ;
  9744. i++
  9745. }
  9746. return libc.Int32FromUint32(xcb_buffer_len)
  9747. }
  9748. func Xxcb_create_window_value_list_unpack(tls *libc.TLS, _buffer uintptr, value_mask Tuint32_t, _aux uintptr) (r int32) {
  9749. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset uint32
  9750. var xcb_tmp uintptr
  9751. _, _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset, xcb_tmp
  9752. xcb_tmp = _buffer
  9753. xcb_buffer_len = uint32(0)
  9754. xcb_block_len = uint32(0)
  9755. xcb_pad = uint32(0)
  9756. xcb_align_to = uint32(0)
  9757. xcb_padding_offset = uint32(0)
  9758. if value_mask&uint32(_XCB_CW_BACK_PIXMAP) != 0 {
  9759. /* xcb_create_window_value_list_t.background_pixmap */
  9760. (*Txcb_create_window_value_list_t)(unsafe.Pointer(_aux)).Fbackground_pixmap = *(*Txcb_pixmap_t)(unsafe.Pointer(xcb_tmp))
  9761. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9762. xcb_tmp += uintptr(4)
  9763. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9764. }
  9765. if value_mask&uint32(_XCB_CW_BACK_PIXEL) != 0 {
  9766. /* xcb_create_window_value_list_t.background_pixel */
  9767. (*Txcb_create_window_value_list_t)(unsafe.Pointer(_aux)).Fbackground_pixel = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  9768. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9769. xcb_tmp += uintptr(4)
  9770. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9771. }
  9772. if value_mask&uint32(_XCB_CW_BORDER_PIXMAP) != 0 {
  9773. /* xcb_create_window_value_list_t.border_pixmap */
  9774. (*Txcb_create_window_value_list_t)(unsafe.Pointer(_aux)).Fborder_pixmap = *(*Txcb_pixmap_t)(unsafe.Pointer(xcb_tmp))
  9775. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9776. xcb_tmp += uintptr(4)
  9777. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9778. }
  9779. if value_mask&uint32(_XCB_CW_BORDER_PIXEL) != 0 {
  9780. /* xcb_create_window_value_list_t.border_pixel */
  9781. (*Txcb_create_window_value_list_t)(unsafe.Pointer(_aux)).Fborder_pixel = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  9782. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9783. xcb_tmp += uintptr(4)
  9784. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9785. }
  9786. if value_mask&uint32(_XCB_CW_BIT_GRAVITY) != 0 {
  9787. /* xcb_create_window_value_list_t.bit_gravity */
  9788. (*Txcb_create_window_value_list_t)(unsafe.Pointer(_aux)).Fbit_gravity = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  9789. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9790. xcb_tmp += uintptr(4)
  9791. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9792. }
  9793. if value_mask&uint32(_XCB_CW_WIN_GRAVITY) != 0 {
  9794. /* xcb_create_window_value_list_t.win_gravity */
  9795. (*Txcb_create_window_value_list_t)(unsafe.Pointer(_aux)).Fwin_gravity = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  9796. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9797. xcb_tmp += uintptr(4)
  9798. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9799. }
  9800. if value_mask&uint32(_XCB_CW_BACKING_STORE) != 0 {
  9801. /* xcb_create_window_value_list_t.backing_store */
  9802. (*Txcb_create_window_value_list_t)(unsafe.Pointer(_aux)).Fbacking_store = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  9803. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9804. xcb_tmp += uintptr(4)
  9805. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9806. }
  9807. if value_mask&uint32(_XCB_CW_BACKING_PLANES) != 0 {
  9808. /* xcb_create_window_value_list_t.backing_planes */
  9809. (*Txcb_create_window_value_list_t)(unsafe.Pointer(_aux)).Fbacking_planes = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  9810. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9811. xcb_tmp += uintptr(4)
  9812. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9813. }
  9814. if value_mask&uint32(_XCB_CW_BACKING_PIXEL) != 0 {
  9815. /* xcb_create_window_value_list_t.backing_pixel */
  9816. (*Txcb_create_window_value_list_t)(unsafe.Pointer(_aux)).Fbacking_pixel = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  9817. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9818. xcb_tmp += uintptr(4)
  9819. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9820. }
  9821. if value_mask&uint32(_XCB_CW_OVERRIDE_REDIRECT) != 0 {
  9822. /* xcb_create_window_value_list_t.override_redirect */
  9823. (*Txcb_create_window_value_list_t)(unsafe.Pointer(_aux)).Foverride_redirect = *(*Txcb_bool32_t)(unsafe.Pointer(xcb_tmp))
  9824. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9825. xcb_tmp += uintptr(4)
  9826. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9827. }
  9828. if value_mask&uint32(_XCB_CW_SAVE_UNDER) != 0 {
  9829. /* xcb_create_window_value_list_t.save_under */
  9830. (*Txcb_create_window_value_list_t)(unsafe.Pointer(_aux)).Fsave_under = *(*Txcb_bool32_t)(unsafe.Pointer(xcb_tmp))
  9831. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9832. xcb_tmp += uintptr(4)
  9833. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9834. }
  9835. if value_mask&uint32(_XCB_CW_EVENT_MASK) != 0 {
  9836. /* xcb_create_window_value_list_t.event_mask */
  9837. (*Txcb_create_window_value_list_t)(unsafe.Pointer(_aux)).Fevent_mask = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  9838. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9839. xcb_tmp += uintptr(4)
  9840. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9841. }
  9842. if value_mask&uint32(_XCB_CW_DONT_PROPAGATE) != 0 {
  9843. /* xcb_create_window_value_list_t.do_not_propogate_mask */
  9844. (*Txcb_create_window_value_list_t)(unsafe.Pointer(_aux)).Fdo_not_propogate_mask = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  9845. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9846. xcb_tmp += uintptr(4)
  9847. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9848. }
  9849. if value_mask&uint32(_XCB_CW_COLORMAP) != 0 {
  9850. /* xcb_create_window_value_list_t.colormap */
  9851. (*Txcb_create_window_value_list_t)(unsafe.Pointer(_aux)).Fcolormap = *(*Txcb_colormap_t)(unsafe.Pointer(xcb_tmp))
  9852. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9853. xcb_tmp += uintptr(4)
  9854. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9855. }
  9856. if value_mask&uint32(_XCB_CW_CURSOR) != 0 {
  9857. /* xcb_create_window_value_list_t.cursor */
  9858. (*Txcb_create_window_value_list_t)(unsafe.Pointer(_aux)).Fcursor = *(*Txcb_cursor_t)(unsafe.Pointer(xcb_tmp))
  9859. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  9860. xcb_tmp += uintptr(4)
  9861. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  9862. }
  9863. /* insert padding */
  9864. xcb_pad = -(xcb_block_len + xcb_padding_offset) & (xcb_align_to - uint32(1))
  9865. xcb_buffer_len += xcb_block_len + xcb_pad
  9866. if uint32(0) != xcb_pad {
  9867. xcb_tmp += uintptr(xcb_pad)
  9868. xcb_pad = uint32(0)
  9869. }
  9870. xcb_block_len = uint32(0)
  9871. xcb_padding_offset = uint32(0)
  9872. return libc.Int32FromUint32(xcb_buffer_len)
  9873. }
  9874. func Xxcb_create_window_value_list_sizeof(tls *libc.TLS, _buffer uintptr, value_mask Tuint32_t) (r int32) {
  9875. bp := tls.Alloc(64)
  9876. defer tls.Free(64)
  9877. var _ /* _aux at bp+0 */ Txcb_create_window_value_list_t
  9878. return Xxcb_create_window_value_list_unpack(tls, _buffer, value_mask, bp)
  9879. }
  9880. func Xxcb_create_window_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  9881. var _aux, xcb_tmp uintptr
  9882. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  9883. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  9884. xcb_tmp = _buffer
  9885. _aux = _buffer
  9886. xcb_buffer_len = uint32(0)
  9887. xcb_block_len = uint32(0)
  9888. xcb_pad = uint32(0)
  9889. xcb_align_to = uint32(0)
  9890. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(32))
  9891. xcb_tmp += uintptr(xcb_block_len)
  9892. xcb_buffer_len += xcb_block_len
  9893. xcb_block_len = uint32(0)
  9894. /* value_list */
  9895. xcb_block_len += libc.Uint32FromInt32(Xxcb_create_window_value_list_sizeof(tls, xcb_tmp, (*Txcb_create_window_request_t)(unsafe.Pointer(_aux)).Fvalue_mask))
  9896. xcb_tmp += uintptr(xcb_block_len)
  9897. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  9898. /* insert padding */
  9899. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  9900. xcb_buffer_len += xcb_block_len + xcb_pad
  9901. if uint32(0) != xcb_pad {
  9902. xcb_tmp += uintptr(xcb_pad)
  9903. xcb_pad = uint32(0)
  9904. }
  9905. xcb_block_len = uint32(0)
  9906. return libc.Int32FromUint32(xcb_buffer_len)
  9907. }
  9908. func Xxcb_create_window_checked(tls *libc.TLS, c uintptr, depth Tuint8_t, wid Txcb_window_t, parent Txcb_window_t, x Tint16_t, y Tint16_t, width Tuint16_t, height Tuint16_t, border_width Tuint16_t, _class Tuint16_t, visual Txcb_visualid_t, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  9909. bp := tls.Alloc(112)
  9910. defer tls.Free(112)
  9911. var xcb_ret Txcb_void_cookie_t
  9912. var _ /* xcb_out at bp+80 */ Txcb_create_window_request_t
  9913. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  9914. _ = xcb_ret
  9915. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fdepth = depth
  9916. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fwid = wid
  9917. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fparent = parent
  9918. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fx = x
  9919. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fy = y
  9920. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fwidth = width
  9921. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fheight = height
  9922. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fborder_width = border_width
  9923. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).F_class = _class
  9924. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fvisual = visual
  9925. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  9926. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  9927. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(32)
  9928. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  9929. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  9930. /* xcb_create_window_value_list_t value_list */
  9931. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = value_list
  9932. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_create_window_value_list_sizeof(tls, value_list, value_mask))
  9933. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req)))
  9934. return xcb_ret
  9935. }
  9936. var _xcb_req = Txcb_protocol_request_t{
  9937. Fcount: uint64(3),
  9938. Fopcode: uint8(m_XCB_CREATE_WINDOW),
  9939. Fisvoid: uint8(1),
  9940. }
  9941. func Xxcb_create_window(tls *libc.TLS, c uintptr, depth Tuint8_t, wid Txcb_window_t, parent Txcb_window_t, x Tint16_t, y Tint16_t, width Tuint16_t, height Tuint16_t, border_width Tuint16_t, _class Tuint16_t, visual Txcb_visualid_t, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  9942. bp := tls.Alloc(112)
  9943. defer tls.Free(112)
  9944. var xcb_ret Txcb_void_cookie_t
  9945. var _ /* xcb_out at bp+80 */ Txcb_create_window_request_t
  9946. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  9947. _ = xcb_ret
  9948. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fdepth = depth
  9949. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fwid = wid
  9950. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fparent = parent
  9951. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fx = x
  9952. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fy = y
  9953. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fwidth = width
  9954. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fheight = height
  9955. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fborder_width = border_width
  9956. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).F_class = _class
  9957. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fvisual = visual
  9958. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  9959. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  9960. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(32)
  9961. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  9962. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  9963. /* xcb_create_window_value_list_t value_list */
  9964. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = value_list
  9965. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_create_window_value_list_sizeof(tls, value_list, value_mask))
  9966. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req1)))
  9967. return xcb_ret
  9968. }
  9969. var _xcb_req1 = Txcb_protocol_request_t{
  9970. Fcount: uint64(3),
  9971. Fopcode: uint8(m_XCB_CREATE_WINDOW),
  9972. Fisvoid: uint8(1),
  9973. }
  9974. func Xxcb_create_window_aux_checked(tls *libc.TLS, c uintptr, depth Tuint8_t, wid Txcb_window_t, parent Txcb_window_t, x Tint16_t, y Tint16_t, width Tuint16_t, height Tuint16_t, border_width Tuint16_t, _class Tuint16_t, visual Txcb_visualid_t, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  9975. bp := tls.Alloc(128)
  9976. defer tls.Free(128)
  9977. var xcb_ret Txcb_void_cookie_t
  9978. var _ /* xcb_aux0 at bp+112 */ uintptr
  9979. var _ /* xcb_out at bp+80 */ Txcb_create_window_request_t
  9980. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  9981. _ = xcb_ret
  9982. *(*uintptr)(unsafe.Pointer(bp + 112)) = uintptr(0)
  9983. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fdepth = depth
  9984. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fwid = wid
  9985. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fparent = parent
  9986. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fx = x
  9987. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fy = y
  9988. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fwidth = width
  9989. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fheight = height
  9990. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fborder_width = border_width
  9991. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).F_class = _class
  9992. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fvisual = visual
  9993. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  9994. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  9995. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(32)
  9996. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  9997. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  9998. /* xcb_create_window_value_list_t value_list */
  9999. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_create_window_value_list_serialize(tls, bp+112, value_mask, value_list))
  10000. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = *(*uintptr)(unsafe.Pointer(bp + 112))
  10001. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req2)))
  10002. libc.Xfree(tls, *(*uintptr)(unsafe.Pointer(bp + 112)))
  10003. return xcb_ret
  10004. }
  10005. var _xcb_req2 = Txcb_protocol_request_t{
  10006. Fcount: uint64(3),
  10007. Fopcode: uint8(m_XCB_CREATE_WINDOW),
  10008. Fisvoid: uint8(1),
  10009. }
  10010. func Xxcb_create_window_aux(tls *libc.TLS, c uintptr, depth Tuint8_t, wid Txcb_window_t, parent Txcb_window_t, x Tint16_t, y Tint16_t, width Tuint16_t, height Tuint16_t, border_width Tuint16_t, _class Tuint16_t, visual Txcb_visualid_t, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  10011. bp := tls.Alloc(128)
  10012. defer tls.Free(128)
  10013. var xcb_ret Txcb_void_cookie_t
  10014. var _ /* xcb_aux0 at bp+112 */ uintptr
  10015. var _ /* xcb_out at bp+80 */ Txcb_create_window_request_t
  10016. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  10017. _ = xcb_ret
  10018. *(*uintptr)(unsafe.Pointer(bp + 112)) = uintptr(0)
  10019. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fdepth = depth
  10020. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fwid = wid
  10021. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fparent = parent
  10022. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fx = x
  10023. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fy = y
  10024. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fwidth = width
  10025. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fheight = height
  10026. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fborder_width = border_width
  10027. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).F_class = _class
  10028. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fvisual = visual
  10029. (*(*Txcb_create_window_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  10030. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  10031. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(32)
  10032. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10033. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10034. /* xcb_create_window_value_list_t value_list */
  10035. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_create_window_value_list_serialize(tls, bp+112, value_mask, value_list))
  10036. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = *(*uintptr)(unsafe.Pointer(bp + 112))
  10037. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req3)))
  10038. libc.Xfree(tls, *(*uintptr)(unsafe.Pointer(bp + 112)))
  10039. return xcb_ret
  10040. }
  10041. var _xcb_req3 = Txcb_protocol_request_t{
  10042. Fcount: uint64(3),
  10043. Fopcode: uint8(m_XCB_CREATE_WINDOW),
  10044. Fisvoid: uint8(1),
  10045. }
  10046. func Xxcb_create_window_value_list(tls *libc.TLS, R uintptr) (r uintptr) {
  10047. return R + libc.UintptrFromInt32(1)*32
  10048. }
  10049. func Xxcb_change_window_attributes_value_list_serialize(tls *libc.TLS, _buffer uintptr, value_mask Tuint32_t, _aux uintptr) (r int32) {
  10050. bp := tls.Alloc(16)
  10051. defer tls.Free(16)
  10052. var i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset, xcb_parts_idx uint32
  10053. var xcb_out, xcb_tmp uintptr
  10054. var xcb_parts [16]Tiovec
  10055. var _ /* xcb_pad0 at bp+0 */ [3]int8
  10056. _, _, _, _, _, _, _, _, _, _ = i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_out, xcb_pad, xcb_padding_offset, xcb_parts, xcb_parts_idx, xcb_tmp
  10057. xcb_out = *(*uintptr)(unsafe.Pointer(_buffer))
  10058. xcb_buffer_len = uint32(0)
  10059. xcb_align_to = uint32(0)
  10060. xcb_padding_offset = uint32(0)
  10061. xcb_pad = uint32(0)
  10062. *(*[3]int8)(unsafe.Pointer(bp)) = [3]int8{}
  10063. xcb_parts_idx = uint32(0)
  10064. xcb_block_len = uint32(0)
  10065. if value_mask&uint32(_XCB_CW_BACK_PIXMAP) != 0 {
  10066. /* xcb_change_window_attributes_value_list_t.background_pixmap */
  10067. xcb_parts[xcb_parts_idx].Fiov_base = _aux
  10068. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10069. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10070. xcb_parts_idx++
  10071. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10072. }
  10073. if value_mask&uint32(_XCB_CW_BACK_PIXEL) != 0 {
  10074. /* xcb_change_window_attributes_value_list_t.background_pixel */
  10075. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 4
  10076. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10077. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10078. xcb_parts_idx++
  10079. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10080. }
  10081. if value_mask&uint32(_XCB_CW_BORDER_PIXMAP) != 0 {
  10082. /* xcb_change_window_attributes_value_list_t.border_pixmap */
  10083. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 8
  10084. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10085. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10086. xcb_parts_idx++
  10087. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10088. }
  10089. if value_mask&uint32(_XCB_CW_BORDER_PIXEL) != 0 {
  10090. /* xcb_change_window_attributes_value_list_t.border_pixel */
  10091. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 12
  10092. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10093. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10094. xcb_parts_idx++
  10095. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10096. }
  10097. if value_mask&uint32(_XCB_CW_BIT_GRAVITY) != 0 {
  10098. /* xcb_change_window_attributes_value_list_t.bit_gravity */
  10099. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 16
  10100. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10101. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10102. xcb_parts_idx++
  10103. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10104. }
  10105. if value_mask&uint32(_XCB_CW_WIN_GRAVITY) != 0 {
  10106. /* xcb_change_window_attributes_value_list_t.win_gravity */
  10107. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 20
  10108. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10109. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10110. xcb_parts_idx++
  10111. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10112. }
  10113. if value_mask&uint32(_XCB_CW_BACKING_STORE) != 0 {
  10114. /* xcb_change_window_attributes_value_list_t.backing_store */
  10115. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 24
  10116. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10117. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10118. xcb_parts_idx++
  10119. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10120. }
  10121. if value_mask&uint32(_XCB_CW_BACKING_PLANES) != 0 {
  10122. /* xcb_change_window_attributes_value_list_t.backing_planes */
  10123. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 28
  10124. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10125. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10126. xcb_parts_idx++
  10127. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10128. }
  10129. if value_mask&uint32(_XCB_CW_BACKING_PIXEL) != 0 {
  10130. /* xcb_change_window_attributes_value_list_t.backing_pixel */
  10131. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 32
  10132. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10133. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10134. xcb_parts_idx++
  10135. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10136. }
  10137. if value_mask&uint32(_XCB_CW_OVERRIDE_REDIRECT) != 0 {
  10138. /* xcb_change_window_attributes_value_list_t.override_redirect */
  10139. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 36
  10140. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10141. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10142. xcb_parts_idx++
  10143. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10144. }
  10145. if value_mask&uint32(_XCB_CW_SAVE_UNDER) != 0 {
  10146. /* xcb_change_window_attributes_value_list_t.save_under */
  10147. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 40
  10148. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10149. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10150. xcb_parts_idx++
  10151. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10152. }
  10153. if value_mask&uint32(_XCB_CW_EVENT_MASK) != 0 {
  10154. /* xcb_change_window_attributes_value_list_t.event_mask */
  10155. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 44
  10156. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10157. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10158. xcb_parts_idx++
  10159. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10160. }
  10161. if value_mask&uint32(_XCB_CW_DONT_PROPAGATE) != 0 {
  10162. /* xcb_change_window_attributes_value_list_t.do_not_propogate_mask */
  10163. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 48
  10164. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10165. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10166. xcb_parts_idx++
  10167. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10168. }
  10169. if value_mask&uint32(_XCB_CW_COLORMAP) != 0 {
  10170. /* xcb_change_window_attributes_value_list_t.colormap */
  10171. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 52
  10172. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10173. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10174. xcb_parts_idx++
  10175. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10176. }
  10177. if value_mask&uint32(_XCB_CW_CURSOR) != 0 {
  10178. /* xcb_change_window_attributes_value_list_t.cursor */
  10179. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 56
  10180. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10181. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10182. xcb_parts_idx++
  10183. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10184. }
  10185. /* insert padding */
  10186. xcb_pad = -(xcb_block_len + xcb_padding_offset) & (xcb_align_to - uint32(1))
  10187. xcb_buffer_len += xcb_block_len + xcb_pad
  10188. if uint32(0) != xcb_pad {
  10189. xcb_parts[xcb_parts_idx].Fiov_base = bp
  10190. xcb_parts[xcb_parts_idx].Fiov_len = uint64(xcb_pad)
  10191. xcb_parts_idx++
  10192. xcb_pad = uint32(0)
  10193. }
  10194. xcb_block_len = uint32(0)
  10195. xcb_padding_offset = uint32(0)
  10196. if libc.UintptrFromInt32(0) == xcb_out {
  10197. /* allocate memory */
  10198. xcb_out = libc.Xmalloc(tls, uint64(xcb_buffer_len))
  10199. *(*uintptr)(unsafe.Pointer(_buffer)) = xcb_out
  10200. }
  10201. xcb_tmp = xcb_out
  10202. i = uint32(0)
  10203. for {
  10204. if !(i < xcb_parts_idx) {
  10205. break
  10206. }
  10207. if uintptr(0) != xcb_parts[i].Fiov_base && uint64(0) != xcb_parts[i].Fiov_len {
  10208. libc.Xmemcpy(tls, xcb_tmp, xcb_parts[i].Fiov_base, xcb_parts[i].Fiov_len)
  10209. }
  10210. if uint64(0) != xcb_parts[i].Fiov_len {
  10211. xcb_tmp += uintptr(xcb_parts[i].Fiov_len)
  10212. }
  10213. goto _1
  10214. _1:
  10215. ;
  10216. i++
  10217. }
  10218. return libc.Int32FromUint32(xcb_buffer_len)
  10219. }
  10220. func Xxcb_change_window_attributes_value_list_unpack(tls *libc.TLS, _buffer uintptr, value_mask Tuint32_t, _aux uintptr) (r int32) {
  10221. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset uint32
  10222. var xcb_tmp uintptr
  10223. _, _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset, xcb_tmp
  10224. xcb_tmp = _buffer
  10225. xcb_buffer_len = uint32(0)
  10226. xcb_block_len = uint32(0)
  10227. xcb_pad = uint32(0)
  10228. xcb_align_to = uint32(0)
  10229. xcb_padding_offset = uint32(0)
  10230. if value_mask&uint32(_XCB_CW_BACK_PIXMAP) != 0 {
  10231. /* xcb_change_window_attributes_value_list_t.background_pixmap */
  10232. (*Txcb_change_window_attributes_value_list_t)(unsafe.Pointer(_aux)).Fbackground_pixmap = *(*Txcb_pixmap_t)(unsafe.Pointer(xcb_tmp))
  10233. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10234. xcb_tmp += uintptr(4)
  10235. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10236. }
  10237. if value_mask&uint32(_XCB_CW_BACK_PIXEL) != 0 {
  10238. /* xcb_change_window_attributes_value_list_t.background_pixel */
  10239. (*Txcb_change_window_attributes_value_list_t)(unsafe.Pointer(_aux)).Fbackground_pixel = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  10240. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10241. xcb_tmp += uintptr(4)
  10242. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10243. }
  10244. if value_mask&uint32(_XCB_CW_BORDER_PIXMAP) != 0 {
  10245. /* xcb_change_window_attributes_value_list_t.border_pixmap */
  10246. (*Txcb_change_window_attributes_value_list_t)(unsafe.Pointer(_aux)).Fborder_pixmap = *(*Txcb_pixmap_t)(unsafe.Pointer(xcb_tmp))
  10247. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10248. xcb_tmp += uintptr(4)
  10249. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10250. }
  10251. if value_mask&uint32(_XCB_CW_BORDER_PIXEL) != 0 {
  10252. /* xcb_change_window_attributes_value_list_t.border_pixel */
  10253. (*Txcb_change_window_attributes_value_list_t)(unsafe.Pointer(_aux)).Fborder_pixel = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  10254. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10255. xcb_tmp += uintptr(4)
  10256. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10257. }
  10258. if value_mask&uint32(_XCB_CW_BIT_GRAVITY) != 0 {
  10259. /* xcb_change_window_attributes_value_list_t.bit_gravity */
  10260. (*Txcb_change_window_attributes_value_list_t)(unsafe.Pointer(_aux)).Fbit_gravity = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  10261. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10262. xcb_tmp += uintptr(4)
  10263. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10264. }
  10265. if value_mask&uint32(_XCB_CW_WIN_GRAVITY) != 0 {
  10266. /* xcb_change_window_attributes_value_list_t.win_gravity */
  10267. (*Txcb_change_window_attributes_value_list_t)(unsafe.Pointer(_aux)).Fwin_gravity = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  10268. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10269. xcb_tmp += uintptr(4)
  10270. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10271. }
  10272. if value_mask&uint32(_XCB_CW_BACKING_STORE) != 0 {
  10273. /* xcb_change_window_attributes_value_list_t.backing_store */
  10274. (*Txcb_change_window_attributes_value_list_t)(unsafe.Pointer(_aux)).Fbacking_store = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  10275. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10276. xcb_tmp += uintptr(4)
  10277. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10278. }
  10279. if value_mask&uint32(_XCB_CW_BACKING_PLANES) != 0 {
  10280. /* xcb_change_window_attributes_value_list_t.backing_planes */
  10281. (*Txcb_change_window_attributes_value_list_t)(unsafe.Pointer(_aux)).Fbacking_planes = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  10282. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10283. xcb_tmp += uintptr(4)
  10284. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10285. }
  10286. if value_mask&uint32(_XCB_CW_BACKING_PIXEL) != 0 {
  10287. /* xcb_change_window_attributes_value_list_t.backing_pixel */
  10288. (*Txcb_change_window_attributes_value_list_t)(unsafe.Pointer(_aux)).Fbacking_pixel = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  10289. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10290. xcb_tmp += uintptr(4)
  10291. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10292. }
  10293. if value_mask&uint32(_XCB_CW_OVERRIDE_REDIRECT) != 0 {
  10294. /* xcb_change_window_attributes_value_list_t.override_redirect */
  10295. (*Txcb_change_window_attributes_value_list_t)(unsafe.Pointer(_aux)).Foverride_redirect = *(*Txcb_bool32_t)(unsafe.Pointer(xcb_tmp))
  10296. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10297. xcb_tmp += uintptr(4)
  10298. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10299. }
  10300. if value_mask&uint32(_XCB_CW_SAVE_UNDER) != 0 {
  10301. /* xcb_change_window_attributes_value_list_t.save_under */
  10302. (*Txcb_change_window_attributes_value_list_t)(unsafe.Pointer(_aux)).Fsave_under = *(*Txcb_bool32_t)(unsafe.Pointer(xcb_tmp))
  10303. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10304. xcb_tmp += uintptr(4)
  10305. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10306. }
  10307. if value_mask&uint32(_XCB_CW_EVENT_MASK) != 0 {
  10308. /* xcb_change_window_attributes_value_list_t.event_mask */
  10309. (*Txcb_change_window_attributes_value_list_t)(unsafe.Pointer(_aux)).Fevent_mask = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  10310. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10311. xcb_tmp += uintptr(4)
  10312. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10313. }
  10314. if value_mask&uint32(_XCB_CW_DONT_PROPAGATE) != 0 {
  10315. /* xcb_change_window_attributes_value_list_t.do_not_propogate_mask */
  10316. (*Txcb_change_window_attributes_value_list_t)(unsafe.Pointer(_aux)).Fdo_not_propogate_mask = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  10317. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10318. xcb_tmp += uintptr(4)
  10319. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10320. }
  10321. if value_mask&uint32(_XCB_CW_COLORMAP) != 0 {
  10322. /* xcb_change_window_attributes_value_list_t.colormap */
  10323. (*Txcb_change_window_attributes_value_list_t)(unsafe.Pointer(_aux)).Fcolormap = *(*Txcb_colormap_t)(unsafe.Pointer(xcb_tmp))
  10324. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10325. xcb_tmp += uintptr(4)
  10326. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10327. }
  10328. if value_mask&uint32(_XCB_CW_CURSOR) != 0 {
  10329. /* xcb_change_window_attributes_value_list_t.cursor */
  10330. (*Txcb_change_window_attributes_value_list_t)(unsafe.Pointer(_aux)).Fcursor = *(*Txcb_cursor_t)(unsafe.Pointer(xcb_tmp))
  10331. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10332. xcb_tmp += uintptr(4)
  10333. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10334. }
  10335. /* insert padding */
  10336. xcb_pad = -(xcb_block_len + xcb_padding_offset) & (xcb_align_to - uint32(1))
  10337. xcb_buffer_len += xcb_block_len + xcb_pad
  10338. if uint32(0) != xcb_pad {
  10339. xcb_tmp += uintptr(xcb_pad)
  10340. xcb_pad = uint32(0)
  10341. }
  10342. xcb_block_len = uint32(0)
  10343. xcb_padding_offset = uint32(0)
  10344. return libc.Int32FromUint32(xcb_buffer_len)
  10345. }
  10346. func Xxcb_change_window_attributes_value_list_sizeof(tls *libc.TLS, _buffer uintptr, value_mask Tuint32_t) (r int32) {
  10347. bp := tls.Alloc(64)
  10348. defer tls.Free(64)
  10349. var _ /* _aux at bp+0 */ Txcb_change_window_attributes_value_list_t
  10350. return Xxcb_change_window_attributes_value_list_unpack(tls, _buffer, value_mask, bp)
  10351. }
  10352. func Xxcb_change_window_attributes_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  10353. var _aux, xcb_tmp uintptr
  10354. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  10355. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  10356. xcb_tmp = _buffer
  10357. _aux = _buffer
  10358. xcb_buffer_len = uint32(0)
  10359. xcb_block_len = uint32(0)
  10360. xcb_pad = uint32(0)
  10361. xcb_align_to = uint32(0)
  10362. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  10363. xcb_tmp += uintptr(xcb_block_len)
  10364. xcb_buffer_len += xcb_block_len
  10365. xcb_block_len = uint32(0)
  10366. /* value_list */
  10367. xcb_block_len += libc.Uint32FromInt32(Xxcb_change_window_attributes_value_list_sizeof(tls, xcb_tmp, (*Txcb_change_window_attributes_request_t)(unsafe.Pointer(_aux)).Fvalue_mask))
  10368. xcb_tmp += uintptr(xcb_block_len)
  10369. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  10370. /* insert padding */
  10371. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  10372. xcb_buffer_len += xcb_block_len + xcb_pad
  10373. if uint32(0) != xcb_pad {
  10374. xcb_tmp += uintptr(xcb_pad)
  10375. xcb_pad = uint32(0)
  10376. }
  10377. xcb_block_len = uint32(0)
  10378. return libc.Int32FromUint32(xcb_buffer_len)
  10379. }
  10380. func Xxcb_change_window_attributes_checked(tls *libc.TLS, c uintptr, window Txcb_window_t, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  10381. bp := tls.Alloc(96)
  10382. defer tls.Free(96)
  10383. var xcb_ret Txcb_void_cookie_t
  10384. var _ /* xcb_out at bp+80 */ Txcb_change_window_attributes_request_t
  10385. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  10386. _ = xcb_ret
  10387. (*(*Txcb_change_window_attributes_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  10388. (*(*Txcb_change_window_attributes_request_t)(unsafe.Pointer(bp + 80))).Fwindow = window
  10389. (*(*Txcb_change_window_attributes_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  10390. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  10391. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  10392. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10393. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10394. /* xcb_change_window_attributes_value_list_t value_list */
  10395. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = value_list
  10396. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_change_window_attributes_value_list_sizeof(tls, value_list, value_mask))
  10397. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req4)))
  10398. return xcb_ret
  10399. }
  10400. var _xcb_req4 = Txcb_protocol_request_t{
  10401. Fcount: uint64(3),
  10402. Fopcode: uint8(m_XCB_CHANGE_WINDOW_ATTRIBUTES),
  10403. Fisvoid: uint8(1),
  10404. }
  10405. func Xxcb_change_window_attributes(tls *libc.TLS, c uintptr, window Txcb_window_t, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  10406. bp := tls.Alloc(96)
  10407. defer tls.Free(96)
  10408. var xcb_ret Txcb_void_cookie_t
  10409. var _ /* xcb_out at bp+80 */ Txcb_change_window_attributes_request_t
  10410. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  10411. _ = xcb_ret
  10412. (*(*Txcb_change_window_attributes_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  10413. (*(*Txcb_change_window_attributes_request_t)(unsafe.Pointer(bp + 80))).Fwindow = window
  10414. (*(*Txcb_change_window_attributes_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  10415. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  10416. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  10417. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10418. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10419. /* xcb_change_window_attributes_value_list_t value_list */
  10420. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = value_list
  10421. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_change_window_attributes_value_list_sizeof(tls, value_list, value_mask))
  10422. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req5)))
  10423. return xcb_ret
  10424. }
  10425. var _xcb_req5 = Txcb_protocol_request_t{
  10426. Fcount: uint64(3),
  10427. Fopcode: uint8(m_XCB_CHANGE_WINDOW_ATTRIBUTES),
  10428. Fisvoid: uint8(1),
  10429. }
  10430. func Xxcb_change_window_attributes_aux_checked(tls *libc.TLS, c uintptr, window Txcb_window_t, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  10431. bp := tls.Alloc(112)
  10432. defer tls.Free(112)
  10433. var xcb_ret Txcb_void_cookie_t
  10434. var _ /* xcb_aux0 at bp+96 */ uintptr
  10435. var _ /* xcb_out at bp+80 */ Txcb_change_window_attributes_request_t
  10436. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  10437. _ = xcb_ret
  10438. *(*uintptr)(unsafe.Pointer(bp + 96)) = uintptr(0)
  10439. (*(*Txcb_change_window_attributes_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  10440. (*(*Txcb_change_window_attributes_request_t)(unsafe.Pointer(bp + 80))).Fwindow = window
  10441. (*(*Txcb_change_window_attributes_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  10442. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  10443. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  10444. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10445. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10446. /* xcb_change_window_attributes_value_list_t value_list */
  10447. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_change_window_attributes_value_list_serialize(tls, bp+96, value_mask, value_list))
  10448. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = *(*uintptr)(unsafe.Pointer(bp + 96))
  10449. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req6)))
  10450. libc.Xfree(tls, *(*uintptr)(unsafe.Pointer(bp + 96)))
  10451. return xcb_ret
  10452. }
  10453. var _xcb_req6 = Txcb_protocol_request_t{
  10454. Fcount: uint64(3),
  10455. Fopcode: uint8(m_XCB_CHANGE_WINDOW_ATTRIBUTES),
  10456. Fisvoid: uint8(1),
  10457. }
  10458. func Xxcb_change_window_attributes_aux(tls *libc.TLS, c uintptr, window Txcb_window_t, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  10459. bp := tls.Alloc(112)
  10460. defer tls.Free(112)
  10461. var xcb_ret Txcb_void_cookie_t
  10462. var _ /* xcb_aux0 at bp+96 */ uintptr
  10463. var _ /* xcb_out at bp+80 */ Txcb_change_window_attributes_request_t
  10464. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  10465. _ = xcb_ret
  10466. *(*uintptr)(unsafe.Pointer(bp + 96)) = uintptr(0)
  10467. (*(*Txcb_change_window_attributes_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  10468. (*(*Txcb_change_window_attributes_request_t)(unsafe.Pointer(bp + 80))).Fwindow = window
  10469. (*(*Txcb_change_window_attributes_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  10470. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  10471. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  10472. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10473. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10474. /* xcb_change_window_attributes_value_list_t value_list */
  10475. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_change_window_attributes_value_list_serialize(tls, bp+96, value_mask, value_list))
  10476. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = *(*uintptr)(unsafe.Pointer(bp + 96))
  10477. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req7)))
  10478. libc.Xfree(tls, *(*uintptr)(unsafe.Pointer(bp + 96)))
  10479. return xcb_ret
  10480. }
  10481. var _xcb_req7 = Txcb_protocol_request_t{
  10482. Fcount: uint64(3),
  10483. Fopcode: uint8(m_XCB_CHANGE_WINDOW_ATTRIBUTES),
  10484. Fisvoid: uint8(1),
  10485. }
  10486. func Xxcb_change_window_attributes_value_list(tls *libc.TLS, R uintptr) (r uintptr) {
  10487. return R + libc.UintptrFromInt32(1)*12
  10488. }
  10489. func Xxcb_get_window_attributes(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_get_window_attributes_cookie_t) {
  10490. bp := tls.Alloc(80)
  10491. defer tls.Free(80)
  10492. var xcb_ret Txcb_get_window_attributes_cookie_t
  10493. var _ /* xcb_out at bp+64 */ Txcb_get_window_attributes_request_t
  10494. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10495. _ = xcb_ret
  10496. (*(*Txcb_get_window_attributes_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  10497. (*(*Txcb_get_window_attributes_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10498. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10499. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  10500. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10501. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10502. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req8)))
  10503. return xcb_ret
  10504. }
  10505. var _xcb_req8 = Txcb_protocol_request_t{
  10506. Fcount: uint64(2),
  10507. Fopcode: uint8(m_XCB_GET_WINDOW_ATTRIBUTES),
  10508. }
  10509. func Xxcb_get_window_attributes_unchecked(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_get_window_attributes_cookie_t) {
  10510. bp := tls.Alloc(80)
  10511. defer tls.Free(80)
  10512. var xcb_ret Txcb_get_window_attributes_cookie_t
  10513. var _ /* xcb_out at bp+64 */ Txcb_get_window_attributes_request_t
  10514. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10515. _ = xcb_ret
  10516. (*(*Txcb_get_window_attributes_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  10517. (*(*Txcb_get_window_attributes_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10518. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10519. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  10520. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10521. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10522. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req9)))
  10523. return xcb_ret
  10524. }
  10525. var _xcb_req9 = Txcb_protocol_request_t{
  10526. Fcount: uint64(2),
  10527. Fopcode: uint8(m_XCB_GET_WINDOW_ATTRIBUTES),
  10528. }
  10529. func Xxcb_get_window_attributes_reply(tls *libc.TLS, c uintptr, cookie Txcb_get_window_attributes_cookie_t, e uintptr) (r uintptr) {
  10530. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  10531. }
  10532. func Xxcb_destroy_window_checked(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_void_cookie_t) {
  10533. bp := tls.Alloc(80)
  10534. defer tls.Free(80)
  10535. var xcb_ret Txcb_void_cookie_t
  10536. var _ /* xcb_out at bp+64 */ Txcb_destroy_window_request_t
  10537. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10538. _ = xcb_ret
  10539. (*(*Txcb_destroy_window_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  10540. (*(*Txcb_destroy_window_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10541. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10542. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  10543. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10544. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10545. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req10)))
  10546. return xcb_ret
  10547. }
  10548. var _xcb_req10 = Txcb_protocol_request_t{
  10549. Fcount: uint64(2),
  10550. Fopcode: uint8(m_XCB_DESTROY_WINDOW),
  10551. Fisvoid: uint8(1),
  10552. }
  10553. func Xxcb_destroy_window(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_void_cookie_t) {
  10554. bp := tls.Alloc(80)
  10555. defer tls.Free(80)
  10556. var xcb_ret Txcb_void_cookie_t
  10557. var _ /* xcb_out at bp+64 */ Txcb_destroy_window_request_t
  10558. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10559. _ = xcb_ret
  10560. (*(*Txcb_destroy_window_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  10561. (*(*Txcb_destroy_window_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10562. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10563. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  10564. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10565. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10566. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req11)))
  10567. return xcb_ret
  10568. }
  10569. var _xcb_req11 = Txcb_protocol_request_t{
  10570. Fcount: uint64(2),
  10571. Fopcode: uint8(m_XCB_DESTROY_WINDOW),
  10572. Fisvoid: uint8(1),
  10573. }
  10574. func Xxcb_destroy_subwindows_checked(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_void_cookie_t) {
  10575. bp := tls.Alloc(80)
  10576. defer tls.Free(80)
  10577. var xcb_ret Txcb_void_cookie_t
  10578. var _ /* xcb_out at bp+64 */ Txcb_destroy_subwindows_request_t
  10579. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10580. _ = xcb_ret
  10581. (*(*Txcb_destroy_subwindows_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  10582. (*(*Txcb_destroy_subwindows_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10583. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10584. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  10585. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10586. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10587. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req12)))
  10588. return xcb_ret
  10589. }
  10590. var _xcb_req12 = Txcb_protocol_request_t{
  10591. Fcount: uint64(2),
  10592. Fopcode: uint8(m_XCB_DESTROY_SUBWINDOWS),
  10593. Fisvoid: uint8(1),
  10594. }
  10595. func Xxcb_destroy_subwindows(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_void_cookie_t) {
  10596. bp := tls.Alloc(80)
  10597. defer tls.Free(80)
  10598. var xcb_ret Txcb_void_cookie_t
  10599. var _ /* xcb_out at bp+64 */ Txcb_destroy_subwindows_request_t
  10600. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10601. _ = xcb_ret
  10602. (*(*Txcb_destroy_subwindows_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  10603. (*(*Txcb_destroy_subwindows_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10604. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10605. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  10606. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10607. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10608. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req13)))
  10609. return xcb_ret
  10610. }
  10611. var _xcb_req13 = Txcb_protocol_request_t{
  10612. Fcount: uint64(2),
  10613. Fopcode: uint8(m_XCB_DESTROY_SUBWINDOWS),
  10614. Fisvoid: uint8(1),
  10615. }
  10616. func Xxcb_change_save_set_checked(tls *libc.TLS, c uintptr, mode Tuint8_t, window Txcb_window_t) (r Txcb_void_cookie_t) {
  10617. bp := tls.Alloc(80)
  10618. defer tls.Free(80)
  10619. var xcb_ret Txcb_void_cookie_t
  10620. var _ /* xcb_out at bp+64 */ Txcb_change_save_set_request_t
  10621. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10622. _ = xcb_ret
  10623. (*(*Txcb_change_save_set_request_t)(unsafe.Pointer(bp + 64))).Fmode = mode
  10624. (*(*Txcb_change_save_set_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10625. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10626. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  10627. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10628. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10629. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req14)))
  10630. return xcb_ret
  10631. }
  10632. var _xcb_req14 = Txcb_protocol_request_t{
  10633. Fcount: uint64(2),
  10634. Fopcode: uint8(m_XCB_CHANGE_SAVE_SET),
  10635. Fisvoid: uint8(1),
  10636. }
  10637. func Xxcb_change_save_set(tls *libc.TLS, c uintptr, mode Tuint8_t, window Txcb_window_t) (r Txcb_void_cookie_t) {
  10638. bp := tls.Alloc(80)
  10639. defer tls.Free(80)
  10640. var xcb_ret Txcb_void_cookie_t
  10641. var _ /* xcb_out at bp+64 */ Txcb_change_save_set_request_t
  10642. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10643. _ = xcb_ret
  10644. (*(*Txcb_change_save_set_request_t)(unsafe.Pointer(bp + 64))).Fmode = mode
  10645. (*(*Txcb_change_save_set_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10646. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10647. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  10648. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10649. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10650. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req15)))
  10651. return xcb_ret
  10652. }
  10653. var _xcb_req15 = Txcb_protocol_request_t{
  10654. Fcount: uint64(2),
  10655. Fopcode: uint8(m_XCB_CHANGE_SAVE_SET),
  10656. Fisvoid: uint8(1),
  10657. }
  10658. func Xxcb_reparent_window_checked(tls *libc.TLS, c uintptr, window Txcb_window_t, parent Txcb_window_t, x Tint16_t, y Tint16_t) (r Txcb_void_cookie_t) {
  10659. bp := tls.Alloc(80)
  10660. defer tls.Free(80)
  10661. var xcb_ret Txcb_void_cookie_t
  10662. var _ /* xcb_out at bp+64 */ Txcb_reparent_window_request_t
  10663. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10664. _ = xcb_ret
  10665. (*(*Txcb_reparent_window_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  10666. (*(*Txcb_reparent_window_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10667. (*(*Txcb_reparent_window_request_t)(unsafe.Pointer(bp + 64))).Fparent = parent
  10668. (*(*Txcb_reparent_window_request_t)(unsafe.Pointer(bp + 64))).Fx = x
  10669. (*(*Txcb_reparent_window_request_t)(unsafe.Pointer(bp + 64))).Fy = y
  10670. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10671. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  10672. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10673. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10674. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req16)))
  10675. return xcb_ret
  10676. }
  10677. var _xcb_req16 = Txcb_protocol_request_t{
  10678. Fcount: uint64(2),
  10679. Fopcode: uint8(m_XCB_REPARENT_WINDOW),
  10680. Fisvoid: uint8(1),
  10681. }
  10682. func Xxcb_reparent_window(tls *libc.TLS, c uintptr, window Txcb_window_t, parent Txcb_window_t, x Tint16_t, y Tint16_t) (r Txcb_void_cookie_t) {
  10683. bp := tls.Alloc(80)
  10684. defer tls.Free(80)
  10685. var xcb_ret Txcb_void_cookie_t
  10686. var _ /* xcb_out at bp+64 */ Txcb_reparent_window_request_t
  10687. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10688. _ = xcb_ret
  10689. (*(*Txcb_reparent_window_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  10690. (*(*Txcb_reparent_window_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10691. (*(*Txcb_reparent_window_request_t)(unsafe.Pointer(bp + 64))).Fparent = parent
  10692. (*(*Txcb_reparent_window_request_t)(unsafe.Pointer(bp + 64))).Fx = x
  10693. (*(*Txcb_reparent_window_request_t)(unsafe.Pointer(bp + 64))).Fy = y
  10694. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10695. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  10696. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10697. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10698. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req17)))
  10699. return xcb_ret
  10700. }
  10701. var _xcb_req17 = Txcb_protocol_request_t{
  10702. Fcount: uint64(2),
  10703. Fopcode: uint8(m_XCB_REPARENT_WINDOW),
  10704. Fisvoid: uint8(1),
  10705. }
  10706. func Xxcb_map_window_checked(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_void_cookie_t) {
  10707. bp := tls.Alloc(80)
  10708. defer tls.Free(80)
  10709. var xcb_ret Txcb_void_cookie_t
  10710. var _ /* xcb_out at bp+64 */ Txcb_map_window_request_t
  10711. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10712. _ = xcb_ret
  10713. (*(*Txcb_map_window_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  10714. (*(*Txcb_map_window_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10715. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10716. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  10717. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10718. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10719. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req18)))
  10720. return xcb_ret
  10721. }
  10722. var _xcb_req18 = Txcb_protocol_request_t{
  10723. Fcount: uint64(2),
  10724. Fopcode: uint8(m_XCB_MAP_WINDOW),
  10725. Fisvoid: uint8(1),
  10726. }
  10727. func Xxcb_map_window(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_void_cookie_t) {
  10728. bp := tls.Alloc(80)
  10729. defer tls.Free(80)
  10730. var xcb_ret Txcb_void_cookie_t
  10731. var _ /* xcb_out at bp+64 */ Txcb_map_window_request_t
  10732. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10733. _ = xcb_ret
  10734. (*(*Txcb_map_window_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  10735. (*(*Txcb_map_window_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10736. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10737. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  10738. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10739. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10740. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req19)))
  10741. return xcb_ret
  10742. }
  10743. var _xcb_req19 = Txcb_protocol_request_t{
  10744. Fcount: uint64(2),
  10745. Fopcode: uint8(m_XCB_MAP_WINDOW),
  10746. Fisvoid: uint8(1),
  10747. }
  10748. func Xxcb_map_subwindows_checked(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_void_cookie_t) {
  10749. bp := tls.Alloc(80)
  10750. defer tls.Free(80)
  10751. var xcb_ret Txcb_void_cookie_t
  10752. var _ /* xcb_out at bp+64 */ Txcb_map_subwindows_request_t
  10753. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10754. _ = xcb_ret
  10755. (*(*Txcb_map_subwindows_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  10756. (*(*Txcb_map_subwindows_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10757. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10758. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  10759. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10760. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10761. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req20)))
  10762. return xcb_ret
  10763. }
  10764. var _xcb_req20 = Txcb_protocol_request_t{
  10765. Fcount: uint64(2),
  10766. Fopcode: uint8(m_XCB_MAP_SUBWINDOWS),
  10767. Fisvoid: uint8(1),
  10768. }
  10769. func Xxcb_map_subwindows(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_void_cookie_t) {
  10770. bp := tls.Alloc(80)
  10771. defer tls.Free(80)
  10772. var xcb_ret Txcb_void_cookie_t
  10773. var _ /* xcb_out at bp+64 */ Txcb_map_subwindows_request_t
  10774. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10775. _ = xcb_ret
  10776. (*(*Txcb_map_subwindows_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  10777. (*(*Txcb_map_subwindows_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10778. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10779. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  10780. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10781. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10782. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req21)))
  10783. return xcb_ret
  10784. }
  10785. var _xcb_req21 = Txcb_protocol_request_t{
  10786. Fcount: uint64(2),
  10787. Fopcode: uint8(m_XCB_MAP_SUBWINDOWS),
  10788. Fisvoid: uint8(1),
  10789. }
  10790. func Xxcb_unmap_window_checked(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_void_cookie_t) {
  10791. bp := tls.Alloc(80)
  10792. defer tls.Free(80)
  10793. var xcb_ret Txcb_void_cookie_t
  10794. var _ /* xcb_out at bp+64 */ Txcb_unmap_window_request_t
  10795. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10796. _ = xcb_ret
  10797. (*(*Txcb_unmap_window_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  10798. (*(*Txcb_unmap_window_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10799. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10800. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  10801. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10802. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10803. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req22)))
  10804. return xcb_ret
  10805. }
  10806. var _xcb_req22 = Txcb_protocol_request_t{
  10807. Fcount: uint64(2),
  10808. Fopcode: uint8(m_XCB_UNMAP_WINDOW),
  10809. Fisvoid: uint8(1),
  10810. }
  10811. func Xxcb_unmap_window(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_void_cookie_t) {
  10812. bp := tls.Alloc(80)
  10813. defer tls.Free(80)
  10814. var xcb_ret Txcb_void_cookie_t
  10815. var _ /* xcb_out at bp+64 */ Txcb_unmap_window_request_t
  10816. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10817. _ = xcb_ret
  10818. (*(*Txcb_unmap_window_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  10819. (*(*Txcb_unmap_window_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10820. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10821. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  10822. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10823. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10824. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req23)))
  10825. return xcb_ret
  10826. }
  10827. var _xcb_req23 = Txcb_protocol_request_t{
  10828. Fcount: uint64(2),
  10829. Fopcode: uint8(m_XCB_UNMAP_WINDOW),
  10830. Fisvoid: uint8(1),
  10831. }
  10832. func Xxcb_unmap_subwindows_checked(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_void_cookie_t) {
  10833. bp := tls.Alloc(80)
  10834. defer tls.Free(80)
  10835. var xcb_ret Txcb_void_cookie_t
  10836. var _ /* xcb_out at bp+64 */ Txcb_unmap_subwindows_request_t
  10837. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10838. _ = xcb_ret
  10839. (*(*Txcb_unmap_subwindows_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  10840. (*(*Txcb_unmap_subwindows_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10841. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10842. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  10843. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10844. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10845. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req24)))
  10846. return xcb_ret
  10847. }
  10848. var _xcb_req24 = Txcb_protocol_request_t{
  10849. Fcount: uint64(2),
  10850. Fopcode: uint8(m_XCB_UNMAP_SUBWINDOWS),
  10851. Fisvoid: uint8(1),
  10852. }
  10853. func Xxcb_unmap_subwindows(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_void_cookie_t) {
  10854. bp := tls.Alloc(80)
  10855. defer tls.Free(80)
  10856. var xcb_ret Txcb_void_cookie_t
  10857. var _ /* xcb_out at bp+64 */ Txcb_unmap_subwindows_request_t
  10858. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  10859. _ = xcb_ret
  10860. (*(*Txcb_unmap_subwindows_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  10861. (*(*Txcb_unmap_subwindows_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  10862. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  10863. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  10864. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  10865. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  10866. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req25)))
  10867. return xcb_ret
  10868. }
  10869. var _xcb_req25 = Txcb_protocol_request_t{
  10870. Fcount: uint64(2),
  10871. Fopcode: uint8(m_XCB_UNMAP_SUBWINDOWS),
  10872. Fisvoid: uint8(1),
  10873. }
  10874. func Xxcb_configure_window_value_list_serialize(tls *libc.TLS, _buffer uintptr, value_mask Tuint16_t, _aux uintptr) (r int32) {
  10875. bp := tls.Alloc(16)
  10876. defer tls.Free(16)
  10877. var i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset, xcb_parts_idx uint32
  10878. var xcb_out, xcb_tmp uintptr
  10879. var xcb_parts [8]Tiovec
  10880. var _ /* xcb_pad0 at bp+0 */ [3]int8
  10881. _, _, _, _, _, _, _, _, _, _ = i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_out, xcb_pad, xcb_padding_offset, xcb_parts, xcb_parts_idx, xcb_tmp
  10882. xcb_out = *(*uintptr)(unsafe.Pointer(_buffer))
  10883. xcb_buffer_len = uint32(0)
  10884. xcb_align_to = uint32(0)
  10885. xcb_padding_offset = uint32(0)
  10886. xcb_pad = uint32(0)
  10887. *(*[3]int8)(unsafe.Pointer(bp)) = [3]int8{}
  10888. xcb_parts_idx = uint32(0)
  10889. xcb_block_len = uint32(0)
  10890. if libc.Int32FromUint16(value_mask)&int32(_XCB_CONFIG_WINDOW_X) != 0 {
  10891. /* xcb_configure_window_value_list_t.x */
  10892. xcb_parts[xcb_parts_idx].Fiov_base = _aux
  10893. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10894. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10895. xcb_parts_idx++
  10896. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10897. }
  10898. if libc.Int32FromUint16(value_mask)&int32(_XCB_CONFIG_WINDOW_Y) != 0 {
  10899. /* xcb_configure_window_value_list_t.y */
  10900. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 4
  10901. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10902. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10903. xcb_parts_idx++
  10904. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10905. }
  10906. if libc.Int32FromUint16(value_mask)&int32(_XCB_CONFIG_WINDOW_WIDTH) != 0 {
  10907. /* xcb_configure_window_value_list_t.width */
  10908. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 8
  10909. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10910. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10911. xcb_parts_idx++
  10912. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10913. }
  10914. if libc.Int32FromUint16(value_mask)&int32(_XCB_CONFIG_WINDOW_HEIGHT) != 0 {
  10915. /* xcb_configure_window_value_list_t.height */
  10916. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 12
  10917. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10918. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10919. xcb_parts_idx++
  10920. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10921. }
  10922. if libc.Int32FromUint16(value_mask)&int32(_XCB_CONFIG_WINDOW_BORDER_WIDTH) != 0 {
  10923. /* xcb_configure_window_value_list_t.border_width */
  10924. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 16
  10925. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10926. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10927. xcb_parts_idx++
  10928. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10929. }
  10930. if libc.Int32FromUint16(value_mask)&int32(_XCB_CONFIG_WINDOW_SIBLING) != 0 {
  10931. /* xcb_configure_window_value_list_t.sibling */
  10932. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 20
  10933. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10934. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10935. xcb_parts_idx++
  10936. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10937. }
  10938. if libc.Int32FromUint16(value_mask)&int32(_XCB_CONFIG_WINDOW_STACK_MODE) != 0 {
  10939. /* xcb_configure_window_value_list_t.stack_mode */
  10940. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 24
  10941. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10942. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  10943. xcb_parts_idx++
  10944. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10945. }
  10946. /* insert padding */
  10947. xcb_pad = -(xcb_block_len + xcb_padding_offset) & (xcb_align_to - uint32(1))
  10948. xcb_buffer_len += xcb_block_len + xcb_pad
  10949. if uint32(0) != xcb_pad {
  10950. xcb_parts[xcb_parts_idx].Fiov_base = bp
  10951. xcb_parts[xcb_parts_idx].Fiov_len = uint64(xcb_pad)
  10952. xcb_parts_idx++
  10953. xcb_pad = uint32(0)
  10954. }
  10955. xcb_block_len = uint32(0)
  10956. xcb_padding_offset = uint32(0)
  10957. if libc.UintptrFromInt32(0) == xcb_out {
  10958. /* allocate memory */
  10959. xcb_out = libc.Xmalloc(tls, uint64(xcb_buffer_len))
  10960. *(*uintptr)(unsafe.Pointer(_buffer)) = xcb_out
  10961. }
  10962. xcb_tmp = xcb_out
  10963. i = uint32(0)
  10964. for {
  10965. if !(i < xcb_parts_idx) {
  10966. break
  10967. }
  10968. if uintptr(0) != xcb_parts[i].Fiov_base && uint64(0) != xcb_parts[i].Fiov_len {
  10969. libc.Xmemcpy(tls, xcb_tmp, xcb_parts[i].Fiov_base, xcb_parts[i].Fiov_len)
  10970. }
  10971. if uint64(0) != xcb_parts[i].Fiov_len {
  10972. xcb_tmp += uintptr(xcb_parts[i].Fiov_len)
  10973. }
  10974. goto _1
  10975. _1:
  10976. ;
  10977. i++
  10978. }
  10979. return libc.Int32FromUint32(xcb_buffer_len)
  10980. }
  10981. func Xxcb_configure_window_value_list_unpack(tls *libc.TLS, _buffer uintptr, value_mask Tuint16_t, _aux uintptr) (r int32) {
  10982. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset uint32
  10983. var xcb_tmp uintptr
  10984. _, _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset, xcb_tmp
  10985. xcb_tmp = _buffer
  10986. xcb_buffer_len = uint32(0)
  10987. xcb_block_len = uint32(0)
  10988. xcb_pad = uint32(0)
  10989. xcb_align_to = uint32(0)
  10990. xcb_padding_offset = uint32(0)
  10991. if libc.Int32FromUint16(value_mask)&int32(_XCB_CONFIG_WINDOW_X) != 0 {
  10992. /* xcb_configure_window_value_list_t.x */
  10993. (*Txcb_configure_window_value_list_t)(unsafe.Pointer(_aux)).Fx = *(*Tint32_t)(unsafe.Pointer(xcb_tmp))
  10994. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  10995. xcb_tmp += uintptr(4)
  10996. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  10997. }
  10998. if libc.Int32FromUint16(value_mask)&int32(_XCB_CONFIG_WINDOW_Y) != 0 {
  10999. /* xcb_configure_window_value_list_t.y */
  11000. (*Txcb_configure_window_value_list_t)(unsafe.Pointer(_aux)).Fy = *(*Tint32_t)(unsafe.Pointer(xcb_tmp))
  11001. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  11002. xcb_tmp += uintptr(4)
  11003. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  11004. }
  11005. if libc.Int32FromUint16(value_mask)&int32(_XCB_CONFIG_WINDOW_WIDTH) != 0 {
  11006. /* xcb_configure_window_value_list_t.width */
  11007. (*Txcb_configure_window_value_list_t)(unsafe.Pointer(_aux)).Fwidth = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  11008. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  11009. xcb_tmp += uintptr(4)
  11010. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  11011. }
  11012. if libc.Int32FromUint16(value_mask)&int32(_XCB_CONFIG_WINDOW_HEIGHT) != 0 {
  11013. /* xcb_configure_window_value_list_t.height */
  11014. (*Txcb_configure_window_value_list_t)(unsafe.Pointer(_aux)).Fheight = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  11015. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  11016. xcb_tmp += uintptr(4)
  11017. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  11018. }
  11019. if libc.Int32FromUint16(value_mask)&int32(_XCB_CONFIG_WINDOW_BORDER_WIDTH) != 0 {
  11020. /* xcb_configure_window_value_list_t.border_width */
  11021. (*Txcb_configure_window_value_list_t)(unsafe.Pointer(_aux)).Fborder_width = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  11022. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  11023. xcb_tmp += uintptr(4)
  11024. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  11025. }
  11026. if libc.Int32FromUint16(value_mask)&int32(_XCB_CONFIG_WINDOW_SIBLING) != 0 {
  11027. /* xcb_configure_window_value_list_t.sibling */
  11028. (*Txcb_configure_window_value_list_t)(unsafe.Pointer(_aux)).Fsibling = *(*Txcb_window_t)(unsafe.Pointer(xcb_tmp))
  11029. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  11030. xcb_tmp += uintptr(4)
  11031. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  11032. }
  11033. if libc.Int32FromUint16(value_mask)&int32(_XCB_CONFIG_WINDOW_STACK_MODE) != 0 {
  11034. /* xcb_configure_window_value_list_t.stack_mode */
  11035. (*Txcb_configure_window_value_list_t)(unsafe.Pointer(_aux)).Fstack_mode = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  11036. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  11037. xcb_tmp += uintptr(4)
  11038. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  11039. }
  11040. /* insert padding */
  11041. xcb_pad = -(xcb_block_len + xcb_padding_offset) & (xcb_align_to - uint32(1))
  11042. xcb_buffer_len += xcb_block_len + xcb_pad
  11043. if uint32(0) != xcb_pad {
  11044. xcb_tmp += uintptr(xcb_pad)
  11045. xcb_pad = uint32(0)
  11046. }
  11047. xcb_block_len = uint32(0)
  11048. xcb_padding_offset = uint32(0)
  11049. return libc.Int32FromUint32(xcb_buffer_len)
  11050. }
  11051. func Xxcb_configure_window_value_list_sizeof(tls *libc.TLS, _buffer uintptr, value_mask Tuint16_t) (r int32) {
  11052. bp := tls.Alloc(32)
  11053. defer tls.Free(32)
  11054. var _ /* _aux at bp+0 */ Txcb_configure_window_value_list_t
  11055. return Xxcb_configure_window_value_list_unpack(tls, _buffer, value_mask, bp)
  11056. }
  11057. func Xxcb_configure_window_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  11058. var _aux, xcb_tmp uintptr
  11059. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  11060. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  11061. xcb_tmp = _buffer
  11062. _aux = _buffer
  11063. xcb_buffer_len = uint32(0)
  11064. xcb_block_len = uint32(0)
  11065. xcb_pad = uint32(0)
  11066. xcb_align_to = uint32(0)
  11067. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  11068. xcb_tmp += uintptr(xcb_block_len)
  11069. xcb_buffer_len += xcb_block_len
  11070. xcb_block_len = uint32(0)
  11071. /* value_list */
  11072. xcb_block_len += libc.Uint32FromInt32(Xxcb_configure_window_value_list_sizeof(tls, xcb_tmp, (*Txcb_configure_window_request_t)(unsafe.Pointer(_aux)).Fvalue_mask))
  11073. xcb_tmp += uintptr(xcb_block_len)
  11074. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  11075. /* insert padding */
  11076. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  11077. xcb_buffer_len += xcb_block_len + xcb_pad
  11078. if uint32(0) != xcb_pad {
  11079. xcb_tmp += uintptr(xcb_pad)
  11080. xcb_pad = uint32(0)
  11081. }
  11082. xcb_block_len = uint32(0)
  11083. return libc.Int32FromUint32(xcb_buffer_len)
  11084. }
  11085. func Xxcb_configure_window_checked(tls *libc.TLS, c uintptr, window Txcb_window_t, value_mask Tuint16_t, value_list uintptr) (r Txcb_void_cookie_t) {
  11086. bp := tls.Alloc(96)
  11087. defer tls.Free(96)
  11088. var xcb_ret Txcb_void_cookie_t
  11089. var _ /* xcb_out at bp+80 */ Txcb_configure_window_request_t
  11090. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  11091. _ = xcb_ret
  11092. (*(*Txcb_configure_window_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  11093. (*(*Txcb_configure_window_request_t)(unsafe.Pointer(bp + 80))).Fwindow = window
  11094. (*(*Txcb_configure_window_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  11095. libc.Xmemset(tls, bp+80+10, 0, uint64(2))
  11096. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  11097. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  11098. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11099. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11100. /* xcb_configure_window_value_list_t value_list */
  11101. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = value_list
  11102. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_configure_window_value_list_sizeof(tls, value_list, value_mask))
  11103. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req26)))
  11104. return xcb_ret
  11105. }
  11106. var _xcb_req26 = Txcb_protocol_request_t{
  11107. Fcount: uint64(3),
  11108. Fopcode: uint8(m_XCB_CONFIGURE_WINDOW),
  11109. Fisvoid: uint8(1),
  11110. }
  11111. func Xxcb_configure_window(tls *libc.TLS, c uintptr, window Txcb_window_t, value_mask Tuint16_t, value_list uintptr) (r Txcb_void_cookie_t) {
  11112. bp := tls.Alloc(96)
  11113. defer tls.Free(96)
  11114. var xcb_ret Txcb_void_cookie_t
  11115. var _ /* xcb_out at bp+80 */ Txcb_configure_window_request_t
  11116. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  11117. _ = xcb_ret
  11118. (*(*Txcb_configure_window_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  11119. (*(*Txcb_configure_window_request_t)(unsafe.Pointer(bp + 80))).Fwindow = window
  11120. (*(*Txcb_configure_window_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  11121. libc.Xmemset(tls, bp+80+10, 0, uint64(2))
  11122. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  11123. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  11124. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11125. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11126. /* xcb_configure_window_value_list_t value_list */
  11127. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = value_list
  11128. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_configure_window_value_list_sizeof(tls, value_list, value_mask))
  11129. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req27)))
  11130. return xcb_ret
  11131. }
  11132. var _xcb_req27 = Txcb_protocol_request_t{
  11133. Fcount: uint64(3),
  11134. Fopcode: uint8(m_XCB_CONFIGURE_WINDOW),
  11135. Fisvoid: uint8(1),
  11136. }
  11137. func Xxcb_configure_window_aux_checked(tls *libc.TLS, c uintptr, window Txcb_window_t, value_mask Tuint16_t, value_list uintptr) (r Txcb_void_cookie_t) {
  11138. bp := tls.Alloc(112)
  11139. defer tls.Free(112)
  11140. var xcb_ret Txcb_void_cookie_t
  11141. var _ /* xcb_aux0 at bp+96 */ uintptr
  11142. var _ /* xcb_out at bp+80 */ Txcb_configure_window_request_t
  11143. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  11144. _ = xcb_ret
  11145. *(*uintptr)(unsafe.Pointer(bp + 96)) = uintptr(0)
  11146. (*(*Txcb_configure_window_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  11147. (*(*Txcb_configure_window_request_t)(unsafe.Pointer(bp + 80))).Fwindow = window
  11148. (*(*Txcb_configure_window_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  11149. libc.Xmemset(tls, bp+80+10, 0, uint64(2))
  11150. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  11151. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  11152. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11153. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11154. /* xcb_configure_window_value_list_t value_list */
  11155. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_configure_window_value_list_serialize(tls, bp+96, value_mask, value_list))
  11156. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = *(*uintptr)(unsafe.Pointer(bp + 96))
  11157. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req28)))
  11158. libc.Xfree(tls, *(*uintptr)(unsafe.Pointer(bp + 96)))
  11159. return xcb_ret
  11160. }
  11161. var _xcb_req28 = Txcb_protocol_request_t{
  11162. Fcount: uint64(3),
  11163. Fopcode: uint8(m_XCB_CONFIGURE_WINDOW),
  11164. Fisvoid: uint8(1),
  11165. }
  11166. func Xxcb_configure_window_aux(tls *libc.TLS, c uintptr, window Txcb_window_t, value_mask Tuint16_t, value_list uintptr) (r Txcb_void_cookie_t) {
  11167. bp := tls.Alloc(112)
  11168. defer tls.Free(112)
  11169. var xcb_ret Txcb_void_cookie_t
  11170. var _ /* xcb_aux0 at bp+96 */ uintptr
  11171. var _ /* xcb_out at bp+80 */ Txcb_configure_window_request_t
  11172. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  11173. _ = xcb_ret
  11174. *(*uintptr)(unsafe.Pointer(bp + 96)) = uintptr(0)
  11175. (*(*Txcb_configure_window_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  11176. (*(*Txcb_configure_window_request_t)(unsafe.Pointer(bp + 80))).Fwindow = window
  11177. (*(*Txcb_configure_window_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  11178. libc.Xmemset(tls, bp+80+10, 0, uint64(2))
  11179. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  11180. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  11181. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11182. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11183. /* xcb_configure_window_value_list_t value_list */
  11184. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_configure_window_value_list_serialize(tls, bp+96, value_mask, value_list))
  11185. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = *(*uintptr)(unsafe.Pointer(bp + 96))
  11186. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req29)))
  11187. libc.Xfree(tls, *(*uintptr)(unsafe.Pointer(bp + 96)))
  11188. return xcb_ret
  11189. }
  11190. var _xcb_req29 = Txcb_protocol_request_t{
  11191. Fcount: uint64(3),
  11192. Fopcode: uint8(m_XCB_CONFIGURE_WINDOW),
  11193. Fisvoid: uint8(1),
  11194. }
  11195. func Xxcb_configure_window_value_list(tls *libc.TLS, R uintptr) (r uintptr) {
  11196. return R + libc.UintptrFromInt32(1)*12
  11197. }
  11198. func Xxcb_circulate_window_checked(tls *libc.TLS, c uintptr, direction Tuint8_t, window Txcb_window_t) (r Txcb_void_cookie_t) {
  11199. bp := tls.Alloc(80)
  11200. defer tls.Free(80)
  11201. var xcb_ret Txcb_void_cookie_t
  11202. var _ /* xcb_out at bp+64 */ Txcb_circulate_window_request_t
  11203. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11204. _ = xcb_ret
  11205. (*(*Txcb_circulate_window_request_t)(unsafe.Pointer(bp + 64))).Fdirection = direction
  11206. (*(*Txcb_circulate_window_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  11207. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11208. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  11209. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11210. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11211. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req30)))
  11212. return xcb_ret
  11213. }
  11214. var _xcb_req30 = Txcb_protocol_request_t{
  11215. Fcount: uint64(2),
  11216. Fopcode: uint8(m_XCB_CIRCULATE_WINDOW),
  11217. Fisvoid: uint8(1),
  11218. }
  11219. func Xxcb_circulate_window(tls *libc.TLS, c uintptr, direction Tuint8_t, window Txcb_window_t) (r Txcb_void_cookie_t) {
  11220. bp := tls.Alloc(80)
  11221. defer tls.Free(80)
  11222. var xcb_ret Txcb_void_cookie_t
  11223. var _ /* xcb_out at bp+64 */ Txcb_circulate_window_request_t
  11224. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11225. _ = xcb_ret
  11226. (*(*Txcb_circulate_window_request_t)(unsafe.Pointer(bp + 64))).Fdirection = direction
  11227. (*(*Txcb_circulate_window_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  11228. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11229. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  11230. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11231. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11232. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req31)))
  11233. return xcb_ret
  11234. }
  11235. var _xcb_req31 = Txcb_protocol_request_t{
  11236. Fcount: uint64(2),
  11237. Fopcode: uint8(m_XCB_CIRCULATE_WINDOW),
  11238. Fisvoid: uint8(1),
  11239. }
  11240. func Xxcb_get_geometry(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t) (r Txcb_get_geometry_cookie_t) {
  11241. bp := tls.Alloc(80)
  11242. defer tls.Free(80)
  11243. var xcb_ret Txcb_get_geometry_cookie_t
  11244. var _ /* xcb_out at bp+64 */ Txcb_get_geometry_request_t
  11245. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11246. _ = xcb_ret
  11247. (*(*Txcb_get_geometry_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  11248. (*(*Txcb_get_geometry_request_t)(unsafe.Pointer(bp + 64))).Fdrawable = drawable
  11249. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11250. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  11251. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11252. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11253. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req32)))
  11254. return xcb_ret
  11255. }
  11256. var _xcb_req32 = Txcb_protocol_request_t{
  11257. Fcount: uint64(2),
  11258. Fopcode: uint8(m_XCB_GET_GEOMETRY),
  11259. }
  11260. func Xxcb_get_geometry_unchecked(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t) (r Txcb_get_geometry_cookie_t) {
  11261. bp := tls.Alloc(80)
  11262. defer tls.Free(80)
  11263. var xcb_ret Txcb_get_geometry_cookie_t
  11264. var _ /* xcb_out at bp+64 */ Txcb_get_geometry_request_t
  11265. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11266. _ = xcb_ret
  11267. (*(*Txcb_get_geometry_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  11268. (*(*Txcb_get_geometry_request_t)(unsafe.Pointer(bp + 64))).Fdrawable = drawable
  11269. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11270. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  11271. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11272. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11273. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req33)))
  11274. return xcb_ret
  11275. }
  11276. var _xcb_req33 = Txcb_protocol_request_t{
  11277. Fcount: uint64(2),
  11278. Fopcode: uint8(m_XCB_GET_GEOMETRY),
  11279. }
  11280. func Xxcb_get_geometry_reply(tls *libc.TLS, c uintptr, cookie Txcb_get_geometry_cookie_t, e uintptr) (r uintptr) {
  11281. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  11282. }
  11283. func Xxcb_query_tree_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  11284. var _aux, xcb_tmp uintptr
  11285. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  11286. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  11287. xcb_tmp = _buffer
  11288. _aux = _buffer
  11289. xcb_buffer_len = uint32(0)
  11290. xcb_block_len = uint32(0)
  11291. xcb_pad = uint32(0)
  11292. xcb_align_to = uint32(0)
  11293. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(32))
  11294. xcb_tmp += uintptr(xcb_block_len)
  11295. xcb_buffer_len += xcb_block_len
  11296. xcb_block_len = uint32(0)
  11297. /* children */
  11298. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_query_tree_reply_t)(unsafe.Pointer(_aux)).Fchildren_len)*libc.Uint64FromInt64(4))
  11299. xcb_tmp += uintptr(xcb_block_len)
  11300. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  11301. /* insert padding */
  11302. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  11303. xcb_buffer_len += xcb_block_len + xcb_pad
  11304. if uint32(0) != xcb_pad {
  11305. xcb_tmp += uintptr(xcb_pad)
  11306. xcb_pad = uint32(0)
  11307. }
  11308. xcb_block_len = uint32(0)
  11309. return libc.Int32FromUint32(xcb_buffer_len)
  11310. }
  11311. func Xxcb_query_tree(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_query_tree_cookie_t) {
  11312. bp := tls.Alloc(80)
  11313. defer tls.Free(80)
  11314. var xcb_ret Txcb_query_tree_cookie_t
  11315. var _ /* xcb_out at bp+64 */ Txcb_query_tree_request_t
  11316. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11317. _ = xcb_ret
  11318. (*(*Txcb_query_tree_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  11319. (*(*Txcb_query_tree_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  11320. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11321. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  11322. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11323. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11324. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req34)))
  11325. return xcb_ret
  11326. }
  11327. var _xcb_req34 = Txcb_protocol_request_t{
  11328. Fcount: uint64(2),
  11329. Fopcode: uint8(m_XCB_QUERY_TREE),
  11330. }
  11331. func Xxcb_query_tree_unchecked(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_query_tree_cookie_t) {
  11332. bp := tls.Alloc(80)
  11333. defer tls.Free(80)
  11334. var xcb_ret Txcb_query_tree_cookie_t
  11335. var _ /* xcb_out at bp+64 */ Txcb_query_tree_request_t
  11336. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11337. _ = xcb_ret
  11338. (*(*Txcb_query_tree_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  11339. (*(*Txcb_query_tree_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  11340. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11341. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  11342. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11343. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11344. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req35)))
  11345. return xcb_ret
  11346. }
  11347. var _xcb_req35 = Txcb_protocol_request_t{
  11348. Fcount: uint64(2),
  11349. Fopcode: uint8(m_XCB_QUERY_TREE),
  11350. }
  11351. func Xxcb_query_tree_children(tls *libc.TLS, R uintptr) (r uintptr) {
  11352. return R + libc.UintptrFromInt32(1)*32
  11353. }
  11354. func Xxcb_query_tree_children_length(tls *libc.TLS, R uintptr) (r int32) {
  11355. return libc.Int32FromUint16((*Txcb_query_tree_reply_t)(unsafe.Pointer(R)).Fchildren_len)
  11356. }
  11357. func Xxcb_query_tree_children_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  11358. var i Txcb_generic_iterator_t
  11359. _ = i
  11360. i.Fdata = R + libc.UintptrFromInt32(1)*32 + uintptr((*Txcb_query_tree_reply_t)(unsafe.Pointer(R)).Fchildren_len)*4
  11361. i.Frem = 0
  11362. i.Findex = int32(int64(i.Fdata) - int64(R))
  11363. return i
  11364. }
  11365. func Xxcb_query_tree_reply(tls *libc.TLS, c uintptr, cookie Txcb_query_tree_cookie_t, e uintptr) (r uintptr) {
  11366. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  11367. }
  11368. func Xxcb_intern_atom_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  11369. var _aux, xcb_tmp uintptr
  11370. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  11371. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  11372. xcb_tmp = _buffer
  11373. _aux = _buffer
  11374. xcb_buffer_len = uint32(0)
  11375. xcb_block_len = uint32(0)
  11376. xcb_pad = uint32(0)
  11377. xcb_align_to = uint32(0)
  11378. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(8))
  11379. xcb_tmp += uintptr(xcb_block_len)
  11380. xcb_buffer_len += xcb_block_len
  11381. xcb_block_len = uint32(0)
  11382. /* name */
  11383. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_intern_atom_request_t)(unsafe.Pointer(_aux)).Fname_len)*libc.Uint64FromInt64(1))
  11384. xcb_tmp += uintptr(xcb_block_len)
  11385. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  11386. /* insert padding */
  11387. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  11388. xcb_buffer_len += xcb_block_len + xcb_pad
  11389. if uint32(0) != xcb_pad {
  11390. xcb_tmp += uintptr(xcb_pad)
  11391. xcb_pad = uint32(0)
  11392. }
  11393. xcb_block_len = uint32(0)
  11394. return libc.Int32FromUint32(xcb_buffer_len)
  11395. }
  11396. func Xxcb_intern_atom(tls *libc.TLS, c uintptr, only_if_exists Tuint8_t, name_len Tuint16_t, name uintptr) (r Txcb_intern_atom_cookie_t) {
  11397. bp := tls.Alloc(112)
  11398. defer tls.Free(112)
  11399. var xcb_ret Txcb_intern_atom_cookie_t
  11400. var _ /* xcb_out at bp+96 */ Txcb_intern_atom_request_t
  11401. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  11402. _ = xcb_ret
  11403. (*(*Txcb_intern_atom_request_t)(unsafe.Pointer(bp + 96))).Fonly_if_exists = only_if_exists
  11404. (*(*Txcb_intern_atom_request_t)(unsafe.Pointer(bp + 96))).Fname_len = name_len
  11405. libc.Xmemset(tls, bp+96+6, 0, uint64(2))
  11406. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  11407. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  11408. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11409. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11410. /* char name */
  11411. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = name
  11412. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(name_len) * uint64(1)
  11413. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  11414. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  11415. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req36)))
  11416. return xcb_ret
  11417. }
  11418. var _xcb_req36 = Txcb_protocol_request_t{
  11419. Fcount: uint64(4),
  11420. Fopcode: uint8(m_XCB_INTERN_ATOM),
  11421. }
  11422. func Xxcb_intern_atom_unchecked(tls *libc.TLS, c uintptr, only_if_exists Tuint8_t, name_len Tuint16_t, name uintptr) (r Txcb_intern_atom_cookie_t) {
  11423. bp := tls.Alloc(112)
  11424. defer tls.Free(112)
  11425. var xcb_ret Txcb_intern_atom_cookie_t
  11426. var _ /* xcb_out at bp+96 */ Txcb_intern_atom_request_t
  11427. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  11428. _ = xcb_ret
  11429. (*(*Txcb_intern_atom_request_t)(unsafe.Pointer(bp + 96))).Fonly_if_exists = only_if_exists
  11430. (*(*Txcb_intern_atom_request_t)(unsafe.Pointer(bp + 96))).Fname_len = name_len
  11431. libc.Xmemset(tls, bp+96+6, 0, uint64(2))
  11432. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  11433. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  11434. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11435. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11436. /* char name */
  11437. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = name
  11438. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(name_len) * uint64(1)
  11439. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  11440. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  11441. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req37)))
  11442. return xcb_ret
  11443. }
  11444. var _xcb_req37 = Txcb_protocol_request_t{
  11445. Fcount: uint64(4),
  11446. Fopcode: uint8(m_XCB_INTERN_ATOM),
  11447. }
  11448. func Xxcb_intern_atom_reply(tls *libc.TLS, c uintptr, cookie Txcb_intern_atom_cookie_t, e uintptr) (r uintptr) {
  11449. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  11450. }
  11451. func Xxcb_get_atom_name_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  11452. var _aux, xcb_tmp uintptr
  11453. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  11454. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  11455. xcb_tmp = _buffer
  11456. _aux = _buffer
  11457. xcb_buffer_len = uint32(0)
  11458. xcb_block_len = uint32(0)
  11459. xcb_pad = uint32(0)
  11460. xcb_align_to = uint32(0)
  11461. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(32))
  11462. xcb_tmp += uintptr(xcb_block_len)
  11463. xcb_buffer_len += xcb_block_len
  11464. xcb_block_len = uint32(0)
  11465. /* name */
  11466. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_get_atom_name_reply_t)(unsafe.Pointer(_aux)).Fname_len)*libc.Uint64FromInt64(1))
  11467. xcb_tmp += uintptr(xcb_block_len)
  11468. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  11469. /* insert padding */
  11470. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  11471. xcb_buffer_len += xcb_block_len + xcb_pad
  11472. if uint32(0) != xcb_pad {
  11473. xcb_tmp += uintptr(xcb_pad)
  11474. xcb_pad = uint32(0)
  11475. }
  11476. xcb_block_len = uint32(0)
  11477. return libc.Int32FromUint32(xcb_buffer_len)
  11478. }
  11479. func Xxcb_get_atom_name(tls *libc.TLS, c uintptr, atom Txcb_atom_t) (r Txcb_get_atom_name_cookie_t) {
  11480. bp := tls.Alloc(80)
  11481. defer tls.Free(80)
  11482. var xcb_ret Txcb_get_atom_name_cookie_t
  11483. var _ /* xcb_out at bp+64 */ Txcb_get_atom_name_request_t
  11484. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11485. _ = xcb_ret
  11486. (*(*Txcb_get_atom_name_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  11487. (*(*Txcb_get_atom_name_request_t)(unsafe.Pointer(bp + 64))).Fatom = atom
  11488. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11489. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  11490. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11491. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11492. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req38)))
  11493. return xcb_ret
  11494. }
  11495. var _xcb_req38 = Txcb_protocol_request_t{
  11496. Fcount: uint64(2),
  11497. Fopcode: uint8(m_XCB_GET_ATOM_NAME),
  11498. }
  11499. func Xxcb_get_atom_name_unchecked(tls *libc.TLS, c uintptr, atom Txcb_atom_t) (r Txcb_get_atom_name_cookie_t) {
  11500. bp := tls.Alloc(80)
  11501. defer tls.Free(80)
  11502. var xcb_ret Txcb_get_atom_name_cookie_t
  11503. var _ /* xcb_out at bp+64 */ Txcb_get_atom_name_request_t
  11504. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11505. _ = xcb_ret
  11506. (*(*Txcb_get_atom_name_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  11507. (*(*Txcb_get_atom_name_request_t)(unsafe.Pointer(bp + 64))).Fatom = atom
  11508. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11509. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  11510. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11511. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11512. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req39)))
  11513. return xcb_ret
  11514. }
  11515. var _xcb_req39 = Txcb_protocol_request_t{
  11516. Fcount: uint64(2),
  11517. Fopcode: uint8(m_XCB_GET_ATOM_NAME),
  11518. }
  11519. func Xxcb_get_atom_name_name(tls *libc.TLS, R uintptr) (r uintptr) {
  11520. return R + libc.UintptrFromInt32(1)*32
  11521. }
  11522. func Xxcb_get_atom_name_name_length(tls *libc.TLS, R uintptr) (r int32) {
  11523. return libc.Int32FromUint16((*Txcb_get_atom_name_reply_t)(unsafe.Pointer(R)).Fname_len)
  11524. }
  11525. func Xxcb_get_atom_name_name_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  11526. var i Txcb_generic_iterator_t
  11527. _ = i
  11528. i.Fdata = R + libc.UintptrFromInt32(1)*32 + uintptr((*Txcb_get_atom_name_reply_t)(unsafe.Pointer(R)).Fname_len)
  11529. i.Frem = 0
  11530. i.Findex = int32(int64(i.Fdata) - int64(R))
  11531. return i
  11532. }
  11533. func Xxcb_get_atom_name_reply(tls *libc.TLS, c uintptr, cookie Txcb_get_atom_name_cookie_t, e uintptr) (r uintptr) {
  11534. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  11535. }
  11536. func Xxcb_change_property_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  11537. var _aux, xcb_tmp uintptr
  11538. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  11539. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  11540. xcb_tmp = _buffer
  11541. _aux = _buffer
  11542. xcb_buffer_len = uint32(0)
  11543. xcb_block_len = uint32(0)
  11544. xcb_pad = uint32(0)
  11545. xcb_align_to = uint32(0)
  11546. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(24))
  11547. xcb_tmp += uintptr(xcb_block_len)
  11548. xcb_buffer_len += xcb_block_len
  11549. xcb_block_len = uint32(0)
  11550. /* data */
  11551. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_change_property_request_t)(unsafe.Pointer(_aux)).Fdata_len*uint32((*Txcb_change_property_request_t)(unsafe.Pointer(_aux)).Fformat)/libc.Uint32FromInt32(8))*libc.Uint64FromInt64(1))
  11552. xcb_tmp += uintptr(xcb_block_len)
  11553. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  11554. /* insert padding */
  11555. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  11556. xcb_buffer_len += xcb_block_len + xcb_pad
  11557. if uint32(0) != xcb_pad {
  11558. xcb_tmp += uintptr(xcb_pad)
  11559. xcb_pad = uint32(0)
  11560. }
  11561. xcb_block_len = uint32(0)
  11562. return libc.Int32FromUint32(xcb_buffer_len)
  11563. }
  11564. func Xxcb_change_property_checked(tls *libc.TLS, c uintptr, mode Tuint8_t, window Txcb_window_t, property Txcb_atom_t, type1 Txcb_atom_t, format Tuint8_t, data_len Tuint32_t, data uintptr) (r Txcb_void_cookie_t) {
  11565. bp := tls.Alloc(128)
  11566. defer tls.Free(128)
  11567. var xcb_ret Txcb_void_cookie_t
  11568. var _ /* xcb_out at bp+96 */ Txcb_change_property_request_t
  11569. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  11570. _ = xcb_ret
  11571. (*(*Txcb_change_property_request_t)(unsafe.Pointer(bp + 96))).Fmode = mode
  11572. (*(*Txcb_change_property_request_t)(unsafe.Pointer(bp + 96))).Fwindow = window
  11573. (*(*Txcb_change_property_request_t)(unsafe.Pointer(bp + 96))).Fproperty = property
  11574. (*(*Txcb_change_property_request_t)(unsafe.Pointer(bp + 96))).Ftype1 = type1
  11575. (*(*Txcb_change_property_request_t)(unsafe.Pointer(bp + 96))).Fformat = format
  11576. libc.Xmemset(tls, bp+96+17, 0, uint64(3))
  11577. (*(*Txcb_change_property_request_t)(unsafe.Pointer(bp + 96))).Fdata_len = data_len
  11578. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  11579. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(24)
  11580. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11581. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11582. /* void data */
  11583. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = data
  11584. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(data_len*uint32(format)/libc.Uint32FromInt32(8)) * uint64(1)
  11585. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  11586. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  11587. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req40)))
  11588. return xcb_ret
  11589. }
  11590. var _xcb_req40 = Txcb_protocol_request_t{
  11591. Fcount: uint64(4),
  11592. Fopcode: uint8(m_XCB_CHANGE_PROPERTY),
  11593. Fisvoid: uint8(1),
  11594. }
  11595. func Xxcb_change_property(tls *libc.TLS, c uintptr, mode Tuint8_t, window Txcb_window_t, property Txcb_atom_t, type1 Txcb_atom_t, format Tuint8_t, data_len Tuint32_t, data uintptr) (r Txcb_void_cookie_t) {
  11596. bp := tls.Alloc(128)
  11597. defer tls.Free(128)
  11598. var xcb_ret Txcb_void_cookie_t
  11599. var _ /* xcb_out at bp+96 */ Txcb_change_property_request_t
  11600. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  11601. _ = xcb_ret
  11602. (*(*Txcb_change_property_request_t)(unsafe.Pointer(bp + 96))).Fmode = mode
  11603. (*(*Txcb_change_property_request_t)(unsafe.Pointer(bp + 96))).Fwindow = window
  11604. (*(*Txcb_change_property_request_t)(unsafe.Pointer(bp + 96))).Fproperty = property
  11605. (*(*Txcb_change_property_request_t)(unsafe.Pointer(bp + 96))).Ftype1 = type1
  11606. (*(*Txcb_change_property_request_t)(unsafe.Pointer(bp + 96))).Fformat = format
  11607. libc.Xmemset(tls, bp+96+17, 0, uint64(3))
  11608. (*(*Txcb_change_property_request_t)(unsafe.Pointer(bp + 96))).Fdata_len = data_len
  11609. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  11610. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(24)
  11611. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11612. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11613. /* void data */
  11614. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = data
  11615. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(data_len*uint32(format)/libc.Uint32FromInt32(8)) * uint64(1)
  11616. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  11617. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  11618. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req41)))
  11619. return xcb_ret
  11620. }
  11621. var _xcb_req41 = Txcb_protocol_request_t{
  11622. Fcount: uint64(4),
  11623. Fopcode: uint8(m_XCB_CHANGE_PROPERTY),
  11624. Fisvoid: uint8(1),
  11625. }
  11626. func Xxcb_change_property_data(tls *libc.TLS, R uintptr) (r uintptr) {
  11627. return R + libc.UintptrFromInt32(1)*24
  11628. }
  11629. func Xxcb_change_property_data_length(tls *libc.TLS, R uintptr) (r int32) {
  11630. return libc.Int32FromUint32((*Txcb_change_property_request_t)(unsafe.Pointer(R)).Fdata_len * uint32((*Txcb_change_property_request_t)(unsafe.Pointer(R)).Fformat) / libc.Uint32FromInt32(8))
  11631. }
  11632. func Xxcb_change_property_data_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  11633. var i Txcb_generic_iterator_t
  11634. _ = i
  11635. i.Fdata = R + libc.UintptrFromInt32(1)*24 + uintptr((*Txcb_change_property_request_t)(unsafe.Pointer(R)).Fdata_len*uint32((*Txcb_change_property_request_t)(unsafe.Pointer(R)).Fformat)/libc.Uint32FromInt32(8))
  11636. i.Frem = 0
  11637. i.Findex = int32(int64(i.Fdata) - int64(R))
  11638. return i
  11639. }
  11640. func Xxcb_delete_property_checked(tls *libc.TLS, c uintptr, window Txcb_window_t, property Txcb_atom_t) (r Txcb_void_cookie_t) {
  11641. bp := tls.Alloc(80)
  11642. defer tls.Free(80)
  11643. var xcb_ret Txcb_void_cookie_t
  11644. var _ /* xcb_out at bp+64 */ Txcb_delete_property_request_t
  11645. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11646. _ = xcb_ret
  11647. (*(*Txcb_delete_property_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  11648. (*(*Txcb_delete_property_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  11649. (*(*Txcb_delete_property_request_t)(unsafe.Pointer(bp + 64))).Fproperty = property
  11650. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11651. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  11652. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11653. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11654. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req42)))
  11655. return xcb_ret
  11656. }
  11657. var _xcb_req42 = Txcb_protocol_request_t{
  11658. Fcount: uint64(2),
  11659. Fopcode: uint8(m_XCB_DELETE_PROPERTY),
  11660. Fisvoid: uint8(1),
  11661. }
  11662. func Xxcb_delete_property(tls *libc.TLS, c uintptr, window Txcb_window_t, property Txcb_atom_t) (r Txcb_void_cookie_t) {
  11663. bp := tls.Alloc(80)
  11664. defer tls.Free(80)
  11665. var xcb_ret Txcb_void_cookie_t
  11666. var _ /* xcb_out at bp+64 */ Txcb_delete_property_request_t
  11667. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11668. _ = xcb_ret
  11669. (*(*Txcb_delete_property_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  11670. (*(*Txcb_delete_property_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  11671. (*(*Txcb_delete_property_request_t)(unsafe.Pointer(bp + 64))).Fproperty = property
  11672. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11673. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  11674. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11675. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11676. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req43)))
  11677. return xcb_ret
  11678. }
  11679. var _xcb_req43 = Txcb_protocol_request_t{
  11680. Fcount: uint64(2),
  11681. Fopcode: uint8(m_XCB_DELETE_PROPERTY),
  11682. Fisvoid: uint8(1),
  11683. }
  11684. func Xxcb_get_property_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  11685. var _aux, xcb_tmp uintptr
  11686. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  11687. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  11688. xcb_tmp = _buffer
  11689. _aux = _buffer
  11690. xcb_buffer_len = uint32(0)
  11691. xcb_block_len = uint32(0)
  11692. xcb_pad = uint32(0)
  11693. xcb_align_to = uint32(0)
  11694. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(32))
  11695. xcb_tmp += uintptr(xcb_block_len)
  11696. xcb_buffer_len += xcb_block_len
  11697. xcb_block_len = uint32(0)
  11698. /* value */
  11699. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_get_property_reply_t)(unsafe.Pointer(_aux)).Fvalue_len*libc.Uint32FromInt32(libc.Int32FromUint8((*Txcb_get_property_reply_t)(unsafe.Pointer(_aux)).Fformat)/libc.Int32FromInt32(8)))*libc.Uint64FromInt64(1))
  11700. xcb_tmp += uintptr(xcb_block_len)
  11701. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  11702. /* insert padding */
  11703. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  11704. xcb_buffer_len += xcb_block_len + xcb_pad
  11705. if uint32(0) != xcb_pad {
  11706. xcb_tmp += uintptr(xcb_pad)
  11707. xcb_pad = uint32(0)
  11708. }
  11709. xcb_block_len = uint32(0)
  11710. return libc.Int32FromUint32(xcb_buffer_len)
  11711. }
  11712. func Xxcb_get_property(tls *libc.TLS, c uintptr, _delete Tuint8_t, window Txcb_window_t, property Txcb_atom_t, type1 Txcb_atom_t, long_offset Tuint32_t, long_length Tuint32_t) (r Txcb_get_property_cookie_t) {
  11713. bp := tls.Alloc(96)
  11714. defer tls.Free(96)
  11715. var xcb_ret Txcb_get_property_cookie_t
  11716. var _ /* xcb_out at bp+64 */ Txcb_get_property_request_t
  11717. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11718. _ = xcb_ret
  11719. (*(*Txcb_get_property_request_t)(unsafe.Pointer(bp + 64))).F_delete = _delete
  11720. (*(*Txcb_get_property_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  11721. (*(*Txcb_get_property_request_t)(unsafe.Pointer(bp + 64))).Fproperty = property
  11722. (*(*Txcb_get_property_request_t)(unsafe.Pointer(bp + 64))).Ftype1 = type1
  11723. (*(*Txcb_get_property_request_t)(unsafe.Pointer(bp + 64))).Flong_offset = long_offset
  11724. (*(*Txcb_get_property_request_t)(unsafe.Pointer(bp + 64))).Flong_length = long_length
  11725. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11726. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(24)
  11727. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11728. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11729. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req44)))
  11730. return xcb_ret
  11731. }
  11732. var _xcb_req44 = Txcb_protocol_request_t{
  11733. Fcount: uint64(2),
  11734. Fopcode: uint8(m_XCB_GET_PROPERTY),
  11735. }
  11736. func Xxcb_get_property_unchecked(tls *libc.TLS, c uintptr, _delete Tuint8_t, window Txcb_window_t, property Txcb_atom_t, type1 Txcb_atom_t, long_offset Tuint32_t, long_length Tuint32_t) (r Txcb_get_property_cookie_t) {
  11737. bp := tls.Alloc(96)
  11738. defer tls.Free(96)
  11739. var xcb_ret Txcb_get_property_cookie_t
  11740. var _ /* xcb_out at bp+64 */ Txcb_get_property_request_t
  11741. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11742. _ = xcb_ret
  11743. (*(*Txcb_get_property_request_t)(unsafe.Pointer(bp + 64))).F_delete = _delete
  11744. (*(*Txcb_get_property_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  11745. (*(*Txcb_get_property_request_t)(unsafe.Pointer(bp + 64))).Fproperty = property
  11746. (*(*Txcb_get_property_request_t)(unsafe.Pointer(bp + 64))).Ftype1 = type1
  11747. (*(*Txcb_get_property_request_t)(unsafe.Pointer(bp + 64))).Flong_offset = long_offset
  11748. (*(*Txcb_get_property_request_t)(unsafe.Pointer(bp + 64))).Flong_length = long_length
  11749. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11750. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(24)
  11751. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11752. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11753. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req45)))
  11754. return xcb_ret
  11755. }
  11756. var _xcb_req45 = Txcb_protocol_request_t{
  11757. Fcount: uint64(2),
  11758. Fopcode: uint8(m_XCB_GET_PROPERTY),
  11759. }
  11760. func Xxcb_get_property_value(tls *libc.TLS, R uintptr) (r uintptr) {
  11761. return R + libc.UintptrFromInt32(1)*32
  11762. }
  11763. func Xxcb_get_property_value_length(tls *libc.TLS, R uintptr) (r int32) {
  11764. return libc.Int32FromUint32((*Txcb_get_property_reply_t)(unsafe.Pointer(R)).Fvalue_len * libc.Uint32FromInt32(libc.Int32FromUint8((*Txcb_get_property_reply_t)(unsafe.Pointer(R)).Fformat)/libc.Int32FromInt32(8)))
  11765. }
  11766. func Xxcb_get_property_value_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  11767. var i Txcb_generic_iterator_t
  11768. _ = i
  11769. i.Fdata = R + libc.UintptrFromInt32(1)*32 + uintptr((*Txcb_get_property_reply_t)(unsafe.Pointer(R)).Fvalue_len*libc.Uint32FromInt32(libc.Int32FromUint8((*Txcb_get_property_reply_t)(unsafe.Pointer(R)).Fformat)/libc.Int32FromInt32(8)))
  11770. i.Frem = 0
  11771. i.Findex = int32(int64(i.Fdata) - int64(R))
  11772. return i
  11773. }
  11774. func Xxcb_get_property_reply(tls *libc.TLS, c uintptr, cookie Txcb_get_property_cookie_t, e uintptr) (r uintptr) {
  11775. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  11776. }
  11777. func Xxcb_list_properties_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  11778. var _aux, xcb_tmp uintptr
  11779. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  11780. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  11781. xcb_tmp = _buffer
  11782. _aux = _buffer
  11783. xcb_buffer_len = uint32(0)
  11784. xcb_block_len = uint32(0)
  11785. xcb_pad = uint32(0)
  11786. xcb_align_to = uint32(0)
  11787. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(32))
  11788. xcb_tmp += uintptr(xcb_block_len)
  11789. xcb_buffer_len += xcb_block_len
  11790. xcb_block_len = uint32(0)
  11791. /* atoms */
  11792. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_list_properties_reply_t)(unsafe.Pointer(_aux)).Fatoms_len)*libc.Uint64FromInt64(4))
  11793. xcb_tmp += uintptr(xcb_block_len)
  11794. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  11795. /* insert padding */
  11796. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  11797. xcb_buffer_len += xcb_block_len + xcb_pad
  11798. if uint32(0) != xcb_pad {
  11799. xcb_tmp += uintptr(xcb_pad)
  11800. xcb_pad = uint32(0)
  11801. }
  11802. xcb_block_len = uint32(0)
  11803. return libc.Int32FromUint32(xcb_buffer_len)
  11804. }
  11805. func Xxcb_list_properties(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_list_properties_cookie_t) {
  11806. bp := tls.Alloc(80)
  11807. defer tls.Free(80)
  11808. var xcb_ret Txcb_list_properties_cookie_t
  11809. var _ /* xcb_out at bp+64 */ Txcb_list_properties_request_t
  11810. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11811. _ = xcb_ret
  11812. (*(*Txcb_list_properties_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  11813. (*(*Txcb_list_properties_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  11814. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11815. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  11816. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11817. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11818. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req46)))
  11819. return xcb_ret
  11820. }
  11821. var _xcb_req46 = Txcb_protocol_request_t{
  11822. Fcount: uint64(2),
  11823. Fopcode: uint8(m_XCB_LIST_PROPERTIES),
  11824. }
  11825. func Xxcb_list_properties_unchecked(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_list_properties_cookie_t) {
  11826. bp := tls.Alloc(80)
  11827. defer tls.Free(80)
  11828. var xcb_ret Txcb_list_properties_cookie_t
  11829. var _ /* xcb_out at bp+64 */ Txcb_list_properties_request_t
  11830. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11831. _ = xcb_ret
  11832. (*(*Txcb_list_properties_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  11833. (*(*Txcb_list_properties_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  11834. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11835. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  11836. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11837. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11838. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req47)))
  11839. return xcb_ret
  11840. }
  11841. var _xcb_req47 = Txcb_protocol_request_t{
  11842. Fcount: uint64(2),
  11843. Fopcode: uint8(m_XCB_LIST_PROPERTIES),
  11844. }
  11845. func Xxcb_list_properties_atoms(tls *libc.TLS, R uintptr) (r uintptr) {
  11846. return R + libc.UintptrFromInt32(1)*32
  11847. }
  11848. func Xxcb_list_properties_atoms_length(tls *libc.TLS, R uintptr) (r int32) {
  11849. return libc.Int32FromUint16((*Txcb_list_properties_reply_t)(unsafe.Pointer(R)).Fatoms_len)
  11850. }
  11851. func Xxcb_list_properties_atoms_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  11852. var i Txcb_generic_iterator_t
  11853. _ = i
  11854. i.Fdata = R + libc.UintptrFromInt32(1)*32 + uintptr((*Txcb_list_properties_reply_t)(unsafe.Pointer(R)).Fatoms_len)*4
  11855. i.Frem = 0
  11856. i.Findex = int32(int64(i.Fdata) - int64(R))
  11857. return i
  11858. }
  11859. func Xxcb_list_properties_reply(tls *libc.TLS, c uintptr, cookie Txcb_list_properties_cookie_t, e uintptr) (r uintptr) {
  11860. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  11861. }
  11862. func Xxcb_set_selection_owner_checked(tls *libc.TLS, c uintptr, owner Txcb_window_t, selection Txcb_atom_t, time Txcb_timestamp_t) (r Txcb_void_cookie_t) {
  11863. bp := tls.Alloc(80)
  11864. defer tls.Free(80)
  11865. var xcb_ret Txcb_void_cookie_t
  11866. var _ /* xcb_out at bp+64 */ Txcb_set_selection_owner_request_t
  11867. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11868. _ = xcb_ret
  11869. (*(*Txcb_set_selection_owner_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  11870. (*(*Txcb_set_selection_owner_request_t)(unsafe.Pointer(bp + 64))).Fowner = owner
  11871. (*(*Txcb_set_selection_owner_request_t)(unsafe.Pointer(bp + 64))).Fselection = selection
  11872. (*(*Txcb_set_selection_owner_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  11873. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11874. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  11875. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11876. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11877. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req48)))
  11878. return xcb_ret
  11879. }
  11880. var _xcb_req48 = Txcb_protocol_request_t{
  11881. Fcount: uint64(2),
  11882. Fopcode: uint8(m_XCB_SET_SELECTION_OWNER),
  11883. Fisvoid: uint8(1),
  11884. }
  11885. func Xxcb_set_selection_owner(tls *libc.TLS, c uintptr, owner Txcb_window_t, selection Txcb_atom_t, time Txcb_timestamp_t) (r Txcb_void_cookie_t) {
  11886. bp := tls.Alloc(80)
  11887. defer tls.Free(80)
  11888. var xcb_ret Txcb_void_cookie_t
  11889. var _ /* xcb_out at bp+64 */ Txcb_set_selection_owner_request_t
  11890. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11891. _ = xcb_ret
  11892. (*(*Txcb_set_selection_owner_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  11893. (*(*Txcb_set_selection_owner_request_t)(unsafe.Pointer(bp + 64))).Fowner = owner
  11894. (*(*Txcb_set_selection_owner_request_t)(unsafe.Pointer(bp + 64))).Fselection = selection
  11895. (*(*Txcb_set_selection_owner_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  11896. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11897. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  11898. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11899. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11900. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req49)))
  11901. return xcb_ret
  11902. }
  11903. var _xcb_req49 = Txcb_protocol_request_t{
  11904. Fcount: uint64(2),
  11905. Fopcode: uint8(m_XCB_SET_SELECTION_OWNER),
  11906. Fisvoid: uint8(1),
  11907. }
  11908. func Xxcb_get_selection_owner(tls *libc.TLS, c uintptr, selection Txcb_atom_t) (r Txcb_get_selection_owner_cookie_t) {
  11909. bp := tls.Alloc(80)
  11910. defer tls.Free(80)
  11911. var xcb_ret Txcb_get_selection_owner_cookie_t
  11912. var _ /* xcb_out at bp+64 */ Txcb_get_selection_owner_request_t
  11913. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11914. _ = xcb_ret
  11915. (*(*Txcb_get_selection_owner_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  11916. (*(*Txcb_get_selection_owner_request_t)(unsafe.Pointer(bp + 64))).Fselection = selection
  11917. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11918. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  11919. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11920. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11921. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req50)))
  11922. return xcb_ret
  11923. }
  11924. var _xcb_req50 = Txcb_protocol_request_t{
  11925. Fcount: uint64(2),
  11926. Fopcode: uint8(m_XCB_GET_SELECTION_OWNER),
  11927. }
  11928. func Xxcb_get_selection_owner_unchecked(tls *libc.TLS, c uintptr, selection Txcb_atom_t) (r Txcb_get_selection_owner_cookie_t) {
  11929. bp := tls.Alloc(80)
  11930. defer tls.Free(80)
  11931. var xcb_ret Txcb_get_selection_owner_cookie_t
  11932. var _ /* xcb_out at bp+64 */ Txcb_get_selection_owner_request_t
  11933. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11934. _ = xcb_ret
  11935. (*(*Txcb_get_selection_owner_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  11936. (*(*Txcb_get_selection_owner_request_t)(unsafe.Pointer(bp + 64))).Fselection = selection
  11937. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11938. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  11939. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11940. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11941. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req51)))
  11942. return xcb_ret
  11943. }
  11944. var _xcb_req51 = Txcb_protocol_request_t{
  11945. Fcount: uint64(2),
  11946. Fopcode: uint8(m_XCB_GET_SELECTION_OWNER),
  11947. }
  11948. func Xxcb_get_selection_owner_reply(tls *libc.TLS, c uintptr, cookie Txcb_get_selection_owner_cookie_t, e uintptr) (r uintptr) {
  11949. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  11950. }
  11951. func Xxcb_convert_selection_checked(tls *libc.TLS, c uintptr, requestor Txcb_window_t, selection Txcb_atom_t, target Txcb_atom_t, property Txcb_atom_t, time Txcb_timestamp_t) (r Txcb_void_cookie_t) {
  11952. bp := tls.Alloc(96)
  11953. defer tls.Free(96)
  11954. var xcb_ret Txcb_void_cookie_t
  11955. var _ /* xcb_out at bp+64 */ Txcb_convert_selection_request_t
  11956. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11957. _ = xcb_ret
  11958. (*(*Txcb_convert_selection_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  11959. (*(*Txcb_convert_selection_request_t)(unsafe.Pointer(bp + 64))).Frequestor = requestor
  11960. (*(*Txcb_convert_selection_request_t)(unsafe.Pointer(bp + 64))).Fselection = selection
  11961. (*(*Txcb_convert_selection_request_t)(unsafe.Pointer(bp + 64))).Ftarget = target
  11962. (*(*Txcb_convert_selection_request_t)(unsafe.Pointer(bp + 64))).Fproperty = property
  11963. (*(*Txcb_convert_selection_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  11964. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11965. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(24)
  11966. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11967. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11968. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req52)))
  11969. return xcb_ret
  11970. }
  11971. var _xcb_req52 = Txcb_protocol_request_t{
  11972. Fcount: uint64(2),
  11973. Fopcode: uint8(m_XCB_CONVERT_SELECTION),
  11974. Fisvoid: uint8(1),
  11975. }
  11976. func Xxcb_convert_selection(tls *libc.TLS, c uintptr, requestor Txcb_window_t, selection Txcb_atom_t, target Txcb_atom_t, property Txcb_atom_t, time Txcb_timestamp_t) (r Txcb_void_cookie_t) {
  11977. bp := tls.Alloc(96)
  11978. defer tls.Free(96)
  11979. var xcb_ret Txcb_void_cookie_t
  11980. var _ /* xcb_out at bp+64 */ Txcb_convert_selection_request_t
  11981. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  11982. _ = xcb_ret
  11983. (*(*Txcb_convert_selection_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  11984. (*(*Txcb_convert_selection_request_t)(unsafe.Pointer(bp + 64))).Frequestor = requestor
  11985. (*(*Txcb_convert_selection_request_t)(unsafe.Pointer(bp + 64))).Fselection = selection
  11986. (*(*Txcb_convert_selection_request_t)(unsafe.Pointer(bp + 64))).Ftarget = target
  11987. (*(*Txcb_convert_selection_request_t)(unsafe.Pointer(bp + 64))).Fproperty = property
  11988. (*(*Txcb_convert_selection_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  11989. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  11990. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(24)
  11991. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  11992. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  11993. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req53)))
  11994. return xcb_ret
  11995. }
  11996. var _xcb_req53 = Txcb_protocol_request_t{
  11997. Fcount: uint64(2),
  11998. Fopcode: uint8(m_XCB_CONVERT_SELECTION),
  11999. Fisvoid: uint8(1),
  12000. }
  12001. func Xxcb_send_event_checked(tls *libc.TLS, c uintptr, propagate Tuint8_t, destination Txcb_window_t, event_mask Tuint32_t, event uintptr) (r Txcb_void_cookie_t) {
  12002. bp := tls.Alloc(112)
  12003. defer tls.Free(112)
  12004. var xcb_ret Txcb_void_cookie_t
  12005. var _ /* xcb_out at bp+64 */ Txcb_send_event_request_t
  12006. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12007. _ = xcb_ret
  12008. (*(*Txcb_send_event_request_t)(unsafe.Pointer(bp + 64))).Fpropagate = propagate
  12009. (*(*Txcb_send_event_request_t)(unsafe.Pointer(bp + 64))).Fdestination = destination
  12010. (*(*Txcb_send_event_request_t)(unsafe.Pointer(bp + 64))).Fevent_mask = event_mask
  12011. libc.Xmemcpy(tls, bp+64+12, event, uint64(32))
  12012. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12013. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(44)
  12014. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12015. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12016. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req54)))
  12017. return xcb_ret
  12018. }
  12019. var _xcb_req54 = Txcb_protocol_request_t{
  12020. Fcount: uint64(2),
  12021. Fopcode: uint8(m_XCB_SEND_EVENT),
  12022. Fisvoid: uint8(1),
  12023. }
  12024. func Xxcb_send_event(tls *libc.TLS, c uintptr, propagate Tuint8_t, destination Txcb_window_t, event_mask Tuint32_t, event uintptr) (r Txcb_void_cookie_t) {
  12025. bp := tls.Alloc(112)
  12026. defer tls.Free(112)
  12027. var xcb_ret Txcb_void_cookie_t
  12028. var _ /* xcb_out at bp+64 */ Txcb_send_event_request_t
  12029. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12030. _ = xcb_ret
  12031. (*(*Txcb_send_event_request_t)(unsafe.Pointer(bp + 64))).Fpropagate = propagate
  12032. (*(*Txcb_send_event_request_t)(unsafe.Pointer(bp + 64))).Fdestination = destination
  12033. (*(*Txcb_send_event_request_t)(unsafe.Pointer(bp + 64))).Fevent_mask = event_mask
  12034. libc.Xmemcpy(tls, bp+64+12, event, uint64(32))
  12035. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12036. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(44)
  12037. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12038. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12039. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req55)))
  12040. return xcb_ret
  12041. }
  12042. var _xcb_req55 = Txcb_protocol_request_t{
  12043. Fcount: uint64(2),
  12044. Fopcode: uint8(m_XCB_SEND_EVENT),
  12045. Fisvoid: uint8(1),
  12046. }
  12047. func Xxcb_grab_pointer(tls *libc.TLS, c uintptr, owner_events Tuint8_t, grab_window Txcb_window_t, event_mask Tuint16_t, pointer_mode Tuint8_t, keyboard_mode Tuint8_t, confine_to Txcb_window_t, cursor Txcb_cursor_t, time Txcb_timestamp_t) (r Txcb_grab_pointer_cookie_t) {
  12048. bp := tls.Alloc(96)
  12049. defer tls.Free(96)
  12050. var xcb_ret Txcb_grab_pointer_cookie_t
  12051. var _ /* xcb_out at bp+64 */ Txcb_grab_pointer_request_t
  12052. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12053. _ = xcb_ret
  12054. (*(*Txcb_grab_pointer_request_t)(unsafe.Pointer(bp + 64))).Fowner_events = owner_events
  12055. (*(*Txcb_grab_pointer_request_t)(unsafe.Pointer(bp + 64))).Fgrab_window = grab_window
  12056. (*(*Txcb_grab_pointer_request_t)(unsafe.Pointer(bp + 64))).Fevent_mask = event_mask
  12057. (*(*Txcb_grab_pointer_request_t)(unsafe.Pointer(bp + 64))).Fpointer_mode = pointer_mode
  12058. (*(*Txcb_grab_pointer_request_t)(unsafe.Pointer(bp + 64))).Fkeyboard_mode = keyboard_mode
  12059. (*(*Txcb_grab_pointer_request_t)(unsafe.Pointer(bp + 64))).Fconfine_to = confine_to
  12060. (*(*Txcb_grab_pointer_request_t)(unsafe.Pointer(bp + 64))).Fcursor = cursor
  12061. (*(*Txcb_grab_pointer_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  12062. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12063. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(24)
  12064. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12065. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12066. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req56)))
  12067. return xcb_ret
  12068. }
  12069. var _xcb_req56 = Txcb_protocol_request_t{
  12070. Fcount: uint64(2),
  12071. Fopcode: uint8(m_XCB_GRAB_POINTER),
  12072. }
  12073. func Xxcb_grab_pointer_unchecked(tls *libc.TLS, c uintptr, owner_events Tuint8_t, grab_window Txcb_window_t, event_mask Tuint16_t, pointer_mode Tuint8_t, keyboard_mode Tuint8_t, confine_to Txcb_window_t, cursor Txcb_cursor_t, time Txcb_timestamp_t) (r Txcb_grab_pointer_cookie_t) {
  12074. bp := tls.Alloc(96)
  12075. defer tls.Free(96)
  12076. var xcb_ret Txcb_grab_pointer_cookie_t
  12077. var _ /* xcb_out at bp+64 */ Txcb_grab_pointer_request_t
  12078. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12079. _ = xcb_ret
  12080. (*(*Txcb_grab_pointer_request_t)(unsafe.Pointer(bp + 64))).Fowner_events = owner_events
  12081. (*(*Txcb_grab_pointer_request_t)(unsafe.Pointer(bp + 64))).Fgrab_window = grab_window
  12082. (*(*Txcb_grab_pointer_request_t)(unsafe.Pointer(bp + 64))).Fevent_mask = event_mask
  12083. (*(*Txcb_grab_pointer_request_t)(unsafe.Pointer(bp + 64))).Fpointer_mode = pointer_mode
  12084. (*(*Txcb_grab_pointer_request_t)(unsafe.Pointer(bp + 64))).Fkeyboard_mode = keyboard_mode
  12085. (*(*Txcb_grab_pointer_request_t)(unsafe.Pointer(bp + 64))).Fconfine_to = confine_to
  12086. (*(*Txcb_grab_pointer_request_t)(unsafe.Pointer(bp + 64))).Fcursor = cursor
  12087. (*(*Txcb_grab_pointer_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  12088. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12089. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(24)
  12090. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12091. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12092. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req57)))
  12093. return xcb_ret
  12094. }
  12095. var _xcb_req57 = Txcb_protocol_request_t{
  12096. Fcount: uint64(2),
  12097. Fopcode: uint8(m_XCB_GRAB_POINTER),
  12098. }
  12099. func Xxcb_grab_pointer_reply(tls *libc.TLS, c uintptr, cookie Txcb_grab_pointer_cookie_t, e uintptr) (r uintptr) {
  12100. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  12101. }
  12102. func Xxcb_ungrab_pointer_checked(tls *libc.TLS, c uintptr, time Txcb_timestamp_t) (r Txcb_void_cookie_t) {
  12103. bp := tls.Alloc(80)
  12104. defer tls.Free(80)
  12105. var xcb_ret Txcb_void_cookie_t
  12106. var _ /* xcb_out at bp+64 */ Txcb_ungrab_pointer_request_t
  12107. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12108. _ = xcb_ret
  12109. (*(*Txcb_ungrab_pointer_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12110. (*(*Txcb_ungrab_pointer_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  12111. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12112. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  12113. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12114. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12115. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req58)))
  12116. return xcb_ret
  12117. }
  12118. var _xcb_req58 = Txcb_protocol_request_t{
  12119. Fcount: uint64(2),
  12120. Fopcode: uint8(m_XCB_UNGRAB_POINTER),
  12121. Fisvoid: uint8(1),
  12122. }
  12123. func Xxcb_ungrab_pointer(tls *libc.TLS, c uintptr, time Txcb_timestamp_t) (r Txcb_void_cookie_t) {
  12124. bp := tls.Alloc(80)
  12125. defer tls.Free(80)
  12126. var xcb_ret Txcb_void_cookie_t
  12127. var _ /* xcb_out at bp+64 */ Txcb_ungrab_pointer_request_t
  12128. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12129. _ = xcb_ret
  12130. (*(*Txcb_ungrab_pointer_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12131. (*(*Txcb_ungrab_pointer_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  12132. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12133. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  12134. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12135. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12136. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req59)))
  12137. return xcb_ret
  12138. }
  12139. var _xcb_req59 = Txcb_protocol_request_t{
  12140. Fcount: uint64(2),
  12141. Fopcode: uint8(m_XCB_UNGRAB_POINTER),
  12142. Fisvoid: uint8(1),
  12143. }
  12144. func Xxcb_grab_button_checked(tls *libc.TLS, c uintptr, owner_events Tuint8_t, grab_window Txcb_window_t, event_mask Tuint16_t, pointer_mode Tuint8_t, keyboard_mode Tuint8_t, confine_to Txcb_window_t, cursor Txcb_cursor_t, button Tuint8_t, modifiers Tuint16_t) (r Txcb_void_cookie_t) {
  12145. bp := tls.Alloc(96)
  12146. defer tls.Free(96)
  12147. var xcb_ret Txcb_void_cookie_t
  12148. var _ /* xcb_out at bp+64 */ Txcb_grab_button_request_t
  12149. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12150. _ = xcb_ret
  12151. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fowner_events = owner_events
  12152. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fgrab_window = grab_window
  12153. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fevent_mask = event_mask
  12154. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fpointer_mode = pointer_mode
  12155. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fkeyboard_mode = keyboard_mode
  12156. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fconfine_to = confine_to
  12157. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fcursor = cursor
  12158. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fbutton = button
  12159. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12160. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fmodifiers = modifiers
  12161. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12162. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(24)
  12163. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12164. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12165. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req60)))
  12166. return xcb_ret
  12167. }
  12168. var _xcb_req60 = Txcb_protocol_request_t{
  12169. Fcount: uint64(2),
  12170. Fopcode: uint8(m_XCB_GRAB_BUTTON),
  12171. Fisvoid: uint8(1),
  12172. }
  12173. func Xxcb_grab_button(tls *libc.TLS, c uintptr, owner_events Tuint8_t, grab_window Txcb_window_t, event_mask Tuint16_t, pointer_mode Tuint8_t, keyboard_mode Tuint8_t, confine_to Txcb_window_t, cursor Txcb_cursor_t, button Tuint8_t, modifiers Tuint16_t) (r Txcb_void_cookie_t) {
  12174. bp := tls.Alloc(96)
  12175. defer tls.Free(96)
  12176. var xcb_ret Txcb_void_cookie_t
  12177. var _ /* xcb_out at bp+64 */ Txcb_grab_button_request_t
  12178. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12179. _ = xcb_ret
  12180. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fowner_events = owner_events
  12181. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fgrab_window = grab_window
  12182. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fevent_mask = event_mask
  12183. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fpointer_mode = pointer_mode
  12184. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fkeyboard_mode = keyboard_mode
  12185. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fconfine_to = confine_to
  12186. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fcursor = cursor
  12187. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fbutton = button
  12188. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12189. (*(*Txcb_grab_button_request_t)(unsafe.Pointer(bp + 64))).Fmodifiers = modifiers
  12190. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12191. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(24)
  12192. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12193. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12194. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req61)))
  12195. return xcb_ret
  12196. }
  12197. var _xcb_req61 = Txcb_protocol_request_t{
  12198. Fcount: uint64(2),
  12199. Fopcode: uint8(m_XCB_GRAB_BUTTON),
  12200. Fisvoid: uint8(1),
  12201. }
  12202. func Xxcb_ungrab_button_checked(tls *libc.TLS, c uintptr, button Tuint8_t, grab_window Txcb_window_t, modifiers Tuint16_t) (r Txcb_void_cookie_t) {
  12203. bp := tls.Alloc(80)
  12204. defer tls.Free(80)
  12205. var xcb_ret Txcb_void_cookie_t
  12206. var _ /* xcb_out at bp+64 */ Txcb_ungrab_button_request_t
  12207. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12208. _ = xcb_ret
  12209. (*(*Txcb_ungrab_button_request_t)(unsafe.Pointer(bp + 64))).Fbutton = button
  12210. (*(*Txcb_ungrab_button_request_t)(unsafe.Pointer(bp + 64))).Fgrab_window = grab_window
  12211. (*(*Txcb_ungrab_button_request_t)(unsafe.Pointer(bp + 64))).Fmodifiers = modifiers
  12212. libc.Xmemset(tls, bp+64+10, 0, uint64(2))
  12213. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12214. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  12215. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12216. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12217. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req62)))
  12218. return xcb_ret
  12219. }
  12220. var _xcb_req62 = Txcb_protocol_request_t{
  12221. Fcount: uint64(2),
  12222. Fopcode: uint8(m_XCB_UNGRAB_BUTTON),
  12223. Fisvoid: uint8(1),
  12224. }
  12225. func Xxcb_ungrab_button(tls *libc.TLS, c uintptr, button Tuint8_t, grab_window Txcb_window_t, modifiers Tuint16_t) (r Txcb_void_cookie_t) {
  12226. bp := tls.Alloc(80)
  12227. defer tls.Free(80)
  12228. var xcb_ret Txcb_void_cookie_t
  12229. var _ /* xcb_out at bp+64 */ Txcb_ungrab_button_request_t
  12230. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12231. _ = xcb_ret
  12232. (*(*Txcb_ungrab_button_request_t)(unsafe.Pointer(bp + 64))).Fbutton = button
  12233. (*(*Txcb_ungrab_button_request_t)(unsafe.Pointer(bp + 64))).Fgrab_window = grab_window
  12234. (*(*Txcb_ungrab_button_request_t)(unsafe.Pointer(bp + 64))).Fmodifiers = modifiers
  12235. libc.Xmemset(tls, bp+64+10, 0, uint64(2))
  12236. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12237. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  12238. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12239. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12240. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req63)))
  12241. return xcb_ret
  12242. }
  12243. var _xcb_req63 = Txcb_protocol_request_t{
  12244. Fcount: uint64(2),
  12245. Fopcode: uint8(m_XCB_UNGRAB_BUTTON),
  12246. Fisvoid: uint8(1),
  12247. }
  12248. func Xxcb_change_active_pointer_grab_checked(tls *libc.TLS, c uintptr, cursor Txcb_cursor_t, time Txcb_timestamp_t, event_mask Tuint16_t) (r Txcb_void_cookie_t) {
  12249. bp := tls.Alloc(80)
  12250. defer tls.Free(80)
  12251. var xcb_ret Txcb_void_cookie_t
  12252. var _ /* xcb_out at bp+64 */ Txcb_change_active_pointer_grab_request_t
  12253. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12254. _ = xcb_ret
  12255. (*(*Txcb_change_active_pointer_grab_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12256. (*(*Txcb_change_active_pointer_grab_request_t)(unsafe.Pointer(bp + 64))).Fcursor = cursor
  12257. (*(*Txcb_change_active_pointer_grab_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  12258. (*(*Txcb_change_active_pointer_grab_request_t)(unsafe.Pointer(bp + 64))).Fevent_mask = event_mask
  12259. libc.Xmemset(tls, bp+64+14, 0, uint64(2))
  12260. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12261. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  12262. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12263. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12264. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req64)))
  12265. return xcb_ret
  12266. }
  12267. var _xcb_req64 = Txcb_protocol_request_t{
  12268. Fcount: uint64(2),
  12269. Fopcode: uint8(m_XCB_CHANGE_ACTIVE_POINTER_GRAB),
  12270. Fisvoid: uint8(1),
  12271. }
  12272. func Xxcb_change_active_pointer_grab(tls *libc.TLS, c uintptr, cursor Txcb_cursor_t, time Txcb_timestamp_t, event_mask Tuint16_t) (r Txcb_void_cookie_t) {
  12273. bp := tls.Alloc(80)
  12274. defer tls.Free(80)
  12275. var xcb_ret Txcb_void_cookie_t
  12276. var _ /* xcb_out at bp+64 */ Txcb_change_active_pointer_grab_request_t
  12277. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12278. _ = xcb_ret
  12279. (*(*Txcb_change_active_pointer_grab_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12280. (*(*Txcb_change_active_pointer_grab_request_t)(unsafe.Pointer(bp + 64))).Fcursor = cursor
  12281. (*(*Txcb_change_active_pointer_grab_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  12282. (*(*Txcb_change_active_pointer_grab_request_t)(unsafe.Pointer(bp + 64))).Fevent_mask = event_mask
  12283. libc.Xmemset(tls, bp+64+14, 0, uint64(2))
  12284. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12285. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  12286. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12287. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12288. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req65)))
  12289. return xcb_ret
  12290. }
  12291. var _xcb_req65 = Txcb_protocol_request_t{
  12292. Fcount: uint64(2),
  12293. Fopcode: uint8(m_XCB_CHANGE_ACTIVE_POINTER_GRAB),
  12294. Fisvoid: uint8(1),
  12295. }
  12296. func Xxcb_grab_keyboard(tls *libc.TLS, c uintptr, owner_events Tuint8_t, grab_window Txcb_window_t, time Txcb_timestamp_t, pointer_mode Tuint8_t, keyboard_mode Tuint8_t) (r Txcb_grab_keyboard_cookie_t) {
  12297. bp := tls.Alloc(80)
  12298. defer tls.Free(80)
  12299. var xcb_ret Txcb_grab_keyboard_cookie_t
  12300. var _ /* xcb_out at bp+64 */ Txcb_grab_keyboard_request_t
  12301. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12302. _ = xcb_ret
  12303. (*(*Txcb_grab_keyboard_request_t)(unsafe.Pointer(bp + 64))).Fowner_events = owner_events
  12304. (*(*Txcb_grab_keyboard_request_t)(unsafe.Pointer(bp + 64))).Fgrab_window = grab_window
  12305. (*(*Txcb_grab_keyboard_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  12306. (*(*Txcb_grab_keyboard_request_t)(unsafe.Pointer(bp + 64))).Fpointer_mode = pointer_mode
  12307. (*(*Txcb_grab_keyboard_request_t)(unsafe.Pointer(bp + 64))).Fkeyboard_mode = keyboard_mode
  12308. libc.Xmemset(tls, bp+64+14, 0, uint64(2))
  12309. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12310. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  12311. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12312. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12313. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req66)))
  12314. return xcb_ret
  12315. }
  12316. var _xcb_req66 = Txcb_protocol_request_t{
  12317. Fcount: uint64(2),
  12318. Fopcode: uint8(m_XCB_GRAB_KEYBOARD),
  12319. }
  12320. func Xxcb_grab_keyboard_unchecked(tls *libc.TLS, c uintptr, owner_events Tuint8_t, grab_window Txcb_window_t, time Txcb_timestamp_t, pointer_mode Tuint8_t, keyboard_mode Tuint8_t) (r Txcb_grab_keyboard_cookie_t) {
  12321. bp := tls.Alloc(80)
  12322. defer tls.Free(80)
  12323. var xcb_ret Txcb_grab_keyboard_cookie_t
  12324. var _ /* xcb_out at bp+64 */ Txcb_grab_keyboard_request_t
  12325. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12326. _ = xcb_ret
  12327. (*(*Txcb_grab_keyboard_request_t)(unsafe.Pointer(bp + 64))).Fowner_events = owner_events
  12328. (*(*Txcb_grab_keyboard_request_t)(unsafe.Pointer(bp + 64))).Fgrab_window = grab_window
  12329. (*(*Txcb_grab_keyboard_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  12330. (*(*Txcb_grab_keyboard_request_t)(unsafe.Pointer(bp + 64))).Fpointer_mode = pointer_mode
  12331. (*(*Txcb_grab_keyboard_request_t)(unsafe.Pointer(bp + 64))).Fkeyboard_mode = keyboard_mode
  12332. libc.Xmemset(tls, bp+64+14, 0, uint64(2))
  12333. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12334. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  12335. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12336. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12337. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req67)))
  12338. return xcb_ret
  12339. }
  12340. var _xcb_req67 = Txcb_protocol_request_t{
  12341. Fcount: uint64(2),
  12342. Fopcode: uint8(m_XCB_GRAB_KEYBOARD),
  12343. }
  12344. func Xxcb_grab_keyboard_reply(tls *libc.TLS, c uintptr, cookie Txcb_grab_keyboard_cookie_t, e uintptr) (r uintptr) {
  12345. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  12346. }
  12347. func Xxcb_ungrab_keyboard_checked(tls *libc.TLS, c uintptr, time Txcb_timestamp_t) (r Txcb_void_cookie_t) {
  12348. bp := tls.Alloc(80)
  12349. defer tls.Free(80)
  12350. var xcb_ret Txcb_void_cookie_t
  12351. var _ /* xcb_out at bp+64 */ Txcb_ungrab_keyboard_request_t
  12352. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12353. _ = xcb_ret
  12354. (*(*Txcb_ungrab_keyboard_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12355. (*(*Txcb_ungrab_keyboard_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  12356. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12357. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  12358. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12359. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12360. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req68)))
  12361. return xcb_ret
  12362. }
  12363. var _xcb_req68 = Txcb_protocol_request_t{
  12364. Fcount: uint64(2),
  12365. Fopcode: uint8(m_XCB_UNGRAB_KEYBOARD),
  12366. Fisvoid: uint8(1),
  12367. }
  12368. func Xxcb_ungrab_keyboard(tls *libc.TLS, c uintptr, time Txcb_timestamp_t) (r Txcb_void_cookie_t) {
  12369. bp := tls.Alloc(80)
  12370. defer tls.Free(80)
  12371. var xcb_ret Txcb_void_cookie_t
  12372. var _ /* xcb_out at bp+64 */ Txcb_ungrab_keyboard_request_t
  12373. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12374. _ = xcb_ret
  12375. (*(*Txcb_ungrab_keyboard_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12376. (*(*Txcb_ungrab_keyboard_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  12377. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12378. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  12379. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12380. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12381. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req69)))
  12382. return xcb_ret
  12383. }
  12384. var _xcb_req69 = Txcb_protocol_request_t{
  12385. Fcount: uint64(2),
  12386. Fopcode: uint8(m_XCB_UNGRAB_KEYBOARD),
  12387. Fisvoid: uint8(1),
  12388. }
  12389. func Xxcb_grab_key_checked(tls *libc.TLS, c uintptr, owner_events Tuint8_t, grab_window Txcb_window_t, modifiers Tuint16_t, key Txcb_keycode_t, pointer_mode Tuint8_t, keyboard_mode Tuint8_t) (r Txcb_void_cookie_t) {
  12390. bp := tls.Alloc(80)
  12391. defer tls.Free(80)
  12392. var xcb_ret Txcb_void_cookie_t
  12393. var _ /* xcb_out at bp+64 */ Txcb_grab_key_request_t
  12394. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12395. _ = xcb_ret
  12396. (*(*Txcb_grab_key_request_t)(unsafe.Pointer(bp + 64))).Fowner_events = owner_events
  12397. (*(*Txcb_grab_key_request_t)(unsafe.Pointer(bp + 64))).Fgrab_window = grab_window
  12398. (*(*Txcb_grab_key_request_t)(unsafe.Pointer(bp + 64))).Fmodifiers = modifiers
  12399. (*(*Txcb_grab_key_request_t)(unsafe.Pointer(bp + 64))).Fkey = key
  12400. (*(*Txcb_grab_key_request_t)(unsafe.Pointer(bp + 64))).Fpointer_mode = pointer_mode
  12401. (*(*Txcb_grab_key_request_t)(unsafe.Pointer(bp + 64))).Fkeyboard_mode = keyboard_mode
  12402. libc.Xmemset(tls, bp+64+13, 0, uint64(3))
  12403. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12404. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  12405. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12406. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12407. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req70)))
  12408. return xcb_ret
  12409. }
  12410. var _xcb_req70 = Txcb_protocol_request_t{
  12411. Fcount: uint64(2),
  12412. Fopcode: uint8(m_XCB_GRAB_KEY),
  12413. Fisvoid: uint8(1),
  12414. }
  12415. func Xxcb_grab_key(tls *libc.TLS, c uintptr, owner_events Tuint8_t, grab_window Txcb_window_t, modifiers Tuint16_t, key Txcb_keycode_t, pointer_mode Tuint8_t, keyboard_mode Tuint8_t) (r Txcb_void_cookie_t) {
  12416. bp := tls.Alloc(80)
  12417. defer tls.Free(80)
  12418. var xcb_ret Txcb_void_cookie_t
  12419. var _ /* xcb_out at bp+64 */ Txcb_grab_key_request_t
  12420. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12421. _ = xcb_ret
  12422. (*(*Txcb_grab_key_request_t)(unsafe.Pointer(bp + 64))).Fowner_events = owner_events
  12423. (*(*Txcb_grab_key_request_t)(unsafe.Pointer(bp + 64))).Fgrab_window = grab_window
  12424. (*(*Txcb_grab_key_request_t)(unsafe.Pointer(bp + 64))).Fmodifiers = modifiers
  12425. (*(*Txcb_grab_key_request_t)(unsafe.Pointer(bp + 64))).Fkey = key
  12426. (*(*Txcb_grab_key_request_t)(unsafe.Pointer(bp + 64))).Fpointer_mode = pointer_mode
  12427. (*(*Txcb_grab_key_request_t)(unsafe.Pointer(bp + 64))).Fkeyboard_mode = keyboard_mode
  12428. libc.Xmemset(tls, bp+64+13, 0, uint64(3))
  12429. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12430. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  12431. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12432. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12433. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req71)))
  12434. return xcb_ret
  12435. }
  12436. var _xcb_req71 = Txcb_protocol_request_t{
  12437. Fcount: uint64(2),
  12438. Fopcode: uint8(m_XCB_GRAB_KEY),
  12439. Fisvoid: uint8(1),
  12440. }
  12441. func Xxcb_ungrab_key_checked(tls *libc.TLS, c uintptr, key Txcb_keycode_t, grab_window Txcb_window_t, modifiers Tuint16_t) (r Txcb_void_cookie_t) {
  12442. bp := tls.Alloc(80)
  12443. defer tls.Free(80)
  12444. var xcb_ret Txcb_void_cookie_t
  12445. var _ /* xcb_out at bp+64 */ Txcb_ungrab_key_request_t
  12446. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12447. _ = xcb_ret
  12448. (*(*Txcb_ungrab_key_request_t)(unsafe.Pointer(bp + 64))).Fkey = key
  12449. (*(*Txcb_ungrab_key_request_t)(unsafe.Pointer(bp + 64))).Fgrab_window = grab_window
  12450. (*(*Txcb_ungrab_key_request_t)(unsafe.Pointer(bp + 64))).Fmodifiers = modifiers
  12451. libc.Xmemset(tls, bp+64+10, 0, uint64(2))
  12452. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12453. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  12454. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12455. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12456. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req72)))
  12457. return xcb_ret
  12458. }
  12459. var _xcb_req72 = Txcb_protocol_request_t{
  12460. Fcount: uint64(2),
  12461. Fopcode: uint8(m_XCB_UNGRAB_KEY),
  12462. Fisvoid: uint8(1),
  12463. }
  12464. func Xxcb_ungrab_key(tls *libc.TLS, c uintptr, key Txcb_keycode_t, grab_window Txcb_window_t, modifiers Tuint16_t) (r Txcb_void_cookie_t) {
  12465. bp := tls.Alloc(80)
  12466. defer tls.Free(80)
  12467. var xcb_ret Txcb_void_cookie_t
  12468. var _ /* xcb_out at bp+64 */ Txcb_ungrab_key_request_t
  12469. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12470. _ = xcb_ret
  12471. (*(*Txcb_ungrab_key_request_t)(unsafe.Pointer(bp + 64))).Fkey = key
  12472. (*(*Txcb_ungrab_key_request_t)(unsafe.Pointer(bp + 64))).Fgrab_window = grab_window
  12473. (*(*Txcb_ungrab_key_request_t)(unsafe.Pointer(bp + 64))).Fmodifiers = modifiers
  12474. libc.Xmemset(tls, bp+64+10, 0, uint64(2))
  12475. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12476. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  12477. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12478. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12479. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req73)))
  12480. return xcb_ret
  12481. }
  12482. var _xcb_req73 = Txcb_protocol_request_t{
  12483. Fcount: uint64(2),
  12484. Fopcode: uint8(m_XCB_UNGRAB_KEY),
  12485. Fisvoid: uint8(1),
  12486. }
  12487. func Xxcb_allow_events_checked(tls *libc.TLS, c uintptr, mode Tuint8_t, time Txcb_timestamp_t) (r Txcb_void_cookie_t) {
  12488. bp := tls.Alloc(80)
  12489. defer tls.Free(80)
  12490. var xcb_ret Txcb_void_cookie_t
  12491. var _ /* xcb_out at bp+64 */ Txcb_allow_events_request_t
  12492. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12493. _ = xcb_ret
  12494. (*(*Txcb_allow_events_request_t)(unsafe.Pointer(bp + 64))).Fmode = mode
  12495. (*(*Txcb_allow_events_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  12496. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12497. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  12498. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12499. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12500. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req74)))
  12501. return xcb_ret
  12502. }
  12503. var _xcb_req74 = Txcb_protocol_request_t{
  12504. Fcount: uint64(2),
  12505. Fopcode: uint8(m_XCB_ALLOW_EVENTS),
  12506. Fisvoid: uint8(1),
  12507. }
  12508. func Xxcb_allow_events(tls *libc.TLS, c uintptr, mode Tuint8_t, time Txcb_timestamp_t) (r Txcb_void_cookie_t) {
  12509. bp := tls.Alloc(80)
  12510. defer tls.Free(80)
  12511. var xcb_ret Txcb_void_cookie_t
  12512. var _ /* xcb_out at bp+64 */ Txcb_allow_events_request_t
  12513. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12514. _ = xcb_ret
  12515. (*(*Txcb_allow_events_request_t)(unsafe.Pointer(bp + 64))).Fmode = mode
  12516. (*(*Txcb_allow_events_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  12517. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12518. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  12519. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12520. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12521. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req75)))
  12522. return xcb_ret
  12523. }
  12524. var _xcb_req75 = Txcb_protocol_request_t{
  12525. Fcount: uint64(2),
  12526. Fopcode: uint8(m_XCB_ALLOW_EVENTS),
  12527. Fisvoid: uint8(1),
  12528. }
  12529. func Xxcb_grab_server_checked(tls *libc.TLS, c uintptr) (r Txcb_void_cookie_t) {
  12530. bp := tls.Alloc(80)
  12531. defer tls.Free(80)
  12532. var xcb_ret Txcb_void_cookie_t
  12533. var _ /* xcb_out at bp+64 */ Txcb_grab_server_request_t
  12534. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12535. _ = xcb_ret
  12536. (*(*Txcb_grab_server_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12537. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12538. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  12539. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12540. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12541. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req76)))
  12542. return xcb_ret
  12543. }
  12544. var _xcb_req76 = Txcb_protocol_request_t{
  12545. Fcount: uint64(2),
  12546. Fopcode: uint8(m_XCB_GRAB_SERVER),
  12547. Fisvoid: uint8(1),
  12548. }
  12549. func Xxcb_grab_server(tls *libc.TLS, c uintptr) (r Txcb_void_cookie_t) {
  12550. bp := tls.Alloc(80)
  12551. defer tls.Free(80)
  12552. var xcb_ret Txcb_void_cookie_t
  12553. var _ /* xcb_out at bp+64 */ Txcb_grab_server_request_t
  12554. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12555. _ = xcb_ret
  12556. (*(*Txcb_grab_server_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12557. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12558. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  12559. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12560. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12561. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req77)))
  12562. return xcb_ret
  12563. }
  12564. var _xcb_req77 = Txcb_protocol_request_t{
  12565. Fcount: uint64(2),
  12566. Fopcode: uint8(m_XCB_GRAB_SERVER),
  12567. Fisvoid: uint8(1),
  12568. }
  12569. func Xxcb_ungrab_server_checked(tls *libc.TLS, c uintptr) (r Txcb_void_cookie_t) {
  12570. bp := tls.Alloc(80)
  12571. defer tls.Free(80)
  12572. var xcb_ret Txcb_void_cookie_t
  12573. var _ /* xcb_out at bp+64 */ Txcb_ungrab_server_request_t
  12574. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12575. _ = xcb_ret
  12576. (*(*Txcb_ungrab_server_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12577. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12578. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  12579. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12580. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12581. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req78)))
  12582. return xcb_ret
  12583. }
  12584. var _xcb_req78 = Txcb_protocol_request_t{
  12585. Fcount: uint64(2),
  12586. Fopcode: uint8(m_XCB_UNGRAB_SERVER),
  12587. Fisvoid: uint8(1),
  12588. }
  12589. func Xxcb_ungrab_server(tls *libc.TLS, c uintptr) (r Txcb_void_cookie_t) {
  12590. bp := tls.Alloc(80)
  12591. defer tls.Free(80)
  12592. var xcb_ret Txcb_void_cookie_t
  12593. var _ /* xcb_out at bp+64 */ Txcb_ungrab_server_request_t
  12594. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12595. _ = xcb_ret
  12596. (*(*Txcb_ungrab_server_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12597. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12598. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  12599. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12600. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12601. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req79)))
  12602. return xcb_ret
  12603. }
  12604. var _xcb_req79 = Txcb_protocol_request_t{
  12605. Fcount: uint64(2),
  12606. Fopcode: uint8(m_XCB_UNGRAB_SERVER),
  12607. Fisvoid: uint8(1),
  12608. }
  12609. func Xxcb_query_pointer(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_query_pointer_cookie_t) {
  12610. bp := tls.Alloc(80)
  12611. defer tls.Free(80)
  12612. var xcb_ret Txcb_query_pointer_cookie_t
  12613. var _ /* xcb_out at bp+64 */ Txcb_query_pointer_request_t
  12614. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12615. _ = xcb_ret
  12616. (*(*Txcb_query_pointer_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12617. (*(*Txcb_query_pointer_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  12618. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12619. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  12620. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12621. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12622. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req80)))
  12623. return xcb_ret
  12624. }
  12625. var _xcb_req80 = Txcb_protocol_request_t{
  12626. Fcount: uint64(2),
  12627. Fopcode: uint8(m_XCB_QUERY_POINTER),
  12628. }
  12629. func Xxcb_query_pointer_unchecked(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_query_pointer_cookie_t) {
  12630. bp := tls.Alloc(80)
  12631. defer tls.Free(80)
  12632. var xcb_ret Txcb_query_pointer_cookie_t
  12633. var _ /* xcb_out at bp+64 */ Txcb_query_pointer_request_t
  12634. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12635. _ = xcb_ret
  12636. (*(*Txcb_query_pointer_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12637. (*(*Txcb_query_pointer_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  12638. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12639. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  12640. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12641. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12642. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req81)))
  12643. return xcb_ret
  12644. }
  12645. var _xcb_req81 = Txcb_protocol_request_t{
  12646. Fcount: uint64(2),
  12647. Fopcode: uint8(m_XCB_QUERY_POINTER),
  12648. }
  12649. func Xxcb_query_pointer_reply(tls *libc.TLS, c uintptr, cookie Txcb_query_pointer_cookie_t, e uintptr) (r uintptr) {
  12650. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  12651. }
  12652. func Xxcb_timecoord_next(tls *libc.TLS, i uintptr) {
  12653. var p1 uintptr
  12654. _ = p1
  12655. (*Txcb_timecoord_iterator_t)(unsafe.Pointer(i)).Frem--
  12656. (*Txcb_timecoord_iterator_t)(unsafe.Pointer(i)).Fdata += 8
  12657. p1 = i + 12
  12658. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(8))
  12659. }
  12660. func Xxcb_timecoord_end(tls *libc.TLS, i Txcb_timecoord_iterator_t) (r Txcb_generic_iterator_t) {
  12661. var ret Txcb_generic_iterator_t
  12662. _ = ret
  12663. ret.Fdata = i.Fdata + uintptr(i.Frem)*8
  12664. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  12665. ret.Frem = 0
  12666. return ret
  12667. }
  12668. func Xxcb_get_motion_events_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  12669. var _aux, xcb_tmp uintptr
  12670. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  12671. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  12672. xcb_tmp = _buffer
  12673. _aux = _buffer
  12674. xcb_buffer_len = uint32(0)
  12675. xcb_block_len = uint32(0)
  12676. xcb_pad = uint32(0)
  12677. xcb_align_to = uint32(0)
  12678. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(32))
  12679. xcb_tmp += uintptr(xcb_block_len)
  12680. xcb_buffer_len += xcb_block_len
  12681. xcb_block_len = uint32(0)
  12682. /* events */
  12683. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_get_motion_events_reply_t)(unsafe.Pointer(_aux)).Fevents_len)*libc.Uint64FromInt64(8))
  12684. xcb_tmp += uintptr(xcb_block_len)
  12685. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  12686. /* insert padding */
  12687. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  12688. xcb_buffer_len += xcb_block_len + xcb_pad
  12689. if uint32(0) != xcb_pad {
  12690. xcb_tmp += uintptr(xcb_pad)
  12691. xcb_pad = uint32(0)
  12692. }
  12693. xcb_block_len = uint32(0)
  12694. return libc.Int32FromUint32(xcb_buffer_len)
  12695. }
  12696. func Xxcb_get_motion_events(tls *libc.TLS, c uintptr, window Txcb_window_t, start Txcb_timestamp_t, stop Txcb_timestamp_t) (r Txcb_get_motion_events_cookie_t) {
  12697. bp := tls.Alloc(80)
  12698. defer tls.Free(80)
  12699. var xcb_ret Txcb_get_motion_events_cookie_t
  12700. var _ /* xcb_out at bp+64 */ Txcb_get_motion_events_request_t
  12701. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12702. _ = xcb_ret
  12703. (*(*Txcb_get_motion_events_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12704. (*(*Txcb_get_motion_events_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  12705. (*(*Txcb_get_motion_events_request_t)(unsafe.Pointer(bp + 64))).Fstart = start
  12706. (*(*Txcb_get_motion_events_request_t)(unsafe.Pointer(bp + 64))).Fstop = stop
  12707. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12708. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  12709. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12710. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12711. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req82)))
  12712. return xcb_ret
  12713. }
  12714. var _xcb_req82 = Txcb_protocol_request_t{
  12715. Fcount: uint64(2),
  12716. Fopcode: uint8(m_XCB_GET_MOTION_EVENTS),
  12717. }
  12718. func Xxcb_get_motion_events_unchecked(tls *libc.TLS, c uintptr, window Txcb_window_t, start Txcb_timestamp_t, stop Txcb_timestamp_t) (r Txcb_get_motion_events_cookie_t) {
  12719. bp := tls.Alloc(80)
  12720. defer tls.Free(80)
  12721. var xcb_ret Txcb_get_motion_events_cookie_t
  12722. var _ /* xcb_out at bp+64 */ Txcb_get_motion_events_request_t
  12723. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12724. _ = xcb_ret
  12725. (*(*Txcb_get_motion_events_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12726. (*(*Txcb_get_motion_events_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  12727. (*(*Txcb_get_motion_events_request_t)(unsafe.Pointer(bp + 64))).Fstart = start
  12728. (*(*Txcb_get_motion_events_request_t)(unsafe.Pointer(bp + 64))).Fstop = stop
  12729. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12730. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  12731. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12732. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12733. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req83)))
  12734. return xcb_ret
  12735. }
  12736. var _xcb_req83 = Txcb_protocol_request_t{
  12737. Fcount: uint64(2),
  12738. Fopcode: uint8(m_XCB_GET_MOTION_EVENTS),
  12739. }
  12740. func Xxcb_get_motion_events_events(tls *libc.TLS, R uintptr) (r uintptr) {
  12741. return R + libc.UintptrFromInt32(1)*32
  12742. }
  12743. func Xxcb_get_motion_events_events_length(tls *libc.TLS, R uintptr) (r int32) {
  12744. return libc.Int32FromUint32((*Txcb_get_motion_events_reply_t)(unsafe.Pointer(R)).Fevents_len)
  12745. }
  12746. func Xxcb_get_motion_events_events_iterator(tls *libc.TLS, R uintptr) (r Txcb_timecoord_iterator_t) {
  12747. var i Txcb_timecoord_iterator_t
  12748. _ = i
  12749. i.Fdata = R + libc.UintptrFromInt32(1)*32
  12750. i.Frem = libc.Int32FromUint32((*Txcb_get_motion_events_reply_t)(unsafe.Pointer(R)).Fevents_len)
  12751. i.Findex = int32(int64(i.Fdata) - int64(R))
  12752. return i
  12753. }
  12754. func Xxcb_get_motion_events_reply(tls *libc.TLS, c uintptr, cookie Txcb_get_motion_events_cookie_t, e uintptr) (r uintptr) {
  12755. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  12756. }
  12757. func Xxcb_translate_coordinates(tls *libc.TLS, c uintptr, src_window Txcb_window_t, dst_window Txcb_window_t, src_x Tint16_t, src_y Tint16_t) (r Txcb_translate_coordinates_cookie_t) {
  12758. bp := tls.Alloc(80)
  12759. defer tls.Free(80)
  12760. var xcb_ret Txcb_translate_coordinates_cookie_t
  12761. var _ /* xcb_out at bp+64 */ Txcb_translate_coordinates_request_t
  12762. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12763. _ = xcb_ret
  12764. (*(*Txcb_translate_coordinates_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12765. (*(*Txcb_translate_coordinates_request_t)(unsafe.Pointer(bp + 64))).Fsrc_window = src_window
  12766. (*(*Txcb_translate_coordinates_request_t)(unsafe.Pointer(bp + 64))).Fdst_window = dst_window
  12767. (*(*Txcb_translate_coordinates_request_t)(unsafe.Pointer(bp + 64))).Fsrc_x = src_x
  12768. (*(*Txcb_translate_coordinates_request_t)(unsafe.Pointer(bp + 64))).Fsrc_y = src_y
  12769. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12770. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  12771. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12772. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12773. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req84)))
  12774. return xcb_ret
  12775. }
  12776. var _xcb_req84 = Txcb_protocol_request_t{
  12777. Fcount: uint64(2),
  12778. Fopcode: uint8(m_XCB_TRANSLATE_COORDINATES),
  12779. }
  12780. func Xxcb_translate_coordinates_unchecked(tls *libc.TLS, c uintptr, src_window Txcb_window_t, dst_window Txcb_window_t, src_x Tint16_t, src_y Tint16_t) (r Txcb_translate_coordinates_cookie_t) {
  12781. bp := tls.Alloc(80)
  12782. defer tls.Free(80)
  12783. var xcb_ret Txcb_translate_coordinates_cookie_t
  12784. var _ /* xcb_out at bp+64 */ Txcb_translate_coordinates_request_t
  12785. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12786. _ = xcb_ret
  12787. (*(*Txcb_translate_coordinates_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12788. (*(*Txcb_translate_coordinates_request_t)(unsafe.Pointer(bp + 64))).Fsrc_window = src_window
  12789. (*(*Txcb_translate_coordinates_request_t)(unsafe.Pointer(bp + 64))).Fdst_window = dst_window
  12790. (*(*Txcb_translate_coordinates_request_t)(unsafe.Pointer(bp + 64))).Fsrc_x = src_x
  12791. (*(*Txcb_translate_coordinates_request_t)(unsafe.Pointer(bp + 64))).Fsrc_y = src_y
  12792. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12793. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  12794. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12795. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12796. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req85)))
  12797. return xcb_ret
  12798. }
  12799. var _xcb_req85 = Txcb_protocol_request_t{
  12800. Fcount: uint64(2),
  12801. Fopcode: uint8(m_XCB_TRANSLATE_COORDINATES),
  12802. }
  12803. func Xxcb_translate_coordinates_reply(tls *libc.TLS, c uintptr, cookie Txcb_translate_coordinates_cookie_t, e uintptr) (r uintptr) {
  12804. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  12805. }
  12806. func Xxcb_warp_pointer_checked(tls *libc.TLS, c uintptr, src_window Txcb_window_t, dst_window Txcb_window_t, src_x Tint16_t, src_y Tint16_t, src_width Tuint16_t, src_height Tuint16_t, dst_x Tint16_t, dst_y Tint16_t) (r Txcb_void_cookie_t) {
  12807. bp := tls.Alloc(96)
  12808. defer tls.Free(96)
  12809. var xcb_ret Txcb_void_cookie_t
  12810. var _ /* xcb_out at bp+64 */ Txcb_warp_pointer_request_t
  12811. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12812. _ = xcb_ret
  12813. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12814. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fsrc_window = src_window
  12815. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fdst_window = dst_window
  12816. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fsrc_x = src_x
  12817. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fsrc_y = src_y
  12818. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fsrc_width = src_width
  12819. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fsrc_height = src_height
  12820. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fdst_x = dst_x
  12821. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fdst_y = dst_y
  12822. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12823. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(24)
  12824. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12825. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12826. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req86)))
  12827. return xcb_ret
  12828. }
  12829. var _xcb_req86 = Txcb_protocol_request_t{
  12830. Fcount: uint64(2),
  12831. Fopcode: uint8(m_XCB_WARP_POINTER),
  12832. Fisvoid: uint8(1),
  12833. }
  12834. func Xxcb_warp_pointer(tls *libc.TLS, c uintptr, src_window Txcb_window_t, dst_window Txcb_window_t, src_x Tint16_t, src_y Tint16_t, src_width Tuint16_t, src_height Tuint16_t, dst_x Tint16_t, dst_y Tint16_t) (r Txcb_void_cookie_t) {
  12835. bp := tls.Alloc(96)
  12836. defer tls.Free(96)
  12837. var xcb_ret Txcb_void_cookie_t
  12838. var _ /* xcb_out at bp+64 */ Txcb_warp_pointer_request_t
  12839. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12840. _ = xcb_ret
  12841. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12842. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fsrc_window = src_window
  12843. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fdst_window = dst_window
  12844. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fsrc_x = src_x
  12845. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fsrc_y = src_y
  12846. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fsrc_width = src_width
  12847. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fsrc_height = src_height
  12848. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fdst_x = dst_x
  12849. (*(*Txcb_warp_pointer_request_t)(unsafe.Pointer(bp + 64))).Fdst_y = dst_y
  12850. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12851. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(24)
  12852. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12853. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12854. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req87)))
  12855. return xcb_ret
  12856. }
  12857. var _xcb_req87 = Txcb_protocol_request_t{
  12858. Fcount: uint64(2),
  12859. Fopcode: uint8(m_XCB_WARP_POINTER),
  12860. Fisvoid: uint8(1),
  12861. }
  12862. func Xxcb_set_input_focus_checked(tls *libc.TLS, c uintptr, revert_to Tuint8_t, focus Txcb_window_t, time Txcb_timestamp_t) (r Txcb_void_cookie_t) {
  12863. bp := tls.Alloc(80)
  12864. defer tls.Free(80)
  12865. var xcb_ret Txcb_void_cookie_t
  12866. var _ /* xcb_out at bp+64 */ Txcb_set_input_focus_request_t
  12867. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12868. _ = xcb_ret
  12869. (*(*Txcb_set_input_focus_request_t)(unsafe.Pointer(bp + 64))).Frevert_to = revert_to
  12870. (*(*Txcb_set_input_focus_request_t)(unsafe.Pointer(bp + 64))).Ffocus = focus
  12871. (*(*Txcb_set_input_focus_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  12872. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12873. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  12874. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12875. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12876. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req88)))
  12877. return xcb_ret
  12878. }
  12879. var _xcb_req88 = Txcb_protocol_request_t{
  12880. Fcount: uint64(2),
  12881. Fopcode: uint8(m_XCB_SET_INPUT_FOCUS),
  12882. Fisvoid: uint8(1),
  12883. }
  12884. func Xxcb_set_input_focus(tls *libc.TLS, c uintptr, revert_to Tuint8_t, focus Txcb_window_t, time Txcb_timestamp_t) (r Txcb_void_cookie_t) {
  12885. bp := tls.Alloc(80)
  12886. defer tls.Free(80)
  12887. var xcb_ret Txcb_void_cookie_t
  12888. var _ /* xcb_out at bp+64 */ Txcb_set_input_focus_request_t
  12889. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12890. _ = xcb_ret
  12891. (*(*Txcb_set_input_focus_request_t)(unsafe.Pointer(bp + 64))).Frevert_to = revert_to
  12892. (*(*Txcb_set_input_focus_request_t)(unsafe.Pointer(bp + 64))).Ffocus = focus
  12893. (*(*Txcb_set_input_focus_request_t)(unsafe.Pointer(bp + 64))).Ftime = time
  12894. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12895. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  12896. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12897. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12898. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req89)))
  12899. return xcb_ret
  12900. }
  12901. var _xcb_req89 = Txcb_protocol_request_t{
  12902. Fcount: uint64(2),
  12903. Fopcode: uint8(m_XCB_SET_INPUT_FOCUS),
  12904. Fisvoid: uint8(1),
  12905. }
  12906. func Xxcb_get_input_focus(tls *libc.TLS, c uintptr) (r Txcb_get_input_focus_cookie_t) {
  12907. bp := tls.Alloc(80)
  12908. defer tls.Free(80)
  12909. var xcb_ret Txcb_get_input_focus_cookie_t
  12910. var _ /* xcb_out at bp+64 */ Txcb_get_input_focus_request_t
  12911. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12912. _ = xcb_ret
  12913. (*(*Txcb_get_input_focus_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12914. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12915. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  12916. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12917. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12918. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req90)))
  12919. return xcb_ret
  12920. }
  12921. var _xcb_req90 = Txcb_protocol_request_t{
  12922. Fcount: uint64(2),
  12923. Fopcode: uint8(m_XCB_GET_INPUT_FOCUS),
  12924. }
  12925. func Xxcb_get_input_focus_unchecked(tls *libc.TLS, c uintptr) (r Txcb_get_input_focus_cookie_t) {
  12926. bp := tls.Alloc(80)
  12927. defer tls.Free(80)
  12928. var xcb_ret Txcb_get_input_focus_cookie_t
  12929. var _ /* xcb_out at bp+64 */ Txcb_get_input_focus_request_t
  12930. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12931. _ = xcb_ret
  12932. (*(*Txcb_get_input_focus_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12933. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12934. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  12935. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12936. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12937. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req91)))
  12938. return xcb_ret
  12939. }
  12940. var _xcb_req91 = Txcb_protocol_request_t{
  12941. Fcount: uint64(2),
  12942. Fopcode: uint8(m_XCB_GET_INPUT_FOCUS),
  12943. }
  12944. func Xxcb_get_input_focus_reply(tls *libc.TLS, c uintptr, cookie Txcb_get_input_focus_cookie_t, e uintptr) (r uintptr) {
  12945. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  12946. }
  12947. func Xxcb_query_keymap(tls *libc.TLS, c uintptr) (r Txcb_query_keymap_cookie_t) {
  12948. bp := tls.Alloc(80)
  12949. defer tls.Free(80)
  12950. var xcb_ret Txcb_query_keymap_cookie_t
  12951. var _ /* xcb_out at bp+64 */ Txcb_query_keymap_request_t
  12952. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12953. _ = xcb_ret
  12954. (*(*Txcb_query_keymap_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12955. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12956. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  12957. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12958. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12959. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req92)))
  12960. return xcb_ret
  12961. }
  12962. var _xcb_req92 = Txcb_protocol_request_t{
  12963. Fcount: uint64(2),
  12964. Fopcode: uint8(m_XCB_QUERY_KEYMAP),
  12965. }
  12966. func Xxcb_query_keymap_unchecked(tls *libc.TLS, c uintptr) (r Txcb_query_keymap_cookie_t) {
  12967. bp := tls.Alloc(80)
  12968. defer tls.Free(80)
  12969. var xcb_ret Txcb_query_keymap_cookie_t
  12970. var _ /* xcb_out at bp+64 */ Txcb_query_keymap_request_t
  12971. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  12972. _ = xcb_ret
  12973. (*(*Txcb_query_keymap_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  12974. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  12975. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  12976. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  12977. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  12978. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req93)))
  12979. return xcb_ret
  12980. }
  12981. var _xcb_req93 = Txcb_protocol_request_t{
  12982. Fcount: uint64(2),
  12983. Fopcode: uint8(m_XCB_QUERY_KEYMAP),
  12984. }
  12985. func Xxcb_query_keymap_reply(tls *libc.TLS, c uintptr, cookie Txcb_query_keymap_cookie_t, e uintptr) (r uintptr) {
  12986. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  12987. }
  12988. func Xxcb_open_font_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  12989. var _aux, xcb_tmp uintptr
  12990. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  12991. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  12992. xcb_tmp = _buffer
  12993. _aux = _buffer
  12994. xcb_buffer_len = uint32(0)
  12995. xcb_block_len = uint32(0)
  12996. xcb_pad = uint32(0)
  12997. xcb_align_to = uint32(0)
  12998. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  12999. xcb_tmp += uintptr(xcb_block_len)
  13000. xcb_buffer_len += xcb_block_len
  13001. xcb_block_len = uint32(0)
  13002. /* name */
  13003. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_open_font_request_t)(unsafe.Pointer(_aux)).Fname_len)*libc.Uint64FromInt64(1))
  13004. xcb_tmp += uintptr(xcb_block_len)
  13005. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  13006. /* insert padding */
  13007. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  13008. xcb_buffer_len += xcb_block_len + xcb_pad
  13009. if uint32(0) != xcb_pad {
  13010. xcb_tmp += uintptr(xcb_pad)
  13011. xcb_pad = uint32(0)
  13012. }
  13013. xcb_block_len = uint32(0)
  13014. return libc.Int32FromUint32(xcb_buffer_len)
  13015. }
  13016. func Xxcb_open_font_checked(tls *libc.TLS, c uintptr, fid Txcb_font_t, name_len Tuint16_t, name uintptr) (r Txcb_void_cookie_t) {
  13017. bp := tls.Alloc(112)
  13018. defer tls.Free(112)
  13019. var xcb_ret Txcb_void_cookie_t
  13020. var _ /* xcb_out at bp+96 */ Txcb_open_font_request_t
  13021. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  13022. _ = xcb_ret
  13023. (*(*Txcb_open_font_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  13024. (*(*Txcb_open_font_request_t)(unsafe.Pointer(bp + 96))).Ffid = fid
  13025. (*(*Txcb_open_font_request_t)(unsafe.Pointer(bp + 96))).Fname_len = name_len
  13026. libc.Xmemset(tls, bp+96+10, 0, uint64(2))
  13027. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  13028. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  13029. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13030. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13031. /* char name */
  13032. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = name
  13033. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(name_len) * uint64(1)
  13034. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  13035. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  13036. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req94)))
  13037. return xcb_ret
  13038. }
  13039. var _xcb_req94 = Txcb_protocol_request_t{
  13040. Fcount: uint64(4),
  13041. Fopcode: uint8(m_XCB_OPEN_FONT),
  13042. Fisvoid: uint8(1),
  13043. }
  13044. func Xxcb_open_font(tls *libc.TLS, c uintptr, fid Txcb_font_t, name_len Tuint16_t, name uintptr) (r Txcb_void_cookie_t) {
  13045. bp := tls.Alloc(112)
  13046. defer tls.Free(112)
  13047. var xcb_ret Txcb_void_cookie_t
  13048. var _ /* xcb_out at bp+96 */ Txcb_open_font_request_t
  13049. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  13050. _ = xcb_ret
  13051. (*(*Txcb_open_font_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  13052. (*(*Txcb_open_font_request_t)(unsafe.Pointer(bp + 96))).Ffid = fid
  13053. (*(*Txcb_open_font_request_t)(unsafe.Pointer(bp + 96))).Fname_len = name_len
  13054. libc.Xmemset(tls, bp+96+10, 0, uint64(2))
  13055. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  13056. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  13057. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13058. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13059. /* char name */
  13060. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = name
  13061. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(name_len) * uint64(1)
  13062. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  13063. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  13064. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req95)))
  13065. return xcb_ret
  13066. }
  13067. var _xcb_req95 = Txcb_protocol_request_t{
  13068. Fcount: uint64(4),
  13069. Fopcode: uint8(m_XCB_OPEN_FONT),
  13070. Fisvoid: uint8(1),
  13071. }
  13072. func Xxcb_open_font_name(tls *libc.TLS, R uintptr) (r uintptr) {
  13073. return R + libc.UintptrFromInt32(1)*12
  13074. }
  13075. func Xxcb_open_font_name_length(tls *libc.TLS, R uintptr) (r int32) {
  13076. return libc.Int32FromUint16((*Txcb_open_font_request_t)(unsafe.Pointer(R)).Fname_len)
  13077. }
  13078. func Xxcb_open_font_name_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  13079. var i Txcb_generic_iterator_t
  13080. _ = i
  13081. i.Fdata = R + libc.UintptrFromInt32(1)*12 + uintptr((*Txcb_open_font_request_t)(unsafe.Pointer(R)).Fname_len)
  13082. i.Frem = 0
  13083. i.Findex = int32(int64(i.Fdata) - int64(R))
  13084. return i
  13085. }
  13086. func Xxcb_close_font_checked(tls *libc.TLS, c uintptr, font Txcb_font_t) (r Txcb_void_cookie_t) {
  13087. bp := tls.Alloc(80)
  13088. defer tls.Free(80)
  13089. var xcb_ret Txcb_void_cookie_t
  13090. var _ /* xcb_out at bp+64 */ Txcb_close_font_request_t
  13091. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  13092. _ = xcb_ret
  13093. (*(*Txcb_close_font_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  13094. (*(*Txcb_close_font_request_t)(unsafe.Pointer(bp + 64))).Ffont = font
  13095. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  13096. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  13097. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13098. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13099. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req96)))
  13100. return xcb_ret
  13101. }
  13102. var _xcb_req96 = Txcb_protocol_request_t{
  13103. Fcount: uint64(2),
  13104. Fopcode: uint8(m_XCB_CLOSE_FONT),
  13105. Fisvoid: uint8(1),
  13106. }
  13107. func Xxcb_close_font(tls *libc.TLS, c uintptr, font Txcb_font_t) (r Txcb_void_cookie_t) {
  13108. bp := tls.Alloc(80)
  13109. defer tls.Free(80)
  13110. var xcb_ret Txcb_void_cookie_t
  13111. var _ /* xcb_out at bp+64 */ Txcb_close_font_request_t
  13112. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  13113. _ = xcb_ret
  13114. (*(*Txcb_close_font_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  13115. (*(*Txcb_close_font_request_t)(unsafe.Pointer(bp + 64))).Ffont = font
  13116. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  13117. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  13118. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13119. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13120. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req97)))
  13121. return xcb_ret
  13122. }
  13123. var _xcb_req97 = Txcb_protocol_request_t{
  13124. Fcount: uint64(2),
  13125. Fopcode: uint8(m_XCB_CLOSE_FONT),
  13126. Fisvoid: uint8(1),
  13127. }
  13128. func Xxcb_fontprop_next(tls *libc.TLS, i uintptr) {
  13129. var p1 uintptr
  13130. _ = p1
  13131. (*Txcb_fontprop_iterator_t)(unsafe.Pointer(i)).Frem--
  13132. (*Txcb_fontprop_iterator_t)(unsafe.Pointer(i)).Fdata += 8
  13133. p1 = i + 12
  13134. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(8))
  13135. }
  13136. func Xxcb_fontprop_end(tls *libc.TLS, i Txcb_fontprop_iterator_t) (r Txcb_generic_iterator_t) {
  13137. var ret Txcb_generic_iterator_t
  13138. _ = ret
  13139. ret.Fdata = i.Fdata + uintptr(i.Frem)*8
  13140. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  13141. ret.Frem = 0
  13142. return ret
  13143. }
  13144. func Xxcb_charinfo_next(tls *libc.TLS, i uintptr) {
  13145. var p1 uintptr
  13146. _ = p1
  13147. (*Txcb_charinfo_iterator_t)(unsafe.Pointer(i)).Frem--
  13148. (*Txcb_charinfo_iterator_t)(unsafe.Pointer(i)).Fdata += 12
  13149. p1 = i + 12
  13150. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(12))
  13151. }
  13152. func Xxcb_charinfo_end(tls *libc.TLS, i Txcb_charinfo_iterator_t) (r Txcb_generic_iterator_t) {
  13153. var ret Txcb_generic_iterator_t
  13154. _ = ret
  13155. ret.Fdata = i.Fdata + uintptr(i.Frem)*12
  13156. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  13157. ret.Frem = 0
  13158. return ret
  13159. }
  13160. func Xxcb_query_font_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  13161. var _aux, xcb_tmp uintptr
  13162. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  13163. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  13164. xcb_tmp = _buffer
  13165. _aux = _buffer
  13166. xcb_buffer_len = uint32(0)
  13167. xcb_block_len = uint32(0)
  13168. xcb_pad = uint32(0)
  13169. xcb_align_to = uint32(0)
  13170. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(60))
  13171. xcb_tmp += uintptr(xcb_block_len)
  13172. xcb_buffer_len += xcb_block_len
  13173. xcb_block_len = uint32(0)
  13174. /* properties */
  13175. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_query_font_reply_t)(unsafe.Pointer(_aux)).Fproperties_len)*libc.Uint64FromInt64(8))
  13176. xcb_tmp += uintptr(xcb_block_len)
  13177. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  13178. /* insert padding */
  13179. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  13180. xcb_buffer_len += xcb_block_len + xcb_pad
  13181. if uint32(0) != xcb_pad {
  13182. xcb_tmp += uintptr(xcb_pad)
  13183. xcb_pad = uint32(0)
  13184. }
  13185. xcb_block_len = uint32(0)
  13186. /* char_infos */
  13187. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_query_font_reply_t)(unsafe.Pointer(_aux)).Fchar_infos_len)*libc.Uint64FromInt64(12))
  13188. xcb_tmp += uintptr(xcb_block_len)
  13189. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 2))
  13190. /* insert padding */
  13191. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  13192. xcb_buffer_len += xcb_block_len + xcb_pad
  13193. if uint32(0) != xcb_pad {
  13194. xcb_tmp += uintptr(xcb_pad)
  13195. xcb_pad = uint32(0)
  13196. }
  13197. xcb_block_len = uint32(0)
  13198. return libc.Int32FromUint32(xcb_buffer_len)
  13199. }
  13200. func Xxcb_query_font(tls *libc.TLS, c uintptr, font Txcb_fontable_t) (r Txcb_query_font_cookie_t) {
  13201. bp := tls.Alloc(80)
  13202. defer tls.Free(80)
  13203. var xcb_ret Txcb_query_font_cookie_t
  13204. var _ /* xcb_out at bp+64 */ Txcb_query_font_request_t
  13205. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  13206. _ = xcb_ret
  13207. (*(*Txcb_query_font_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  13208. (*(*Txcb_query_font_request_t)(unsafe.Pointer(bp + 64))).Ffont = font
  13209. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  13210. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  13211. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13212. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13213. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req98)))
  13214. return xcb_ret
  13215. }
  13216. var _xcb_req98 = Txcb_protocol_request_t{
  13217. Fcount: uint64(2),
  13218. Fopcode: uint8(m_XCB_QUERY_FONT),
  13219. }
  13220. func Xxcb_query_font_unchecked(tls *libc.TLS, c uintptr, font Txcb_fontable_t) (r Txcb_query_font_cookie_t) {
  13221. bp := tls.Alloc(80)
  13222. defer tls.Free(80)
  13223. var xcb_ret Txcb_query_font_cookie_t
  13224. var _ /* xcb_out at bp+64 */ Txcb_query_font_request_t
  13225. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  13226. _ = xcb_ret
  13227. (*(*Txcb_query_font_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  13228. (*(*Txcb_query_font_request_t)(unsafe.Pointer(bp + 64))).Ffont = font
  13229. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  13230. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  13231. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13232. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13233. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req99)))
  13234. return xcb_ret
  13235. }
  13236. var _xcb_req99 = Txcb_protocol_request_t{
  13237. Fcount: uint64(2),
  13238. Fopcode: uint8(m_XCB_QUERY_FONT),
  13239. }
  13240. func Xxcb_query_font_properties(tls *libc.TLS, R uintptr) (r uintptr) {
  13241. return R + libc.UintptrFromInt32(1)*60
  13242. }
  13243. func Xxcb_query_font_properties_length(tls *libc.TLS, R uintptr) (r int32) {
  13244. return libc.Int32FromUint16((*Txcb_query_font_reply_t)(unsafe.Pointer(R)).Fproperties_len)
  13245. }
  13246. func Xxcb_query_font_properties_iterator(tls *libc.TLS, R uintptr) (r Txcb_fontprop_iterator_t) {
  13247. var i Txcb_fontprop_iterator_t
  13248. _ = i
  13249. i.Fdata = R + libc.UintptrFromInt32(1)*60
  13250. i.Frem = libc.Int32FromUint16((*Txcb_query_font_reply_t)(unsafe.Pointer(R)).Fproperties_len)
  13251. i.Findex = int32(int64(i.Fdata) - int64(R))
  13252. return i
  13253. }
  13254. func Xxcb_query_font_char_infos(tls *libc.TLS, R uintptr) (r uintptr) {
  13255. var prev Txcb_generic_iterator_t
  13256. _ = prev
  13257. prev = Xxcb_fontprop_end(tls, Xxcb_query_font_properties_iterator(tls, R))
  13258. return prev.Fdata + uintptr(libc.Uint64FromInt32(-prev.Findex)&libc.Uint64FromInt32(3)) + libc.UintptrFromInt32(0)
  13259. }
  13260. func Xxcb_query_font_char_infos_length(tls *libc.TLS, R uintptr) (r int32) {
  13261. return libc.Int32FromUint32((*Txcb_query_font_reply_t)(unsafe.Pointer(R)).Fchar_infos_len)
  13262. }
  13263. func Xxcb_query_font_char_infos_iterator(tls *libc.TLS, R uintptr) (r Txcb_charinfo_iterator_t) {
  13264. var i Txcb_charinfo_iterator_t
  13265. var prev Txcb_generic_iterator_t
  13266. _, _ = i, prev
  13267. prev = Xxcb_fontprop_end(tls, Xxcb_query_font_properties_iterator(tls, R))
  13268. i.Fdata = prev.Fdata + uintptr(libc.Uint64FromInt32(-prev.Findex)&libc.Uint64FromInt32(3))
  13269. i.Frem = libc.Int32FromUint32((*Txcb_query_font_reply_t)(unsafe.Pointer(R)).Fchar_infos_len)
  13270. i.Findex = int32(int64(i.Fdata) - int64(R))
  13271. return i
  13272. }
  13273. func Xxcb_query_font_reply(tls *libc.TLS, c uintptr, cookie Txcb_query_font_cookie_t, e uintptr) (r uintptr) {
  13274. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  13275. }
  13276. func Xxcb_query_text_extents_sizeof(tls *libc.TLS, _buffer uintptr, string_len Tuint32_t) (r int32) {
  13277. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  13278. var xcb_tmp uintptr
  13279. _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  13280. xcb_tmp = _buffer
  13281. xcb_buffer_len = uint32(0)
  13282. xcb_block_len = uint32(0)
  13283. xcb_pad = uint32(0)
  13284. xcb_align_to = uint32(0)
  13285. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(8))
  13286. xcb_tmp += uintptr(xcb_block_len)
  13287. xcb_buffer_len += xcb_block_len
  13288. xcb_block_len = uint32(0)
  13289. /* string */
  13290. xcb_block_len = uint32(uint64(xcb_block_len) + uint64(string_len)*libc.Uint64FromInt64(2))
  13291. xcb_tmp += uintptr(xcb_block_len)
  13292. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  13293. /* insert padding */
  13294. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  13295. xcb_buffer_len += xcb_block_len + xcb_pad
  13296. if uint32(0) != xcb_pad {
  13297. xcb_tmp += uintptr(xcb_pad)
  13298. xcb_pad = uint32(0)
  13299. }
  13300. xcb_block_len = uint32(0)
  13301. return libc.Int32FromUint32(xcb_buffer_len)
  13302. }
  13303. func Xxcb_query_text_extents(tls *libc.TLS, c uintptr, font Txcb_fontable_t, string_len Tuint32_t, string1 uintptr) (r Txcb_query_text_extents_cookie_t) {
  13304. bp := tls.Alloc(112)
  13305. defer tls.Free(112)
  13306. var xcb_ret Txcb_query_text_extents_cookie_t
  13307. var _ /* xcb_out at bp+96 */ Txcb_query_text_extents_request_t
  13308. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  13309. _ = xcb_ret
  13310. (*(*Txcb_query_text_extents_request_t)(unsafe.Pointer(bp + 96))).Fodd_length = uint8(string_len & libc.Uint32FromInt32(1))
  13311. (*(*Txcb_query_text_extents_request_t)(unsafe.Pointer(bp + 96))).Ffont = font
  13312. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  13313. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  13314. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13315. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13316. /* xcb_char2b_t string */
  13317. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = string1
  13318. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(string_len) * uint64(2)
  13319. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  13320. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  13321. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req100)))
  13322. return xcb_ret
  13323. }
  13324. var _xcb_req100 = Txcb_protocol_request_t{
  13325. Fcount: uint64(4),
  13326. Fopcode: uint8(m_XCB_QUERY_TEXT_EXTENTS),
  13327. }
  13328. func Xxcb_query_text_extents_unchecked(tls *libc.TLS, c uintptr, font Txcb_fontable_t, string_len Tuint32_t, string1 uintptr) (r Txcb_query_text_extents_cookie_t) {
  13329. bp := tls.Alloc(112)
  13330. defer tls.Free(112)
  13331. var xcb_ret Txcb_query_text_extents_cookie_t
  13332. var _ /* xcb_out at bp+96 */ Txcb_query_text_extents_request_t
  13333. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  13334. _ = xcb_ret
  13335. (*(*Txcb_query_text_extents_request_t)(unsafe.Pointer(bp + 96))).Fodd_length = uint8(string_len & libc.Uint32FromInt32(1))
  13336. (*(*Txcb_query_text_extents_request_t)(unsafe.Pointer(bp + 96))).Ffont = font
  13337. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  13338. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  13339. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13340. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13341. /* xcb_char2b_t string */
  13342. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = string1
  13343. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(string_len) * uint64(2)
  13344. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  13345. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  13346. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req101)))
  13347. return xcb_ret
  13348. }
  13349. var _xcb_req101 = Txcb_protocol_request_t{
  13350. Fcount: uint64(4),
  13351. Fopcode: uint8(m_XCB_QUERY_TEXT_EXTENTS),
  13352. }
  13353. func Xxcb_query_text_extents_reply(tls *libc.TLS, c uintptr, cookie Txcb_query_text_extents_cookie_t, e uintptr) (r uintptr) {
  13354. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  13355. }
  13356. func Xxcb_str_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  13357. var _aux, xcb_tmp uintptr
  13358. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  13359. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  13360. xcb_tmp = _buffer
  13361. _aux = _buffer
  13362. xcb_buffer_len = uint32(0)
  13363. xcb_block_len = uint32(0)
  13364. xcb_pad = uint32(0)
  13365. xcb_align_to = uint32(0)
  13366. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(1))
  13367. xcb_tmp += uintptr(xcb_block_len)
  13368. xcb_buffer_len += xcb_block_len
  13369. xcb_block_len = uint32(0)
  13370. /* name */
  13371. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_str_t)(unsafe.Pointer(_aux)).Fname_len)*libc.Uint64FromInt64(1))
  13372. xcb_tmp += uintptr(xcb_block_len)
  13373. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  13374. /* insert padding */
  13375. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  13376. xcb_buffer_len += xcb_block_len + xcb_pad
  13377. if uint32(0) != xcb_pad {
  13378. xcb_tmp += uintptr(xcb_pad)
  13379. xcb_pad = uint32(0)
  13380. }
  13381. xcb_block_len = uint32(0)
  13382. return libc.Int32FromUint32(xcb_buffer_len)
  13383. }
  13384. func Xxcb_str_name(tls *libc.TLS, R uintptr) (r uintptr) {
  13385. return R + libc.UintptrFromInt32(1)
  13386. }
  13387. func Xxcb_str_name_length(tls *libc.TLS, R uintptr) (r int32) {
  13388. return libc.Int32FromUint8((*Txcb_str_t)(unsafe.Pointer(R)).Fname_len)
  13389. }
  13390. func Xxcb_str_name_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  13391. var i Txcb_generic_iterator_t
  13392. _ = i
  13393. i.Fdata = R + libc.UintptrFromInt32(1) + uintptr((*Txcb_str_t)(unsafe.Pointer(R)).Fname_len)
  13394. i.Frem = 0
  13395. i.Findex = int32(int64(i.Fdata) - int64(R))
  13396. return i
  13397. }
  13398. func Xxcb_str_next(tls *libc.TLS, i uintptr) {
  13399. var R uintptr
  13400. var child Txcb_generic_iterator_t
  13401. _, _ = R, child
  13402. R = (*Txcb_str_iterator_t)(unsafe.Pointer(i)).Fdata
  13403. child.Fdata = R + uintptr(Xxcb_str_sizeof(tls, R))
  13404. (*Txcb_str_iterator_t)(unsafe.Pointer(i)).Findex = int32(int64(child.Fdata) - int64((*Txcb_str_iterator_t)(unsafe.Pointer(i)).Fdata))
  13405. (*Txcb_str_iterator_t)(unsafe.Pointer(i)).Frem--
  13406. (*Txcb_str_iterator_t)(unsafe.Pointer(i)).Fdata = child.Fdata
  13407. }
  13408. func Xxcb_str_end(tls *libc.TLS, _i Txcb_str_iterator_t) (r Txcb_generic_iterator_t) {
  13409. bp := tls.Alloc(16)
  13410. defer tls.Free(16)
  13411. *(*Txcb_str_iterator_t)(unsafe.Pointer(bp)) = _i
  13412. var ret Txcb_generic_iterator_t
  13413. _ = ret
  13414. for (*(*Txcb_str_iterator_t)(unsafe.Pointer(bp))).Frem > 0 {
  13415. Xxcb_str_next(tls, bp)
  13416. }
  13417. ret.Fdata = (*(*Txcb_str_iterator_t)(unsafe.Pointer(bp))).Fdata
  13418. ret.Frem = (*(*Txcb_str_iterator_t)(unsafe.Pointer(bp))).Frem
  13419. ret.Findex = (*(*Txcb_str_iterator_t)(unsafe.Pointer(bp))).Findex
  13420. return ret
  13421. }
  13422. func Xxcb_list_fonts_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  13423. var _aux, xcb_tmp uintptr
  13424. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  13425. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  13426. xcb_tmp = _buffer
  13427. _aux = _buffer
  13428. xcb_buffer_len = uint32(0)
  13429. xcb_block_len = uint32(0)
  13430. xcb_pad = uint32(0)
  13431. xcb_align_to = uint32(0)
  13432. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(8))
  13433. xcb_tmp += uintptr(xcb_block_len)
  13434. xcb_buffer_len += xcb_block_len
  13435. xcb_block_len = uint32(0)
  13436. /* pattern */
  13437. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_list_fonts_request_t)(unsafe.Pointer(_aux)).Fpattern_len)*libc.Uint64FromInt64(1))
  13438. xcb_tmp += uintptr(xcb_block_len)
  13439. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  13440. /* insert padding */
  13441. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  13442. xcb_buffer_len += xcb_block_len + xcb_pad
  13443. if uint32(0) != xcb_pad {
  13444. xcb_tmp += uintptr(xcb_pad)
  13445. xcb_pad = uint32(0)
  13446. }
  13447. xcb_block_len = uint32(0)
  13448. return libc.Int32FromUint32(xcb_buffer_len)
  13449. }
  13450. func Xxcb_list_fonts(tls *libc.TLS, c uintptr, max_names Tuint16_t, pattern_len Tuint16_t, pattern uintptr) (r Txcb_list_fonts_cookie_t) {
  13451. bp := tls.Alloc(112)
  13452. defer tls.Free(112)
  13453. var xcb_ret Txcb_list_fonts_cookie_t
  13454. var _ /* xcb_out at bp+96 */ Txcb_list_fonts_request_t
  13455. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  13456. _ = xcb_ret
  13457. (*(*Txcb_list_fonts_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  13458. (*(*Txcb_list_fonts_request_t)(unsafe.Pointer(bp + 96))).Fmax_names = max_names
  13459. (*(*Txcb_list_fonts_request_t)(unsafe.Pointer(bp + 96))).Fpattern_len = pattern_len
  13460. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  13461. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  13462. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13463. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13464. /* char pattern */
  13465. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = pattern
  13466. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(pattern_len) * uint64(1)
  13467. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  13468. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  13469. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req102)))
  13470. return xcb_ret
  13471. }
  13472. var _xcb_req102 = Txcb_protocol_request_t{
  13473. Fcount: uint64(4),
  13474. Fopcode: uint8(m_XCB_LIST_FONTS),
  13475. }
  13476. func Xxcb_list_fonts_unchecked(tls *libc.TLS, c uintptr, max_names Tuint16_t, pattern_len Tuint16_t, pattern uintptr) (r Txcb_list_fonts_cookie_t) {
  13477. bp := tls.Alloc(112)
  13478. defer tls.Free(112)
  13479. var xcb_ret Txcb_list_fonts_cookie_t
  13480. var _ /* xcb_out at bp+96 */ Txcb_list_fonts_request_t
  13481. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  13482. _ = xcb_ret
  13483. (*(*Txcb_list_fonts_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  13484. (*(*Txcb_list_fonts_request_t)(unsafe.Pointer(bp + 96))).Fmax_names = max_names
  13485. (*(*Txcb_list_fonts_request_t)(unsafe.Pointer(bp + 96))).Fpattern_len = pattern_len
  13486. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  13487. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  13488. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13489. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13490. /* char pattern */
  13491. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = pattern
  13492. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(pattern_len) * uint64(1)
  13493. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  13494. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  13495. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req103)))
  13496. return xcb_ret
  13497. }
  13498. var _xcb_req103 = Txcb_protocol_request_t{
  13499. Fcount: uint64(4),
  13500. Fopcode: uint8(m_XCB_LIST_FONTS),
  13501. }
  13502. func Xxcb_list_fonts_names_length(tls *libc.TLS, R uintptr) (r int32) {
  13503. return libc.Int32FromUint16((*Txcb_list_fonts_reply_t)(unsafe.Pointer(R)).Fnames_len)
  13504. }
  13505. func Xxcb_list_fonts_names_iterator(tls *libc.TLS, R uintptr) (r Txcb_str_iterator_t) {
  13506. var i Txcb_str_iterator_t
  13507. _ = i
  13508. i.Fdata = R + libc.UintptrFromInt32(1)*32
  13509. i.Frem = libc.Int32FromUint16((*Txcb_list_fonts_reply_t)(unsafe.Pointer(R)).Fnames_len)
  13510. i.Findex = int32(int64(i.Fdata) - int64(R))
  13511. return i
  13512. }
  13513. func Xxcb_list_fonts_reply(tls *libc.TLS, c uintptr, cookie Txcb_list_fonts_cookie_t, e uintptr) (r uintptr) {
  13514. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  13515. }
  13516. func Xxcb_list_fonts_with_info_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  13517. var _aux, xcb_tmp uintptr
  13518. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  13519. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  13520. xcb_tmp = _buffer
  13521. _aux = _buffer
  13522. xcb_buffer_len = uint32(0)
  13523. xcb_block_len = uint32(0)
  13524. xcb_pad = uint32(0)
  13525. xcb_align_to = uint32(0)
  13526. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(8))
  13527. xcb_tmp += uintptr(xcb_block_len)
  13528. xcb_buffer_len += xcb_block_len
  13529. xcb_block_len = uint32(0)
  13530. /* pattern */
  13531. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_list_fonts_with_info_request_t)(unsafe.Pointer(_aux)).Fpattern_len)*libc.Uint64FromInt64(1))
  13532. xcb_tmp += uintptr(xcb_block_len)
  13533. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  13534. /* insert padding */
  13535. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  13536. xcb_buffer_len += xcb_block_len + xcb_pad
  13537. if uint32(0) != xcb_pad {
  13538. xcb_tmp += uintptr(xcb_pad)
  13539. xcb_pad = uint32(0)
  13540. }
  13541. xcb_block_len = uint32(0)
  13542. return libc.Int32FromUint32(xcb_buffer_len)
  13543. }
  13544. func Xxcb_list_fonts_with_info(tls *libc.TLS, c uintptr, max_names Tuint16_t, pattern_len Tuint16_t, pattern uintptr) (r Txcb_list_fonts_with_info_cookie_t) {
  13545. bp := tls.Alloc(112)
  13546. defer tls.Free(112)
  13547. var xcb_ret Txcb_list_fonts_with_info_cookie_t
  13548. var _ /* xcb_out at bp+96 */ Txcb_list_fonts_with_info_request_t
  13549. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  13550. _ = xcb_ret
  13551. (*(*Txcb_list_fonts_with_info_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  13552. (*(*Txcb_list_fonts_with_info_request_t)(unsafe.Pointer(bp + 96))).Fmax_names = max_names
  13553. (*(*Txcb_list_fonts_with_info_request_t)(unsafe.Pointer(bp + 96))).Fpattern_len = pattern_len
  13554. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  13555. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  13556. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13557. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13558. /* char pattern */
  13559. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = pattern
  13560. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(pattern_len) * uint64(1)
  13561. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  13562. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  13563. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req104)))
  13564. return xcb_ret
  13565. }
  13566. var _xcb_req104 = Txcb_protocol_request_t{
  13567. Fcount: uint64(4),
  13568. Fopcode: uint8(m_XCB_LIST_FONTS_WITH_INFO),
  13569. }
  13570. func Xxcb_list_fonts_with_info_unchecked(tls *libc.TLS, c uintptr, max_names Tuint16_t, pattern_len Tuint16_t, pattern uintptr) (r Txcb_list_fonts_with_info_cookie_t) {
  13571. bp := tls.Alloc(112)
  13572. defer tls.Free(112)
  13573. var xcb_ret Txcb_list_fonts_with_info_cookie_t
  13574. var _ /* xcb_out at bp+96 */ Txcb_list_fonts_with_info_request_t
  13575. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  13576. _ = xcb_ret
  13577. (*(*Txcb_list_fonts_with_info_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  13578. (*(*Txcb_list_fonts_with_info_request_t)(unsafe.Pointer(bp + 96))).Fmax_names = max_names
  13579. (*(*Txcb_list_fonts_with_info_request_t)(unsafe.Pointer(bp + 96))).Fpattern_len = pattern_len
  13580. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  13581. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  13582. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13583. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13584. /* char pattern */
  13585. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = pattern
  13586. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(pattern_len) * uint64(1)
  13587. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  13588. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  13589. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req105)))
  13590. return xcb_ret
  13591. }
  13592. var _xcb_req105 = Txcb_protocol_request_t{
  13593. Fcount: uint64(4),
  13594. Fopcode: uint8(m_XCB_LIST_FONTS_WITH_INFO),
  13595. }
  13596. func Xxcb_list_fonts_with_info_properties(tls *libc.TLS, R uintptr) (r uintptr) {
  13597. return R + libc.UintptrFromInt32(1)*60
  13598. }
  13599. func Xxcb_list_fonts_with_info_properties_length(tls *libc.TLS, R uintptr) (r int32) {
  13600. return libc.Int32FromUint16((*Txcb_list_fonts_with_info_reply_t)(unsafe.Pointer(R)).Fproperties_len)
  13601. }
  13602. func Xxcb_list_fonts_with_info_properties_iterator(tls *libc.TLS, R uintptr) (r Txcb_fontprop_iterator_t) {
  13603. var i Txcb_fontprop_iterator_t
  13604. _ = i
  13605. i.Fdata = R + libc.UintptrFromInt32(1)*60
  13606. i.Frem = libc.Int32FromUint16((*Txcb_list_fonts_with_info_reply_t)(unsafe.Pointer(R)).Fproperties_len)
  13607. i.Findex = int32(int64(i.Fdata) - int64(R))
  13608. return i
  13609. }
  13610. func Xxcb_list_fonts_with_info_name(tls *libc.TLS, R uintptr) (r uintptr) {
  13611. var prev Txcb_generic_iterator_t
  13612. _ = prev
  13613. prev = Xxcb_fontprop_end(tls, Xxcb_list_fonts_with_info_properties_iterator(tls, R))
  13614. return prev.Fdata + uintptr(libc.Uint64FromInt32(-prev.Findex)&(libc.Uint64FromInt64(1)-libc.Uint64FromInt32(1))) + libc.UintptrFromInt32(0)
  13615. }
  13616. func Xxcb_list_fonts_with_info_name_length(tls *libc.TLS, R uintptr) (r int32) {
  13617. return libc.Int32FromUint8((*Txcb_list_fonts_with_info_reply_t)(unsafe.Pointer(R)).Fname_len)
  13618. }
  13619. func Xxcb_list_fonts_with_info_name_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  13620. var i, prev Txcb_generic_iterator_t
  13621. _, _ = i, prev
  13622. prev = Xxcb_fontprop_end(tls, Xxcb_list_fonts_with_info_properties_iterator(tls, R))
  13623. i.Fdata = prev.Fdata + uintptr(libc.Uint64FromInt32(-prev.Findex)&(libc.Uint64FromInt64(1)-libc.Uint64FromInt32(1))) + uintptr((*Txcb_list_fonts_with_info_reply_t)(unsafe.Pointer(R)).Fname_len)
  13624. i.Frem = 0
  13625. i.Findex = int32(int64(i.Fdata) - int64(R))
  13626. return i
  13627. }
  13628. func Xxcb_list_fonts_with_info_reply(tls *libc.TLS, c uintptr, cookie Txcb_list_fonts_with_info_cookie_t, e uintptr) (r uintptr) {
  13629. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  13630. }
  13631. func Xxcb_set_font_path_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  13632. var _aux, xcb_tmp uintptr
  13633. var i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp_len uint32
  13634. _, _, _, _, _, _, _, _ = _aux, i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp, xcb_tmp_len
  13635. xcb_tmp = _buffer
  13636. _aux = _buffer
  13637. xcb_buffer_len = uint32(0)
  13638. xcb_block_len = uint32(0)
  13639. xcb_pad = uint32(0)
  13640. xcb_align_to = uint32(0)
  13641. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(8))
  13642. xcb_tmp += uintptr(xcb_block_len)
  13643. xcb_buffer_len += xcb_block_len
  13644. xcb_block_len = uint32(0)
  13645. /* font */
  13646. i = uint32(0)
  13647. for {
  13648. if !(i < uint32((*Txcb_set_font_path_request_t)(unsafe.Pointer(_aux)).Ffont_qty)) {
  13649. break
  13650. }
  13651. xcb_tmp_len = libc.Uint32FromInt32(Xxcb_str_sizeof(tls, xcb_tmp))
  13652. xcb_block_len += xcb_tmp_len
  13653. xcb_tmp += uintptr(xcb_tmp_len)
  13654. goto _1
  13655. _1:
  13656. ;
  13657. i++
  13658. }
  13659. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  13660. /* insert padding */
  13661. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  13662. xcb_buffer_len += xcb_block_len + xcb_pad
  13663. if uint32(0) != xcb_pad {
  13664. xcb_tmp += uintptr(xcb_pad)
  13665. xcb_pad = uint32(0)
  13666. }
  13667. xcb_block_len = uint32(0)
  13668. return libc.Int32FromUint32(xcb_buffer_len)
  13669. }
  13670. func Xxcb_set_font_path_checked(tls *libc.TLS, c uintptr, font_qty Tuint16_t, font uintptr) (r Txcb_void_cookie_t) {
  13671. bp := tls.Alloc(112)
  13672. defer tls.Free(112)
  13673. var i, xcb_tmp_len uint32
  13674. var xcb_ret Txcb_void_cookie_t
  13675. var xcb_tmp uintptr
  13676. var _ /* xcb_out at bp+96 */ Txcb_set_font_path_request_t
  13677. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  13678. _, _, _, _ = i, xcb_ret, xcb_tmp, xcb_tmp_len
  13679. (*(*Txcb_set_font_path_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  13680. (*(*Txcb_set_font_path_request_t)(unsafe.Pointer(bp + 96))).Ffont_qty = font_qty
  13681. libc.Xmemset(tls, bp+96+6, 0, uint64(2))
  13682. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  13683. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  13684. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13685. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13686. /* xcb_str_t font */
  13687. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = font
  13688. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(0)
  13689. xcb_tmp = font
  13690. i = uint32(0)
  13691. for {
  13692. if !(i < uint32(font_qty)) {
  13693. break
  13694. }
  13695. xcb_tmp_len = libc.Uint32FromInt32(Xxcb_str_sizeof(tls, xcb_tmp))
  13696. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len += uint64(xcb_tmp_len)
  13697. xcb_tmp += uintptr(xcb_tmp_len)
  13698. goto _1
  13699. _1:
  13700. ;
  13701. i++
  13702. }
  13703. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  13704. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  13705. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req106)))
  13706. return xcb_ret
  13707. }
  13708. var _xcb_req106 = Txcb_protocol_request_t{
  13709. Fcount: uint64(4),
  13710. Fopcode: uint8(m_XCB_SET_FONT_PATH),
  13711. Fisvoid: uint8(1),
  13712. }
  13713. func Xxcb_set_font_path(tls *libc.TLS, c uintptr, font_qty Tuint16_t, font uintptr) (r Txcb_void_cookie_t) {
  13714. bp := tls.Alloc(112)
  13715. defer tls.Free(112)
  13716. var i, xcb_tmp_len uint32
  13717. var xcb_ret Txcb_void_cookie_t
  13718. var xcb_tmp uintptr
  13719. var _ /* xcb_out at bp+96 */ Txcb_set_font_path_request_t
  13720. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  13721. _, _, _, _ = i, xcb_ret, xcb_tmp, xcb_tmp_len
  13722. (*(*Txcb_set_font_path_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  13723. (*(*Txcb_set_font_path_request_t)(unsafe.Pointer(bp + 96))).Ffont_qty = font_qty
  13724. libc.Xmemset(tls, bp+96+6, 0, uint64(2))
  13725. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  13726. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  13727. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13728. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13729. /* xcb_str_t font */
  13730. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = font
  13731. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(0)
  13732. xcb_tmp = font
  13733. i = uint32(0)
  13734. for {
  13735. if !(i < uint32(font_qty)) {
  13736. break
  13737. }
  13738. xcb_tmp_len = libc.Uint32FromInt32(Xxcb_str_sizeof(tls, xcb_tmp))
  13739. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len += uint64(xcb_tmp_len)
  13740. xcb_tmp += uintptr(xcb_tmp_len)
  13741. goto _1
  13742. _1:
  13743. ;
  13744. i++
  13745. }
  13746. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  13747. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  13748. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req107)))
  13749. return xcb_ret
  13750. }
  13751. var _xcb_req107 = Txcb_protocol_request_t{
  13752. Fcount: uint64(4),
  13753. Fopcode: uint8(m_XCB_SET_FONT_PATH),
  13754. Fisvoid: uint8(1),
  13755. }
  13756. func Xxcb_set_font_path_font_length(tls *libc.TLS, R uintptr) (r int32) {
  13757. return libc.Int32FromUint16((*Txcb_set_font_path_request_t)(unsafe.Pointer(R)).Ffont_qty)
  13758. }
  13759. func Xxcb_set_font_path_font_iterator(tls *libc.TLS, R uintptr) (r Txcb_str_iterator_t) {
  13760. var i Txcb_str_iterator_t
  13761. _ = i
  13762. i.Fdata = R + libc.UintptrFromInt32(1)*8
  13763. i.Frem = libc.Int32FromUint16((*Txcb_set_font_path_request_t)(unsafe.Pointer(R)).Ffont_qty)
  13764. i.Findex = int32(int64(i.Fdata) - int64(R))
  13765. return i
  13766. }
  13767. func Xxcb_get_font_path_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  13768. var _aux, xcb_tmp uintptr
  13769. var i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp_len uint32
  13770. _, _, _, _, _, _, _, _ = _aux, i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp, xcb_tmp_len
  13771. xcb_tmp = _buffer
  13772. _aux = _buffer
  13773. xcb_buffer_len = uint32(0)
  13774. xcb_block_len = uint32(0)
  13775. xcb_pad = uint32(0)
  13776. xcb_align_to = uint32(0)
  13777. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(32))
  13778. xcb_tmp += uintptr(xcb_block_len)
  13779. xcb_buffer_len += xcb_block_len
  13780. xcb_block_len = uint32(0)
  13781. /* path */
  13782. i = uint32(0)
  13783. for {
  13784. if !(i < uint32((*Txcb_get_font_path_reply_t)(unsafe.Pointer(_aux)).Fpath_len)) {
  13785. break
  13786. }
  13787. xcb_tmp_len = libc.Uint32FromInt32(Xxcb_str_sizeof(tls, xcb_tmp))
  13788. xcb_block_len += xcb_tmp_len
  13789. xcb_tmp += uintptr(xcb_tmp_len)
  13790. goto _1
  13791. _1:
  13792. ;
  13793. i++
  13794. }
  13795. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  13796. /* insert padding */
  13797. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  13798. xcb_buffer_len += xcb_block_len + xcb_pad
  13799. if uint32(0) != xcb_pad {
  13800. xcb_tmp += uintptr(xcb_pad)
  13801. xcb_pad = uint32(0)
  13802. }
  13803. xcb_block_len = uint32(0)
  13804. return libc.Int32FromUint32(xcb_buffer_len)
  13805. }
  13806. func Xxcb_get_font_path(tls *libc.TLS, c uintptr) (r Txcb_get_font_path_cookie_t) {
  13807. bp := tls.Alloc(80)
  13808. defer tls.Free(80)
  13809. var xcb_ret Txcb_get_font_path_cookie_t
  13810. var _ /* xcb_out at bp+64 */ Txcb_get_font_path_request_t
  13811. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  13812. _ = xcb_ret
  13813. (*(*Txcb_get_font_path_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  13814. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  13815. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  13816. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13817. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13818. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req108)))
  13819. return xcb_ret
  13820. }
  13821. var _xcb_req108 = Txcb_protocol_request_t{
  13822. Fcount: uint64(2),
  13823. Fopcode: uint8(m_XCB_GET_FONT_PATH),
  13824. }
  13825. func Xxcb_get_font_path_unchecked(tls *libc.TLS, c uintptr) (r Txcb_get_font_path_cookie_t) {
  13826. bp := tls.Alloc(80)
  13827. defer tls.Free(80)
  13828. var xcb_ret Txcb_get_font_path_cookie_t
  13829. var _ /* xcb_out at bp+64 */ Txcb_get_font_path_request_t
  13830. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  13831. _ = xcb_ret
  13832. (*(*Txcb_get_font_path_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  13833. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  13834. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  13835. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13836. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13837. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req109)))
  13838. return xcb_ret
  13839. }
  13840. var _xcb_req109 = Txcb_protocol_request_t{
  13841. Fcount: uint64(2),
  13842. Fopcode: uint8(m_XCB_GET_FONT_PATH),
  13843. }
  13844. func Xxcb_get_font_path_path_length(tls *libc.TLS, R uintptr) (r int32) {
  13845. return libc.Int32FromUint16((*Txcb_get_font_path_reply_t)(unsafe.Pointer(R)).Fpath_len)
  13846. }
  13847. func Xxcb_get_font_path_path_iterator(tls *libc.TLS, R uintptr) (r Txcb_str_iterator_t) {
  13848. var i Txcb_str_iterator_t
  13849. _ = i
  13850. i.Fdata = R + libc.UintptrFromInt32(1)*32
  13851. i.Frem = libc.Int32FromUint16((*Txcb_get_font_path_reply_t)(unsafe.Pointer(R)).Fpath_len)
  13852. i.Findex = int32(int64(i.Fdata) - int64(R))
  13853. return i
  13854. }
  13855. func Xxcb_get_font_path_reply(tls *libc.TLS, c uintptr, cookie Txcb_get_font_path_cookie_t, e uintptr) (r uintptr) {
  13856. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  13857. }
  13858. func Xxcb_create_pixmap_checked(tls *libc.TLS, c uintptr, depth Tuint8_t, pid Txcb_pixmap_t, drawable Txcb_drawable_t, width Tuint16_t, height Tuint16_t) (r Txcb_void_cookie_t) {
  13859. bp := tls.Alloc(80)
  13860. defer tls.Free(80)
  13861. var xcb_ret Txcb_void_cookie_t
  13862. var _ /* xcb_out at bp+64 */ Txcb_create_pixmap_request_t
  13863. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  13864. _ = xcb_ret
  13865. (*(*Txcb_create_pixmap_request_t)(unsafe.Pointer(bp + 64))).Fdepth = depth
  13866. (*(*Txcb_create_pixmap_request_t)(unsafe.Pointer(bp + 64))).Fpid = pid
  13867. (*(*Txcb_create_pixmap_request_t)(unsafe.Pointer(bp + 64))).Fdrawable = drawable
  13868. (*(*Txcb_create_pixmap_request_t)(unsafe.Pointer(bp + 64))).Fwidth = width
  13869. (*(*Txcb_create_pixmap_request_t)(unsafe.Pointer(bp + 64))).Fheight = height
  13870. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  13871. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  13872. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13873. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13874. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req110)))
  13875. return xcb_ret
  13876. }
  13877. var _xcb_req110 = Txcb_protocol_request_t{
  13878. Fcount: uint64(2),
  13879. Fopcode: uint8(m_XCB_CREATE_PIXMAP),
  13880. Fisvoid: uint8(1),
  13881. }
  13882. func Xxcb_create_pixmap(tls *libc.TLS, c uintptr, depth Tuint8_t, pid Txcb_pixmap_t, drawable Txcb_drawable_t, width Tuint16_t, height Tuint16_t) (r Txcb_void_cookie_t) {
  13883. bp := tls.Alloc(80)
  13884. defer tls.Free(80)
  13885. var xcb_ret Txcb_void_cookie_t
  13886. var _ /* xcb_out at bp+64 */ Txcb_create_pixmap_request_t
  13887. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  13888. _ = xcb_ret
  13889. (*(*Txcb_create_pixmap_request_t)(unsafe.Pointer(bp + 64))).Fdepth = depth
  13890. (*(*Txcb_create_pixmap_request_t)(unsafe.Pointer(bp + 64))).Fpid = pid
  13891. (*(*Txcb_create_pixmap_request_t)(unsafe.Pointer(bp + 64))).Fdrawable = drawable
  13892. (*(*Txcb_create_pixmap_request_t)(unsafe.Pointer(bp + 64))).Fwidth = width
  13893. (*(*Txcb_create_pixmap_request_t)(unsafe.Pointer(bp + 64))).Fheight = height
  13894. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  13895. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  13896. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13897. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13898. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req111)))
  13899. return xcb_ret
  13900. }
  13901. var _xcb_req111 = Txcb_protocol_request_t{
  13902. Fcount: uint64(2),
  13903. Fopcode: uint8(m_XCB_CREATE_PIXMAP),
  13904. Fisvoid: uint8(1),
  13905. }
  13906. func Xxcb_free_pixmap_checked(tls *libc.TLS, c uintptr, pixmap Txcb_pixmap_t) (r Txcb_void_cookie_t) {
  13907. bp := tls.Alloc(80)
  13908. defer tls.Free(80)
  13909. var xcb_ret Txcb_void_cookie_t
  13910. var _ /* xcb_out at bp+64 */ Txcb_free_pixmap_request_t
  13911. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  13912. _ = xcb_ret
  13913. (*(*Txcb_free_pixmap_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  13914. (*(*Txcb_free_pixmap_request_t)(unsafe.Pointer(bp + 64))).Fpixmap = pixmap
  13915. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  13916. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  13917. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13918. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13919. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req112)))
  13920. return xcb_ret
  13921. }
  13922. var _xcb_req112 = Txcb_protocol_request_t{
  13923. Fcount: uint64(2),
  13924. Fopcode: uint8(m_XCB_FREE_PIXMAP),
  13925. Fisvoid: uint8(1),
  13926. }
  13927. func Xxcb_free_pixmap(tls *libc.TLS, c uintptr, pixmap Txcb_pixmap_t) (r Txcb_void_cookie_t) {
  13928. bp := tls.Alloc(80)
  13929. defer tls.Free(80)
  13930. var xcb_ret Txcb_void_cookie_t
  13931. var _ /* xcb_out at bp+64 */ Txcb_free_pixmap_request_t
  13932. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  13933. _ = xcb_ret
  13934. (*(*Txcb_free_pixmap_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  13935. (*(*Txcb_free_pixmap_request_t)(unsafe.Pointer(bp + 64))).Fpixmap = pixmap
  13936. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  13937. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  13938. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  13939. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  13940. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req113)))
  13941. return xcb_ret
  13942. }
  13943. var _xcb_req113 = Txcb_protocol_request_t{
  13944. Fcount: uint64(2),
  13945. Fopcode: uint8(m_XCB_FREE_PIXMAP),
  13946. Fisvoid: uint8(1),
  13947. }
  13948. func Xxcb_create_gc_value_list_serialize(tls *libc.TLS, _buffer uintptr, value_mask Tuint32_t, _aux uintptr) (r int32) {
  13949. bp := tls.Alloc(16)
  13950. defer tls.Free(16)
  13951. var i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset, xcb_parts_idx uint32
  13952. var xcb_out, xcb_tmp uintptr
  13953. var xcb_parts [24]Tiovec
  13954. var _ /* xcb_pad0 at bp+0 */ [3]int8
  13955. _, _, _, _, _, _, _, _, _, _ = i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_out, xcb_pad, xcb_padding_offset, xcb_parts, xcb_parts_idx, xcb_tmp
  13956. xcb_out = *(*uintptr)(unsafe.Pointer(_buffer))
  13957. xcb_buffer_len = uint32(0)
  13958. xcb_align_to = uint32(0)
  13959. xcb_padding_offset = uint32(0)
  13960. xcb_pad = uint32(0)
  13961. *(*[3]int8)(unsafe.Pointer(bp)) = [3]int8{}
  13962. xcb_parts_idx = uint32(0)
  13963. xcb_block_len = uint32(0)
  13964. if value_mask&uint32(_XCB_GC_FUNCTION) != 0 {
  13965. /* xcb_create_gc_value_list_t.function */
  13966. xcb_parts[xcb_parts_idx].Fiov_base = _aux
  13967. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  13968. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  13969. xcb_parts_idx++
  13970. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  13971. }
  13972. if value_mask&uint32(_XCB_GC_PLANE_MASK) != 0 {
  13973. /* xcb_create_gc_value_list_t.plane_mask */
  13974. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 4
  13975. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  13976. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  13977. xcb_parts_idx++
  13978. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  13979. }
  13980. if value_mask&uint32(_XCB_GC_FOREGROUND) != 0 {
  13981. /* xcb_create_gc_value_list_t.foreground */
  13982. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 8
  13983. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  13984. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  13985. xcb_parts_idx++
  13986. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  13987. }
  13988. if value_mask&uint32(_XCB_GC_BACKGROUND) != 0 {
  13989. /* xcb_create_gc_value_list_t.background */
  13990. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 12
  13991. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  13992. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  13993. xcb_parts_idx++
  13994. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  13995. }
  13996. if value_mask&uint32(_XCB_GC_LINE_WIDTH) != 0 {
  13997. /* xcb_create_gc_value_list_t.line_width */
  13998. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 16
  13999. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14000. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14001. xcb_parts_idx++
  14002. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14003. }
  14004. if value_mask&uint32(_XCB_GC_LINE_STYLE) != 0 {
  14005. /* xcb_create_gc_value_list_t.line_style */
  14006. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 20
  14007. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14008. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14009. xcb_parts_idx++
  14010. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14011. }
  14012. if value_mask&uint32(_XCB_GC_CAP_STYLE) != 0 {
  14013. /* xcb_create_gc_value_list_t.cap_style */
  14014. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 24
  14015. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14016. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14017. xcb_parts_idx++
  14018. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14019. }
  14020. if value_mask&uint32(_XCB_GC_JOIN_STYLE) != 0 {
  14021. /* xcb_create_gc_value_list_t.join_style */
  14022. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 28
  14023. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14024. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14025. xcb_parts_idx++
  14026. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14027. }
  14028. if value_mask&uint32(_XCB_GC_FILL_STYLE) != 0 {
  14029. /* xcb_create_gc_value_list_t.fill_style */
  14030. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 32
  14031. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14032. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14033. xcb_parts_idx++
  14034. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14035. }
  14036. if value_mask&uint32(_XCB_GC_FILL_RULE) != 0 {
  14037. /* xcb_create_gc_value_list_t.fill_rule */
  14038. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 36
  14039. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14040. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14041. xcb_parts_idx++
  14042. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14043. }
  14044. if value_mask&uint32(_XCB_GC_TILE) != 0 {
  14045. /* xcb_create_gc_value_list_t.tile */
  14046. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 40
  14047. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14048. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14049. xcb_parts_idx++
  14050. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14051. }
  14052. if value_mask&uint32(_XCB_GC_STIPPLE) != 0 {
  14053. /* xcb_create_gc_value_list_t.stipple */
  14054. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 44
  14055. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14056. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14057. xcb_parts_idx++
  14058. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14059. }
  14060. if value_mask&uint32(_XCB_GC_TILE_STIPPLE_ORIGIN_X) != 0 {
  14061. /* xcb_create_gc_value_list_t.tile_stipple_x_origin */
  14062. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 48
  14063. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14064. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14065. xcb_parts_idx++
  14066. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14067. }
  14068. if value_mask&uint32(_XCB_GC_TILE_STIPPLE_ORIGIN_Y) != 0 {
  14069. /* xcb_create_gc_value_list_t.tile_stipple_y_origin */
  14070. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 52
  14071. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14072. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14073. xcb_parts_idx++
  14074. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14075. }
  14076. if value_mask&uint32(_XCB_GC_FONT) != 0 {
  14077. /* xcb_create_gc_value_list_t.font */
  14078. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 56
  14079. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14080. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14081. xcb_parts_idx++
  14082. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14083. }
  14084. if value_mask&uint32(_XCB_GC_SUBWINDOW_MODE) != 0 {
  14085. /* xcb_create_gc_value_list_t.subwindow_mode */
  14086. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 60
  14087. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14088. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14089. xcb_parts_idx++
  14090. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14091. }
  14092. if value_mask&uint32(_XCB_GC_GRAPHICS_EXPOSURES) != 0 {
  14093. /* xcb_create_gc_value_list_t.graphics_exposures */
  14094. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 64
  14095. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14096. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14097. xcb_parts_idx++
  14098. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14099. }
  14100. if value_mask&uint32(_XCB_GC_CLIP_ORIGIN_X) != 0 {
  14101. /* xcb_create_gc_value_list_t.clip_x_origin */
  14102. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 68
  14103. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14104. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14105. xcb_parts_idx++
  14106. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14107. }
  14108. if value_mask&uint32(_XCB_GC_CLIP_ORIGIN_Y) != 0 {
  14109. /* xcb_create_gc_value_list_t.clip_y_origin */
  14110. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 72
  14111. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14112. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14113. xcb_parts_idx++
  14114. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14115. }
  14116. if value_mask&uint32(_XCB_GC_CLIP_MASK) != 0 {
  14117. /* xcb_create_gc_value_list_t.clip_mask */
  14118. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 76
  14119. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14120. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14121. xcb_parts_idx++
  14122. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14123. }
  14124. if value_mask&uint32(_XCB_GC_DASH_OFFSET) != 0 {
  14125. /* xcb_create_gc_value_list_t.dash_offset */
  14126. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 80
  14127. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14128. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14129. xcb_parts_idx++
  14130. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14131. }
  14132. if value_mask&uint32(_XCB_GC_DASH_LIST) != 0 {
  14133. /* xcb_create_gc_value_list_t.dashes */
  14134. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 84
  14135. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14136. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14137. xcb_parts_idx++
  14138. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14139. }
  14140. if value_mask&uint32(_XCB_GC_ARC_MODE) != 0 {
  14141. /* xcb_create_gc_value_list_t.arc_mode */
  14142. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 88
  14143. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14144. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14145. xcb_parts_idx++
  14146. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14147. }
  14148. /* insert padding */
  14149. xcb_pad = -(xcb_block_len + xcb_padding_offset) & (xcb_align_to - uint32(1))
  14150. xcb_buffer_len += xcb_block_len + xcb_pad
  14151. if uint32(0) != xcb_pad {
  14152. xcb_parts[xcb_parts_idx].Fiov_base = bp
  14153. xcb_parts[xcb_parts_idx].Fiov_len = uint64(xcb_pad)
  14154. xcb_parts_idx++
  14155. xcb_pad = uint32(0)
  14156. }
  14157. xcb_block_len = uint32(0)
  14158. xcb_padding_offset = uint32(0)
  14159. if libc.UintptrFromInt32(0) == xcb_out {
  14160. /* allocate memory */
  14161. xcb_out = libc.Xmalloc(tls, uint64(xcb_buffer_len))
  14162. *(*uintptr)(unsafe.Pointer(_buffer)) = xcb_out
  14163. }
  14164. xcb_tmp = xcb_out
  14165. i = uint32(0)
  14166. for {
  14167. if !(i < xcb_parts_idx) {
  14168. break
  14169. }
  14170. if uintptr(0) != xcb_parts[i].Fiov_base && uint64(0) != xcb_parts[i].Fiov_len {
  14171. libc.Xmemcpy(tls, xcb_tmp, xcb_parts[i].Fiov_base, xcb_parts[i].Fiov_len)
  14172. }
  14173. if uint64(0) != xcb_parts[i].Fiov_len {
  14174. xcb_tmp += uintptr(xcb_parts[i].Fiov_len)
  14175. }
  14176. goto _1
  14177. _1:
  14178. ;
  14179. i++
  14180. }
  14181. return libc.Int32FromUint32(xcb_buffer_len)
  14182. }
  14183. func Xxcb_create_gc_value_list_unpack(tls *libc.TLS, _buffer uintptr, value_mask Tuint32_t, _aux uintptr) (r int32) {
  14184. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset uint32
  14185. var xcb_tmp uintptr
  14186. _, _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset, xcb_tmp
  14187. xcb_tmp = _buffer
  14188. xcb_buffer_len = uint32(0)
  14189. xcb_block_len = uint32(0)
  14190. xcb_pad = uint32(0)
  14191. xcb_align_to = uint32(0)
  14192. xcb_padding_offset = uint32(0)
  14193. if value_mask&uint32(_XCB_GC_FUNCTION) != 0 {
  14194. /* xcb_create_gc_value_list_t.function */
  14195. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Ffunction = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14196. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14197. xcb_tmp += uintptr(4)
  14198. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14199. }
  14200. if value_mask&uint32(_XCB_GC_PLANE_MASK) != 0 {
  14201. /* xcb_create_gc_value_list_t.plane_mask */
  14202. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Fplane_mask = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14203. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14204. xcb_tmp += uintptr(4)
  14205. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14206. }
  14207. if value_mask&uint32(_XCB_GC_FOREGROUND) != 0 {
  14208. /* xcb_create_gc_value_list_t.foreground */
  14209. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Fforeground = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14210. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14211. xcb_tmp += uintptr(4)
  14212. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14213. }
  14214. if value_mask&uint32(_XCB_GC_BACKGROUND) != 0 {
  14215. /* xcb_create_gc_value_list_t.background */
  14216. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Fbackground = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14217. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14218. xcb_tmp += uintptr(4)
  14219. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14220. }
  14221. if value_mask&uint32(_XCB_GC_LINE_WIDTH) != 0 {
  14222. /* xcb_create_gc_value_list_t.line_width */
  14223. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Fline_width = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14224. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14225. xcb_tmp += uintptr(4)
  14226. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14227. }
  14228. if value_mask&uint32(_XCB_GC_LINE_STYLE) != 0 {
  14229. /* xcb_create_gc_value_list_t.line_style */
  14230. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Fline_style = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14231. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14232. xcb_tmp += uintptr(4)
  14233. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14234. }
  14235. if value_mask&uint32(_XCB_GC_CAP_STYLE) != 0 {
  14236. /* xcb_create_gc_value_list_t.cap_style */
  14237. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Fcap_style = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14238. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14239. xcb_tmp += uintptr(4)
  14240. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14241. }
  14242. if value_mask&uint32(_XCB_GC_JOIN_STYLE) != 0 {
  14243. /* xcb_create_gc_value_list_t.join_style */
  14244. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Fjoin_style = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14245. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14246. xcb_tmp += uintptr(4)
  14247. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14248. }
  14249. if value_mask&uint32(_XCB_GC_FILL_STYLE) != 0 {
  14250. /* xcb_create_gc_value_list_t.fill_style */
  14251. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Ffill_style = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14252. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14253. xcb_tmp += uintptr(4)
  14254. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14255. }
  14256. if value_mask&uint32(_XCB_GC_FILL_RULE) != 0 {
  14257. /* xcb_create_gc_value_list_t.fill_rule */
  14258. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Ffill_rule = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14259. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14260. xcb_tmp += uintptr(4)
  14261. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14262. }
  14263. if value_mask&uint32(_XCB_GC_TILE) != 0 {
  14264. /* xcb_create_gc_value_list_t.tile */
  14265. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Ftile = *(*Txcb_pixmap_t)(unsafe.Pointer(xcb_tmp))
  14266. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14267. xcb_tmp += uintptr(4)
  14268. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14269. }
  14270. if value_mask&uint32(_XCB_GC_STIPPLE) != 0 {
  14271. /* xcb_create_gc_value_list_t.stipple */
  14272. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Fstipple = *(*Txcb_pixmap_t)(unsafe.Pointer(xcb_tmp))
  14273. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14274. xcb_tmp += uintptr(4)
  14275. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14276. }
  14277. if value_mask&uint32(_XCB_GC_TILE_STIPPLE_ORIGIN_X) != 0 {
  14278. /* xcb_create_gc_value_list_t.tile_stipple_x_origin */
  14279. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Ftile_stipple_x_origin = *(*Tint32_t)(unsafe.Pointer(xcb_tmp))
  14280. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14281. xcb_tmp += uintptr(4)
  14282. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14283. }
  14284. if value_mask&uint32(_XCB_GC_TILE_STIPPLE_ORIGIN_Y) != 0 {
  14285. /* xcb_create_gc_value_list_t.tile_stipple_y_origin */
  14286. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Ftile_stipple_y_origin = *(*Tint32_t)(unsafe.Pointer(xcb_tmp))
  14287. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14288. xcb_tmp += uintptr(4)
  14289. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14290. }
  14291. if value_mask&uint32(_XCB_GC_FONT) != 0 {
  14292. /* xcb_create_gc_value_list_t.font */
  14293. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Ffont = *(*Txcb_font_t)(unsafe.Pointer(xcb_tmp))
  14294. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14295. xcb_tmp += uintptr(4)
  14296. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14297. }
  14298. if value_mask&uint32(_XCB_GC_SUBWINDOW_MODE) != 0 {
  14299. /* xcb_create_gc_value_list_t.subwindow_mode */
  14300. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Fsubwindow_mode = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14301. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14302. xcb_tmp += uintptr(4)
  14303. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14304. }
  14305. if value_mask&uint32(_XCB_GC_GRAPHICS_EXPOSURES) != 0 {
  14306. /* xcb_create_gc_value_list_t.graphics_exposures */
  14307. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Fgraphics_exposures = *(*Txcb_bool32_t)(unsafe.Pointer(xcb_tmp))
  14308. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14309. xcb_tmp += uintptr(4)
  14310. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14311. }
  14312. if value_mask&uint32(_XCB_GC_CLIP_ORIGIN_X) != 0 {
  14313. /* xcb_create_gc_value_list_t.clip_x_origin */
  14314. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Fclip_x_origin = *(*Tint32_t)(unsafe.Pointer(xcb_tmp))
  14315. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14316. xcb_tmp += uintptr(4)
  14317. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14318. }
  14319. if value_mask&uint32(_XCB_GC_CLIP_ORIGIN_Y) != 0 {
  14320. /* xcb_create_gc_value_list_t.clip_y_origin */
  14321. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Fclip_y_origin = *(*Tint32_t)(unsafe.Pointer(xcb_tmp))
  14322. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14323. xcb_tmp += uintptr(4)
  14324. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14325. }
  14326. if value_mask&uint32(_XCB_GC_CLIP_MASK) != 0 {
  14327. /* xcb_create_gc_value_list_t.clip_mask */
  14328. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Fclip_mask = *(*Txcb_pixmap_t)(unsafe.Pointer(xcb_tmp))
  14329. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14330. xcb_tmp += uintptr(4)
  14331. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14332. }
  14333. if value_mask&uint32(_XCB_GC_DASH_OFFSET) != 0 {
  14334. /* xcb_create_gc_value_list_t.dash_offset */
  14335. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Fdash_offset = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14336. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14337. xcb_tmp += uintptr(4)
  14338. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14339. }
  14340. if value_mask&uint32(_XCB_GC_DASH_LIST) != 0 {
  14341. /* xcb_create_gc_value_list_t.dashes */
  14342. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Fdashes = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14343. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14344. xcb_tmp += uintptr(4)
  14345. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14346. }
  14347. if value_mask&uint32(_XCB_GC_ARC_MODE) != 0 {
  14348. /* xcb_create_gc_value_list_t.arc_mode */
  14349. (*Txcb_create_gc_value_list_t)(unsafe.Pointer(_aux)).Farc_mode = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14350. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14351. xcb_tmp += uintptr(4)
  14352. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14353. }
  14354. /* insert padding */
  14355. xcb_pad = -(xcb_block_len + xcb_padding_offset) & (xcb_align_to - uint32(1))
  14356. xcb_buffer_len += xcb_block_len + xcb_pad
  14357. if uint32(0) != xcb_pad {
  14358. xcb_tmp += uintptr(xcb_pad)
  14359. xcb_pad = uint32(0)
  14360. }
  14361. xcb_block_len = uint32(0)
  14362. xcb_padding_offset = uint32(0)
  14363. return libc.Int32FromUint32(xcb_buffer_len)
  14364. }
  14365. func Xxcb_create_gc_value_list_sizeof(tls *libc.TLS, _buffer uintptr, value_mask Tuint32_t) (r int32) {
  14366. bp := tls.Alloc(96)
  14367. defer tls.Free(96)
  14368. var _ /* _aux at bp+0 */ Txcb_create_gc_value_list_t
  14369. return Xxcb_create_gc_value_list_unpack(tls, _buffer, value_mask, bp)
  14370. }
  14371. func Xxcb_create_gc_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  14372. var _aux, xcb_tmp uintptr
  14373. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  14374. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  14375. xcb_tmp = _buffer
  14376. _aux = _buffer
  14377. xcb_buffer_len = uint32(0)
  14378. xcb_block_len = uint32(0)
  14379. xcb_pad = uint32(0)
  14380. xcb_align_to = uint32(0)
  14381. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(16))
  14382. xcb_tmp += uintptr(xcb_block_len)
  14383. xcb_buffer_len += xcb_block_len
  14384. xcb_block_len = uint32(0)
  14385. /* value_list */
  14386. xcb_block_len += libc.Uint32FromInt32(Xxcb_create_gc_value_list_sizeof(tls, xcb_tmp, (*Txcb_create_gc_request_t)(unsafe.Pointer(_aux)).Fvalue_mask))
  14387. xcb_tmp += uintptr(xcb_block_len)
  14388. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  14389. /* insert padding */
  14390. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  14391. xcb_buffer_len += xcb_block_len + xcb_pad
  14392. if uint32(0) != xcb_pad {
  14393. xcb_tmp += uintptr(xcb_pad)
  14394. xcb_pad = uint32(0)
  14395. }
  14396. xcb_block_len = uint32(0)
  14397. return libc.Int32FromUint32(xcb_buffer_len)
  14398. }
  14399. func Xxcb_create_gc_checked(tls *libc.TLS, c uintptr, cid Txcb_gcontext_t, drawable Txcb_drawable_t, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  14400. bp := tls.Alloc(96)
  14401. defer tls.Free(96)
  14402. var xcb_ret Txcb_void_cookie_t
  14403. var _ /* xcb_out at bp+80 */ Txcb_create_gc_request_t
  14404. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  14405. _ = xcb_ret
  14406. (*(*Txcb_create_gc_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  14407. (*(*Txcb_create_gc_request_t)(unsafe.Pointer(bp + 80))).Fcid = cid
  14408. (*(*Txcb_create_gc_request_t)(unsafe.Pointer(bp + 80))).Fdrawable = drawable
  14409. (*(*Txcb_create_gc_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  14410. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  14411. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  14412. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  14413. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  14414. /* xcb_create_gc_value_list_t value_list */
  14415. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = value_list
  14416. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_create_gc_value_list_sizeof(tls, value_list, value_mask))
  14417. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req114)))
  14418. return xcb_ret
  14419. }
  14420. var _xcb_req114 = Txcb_protocol_request_t{
  14421. Fcount: uint64(3),
  14422. Fopcode: uint8(m_XCB_CREATE_GC),
  14423. Fisvoid: uint8(1),
  14424. }
  14425. func Xxcb_create_gc(tls *libc.TLS, c uintptr, cid Txcb_gcontext_t, drawable Txcb_drawable_t, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  14426. bp := tls.Alloc(96)
  14427. defer tls.Free(96)
  14428. var xcb_ret Txcb_void_cookie_t
  14429. var _ /* xcb_out at bp+80 */ Txcb_create_gc_request_t
  14430. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  14431. _ = xcb_ret
  14432. (*(*Txcb_create_gc_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  14433. (*(*Txcb_create_gc_request_t)(unsafe.Pointer(bp + 80))).Fcid = cid
  14434. (*(*Txcb_create_gc_request_t)(unsafe.Pointer(bp + 80))).Fdrawable = drawable
  14435. (*(*Txcb_create_gc_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  14436. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  14437. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  14438. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  14439. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  14440. /* xcb_create_gc_value_list_t value_list */
  14441. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = value_list
  14442. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_create_gc_value_list_sizeof(tls, value_list, value_mask))
  14443. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req115)))
  14444. return xcb_ret
  14445. }
  14446. var _xcb_req115 = Txcb_protocol_request_t{
  14447. Fcount: uint64(3),
  14448. Fopcode: uint8(m_XCB_CREATE_GC),
  14449. Fisvoid: uint8(1),
  14450. }
  14451. func Xxcb_create_gc_aux_checked(tls *libc.TLS, c uintptr, cid Txcb_gcontext_t, drawable Txcb_drawable_t, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  14452. bp := tls.Alloc(112)
  14453. defer tls.Free(112)
  14454. var xcb_ret Txcb_void_cookie_t
  14455. var _ /* xcb_aux0 at bp+96 */ uintptr
  14456. var _ /* xcb_out at bp+80 */ Txcb_create_gc_request_t
  14457. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  14458. _ = xcb_ret
  14459. *(*uintptr)(unsafe.Pointer(bp + 96)) = uintptr(0)
  14460. (*(*Txcb_create_gc_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  14461. (*(*Txcb_create_gc_request_t)(unsafe.Pointer(bp + 80))).Fcid = cid
  14462. (*(*Txcb_create_gc_request_t)(unsafe.Pointer(bp + 80))).Fdrawable = drawable
  14463. (*(*Txcb_create_gc_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  14464. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  14465. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  14466. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  14467. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  14468. /* xcb_create_gc_value_list_t value_list */
  14469. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_create_gc_value_list_serialize(tls, bp+96, value_mask, value_list))
  14470. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = *(*uintptr)(unsafe.Pointer(bp + 96))
  14471. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req116)))
  14472. libc.Xfree(tls, *(*uintptr)(unsafe.Pointer(bp + 96)))
  14473. return xcb_ret
  14474. }
  14475. var _xcb_req116 = Txcb_protocol_request_t{
  14476. Fcount: uint64(3),
  14477. Fopcode: uint8(m_XCB_CREATE_GC),
  14478. Fisvoid: uint8(1),
  14479. }
  14480. func Xxcb_create_gc_aux(tls *libc.TLS, c uintptr, cid Txcb_gcontext_t, drawable Txcb_drawable_t, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  14481. bp := tls.Alloc(112)
  14482. defer tls.Free(112)
  14483. var xcb_ret Txcb_void_cookie_t
  14484. var _ /* xcb_aux0 at bp+96 */ uintptr
  14485. var _ /* xcb_out at bp+80 */ Txcb_create_gc_request_t
  14486. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  14487. _ = xcb_ret
  14488. *(*uintptr)(unsafe.Pointer(bp + 96)) = uintptr(0)
  14489. (*(*Txcb_create_gc_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  14490. (*(*Txcb_create_gc_request_t)(unsafe.Pointer(bp + 80))).Fcid = cid
  14491. (*(*Txcb_create_gc_request_t)(unsafe.Pointer(bp + 80))).Fdrawable = drawable
  14492. (*(*Txcb_create_gc_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  14493. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  14494. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  14495. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  14496. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  14497. /* xcb_create_gc_value_list_t value_list */
  14498. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_create_gc_value_list_serialize(tls, bp+96, value_mask, value_list))
  14499. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = *(*uintptr)(unsafe.Pointer(bp + 96))
  14500. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req117)))
  14501. libc.Xfree(tls, *(*uintptr)(unsafe.Pointer(bp + 96)))
  14502. return xcb_ret
  14503. }
  14504. var _xcb_req117 = Txcb_protocol_request_t{
  14505. Fcount: uint64(3),
  14506. Fopcode: uint8(m_XCB_CREATE_GC),
  14507. Fisvoid: uint8(1),
  14508. }
  14509. func Xxcb_create_gc_value_list(tls *libc.TLS, R uintptr) (r uintptr) {
  14510. return R + libc.UintptrFromInt32(1)*16
  14511. }
  14512. func Xxcb_change_gc_value_list_serialize(tls *libc.TLS, _buffer uintptr, value_mask Tuint32_t, _aux uintptr) (r int32) {
  14513. bp := tls.Alloc(16)
  14514. defer tls.Free(16)
  14515. var i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset, xcb_parts_idx uint32
  14516. var xcb_out, xcb_tmp uintptr
  14517. var xcb_parts [24]Tiovec
  14518. var _ /* xcb_pad0 at bp+0 */ [3]int8
  14519. _, _, _, _, _, _, _, _, _, _ = i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_out, xcb_pad, xcb_padding_offset, xcb_parts, xcb_parts_idx, xcb_tmp
  14520. xcb_out = *(*uintptr)(unsafe.Pointer(_buffer))
  14521. xcb_buffer_len = uint32(0)
  14522. xcb_align_to = uint32(0)
  14523. xcb_padding_offset = uint32(0)
  14524. xcb_pad = uint32(0)
  14525. *(*[3]int8)(unsafe.Pointer(bp)) = [3]int8{}
  14526. xcb_parts_idx = uint32(0)
  14527. xcb_block_len = uint32(0)
  14528. if value_mask&uint32(_XCB_GC_FUNCTION) != 0 {
  14529. /* xcb_change_gc_value_list_t.function */
  14530. xcb_parts[xcb_parts_idx].Fiov_base = _aux
  14531. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14532. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14533. xcb_parts_idx++
  14534. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14535. }
  14536. if value_mask&uint32(_XCB_GC_PLANE_MASK) != 0 {
  14537. /* xcb_change_gc_value_list_t.plane_mask */
  14538. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 4
  14539. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14540. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14541. xcb_parts_idx++
  14542. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14543. }
  14544. if value_mask&uint32(_XCB_GC_FOREGROUND) != 0 {
  14545. /* xcb_change_gc_value_list_t.foreground */
  14546. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 8
  14547. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14548. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14549. xcb_parts_idx++
  14550. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14551. }
  14552. if value_mask&uint32(_XCB_GC_BACKGROUND) != 0 {
  14553. /* xcb_change_gc_value_list_t.background */
  14554. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 12
  14555. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14556. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14557. xcb_parts_idx++
  14558. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14559. }
  14560. if value_mask&uint32(_XCB_GC_LINE_WIDTH) != 0 {
  14561. /* xcb_change_gc_value_list_t.line_width */
  14562. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 16
  14563. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14564. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14565. xcb_parts_idx++
  14566. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14567. }
  14568. if value_mask&uint32(_XCB_GC_LINE_STYLE) != 0 {
  14569. /* xcb_change_gc_value_list_t.line_style */
  14570. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 20
  14571. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14572. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14573. xcb_parts_idx++
  14574. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14575. }
  14576. if value_mask&uint32(_XCB_GC_CAP_STYLE) != 0 {
  14577. /* xcb_change_gc_value_list_t.cap_style */
  14578. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 24
  14579. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14580. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14581. xcb_parts_idx++
  14582. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14583. }
  14584. if value_mask&uint32(_XCB_GC_JOIN_STYLE) != 0 {
  14585. /* xcb_change_gc_value_list_t.join_style */
  14586. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 28
  14587. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14588. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14589. xcb_parts_idx++
  14590. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14591. }
  14592. if value_mask&uint32(_XCB_GC_FILL_STYLE) != 0 {
  14593. /* xcb_change_gc_value_list_t.fill_style */
  14594. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 32
  14595. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14596. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14597. xcb_parts_idx++
  14598. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14599. }
  14600. if value_mask&uint32(_XCB_GC_FILL_RULE) != 0 {
  14601. /* xcb_change_gc_value_list_t.fill_rule */
  14602. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 36
  14603. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14604. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14605. xcb_parts_idx++
  14606. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14607. }
  14608. if value_mask&uint32(_XCB_GC_TILE) != 0 {
  14609. /* xcb_change_gc_value_list_t.tile */
  14610. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 40
  14611. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14612. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14613. xcb_parts_idx++
  14614. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14615. }
  14616. if value_mask&uint32(_XCB_GC_STIPPLE) != 0 {
  14617. /* xcb_change_gc_value_list_t.stipple */
  14618. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 44
  14619. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14620. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14621. xcb_parts_idx++
  14622. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14623. }
  14624. if value_mask&uint32(_XCB_GC_TILE_STIPPLE_ORIGIN_X) != 0 {
  14625. /* xcb_change_gc_value_list_t.tile_stipple_x_origin */
  14626. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 48
  14627. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14628. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14629. xcb_parts_idx++
  14630. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14631. }
  14632. if value_mask&uint32(_XCB_GC_TILE_STIPPLE_ORIGIN_Y) != 0 {
  14633. /* xcb_change_gc_value_list_t.tile_stipple_y_origin */
  14634. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 52
  14635. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14636. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14637. xcb_parts_idx++
  14638. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14639. }
  14640. if value_mask&uint32(_XCB_GC_FONT) != 0 {
  14641. /* xcb_change_gc_value_list_t.font */
  14642. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 56
  14643. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14644. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14645. xcb_parts_idx++
  14646. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14647. }
  14648. if value_mask&uint32(_XCB_GC_SUBWINDOW_MODE) != 0 {
  14649. /* xcb_change_gc_value_list_t.subwindow_mode */
  14650. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 60
  14651. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14652. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14653. xcb_parts_idx++
  14654. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14655. }
  14656. if value_mask&uint32(_XCB_GC_GRAPHICS_EXPOSURES) != 0 {
  14657. /* xcb_change_gc_value_list_t.graphics_exposures */
  14658. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 64
  14659. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14660. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14661. xcb_parts_idx++
  14662. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14663. }
  14664. if value_mask&uint32(_XCB_GC_CLIP_ORIGIN_X) != 0 {
  14665. /* xcb_change_gc_value_list_t.clip_x_origin */
  14666. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 68
  14667. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14668. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14669. xcb_parts_idx++
  14670. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14671. }
  14672. if value_mask&uint32(_XCB_GC_CLIP_ORIGIN_Y) != 0 {
  14673. /* xcb_change_gc_value_list_t.clip_y_origin */
  14674. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 72
  14675. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14676. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14677. xcb_parts_idx++
  14678. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14679. }
  14680. if value_mask&uint32(_XCB_GC_CLIP_MASK) != 0 {
  14681. /* xcb_change_gc_value_list_t.clip_mask */
  14682. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 76
  14683. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14684. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14685. xcb_parts_idx++
  14686. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14687. }
  14688. if value_mask&uint32(_XCB_GC_DASH_OFFSET) != 0 {
  14689. /* xcb_change_gc_value_list_t.dash_offset */
  14690. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 80
  14691. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14692. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14693. xcb_parts_idx++
  14694. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14695. }
  14696. if value_mask&uint32(_XCB_GC_DASH_LIST) != 0 {
  14697. /* xcb_change_gc_value_list_t.dashes */
  14698. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 84
  14699. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14700. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14701. xcb_parts_idx++
  14702. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14703. }
  14704. if value_mask&uint32(_XCB_GC_ARC_MODE) != 0 {
  14705. /* xcb_change_gc_value_list_t.arc_mode */
  14706. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 88
  14707. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14708. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  14709. xcb_parts_idx++
  14710. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14711. }
  14712. /* insert padding */
  14713. xcb_pad = -(xcb_block_len + xcb_padding_offset) & (xcb_align_to - uint32(1))
  14714. xcb_buffer_len += xcb_block_len + xcb_pad
  14715. if uint32(0) != xcb_pad {
  14716. xcb_parts[xcb_parts_idx].Fiov_base = bp
  14717. xcb_parts[xcb_parts_idx].Fiov_len = uint64(xcb_pad)
  14718. xcb_parts_idx++
  14719. xcb_pad = uint32(0)
  14720. }
  14721. xcb_block_len = uint32(0)
  14722. xcb_padding_offset = uint32(0)
  14723. if libc.UintptrFromInt32(0) == xcb_out {
  14724. /* allocate memory */
  14725. xcb_out = libc.Xmalloc(tls, uint64(xcb_buffer_len))
  14726. *(*uintptr)(unsafe.Pointer(_buffer)) = xcb_out
  14727. }
  14728. xcb_tmp = xcb_out
  14729. i = uint32(0)
  14730. for {
  14731. if !(i < xcb_parts_idx) {
  14732. break
  14733. }
  14734. if uintptr(0) != xcb_parts[i].Fiov_base && uint64(0) != xcb_parts[i].Fiov_len {
  14735. libc.Xmemcpy(tls, xcb_tmp, xcb_parts[i].Fiov_base, xcb_parts[i].Fiov_len)
  14736. }
  14737. if uint64(0) != xcb_parts[i].Fiov_len {
  14738. xcb_tmp += uintptr(xcb_parts[i].Fiov_len)
  14739. }
  14740. goto _1
  14741. _1:
  14742. ;
  14743. i++
  14744. }
  14745. return libc.Int32FromUint32(xcb_buffer_len)
  14746. }
  14747. func Xxcb_change_gc_value_list_unpack(tls *libc.TLS, _buffer uintptr, value_mask Tuint32_t, _aux uintptr) (r int32) {
  14748. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset uint32
  14749. var xcb_tmp uintptr
  14750. _, _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset, xcb_tmp
  14751. xcb_tmp = _buffer
  14752. xcb_buffer_len = uint32(0)
  14753. xcb_block_len = uint32(0)
  14754. xcb_pad = uint32(0)
  14755. xcb_align_to = uint32(0)
  14756. xcb_padding_offset = uint32(0)
  14757. if value_mask&uint32(_XCB_GC_FUNCTION) != 0 {
  14758. /* xcb_change_gc_value_list_t.function */
  14759. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Ffunction = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14760. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14761. xcb_tmp += uintptr(4)
  14762. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14763. }
  14764. if value_mask&uint32(_XCB_GC_PLANE_MASK) != 0 {
  14765. /* xcb_change_gc_value_list_t.plane_mask */
  14766. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Fplane_mask = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14767. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14768. xcb_tmp += uintptr(4)
  14769. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14770. }
  14771. if value_mask&uint32(_XCB_GC_FOREGROUND) != 0 {
  14772. /* xcb_change_gc_value_list_t.foreground */
  14773. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Fforeground = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14774. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14775. xcb_tmp += uintptr(4)
  14776. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14777. }
  14778. if value_mask&uint32(_XCB_GC_BACKGROUND) != 0 {
  14779. /* xcb_change_gc_value_list_t.background */
  14780. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Fbackground = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14781. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14782. xcb_tmp += uintptr(4)
  14783. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14784. }
  14785. if value_mask&uint32(_XCB_GC_LINE_WIDTH) != 0 {
  14786. /* xcb_change_gc_value_list_t.line_width */
  14787. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Fline_width = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14788. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14789. xcb_tmp += uintptr(4)
  14790. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14791. }
  14792. if value_mask&uint32(_XCB_GC_LINE_STYLE) != 0 {
  14793. /* xcb_change_gc_value_list_t.line_style */
  14794. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Fline_style = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14795. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14796. xcb_tmp += uintptr(4)
  14797. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14798. }
  14799. if value_mask&uint32(_XCB_GC_CAP_STYLE) != 0 {
  14800. /* xcb_change_gc_value_list_t.cap_style */
  14801. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Fcap_style = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14802. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14803. xcb_tmp += uintptr(4)
  14804. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14805. }
  14806. if value_mask&uint32(_XCB_GC_JOIN_STYLE) != 0 {
  14807. /* xcb_change_gc_value_list_t.join_style */
  14808. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Fjoin_style = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14809. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14810. xcb_tmp += uintptr(4)
  14811. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14812. }
  14813. if value_mask&uint32(_XCB_GC_FILL_STYLE) != 0 {
  14814. /* xcb_change_gc_value_list_t.fill_style */
  14815. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Ffill_style = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14816. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14817. xcb_tmp += uintptr(4)
  14818. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14819. }
  14820. if value_mask&uint32(_XCB_GC_FILL_RULE) != 0 {
  14821. /* xcb_change_gc_value_list_t.fill_rule */
  14822. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Ffill_rule = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14823. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14824. xcb_tmp += uintptr(4)
  14825. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14826. }
  14827. if value_mask&uint32(_XCB_GC_TILE) != 0 {
  14828. /* xcb_change_gc_value_list_t.tile */
  14829. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Ftile = *(*Txcb_pixmap_t)(unsafe.Pointer(xcb_tmp))
  14830. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14831. xcb_tmp += uintptr(4)
  14832. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14833. }
  14834. if value_mask&uint32(_XCB_GC_STIPPLE) != 0 {
  14835. /* xcb_change_gc_value_list_t.stipple */
  14836. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Fstipple = *(*Txcb_pixmap_t)(unsafe.Pointer(xcb_tmp))
  14837. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14838. xcb_tmp += uintptr(4)
  14839. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14840. }
  14841. if value_mask&uint32(_XCB_GC_TILE_STIPPLE_ORIGIN_X) != 0 {
  14842. /* xcb_change_gc_value_list_t.tile_stipple_x_origin */
  14843. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Ftile_stipple_x_origin = *(*Tint32_t)(unsafe.Pointer(xcb_tmp))
  14844. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14845. xcb_tmp += uintptr(4)
  14846. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14847. }
  14848. if value_mask&uint32(_XCB_GC_TILE_STIPPLE_ORIGIN_Y) != 0 {
  14849. /* xcb_change_gc_value_list_t.tile_stipple_y_origin */
  14850. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Ftile_stipple_y_origin = *(*Tint32_t)(unsafe.Pointer(xcb_tmp))
  14851. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14852. xcb_tmp += uintptr(4)
  14853. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14854. }
  14855. if value_mask&uint32(_XCB_GC_FONT) != 0 {
  14856. /* xcb_change_gc_value_list_t.font */
  14857. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Ffont = *(*Txcb_font_t)(unsafe.Pointer(xcb_tmp))
  14858. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14859. xcb_tmp += uintptr(4)
  14860. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14861. }
  14862. if value_mask&uint32(_XCB_GC_SUBWINDOW_MODE) != 0 {
  14863. /* xcb_change_gc_value_list_t.subwindow_mode */
  14864. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Fsubwindow_mode = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14865. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14866. xcb_tmp += uintptr(4)
  14867. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14868. }
  14869. if value_mask&uint32(_XCB_GC_GRAPHICS_EXPOSURES) != 0 {
  14870. /* xcb_change_gc_value_list_t.graphics_exposures */
  14871. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Fgraphics_exposures = *(*Txcb_bool32_t)(unsafe.Pointer(xcb_tmp))
  14872. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14873. xcb_tmp += uintptr(4)
  14874. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14875. }
  14876. if value_mask&uint32(_XCB_GC_CLIP_ORIGIN_X) != 0 {
  14877. /* xcb_change_gc_value_list_t.clip_x_origin */
  14878. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Fclip_x_origin = *(*Tint32_t)(unsafe.Pointer(xcb_tmp))
  14879. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14880. xcb_tmp += uintptr(4)
  14881. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14882. }
  14883. if value_mask&uint32(_XCB_GC_CLIP_ORIGIN_Y) != 0 {
  14884. /* xcb_change_gc_value_list_t.clip_y_origin */
  14885. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Fclip_y_origin = *(*Tint32_t)(unsafe.Pointer(xcb_tmp))
  14886. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14887. xcb_tmp += uintptr(4)
  14888. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14889. }
  14890. if value_mask&uint32(_XCB_GC_CLIP_MASK) != 0 {
  14891. /* xcb_change_gc_value_list_t.clip_mask */
  14892. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Fclip_mask = *(*Txcb_pixmap_t)(unsafe.Pointer(xcb_tmp))
  14893. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14894. xcb_tmp += uintptr(4)
  14895. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14896. }
  14897. if value_mask&uint32(_XCB_GC_DASH_OFFSET) != 0 {
  14898. /* xcb_change_gc_value_list_t.dash_offset */
  14899. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Fdash_offset = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14900. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14901. xcb_tmp += uintptr(4)
  14902. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14903. }
  14904. if value_mask&uint32(_XCB_GC_DASH_LIST) != 0 {
  14905. /* xcb_change_gc_value_list_t.dashes */
  14906. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Fdashes = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14907. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14908. xcb_tmp += uintptr(4)
  14909. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14910. }
  14911. if value_mask&uint32(_XCB_GC_ARC_MODE) != 0 {
  14912. /* xcb_change_gc_value_list_t.arc_mode */
  14913. (*Txcb_change_gc_value_list_t)(unsafe.Pointer(_aux)).Farc_mode = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  14914. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  14915. xcb_tmp += uintptr(4)
  14916. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  14917. }
  14918. /* insert padding */
  14919. xcb_pad = -(xcb_block_len + xcb_padding_offset) & (xcb_align_to - uint32(1))
  14920. xcb_buffer_len += xcb_block_len + xcb_pad
  14921. if uint32(0) != xcb_pad {
  14922. xcb_tmp += uintptr(xcb_pad)
  14923. xcb_pad = uint32(0)
  14924. }
  14925. xcb_block_len = uint32(0)
  14926. xcb_padding_offset = uint32(0)
  14927. return libc.Int32FromUint32(xcb_buffer_len)
  14928. }
  14929. func Xxcb_change_gc_value_list_sizeof(tls *libc.TLS, _buffer uintptr, value_mask Tuint32_t) (r int32) {
  14930. bp := tls.Alloc(96)
  14931. defer tls.Free(96)
  14932. var _ /* _aux at bp+0 */ Txcb_change_gc_value_list_t
  14933. return Xxcb_change_gc_value_list_unpack(tls, _buffer, value_mask, bp)
  14934. }
  14935. func Xxcb_change_gc_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  14936. var _aux, xcb_tmp uintptr
  14937. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  14938. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  14939. xcb_tmp = _buffer
  14940. _aux = _buffer
  14941. xcb_buffer_len = uint32(0)
  14942. xcb_block_len = uint32(0)
  14943. xcb_pad = uint32(0)
  14944. xcb_align_to = uint32(0)
  14945. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  14946. xcb_tmp += uintptr(xcb_block_len)
  14947. xcb_buffer_len += xcb_block_len
  14948. xcb_block_len = uint32(0)
  14949. /* value_list */
  14950. xcb_block_len += libc.Uint32FromInt32(Xxcb_change_gc_value_list_sizeof(tls, xcb_tmp, (*Txcb_change_gc_request_t)(unsafe.Pointer(_aux)).Fvalue_mask))
  14951. xcb_tmp += uintptr(xcb_block_len)
  14952. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  14953. /* insert padding */
  14954. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  14955. xcb_buffer_len += xcb_block_len + xcb_pad
  14956. if uint32(0) != xcb_pad {
  14957. xcb_tmp += uintptr(xcb_pad)
  14958. xcb_pad = uint32(0)
  14959. }
  14960. xcb_block_len = uint32(0)
  14961. return libc.Int32FromUint32(xcb_buffer_len)
  14962. }
  14963. func Xxcb_change_gc_checked(tls *libc.TLS, c uintptr, gc Txcb_gcontext_t, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  14964. bp := tls.Alloc(96)
  14965. defer tls.Free(96)
  14966. var xcb_ret Txcb_void_cookie_t
  14967. var _ /* xcb_out at bp+80 */ Txcb_change_gc_request_t
  14968. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  14969. _ = xcb_ret
  14970. (*(*Txcb_change_gc_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  14971. (*(*Txcb_change_gc_request_t)(unsafe.Pointer(bp + 80))).Fgc = gc
  14972. (*(*Txcb_change_gc_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  14973. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  14974. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  14975. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  14976. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  14977. /* xcb_change_gc_value_list_t value_list */
  14978. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = value_list
  14979. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_change_gc_value_list_sizeof(tls, value_list, value_mask))
  14980. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req118)))
  14981. return xcb_ret
  14982. }
  14983. var _xcb_req118 = Txcb_protocol_request_t{
  14984. Fcount: uint64(3),
  14985. Fopcode: uint8(m_XCB_CHANGE_GC),
  14986. Fisvoid: uint8(1),
  14987. }
  14988. func Xxcb_change_gc(tls *libc.TLS, c uintptr, gc Txcb_gcontext_t, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  14989. bp := tls.Alloc(96)
  14990. defer tls.Free(96)
  14991. var xcb_ret Txcb_void_cookie_t
  14992. var _ /* xcb_out at bp+80 */ Txcb_change_gc_request_t
  14993. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  14994. _ = xcb_ret
  14995. (*(*Txcb_change_gc_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  14996. (*(*Txcb_change_gc_request_t)(unsafe.Pointer(bp + 80))).Fgc = gc
  14997. (*(*Txcb_change_gc_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  14998. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  14999. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  15000. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15001. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15002. /* xcb_change_gc_value_list_t value_list */
  15003. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = value_list
  15004. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_change_gc_value_list_sizeof(tls, value_list, value_mask))
  15005. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req119)))
  15006. return xcb_ret
  15007. }
  15008. var _xcb_req119 = Txcb_protocol_request_t{
  15009. Fcount: uint64(3),
  15010. Fopcode: uint8(m_XCB_CHANGE_GC),
  15011. Fisvoid: uint8(1),
  15012. }
  15013. func Xxcb_change_gc_aux_checked(tls *libc.TLS, c uintptr, gc Txcb_gcontext_t, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  15014. bp := tls.Alloc(112)
  15015. defer tls.Free(112)
  15016. var xcb_ret Txcb_void_cookie_t
  15017. var _ /* xcb_aux0 at bp+96 */ uintptr
  15018. var _ /* xcb_out at bp+80 */ Txcb_change_gc_request_t
  15019. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  15020. _ = xcb_ret
  15021. *(*uintptr)(unsafe.Pointer(bp + 96)) = uintptr(0)
  15022. (*(*Txcb_change_gc_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  15023. (*(*Txcb_change_gc_request_t)(unsafe.Pointer(bp + 80))).Fgc = gc
  15024. (*(*Txcb_change_gc_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  15025. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  15026. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  15027. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15028. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15029. /* xcb_change_gc_value_list_t value_list */
  15030. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_change_gc_value_list_serialize(tls, bp+96, value_mask, value_list))
  15031. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = *(*uintptr)(unsafe.Pointer(bp + 96))
  15032. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req120)))
  15033. libc.Xfree(tls, *(*uintptr)(unsafe.Pointer(bp + 96)))
  15034. return xcb_ret
  15035. }
  15036. var _xcb_req120 = Txcb_protocol_request_t{
  15037. Fcount: uint64(3),
  15038. Fopcode: uint8(m_XCB_CHANGE_GC),
  15039. Fisvoid: uint8(1),
  15040. }
  15041. func Xxcb_change_gc_aux(tls *libc.TLS, c uintptr, gc Txcb_gcontext_t, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  15042. bp := tls.Alloc(112)
  15043. defer tls.Free(112)
  15044. var xcb_ret Txcb_void_cookie_t
  15045. var _ /* xcb_aux0 at bp+96 */ uintptr
  15046. var _ /* xcb_out at bp+80 */ Txcb_change_gc_request_t
  15047. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  15048. _ = xcb_ret
  15049. *(*uintptr)(unsafe.Pointer(bp + 96)) = uintptr(0)
  15050. (*(*Txcb_change_gc_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  15051. (*(*Txcb_change_gc_request_t)(unsafe.Pointer(bp + 80))).Fgc = gc
  15052. (*(*Txcb_change_gc_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  15053. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  15054. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  15055. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15056. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15057. /* xcb_change_gc_value_list_t value_list */
  15058. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_change_gc_value_list_serialize(tls, bp+96, value_mask, value_list))
  15059. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = *(*uintptr)(unsafe.Pointer(bp + 96))
  15060. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req121)))
  15061. libc.Xfree(tls, *(*uintptr)(unsafe.Pointer(bp + 96)))
  15062. return xcb_ret
  15063. }
  15064. var _xcb_req121 = Txcb_protocol_request_t{
  15065. Fcount: uint64(3),
  15066. Fopcode: uint8(m_XCB_CHANGE_GC),
  15067. Fisvoid: uint8(1),
  15068. }
  15069. func Xxcb_change_gc_value_list(tls *libc.TLS, R uintptr) (r uintptr) {
  15070. return R + libc.UintptrFromInt32(1)*12
  15071. }
  15072. func Xxcb_copy_gc_checked(tls *libc.TLS, c uintptr, src_gc Txcb_gcontext_t, dst_gc Txcb_gcontext_t, value_mask Tuint32_t) (r Txcb_void_cookie_t) {
  15073. bp := tls.Alloc(80)
  15074. defer tls.Free(80)
  15075. var xcb_ret Txcb_void_cookie_t
  15076. var _ /* xcb_out at bp+64 */ Txcb_copy_gc_request_t
  15077. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  15078. _ = xcb_ret
  15079. (*(*Txcb_copy_gc_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  15080. (*(*Txcb_copy_gc_request_t)(unsafe.Pointer(bp + 64))).Fsrc_gc = src_gc
  15081. (*(*Txcb_copy_gc_request_t)(unsafe.Pointer(bp + 64))).Fdst_gc = dst_gc
  15082. (*(*Txcb_copy_gc_request_t)(unsafe.Pointer(bp + 64))).Fvalue_mask = value_mask
  15083. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  15084. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  15085. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15086. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15087. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req122)))
  15088. return xcb_ret
  15089. }
  15090. var _xcb_req122 = Txcb_protocol_request_t{
  15091. Fcount: uint64(2),
  15092. Fopcode: uint8(m_XCB_COPY_GC),
  15093. Fisvoid: uint8(1),
  15094. }
  15095. func Xxcb_copy_gc(tls *libc.TLS, c uintptr, src_gc Txcb_gcontext_t, dst_gc Txcb_gcontext_t, value_mask Tuint32_t) (r Txcb_void_cookie_t) {
  15096. bp := tls.Alloc(80)
  15097. defer tls.Free(80)
  15098. var xcb_ret Txcb_void_cookie_t
  15099. var _ /* xcb_out at bp+64 */ Txcb_copy_gc_request_t
  15100. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  15101. _ = xcb_ret
  15102. (*(*Txcb_copy_gc_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  15103. (*(*Txcb_copy_gc_request_t)(unsafe.Pointer(bp + 64))).Fsrc_gc = src_gc
  15104. (*(*Txcb_copy_gc_request_t)(unsafe.Pointer(bp + 64))).Fdst_gc = dst_gc
  15105. (*(*Txcb_copy_gc_request_t)(unsafe.Pointer(bp + 64))).Fvalue_mask = value_mask
  15106. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  15107. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  15108. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15109. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15110. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req123)))
  15111. return xcb_ret
  15112. }
  15113. var _xcb_req123 = Txcb_protocol_request_t{
  15114. Fcount: uint64(2),
  15115. Fopcode: uint8(m_XCB_COPY_GC),
  15116. Fisvoid: uint8(1),
  15117. }
  15118. func Xxcb_set_dashes_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  15119. var _aux, xcb_tmp uintptr
  15120. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  15121. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  15122. xcb_tmp = _buffer
  15123. _aux = _buffer
  15124. xcb_buffer_len = uint32(0)
  15125. xcb_block_len = uint32(0)
  15126. xcb_pad = uint32(0)
  15127. xcb_align_to = uint32(0)
  15128. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  15129. xcb_tmp += uintptr(xcb_block_len)
  15130. xcb_buffer_len += xcb_block_len
  15131. xcb_block_len = uint32(0)
  15132. /* dashes */
  15133. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_set_dashes_request_t)(unsafe.Pointer(_aux)).Fdashes_len)*libc.Uint64FromInt64(1))
  15134. xcb_tmp += uintptr(xcb_block_len)
  15135. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  15136. /* insert padding */
  15137. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  15138. xcb_buffer_len += xcb_block_len + xcb_pad
  15139. if uint32(0) != xcb_pad {
  15140. xcb_tmp += uintptr(xcb_pad)
  15141. xcb_pad = uint32(0)
  15142. }
  15143. xcb_block_len = uint32(0)
  15144. return libc.Int32FromUint32(xcb_buffer_len)
  15145. }
  15146. func Xxcb_set_dashes_checked(tls *libc.TLS, c uintptr, gc Txcb_gcontext_t, dash_offset Tuint16_t, dashes_len Tuint16_t, dashes uintptr) (r Txcb_void_cookie_t) {
  15147. bp := tls.Alloc(112)
  15148. defer tls.Free(112)
  15149. var xcb_ret Txcb_void_cookie_t
  15150. var _ /* xcb_out at bp+96 */ Txcb_set_dashes_request_t
  15151. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  15152. _ = xcb_ret
  15153. (*(*Txcb_set_dashes_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  15154. (*(*Txcb_set_dashes_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  15155. (*(*Txcb_set_dashes_request_t)(unsafe.Pointer(bp + 96))).Fdash_offset = dash_offset
  15156. (*(*Txcb_set_dashes_request_t)(unsafe.Pointer(bp + 96))).Fdashes_len = dashes_len
  15157. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  15158. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  15159. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15160. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15161. /* uint8_t dashes */
  15162. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = dashes
  15163. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(dashes_len) * uint64(1)
  15164. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  15165. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  15166. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req124)))
  15167. return xcb_ret
  15168. }
  15169. var _xcb_req124 = Txcb_protocol_request_t{
  15170. Fcount: uint64(4),
  15171. Fopcode: uint8(m_XCB_SET_DASHES),
  15172. Fisvoid: uint8(1),
  15173. }
  15174. func Xxcb_set_dashes(tls *libc.TLS, c uintptr, gc Txcb_gcontext_t, dash_offset Tuint16_t, dashes_len Tuint16_t, dashes uintptr) (r Txcb_void_cookie_t) {
  15175. bp := tls.Alloc(112)
  15176. defer tls.Free(112)
  15177. var xcb_ret Txcb_void_cookie_t
  15178. var _ /* xcb_out at bp+96 */ Txcb_set_dashes_request_t
  15179. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  15180. _ = xcb_ret
  15181. (*(*Txcb_set_dashes_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  15182. (*(*Txcb_set_dashes_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  15183. (*(*Txcb_set_dashes_request_t)(unsafe.Pointer(bp + 96))).Fdash_offset = dash_offset
  15184. (*(*Txcb_set_dashes_request_t)(unsafe.Pointer(bp + 96))).Fdashes_len = dashes_len
  15185. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  15186. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  15187. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15188. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15189. /* uint8_t dashes */
  15190. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = dashes
  15191. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(dashes_len) * uint64(1)
  15192. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  15193. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  15194. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req125)))
  15195. return xcb_ret
  15196. }
  15197. var _xcb_req125 = Txcb_protocol_request_t{
  15198. Fcount: uint64(4),
  15199. Fopcode: uint8(m_XCB_SET_DASHES),
  15200. Fisvoid: uint8(1),
  15201. }
  15202. func Xxcb_set_dashes_dashes(tls *libc.TLS, R uintptr) (r uintptr) {
  15203. return R + libc.UintptrFromInt32(1)*12
  15204. }
  15205. func Xxcb_set_dashes_dashes_length(tls *libc.TLS, R uintptr) (r int32) {
  15206. return libc.Int32FromUint16((*Txcb_set_dashes_request_t)(unsafe.Pointer(R)).Fdashes_len)
  15207. }
  15208. func Xxcb_set_dashes_dashes_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  15209. var i Txcb_generic_iterator_t
  15210. _ = i
  15211. i.Fdata = R + libc.UintptrFromInt32(1)*12 + uintptr((*Txcb_set_dashes_request_t)(unsafe.Pointer(R)).Fdashes_len)
  15212. i.Frem = 0
  15213. i.Findex = int32(int64(i.Fdata) - int64(R))
  15214. return i
  15215. }
  15216. func Xxcb_set_clip_rectangles_sizeof(tls *libc.TLS, _buffer uintptr, rectangles_len Tuint32_t) (r int32) {
  15217. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  15218. var xcb_tmp uintptr
  15219. _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  15220. xcb_tmp = _buffer
  15221. xcb_buffer_len = uint32(0)
  15222. xcb_block_len = uint32(0)
  15223. xcb_pad = uint32(0)
  15224. xcb_align_to = uint32(0)
  15225. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  15226. xcb_tmp += uintptr(xcb_block_len)
  15227. xcb_buffer_len += xcb_block_len
  15228. xcb_block_len = uint32(0)
  15229. /* rectangles */
  15230. xcb_block_len = uint32(uint64(xcb_block_len) + uint64(rectangles_len)*libc.Uint64FromInt64(8))
  15231. xcb_tmp += uintptr(xcb_block_len)
  15232. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 2))
  15233. /* insert padding */
  15234. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  15235. xcb_buffer_len += xcb_block_len + xcb_pad
  15236. if uint32(0) != xcb_pad {
  15237. xcb_tmp += uintptr(xcb_pad)
  15238. xcb_pad = uint32(0)
  15239. }
  15240. xcb_block_len = uint32(0)
  15241. return libc.Int32FromUint32(xcb_buffer_len)
  15242. }
  15243. func Xxcb_set_clip_rectangles_checked(tls *libc.TLS, c uintptr, ordering Tuint8_t, gc Txcb_gcontext_t, clip_x_origin Tint16_t, clip_y_origin Tint16_t, rectangles_len Tuint32_t, rectangles uintptr) (r Txcb_void_cookie_t) {
  15244. bp := tls.Alloc(112)
  15245. defer tls.Free(112)
  15246. var xcb_ret Txcb_void_cookie_t
  15247. var _ /* xcb_out at bp+96 */ Txcb_set_clip_rectangles_request_t
  15248. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  15249. _ = xcb_ret
  15250. (*(*Txcb_set_clip_rectangles_request_t)(unsafe.Pointer(bp + 96))).Fordering = ordering
  15251. (*(*Txcb_set_clip_rectangles_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  15252. (*(*Txcb_set_clip_rectangles_request_t)(unsafe.Pointer(bp + 96))).Fclip_x_origin = clip_x_origin
  15253. (*(*Txcb_set_clip_rectangles_request_t)(unsafe.Pointer(bp + 96))).Fclip_y_origin = clip_y_origin
  15254. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  15255. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  15256. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15257. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15258. /* xcb_rectangle_t rectangles */
  15259. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = rectangles
  15260. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(rectangles_len) * uint64(8)
  15261. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  15262. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  15263. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req126)))
  15264. return xcb_ret
  15265. }
  15266. var _xcb_req126 = Txcb_protocol_request_t{
  15267. Fcount: uint64(4),
  15268. Fopcode: uint8(m_XCB_SET_CLIP_RECTANGLES),
  15269. Fisvoid: uint8(1),
  15270. }
  15271. func Xxcb_set_clip_rectangles(tls *libc.TLS, c uintptr, ordering Tuint8_t, gc Txcb_gcontext_t, clip_x_origin Tint16_t, clip_y_origin Tint16_t, rectangles_len Tuint32_t, rectangles uintptr) (r Txcb_void_cookie_t) {
  15272. bp := tls.Alloc(112)
  15273. defer tls.Free(112)
  15274. var xcb_ret Txcb_void_cookie_t
  15275. var _ /* xcb_out at bp+96 */ Txcb_set_clip_rectangles_request_t
  15276. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  15277. _ = xcb_ret
  15278. (*(*Txcb_set_clip_rectangles_request_t)(unsafe.Pointer(bp + 96))).Fordering = ordering
  15279. (*(*Txcb_set_clip_rectangles_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  15280. (*(*Txcb_set_clip_rectangles_request_t)(unsafe.Pointer(bp + 96))).Fclip_x_origin = clip_x_origin
  15281. (*(*Txcb_set_clip_rectangles_request_t)(unsafe.Pointer(bp + 96))).Fclip_y_origin = clip_y_origin
  15282. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  15283. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  15284. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15285. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15286. /* xcb_rectangle_t rectangles */
  15287. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = rectangles
  15288. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(rectangles_len) * uint64(8)
  15289. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  15290. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  15291. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req127)))
  15292. return xcb_ret
  15293. }
  15294. var _xcb_req127 = Txcb_protocol_request_t{
  15295. Fcount: uint64(4),
  15296. Fopcode: uint8(m_XCB_SET_CLIP_RECTANGLES),
  15297. Fisvoid: uint8(1),
  15298. }
  15299. func Xxcb_set_clip_rectangles_rectangles(tls *libc.TLS, R uintptr) (r uintptr) {
  15300. return R + libc.UintptrFromInt32(1)*12
  15301. }
  15302. func Xxcb_set_clip_rectangles_rectangles_length(tls *libc.TLS, R uintptr) (r int32) {
  15303. return libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_set_clip_rectangles_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(12)) / libc.Uint64FromInt64(8))
  15304. }
  15305. func Xxcb_set_clip_rectangles_rectangles_iterator(tls *libc.TLS, R uintptr) (r Txcb_rectangle_iterator_t) {
  15306. var i Txcb_rectangle_iterator_t
  15307. _ = i
  15308. i.Fdata = R + libc.UintptrFromInt32(1)*12
  15309. i.Frem = libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_set_clip_rectangles_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(12)) / libc.Uint64FromInt64(8))
  15310. i.Findex = int32(int64(i.Fdata) - int64(R))
  15311. return i
  15312. }
  15313. func Xxcb_free_gc_checked(tls *libc.TLS, c uintptr, gc Txcb_gcontext_t) (r Txcb_void_cookie_t) {
  15314. bp := tls.Alloc(80)
  15315. defer tls.Free(80)
  15316. var xcb_ret Txcb_void_cookie_t
  15317. var _ /* xcb_out at bp+64 */ Txcb_free_gc_request_t
  15318. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  15319. _ = xcb_ret
  15320. (*(*Txcb_free_gc_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  15321. (*(*Txcb_free_gc_request_t)(unsafe.Pointer(bp + 64))).Fgc = gc
  15322. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  15323. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  15324. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15325. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15326. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req128)))
  15327. return xcb_ret
  15328. }
  15329. var _xcb_req128 = Txcb_protocol_request_t{
  15330. Fcount: uint64(2),
  15331. Fopcode: uint8(m_XCB_FREE_GC),
  15332. Fisvoid: uint8(1),
  15333. }
  15334. func Xxcb_free_gc(tls *libc.TLS, c uintptr, gc Txcb_gcontext_t) (r Txcb_void_cookie_t) {
  15335. bp := tls.Alloc(80)
  15336. defer tls.Free(80)
  15337. var xcb_ret Txcb_void_cookie_t
  15338. var _ /* xcb_out at bp+64 */ Txcb_free_gc_request_t
  15339. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  15340. _ = xcb_ret
  15341. (*(*Txcb_free_gc_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  15342. (*(*Txcb_free_gc_request_t)(unsafe.Pointer(bp + 64))).Fgc = gc
  15343. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  15344. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  15345. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15346. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15347. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req129)))
  15348. return xcb_ret
  15349. }
  15350. var _xcb_req129 = Txcb_protocol_request_t{
  15351. Fcount: uint64(2),
  15352. Fopcode: uint8(m_XCB_FREE_GC),
  15353. Fisvoid: uint8(1),
  15354. }
  15355. func Xxcb_clear_area_checked(tls *libc.TLS, c uintptr, exposures Tuint8_t, window Txcb_window_t, x Tint16_t, y Tint16_t, width Tuint16_t, height Tuint16_t) (r Txcb_void_cookie_t) {
  15356. bp := tls.Alloc(80)
  15357. defer tls.Free(80)
  15358. var xcb_ret Txcb_void_cookie_t
  15359. var _ /* xcb_out at bp+64 */ Txcb_clear_area_request_t
  15360. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  15361. _ = xcb_ret
  15362. (*(*Txcb_clear_area_request_t)(unsafe.Pointer(bp + 64))).Fexposures = exposures
  15363. (*(*Txcb_clear_area_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  15364. (*(*Txcb_clear_area_request_t)(unsafe.Pointer(bp + 64))).Fx = x
  15365. (*(*Txcb_clear_area_request_t)(unsafe.Pointer(bp + 64))).Fy = y
  15366. (*(*Txcb_clear_area_request_t)(unsafe.Pointer(bp + 64))).Fwidth = width
  15367. (*(*Txcb_clear_area_request_t)(unsafe.Pointer(bp + 64))).Fheight = height
  15368. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  15369. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  15370. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15371. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15372. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req130)))
  15373. return xcb_ret
  15374. }
  15375. var _xcb_req130 = Txcb_protocol_request_t{
  15376. Fcount: uint64(2),
  15377. Fopcode: uint8(m_XCB_CLEAR_AREA),
  15378. Fisvoid: uint8(1),
  15379. }
  15380. func Xxcb_clear_area(tls *libc.TLS, c uintptr, exposures Tuint8_t, window Txcb_window_t, x Tint16_t, y Tint16_t, width Tuint16_t, height Tuint16_t) (r Txcb_void_cookie_t) {
  15381. bp := tls.Alloc(80)
  15382. defer tls.Free(80)
  15383. var xcb_ret Txcb_void_cookie_t
  15384. var _ /* xcb_out at bp+64 */ Txcb_clear_area_request_t
  15385. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  15386. _ = xcb_ret
  15387. (*(*Txcb_clear_area_request_t)(unsafe.Pointer(bp + 64))).Fexposures = exposures
  15388. (*(*Txcb_clear_area_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  15389. (*(*Txcb_clear_area_request_t)(unsafe.Pointer(bp + 64))).Fx = x
  15390. (*(*Txcb_clear_area_request_t)(unsafe.Pointer(bp + 64))).Fy = y
  15391. (*(*Txcb_clear_area_request_t)(unsafe.Pointer(bp + 64))).Fwidth = width
  15392. (*(*Txcb_clear_area_request_t)(unsafe.Pointer(bp + 64))).Fheight = height
  15393. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  15394. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  15395. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15396. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15397. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req131)))
  15398. return xcb_ret
  15399. }
  15400. var _xcb_req131 = Txcb_protocol_request_t{
  15401. Fcount: uint64(2),
  15402. Fopcode: uint8(m_XCB_CLEAR_AREA),
  15403. Fisvoid: uint8(1),
  15404. }
  15405. func Xxcb_copy_area_checked(tls *libc.TLS, c uintptr, src_drawable Txcb_drawable_t, dst_drawable Txcb_drawable_t, gc Txcb_gcontext_t, src_x Tint16_t, src_y Tint16_t, dst_x Tint16_t, dst_y Tint16_t, width Tuint16_t, height Tuint16_t) (r Txcb_void_cookie_t) {
  15406. bp := tls.Alloc(96)
  15407. defer tls.Free(96)
  15408. var xcb_ret Txcb_void_cookie_t
  15409. var _ /* xcb_out at bp+64 */ Txcb_copy_area_request_t
  15410. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  15411. _ = xcb_ret
  15412. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  15413. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fsrc_drawable = src_drawable
  15414. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fdst_drawable = dst_drawable
  15415. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fgc = gc
  15416. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fsrc_x = src_x
  15417. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fsrc_y = src_y
  15418. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fdst_x = dst_x
  15419. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fdst_y = dst_y
  15420. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fwidth = width
  15421. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fheight = height
  15422. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  15423. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(28)
  15424. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15425. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15426. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req132)))
  15427. return xcb_ret
  15428. }
  15429. var _xcb_req132 = Txcb_protocol_request_t{
  15430. Fcount: uint64(2),
  15431. Fopcode: uint8(m_XCB_COPY_AREA),
  15432. Fisvoid: uint8(1),
  15433. }
  15434. func Xxcb_copy_area(tls *libc.TLS, c uintptr, src_drawable Txcb_drawable_t, dst_drawable Txcb_drawable_t, gc Txcb_gcontext_t, src_x Tint16_t, src_y Tint16_t, dst_x Tint16_t, dst_y Tint16_t, width Tuint16_t, height Tuint16_t) (r Txcb_void_cookie_t) {
  15435. bp := tls.Alloc(96)
  15436. defer tls.Free(96)
  15437. var xcb_ret Txcb_void_cookie_t
  15438. var _ /* xcb_out at bp+64 */ Txcb_copy_area_request_t
  15439. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  15440. _ = xcb_ret
  15441. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  15442. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fsrc_drawable = src_drawable
  15443. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fdst_drawable = dst_drawable
  15444. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fgc = gc
  15445. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fsrc_x = src_x
  15446. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fsrc_y = src_y
  15447. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fdst_x = dst_x
  15448. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fdst_y = dst_y
  15449. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fwidth = width
  15450. (*(*Txcb_copy_area_request_t)(unsafe.Pointer(bp + 64))).Fheight = height
  15451. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  15452. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(28)
  15453. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15454. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15455. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req133)))
  15456. return xcb_ret
  15457. }
  15458. var _xcb_req133 = Txcb_protocol_request_t{
  15459. Fcount: uint64(2),
  15460. Fopcode: uint8(m_XCB_COPY_AREA),
  15461. Fisvoid: uint8(1),
  15462. }
  15463. func Xxcb_copy_plane_checked(tls *libc.TLS, c uintptr, src_drawable Txcb_drawable_t, dst_drawable Txcb_drawable_t, gc Txcb_gcontext_t, src_x Tint16_t, src_y Tint16_t, dst_x Tint16_t, dst_y Tint16_t, width Tuint16_t, height Tuint16_t, bit_plane Tuint32_t) (r Txcb_void_cookie_t) {
  15464. bp := tls.Alloc(96)
  15465. defer tls.Free(96)
  15466. var xcb_ret Txcb_void_cookie_t
  15467. var _ /* xcb_out at bp+64 */ Txcb_copy_plane_request_t
  15468. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  15469. _ = xcb_ret
  15470. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  15471. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fsrc_drawable = src_drawable
  15472. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fdst_drawable = dst_drawable
  15473. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fgc = gc
  15474. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fsrc_x = src_x
  15475. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fsrc_y = src_y
  15476. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fdst_x = dst_x
  15477. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fdst_y = dst_y
  15478. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fwidth = width
  15479. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fheight = height
  15480. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fbit_plane = bit_plane
  15481. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  15482. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(32)
  15483. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15484. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15485. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req134)))
  15486. return xcb_ret
  15487. }
  15488. var _xcb_req134 = Txcb_protocol_request_t{
  15489. Fcount: uint64(2),
  15490. Fopcode: uint8(m_XCB_COPY_PLANE),
  15491. Fisvoid: uint8(1),
  15492. }
  15493. func Xxcb_copy_plane(tls *libc.TLS, c uintptr, src_drawable Txcb_drawable_t, dst_drawable Txcb_drawable_t, gc Txcb_gcontext_t, src_x Tint16_t, src_y Tint16_t, dst_x Tint16_t, dst_y Tint16_t, width Tuint16_t, height Tuint16_t, bit_plane Tuint32_t) (r Txcb_void_cookie_t) {
  15494. bp := tls.Alloc(96)
  15495. defer tls.Free(96)
  15496. var xcb_ret Txcb_void_cookie_t
  15497. var _ /* xcb_out at bp+64 */ Txcb_copy_plane_request_t
  15498. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  15499. _ = xcb_ret
  15500. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  15501. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fsrc_drawable = src_drawable
  15502. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fdst_drawable = dst_drawable
  15503. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fgc = gc
  15504. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fsrc_x = src_x
  15505. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fsrc_y = src_y
  15506. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fdst_x = dst_x
  15507. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fdst_y = dst_y
  15508. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fwidth = width
  15509. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fheight = height
  15510. (*(*Txcb_copy_plane_request_t)(unsafe.Pointer(bp + 64))).Fbit_plane = bit_plane
  15511. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  15512. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(32)
  15513. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15514. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15515. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req135)))
  15516. return xcb_ret
  15517. }
  15518. var _xcb_req135 = Txcb_protocol_request_t{
  15519. Fcount: uint64(2),
  15520. Fopcode: uint8(m_XCB_COPY_PLANE),
  15521. Fisvoid: uint8(1),
  15522. }
  15523. func Xxcb_poly_point_sizeof(tls *libc.TLS, _buffer uintptr, points_len Tuint32_t) (r int32) {
  15524. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  15525. var xcb_tmp uintptr
  15526. _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  15527. xcb_tmp = _buffer
  15528. xcb_buffer_len = uint32(0)
  15529. xcb_block_len = uint32(0)
  15530. xcb_pad = uint32(0)
  15531. xcb_align_to = uint32(0)
  15532. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  15533. xcb_tmp += uintptr(xcb_block_len)
  15534. xcb_buffer_len += xcb_block_len
  15535. xcb_block_len = uint32(0)
  15536. /* points */
  15537. xcb_block_len = uint32(uint64(xcb_block_len) + uint64(points_len)*libc.Uint64FromInt64(4))
  15538. xcb_tmp += uintptr(xcb_block_len)
  15539. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 2))
  15540. /* insert padding */
  15541. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  15542. xcb_buffer_len += xcb_block_len + xcb_pad
  15543. if uint32(0) != xcb_pad {
  15544. xcb_tmp += uintptr(xcb_pad)
  15545. xcb_pad = uint32(0)
  15546. }
  15547. xcb_block_len = uint32(0)
  15548. return libc.Int32FromUint32(xcb_buffer_len)
  15549. }
  15550. func Xxcb_poly_point_checked(tls *libc.TLS, c uintptr, coordinate_mode Tuint8_t, drawable Txcb_drawable_t, gc Txcb_gcontext_t, points_len Tuint32_t, points uintptr) (r Txcb_void_cookie_t) {
  15551. bp := tls.Alloc(112)
  15552. defer tls.Free(112)
  15553. var xcb_ret Txcb_void_cookie_t
  15554. var _ /* xcb_out at bp+96 */ Txcb_poly_point_request_t
  15555. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  15556. _ = xcb_ret
  15557. (*(*Txcb_poly_point_request_t)(unsafe.Pointer(bp + 96))).Fcoordinate_mode = coordinate_mode
  15558. (*(*Txcb_poly_point_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  15559. (*(*Txcb_poly_point_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  15560. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  15561. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  15562. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15563. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15564. /* xcb_point_t points */
  15565. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = points
  15566. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(points_len) * uint64(4)
  15567. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  15568. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  15569. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req136)))
  15570. return xcb_ret
  15571. }
  15572. var _xcb_req136 = Txcb_protocol_request_t{
  15573. Fcount: uint64(4),
  15574. Fopcode: uint8(m_XCB_POLY_POINT),
  15575. Fisvoid: uint8(1),
  15576. }
  15577. func Xxcb_poly_point(tls *libc.TLS, c uintptr, coordinate_mode Tuint8_t, drawable Txcb_drawable_t, gc Txcb_gcontext_t, points_len Tuint32_t, points uintptr) (r Txcb_void_cookie_t) {
  15578. bp := tls.Alloc(112)
  15579. defer tls.Free(112)
  15580. var xcb_ret Txcb_void_cookie_t
  15581. var _ /* xcb_out at bp+96 */ Txcb_poly_point_request_t
  15582. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  15583. _ = xcb_ret
  15584. (*(*Txcb_poly_point_request_t)(unsafe.Pointer(bp + 96))).Fcoordinate_mode = coordinate_mode
  15585. (*(*Txcb_poly_point_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  15586. (*(*Txcb_poly_point_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  15587. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  15588. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  15589. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15590. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15591. /* xcb_point_t points */
  15592. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = points
  15593. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(points_len) * uint64(4)
  15594. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  15595. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  15596. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req137)))
  15597. return xcb_ret
  15598. }
  15599. var _xcb_req137 = Txcb_protocol_request_t{
  15600. Fcount: uint64(4),
  15601. Fopcode: uint8(m_XCB_POLY_POINT),
  15602. Fisvoid: uint8(1),
  15603. }
  15604. func Xxcb_poly_point_points(tls *libc.TLS, R uintptr) (r uintptr) {
  15605. return R + libc.UintptrFromInt32(1)*12
  15606. }
  15607. func Xxcb_poly_point_points_length(tls *libc.TLS, R uintptr) (r int32) {
  15608. return libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_point_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(12)) / libc.Uint64FromInt64(4))
  15609. }
  15610. func Xxcb_poly_point_points_iterator(tls *libc.TLS, R uintptr) (r Txcb_point_iterator_t) {
  15611. var i Txcb_point_iterator_t
  15612. _ = i
  15613. i.Fdata = R + libc.UintptrFromInt32(1)*12
  15614. i.Frem = libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_point_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(12)) / libc.Uint64FromInt64(4))
  15615. i.Findex = int32(int64(i.Fdata) - int64(R))
  15616. return i
  15617. }
  15618. func Xxcb_poly_line_sizeof(tls *libc.TLS, _buffer uintptr, points_len Tuint32_t) (r int32) {
  15619. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  15620. var xcb_tmp uintptr
  15621. _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  15622. xcb_tmp = _buffer
  15623. xcb_buffer_len = uint32(0)
  15624. xcb_block_len = uint32(0)
  15625. xcb_pad = uint32(0)
  15626. xcb_align_to = uint32(0)
  15627. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  15628. xcb_tmp += uintptr(xcb_block_len)
  15629. xcb_buffer_len += xcb_block_len
  15630. xcb_block_len = uint32(0)
  15631. /* points */
  15632. xcb_block_len = uint32(uint64(xcb_block_len) + uint64(points_len)*libc.Uint64FromInt64(4))
  15633. xcb_tmp += uintptr(xcb_block_len)
  15634. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 2))
  15635. /* insert padding */
  15636. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  15637. xcb_buffer_len += xcb_block_len + xcb_pad
  15638. if uint32(0) != xcb_pad {
  15639. xcb_tmp += uintptr(xcb_pad)
  15640. xcb_pad = uint32(0)
  15641. }
  15642. xcb_block_len = uint32(0)
  15643. return libc.Int32FromUint32(xcb_buffer_len)
  15644. }
  15645. func Xxcb_poly_line_checked(tls *libc.TLS, c uintptr, coordinate_mode Tuint8_t, drawable Txcb_drawable_t, gc Txcb_gcontext_t, points_len Tuint32_t, points uintptr) (r Txcb_void_cookie_t) {
  15646. bp := tls.Alloc(112)
  15647. defer tls.Free(112)
  15648. var xcb_ret Txcb_void_cookie_t
  15649. var _ /* xcb_out at bp+96 */ Txcb_poly_line_request_t
  15650. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  15651. _ = xcb_ret
  15652. (*(*Txcb_poly_line_request_t)(unsafe.Pointer(bp + 96))).Fcoordinate_mode = coordinate_mode
  15653. (*(*Txcb_poly_line_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  15654. (*(*Txcb_poly_line_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  15655. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  15656. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  15657. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15658. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15659. /* xcb_point_t points */
  15660. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = points
  15661. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(points_len) * uint64(4)
  15662. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  15663. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  15664. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req138)))
  15665. return xcb_ret
  15666. }
  15667. var _xcb_req138 = Txcb_protocol_request_t{
  15668. Fcount: uint64(4),
  15669. Fopcode: uint8(m_XCB_POLY_LINE),
  15670. Fisvoid: uint8(1),
  15671. }
  15672. func Xxcb_poly_line(tls *libc.TLS, c uintptr, coordinate_mode Tuint8_t, drawable Txcb_drawable_t, gc Txcb_gcontext_t, points_len Tuint32_t, points uintptr) (r Txcb_void_cookie_t) {
  15673. bp := tls.Alloc(112)
  15674. defer tls.Free(112)
  15675. var xcb_ret Txcb_void_cookie_t
  15676. var _ /* xcb_out at bp+96 */ Txcb_poly_line_request_t
  15677. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  15678. _ = xcb_ret
  15679. (*(*Txcb_poly_line_request_t)(unsafe.Pointer(bp + 96))).Fcoordinate_mode = coordinate_mode
  15680. (*(*Txcb_poly_line_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  15681. (*(*Txcb_poly_line_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  15682. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  15683. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  15684. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15685. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15686. /* xcb_point_t points */
  15687. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = points
  15688. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(points_len) * uint64(4)
  15689. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  15690. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  15691. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req139)))
  15692. return xcb_ret
  15693. }
  15694. var _xcb_req139 = Txcb_protocol_request_t{
  15695. Fcount: uint64(4),
  15696. Fopcode: uint8(m_XCB_POLY_LINE),
  15697. Fisvoid: uint8(1),
  15698. }
  15699. func Xxcb_poly_line_points(tls *libc.TLS, R uintptr) (r uintptr) {
  15700. return R + libc.UintptrFromInt32(1)*12
  15701. }
  15702. func Xxcb_poly_line_points_length(tls *libc.TLS, R uintptr) (r int32) {
  15703. return libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_line_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(12)) / libc.Uint64FromInt64(4))
  15704. }
  15705. func Xxcb_poly_line_points_iterator(tls *libc.TLS, R uintptr) (r Txcb_point_iterator_t) {
  15706. var i Txcb_point_iterator_t
  15707. _ = i
  15708. i.Fdata = R + libc.UintptrFromInt32(1)*12
  15709. i.Frem = libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_line_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(12)) / libc.Uint64FromInt64(4))
  15710. i.Findex = int32(int64(i.Fdata) - int64(R))
  15711. return i
  15712. }
  15713. func Xxcb_segment_next(tls *libc.TLS, i uintptr) {
  15714. var p1 uintptr
  15715. _ = p1
  15716. (*Txcb_segment_iterator_t)(unsafe.Pointer(i)).Frem--
  15717. (*Txcb_segment_iterator_t)(unsafe.Pointer(i)).Fdata += 8
  15718. p1 = i + 12
  15719. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(8))
  15720. }
  15721. func Xxcb_segment_end(tls *libc.TLS, i Txcb_segment_iterator_t) (r Txcb_generic_iterator_t) {
  15722. var ret Txcb_generic_iterator_t
  15723. _ = ret
  15724. ret.Fdata = i.Fdata + uintptr(i.Frem)*8
  15725. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  15726. ret.Frem = 0
  15727. return ret
  15728. }
  15729. func Xxcb_poly_segment_sizeof(tls *libc.TLS, _buffer uintptr, segments_len Tuint32_t) (r int32) {
  15730. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  15731. var xcb_tmp uintptr
  15732. _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  15733. xcb_tmp = _buffer
  15734. xcb_buffer_len = uint32(0)
  15735. xcb_block_len = uint32(0)
  15736. xcb_pad = uint32(0)
  15737. xcb_align_to = uint32(0)
  15738. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  15739. xcb_tmp += uintptr(xcb_block_len)
  15740. xcb_buffer_len += xcb_block_len
  15741. xcb_block_len = uint32(0)
  15742. /* segments */
  15743. xcb_block_len = uint32(uint64(xcb_block_len) + uint64(segments_len)*libc.Uint64FromInt64(8))
  15744. xcb_tmp += uintptr(xcb_block_len)
  15745. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 2))
  15746. /* insert padding */
  15747. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  15748. xcb_buffer_len += xcb_block_len + xcb_pad
  15749. if uint32(0) != xcb_pad {
  15750. xcb_tmp += uintptr(xcb_pad)
  15751. xcb_pad = uint32(0)
  15752. }
  15753. xcb_block_len = uint32(0)
  15754. return libc.Int32FromUint32(xcb_buffer_len)
  15755. }
  15756. func Xxcb_poly_segment_checked(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t, gc Txcb_gcontext_t, segments_len Tuint32_t, segments uintptr) (r Txcb_void_cookie_t) {
  15757. bp := tls.Alloc(112)
  15758. defer tls.Free(112)
  15759. var xcb_ret Txcb_void_cookie_t
  15760. var _ /* xcb_out at bp+96 */ Txcb_poly_segment_request_t
  15761. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  15762. _ = xcb_ret
  15763. (*(*Txcb_poly_segment_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  15764. (*(*Txcb_poly_segment_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  15765. (*(*Txcb_poly_segment_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  15766. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  15767. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  15768. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15769. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15770. /* xcb_segment_t segments */
  15771. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = segments
  15772. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(segments_len) * uint64(8)
  15773. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  15774. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  15775. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req140)))
  15776. return xcb_ret
  15777. }
  15778. var _xcb_req140 = Txcb_protocol_request_t{
  15779. Fcount: uint64(4),
  15780. Fopcode: uint8(m_XCB_POLY_SEGMENT),
  15781. Fisvoid: uint8(1),
  15782. }
  15783. func Xxcb_poly_segment(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t, gc Txcb_gcontext_t, segments_len Tuint32_t, segments uintptr) (r Txcb_void_cookie_t) {
  15784. bp := tls.Alloc(112)
  15785. defer tls.Free(112)
  15786. var xcb_ret Txcb_void_cookie_t
  15787. var _ /* xcb_out at bp+96 */ Txcb_poly_segment_request_t
  15788. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  15789. _ = xcb_ret
  15790. (*(*Txcb_poly_segment_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  15791. (*(*Txcb_poly_segment_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  15792. (*(*Txcb_poly_segment_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  15793. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  15794. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  15795. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15796. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15797. /* xcb_segment_t segments */
  15798. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = segments
  15799. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(segments_len) * uint64(8)
  15800. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  15801. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  15802. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req141)))
  15803. return xcb_ret
  15804. }
  15805. var _xcb_req141 = Txcb_protocol_request_t{
  15806. Fcount: uint64(4),
  15807. Fopcode: uint8(m_XCB_POLY_SEGMENT),
  15808. Fisvoid: uint8(1),
  15809. }
  15810. func Xxcb_poly_segment_segments(tls *libc.TLS, R uintptr) (r uintptr) {
  15811. return R + libc.UintptrFromInt32(1)*12
  15812. }
  15813. func Xxcb_poly_segment_segments_length(tls *libc.TLS, R uintptr) (r int32) {
  15814. return libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_segment_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(12)) / libc.Uint64FromInt64(8))
  15815. }
  15816. func Xxcb_poly_segment_segments_iterator(tls *libc.TLS, R uintptr) (r Txcb_segment_iterator_t) {
  15817. var i Txcb_segment_iterator_t
  15818. _ = i
  15819. i.Fdata = R + libc.UintptrFromInt32(1)*12
  15820. i.Frem = libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_segment_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(12)) / libc.Uint64FromInt64(8))
  15821. i.Findex = int32(int64(i.Fdata) - int64(R))
  15822. return i
  15823. }
  15824. func Xxcb_poly_rectangle_sizeof(tls *libc.TLS, _buffer uintptr, rectangles_len Tuint32_t) (r int32) {
  15825. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  15826. var xcb_tmp uintptr
  15827. _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  15828. xcb_tmp = _buffer
  15829. xcb_buffer_len = uint32(0)
  15830. xcb_block_len = uint32(0)
  15831. xcb_pad = uint32(0)
  15832. xcb_align_to = uint32(0)
  15833. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  15834. xcb_tmp += uintptr(xcb_block_len)
  15835. xcb_buffer_len += xcb_block_len
  15836. xcb_block_len = uint32(0)
  15837. /* rectangles */
  15838. xcb_block_len = uint32(uint64(xcb_block_len) + uint64(rectangles_len)*libc.Uint64FromInt64(8))
  15839. xcb_tmp += uintptr(xcb_block_len)
  15840. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 2))
  15841. /* insert padding */
  15842. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  15843. xcb_buffer_len += xcb_block_len + xcb_pad
  15844. if uint32(0) != xcb_pad {
  15845. xcb_tmp += uintptr(xcb_pad)
  15846. xcb_pad = uint32(0)
  15847. }
  15848. xcb_block_len = uint32(0)
  15849. return libc.Int32FromUint32(xcb_buffer_len)
  15850. }
  15851. func Xxcb_poly_rectangle_checked(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t, gc Txcb_gcontext_t, rectangles_len Tuint32_t, rectangles uintptr) (r Txcb_void_cookie_t) {
  15852. bp := tls.Alloc(112)
  15853. defer tls.Free(112)
  15854. var xcb_ret Txcb_void_cookie_t
  15855. var _ /* xcb_out at bp+96 */ Txcb_poly_rectangle_request_t
  15856. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  15857. _ = xcb_ret
  15858. (*(*Txcb_poly_rectangle_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  15859. (*(*Txcb_poly_rectangle_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  15860. (*(*Txcb_poly_rectangle_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  15861. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  15862. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  15863. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15864. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15865. /* xcb_rectangle_t rectangles */
  15866. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = rectangles
  15867. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(rectangles_len) * uint64(8)
  15868. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  15869. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  15870. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req142)))
  15871. return xcb_ret
  15872. }
  15873. var _xcb_req142 = Txcb_protocol_request_t{
  15874. Fcount: uint64(4),
  15875. Fopcode: uint8(m_XCB_POLY_RECTANGLE),
  15876. Fisvoid: uint8(1),
  15877. }
  15878. func Xxcb_poly_rectangle(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t, gc Txcb_gcontext_t, rectangles_len Tuint32_t, rectangles uintptr) (r Txcb_void_cookie_t) {
  15879. bp := tls.Alloc(112)
  15880. defer tls.Free(112)
  15881. var xcb_ret Txcb_void_cookie_t
  15882. var _ /* xcb_out at bp+96 */ Txcb_poly_rectangle_request_t
  15883. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  15884. _ = xcb_ret
  15885. (*(*Txcb_poly_rectangle_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  15886. (*(*Txcb_poly_rectangle_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  15887. (*(*Txcb_poly_rectangle_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  15888. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  15889. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  15890. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15891. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15892. /* xcb_rectangle_t rectangles */
  15893. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = rectangles
  15894. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(rectangles_len) * uint64(8)
  15895. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  15896. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  15897. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req143)))
  15898. return xcb_ret
  15899. }
  15900. var _xcb_req143 = Txcb_protocol_request_t{
  15901. Fcount: uint64(4),
  15902. Fopcode: uint8(m_XCB_POLY_RECTANGLE),
  15903. Fisvoid: uint8(1),
  15904. }
  15905. func Xxcb_poly_rectangle_rectangles(tls *libc.TLS, R uintptr) (r uintptr) {
  15906. return R + libc.UintptrFromInt32(1)*12
  15907. }
  15908. func Xxcb_poly_rectangle_rectangles_length(tls *libc.TLS, R uintptr) (r int32) {
  15909. return libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_rectangle_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(12)) / libc.Uint64FromInt64(8))
  15910. }
  15911. func Xxcb_poly_rectangle_rectangles_iterator(tls *libc.TLS, R uintptr) (r Txcb_rectangle_iterator_t) {
  15912. var i Txcb_rectangle_iterator_t
  15913. _ = i
  15914. i.Fdata = R + libc.UintptrFromInt32(1)*12
  15915. i.Frem = libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_rectangle_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(12)) / libc.Uint64FromInt64(8))
  15916. i.Findex = int32(int64(i.Fdata) - int64(R))
  15917. return i
  15918. }
  15919. func Xxcb_poly_arc_sizeof(tls *libc.TLS, _buffer uintptr, arcs_len Tuint32_t) (r int32) {
  15920. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  15921. var xcb_tmp uintptr
  15922. _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  15923. xcb_tmp = _buffer
  15924. xcb_buffer_len = uint32(0)
  15925. xcb_block_len = uint32(0)
  15926. xcb_pad = uint32(0)
  15927. xcb_align_to = uint32(0)
  15928. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  15929. xcb_tmp += uintptr(xcb_block_len)
  15930. xcb_buffer_len += xcb_block_len
  15931. xcb_block_len = uint32(0)
  15932. /* arcs */
  15933. xcb_block_len = uint32(uint64(xcb_block_len) + uint64(arcs_len)*libc.Uint64FromInt64(12))
  15934. xcb_tmp += uintptr(xcb_block_len)
  15935. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 2))
  15936. /* insert padding */
  15937. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  15938. xcb_buffer_len += xcb_block_len + xcb_pad
  15939. if uint32(0) != xcb_pad {
  15940. xcb_tmp += uintptr(xcb_pad)
  15941. xcb_pad = uint32(0)
  15942. }
  15943. xcb_block_len = uint32(0)
  15944. return libc.Int32FromUint32(xcb_buffer_len)
  15945. }
  15946. func Xxcb_poly_arc_checked(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t, gc Txcb_gcontext_t, arcs_len Tuint32_t, arcs uintptr) (r Txcb_void_cookie_t) {
  15947. bp := tls.Alloc(112)
  15948. defer tls.Free(112)
  15949. var xcb_ret Txcb_void_cookie_t
  15950. var _ /* xcb_out at bp+96 */ Txcb_poly_arc_request_t
  15951. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  15952. _ = xcb_ret
  15953. (*(*Txcb_poly_arc_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  15954. (*(*Txcb_poly_arc_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  15955. (*(*Txcb_poly_arc_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  15956. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  15957. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  15958. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15959. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15960. /* xcb_arc_t arcs */
  15961. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = arcs
  15962. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(arcs_len) * uint64(12)
  15963. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  15964. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  15965. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req144)))
  15966. return xcb_ret
  15967. }
  15968. var _xcb_req144 = Txcb_protocol_request_t{
  15969. Fcount: uint64(4),
  15970. Fopcode: uint8(m_XCB_POLY_ARC),
  15971. Fisvoid: uint8(1),
  15972. }
  15973. func Xxcb_poly_arc(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t, gc Txcb_gcontext_t, arcs_len Tuint32_t, arcs uintptr) (r Txcb_void_cookie_t) {
  15974. bp := tls.Alloc(112)
  15975. defer tls.Free(112)
  15976. var xcb_ret Txcb_void_cookie_t
  15977. var _ /* xcb_out at bp+96 */ Txcb_poly_arc_request_t
  15978. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  15979. _ = xcb_ret
  15980. (*(*Txcb_poly_arc_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  15981. (*(*Txcb_poly_arc_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  15982. (*(*Txcb_poly_arc_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  15983. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  15984. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  15985. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  15986. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  15987. /* xcb_arc_t arcs */
  15988. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = arcs
  15989. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(arcs_len) * uint64(12)
  15990. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  15991. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  15992. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req145)))
  15993. return xcb_ret
  15994. }
  15995. var _xcb_req145 = Txcb_protocol_request_t{
  15996. Fcount: uint64(4),
  15997. Fopcode: uint8(m_XCB_POLY_ARC),
  15998. Fisvoid: uint8(1),
  15999. }
  16000. func Xxcb_poly_arc_arcs(tls *libc.TLS, R uintptr) (r uintptr) {
  16001. return R + libc.UintptrFromInt32(1)*12
  16002. }
  16003. func Xxcb_poly_arc_arcs_length(tls *libc.TLS, R uintptr) (r int32) {
  16004. return libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_arc_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(12)) / libc.Uint64FromInt64(12))
  16005. }
  16006. func Xxcb_poly_arc_arcs_iterator(tls *libc.TLS, R uintptr) (r Txcb_arc_iterator_t) {
  16007. var i Txcb_arc_iterator_t
  16008. _ = i
  16009. i.Fdata = R + libc.UintptrFromInt32(1)*12
  16010. i.Frem = libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_arc_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(12)) / libc.Uint64FromInt64(12))
  16011. i.Findex = int32(int64(i.Fdata) - int64(R))
  16012. return i
  16013. }
  16014. func Xxcb_fill_poly_sizeof(tls *libc.TLS, _buffer uintptr, points_len Tuint32_t) (r int32) {
  16015. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  16016. var xcb_tmp uintptr
  16017. _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  16018. xcb_tmp = _buffer
  16019. xcb_buffer_len = uint32(0)
  16020. xcb_block_len = uint32(0)
  16021. xcb_pad = uint32(0)
  16022. xcb_align_to = uint32(0)
  16023. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(16))
  16024. xcb_tmp += uintptr(xcb_block_len)
  16025. xcb_buffer_len += xcb_block_len
  16026. xcb_block_len = uint32(0)
  16027. /* points */
  16028. xcb_block_len = uint32(uint64(xcb_block_len) + uint64(points_len)*libc.Uint64FromInt64(4))
  16029. xcb_tmp += uintptr(xcb_block_len)
  16030. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 2))
  16031. /* insert padding */
  16032. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  16033. xcb_buffer_len += xcb_block_len + xcb_pad
  16034. if uint32(0) != xcb_pad {
  16035. xcb_tmp += uintptr(xcb_pad)
  16036. xcb_pad = uint32(0)
  16037. }
  16038. xcb_block_len = uint32(0)
  16039. return libc.Int32FromUint32(xcb_buffer_len)
  16040. }
  16041. func Xxcb_fill_poly_checked(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t, gc Txcb_gcontext_t, shape Tuint8_t, coordinate_mode Tuint8_t, points_len Tuint32_t, points uintptr) (r Txcb_void_cookie_t) {
  16042. bp := tls.Alloc(112)
  16043. defer tls.Free(112)
  16044. var xcb_ret Txcb_void_cookie_t
  16045. var _ /* xcb_out at bp+96 */ Txcb_fill_poly_request_t
  16046. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  16047. _ = xcb_ret
  16048. (*(*Txcb_fill_poly_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  16049. (*(*Txcb_fill_poly_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  16050. (*(*Txcb_fill_poly_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  16051. (*(*Txcb_fill_poly_request_t)(unsafe.Pointer(bp + 96))).Fshape = shape
  16052. (*(*Txcb_fill_poly_request_t)(unsafe.Pointer(bp + 96))).Fcoordinate_mode = coordinate_mode
  16053. libc.Xmemset(tls, bp+96+14, 0, uint64(2))
  16054. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  16055. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  16056. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16057. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16058. /* xcb_point_t points */
  16059. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = points
  16060. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(points_len) * uint64(4)
  16061. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  16062. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  16063. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req146)))
  16064. return xcb_ret
  16065. }
  16066. var _xcb_req146 = Txcb_protocol_request_t{
  16067. Fcount: uint64(4),
  16068. Fopcode: uint8(m_XCB_FILL_POLY),
  16069. Fisvoid: uint8(1),
  16070. }
  16071. func Xxcb_fill_poly(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t, gc Txcb_gcontext_t, shape Tuint8_t, coordinate_mode Tuint8_t, points_len Tuint32_t, points uintptr) (r Txcb_void_cookie_t) {
  16072. bp := tls.Alloc(112)
  16073. defer tls.Free(112)
  16074. var xcb_ret Txcb_void_cookie_t
  16075. var _ /* xcb_out at bp+96 */ Txcb_fill_poly_request_t
  16076. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  16077. _ = xcb_ret
  16078. (*(*Txcb_fill_poly_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  16079. (*(*Txcb_fill_poly_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  16080. (*(*Txcb_fill_poly_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  16081. (*(*Txcb_fill_poly_request_t)(unsafe.Pointer(bp + 96))).Fshape = shape
  16082. (*(*Txcb_fill_poly_request_t)(unsafe.Pointer(bp + 96))).Fcoordinate_mode = coordinate_mode
  16083. libc.Xmemset(tls, bp+96+14, 0, uint64(2))
  16084. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  16085. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  16086. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16087. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16088. /* xcb_point_t points */
  16089. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = points
  16090. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(points_len) * uint64(4)
  16091. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  16092. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  16093. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req147)))
  16094. return xcb_ret
  16095. }
  16096. var _xcb_req147 = Txcb_protocol_request_t{
  16097. Fcount: uint64(4),
  16098. Fopcode: uint8(m_XCB_FILL_POLY),
  16099. Fisvoid: uint8(1),
  16100. }
  16101. func Xxcb_fill_poly_points(tls *libc.TLS, R uintptr) (r uintptr) {
  16102. return R + libc.UintptrFromInt32(1)*16
  16103. }
  16104. func Xxcb_fill_poly_points_length(tls *libc.TLS, R uintptr) (r int32) {
  16105. return libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_fill_poly_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(16)) / libc.Uint64FromInt64(4))
  16106. }
  16107. func Xxcb_fill_poly_points_iterator(tls *libc.TLS, R uintptr) (r Txcb_point_iterator_t) {
  16108. var i Txcb_point_iterator_t
  16109. _ = i
  16110. i.Fdata = R + libc.UintptrFromInt32(1)*16
  16111. i.Frem = libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_fill_poly_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(16)) / libc.Uint64FromInt64(4))
  16112. i.Findex = int32(int64(i.Fdata) - int64(R))
  16113. return i
  16114. }
  16115. func Xxcb_poly_fill_rectangle_sizeof(tls *libc.TLS, _buffer uintptr, rectangles_len Tuint32_t) (r int32) {
  16116. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  16117. var xcb_tmp uintptr
  16118. _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  16119. xcb_tmp = _buffer
  16120. xcb_buffer_len = uint32(0)
  16121. xcb_block_len = uint32(0)
  16122. xcb_pad = uint32(0)
  16123. xcb_align_to = uint32(0)
  16124. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  16125. xcb_tmp += uintptr(xcb_block_len)
  16126. xcb_buffer_len += xcb_block_len
  16127. xcb_block_len = uint32(0)
  16128. /* rectangles */
  16129. xcb_block_len = uint32(uint64(xcb_block_len) + uint64(rectangles_len)*libc.Uint64FromInt64(8))
  16130. xcb_tmp += uintptr(xcb_block_len)
  16131. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 2))
  16132. /* insert padding */
  16133. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  16134. xcb_buffer_len += xcb_block_len + xcb_pad
  16135. if uint32(0) != xcb_pad {
  16136. xcb_tmp += uintptr(xcb_pad)
  16137. xcb_pad = uint32(0)
  16138. }
  16139. xcb_block_len = uint32(0)
  16140. return libc.Int32FromUint32(xcb_buffer_len)
  16141. }
  16142. func Xxcb_poly_fill_rectangle_checked(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t, gc Txcb_gcontext_t, rectangles_len Tuint32_t, rectangles uintptr) (r Txcb_void_cookie_t) {
  16143. bp := tls.Alloc(112)
  16144. defer tls.Free(112)
  16145. var xcb_ret Txcb_void_cookie_t
  16146. var _ /* xcb_out at bp+96 */ Txcb_poly_fill_rectangle_request_t
  16147. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  16148. _ = xcb_ret
  16149. (*(*Txcb_poly_fill_rectangle_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  16150. (*(*Txcb_poly_fill_rectangle_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  16151. (*(*Txcb_poly_fill_rectangle_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  16152. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  16153. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  16154. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16155. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16156. /* xcb_rectangle_t rectangles */
  16157. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = rectangles
  16158. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(rectangles_len) * uint64(8)
  16159. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  16160. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  16161. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req148)))
  16162. return xcb_ret
  16163. }
  16164. var _xcb_req148 = Txcb_protocol_request_t{
  16165. Fcount: uint64(4),
  16166. Fopcode: uint8(m_XCB_POLY_FILL_RECTANGLE),
  16167. Fisvoid: uint8(1),
  16168. }
  16169. func Xxcb_poly_fill_rectangle(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t, gc Txcb_gcontext_t, rectangles_len Tuint32_t, rectangles uintptr) (r Txcb_void_cookie_t) {
  16170. bp := tls.Alloc(112)
  16171. defer tls.Free(112)
  16172. var xcb_ret Txcb_void_cookie_t
  16173. var _ /* xcb_out at bp+96 */ Txcb_poly_fill_rectangle_request_t
  16174. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  16175. _ = xcb_ret
  16176. (*(*Txcb_poly_fill_rectangle_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  16177. (*(*Txcb_poly_fill_rectangle_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  16178. (*(*Txcb_poly_fill_rectangle_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  16179. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  16180. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  16181. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16182. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16183. /* xcb_rectangle_t rectangles */
  16184. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = rectangles
  16185. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(rectangles_len) * uint64(8)
  16186. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  16187. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  16188. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req149)))
  16189. return xcb_ret
  16190. }
  16191. var _xcb_req149 = Txcb_protocol_request_t{
  16192. Fcount: uint64(4),
  16193. Fopcode: uint8(m_XCB_POLY_FILL_RECTANGLE),
  16194. Fisvoid: uint8(1),
  16195. }
  16196. func Xxcb_poly_fill_rectangle_rectangles(tls *libc.TLS, R uintptr) (r uintptr) {
  16197. return R + libc.UintptrFromInt32(1)*12
  16198. }
  16199. func Xxcb_poly_fill_rectangle_rectangles_length(tls *libc.TLS, R uintptr) (r int32) {
  16200. return libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_fill_rectangle_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(12)) / libc.Uint64FromInt64(8))
  16201. }
  16202. func Xxcb_poly_fill_rectangle_rectangles_iterator(tls *libc.TLS, R uintptr) (r Txcb_rectangle_iterator_t) {
  16203. var i Txcb_rectangle_iterator_t
  16204. _ = i
  16205. i.Fdata = R + libc.UintptrFromInt32(1)*12
  16206. i.Frem = libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_fill_rectangle_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(12)) / libc.Uint64FromInt64(8))
  16207. i.Findex = int32(int64(i.Fdata) - int64(R))
  16208. return i
  16209. }
  16210. func Xxcb_poly_fill_arc_sizeof(tls *libc.TLS, _buffer uintptr, arcs_len Tuint32_t) (r int32) {
  16211. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  16212. var xcb_tmp uintptr
  16213. _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  16214. xcb_tmp = _buffer
  16215. xcb_buffer_len = uint32(0)
  16216. xcb_block_len = uint32(0)
  16217. xcb_pad = uint32(0)
  16218. xcb_align_to = uint32(0)
  16219. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  16220. xcb_tmp += uintptr(xcb_block_len)
  16221. xcb_buffer_len += xcb_block_len
  16222. xcb_block_len = uint32(0)
  16223. /* arcs */
  16224. xcb_block_len = uint32(uint64(xcb_block_len) + uint64(arcs_len)*libc.Uint64FromInt64(12))
  16225. xcb_tmp += uintptr(xcb_block_len)
  16226. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 2))
  16227. /* insert padding */
  16228. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  16229. xcb_buffer_len += xcb_block_len + xcb_pad
  16230. if uint32(0) != xcb_pad {
  16231. xcb_tmp += uintptr(xcb_pad)
  16232. xcb_pad = uint32(0)
  16233. }
  16234. xcb_block_len = uint32(0)
  16235. return libc.Int32FromUint32(xcb_buffer_len)
  16236. }
  16237. func Xxcb_poly_fill_arc_checked(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t, gc Txcb_gcontext_t, arcs_len Tuint32_t, arcs uintptr) (r Txcb_void_cookie_t) {
  16238. bp := tls.Alloc(112)
  16239. defer tls.Free(112)
  16240. var xcb_ret Txcb_void_cookie_t
  16241. var _ /* xcb_out at bp+96 */ Txcb_poly_fill_arc_request_t
  16242. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  16243. _ = xcb_ret
  16244. (*(*Txcb_poly_fill_arc_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  16245. (*(*Txcb_poly_fill_arc_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  16246. (*(*Txcb_poly_fill_arc_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  16247. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  16248. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  16249. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16250. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16251. /* xcb_arc_t arcs */
  16252. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = arcs
  16253. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(arcs_len) * uint64(12)
  16254. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  16255. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  16256. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req150)))
  16257. return xcb_ret
  16258. }
  16259. var _xcb_req150 = Txcb_protocol_request_t{
  16260. Fcount: uint64(4),
  16261. Fopcode: uint8(m_XCB_POLY_FILL_ARC),
  16262. Fisvoid: uint8(1),
  16263. }
  16264. func Xxcb_poly_fill_arc(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t, gc Txcb_gcontext_t, arcs_len Tuint32_t, arcs uintptr) (r Txcb_void_cookie_t) {
  16265. bp := tls.Alloc(112)
  16266. defer tls.Free(112)
  16267. var xcb_ret Txcb_void_cookie_t
  16268. var _ /* xcb_out at bp+96 */ Txcb_poly_fill_arc_request_t
  16269. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  16270. _ = xcb_ret
  16271. (*(*Txcb_poly_fill_arc_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  16272. (*(*Txcb_poly_fill_arc_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  16273. (*(*Txcb_poly_fill_arc_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  16274. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  16275. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  16276. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16277. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16278. /* xcb_arc_t arcs */
  16279. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = arcs
  16280. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(arcs_len) * uint64(12)
  16281. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  16282. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  16283. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req151)))
  16284. return xcb_ret
  16285. }
  16286. var _xcb_req151 = Txcb_protocol_request_t{
  16287. Fcount: uint64(4),
  16288. Fopcode: uint8(m_XCB_POLY_FILL_ARC),
  16289. Fisvoid: uint8(1),
  16290. }
  16291. func Xxcb_poly_fill_arc_arcs(tls *libc.TLS, R uintptr) (r uintptr) {
  16292. return R + libc.UintptrFromInt32(1)*12
  16293. }
  16294. func Xxcb_poly_fill_arc_arcs_length(tls *libc.TLS, R uintptr) (r int32) {
  16295. return libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_fill_arc_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(12)) / libc.Uint64FromInt64(12))
  16296. }
  16297. func Xxcb_poly_fill_arc_arcs_iterator(tls *libc.TLS, R uintptr) (r Txcb_arc_iterator_t) {
  16298. var i Txcb_arc_iterator_t
  16299. _ = i
  16300. i.Fdata = R + libc.UintptrFromInt32(1)*12
  16301. i.Frem = libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_fill_arc_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(12)) / libc.Uint64FromInt64(12))
  16302. i.Findex = int32(int64(i.Fdata) - int64(R))
  16303. return i
  16304. }
  16305. func Xxcb_put_image_sizeof(tls *libc.TLS, _buffer uintptr, data_len Tuint32_t) (r int32) {
  16306. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  16307. var xcb_tmp uintptr
  16308. _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  16309. xcb_tmp = _buffer
  16310. xcb_buffer_len = uint32(0)
  16311. xcb_block_len = uint32(0)
  16312. xcb_pad = uint32(0)
  16313. xcb_align_to = uint32(0)
  16314. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(24))
  16315. xcb_tmp += uintptr(xcb_block_len)
  16316. xcb_buffer_len += xcb_block_len
  16317. xcb_block_len = uint32(0)
  16318. /* data */
  16319. xcb_block_len = uint32(uint64(xcb_block_len) + uint64(data_len)*libc.Uint64FromInt64(1))
  16320. xcb_tmp += uintptr(xcb_block_len)
  16321. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  16322. /* insert padding */
  16323. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  16324. xcb_buffer_len += xcb_block_len + xcb_pad
  16325. if uint32(0) != xcb_pad {
  16326. xcb_tmp += uintptr(xcb_pad)
  16327. xcb_pad = uint32(0)
  16328. }
  16329. xcb_block_len = uint32(0)
  16330. return libc.Int32FromUint32(xcb_buffer_len)
  16331. }
  16332. func Xxcb_put_image_checked(tls *libc.TLS, c uintptr, format Tuint8_t, drawable Txcb_drawable_t, gc Txcb_gcontext_t, width Tuint16_t, height Tuint16_t, dst_x Tint16_t, dst_y Tint16_t, left_pad Tuint8_t, depth Tuint8_t, data_len Tuint32_t, data uintptr) (r Txcb_void_cookie_t) {
  16333. bp := tls.Alloc(128)
  16334. defer tls.Free(128)
  16335. var xcb_ret Txcb_void_cookie_t
  16336. var _ /* xcb_out at bp+96 */ Txcb_put_image_request_t
  16337. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  16338. _ = xcb_ret
  16339. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fformat = format
  16340. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  16341. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  16342. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fwidth = width
  16343. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fheight = height
  16344. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fdst_x = dst_x
  16345. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fdst_y = dst_y
  16346. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fleft_pad = left_pad
  16347. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fdepth = depth
  16348. libc.Xmemset(tls, bp+96+22, 0, uint64(2))
  16349. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  16350. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(24)
  16351. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16352. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16353. /* uint8_t data */
  16354. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = data
  16355. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(data_len) * uint64(1)
  16356. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  16357. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  16358. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req152)))
  16359. return xcb_ret
  16360. }
  16361. var _xcb_req152 = Txcb_protocol_request_t{
  16362. Fcount: uint64(4),
  16363. Fopcode: uint8(m_XCB_PUT_IMAGE),
  16364. Fisvoid: uint8(1),
  16365. }
  16366. func Xxcb_put_image(tls *libc.TLS, c uintptr, format Tuint8_t, drawable Txcb_drawable_t, gc Txcb_gcontext_t, width Tuint16_t, height Tuint16_t, dst_x Tint16_t, dst_y Tint16_t, left_pad Tuint8_t, depth Tuint8_t, data_len Tuint32_t, data uintptr) (r Txcb_void_cookie_t) {
  16367. bp := tls.Alloc(128)
  16368. defer tls.Free(128)
  16369. var xcb_ret Txcb_void_cookie_t
  16370. var _ /* xcb_out at bp+96 */ Txcb_put_image_request_t
  16371. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  16372. _ = xcb_ret
  16373. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fformat = format
  16374. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  16375. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  16376. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fwidth = width
  16377. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fheight = height
  16378. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fdst_x = dst_x
  16379. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fdst_y = dst_y
  16380. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fleft_pad = left_pad
  16381. (*(*Txcb_put_image_request_t)(unsafe.Pointer(bp + 96))).Fdepth = depth
  16382. libc.Xmemset(tls, bp+96+22, 0, uint64(2))
  16383. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  16384. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(24)
  16385. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16386. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16387. /* uint8_t data */
  16388. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = data
  16389. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(data_len) * uint64(1)
  16390. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  16391. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  16392. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req153)))
  16393. return xcb_ret
  16394. }
  16395. var _xcb_req153 = Txcb_protocol_request_t{
  16396. Fcount: uint64(4),
  16397. Fopcode: uint8(m_XCB_PUT_IMAGE),
  16398. Fisvoid: uint8(1),
  16399. }
  16400. func Xxcb_put_image_data(tls *libc.TLS, R uintptr) (r uintptr) {
  16401. return R + libc.UintptrFromInt32(1)*24
  16402. }
  16403. func Xxcb_put_image_data_length(tls *libc.TLS, R uintptr) (r int32) {
  16404. return libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_put_image_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(24)) / libc.Uint64FromInt64(1))
  16405. }
  16406. func Xxcb_put_image_data_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  16407. var i Txcb_generic_iterator_t
  16408. _ = i
  16409. i.Fdata = R + libc.UintptrFromInt32(1)*24 + uintptr((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_put_image_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4))-libc.Uint64FromInt64(24))/libc.Uint64FromInt64(1))
  16410. i.Frem = 0
  16411. i.Findex = int32(int64(i.Fdata) - int64(R))
  16412. return i
  16413. }
  16414. func Xxcb_get_image_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  16415. var _aux, xcb_tmp uintptr
  16416. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  16417. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  16418. xcb_tmp = _buffer
  16419. _aux = _buffer
  16420. xcb_buffer_len = uint32(0)
  16421. xcb_block_len = uint32(0)
  16422. xcb_pad = uint32(0)
  16423. xcb_align_to = uint32(0)
  16424. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(32))
  16425. xcb_tmp += uintptr(xcb_block_len)
  16426. xcb_buffer_len += xcb_block_len
  16427. xcb_block_len = uint32(0)
  16428. /* data */
  16429. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_get_image_reply_t)(unsafe.Pointer(_aux)).Flength*libc.Uint32FromInt32(4))*libc.Uint64FromInt64(1))
  16430. xcb_tmp += uintptr(xcb_block_len)
  16431. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  16432. /* insert padding */
  16433. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  16434. xcb_buffer_len += xcb_block_len + xcb_pad
  16435. if uint32(0) != xcb_pad {
  16436. xcb_tmp += uintptr(xcb_pad)
  16437. xcb_pad = uint32(0)
  16438. }
  16439. xcb_block_len = uint32(0)
  16440. return libc.Int32FromUint32(xcb_buffer_len)
  16441. }
  16442. func Xxcb_get_image(tls *libc.TLS, c uintptr, format Tuint8_t, drawable Txcb_drawable_t, x Tint16_t, y Tint16_t, width Tuint16_t, height Tuint16_t, plane_mask Tuint32_t) (r Txcb_get_image_cookie_t) {
  16443. bp := tls.Alloc(96)
  16444. defer tls.Free(96)
  16445. var xcb_ret Txcb_get_image_cookie_t
  16446. var _ /* xcb_out at bp+64 */ Txcb_get_image_request_t
  16447. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  16448. _ = xcb_ret
  16449. (*(*Txcb_get_image_request_t)(unsafe.Pointer(bp + 64))).Fformat = format
  16450. (*(*Txcb_get_image_request_t)(unsafe.Pointer(bp + 64))).Fdrawable = drawable
  16451. (*(*Txcb_get_image_request_t)(unsafe.Pointer(bp + 64))).Fx = x
  16452. (*(*Txcb_get_image_request_t)(unsafe.Pointer(bp + 64))).Fy = y
  16453. (*(*Txcb_get_image_request_t)(unsafe.Pointer(bp + 64))).Fwidth = width
  16454. (*(*Txcb_get_image_request_t)(unsafe.Pointer(bp + 64))).Fheight = height
  16455. (*(*Txcb_get_image_request_t)(unsafe.Pointer(bp + 64))).Fplane_mask = plane_mask
  16456. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  16457. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(20)
  16458. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16459. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16460. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req154)))
  16461. return xcb_ret
  16462. }
  16463. var _xcb_req154 = Txcb_protocol_request_t{
  16464. Fcount: uint64(2),
  16465. Fopcode: uint8(m_XCB_GET_IMAGE),
  16466. }
  16467. func Xxcb_get_image_unchecked(tls *libc.TLS, c uintptr, format Tuint8_t, drawable Txcb_drawable_t, x Tint16_t, y Tint16_t, width Tuint16_t, height Tuint16_t, plane_mask Tuint32_t) (r Txcb_get_image_cookie_t) {
  16468. bp := tls.Alloc(96)
  16469. defer tls.Free(96)
  16470. var xcb_ret Txcb_get_image_cookie_t
  16471. var _ /* xcb_out at bp+64 */ Txcb_get_image_request_t
  16472. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  16473. _ = xcb_ret
  16474. (*(*Txcb_get_image_request_t)(unsafe.Pointer(bp + 64))).Fformat = format
  16475. (*(*Txcb_get_image_request_t)(unsafe.Pointer(bp + 64))).Fdrawable = drawable
  16476. (*(*Txcb_get_image_request_t)(unsafe.Pointer(bp + 64))).Fx = x
  16477. (*(*Txcb_get_image_request_t)(unsafe.Pointer(bp + 64))).Fy = y
  16478. (*(*Txcb_get_image_request_t)(unsafe.Pointer(bp + 64))).Fwidth = width
  16479. (*(*Txcb_get_image_request_t)(unsafe.Pointer(bp + 64))).Fheight = height
  16480. (*(*Txcb_get_image_request_t)(unsafe.Pointer(bp + 64))).Fplane_mask = plane_mask
  16481. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  16482. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(20)
  16483. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16484. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16485. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req155)))
  16486. return xcb_ret
  16487. }
  16488. var _xcb_req155 = Txcb_protocol_request_t{
  16489. Fcount: uint64(2),
  16490. Fopcode: uint8(m_XCB_GET_IMAGE),
  16491. }
  16492. func Xxcb_get_image_data(tls *libc.TLS, R uintptr) (r uintptr) {
  16493. return R + libc.UintptrFromInt32(1)*32
  16494. }
  16495. func Xxcb_get_image_data_length(tls *libc.TLS, R uintptr) (r int32) {
  16496. return libc.Int32FromUint32((*Txcb_get_image_reply_t)(unsafe.Pointer(R)).Flength * libc.Uint32FromInt32(4))
  16497. }
  16498. func Xxcb_get_image_data_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  16499. var i Txcb_generic_iterator_t
  16500. _ = i
  16501. i.Fdata = R + libc.UintptrFromInt32(1)*32 + uintptr((*Txcb_get_image_reply_t)(unsafe.Pointer(R)).Flength*libc.Uint32FromInt32(4))
  16502. i.Frem = 0
  16503. i.Findex = int32(int64(i.Fdata) - int64(R))
  16504. return i
  16505. }
  16506. func Xxcb_get_image_reply(tls *libc.TLS, c uintptr, cookie Txcb_get_image_cookie_t, e uintptr) (r uintptr) {
  16507. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  16508. }
  16509. func Xxcb_poly_text_8_sizeof(tls *libc.TLS, _buffer uintptr, items_len Tuint32_t) (r int32) {
  16510. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  16511. var xcb_tmp uintptr
  16512. _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  16513. xcb_tmp = _buffer
  16514. xcb_buffer_len = uint32(0)
  16515. xcb_block_len = uint32(0)
  16516. xcb_pad = uint32(0)
  16517. xcb_align_to = uint32(0)
  16518. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(16))
  16519. xcb_tmp += uintptr(xcb_block_len)
  16520. xcb_buffer_len += xcb_block_len
  16521. xcb_block_len = uint32(0)
  16522. /* items */
  16523. xcb_block_len = uint32(uint64(xcb_block_len) + uint64(items_len)*libc.Uint64FromInt64(1))
  16524. xcb_tmp += uintptr(xcb_block_len)
  16525. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  16526. /* insert padding */
  16527. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  16528. xcb_buffer_len += xcb_block_len + xcb_pad
  16529. if uint32(0) != xcb_pad {
  16530. xcb_tmp += uintptr(xcb_pad)
  16531. xcb_pad = uint32(0)
  16532. }
  16533. xcb_block_len = uint32(0)
  16534. return libc.Int32FromUint32(xcb_buffer_len)
  16535. }
  16536. func Xxcb_poly_text_8_checked(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t, gc Txcb_gcontext_t, x Tint16_t, y Tint16_t, items_len Tuint32_t, items uintptr) (r Txcb_void_cookie_t) {
  16537. bp := tls.Alloc(112)
  16538. defer tls.Free(112)
  16539. var xcb_ret Txcb_void_cookie_t
  16540. var _ /* xcb_out at bp+96 */ Txcb_poly_text_8_request_t
  16541. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  16542. _ = xcb_ret
  16543. (*(*Txcb_poly_text_8_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  16544. (*(*Txcb_poly_text_8_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  16545. (*(*Txcb_poly_text_8_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  16546. (*(*Txcb_poly_text_8_request_t)(unsafe.Pointer(bp + 96))).Fx = x
  16547. (*(*Txcb_poly_text_8_request_t)(unsafe.Pointer(bp + 96))).Fy = y
  16548. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  16549. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  16550. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16551. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16552. /* uint8_t items */
  16553. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = items
  16554. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(items_len) * uint64(1)
  16555. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  16556. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  16557. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req156)))
  16558. return xcb_ret
  16559. }
  16560. var _xcb_req156 = Txcb_protocol_request_t{
  16561. Fcount: uint64(4),
  16562. Fopcode: uint8(m_XCB_POLY_TEXT_8),
  16563. Fisvoid: uint8(1),
  16564. }
  16565. func Xxcb_poly_text_8(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t, gc Txcb_gcontext_t, x Tint16_t, y Tint16_t, items_len Tuint32_t, items uintptr) (r Txcb_void_cookie_t) {
  16566. bp := tls.Alloc(112)
  16567. defer tls.Free(112)
  16568. var xcb_ret Txcb_void_cookie_t
  16569. var _ /* xcb_out at bp+96 */ Txcb_poly_text_8_request_t
  16570. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  16571. _ = xcb_ret
  16572. (*(*Txcb_poly_text_8_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  16573. (*(*Txcb_poly_text_8_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  16574. (*(*Txcb_poly_text_8_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  16575. (*(*Txcb_poly_text_8_request_t)(unsafe.Pointer(bp + 96))).Fx = x
  16576. (*(*Txcb_poly_text_8_request_t)(unsafe.Pointer(bp + 96))).Fy = y
  16577. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  16578. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  16579. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16580. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16581. /* uint8_t items */
  16582. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = items
  16583. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(items_len) * uint64(1)
  16584. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  16585. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  16586. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req157)))
  16587. return xcb_ret
  16588. }
  16589. var _xcb_req157 = Txcb_protocol_request_t{
  16590. Fcount: uint64(4),
  16591. Fopcode: uint8(m_XCB_POLY_TEXT_8),
  16592. Fisvoid: uint8(1),
  16593. }
  16594. func Xxcb_poly_text_8_items(tls *libc.TLS, R uintptr) (r uintptr) {
  16595. return R + libc.UintptrFromInt32(1)*16
  16596. }
  16597. func Xxcb_poly_text_8_items_length(tls *libc.TLS, R uintptr) (r int32) {
  16598. return libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_text_8_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(16)) / libc.Uint64FromInt64(1))
  16599. }
  16600. func Xxcb_poly_text_8_items_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  16601. var i Txcb_generic_iterator_t
  16602. _ = i
  16603. i.Fdata = R + libc.UintptrFromInt32(1)*16 + uintptr((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_text_8_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4))-libc.Uint64FromInt64(16))/libc.Uint64FromInt64(1))
  16604. i.Frem = 0
  16605. i.Findex = int32(int64(i.Fdata) - int64(R))
  16606. return i
  16607. }
  16608. func Xxcb_poly_text_16_sizeof(tls *libc.TLS, _buffer uintptr, items_len Tuint32_t) (r int32) {
  16609. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  16610. var xcb_tmp uintptr
  16611. _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  16612. xcb_tmp = _buffer
  16613. xcb_buffer_len = uint32(0)
  16614. xcb_block_len = uint32(0)
  16615. xcb_pad = uint32(0)
  16616. xcb_align_to = uint32(0)
  16617. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(16))
  16618. xcb_tmp += uintptr(xcb_block_len)
  16619. xcb_buffer_len += xcb_block_len
  16620. xcb_block_len = uint32(0)
  16621. /* items */
  16622. xcb_block_len = uint32(uint64(xcb_block_len) + uint64(items_len)*libc.Uint64FromInt64(1))
  16623. xcb_tmp += uintptr(xcb_block_len)
  16624. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  16625. /* insert padding */
  16626. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  16627. xcb_buffer_len += xcb_block_len + xcb_pad
  16628. if uint32(0) != xcb_pad {
  16629. xcb_tmp += uintptr(xcb_pad)
  16630. xcb_pad = uint32(0)
  16631. }
  16632. xcb_block_len = uint32(0)
  16633. return libc.Int32FromUint32(xcb_buffer_len)
  16634. }
  16635. func Xxcb_poly_text_16_checked(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t, gc Txcb_gcontext_t, x Tint16_t, y Tint16_t, items_len Tuint32_t, items uintptr) (r Txcb_void_cookie_t) {
  16636. bp := tls.Alloc(112)
  16637. defer tls.Free(112)
  16638. var xcb_ret Txcb_void_cookie_t
  16639. var _ /* xcb_out at bp+96 */ Txcb_poly_text_16_request_t
  16640. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  16641. _ = xcb_ret
  16642. (*(*Txcb_poly_text_16_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  16643. (*(*Txcb_poly_text_16_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  16644. (*(*Txcb_poly_text_16_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  16645. (*(*Txcb_poly_text_16_request_t)(unsafe.Pointer(bp + 96))).Fx = x
  16646. (*(*Txcb_poly_text_16_request_t)(unsafe.Pointer(bp + 96))).Fy = y
  16647. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  16648. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  16649. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16650. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16651. /* uint8_t items */
  16652. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = items
  16653. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(items_len) * uint64(1)
  16654. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  16655. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  16656. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req158)))
  16657. return xcb_ret
  16658. }
  16659. var _xcb_req158 = Txcb_protocol_request_t{
  16660. Fcount: uint64(4),
  16661. Fopcode: uint8(m_XCB_POLY_TEXT_16),
  16662. Fisvoid: uint8(1),
  16663. }
  16664. func Xxcb_poly_text_16(tls *libc.TLS, c uintptr, drawable Txcb_drawable_t, gc Txcb_gcontext_t, x Tint16_t, y Tint16_t, items_len Tuint32_t, items uintptr) (r Txcb_void_cookie_t) {
  16665. bp := tls.Alloc(112)
  16666. defer tls.Free(112)
  16667. var xcb_ret Txcb_void_cookie_t
  16668. var _ /* xcb_out at bp+96 */ Txcb_poly_text_16_request_t
  16669. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  16670. _ = xcb_ret
  16671. (*(*Txcb_poly_text_16_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  16672. (*(*Txcb_poly_text_16_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  16673. (*(*Txcb_poly_text_16_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  16674. (*(*Txcb_poly_text_16_request_t)(unsafe.Pointer(bp + 96))).Fx = x
  16675. (*(*Txcb_poly_text_16_request_t)(unsafe.Pointer(bp + 96))).Fy = y
  16676. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  16677. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  16678. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16679. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16680. /* uint8_t items */
  16681. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = items
  16682. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(items_len) * uint64(1)
  16683. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  16684. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  16685. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req159)))
  16686. return xcb_ret
  16687. }
  16688. var _xcb_req159 = Txcb_protocol_request_t{
  16689. Fcount: uint64(4),
  16690. Fopcode: uint8(m_XCB_POLY_TEXT_16),
  16691. Fisvoid: uint8(1),
  16692. }
  16693. func Xxcb_poly_text_16_items(tls *libc.TLS, R uintptr) (r uintptr) {
  16694. return R + libc.UintptrFromInt32(1)*16
  16695. }
  16696. func Xxcb_poly_text_16_items_length(tls *libc.TLS, R uintptr) (r int32) {
  16697. return libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_text_16_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(16)) / libc.Uint64FromInt64(1))
  16698. }
  16699. func Xxcb_poly_text_16_items_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  16700. var i Txcb_generic_iterator_t
  16701. _ = i
  16702. i.Fdata = R + libc.UintptrFromInt32(1)*16 + uintptr((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_poly_text_16_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4))-libc.Uint64FromInt64(16))/libc.Uint64FromInt64(1))
  16703. i.Frem = 0
  16704. i.Findex = int32(int64(i.Fdata) - int64(R))
  16705. return i
  16706. }
  16707. func Xxcb_image_text_8_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  16708. var _aux, xcb_tmp uintptr
  16709. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  16710. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  16711. xcb_tmp = _buffer
  16712. _aux = _buffer
  16713. xcb_buffer_len = uint32(0)
  16714. xcb_block_len = uint32(0)
  16715. xcb_pad = uint32(0)
  16716. xcb_align_to = uint32(0)
  16717. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(16))
  16718. xcb_tmp += uintptr(xcb_block_len)
  16719. xcb_buffer_len += xcb_block_len
  16720. xcb_block_len = uint32(0)
  16721. /* string */
  16722. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_image_text_8_request_t)(unsafe.Pointer(_aux)).Fstring_len)*libc.Uint64FromInt64(1))
  16723. xcb_tmp += uintptr(xcb_block_len)
  16724. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  16725. /* insert padding */
  16726. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  16727. xcb_buffer_len += xcb_block_len + xcb_pad
  16728. if uint32(0) != xcb_pad {
  16729. xcb_tmp += uintptr(xcb_pad)
  16730. xcb_pad = uint32(0)
  16731. }
  16732. xcb_block_len = uint32(0)
  16733. return libc.Int32FromUint32(xcb_buffer_len)
  16734. }
  16735. func Xxcb_image_text_8_checked(tls *libc.TLS, c uintptr, string_len Tuint8_t, drawable Txcb_drawable_t, gc Txcb_gcontext_t, x Tint16_t, y Tint16_t, string1 uintptr) (r Txcb_void_cookie_t) {
  16736. bp := tls.Alloc(112)
  16737. defer tls.Free(112)
  16738. var xcb_ret Txcb_void_cookie_t
  16739. var _ /* xcb_out at bp+96 */ Txcb_image_text_8_request_t
  16740. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  16741. _ = xcb_ret
  16742. (*(*Txcb_image_text_8_request_t)(unsafe.Pointer(bp + 96))).Fstring_len = string_len
  16743. (*(*Txcb_image_text_8_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  16744. (*(*Txcb_image_text_8_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  16745. (*(*Txcb_image_text_8_request_t)(unsafe.Pointer(bp + 96))).Fx = x
  16746. (*(*Txcb_image_text_8_request_t)(unsafe.Pointer(bp + 96))).Fy = y
  16747. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  16748. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  16749. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16750. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16751. /* char string */
  16752. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = string1
  16753. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(string_len) * uint64(1)
  16754. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  16755. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  16756. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req160)))
  16757. return xcb_ret
  16758. }
  16759. var _xcb_req160 = Txcb_protocol_request_t{
  16760. Fcount: uint64(4),
  16761. Fopcode: uint8(m_XCB_IMAGE_TEXT_8),
  16762. Fisvoid: uint8(1),
  16763. }
  16764. func Xxcb_image_text_8(tls *libc.TLS, c uintptr, string_len Tuint8_t, drawable Txcb_drawable_t, gc Txcb_gcontext_t, x Tint16_t, y Tint16_t, string1 uintptr) (r Txcb_void_cookie_t) {
  16765. bp := tls.Alloc(112)
  16766. defer tls.Free(112)
  16767. var xcb_ret Txcb_void_cookie_t
  16768. var _ /* xcb_out at bp+96 */ Txcb_image_text_8_request_t
  16769. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  16770. _ = xcb_ret
  16771. (*(*Txcb_image_text_8_request_t)(unsafe.Pointer(bp + 96))).Fstring_len = string_len
  16772. (*(*Txcb_image_text_8_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  16773. (*(*Txcb_image_text_8_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  16774. (*(*Txcb_image_text_8_request_t)(unsafe.Pointer(bp + 96))).Fx = x
  16775. (*(*Txcb_image_text_8_request_t)(unsafe.Pointer(bp + 96))).Fy = y
  16776. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  16777. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  16778. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16779. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16780. /* char string */
  16781. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = string1
  16782. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(string_len) * uint64(1)
  16783. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  16784. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  16785. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req161)))
  16786. return xcb_ret
  16787. }
  16788. var _xcb_req161 = Txcb_protocol_request_t{
  16789. Fcount: uint64(4),
  16790. Fopcode: uint8(m_XCB_IMAGE_TEXT_8),
  16791. Fisvoid: uint8(1),
  16792. }
  16793. func Xxcb_image_text_8_string(tls *libc.TLS, R uintptr) (r uintptr) {
  16794. return R + libc.UintptrFromInt32(1)*16
  16795. }
  16796. func Xxcb_image_text_8_string_length(tls *libc.TLS, R uintptr) (r int32) {
  16797. return libc.Int32FromUint8((*Txcb_image_text_8_request_t)(unsafe.Pointer(R)).Fstring_len)
  16798. }
  16799. func Xxcb_image_text_8_string_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  16800. var i Txcb_generic_iterator_t
  16801. _ = i
  16802. i.Fdata = R + libc.UintptrFromInt32(1)*16 + uintptr((*Txcb_image_text_8_request_t)(unsafe.Pointer(R)).Fstring_len)
  16803. i.Frem = 0
  16804. i.Findex = int32(int64(i.Fdata) - int64(R))
  16805. return i
  16806. }
  16807. func Xxcb_image_text_16_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  16808. var _aux, xcb_tmp uintptr
  16809. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  16810. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  16811. xcb_tmp = _buffer
  16812. _aux = _buffer
  16813. xcb_buffer_len = uint32(0)
  16814. xcb_block_len = uint32(0)
  16815. xcb_pad = uint32(0)
  16816. xcb_align_to = uint32(0)
  16817. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(16))
  16818. xcb_tmp += uintptr(xcb_block_len)
  16819. xcb_buffer_len += xcb_block_len
  16820. xcb_block_len = uint32(0)
  16821. /* string */
  16822. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_image_text_16_request_t)(unsafe.Pointer(_aux)).Fstring_len)*libc.Uint64FromInt64(2))
  16823. xcb_tmp += uintptr(xcb_block_len)
  16824. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  16825. /* insert padding */
  16826. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  16827. xcb_buffer_len += xcb_block_len + xcb_pad
  16828. if uint32(0) != xcb_pad {
  16829. xcb_tmp += uintptr(xcb_pad)
  16830. xcb_pad = uint32(0)
  16831. }
  16832. xcb_block_len = uint32(0)
  16833. return libc.Int32FromUint32(xcb_buffer_len)
  16834. }
  16835. func Xxcb_image_text_16_checked(tls *libc.TLS, c uintptr, string_len Tuint8_t, drawable Txcb_drawable_t, gc Txcb_gcontext_t, x Tint16_t, y Tint16_t, string1 uintptr) (r Txcb_void_cookie_t) {
  16836. bp := tls.Alloc(112)
  16837. defer tls.Free(112)
  16838. var xcb_ret Txcb_void_cookie_t
  16839. var _ /* xcb_out at bp+96 */ Txcb_image_text_16_request_t
  16840. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  16841. _ = xcb_ret
  16842. (*(*Txcb_image_text_16_request_t)(unsafe.Pointer(bp + 96))).Fstring_len = string_len
  16843. (*(*Txcb_image_text_16_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  16844. (*(*Txcb_image_text_16_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  16845. (*(*Txcb_image_text_16_request_t)(unsafe.Pointer(bp + 96))).Fx = x
  16846. (*(*Txcb_image_text_16_request_t)(unsafe.Pointer(bp + 96))).Fy = y
  16847. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  16848. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  16849. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16850. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16851. /* xcb_char2b_t string */
  16852. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = string1
  16853. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(string_len) * uint64(2)
  16854. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  16855. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  16856. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req162)))
  16857. return xcb_ret
  16858. }
  16859. var _xcb_req162 = Txcb_protocol_request_t{
  16860. Fcount: uint64(4),
  16861. Fopcode: uint8(m_XCB_IMAGE_TEXT_16),
  16862. Fisvoid: uint8(1),
  16863. }
  16864. func Xxcb_image_text_16(tls *libc.TLS, c uintptr, string_len Tuint8_t, drawable Txcb_drawable_t, gc Txcb_gcontext_t, x Tint16_t, y Tint16_t, string1 uintptr) (r Txcb_void_cookie_t) {
  16865. bp := tls.Alloc(112)
  16866. defer tls.Free(112)
  16867. var xcb_ret Txcb_void_cookie_t
  16868. var _ /* xcb_out at bp+96 */ Txcb_image_text_16_request_t
  16869. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  16870. _ = xcb_ret
  16871. (*(*Txcb_image_text_16_request_t)(unsafe.Pointer(bp + 96))).Fstring_len = string_len
  16872. (*(*Txcb_image_text_16_request_t)(unsafe.Pointer(bp + 96))).Fdrawable = drawable
  16873. (*(*Txcb_image_text_16_request_t)(unsafe.Pointer(bp + 96))).Fgc = gc
  16874. (*(*Txcb_image_text_16_request_t)(unsafe.Pointer(bp + 96))).Fx = x
  16875. (*(*Txcb_image_text_16_request_t)(unsafe.Pointer(bp + 96))).Fy = y
  16876. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  16877. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  16878. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16879. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16880. /* xcb_char2b_t string */
  16881. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = string1
  16882. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(string_len) * uint64(2)
  16883. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  16884. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  16885. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req163)))
  16886. return xcb_ret
  16887. }
  16888. var _xcb_req163 = Txcb_protocol_request_t{
  16889. Fcount: uint64(4),
  16890. Fopcode: uint8(m_XCB_IMAGE_TEXT_16),
  16891. Fisvoid: uint8(1),
  16892. }
  16893. func Xxcb_image_text_16_string(tls *libc.TLS, R uintptr) (r uintptr) {
  16894. return R + libc.UintptrFromInt32(1)*16
  16895. }
  16896. func Xxcb_image_text_16_string_length(tls *libc.TLS, R uintptr) (r int32) {
  16897. return libc.Int32FromUint8((*Txcb_image_text_16_request_t)(unsafe.Pointer(R)).Fstring_len)
  16898. }
  16899. func Xxcb_image_text_16_string_iterator(tls *libc.TLS, R uintptr) (r Txcb_char2b_iterator_t) {
  16900. var i Txcb_char2b_iterator_t
  16901. _ = i
  16902. i.Fdata = R + libc.UintptrFromInt32(1)*16
  16903. i.Frem = libc.Int32FromUint8((*Txcb_image_text_16_request_t)(unsafe.Pointer(R)).Fstring_len)
  16904. i.Findex = int32(int64(i.Fdata) - int64(R))
  16905. return i
  16906. }
  16907. func Xxcb_create_colormap_checked(tls *libc.TLS, c uintptr, alloc Tuint8_t, mid Txcb_colormap_t, window Txcb_window_t, visual Txcb_visualid_t) (r Txcb_void_cookie_t) {
  16908. bp := tls.Alloc(80)
  16909. defer tls.Free(80)
  16910. var xcb_ret Txcb_void_cookie_t
  16911. var _ /* xcb_out at bp+64 */ Txcb_create_colormap_request_t
  16912. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  16913. _ = xcb_ret
  16914. (*(*Txcb_create_colormap_request_t)(unsafe.Pointer(bp + 64))).Falloc = alloc
  16915. (*(*Txcb_create_colormap_request_t)(unsafe.Pointer(bp + 64))).Fmid = mid
  16916. (*(*Txcb_create_colormap_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  16917. (*(*Txcb_create_colormap_request_t)(unsafe.Pointer(bp + 64))).Fvisual = visual
  16918. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  16919. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  16920. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16921. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16922. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req164)))
  16923. return xcb_ret
  16924. }
  16925. var _xcb_req164 = Txcb_protocol_request_t{
  16926. Fcount: uint64(2),
  16927. Fopcode: uint8(m_XCB_CREATE_COLORMAP),
  16928. Fisvoid: uint8(1),
  16929. }
  16930. func Xxcb_create_colormap(tls *libc.TLS, c uintptr, alloc Tuint8_t, mid Txcb_colormap_t, window Txcb_window_t, visual Txcb_visualid_t) (r Txcb_void_cookie_t) {
  16931. bp := tls.Alloc(80)
  16932. defer tls.Free(80)
  16933. var xcb_ret Txcb_void_cookie_t
  16934. var _ /* xcb_out at bp+64 */ Txcb_create_colormap_request_t
  16935. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  16936. _ = xcb_ret
  16937. (*(*Txcb_create_colormap_request_t)(unsafe.Pointer(bp + 64))).Falloc = alloc
  16938. (*(*Txcb_create_colormap_request_t)(unsafe.Pointer(bp + 64))).Fmid = mid
  16939. (*(*Txcb_create_colormap_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  16940. (*(*Txcb_create_colormap_request_t)(unsafe.Pointer(bp + 64))).Fvisual = visual
  16941. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  16942. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  16943. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16944. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16945. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req165)))
  16946. return xcb_ret
  16947. }
  16948. var _xcb_req165 = Txcb_protocol_request_t{
  16949. Fcount: uint64(2),
  16950. Fopcode: uint8(m_XCB_CREATE_COLORMAP),
  16951. Fisvoid: uint8(1),
  16952. }
  16953. func Xxcb_free_colormap_checked(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t) (r Txcb_void_cookie_t) {
  16954. bp := tls.Alloc(80)
  16955. defer tls.Free(80)
  16956. var xcb_ret Txcb_void_cookie_t
  16957. var _ /* xcb_out at bp+64 */ Txcb_free_colormap_request_t
  16958. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  16959. _ = xcb_ret
  16960. (*(*Txcb_free_colormap_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  16961. (*(*Txcb_free_colormap_request_t)(unsafe.Pointer(bp + 64))).Fcmap = cmap
  16962. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  16963. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  16964. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16965. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16966. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req166)))
  16967. return xcb_ret
  16968. }
  16969. var _xcb_req166 = Txcb_protocol_request_t{
  16970. Fcount: uint64(2),
  16971. Fopcode: uint8(m_XCB_FREE_COLORMAP),
  16972. Fisvoid: uint8(1),
  16973. }
  16974. func Xxcb_free_colormap(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t) (r Txcb_void_cookie_t) {
  16975. bp := tls.Alloc(80)
  16976. defer tls.Free(80)
  16977. var xcb_ret Txcb_void_cookie_t
  16978. var _ /* xcb_out at bp+64 */ Txcb_free_colormap_request_t
  16979. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  16980. _ = xcb_ret
  16981. (*(*Txcb_free_colormap_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  16982. (*(*Txcb_free_colormap_request_t)(unsafe.Pointer(bp + 64))).Fcmap = cmap
  16983. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  16984. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  16985. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  16986. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  16987. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req167)))
  16988. return xcb_ret
  16989. }
  16990. var _xcb_req167 = Txcb_protocol_request_t{
  16991. Fcount: uint64(2),
  16992. Fopcode: uint8(m_XCB_FREE_COLORMAP),
  16993. Fisvoid: uint8(1),
  16994. }
  16995. func Xxcb_copy_colormap_and_free_checked(tls *libc.TLS, c uintptr, mid Txcb_colormap_t, src_cmap Txcb_colormap_t) (r Txcb_void_cookie_t) {
  16996. bp := tls.Alloc(80)
  16997. defer tls.Free(80)
  16998. var xcb_ret Txcb_void_cookie_t
  16999. var _ /* xcb_out at bp+64 */ Txcb_copy_colormap_and_free_request_t
  17000. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  17001. _ = xcb_ret
  17002. (*(*Txcb_copy_colormap_and_free_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  17003. (*(*Txcb_copy_colormap_and_free_request_t)(unsafe.Pointer(bp + 64))).Fmid = mid
  17004. (*(*Txcb_copy_colormap_and_free_request_t)(unsafe.Pointer(bp + 64))).Fsrc_cmap = src_cmap
  17005. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  17006. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  17007. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17008. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17009. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req168)))
  17010. return xcb_ret
  17011. }
  17012. var _xcb_req168 = Txcb_protocol_request_t{
  17013. Fcount: uint64(2),
  17014. Fopcode: uint8(m_XCB_COPY_COLORMAP_AND_FREE),
  17015. Fisvoid: uint8(1),
  17016. }
  17017. func Xxcb_copy_colormap_and_free(tls *libc.TLS, c uintptr, mid Txcb_colormap_t, src_cmap Txcb_colormap_t) (r Txcb_void_cookie_t) {
  17018. bp := tls.Alloc(80)
  17019. defer tls.Free(80)
  17020. var xcb_ret Txcb_void_cookie_t
  17021. var _ /* xcb_out at bp+64 */ Txcb_copy_colormap_and_free_request_t
  17022. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  17023. _ = xcb_ret
  17024. (*(*Txcb_copy_colormap_and_free_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  17025. (*(*Txcb_copy_colormap_and_free_request_t)(unsafe.Pointer(bp + 64))).Fmid = mid
  17026. (*(*Txcb_copy_colormap_and_free_request_t)(unsafe.Pointer(bp + 64))).Fsrc_cmap = src_cmap
  17027. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  17028. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  17029. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17030. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17031. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req169)))
  17032. return xcb_ret
  17033. }
  17034. var _xcb_req169 = Txcb_protocol_request_t{
  17035. Fcount: uint64(2),
  17036. Fopcode: uint8(m_XCB_COPY_COLORMAP_AND_FREE),
  17037. Fisvoid: uint8(1),
  17038. }
  17039. func Xxcb_install_colormap_checked(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t) (r Txcb_void_cookie_t) {
  17040. bp := tls.Alloc(80)
  17041. defer tls.Free(80)
  17042. var xcb_ret Txcb_void_cookie_t
  17043. var _ /* xcb_out at bp+64 */ Txcb_install_colormap_request_t
  17044. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  17045. _ = xcb_ret
  17046. (*(*Txcb_install_colormap_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  17047. (*(*Txcb_install_colormap_request_t)(unsafe.Pointer(bp + 64))).Fcmap = cmap
  17048. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  17049. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  17050. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17051. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17052. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req170)))
  17053. return xcb_ret
  17054. }
  17055. var _xcb_req170 = Txcb_protocol_request_t{
  17056. Fcount: uint64(2),
  17057. Fopcode: uint8(m_XCB_INSTALL_COLORMAP),
  17058. Fisvoid: uint8(1),
  17059. }
  17060. func Xxcb_install_colormap(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t) (r Txcb_void_cookie_t) {
  17061. bp := tls.Alloc(80)
  17062. defer tls.Free(80)
  17063. var xcb_ret Txcb_void_cookie_t
  17064. var _ /* xcb_out at bp+64 */ Txcb_install_colormap_request_t
  17065. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  17066. _ = xcb_ret
  17067. (*(*Txcb_install_colormap_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  17068. (*(*Txcb_install_colormap_request_t)(unsafe.Pointer(bp + 64))).Fcmap = cmap
  17069. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  17070. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  17071. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17072. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17073. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req171)))
  17074. return xcb_ret
  17075. }
  17076. var _xcb_req171 = Txcb_protocol_request_t{
  17077. Fcount: uint64(2),
  17078. Fopcode: uint8(m_XCB_INSTALL_COLORMAP),
  17079. Fisvoid: uint8(1),
  17080. }
  17081. func Xxcb_uninstall_colormap_checked(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t) (r Txcb_void_cookie_t) {
  17082. bp := tls.Alloc(80)
  17083. defer tls.Free(80)
  17084. var xcb_ret Txcb_void_cookie_t
  17085. var _ /* xcb_out at bp+64 */ Txcb_uninstall_colormap_request_t
  17086. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  17087. _ = xcb_ret
  17088. (*(*Txcb_uninstall_colormap_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  17089. (*(*Txcb_uninstall_colormap_request_t)(unsafe.Pointer(bp + 64))).Fcmap = cmap
  17090. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  17091. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  17092. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17093. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17094. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req172)))
  17095. return xcb_ret
  17096. }
  17097. var _xcb_req172 = Txcb_protocol_request_t{
  17098. Fcount: uint64(2),
  17099. Fopcode: uint8(m_XCB_UNINSTALL_COLORMAP),
  17100. Fisvoid: uint8(1),
  17101. }
  17102. func Xxcb_uninstall_colormap(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t) (r Txcb_void_cookie_t) {
  17103. bp := tls.Alloc(80)
  17104. defer tls.Free(80)
  17105. var xcb_ret Txcb_void_cookie_t
  17106. var _ /* xcb_out at bp+64 */ Txcb_uninstall_colormap_request_t
  17107. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  17108. _ = xcb_ret
  17109. (*(*Txcb_uninstall_colormap_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  17110. (*(*Txcb_uninstall_colormap_request_t)(unsafe.Pointer(bp + 64))).Fcmap = cmap
  17111. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  17112. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  17113. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17114. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17115. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req173)))
  17116. return xcb_ret
  17117. }
  17118. var _xcb_req173 = Txcb_protocol_request_t{
  17119. Fcount: uint64(2),
  17120. Fopcode: uint8(m_XCB_UNINSTALL_COLORMAP),
  17121. Fisvoid: uint8(1),
  17122. }
  17123. func Xxcb_list_installed_colormaps_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  17124. var _aux, xcb_tmp uintptr
  17125. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  17126. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  17127. xcb_tmp = _buffer
  17128. _aux = _buffer
  17129. xcb_buffer_len = uint32(0)
  17130. xcb_block_len = uint32(0)
  17131. xcb_pad = uint32(0)
  17132. xcb_align_to = uint32(0)
  17133. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(32))
  17134. xcb_tmp += uintptr(xcb_block_len)
  17135. xcb_buffer_len += xcb_block_len
  17136. xcb_block_len = uint32(0)
  17137. /* cmaps */
  17138. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_list_installed_colormaps_reply_t)(unsafe.Pointer(_aux)).Fcmaps_len)*libc.Uint64FromInt64(4))
  17139. xcb_tmp += uintptr(xcb_block_len)
  17140. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  17141. /* insert padding */
  17142. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  17143. xcb_buffer_len += xcb_block_len + xcb_pad
  17144. if uint32(0) != xcb_pad {
  17145. xcb_tmp += uintptr(xcb_pad)
  17146. xcb_pad = uint32(0)
  17147. }
  17148. xcb_block_len = uint32(0)
  17149. return libc.Int32FromUint32(xcb_buffer_len)
  17150. }
  17151. func Xxcb_list_installed_colormaps(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_list_installed_colormaps_cookie_t) {
  17152. bp := tls.Alloc(80)
  17153. defer tls.Free(80)
  17154. var xcb_ret Txcb_list_installed_colormaps_cookie_t
  17155. var _ /* xcb_out at bp+64 */ Txcb_list_installed_colormaps_request_t
  17156. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  17157. _ = xcb_ret
  17158. (*(*Txcb_list_installed_colormaps_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  17159. (*(*Txcb_list_installed_colormaps_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  17160. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  17161. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  17162. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17163. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17164. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req174)))
  17165. return xcb_ret
  17166. }
  17167. var _xcb_req174 = Txcb_protocol_request_t{
  17168. Fcount: uint64(2),
  17169. Fopcode: uint8(m_XCB_LIST_INSTALLED_COLORMAPS),
  17170. }
  17171. func Xxcb_list_installed_colormaps_unchecked(tls *libc.TLS, c uintptr, window Txcb_window_t) (r Txcb_list_installed_colormaps_cookie_t) {
  17172. bp := tls.Alloc(80)
  17173. defer tls.Free(80)
  17174. var xcb_ret Txcb_list_installed_colormaps_cookie_t
  17175. var _ /* xcb_out at bp+64 */ Txcb_list_installed_colormaps_request_t
  17176. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  17177. _ = xcb_ret
  17178. (*(*Txcb_list_installed_colormaps_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  17179. (*(*Txcb_list_installed_colormaps_request_t)(unsafe.Pointer(bp + 64))).Fwindow = window
  17180. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  17181. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  17182. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17183. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17184. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req175)))
  17185. return xcb_ret
  17186. }
  17187. var _xcb_req175 = Txcb_protocol_request_t{
  17188. Fcount: uint64(2),
  17189. Fopcode: uint8(m_XCB_LIST_INSTALLED_COLORMAPS),
  17190. }
  17191. func Xxcb_list_installed_colormaps_cmaps(tls *libc.TLS, R uintptr) (r uintptr) {
  17192. return R + libc.UintptrFromInt32(1)*32
  17193. }
  17194. func Xxcb_list_installed_colormaps_cmaps_length(tls *libc.TLS, R uintptr) (r int32) {
  17195. return libc.Int32FromUint16((*Txcb_list_installed_colormaps_reply_t)(unsafe.Pointer(R)).Fcmaps_len)
  17196. }
  17197. func Xxcb_list_installed_colormaps_cmaps_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  17198. var i Txcb_generic_iterator_t
  17199. _ = i
  17200. i.Fdata = R + libc.UintptrFromInt32(1)*32 + uintptr((*Txcb_list_installed_colormaps_reply_t)(unsafe.Pointer(R)).Fcmaps_len)*4
  17201. i.Frem = 0
  17202. i.Findex = int32(int64(i.Fdata) - int64(R))
  17203. return i
  17204. }
  17205. func Xxcb_list_installed_colormaps_reply(tls *libc.TLS, c uintptr, cookie Txcb_list_installed_colormaps_cookie_t, e uintptr) (r uintptr) {
  17206. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  17207. }
  17208. func Xxcb_alloc_color(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t, red Tuint16_t, green Tuint16_t, blue Tuint16_t) (r Txcb_alloc_color_cookie_t) {
  17209. bp := tls.Alloc(80)
  17210. defer tls.Free(80)
  17211. var xcb_ret Txcb_alloc_color_cookie_t
  17212. var _ /* xcb_out at bp+64 */ Txcb_alloc_color_request_t
  17213. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  17214. _ = xcb_ret
  17215. (*(*Txcb_alloc_color_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  17216. (*(*Txcb_alloc_color_request_t)(unsafe.Pointer(bp + 64))).Fcmap = cmap
  17217. (*(*Txcb_alloc_color_request_t)(unsafe.Pointer(bp + 64))).Fred = red
  17218. (*(*Txcb_alloc_color_request_t)(unsafe.Pointer(bp + 64))).Fgreen = green
  17219. (*(*Txcb_alloc_color_request_t)(unsafe.Pointer(bp + 64))).Fblue = blue
  17220. libc.Xmemset(tls, bp+64+14, 0, uint64(2))
  17221. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  17222. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  17223. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17224. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17225. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req176)))
  17226. return xcb_ret
  17227. }
  17228. var _xcb_req176 = Txcb_protocol_request_t{
  17229. Fcount: uint64(2),
  17230. Fopcode: uint8(m_XCB_ALLOC_COLOR),
  17231. }
  17232. func Xxcb_alloc_color_unchecked(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t, red Tuint16_t, green Tuint16_t, blue Tuint16_t) (r Txcb_alloc_color_cookie_t) {
  17233. bp := tls.Alloc(80)
  17234. defer tls.Free(80)
  17235. var xcb_ret Txcb_alloc_color_cookie_t
  17236. var _ /* xcb_out at bp+64 */ Txcb_alloc_color_request_t
  17237. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  17238. _ = xcb_ret
  17239. (*(*Txcb_alloc_color_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  17240. (*(*Txcb_alloc_color_request_t)(unsafe.Pointer(bp + 64))).Fcmap = cmap
  17241. (*(*Txcb_alloc_color_request_t)(unsafe.Pointer(bp + 64))).Fred = red
  17242. (*(*Txcb_alloc_color_request_t)(unsafe.Pointer(bp + 64))).Fgreen = green
  17243. (*(*Txcb_alloc_color_request_t)(unsafe.Pointer(bp + 64))).Fblue = blue
  17244. libc.Xmemset(tls, bp+64+14, 0, uint64(2))
  17245. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  17246. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  17247. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17248. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17249. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req177)))
  17250. return xcb_ret
  17251. }
  17252. var _xcb_req177 = Txcb_protocol_request_t{
  17253. Fcount: uint64(2),
  17254. Fopcode: uint8(m_XCB_ALLOC_COLOR),
  17255. }
  17256. func Xxcb_alloc_color_reply(tls *libc.TLS, c uintptr, cookie Txcb_alloc_color_cookie_t, e uintptr) (r uintptr) {
  17257. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  17258. }
  17259. func Xxcb_alloc_named_color_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  17260. var _aux, xcb_tmp uintptr
  17261. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  17262. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  17263. xcb_tmp = _buffer
  17264. _aux = _buffer
  17265. xcb_buffer_len = uint32(0)
  17266. xcb_block_len = uint32(0)
  17267. xcb_pad = uint32(0)
  17268. xcb_align_to = uint32(0)
  17269. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  17270. xcb_tmp += uintptr(xcb_block_len)
  17271. xcb_buffer_len += xcb_block_len
  17272. xcb_block_len = uint32(0)
  17273. /* name */
  17274. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_alloc_named_color_request_t)(unsafe.Pointer(_aux)).Fname_len)*libc.Uint64FromInt64(1))
  17275. xcb_tmp += uintptr(xcb_block_len)
  17276. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  17277. /* insert padding */
  17278. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  17279. xcb_buffer_len += xcb_block_len + xcb_pad
  17280. if uint32(0) != xcb_pad {
  17281. xcb_tmp += uintptr(xcb_pad)
  17282. xcb_pad = uint32(0)
  17283. }
  17284. xcb_block_len = uint32(0)
  17285. return libc.Int32FromUint32(xcb_buffer_len)
  17286. }
  17287. func Xxcb_alloc_named_color(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t, name_len Tuint16_t, name uintptr) (r Txcb_alloc_named_color_cookie_t) {
  17288. bp := tls.Alloc(112)
  17289. defer tls.Free(112)
  17290. var xcb_ret Txcb_alloc_named_color_cookie_t
  17291. var _ /* xcb_out at bp+96 */ Txcb_alloc_named_color_request_t
  17292. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  17293. _ = xcb_ret
  17294. (*(*Txcb_alloc_named_color_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  17295. (*(*Txcb_alloc_named_color_request_t)(unsafe.Pointer(bp + 96))).Fcmap = cmap
  17296. (*(*Txcb_alloc_named_color_request_t)(unsafe.Pointer(bp + 96))).Fname_len = name_len
  17297. libc.Xmemset(tls, bp+96+10, 0, uint64(2))
  17298. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  17299. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  17300. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17301. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17302. /* char name */
  17303. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = name
  17304. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(name_len) * uint64(1)
  17305. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  17306. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  17307. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req178)))
  17308. return xcb_ret
  17309. }
  17310. var _xcb_req178 = Txcb_protocol_request_t{
  17311. Fcount: uint64(4),
  17312. Fopcode: uint8(m_XCB_ALLOC_NAMED_COLOR),
  17313. }
  17314. func Xxcb_alloc_named_color_unchecked(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t, name_len Tuint16_t, name uintptr) (r Txcb_alloc_named_color_cookie_t) {
  17315. bp := tls.Alloc(112)
  17316. defer tls.Free(112)
  17317. var xcb_ret Txcb_alloc_named_color_cookie_t
  17318. var _ /* xcb_out at bp+96 */ Txcb_alloc_named_color_request_t
  17319. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  17320. _ = xcb_ret
  17321. (*(*Txcb_alloc_named_color_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  17322. (*(*Txcb_alloc_named_color_request_t)(unsafe.Pointer(bp + 96))).Fcmap = cmap
  17323. (*(*Txcb_alloc_named_color_request_t)(unsafe.Pointer(bp + 96))).Fname_len = name_len
  17324. libc.Xmemset(tls, bp+96+10, 0, uint64(2))
  17325. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  17326. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  17327. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17328. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17329. /* char name */
  17330. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = name
  17331. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(name_len) * uint64(1)
  17332. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  17333. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  17334. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req179)))
  17335. return xcb_ret
  17336. }
  17337. var _xcb_req179 = Txcb_protocol_request_t{
  17338. Fcount: uint64(4),
  17339. Fopcode: uint8(m_XCB_ALLOC_NAMED_COLOR),
  17340. }
  17341. func Xxcb_alloc_named_color_reply(tls *libc.TLS, c uintptr, cookie Txcb_alloc_named_color_cookie_t, e uintptr) (r uintptr) {
  17342. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  17343. }
  17344. func Xxcb_alloc_color_cells_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  17345. var _aux, xcb_tmp uintptr
  17346. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  17347. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  17348. xcb_tmp = _buffer
  17349. _aux = _buffer
  17350. xcb_buffer_len = uint32(0)
  17351. xcb_block_len = uint32(0)
  17352. xcb_pad = uint32(0)
  17353. xcb_align_to = uint32(0)
  17354. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(32))
  17355. xcb_tmp += uintptr(xcb_block_len)
  17356. xcb_buffer_len += xcb_block_len
  17357. xcb_block_len = uint32(0)
  17358. /* pixels */
  17359. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_alloc_color_cells_reply_t)(unsafe.Pointer(_aux)).Fpixels_len)*libc.Uint64FromInt64(4))
  17360. xcb_tmp += uintptr(xcb_block_len)
  17361. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  17362. /* insert padding */
  17363. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  17364. xcb_buffer_len += xcb_block_len + xcb_pad
  17365. if uint32(0) != xcb_pad {
  17366. xcb_tmp += uintptr(xcb_pad)
  17367. xcb_pad = uint32(0)
  17368. }
  17369. xcb_block_len = uint32(0)
  17370. /* masks */
  17371. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_alloc_color_cells_reply_t)(unsafe.Pointer(_aux)).Fmasks_len)*libc.Uint64FromInt64(4))
  17372. xcb_tmp += uintptr(xcb_block_len)
  17373. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  17374. /* insert padding */
  17375. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  17376. xcb_buffer_len += xcb_block_len + xcb_pad
  17377. if uint32(0) != xcb_pad {
  17378. xcb_tmp += uintptr(xcb_pad)
  17379. xcb_pad = uint32(0)
  17380. }
  17381. xcb_block_len = uint32(0)
  17382. return libc.Int32FromUint32(xcb_buffer_len)
  17383. }
  17384. func Xxcb_alloc_color_cells(tls *libc.TLS, c uintptr, contiguous Tuint8_t, cmap Txcb_colormap_t, colors Tuint16_t, planes Tuint16_t) (r Txcb_alloc_color_cells_cookie_t) {
  17385. bp := tls.Alloc(80)
  17386. defer tls.Free(80)
  17387. var xcb_ret Txcb_alloc_color_cells_cookie_t
  17388. var _ /* xcb_out at bp+64 */ Txcb_alloc_color_cells_request_t
  17389. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  17390. _ = xcb_ret
  17391. (*(*Txcb_alloc_color_cells_request_t)(unsafe.Pointer(bp + 64))).Fcontiguous = contiguous
  17392. (*(*Txcb_alloc_color_cells_request_t)(unsafe.Pointer(bp + 64))).Fcmap = cmap
  17393. (*(*Txcb_alloc_color_cells_request_t)(unsafe.Pointer(bp + 64))).Fcolors = colors
  17394. (*(*Txcb_alloc_color_cells_request_t)(unsafe.Pointer(bp + 64))).Fplanes = planes
  17395. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  17396. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  17397. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17398. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17399. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req180)))
  17400. return xcb_ret
  17401. }
  17402. var _xcb_req180 = Txcb_protocol_request_t{
  17403. Fcount: uint64(2),
  17404. Fopcode: uint8(m_XCB_ALLOC_COLOR_CELLS),
  17405. }
  17406. func Xxcb_alloc_color_cells_unchecked(tls *libc.TLS, c uintptr, contiguous Tuint8_t, cmap Txcb_colormap_t, colors Tuint16_t, planes Tuint16_t) (r Txcb_alloc_color_cells_cookie_t) {
  17407. bp := tls.Alloc(80)
  17408. defer tls.Free(80)
  17409. var xcb_ret Txcb_alloc_color_cells_cookie_t
  17410. var _ /* xcb_out at bp+64 */ Txcb_alloc_color_cells_request_t
  17411. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  17412. _ = xcb_ret
  17413. (*(*Txcb_alloc_color_cells_request_t)(unsafe.Pointer(bp + 64))).Fcontiguous = contiguous
  17414. (*(*Txcb_alloc_color_cells_request_t)(unsafe.Pointer(bp + 64))).Fcmap = cmap
  17415. (*(*Txcb_alloc_color_cells_request_t)(unsafe.Pointer(bp + 64))).Fcolors = colors
  17416. (*(*Txcb_alloc_color_cells_request_t)(unsafe.Pointer(bp + 64))).Fplanes = planes
  17417. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  17418. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  17419. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17420. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17421. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req181)))
  17422. return xcb_ret
  17423. }
  17424. var _xcb_req181 = Txcb_protocol_request_t{
  17425. Fcount: uint64(2),
  17426. Fopcode: uint8(m_XCB_ALLOC_COLOR_CELLS),
  17427. }
  17428. func Xxcb_alloc_color_cells_pixels(tls *libc.TLS, R uintptr) (r uintptr) {
  17429. return R + libc.UintptrFromInt32(1)*32
  17430. }
  17431. func Xxcb_alloc_color_cells_pixels_length(tls *libc.TLS, R uintptr) (r int32) {
  17432. return libc.Int32FromUint16((*Txcb_alloc_color_cells_reply_t)(unsafe.Pointer(R)).Fpixels_len)
  17433. }
  17434. func Xxcb_alloc_color_cells_pixels_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  17435. var i Txcb_generic_iterator_t
  17436. _ = i
  17437. i.Fdata = R + libc.UintptrFromInt32(1)*32 + uintptr((*Txcb_alloc_color_cells_reply_t)(unsafe.Pointer(R)).Fpixels_len)*4
  17438. i.Frem = 0
  17439. i.Findex = int32(int64(i.Fdata) - int64(R))
  17440. return i
  17441. }
  17442. func Xxcb_alloc_color_cells_masks(tls *libc.TLS, R uintptr) (r uintptr) {
  17443. var prev Txcb_generic_iterator_t
  17444. _ = prev
  17445. prev = Xxcb_alloc_color_cells_pixels_end(tls, R)
  17446. return prev.Fdata + uintptr(libc.Uint64FromInt32(-prev.Findex)&(libc.Uint64FromInt64(4)-libc.Uint64FromInt32(1))) + libc.UintptrFromInt32(0)
  17447. }
  17448. func Xxcb_alloc_color_cells_masks_length(tls *libc.TLS, R uintptr) (r int32) {
  17449. return libc.Int32FromUint16((*Txcb_alloc_color_cells_reply_t)(unsafe.Pointer(R)).Fmasks_len)
  17450. }
  17451. func Xxcb_alloc_color_cells_masks_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  17452. var i, prev Txcb_generic_iterator_t
  17453. _, _ = i, prev
  17454. prev = Xxcb_alloc_color_cells_pixels_end(tls, R)
  17455. i.Fdata = prev.Fdata + uintptr(libc.Uint64FromInt32(-prev.Findex)&(libc.Uint64FromInt64(4)-libc.Uint64FromInt32(1))) + uintptr((*Txcb_alloc_color_cells_reply_t)(unsafe.Pointer(R)).Fmasks_len)*4
  17456. i.Frem = 0
  17457. i.Findex = int32(int64(i.Fdata) - int64(R))
  17458. return i
  17459. }
  17460. func Xxcb_alloc_color_cells_reply(tls *libc.TLS, c uintptr, cookie Txcb_alloc_color_cells_cookie_t, e uintptr) (r uintptr) {
  17461. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  17462. }
  17463. func Xxcb_alloc_color_planes_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  17464. var _aux, xcb_tmp uintptr
  17465. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  17466. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  17467. xcb_tmp = _buffer
  17468. _aux = _buffer
  17469. xcb_buffer_len = uint32(0)
  17470. xcb_block_len = uint32(0)
  17471. xcb_pad = uint32(0)
  17472. xcb_align_to = uint32(0)
  17473. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(32))
  17474. xcb_tmp += uintptr(xcb_block_len)
  17475. xcb_buffer_len += xcb_block_len
  17476. xcb_block_len = uint32(0)
  17477. /* pixels */
  17478. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_alloc_color_planes_reply_t)(unsafe.Pointer(_aux)).Fpixels_len)*libc.Uint64FromInt64(4))
  17479. xcb_tmp += uintptr(xcb_block_len)
  17480. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  17481. /* insert padding */
  17482. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  17483. xcb_buffer_len += xcb_block_len + xcb_pad
  17484. if uint32(0) != xcb_pad {
  17485. xcb_tmp += uintptr(xcb_pad)
  17486. xcb_pad = uint32(0)
  17487. }
  17488. xcb_block_len = uint32(0)
  17489. return libc.Int32FromUint32(xcb_buffer_len)
  17490. }
  17491. func Xxcb_alloc_color_planes(tls *libc.TLS, c uintptr, contiguous Tuint8_t, cmap Txcb_colormap_t, colors Tuint16_t, reds Tuint16_t, greens Tuint16_t, blues Tuint16_t) (r Txcb_alloc_color_planes_cookie_t) {
  17492. bp := tls.Alloc(80)
  17493. defer tls.Free(80)
  17494. var xcb_ret Txcb_alloc_color_planes_cookie_t
  17495. var _ /* xcb_out at bp+64 */ Txcb_alloc_color_planes_request_t
  17496. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  17497. _ = xcb_ret
  17498. (*(*Txcb_alloc_color_planes_request_t)(unsafe.Pointer(bp + 64))).Fcontiguous = contiguous
  17499. (*(*Txcb_alloc_color_planes_request_t)(unsafe.Pointer(bp + 64))).Fcmap = cmap
  17500. (*(*Txcb_alloc_color_planes_request_t)(unsafe.Pointer(bp + 64))).Fcolors = colors
  17501. (*(*Txcb_alloc_color_planes_request_t)(unsafe.Pointer(bp + 64))).Freds = reds
  17502. (*(*Txcb_alloc_color_planes_request_t)(unsafe.Pointer(bp + 64))).Fgreens = greens
  17503. (*(*Txcb_alloc_color_planes_request_t)(unsafe.Pointer(bp + 64))).Fblues = blues
  17504. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  17505. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  17506. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17507. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17508. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req182)))
  17509. return xcb_ret
  17510. }
  17511. var _xcb_req182 = Txcb_protocol_request_t{
  17512. Fcount: uint64(2),
  17513. Fopcode: uint8(m_XCB_ALLOC_COLOR_PLANES),
  17514. }
  17515. func Xxcb_alloc_color_planes_unchecked(tls *libc.TLS, c uintptr, contiguous Tuint8_t, cmap Txcb_colormap_t, colors Tuint16_t, reds Tuint16_t, greens Tuint16_t, blues Tuint16_t) (r Txcb_alloc_color_planes_cookie_t) {
  17516. bp := tls.Alloc(80)
  17517. defer tls.Free(80)
  17518. var xcb_ret Txcb_alloc_color_planes_cookie_t
  17519. var _ /* xcb_out at bp+64 */ Txcb_alloc_color_planes_request_t
  17520. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  17521. _ = xcb_ret
  17522. (*(*Txcb_alloc_color_planes_request_t)(unsafe.Pointer(bp + 64))).Fcontiguous = contiguous
  17523. (*(*Txcb_alloc_color_planes_request_t)(unsafe.Pointer(bp + 64))).Fcmap = cmap
  17524. (*(*Txcb_alloc_color_planes_request_t)(unsafe.Pointer(bp + 64))).Fcolors = colors
  17525. (*(*Txcb_alloc_color_planes_request_t)(unsafe.Pointer(bp + 64))).Freds = reds
  17526. (*(*Txcb_alloc_color_planes_request_t)(unsafe.Pointer(bp + 64))).Fgreens = greens
  17527. (*(*Txcb_alloc_color_planes_request_t)(unsafe.Pointer(bp + 64))).Fblues = blues
  17528. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  17529. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  17530. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17531. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17532. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req183)))
  17533. return xcb_ret
  17534. }
  17535. var _xcb_req183 = Txcb_protocol_request_t{
  17536. Fcount: uint64(2),
  17537. Fopcode: uint8(m_XCB_ALLOC_COLOR_PLANES),
  17538. }
  17539. func Xxcb_alloc_color_planes_pixels(tls *libc.TLS, R uintptr) (r uintptr) {
  17540. return R + libc.UintptrFromInt32(1)*32
  17541. }
  17542. func Xxcb_alloc_color_planes_pixels_length(tls *libc.TLS, R uintptr) (r int32) {
  17543. return libc.Int32FromUint16((*Txcb_alloc_color_planes_reply_t)(unsafe.Pointer(R)).Fpixels_len)
  17544. }
  17545. func Xxcb_alloc_color_planes_pixels_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  17546. var i Txcb_generic_iterator_t
  17547. _ = i
  17548. i.Fdata = R + libc.UintptrFromInt32(1)*32 + uintptr((*Txcb_alloc_color_planes_reply_t)(unsafe.Pointer(R)).Fpixels_len)*4
  17549. i.Frem = 0
  17550. i.Findex = int32(int64(i.Fdata) - int64(R))
  17551. return i
  17552. }
  17553. func Xxcb_alloc_color_planes_reply(tls *libc.TLS, c uintptr, cookie Txcb_alloc_color_planes_cookie_t, e uintptr) (r uintptr) {
  17554. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  17555. }
  17556. func Xxcb_free_colors_sizeof(tls *libc.TLS, _buffer uintptr, pixels_len Tuint32_t) (r int32) {
  17557. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  17558. var xcb_tmp uintptr
  17559. _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  17560. xcb_tmp = _buffer
  17561. xcb_buffer_len = uint32(0)
  17562. xcb_block_len = uint32(0)
  17563. xcb_pad = uint32(0)
  17564. xcb_align_to = uint32(0)
  17565. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  17566. xcb_tmp += uintptr(xcb_block_len)
  17567. xcb_buffer_len += xcb_block_len
  17568. xcb_block_len = uint32(0)
  17569. /* pixels */
  17570. xcb_block_len = uint32(uint64(xcb_block_len) + uint64(pixels_len)*libc.Uint64FromInt64(4))
  17571. xcb_tmp += uintptr(xcb_block_len)
  17572. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  17573. /* insert padding */
  17574. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  17575. xcb_buffer_len += xcb_block_len + xcb_pad
  17576. if uint32(0) != xcb_pad {
  17577. xcb_tmp += uintptr(xcb_pad)
  17578. xcb_pad = uint32(0)
  17579. }
  17580. xcb_block_len = uint32(0)
  17581. return libc.Int32FromUint32(xcb_buffer_len)
  17582. }
  17583. func Xxcb_free_colors_checked(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t, plane_mask Tuint32_t, pixels_len Tuint32_t, pixels uintptr) (r Txcb_void_cookie_t) {
  17584. bp := tls.Alloc(112)
  17585. defer tls.Free(112)
  17586. var xcb_ret Txcb_void_cookie_t
  17587. var _ /* xcb_out at bp+96 */ Txcb_free_colors_request_t
  17588. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  17589. _ = xcb_ret
  17590. (*(*Txcb_free_colors_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  17591. (*(*Txcb_free_colors_request_t)(unsafe.Pointer(bp + 96))).Fcmap = cmap
  17592. (*(*Txcb_free_colors_request_t)(unsafe.Pointer(bp + 96))).Fplane_mask = plane_mask
  17593. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  17594. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  17595. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17596. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17597. /* uint32_t pixels */
  17598. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = pixels
  17599. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(pixels_len) * uint64(4)
  17600. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  17601. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  17602. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req184)))
  17603. return xcb_ret
  17604. }
  17605. var _xcb_req184 = Txcb_protocol_request_t{
  17606. Fcount: uint64(4),
  17607. Fopcode: uint8(m_XCB_FREE_COLORS),
  17608. Fisvoid: uint8(1),
  17609. }
  17610. func Xxcb_free_colors(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t, plane_mask Tuint32_t, pixels_len Tuint32_t, pixels uintptr) (r Txcb_void_cookie_t) {
  17611. bp := tls.Alloc(112)
  17612. defer tls.Free(112)
  17613. var xcb_ret Txcb_void_cookie_t
  17614. var _ /* xcb_out at bp+96 */ Txcb_free_colors_request_t
  17615. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  17616. _ = xcb_ret
  17617. (*(*Txcb_free_colors_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  17618. (*(*Txcb_free_colors_request_t)(unsafe.Pointer(bp + 96))).Fcmap = cmap
  17619. (*(*Txcb_free_colors_request_t)(unsafe.Pointer(bp + 96))).Fplane_mask = plane_mask
  17620. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  17621. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  17622. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17623. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17624. /* uint32_t pixels */
  17625. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = pixels
  17626. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(pixels_len) * uint64(4)
  17627. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  17628. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  17629. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req185)))
  17630. return xcb_ret
  17631. }
  17632. var _xcb_req185 = Txcb_protocol_request_t{
  17633. Fcount: uint64(4),
  17634. Fopcode: uint8(m_XCB_FREE_COLORS),
  17635. Fisvoid: uint8(1),
  17636. }
  17637. func Xxcb_free_colors_pixels(tls *libc.TLS, R uintptr) (r uintptr) {
  17638. return R + libc.UintptrFromInt32(1)*12
  17639. }
  17640. func Xxcb_free_colors_pixels_length(tls *libc.TLS, R uintptr) (r int32) {
  17641. return libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_free_colors_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(12)) / libc.Uint64FromInt64(4))
  17642. }
  17643. func Xxcb_free_colors_pixels_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  17644. var i Txcb_generic_iterator_t
  17645. _ = i
  17646. i.Fdata = R + libc.UintptrFromInt32(1)*12 + uintptr((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_free_colors_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4))-libc.Uint64FromInt64(12))/libc.Uint64FromInt64(4))*4
  17647. i.Frem = 0
  17648. i.Findex = int32(int64(i.Fdata) - int64(R))
  17649. return i
  17650. }
  17651. func Xxcb_coloritem_next(tls *libc.TLS, i uintptr) {
  17652. var p1 uintptr
  17653. _ = p1
  17654. (*Txcb_coloritem_iterator_t)(unsafe.Pointer(i)).Frem--
  17655. (*Txcb_coloritem_iterator_t)(unsafe.Pointer(i)).Fdata += 12
  17656. p1 = i + 12
  17657. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(12))
  17658. }
  17659. func Xxcb_coloritem_end(tls *libc.TLS, i Txcb_coloritem_iterator_t) (r Txcb_generic_iterator_t) {
  17660. var ret Txcb_generic_iterator_t
  17661. _ = ret
  17662. ret.Fdata = i.Fdata + uintptr(i.Frem)*12
  17663. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  17664. ret.Frem = 0
  17665. return ret
  17666. }
  17667. func Xxcb_store_colors_sizeof(tls *libc.TLS, _buffer uintptr, items_len Tuint32_t) (r int32) {
  17668. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  17669. var xcb_tmp uintptr
  17670. _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  17671. xcb_tmp = _buffer
  17672. xcb_buffer_len = uint32(0)
  17673. xcb_block_len = uint32(0)
  17674. xcb_pad = uint32(0)
  17675. xcb_align_to = uint32(0)
  17676. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(8))
  17677. xcb_tmp += uintptr(xcb_block_len)
  17678. xcb_buffer_len += xcb_block_len
  17679. xcb_block_len = uint32(0)
  17680. /* items */
  17681. xcb_block_len = uint32(uint64(xcb_block_len) + uint64(items_len)*libc.Uint64FromInt64(12))
  17682. xcb_tmp += uintptr(xcb_block_len)
  17683. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  17684. /* insert padding */
  17685. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  17686. xcb_buffer_len += xcb_block_len + xcb_pad
  17687. if uint32(0) != xcb_pad {
  17688. xcb_tmp += uintptr(xcb_pad)
  17689. xcb_pad = uint32(0)
  17690. }
  17691. xcb_block_len = uint32(0)
  17692. return libc.Int32FromUint32(xcb_buffer_len)
  17693. }
  17694. func Xxcb_store_colors_checked(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t, items_len Tuint32_t, items uintptr) (r Txcb_void_cookie_t) {
  17695. bp := tls.Alloc(112)
  17696. defer tls.Free(112)
  17697. var xcb_ret Txcb_void_cookie_t
  17698. var _ /* xcb_out at bp+96 */ Txcb_store_colors_request_t
  17699. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  17700. _ = xcb_ret
  17701. (*(*Txcb_store_colors_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  17702. (*(*Txcb_store_colors_request_t)(unsafe.Pointer(bp + 96))).Fcmap = cmap
  17703. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  17704. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  17705. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17706. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17707. /* xcb_coloritem_t items */
  17708. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = items
  17709. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(items_len) * uint64(12)
  17710. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  17711. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  17712. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req186)))
  17713. return xcb_ret
  17714. }
  17715. var _xcb_req186 = Txcb_protocol_request_t{
  17716. Fcount: uint64(4),
  17717. Fopcode: uint8(m_XCB_STORE_COLORS),
  17718. Fisvoid: uint8(1),
  17719. }
  17720. func Xxcb_store_colors(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t, items_len Tuint32_t, items uintptr) (r Txcb_void_cookie_t) {
  17721. bp := tls.Alloc(112)
  17722. defer tls.Free(112)
  17723. var xcb_ret Txcb_void_cookie_t
  17724. var _ /* xcb_out at bp+96 */ Txcb_store_colors_request_t
  17725. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  17726. _ = xcb_ret
  17727. (*(*Txcb_store_colors_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  17728. (*(*Txcb_store_colors_request_t)(unsafe.Pointer(bp + 96))).Fcmap = cmap
  17729. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  17730. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  17731. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17732. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17733. /* xcb_coloritem_t items */
  17734. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = items
  17735. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(items_len) * uint64(12)
  17736. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  17737. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  17738. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req187)))
  17739. return xcb_ret
  17740. }
  17741. var _xcb_req187 = Txcb_protocol_request_t{
  17742. Fcount: uint64(4),
  17743. Fopcode: uint8(m_XCB_STORE_COLORS),
  17744. Fisvoid: uint8(1),
  17745. }
  17746. func Xxcb_store_colors_items(tls *libc.TLS, R uintptr) (r uintptr) {
  17747. return R + libc.UintptrFromInt32(1)*8
  17748. }
  17749. func Xxcb_store_colors_items_length(tls *libc.TLS, R uintptr) (r int32) {
  17750. return libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_store_colors_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(8)) / libc.Uint64FromInt64(12))
  17751. }
  17752. func Xxcb_store_colors_items_iterator(tls *libc.TLS, R uintptr) (r Txcb_coloritem_iterator_t) {
  17753. var i Txcb_coloritem_iterator_t
  17754. _ = i
  17755. i.Fdata = R + libc.UintptrFromInt32(1)*8
  17756. i.Frem = libc.Int32FromUint64((libc.Uint64FromInt32(libc.Int32FromUint16((*Txcb_store_colors_request_t)(unsafe.Pointer(R)).Flength)*libc.Int32FromInt32(4)) - libc.Uint64FromInt64(8)) / libc.Uint64FromInt64(12))
  17757. i.Findex = int32(int64(i.Fdata) - int64(R))
  17758. return i
  17759. }
  17760. func Xxcb_store_named_color_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  17761. var _aux, xcb_tmp uintptr
  17762. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  17763. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  17764. xcb_tmp = _buffer
  17765. _aux = _buffer
  17766. xcb_buffer_len = uint32(0)
  17767. xcb_block_len = uint32(0)
  17768. xcb_pad = uint32(0)
  17769. xcb_align_to = uint32(0)
  17770. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(16))
  17771. xcb_tmp += uintptr(xcb_block_len)
  17772. xcb_buffer_len += xcb_block_len
  17773. xcb_block_len = uint32(0)
  17774. /* name */
  17775. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_store_named_color_request_t)(unsafe.Pointer(_aux)).Fname_len)*libc.Uint64FromInt64(1))
  17776. xcb_tmp += uintptr(xcb_block_len)
  17777. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  17778. /* insert padding */
  17779. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  17780. xcb_buffer_len += xcb_block_len + xcb_pad
  17781. if uint32(0) != xcb_pad {
  17782. xcb_tmp += uintptr(xcb_pad)
  17783. xcb_pad = uint32(0)
  17784. }
  17785. xcb_block_len = uint32(0)
  17786. return libc.Int32FromUint32(xcb_buffer_len)
  17787. }
  17788. func Xxcb_store_named_color_checked(tls *libc.TLS, c uintptr, flags Tuint8_t, cmap Txcb_colormap_t, pixel Tuint32_t, name_len Tuint16_t, name uintptr) (r Txcb_void_cookie_t) {
  17789. bp := tls.Alloc(112)
  17790. defer tls.Free(112)
  17791. var xcb_ret Txcb_void_cookie_t
  17792. var _ /* xcb_out at bp+96 */ Txcb_store_named_color_request_t
  17793. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  17794. _ = xcb_ret
  17795. (*(*Txcb_store_named_color_request_t)(unsafe.Pointer(bp + 96))).Fflags = flags
  17796. (*(*Txcb_store_named_color_request_t)(unsafe.Pointer(bp + 96))).Fcmap = cmap
  17797. (*(*Txcb_store_named_color_request_t)(unsafe.Pointer(bp + 96))).Fpixel = pixel
  17798. (*(*Txcb_store_named_color_request_t)(unsafe.Pointer(bp + 96))).Fname_len = name_len
  17799. libc.Xmemset(tls, bp+96+14, 0, uint64(2))
  17800. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  17801. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  17802. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17803. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17804. /* char name */
  17805. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = name
  17806. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(name_len) * uint64(1)
  17807. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  17808. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  17809. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req188)))
  17810. return xcb_ret
  17811. }
  17812. var _xcb_req188 = Txcb_protocol_request_t{
  17813. Fcount: uint64(4),
  17814. Fopcode: uint8(m_XCB_STORE_NAMED_COLOR),
  17815. Fisvoid: uint8(1),
  17816. }
  17817. func Xxcb_store_named_color(tls *libc.TLS, c uintptr, flags Tuint8_t, cmap Txcb_colormap_t, pixel Tuint32_t, name_len Tuint16_t, name uintptr) (r Txcb_void_cookie_t) {
  17818. bp := tls.Alloc(112)
  17819. defer tls.Free(112)
  17820. var xcb_ret Txcb_void_cookie_t
  17821. var _ /* xcb_out at bp+96 */ Txcb_store_named_color_request_t
  17822. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  17823. _ = xcb_ret
  17824. (*(*Txcb_store_named_color_request_t)(unsafe.Pointer(bp + 96))).Fflags = flags
  17825. (*(*Txcb_store_named_color_request_t)(unsafe.Pointer(bp + 96))).Fcmap = cmap
  17826. (*(*Txcb_store_named_color_request_t)(unsafe.Pointer(bp + 96))).Fpixel = pixel
  17827. (*(*Txcb_store_named_color_request_t)(unsafe.Pointer(bp + 96))).Fname_len = name_len
  17828. libc.Xmemset(tls, bp+96+14, 0, uint64(2))
  17829. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  17830. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(16)
  17831. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17832. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17833. /* char name */
  17834. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = name
  17835. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(name_len) * uint64(1)
  17836. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  17837. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  17838. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req189)))
  17839. return xcb_ret
  17840. }
  17841. var _xcb_req189 = Txcb_protocol_request_t{
  17842. Fcount: uint64(4),
  17843. Fopcode: uint8(m_XCB_STORE_NAMED_COLOR),
  17844. Fisvoid: uint8(1),
  17845. }
  17846. func Xxcb_store_named_color_name(tls *libc.TLS, R uintptr) (r uintptr) {
  17847. return R + libc.UintptrFromInt32(1)*16
  17848. }
  17849. func Xxcb_store_named_color_name_length(tls *libc.TLS, R uintptr) (r int32) {
  17850. return libc.Int32FromUint16((*Txcb_store_named_color_request_t)(unsafe.Pointer(R)).Fname_len)
  17851. }
  17852. func Xxcb_store_named_color_name_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  17853. var i Txcb_generic_iterator_t
  17854. _ = i
  17855. i.Fdata = R + libc.UintptrFromInt32(1)*16 + uintptr((*Txcb_store_named_color_request_t)(unsafe.Pointer(R)).Fname_len)
  17856. i.Frem = 0
  17857. i.Findex = int32(int64(i.Fdata) - int64(R))
  17858. return i
  17859. }
  17860. func Xxcb_rgb_next(tls *libc.TLS, i uintptr) {
  17861. var p1 uintptr
  17862. _ = p1
  17863. (*Txcb_rgb_iterator_t)(unsafe.Pointer(i)).Frem--
  17864. (*Txcb_rgb_iterator_t)(unsafe.Pointer(i)).Fdata += 8
  17865. p1 = i + 12
  17866. *(*int32)(unsafe.Pointer(p1)) = int32(uint64(*(*int32)(unsafe.Pointer(p1))) + libc.Uint64FromInt64(8))
  17867. }
  17868. func Xxcb_rgb_end(tls *libc.TLS, i Txcb_rgb_iterator_t) (r Txcb_generic_iterator_t) {
  17869. var ret Txcb_generic_iterator_t
  17870. _ = ret
  17871. ret.Fdata = i.Fdata + uintptr(i.Frem)*8
  17872. ret.Findex = int32(int64(i.Findex) + (int64(ret.Fdata) - int64(i.Fdata)))
  17873. ret.Frem = 0
  17874. return ret
  17875. }
  17876. func Xxcb_query_colors_sizeof(tls *libc.TLS, _buffer uintptr, pixels_len Tuint32_t) (r int32) {
  17877. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  17878. var xcb_tmp uintptr
  17879. _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  17880. xcb_tmp = _buffer
  17881. xcb_buffer_len = uint32(0)
  17882. xcb_block_len = uint32(0)
  17883. xcb_pad = uint32(0)
  17884. xcb_align_to = uint32(0)
  17885. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(8))
  17886. xcb_tmp += uintptr(xcb_block_len)
  17887. xcb_buffer_len += xcb_block_len
  17888. xcb_block_len = uint32(0)
  17889. /* pixels */
  17890. xcb_block_len = uint32(uint64(xcb_block_len) + uint64(pixels_len)*libc.Uint64FromInt64(4))
  17891. xcb_tmp += uintptr(xcb_block_len)
  17892. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  17893. /* insert padding */
  17894. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  17895. xcb_buffer_len += xcb_block_len + xcb_pad
  17896. if uint32(0) != xcb_pad {
  17897. xcb_tmp += uintptr(xcb_pad)
  17898. xcb_pad = uint32(0)
  17899. }
  17900. xcb_block_len = uint32(0)
  17901. return libc.Int32FromUint32(xcb_buffer_len)
  17902. }
  17903. func Xxcb_query_colors(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t, pixels_len Tuint32_t, pixels uintptr) (r Txcb_query_colors_cookie_t) {
  17904. bp := tls.Alloc(112)
  17905. defer tls.Free(112)
  17906. var xcb_ret Txcb_query_colors_cookie_t
  17907. var _ /* xcb_out at bp+96 */ Txcb_query_colors_request_t
  17908. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  17909. _ = xcb_ret
  17910. (*(*Txcb_query_colors_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  17911. (*(*Txcb_query_colors_request_t)(unsafe.Pointer(bp + 96))).Fcmap = cmap
  17912. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  17913. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  17914. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17915. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17916. /* uint32_t pixels */
  17917. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = pixels
  17918. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(pixels_len) * uint64(4)
  17919. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  17920. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  17921. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req190)))
  17922. return xcb_ret
  17923. }
  17924. var _xcb_req190 = Txcb_protocol_request_t{
  17925. Fcount: uint64(4),
  17926. Fopcode: uint8(m_XCB_QUERY_COLORS),
  17927. }
  17928. func Xxcb_query_colors_unchecked(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t, pixels_len Tuint32_t, pixels uintptr) (r Txcb_query_colors_cookie_t) {
  17929. bp := tls.Alloc(112)
  17930. defer tls.Free(112)
  17931. var xcb_ret Txcb_query_colors_cookie_t
  17932. var _ /* xcb_out at bp+96 */ Txcb_query_colors_request_t
  17933. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  17934. _ = xcb_ret
  17935. (*(*Txcb_query_colors_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  17936. (*(*Txcb_query_colors_request_t)(unsafe.Pointer(bp + 96))).Fcmap = cmap
  17937. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  17938. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  17939. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  17940. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  17941. /* uint32_t pixels */
  17942. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = pixels
  17943. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(pixels_len) * uint64(4)
  17944. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  17945. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  17946. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req191)))
  17947. return xcb_ret
  17948. }
  17949. var _xcb_req191 = Txcb_protocol_request_t{
  17950. Fcount: uint64(4),
  17951. Fopcode: uint8(m_XCB_QUERY_COLORS),
  17952. }
  17953. func Xxcb_query_colors_colors(tls *libc.TLS, R uintptr) (r uintptr) {
  17954. return R + libc.UintptrFromInt32(1)*32
  17955. }
  17956. func Xxcb_query_colors_colors_length(tls *libc.TLS, R uintptr) (r int32) {
  17957. return libc.Int32FromUint16((*Txcb_query_colors_reply_t)(unsafe.Pointer(R)).Fcolors_len)
  17958. }
  17959. func Xxcb_query_colors_colors_iterator(tls *libc.TLS, R uintptr) (r Txcb_rgb_iterator_t) {
  17960. var i Txcb_rgb_iterator_t
  17961. _ = i
  17962. i.Fdata = R + libc.UintptrFromInt32(1)*32
  17963. i.Frem = libc.Int32FromUint16((*Txcb_query_colors_reply_t)(unsafe.Pointer(R)).Fcolors_len)
  17964. i.Findex = int32(int64(i.Fdata) - int64(R))
  17965. return i
  17966. }
  17967. func Xxcb_query_colors_reply(tls *libc.TLS, c uintptr, cookie Txcb_query_colors_cookie_t, e uintptr) (r uintptr) {
  17968. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  17969. }
  17970. func Xxcb_lookup_color_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  17971. var _aux, xcb_tmp uintptr
  17972. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  17973. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  17974. xcb_tmp = _buffer
  17975. _aux = _buffer
  17976. xcb_buffer_len = uint32(0)
  17977. xcb_block_len = uint32(0)
  17978. xcb_pad = uint32(0)
  17979. xcb_align_to = uint32(0)
  17980. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  17981. xcb_tmp += uintptr(xcb_block_len)
  17982. xcb_buffer_len += xcb_block_len
  17983. xcb_block_len = uint32(0)
  17984. /* name */
  17985. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_lookup_color_request_t)(unsafe.Pointer(_aux)).Fname_len)*libc.Uint64FromInt64(1))
  17986. xcb_tmp += uintptr(xcb_block_len)
  17987. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  17988. /* insert padding */
  17989. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  17990. xcb_buffer_len += xcb_block_len + xcb_pad
  17991. if uint32(0) != xcb_pad {
  17992. xcb_tmp += uintptr(xcb_pad)
  17993. xcb_pad = uint32(0)
  17994. }
  17995. xcb_block_len = uint32(0)
  17996. return libc.Int32FromUint32(xcb_buffer_len)
  17997. }
  17998. func Xxcb_lookup_color(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t, name_len Tuint16_t, name uintptr) (r Txcb_lookup_color_cookie_t) {
  17999. bp := tls.Alloc(112)
  18000. defer tls.Free(112)
  18001. var xcb_ret Txcb_lookup_color_cookie_t
  18002. var _ /* xcb_out at bp+96 */ Txcb_lookup_color_request_t
  18003. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  18004. _ = xcb_ret
  18005. (*(*Txcb_lookup_color_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  18006. (*(*Txcb_lookup_color_request_t)(unsafe.Pointer(bp + 96))).Fcmap = cmap
  18007. (*(*Txcb_lookup_color_request_t)(unsafe.Pointer(bp + 96))).Fname_len = name_len
  18008. libc.Xmemset(tls, bp+96+10, 0, uint64(2))
  18009. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  18010. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  18011. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18012. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18013. /* char name */
  18014. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = name
  18015. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(name_len) * uint64(1)
  18016. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  18017. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  18018. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req192)))
  18019. return xcb_ret
  18020. }
  18021. var _xcb_req192 = Txcb_protocol_request_t{
  18022. Fcount: uint64(4),
  18023. Fopcode: uint8(m_XCB_LOOKUP_COLOR),
  18024. }
  18025. func Xxcb_lookup_color_unchecked(tls *libc.TLS, c uintptr, cmap Txcb_colormap_t, name_len Tuint16_t, name uintptr) (r Txcb_lookup_color_cookie_t) {
  18026. bp := tls.Alloc(112)
  18027. defer tls.Free(112)
  18028. var xcb_ret Txcb_lookup_color_cookie_t
  18029. var _ /* xcb_out at bp+96 */ Txcb_lookup_color_request_t
  18030. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  18031. _ = xcb_ret
  18032. (*(*Txcb_lookup_color_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  18033. (*(*Txcb_lookup_color_request_t)(unsafe.Pointer(bp + 96))).Fcmap = cmap
  18034. (*(*Txcb_lookup_color_request_t)(unsafe.Pointer(bp + 96))).Fname_len = name_len
  18035. libc.Xmemset(tls, bp+96+10, 0, uint64(2))
  18036. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  18037. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  18038. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18039. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18040. /* char name */
  18041. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = name
  18042. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(name_len) * uint64(1)
  18043. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  18044. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  18045. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req193)))
  18046. return xcb_ret
  18047. }
  18048. var _xcb_req193 = Txcb_protocol_request_t{
  18049. Fcount: uint64(4),
  18050. Fopcode: uint8(m_XCB_LOOKUP_COLOR),
  18051. }
  18052. func Xxcb_lookup_color_reply(tls *libc.TLS, c uintptr, cookie Txcb_lookup_color_cookie_t, e uintptr) (r uintptr) {
  18053. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  18054. }
  18055. func Xxcb_create_cursor_checked(tls *libc.TLS, c uintptr, cid Txcb_cursor_t, source Txcb_pixmap_t, mask Txcb_pixmap_t, fore_red Tuint16_t, fore_green Tuint16_t, fore_blue Tuint16_t, back_red Tuint16_t, back_green Tuint16_t, back_blue Tuint16_t, x Tuint16_t, y Tuint16_t) (r Txcb_void_cookie_t) {
  18056. bp := tls.Alloc(96)
  18057. defer tls.Free(96)
  18058. var xcb_ret Txcb_void_cookie_t
  18059. var _ /* xcb_out at bp+64 */ Txcb_create_cursor_request_t
  18060. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  18061. _ = xcb_ret
  18062. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  18063. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fcid = cid
  18064. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fsource = source
  18065. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fmask = mask
  18066. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_red = fore_red
  18067. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_green = fore_green
  18068. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_blue = fore_blue
  18069. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_red = back_red
  18070. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_green = back_green
  18071. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_blue = back_blue
  18072. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fx = x
  18073. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fy = y
  18074. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  18075. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(32)
  18076. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18077. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18078. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req194)))
  18079. return xcb_ret
  18080. }
  18081. var _xcb_req194 = Txcb_protocol_request_t{
  18082. Fcount: uint64(2),
  18083. Fopcode: uint8(m_XCB_CREATE_CURSOR),
  18084. Fisvoid: uint8(1),
  18085. }
  18086. func Xxcb_create_cursor(tls *libc.TLS, c uintptr, cid Txcb_cursor_t, source Txcb_pixmap_t, mask Txcb_pixmap_t, fore_red Tuint16_t, fore_green Tuint16_t, fore_blue Tuint16_t, back_red Tuint16_t, back_green Tuint16_t, back_blue Tuint16_t, x Tuint16_t, y Tuint16_t) (r Txcb_void_cookie_t) {
  18087. bp := tls.Alloc(96)
  18088. defer tls.Free(96)
  18089. var xcb_ret Txcb_void_cookie_t
  18090. var _ /* xcb_out at bp+64 */ Txcb_create_cursor_request_t
  18091. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  18092. _ = xcb_ret
  18093. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  18094. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fcid = cid
  18095. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fsource = source
  18096. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fmask = mask
  18097. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_red = fore_red
  18098. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_green = fore_green
  18099. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_blue = fore_blue
  18100. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_red = back_red
  18101. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_green = back_green
  18102. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_blue = back_blue
  18103. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fx = x
  18104. (*(*Txcb_create_cursor_request_t)(unsafe.Pointer(bp + 64))).Fy = y
  18105. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  18106. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(32)
  18107. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18108. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18109. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req195)))
  18110. return xcb_ret
  18111. }
  18112. var _xcb_req195 = Txcb_protocol_request_t{
  18113. Fcount: uint64(2),
  18114. Fopcode: uint8(m_XCB_CREATE_CURSOR),
  18115. Fisvoid: uint8(1),
  18116. }
  18117. func Xxcb_create_glyph_cursor_checked(tls *libc.TLS, c uintptr, cid Txcb_cursor_t, source_font Txcb_font_t, mask_font Txcb_font_t, source_char Tuint16_t, mask_char Tuint16_t, fore_red Tuint16_t, fore_green Tuint16_t, fore_blue Tuint16_t, back_red Tuint16_t, back_green Tuint16_t, back_blue Tuint16_t) (r Txcb_void_cookie_t) {
  18118. bp := tls.Alloc(96)
  18119. defer tls.Free(96)
  18120. var xcb_ret Txcb_void_cookie_t
  18121. var _ /* xcb_out at bp+64 */ Txcb_create_glyph_cursor_request_t
  18122. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  18123. _ = xcb_ret
  18124. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  18125. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fcid = cid
  18126. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fsource_font = source_font
  18127. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fmask_font = mask_font
  18128. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fsource_char = source_char
  18129. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fmask_char = mask_char
  18130. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_red = fore_red
  18131. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_green = fore_green
  18132. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_blue = fore_blue
  18133. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_red = back_red
  18134. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_green = back_green
  18135. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_blue = back_blue
  18136. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  18137. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(32)
  18138. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18139. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18140. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req196)))
  18141. return xcb_ret
  18142. }
  18143. var _xcb_req196 = Txcb_protocol_request_t{
  18144. Fcount: uint64(2),
  18145. Fopcode: uint8(m_XCB_CREATE_GLYPH_CURSOR),
  18146. Fisvoid: uint8(1),
  18147. }
  18148. func Xxcb_create_glyph_cursor(tls *libc.TLS, c uintptr, cid Txcb_cursor_t, source_font Txcb_font_t, mask_font Txcb_font_t, source_char Tuint16_t, mask_char Tuint16_t, fore_red Tuint16_t, fore_green Tuint16_t, fore_blue Tuint16_t, back_red Tuint16_t, back_green Tuint16_t, back_blue Tuint16_t) (r Txcb_void_cookie_t) {
  18149. bp := tls.Alloc(96)
  18150. defer tls.Free(96)
  18151. var xcb_ret Txcb_void_cookie_t
  18152. var _ /* xcb_out at bp+64 */ Txcb_create_glyph_cursor_request_t
  18153. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  18154. _ = xcb_ret
  18155. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  18156. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fcid = cid
  18157. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fsource_font = source_font
  18158. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fmask_font = mask_font
  18159. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fsource_char = source_char
  18160. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fmask_char = mask_char
  18161. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_red = fore_red
  18162. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_green = fore_green
  18163. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_blue = fore_blue
  18164. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_red = back_red
  18165. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_green = back_green
  18166. (*(*Txcb_create_glyph_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_blue = back_blue
  18167. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  18168. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(32)
  18169. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18170. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18171. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req197)))
  18172. return xcb_ret
  18173. }
  18174. var _xcb_req197 = Txcb_protocol_request_t{
  18175. Fcount: uint64(2),
  18176. Fopcode: uint8(m_XCB_CREATE_GLYPH_CURSOR),
  18177. Fisvoid: uint8(1),
  18178. }
  18179. func Xxcb_free_cursor_checked(tls *libc.TLS, c uintptr, cursor Txcb_cursor_t) (r Txcb_void_cookie_t) {
  18180. bp := tls.Alloc(80)
  18181. defer tls.Free(80)
  18182. var xcb_ret Txcb_void_cookie_t
  18183. var _ /* xcb_out at bp+64 */ Txcb_free_cursor_request_t
  18184. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  18185. _ = xcb_ret
  18186. (*(*Txcb_free_cursor_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  18187. (*(*Txcb_free_cursor_request_t)(unsafe.Pointer(bp + 64))).Fcursor = cursor
  18188. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  18189. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  18190. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18191. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18192. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req198)))
  18193. return xcb_ret
  18194. }
  18195. var _xcb_req198 = Txcb_protocol_request_t{
  18196. Fcount: uint64(2),
  18197. Fopcode: uint8(m_XCB_FREE_CURSOR),
  18198. Fisvoid: uint8(1),
  18199. }
  18200. func Xxcb_free_cursor(tls *libc.TLS, c uintptr, cursor Txcb_cursor_t) (r Txcb_void_cookie_t) {
  18201. bp := tls.Alloc(80)
  18202. defer tls.Free(80)
  18203. var xcb_ret Txcb_void_cookie_t
  18204. var _ /* xcb_out at bp+64 */ Txcb_free_cursor_request_t
  18205. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  18206. _ = xcb_ret
  18207. (*(*Txcb_free_cursor_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  18208. (*(*Txcb_free_cursor_request_t)(unsafe.Pointer(bp + 64))).Fcursor = cursor
  18209. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  18210. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  18211. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18212. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18213. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req199)))
  18214. return xcb_ret
  18215. }
  18216. var _xcb_req199 = Txcb_protocol_request_t{
  18217. Fcount: uint64(2),
  18218. Fopcode: uint8(m_XCB_FREE_CURSOR),
  18219. Fisvoid: uint8(1),
  18220. }
  18221. func Xxcb_recolor_cursor_checked(tls *libc.TLS, c uintptr, cursor Txcb_cursor_t, fore_red Tuint16_t, fore_green Tuint16_t, fore_blue Tuint16_t, back_red Tuint16_t, back_green Tuint16_t, back_blue Tuint16_t) (r Txcb_void_cookie_t) {
  18222. bp := tls.Alloc(96)
  18223. defer tls.Free(96)
  18224. var xcb_ret Txcb_void_cookie_t
  18225. var _ /* xcb_out at bp+64 */ Txcb_recolor_cursor_request_t
  18226. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  18227. _ = xcb_ret
  18228. (*(*Txcb_recolor_cursor_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  18229. (*(*Txcb_recolor_cursor_request_t)(unsafe.Pointer(bp + 64))).Fcursor = cursor
  18230. (*(*Txcb_recolor_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_red = fore_red
  18231. (*(*Txcb_recolor_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_green = fore_green
  18232. (*(*Txcb_recolor_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_blue = fore_blue
  18233. (*(*Txcb_recolor_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_red = back_red
  18234. (*(*Txcb_recolor_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_green = back_green
  18235. (*(*Txcb_recolor_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_blue = back_blue
  18236. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  18237. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(20)
  18238. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18239. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18240. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req200)))
  18241. return xcb_ret
  18242. }
  18243. var _xcb_req200 = Txcb_protocol_request_t{
  18244. Fcount: uint64(2),
  18245. Fopcode: uint8(m_XCB_RECOLOR_CURSOR),
  18246. Fisvoid: uint8(1),
  18247. }
  18248. func Xxcb_recolor_cursor(tls *libc.TLS, c uintptr, cursor Txcb_cursor_t, fore_red Tuint16_t, fore_green Tuint16_t, fore_blue Tuint16_t, back_red Tuint16_t, back_green Tuint16_t, back_blue Tuint16_t) (r Txcb_void_cookie_t) {
  18249. bp := tls.Alloc(96)
  18250. defer tls.Free(96)
  18251. var xcb_ret Txcb_void_cookie_t
  18252. var _ /* xcb_out at bp+64 */ Txcb_recolor_cursor_request_t
  18253. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  18254. _ = xcb_ret
  18255. (*(*Txcb_recolor_cursor_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  18256. (*(*Txcb_recolor_cursor_request_t)(unsafe.Pointer(bp + 64))).Fcursor = cursor
  18257. (*(*Txcb_recolor_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_red = fore_red
  18258. (*(*Txcb_recolor_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_green = fore_green
  18259. (*(*Txcb_recolor_cursor_request_t)(unsafe.Pointer(bp + 64))).Ffore_blue = fore_blue
  18260. (*(*Txcb_recolor_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_red = back_red
  18261. (*(*Txcb_recolor_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_green = back_green
  18262. (*(*Txcb_recolor_cursor_request_t)(unsafe.Pointer(bp + 64))).Fback_blue = back_blue
  18263. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  18264. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(20)
  18265. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18266. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18267. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req201)))
  18268. return xcb_ret
  18269. }
  18270. var _xcb_req201 = Txcb_protocol_request_t{
  18271. Fcount: uint64(2),
  18272. Fopcode: uint8(m_XCB_RECOLOR_CURSOR),
  18273. Fisvoid: uint8(1),
  18274. }
  18275. func Xxcb_query_best_size(tls *libc.TLS, c uintptr, _class Tuint8_t, drawable Txcb_drawable_t, width Tuint16_t, height Tuint16_t) (r Txcb_query_best_size_cookie_t) {
  18276. bp := tls.Alloc(80)
  18277. defer tls.Free(80)
  18278. var xcb_ret Txcb_query_best_size_cookie_t
  18279. var _ /* xcb_out at bp+64 */ Txcb_query_best_size_request_t
  18280. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  18281. _ = xcb_ret
  18282. (*(*Txcb_query_best_size_request_t)(unsafe.Pointer(bp + 64))).F_class = _class
  18283. (*(*Txcb_query_best_size_request_t)(unsafe.Pointer(bp + 64))).Fdrawable = drawable
  18284. (*(*Txcb_query_best_size_request_t)(unsafe.Pointer(bp + 64))).Fwidth = width
  18285. (*(*Txcb_query_best_size_request_t)(unsafe.Pointer(bp + 64))).Fheight = height
  18286. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  18287. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  18288. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18289. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18290. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req202)))
  18291. return xcb_ret
  18292. }
  18293. var _xcb_req202 = Txcb_protocol_request_t{
  18294. Fcount: uint64(2),
  18295. Fopcode: uint8(m_XCB_QUERY_BEST_SIZE),
  18296. }
  18297. func Xxcb_query_best_size_unchecked(tls *libc.TLS, c uintptr, _class Tuint8_t, drawable Txcb_drawable_t, width Tuint16_t, height Tuint16_t) (r Txcb_query_best_size_cookie_t) {
  18298. bp := tls.Alloc(80)
  18299. defer tls.Free(80)
  18300. var xcb_ret Txcb_query_best_size_cookie_t
  18301. var _ /* xcb_out at bp+64 */ Txcb_query_best_size_request_t
  18302. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  18303. _ = xcb_ret
  18304. (*(*Txcb_query_best_size_request_t)(unsafe.Pointer(bp + 64))).F_class = _class
  18305. (*(*Txcb_query_best_size_request_t)(unsafe.Pointer(bp + 64))).Fdrawable = drawable
  18306. (*(*Txcb_query_best_size_request_t)(unsafe.Pointer(bp + 64))).Fwidth = width
  18307. (*(*Txcb_query_best_size_request_t)(unsafe.Pointer(bp + 64))).Fheight = height
  18308. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  18309. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  18310. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18311. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18312. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req203)))
  18313. return xcb_ret
  18314. }
  18315. var _xcb_req203 = Txcb_protocol_request_t{
  18316. Fcount: uint64(2),
  18317. Fopcode: uint8(m_XCB_QUERY_BEST_SIZE),
  18318. }
  18319. func Xxcb_query_best_size_reply(tls *libc.TLS, c uintptr, cookie Txcb_query_best_size_cookie_t, e uintptr) (r uintptr) {
  18320. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  18321. }
  18322. func Xxcb_query_extension_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  18323. var _aux, xcb_tmp uintptr
  18324. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  18325. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  18326. xcb_tmp = _buffer
  18327. _aux = _buffer
  18328. xcb_buffer_len = uint32(0)
  18329. xcb_block_len = uint32(0)
  18330. xcb_pad = uint32(0)
  18331. xcb_align_to = uint32(0)
  18332. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(8))
  18333. xcb_tmp += uintptr(xcb_block_len)
  18334. xcb_buffer_len += xcb_block_len
  18335. xcb_block_len = uint32(0)
  18336. /* name */
  18337. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_query_extension_request_t)(unsafe.Pointer(_aux)).Fname_len)*libc.Uint64FromInt64(1))
  18338. xcb_tmp += uintptr(xcb_block_len)
  18339. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  18340. /* insert padding */
  18341. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  18342. xcb_buffer_len += xcb_block_len + xcb_pad
  18343. if uint32(0) != xcb_pad {
  18344. xcb_tmp += uintptr(xcb_pad)
  18345. xcb_pad = uint32(0)
  18346. }
  18347. xcb_block_len = uint32(0)
  18348. return libc.Int32FromUint32(xcb_buffer_len)
  18349. }
  18350. func Xxcb_query_extension(tls *libc.TLS, c uintptr, name_len Tuint16_t, name uintptr) (r Txcb_query_extension_cookie_t) {
  18351. bp := tls.Alloc(112)
  18352. defer tls.Free(112)
  18353. var xcb_ret Txcb_query_extension_cookie_t
  18354. var _ /* xcb_out at bp+96 */ Txcb_query_extension_request_t
  18355. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  18356. _ = xcb_ret
  18357. (*(*Txcb_query_extension_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  18358. (*(*Txcb_query_extension_request_t)(unsafe.Pointer(bp + 96))).Fname_len = name_len
  18359. libc.Xmemset(tls, bp+96+6, 0, uint64(2))
  18360. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  18361. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  18362. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18363. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18364. /* char name */
  18365. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = name
  18366. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(name_len) * uint64(1)
  18367. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  18368. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  18369. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req204)))
  18370. return xcb_ret
  18371. }
  18372. var _xcb_req204 = Txcb_protocol_request_t{
  18373. Fcount: uint64(4),
  18374. Fopcode: uint8(m_XCB_QUERY_EXTENSION),
  18375. }
  18376. func Xxcb_query_extension_unchecked(tls *libc.TLS, c uintptr, name_len Tuint16_t, name uintptr) (r Txcb_query_extension_cookie_t) {
  18377. bp := tls.Alloc(112)
  18378. defer tls.Free(112)
  18379. var xcb_ret Txcb_query_extension_cookie_t
  18380. var _ /* xcb_out at bp+96 */ Txcb_query_extension_request_t
  18381. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  18382. _ = xcb_ret
  18383. (*(*Txcb_query_extension_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  18384. (*(*Txcb_query_extension_request_t)(unsafe.Pointer(bp + 96))).Fname_len = name_len
  18385. libc.Xmemset(tls, bp+96+6, 0, uint64(2))
  18386. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  18387. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  18388. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18389. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18390. /* char name */
  18391. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = name
  18392. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(name_len) * uint64(1)
  18393. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  18394. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  18395. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req205)))
  18396. return xcb_ret
  18397. }
  18398. var _xcb_req205 = Txcb_protocol_request_t{
  18399. Fcount: uint64(4),
  18400. Fopcode: uint8(m_XCB_QUERY_EXTENSION),
  18401. }
  18402. func Xxcb_query_extension_reply(tls *libc.TLS, c uintptr, cookie Txcb_query_extension_cookie_t, e uintptr) (r uintptr) {
  18403. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  18404. }
  18405. func Xxcb_list_extensions_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  18406. var _aux, xcb_tmp uintptr
  18407. var i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp_len uint32
  18408. _, _, _, _, _, _, _, _ = _aux, i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp, xcb_tmp_len
  18409. xcb_tmp = _buffer
  18410. _aux = _buffer
  18411. xcb_buffer_len = uint32(0)
  18412. xcb_block_len = uint32(0)
  18413. xcb_pad = uint32(0)
  18414. xcb_align_to = uint32(0)
  18415. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(32))
  18416. xcb_tmp += uintptr(xcb_block_len)
  18417. xcb_buffer_len += xcb_block_len
  18418. xcb_block_len = uint32(0)
  18419. /* names */
  18420. i = uint32(0)
  18421. for {
  18422. if !(i < uint32((*Txcb_list_extensions_reply_t)(unsafe.Pointer(_aux)).Fnames_len)) {
  18423. break
  18424. }
  18425. xcb_tmp_len = libc.Uint32FromInt32(Xxcb_str_sizeof(tls, xcb_tmp))
  18426. xcb_block_len += xcb_tmp_len
  18427. xcb_tmp += uintptr(xcb_tmp_len)
  18428. goto _1
  18429. _1:
  18430. ;
  18431. i++
  18432. }
  18433. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  18434. /* insert padding */
  18435. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  18436. xcb_buffer_len += xcb_block_len + xcb_pad
  18437. if uint32(0) != xcb_pad {
  18438. xcb_tmp += uintptr(xcb_pad)
  18439. xcb_pad = uint32(0)
  18440. }
  18441. xcb_block_len = uint32(0)
  18442. return libc.Int32FromUint32(xcb_buffer_len)
  18443. }
  18444. func Xxcb_list_extensions(tls *libc.TLS, c uintptr) (r Txcb_list_extensions_cookie_t) {
  18445. bp := tls.Alloc(80)
  18446. defer tls.Free(80)
  18447. var xcb_ret Txcb_list_extensions_cookie_t
  18448. var _ /* xcb_out at bp+64 */ Txcb_list_extensions_request_t
  18449. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  18450. _ = xcb_ret
  18451. (*(*Txcb_list_extensions_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  18452. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  18453. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  18454. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18455. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18456. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req206)))
  18457. return xcb_ret
  18458. }
  18459. var _xcb_req206 = Txcb_protocol_request_t{
  18460. Fcount: uint64(2),
  18461. Fopcode: uint8(m_XCB_LIST_EXTENSIONS),
  18462. }
  18463. func Xxcb_list_extensions_unchecked(tls *libc.TLS, c uintptr) (r Txcb_list_extensions_cookie_t) {
  18464. bp := tls.Alloc(80)
  18465. defer tls.Free(80)
  18466. var xcb_ret Txcb_list_extensions_cookie_t
  18467. var _ /* xcb_out at bp+64 */ Txcb_list_extensions_request_t
  18468. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  18469. _ = xcb_ret
  18470. (*(*Txcb_list_extensions_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  18471. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  18472. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  18473. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18474. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18475. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req207)))
  18476. return xcb_ret
  18477. }
  18478. var _xcb_req207 = Txcb_protocol_request_t{
  18479. Fcount: uint64(2),
  18480. Fopcode: uint8(m_XCB_LIST_EXTENSIONS),
  18481. }
  18482. func Xxcb_list_extensions_names_length(tls *libc.TLS, R uintptr) (r int32) {
  18483. return libc.Int32FromUint8((*Txcb_list_extensions_reply_t)(unsafe.Pointer(R)).Fnames_len)
  18484. }
  18485. func Xxcb_list_extensions_names_iterator(tls *libc.TLS, R uintptr) (r Txcb_str_iterator_t) {
  18486. var i Txcb_str_iterator_t
  18487. _ = i
  18488. i.Fdata = R + libc.UintptrFromInt32(1)*32
  18489. i.Frem = libc.Int32FromUint8((*Txcb_list_extensions_reply_t)(unsafe.Pointer(R)).Fnames_len)
  18490. i.Findex = int32(int64(i.Fdata) - int64(R))
  18491. return i
  18492. }
  18493. func Xxcb_list_extensions_reply(tls *libc.TLS, c uintptr, cookie Txcb_list_extensions_cookie_t, e uintptr) (r uintptr) {
  18494. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  18495. }
  18496. func Xxcb_change_keyboard_mapping_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  18497. var _aux, xcb_tmp uintptr
  18498. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  18499. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  18500. xcb_tmp = _buffer
  18501. _aux = _buffer
  18502. xcb_buffer_len = uint32(0)
  18503. xcb_block_len = uint32(0)
  18504. xcb_pad = uint32(0)
  18505. xcb_align_to = uint32(0)
  18506. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(8))
  18507. xcb_tmp += uintptr(xcb_block_len)
  18508. xcb_buffer_len += xcb_block_len
  18509. xcb_block_len = uint32(0)
  18510. /* keysyms */
  18511. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt32(libc.Int32FromUint8((*Txcb_change_keyboard_mapping_request_t)(unsafe.Pointer(_aux)).Fkeycode_count)*libc.Int32FromUint8((*Txcb_change_keyboard_mapping_request_t)(unsafe.Pointer(_aux)).Fkeysyms_per_keycode))*libc.Uint64FromInt64(4))
  18512. xcb_tmp += uintptr(xcb_block_len)
  18513. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18514. /* insert padding */
  18515. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  18516. xcb_buffer_len += xcb_block_len + xcb_pad
  18517. if uint32(0) != xcb_pad {
  18518. xcb_tmp += uintptr(xcb_pad)
  18519. xcb_pad = uint32(0)
  18520. }
  18521. xcb_block_len = uint32(0)
  18522. return libc.Int32FromUint32(xcb_buffer_len)
  18523. }
  18524. func Xxcb_change_keyboard_mapping_checked(tls *libc.TLS, c uintptr, keycode_count Tuint8_t, first_keycode Txcb_keycode_t, keysyms_per_keycode Tuint8_t, keysyms uintptr) (r Txcb_void_cookie_t) {
  18525. bp := tls.Alloc(112)
  18526. defer tls.Free(112)
  18527. var xcb_ret Txcb_void_cookie_t
  18528. var _ /* xcb_out at bp+96 */ Txcb_change_keyboard_mapping_request_t
  18529. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  18530. _ = xcb_ret
  18531. (*(*Txcb_change_keyboard_mapping_request_t)(unsafe.Pointer(bp + 96))).Fkeycode_count = keycode_count
  18532. (*(*Txcb_change_keyboard_mapping_request_t)(unsafe.Pointer(bp + 96))).Ffirst_keycode = first_keycode
  18533. (*(*Txcb_change_keyboard_mapping_request_t)(unsafe.Pointer(bp + 96))).Fkeysyms_per_keycode = keysyms_per_keycode
  18534. libc.Xmemset(tls, bp+96+6, 0, uint64(2))
  18535. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  18536. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  18537. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18538. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18539. /* xcb_keysym_t keysyms */
  18540. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = keysyms
  18541. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(libc.Int32FromUint8(keycode_count)*libc.Int32FromUint8(keysyms_per_keycode)) * uint64(4)
  18542. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  18543. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  18544. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req208)))
  18545. return xcb_ret
  18546. }
  18547. var _xcb_req208 = Txcb_protocol_request_t{
  18548. Fcount: uint64(4),
  18549. Fopcode: uint8(m_XCB_CHANGE_KEYBOARD_MAPPING),
  18550. Fisvoid: uint8(1),
  18551. }
  18552. func Xxcb_change_keyboard_mapping(tls *libc.TLS, c uintptr, keycode_count Tuint8_t, first_keycode Txcb_keycode_t, keysyms_per_keycode Tuint8_t, keysyms uintptr) (r Txcb_void_cookie_t) {
  18553. bp := tls.Alloc(112)
  18554. defer tls.Free(112)
  18555. var xcb_ret Txcb_void_cookie_t
  18556. var _ /* xcb_out at bp+96 */ Txcb_change_keyboard_mapping_request_t
  18557. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  18558. _ = xcb_ret
  18559. (*(*Txcb_change_keyboard_mapping_request_t)(unsafe.Pointer(bp + 96))).Fkeycode_count = keycode_count
  18560. (*(*Txcb_change_keyboard_mapping_request_t)(unsafe.Pointer(bp + 96))).Ffirst_keycode = first_keycode
  18561. (*(*Txcb_change_keyboard_mapping_request_t)(unsafe.Pointer(bp + 96))).Fkeysyms_per_keycode = keysyms_per_keycode
  18562. libc.Xmemset(tls, bp+96+6, 0, uint64(2))
  18563. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  18564. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  18565. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18566. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18567. /* xcb_keysym_t keysyms */
  18568. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = keysyms
  18569. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(libc.Int32FromUint8(keycode_count)*libc.Int32FromUint8(keysyms_per_keycode)) * uint64(4)
  18570. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  18571. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  18572. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req209)))
  18573. return xcb_ret
  18574. }
  18575. var _xcb_req209 = Txcb_protocol_request_t{
  18576. Fcount: uint64(4),
  18577. Fopcode: uint8(m_XCB_CHANGE_KEYBOARD_MAPPING),
  18578. Fisvoid: uint8(1),
  18579. }
  18580. func Xxcb_change_keyboard_mapping_keysyms(tls *libc.TLS, R uintptr) (r uintptr) {
  18581. return R + libc.UintptrFromInt32(1)*8
  18582. }
  18583. func Xxcb_change_keyboard_mapping_keysyms_length(tls *libc.TLS, R uintptr) (r int32) {
  18584. return libc.Int32FromUint8((*Txcb_change_keyboard_mapping_request_t)(unsafe.Pointer(R)).Fkeycode_count) * libc.Int32FromUint8((*Txcb_change_keyboard_mapping_request_t)(unsafe.Pointer(R)).Fkeysyms_per_keycode)
  18585. }
  18586. func Xxcb_change_keyboard_mapping_keysyms_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  18587. var i Txcb_generic_iterator_t
  18588. _ = i
  18589. i.Fdata = R + libc.UintptrFromInt32(1)*8 + uintptr(libc.Int32FromUint8((*Txcb_change_keyboard_mapping_request_t)(unsafe.Pointer(R)).Fkeycode_count)*libc.Int32FromUint8((*Txcb_change_keyboard_mapping_request_t)(unsafe.Pointer(R)).Fkeysyms_per_keycode))*4
  18590. i.Frem = 0
  18591. i.Findex = int32(int64(i.Fdata) - int64(R))
  18592. return i
  18593. }
  18594. func Xxcb_get_keyboard_mapping_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  18595. var _aux, xcb_tmp uintptr
  18596. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  18597. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  18598. xcb_tmp = _buffer
  18599. _aux = _buffer
  18600. xcb_buffer_len = uint32(0)
  18601. xcb_block_len = uint32(0)
  18602. xcb_pad = uint32(0)
  18603. xcb_align_to = uint32(0)
  18604. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(32))
  18605. xcb_tmp += uintptr(xcb_block_len)
  18606. xcb_buffer_len += xcb_block_len
  18607. xcb_block_len = uint32(0)
  18608. /* keysyms */
  18609. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_get_keyboard_mapping_reply_t)(unsafe.Pointer(_aux)).Flength)*libc.Uint64FromInt64(4))
  18610. xcb_tmp += uintptr(xcb_block_len)
  18611. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18612. /* insert padding */
  18613. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  18614. xcb_buffer_len += xcb_block_len + xcb_pad
  18615. if uint32(0) != xcb_pad {
  18616. xcb_tmp += uintptr(xcb_pad)
  18617. xcb_pad = uint32(0)
  18618. }
  18619. xcb_block_len = uint32(0)
  18620. return libc.Int32FromUint32(xcb_buffer_len)
  18621. }
  18622. func Xxcb_get_keyboard_mapping(tls *libc.TLS, c uintptr, first_keycode Txcb_keycode_t, count Tuint8_t) (r Txcb_get_keyboard_mapping_cookie_t) {
  18623. bp := tls.Alloc(80)
  18624. defer tls.Free(80)
  18625. var xcb_ret Txcb_get_keyboard_mapping_cookie_t
  18626. var _ /* xcb_out at bp+66 */ Txcb_get_keyboard_mapping_request_t
  18627. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  18628. _ = xcb_ret
  18629. (*(*Txcb_get_keyboard_mapping_request_t)(unsafe.Pointer(bp + 66))).Fpad0 = uint8(0)
  18630. (*(*Txcb_get_keyboard_mapping_request_t)(unsafe.Pointer(bp + 66))).Ffirst_keycode = first_keycode
  18631. (*(*Txcb_get_keyboard_mapping_request_t)(unsafe.Pointer(bp + 66))).Fcount = count
  18632. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 66
  18633. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(6)
  18634. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18635. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18636. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req210)))
  18637. return xcb_ret
  18638. }
  18639. var _xcb_req210 = Txcb_protocol_request_t{
  18640. Fcount: uint64(2),
  18641. Fopcode: uint8(m_XCB_GET_KEYBOARD_MAPPING),
  18642. }
  18643. func Xxcb_get_keyboard_mapping_unchecked(tls *libc.TLS, c uintptr, first_keycode Txcb_keycode_t, count Tuint8_t) (r Txcb_get_keyboard_mapping_cookie_t) {
  18644. bp := tls.Alloc(80)
  18645. defer tls.Free(80)
  18646. var xcb_ret Txcb_get_keyboard_mapping_cookie_t
  18647. var _ /* xcb_out at bp+66 */ Txcb_get_keyboard_mapping_request_t
  18648. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  18649. _ = xcb_ret
  18650. (*(*Txcb_get_keyboard_mapping_request_t)(unsafe.Pointer(bp + 66))).Fpad0 = uint8(0)
  18651. (*(*Txcb_get_keyboard_mapping_request_t)(unsafe.Pointer(bp + 66))).Ffirst_keycode = first_keycode
  18652. (*(*Txcb_get_keyboard_mapping_request_t)(unsafe.Pointer(bp + 66))).Fcount = count
  18653. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 66
  18654. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(6)
  18655. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18656. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18657. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req211)))
  18658. return xcb_ret
  18659. }
  18660. var _xcb_req211 = Txcb_protocol_request_t{
  18661. Fcount: uint64(2),
  18662. Fopcode: uint8(m_XCB_GET_KEYBOARD_MAPPING),
  18663. }
  18664. func Xxcb_get_keyboard_mapping_keysyms(tls *libc.TLS, R uintptr) (r uintptr) {
  18665. return R + libc.UintptrFromInt32(1)*32
  18666. }
  18667. func Xxcb_get_keyboard_mapping_keysyms_length(tls *libc.TLS, R uintptr) (r int32) {
  18668. return libc.Int32FromUint32((*Txcb_get_keyboard_mapping_reply_t)(unsafe.Pointer(R)).Flength)
  18669. }
  18670. func Xxcb_get_keyboard_mapping_keysyms_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  18671. var i Txcb_generic_iterator_t
  18672. _ = i
  18673. i.Fdata = R + libc.UintptrFromInt32(1)*32 + uintptr((*Txcb_get_keyboard_mapping_reply_t)(unsafe.Pointer(R)).Flength)*4
  18674. i.Frem = 0
  18675. i.Findex = int32(int64(i.Fdata) - int64(R))
  18676. return i
  18677. }
  18678. func Xxcb_get_keyboard_mapping_reply(tls *libc.TLS, c uintptr, cookie Txcb_get_keyboard_mapping_cookie_t, e uintptr) (r uintptr) {
  18679. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  18680. }
  18681. func Xxcb_change_keyboard_control_value_list_serialize(tls *libc.TLS, _buffer uintptr, value_mask Tuint32_t, _aux uintptr) (r int32) {
  18682. bp := tls.Alloc(16)
  18683. defer tls.Free(16)
  18684. var i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset, xcb_parts_idx uint32
  18685. var xcb_out, xcb_tmp uintptr
  18686. var xcb_parts [9]Tiovec
  18687. var _ /* xcb_pad0 at bp+0 */ [3]int8
  18688. _, _, _, _, _, _, _, _, _, _ = i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_out, xcb_pad, xcb_padding_offset, xcb_parts, xcb_parts_idx, xcb_tmp
  18689. xcb_out = *(*uintptr)(unsafe.Pointer(_buffer))
  18690. xcb_buffer_len = uint32(0)
  18691. xcb_align_to = uint32(0)
  18692. xcb_padding_offset = uint32(0)
  18693. xcb_pad = uint32(0)
  18694. *(*[3]int8)(unsafe.Pointer(bp)) = [3]int8{}
  18695. xcb_parts_idx = uint32(0)
  18696. xcb_block_len = uint32(0)
  18697. if value_mask&uint32(_XCB_KB_KEY_CLICK_PERCENT) != 0 {
  18698. /* xcb_change_keyboard_control_value_list_t.key_click_percent */
  18699. xcb_parts[xcb_parts_idx].Fiov_base = _aux
  18700. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  18701. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  18702. xcb_parts_idx++
  18703. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18704. }
  18705. if value_mask&uint32(_XCB_KB_BELL_PERCENT) != 0 {
  18706. /* xcb_change_keyboard_control_value_list_t.bell_percent */
  18707. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 4
  18708. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  18709. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  18710. xcb_parts_idx++
  18711. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18712. }
  18713. if value_mask&uint32(_XCB_KB_BELL_PITCH) != 0 {
  18714. /* xcb_change_keyboard_control_value_list_t.bell_pitch */
  18715. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 8
  18716. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  18717. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  18718. xcb_parts_idx++
  18719. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18720. }
  18721. if value_mask&uint32(_XCB_KB_BELL_DURATION) != 0 {
  18722. /* xcb_change_keyboard_control_value_list_t.bell_duration */
  18723. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 12
  18724. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  18725. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  18726. xcb_parts_idx++
  18727. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18728. }
  18729. if value_mask&uint32(_XCB_KB_LED) != 0 {
  18730. /* xcb_change_keyboard_control_value_list_t.led */
  18731. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 16
  18732. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  18733. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  18734. xcb_parts_idx++
  18735. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18736. }
  18737. if value_mask&uint32(_XCB_KB_LED_MODE) != 0 {
  18738. /* xcb_change_keyboard_control_value_list_t.led_mode */
  18739. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 20
  18740. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  18741. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  18742. xcb_parts_idx++
  18743. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18744. }
  18745. if value_mask&uint32(_XCB_KB_KEY) != 0 {
  18746. /* xcb_change_keyboard_control_value_list_t.key */
  18747. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 24
  18748. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  18749. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  18750. xcb_parts_idx++
  18751. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18752. }
  18753. if value_mask&uint32(_XCB_KB_AUTO_REPEAT_MODE) != 0 {
  18754. /* xcb_change_keyboard_control_value_list_t.auto_repeat_mode */
  18755. xcb_parts[xcb_parts_idx].Fiov_base = _aux + 28
  18756. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  18757. xcb_parts[xcb_parts_idx].Fiov_len = uint64(4)
  18758. xcb_parts_idx++
  18759. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18760. }
  18761. /* insert padding */
  18762. xcb_pad = -(xcb_block_len + xcb_padding_offset) & (xcb_align_to - uint32(1))
  18763. xcb_buffer_len += xcb_block_len + xcb_pad
  18764. if uint32(0) != xcb_pad {
  18765. xcb_parts[xcb_parts_idx].Fiov_base = bp
  18766. xcb_parts[xcb_parts_idx].Fiov_len = uint64(xcb_pad)
  18767. xcb_parts_idx++
  18768. xcb_pad = uint32(0)
  18769. }
  18770. xcb_block_len = uint32(0)
  18771. xcb_padding_offset = uint32(0)
  18772. if libc.UintptrFromInt32(0) == xcb_out {
  18773. /* allocate memory */
  18774. xcb_out = libc.Xmalloc(tls, uint64(xcb_buffer_len))
  18775. *(*uintptr)(unsafe.Pointer(_buffer)) = xcb_out
  18776. }
  18777. xcb_tmp = xcb_out
  18778. i = uint32(0)
  18779. for {
  18780. if !(i < xcb_parts_idx) {
  18781. break
  18782. }
  18783. if uintptr(0) != xcb_parts[i].Fiov_base && uint64(0) != xcb_parts[i].Fiov_len {
  18784. libc.Xmemcpy(tls, xcb_tmp, xcb_parts[i].Fiov_base, xcb_parts[i].Fiov_len)
  18785. }
  18786. if uint64(0) != xcb_parts[i].Fiov_len {
  18787. xcb_tmp += uintptr(xcb_parts[i].Fiov_len)
  18788. }
  18789. goto _1
  18790. _1:
  18791. ;
  18792. i++
  18793. }
  18794. return libc.Int32FromUint32(xcb_buffer_len)
  18795. }
  18796. func Xxcb_change_keyboard_control_value_list_unpack(tls *libc.TLS, _buffer uintptr, value_mask Tuint32_t, _aux uintptr) (r int32) {
  18797. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset uint32
  18798. var xcb_tmp uintptr
  18799. _, _, _, _, _, _ = xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_padding_offset, xcb_tmp
  18800. xcb_tmp = _buffer
  18801. xcb_buffer_len = uint32(0)
  18802. xcb_block_len = uint32(0)
  18803. xcb_pad = uint32(0)
  18804. xcb_align_to = uint32(0)
  18805. xcb_padding_offset = uint32(0)
  18806. if value_mask&uint32(_XCB_KB_KEY_CLICK_PERCENT) != 0 {
  18807. /* xcb_change_keyboard_control_value_list_t.key_click_percent */
  18808. (*Txcb_change_keyboard_control_value_list_t)(unsafe.Pointer(_aux)).Fkey_click_percent = *(*Tint32_t)(unsafe.Pointer(xcb_tmp))
  18809. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  18810. xcb_tmp += uintptr(4)
  18811. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18812. }
  18813. if value_mask&uint32(_XCB_KB_BELL_PERCENT) != 0 {
  18814. /* xcb_change_keyboard_control_value_list_t.bell_percent */
  18815. (*Txcb_change_keyboard_control_value_list_t)(unsafe.Pointer(_aux)).Fbell_percent = *(*Tint32_t)(unsafe.Pointer(xcb_tmp))
  18816. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  18817. xcb_tmp += uintptr(4)
  18818. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18819. }
  18820. if value_mask&uint32(_XCB_KB_BELL_PITCH) != 0 {
  18821. /* xcb_change_keyboard_control_value_list_t.bell_pitch */
  18822. (*Txcb_change_keyboard_control_value_list_t)(unsafe.Pointer(_aux)).Fbell_pitch = *(*Tint32_t)(unsafe.Pointer(xcb_tmp))
  18823. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  18824. xcb_tmp += uintptr(4)
  18825. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18826. }
  18827. if value_mask&uint32(_XCB_KB_BELL_DURATION) != 0 {
  18828. /* xcb_change_keyboard_control_value_list_t.bell_duration */
  18829. (*Txcb_change_keyboard_control_value_list_t)(unsafe.Pointer(_aux)).Fbell_duration = *(*Tint32_t)(unsafe.Pointer(xcb_tmp))
  18830. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  18831. xcb_tmp += uintptr(4)
  18832. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18833. }
  18834. if value_mask&uint32(_XCB_KB_LED) != 0 {
  18835. /* xcb_change_keyboard_control_value_list_t.led */
  18836. (*Txcb_change_keyboard_control_value_list_t)(unsafe.Pointer(_aux)).Fled = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  18837. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  18838. xcb_tmp += uintptr(4)
  18839. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18840. }
  18841. if value_mask&uint32(_XCB_KB_LED_MODE) != 0 {
  18842. /* xcb_change_keyboard_control_value_list_t.led_mode */
  18843. (*Txcb_change_keyboard_control_value_list_t)(unsafe.Pointer(_aux)).Fled_mode = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  18844. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  18845. xcb_tmp += uintptr(4)
  18846. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18847. }
  18848. if value_mask&uint32(_XCB_KB_KEY) != 0 {
  18849. /* xcb_change_keyboard_control_value_list_t.key */
  18850. (*Txcb_change_keyboard_control_value_list_t)(unsafe.Pointer(_aux)).Fkey = *(*Txcb_keycode32_t)(unsafe.Pointer(xcb_tmp))
  18851. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  18852. xcb_tmp += uintptr(4)
  18853. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18854. }
  18855. if value_mask&uint32(_XCB_KB_AUTO_REPEAT_MODE) != 0 {
  18856. /* xcb_change_keyboard_control_value_list_t.auto_repeat_mode */
  18857. (*Txcb_change_keyboard_control_value_list_t)(unsafe.Pointer(_aux)).Fauto_repeat_mode = *(*Tuint32_t)(unsafe.Pointer(xcb_tmp))
  18858. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  18859. xcb_tmp += uintptr(4)
  18860. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  18861. }
  18862. /* insert padding */
  18863. xcb_pad = -(xcb_block_len + xcb_padding_offset) & (xcb_align_to - uint32(1))
  18864. xcb_buffer_len += xcb_block_len + xcb_pad
  18865. if uint32(0) != xcb_pad {
  18866. xcb_tmp += uintptr(xcb_pad)
  18867. xcb_pad = uint32(0)
  18868. }
  18869. xcb_block_len = uint32(0)
  18870. xcb_padding_offset = uint32(0)
  18871. return libc.Int32FromUint32(xcb_buffer_len)
  18872. }
  18873. func Xxcb_change_keyboard_control_value_list_sizeof(tls *libc.TLS, _buffer uintptr, value_mask Tuint32_t) (r int32) {
  18874. bp := tls.Alloc(32)
  18875. defer tls.Free(32)
  18876. var _ /* _aux at bp+0 */ Txcb_change_keyboard_control_value_list_t
  18877. return Xxcb_change_keyboard_control_value_list_unpack(tls, _buffer, value_mask, bp)
  18878. }
  18879. func Xxcb_change_keyboard_control_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  18880. var _aux, xcb_tmp uintptr
  18881. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  18882. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  18883. xcb_tmp = _buffer
  18884. _aux = _buffer
  18885. xcb_buffer_len = uint32(0)
  18886. xcb_block_len = uint32(0)
  18887. xcb_pad = uint32(0)
  18888. xcb_align_to = uint32(0)
  18889. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(8))
  18890. xcb_tmp += uintptr(xcb_block_len)
  18891. xcb_buffer_len += xcb_block_len
  18892. xcb_block_len = uint32(0)
  18893. /* value_list */
  18894. xcb_block_len += libc.Uint32FromInt32(Xxcb_change_keyboard_control_value_list_sizeof(tls, xcb_tmp, (*Txcb_change_keyboard_control_request_t)(unsafe.Pointer(_aux)).Fvalue_mask))
  18895. xcb_tmp += uintptr(xcb_block_len)
  18896. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  18897. /* insert padding */
  18898. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  18899. xcb_buffer_len += xcb_block_len + xcb_pad
  18900. if uint32(0) != xcb_pad {
  18901. xcb_tmp += uintptr(xcb_pad)
  18902. xcb_pad = uint32(0)
  18903. }
  18904. xcb_block_len = uint32(0)
  18905. return libc.Int32FromUint32(xcb_buffer_len)
  18906. }
  18907. func Xxcb_change_keyboard_control_checked(tls *libc.TLS, c uintptr, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  18908. bp := tls.Alloc(96)
  18909. defer tls.Free(96)
  18910. var xcb_ret Txcb_void_cookie_t
  18911. var _ /* xcb_out at bp+80 */ Txcb_change_keyboard_control_request_t
  18912. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  18913. _ = xcb_ret
  18914. (*(*Txcb_change_keyboard_control_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  18915. (*(*Txcb_change_keyboard_control_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  18916. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  18917. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  18918. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18919. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18920. /* xcb_change_keyboard_control_value_list_t value_list */
  18921. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = value_list
  18922. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_change_keyboard_control_value_list_sizeof(tls, value_list, value_mask))
  18923. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req212)))
  18924. return xcb_ret
  18925. }
  18926. var _xcb_req212 = Txcb_protocol_request_t{
  18927. Fcount: uint64(3),
  18928. Fopcode: uint8(m_XCB_CHANGE_KEYBOARD_CONTROL),
  18929. Fisvoid: uint8(1),
  18930. }
  18931. func Xxcb_change_keyboard_control(tls *libc.TLS, c uintptr, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  18932. bp := tls.Alloc(96)
  18933. defer tls.Free(96)
  18934. var xcb_ret Txcb_void_cookie_t
  18935. var _ /* xcb_out at bp+80 */ Txcb_change_keyboard_control_request_t
  18936. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  18937. _ = xcb_ret
  18938. (*(*Txcb_change_keyboard_control_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  18939. (*(*Txcb_change_keyboard_control_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  18940. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  18941. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  18942. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18943. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18944. /* xcb_change_keyboard_control_value_list_t value_list */
  18945. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = value_list
  18946. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_change_keyboard_control_value_list_sizeof(tls, value_list, value_mask))
  18947. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req213)))
  18948. return xcb_ret
  18949. }
  18950. var _xcb_req213 = Txcb_protocol_request_t{
  18951. Fcount: uint64(3),
  18952. Fopcode: uint8(m_XCB_CHANGE_KEYBOARD_CONTROL),
  18953. Fisvoid: uint8(1),
  18954. }
  18955. func Xxcb_change_keyboard_control_aux_checked(tls *libc.TLS, c uintptr, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  18956. bp := tls.Alloc(96)
  18957. defer tls.Free(96)
  18958. var xcb_ret Txcb_void_cookie_t
  18959. var _ /* xcb_aux0 at bp+88 */ uintptr
  18960. var _ /* xcb_out at bp+80 */ Txcb_change_keyboard_control_request_t
  18961. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  18962. _ = xcb_ret
  18963. *(*uintptr)(unsafe.Pointer(bp + 88)) = uintptr(0)
  18964. (*(*Txcb_change_keyboard_control_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  18965. (*(*Txcb_change_keyboard_control_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  18966. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  18967. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  18968. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18969. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18970. /* xcb_change_keyboard_control_value_list_t value_list */
  18971. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_change_keyboard_control_value_list_serialize(tls, bp+88, value_mask, value_list))
  18972. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = *(*uintptr)(unsafe.Pointer(bp + 88))
  18973. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req214)))
  18974. libc.Xfree(tls, *(*uintptr)(unsafe.Pointer(bp + 88)))
  18975. return xcb_ret
  18976. }
  18977. var _xcb_req214 = Txcb_protocol_request_t{
  18978. Fcount: uint64(3),
  18979. Fopcode: uint8(m_XCB_CHANGE_KEYBOARD_CONTROL),
  18980. Fisvoid: uint8(1),
  18981. }
  18982. func Xxcb_change_keyboard_control_aux(tls *libc.TLS, c uintptr, value_mask Tuint32_t, value_list uintptr) (r Txcb_void_cookie_t) {
  18983. bp := tls.Alloc(96)
  18984. defer tls.Free(96)
  18985. var xcb_ret Txcb_void_cookie_t
  18986. var _ /* xcb_aux0 at bp+88 */ uintptr
  18987. var _ /* xcb_out at bp+80 */ Txcb_change_keyboard_control_request_t
  18988. var _ /* xcb_parts at bp+0 */ [5]Tiovec
  18989. _ = xcb_ret
  18990. *(*uintptr)(unsafe.Pointer(bp + 88)) = uintptr(0)
  18991. (*(*Txcb_change_keyboard_control_request_t)(unsafe.Pointer(bp + 80))).Fpad0 = uint8(0)
  18992. (*(*Txcb_change_keyboard_control_request_t)(unsafe.Pointer(bp + 80))).Fvalue_mask = value_mask
  18993. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 80
  18994. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  18995. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  18996. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  18997. /* xcb_change_keyboard_control_value_list_t value_list */
  18998. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(Xxcb_change_keyboard_control_value_list_serialize(tls, bp+88, value_mask, value_list))
  18999. (*(*[5]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = *(*uintptr)(unsafe.Pointer(bp + 88))
  19000. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req215)))
  19001. libc.Xfree(tls, *(*uintptr)(unsafe.Pointer(bp + 88)))
  19002. return xcb_ret
  19003. }
  19004. var _xcb_req215 = Txcb_protocol_request_t{
  19005. Fcount: uint64(3),
  19006. Fopcode: uint8(m_XCB_CHANGE_KEYBOARD_CONTROL),
  19007. Fisvoid: uint8(1),
  19008. }
  19009. func Xxcb_change_keyboard_control_value_list(tls *libc.TLS, R uintptr) (r uintptr) {
  19010. return R + libc.UintptrFromInt32(1)*8
  19011. }
  19012. func Xxcb_get_keyboard_control(tls *libc.TLS, c uintptr) (r Txcb_get_keyboard_control_cookie_t) {
  19013. bp := tls.Alloc(80)
  19014. defer tls.Free(80)
  19015. var xcb_ret Txcb_get_keyboard_control_cookie_t
  19016. var _ /* xcb_out at bp+64 */ Txcb_get_keyboard_control_request_t
  19017. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19018. _ = xcb_ret
  19019. (*(*Txcb_get_keyboard_control_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  19020. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19021. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19022. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19023. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19024. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req216)))
  19025. return xcb_ret
  19026. }
  19027. var _xcb_req216 = Txcb_protocol_request_t{
  19028. Fcount: uint64(2),
  19029. Fopcode: uint8(m_XCB_GET_KEYBOARD_CONTROL),
  19030. }
  19031. func Xxcb_get_keyboard_control_unchecked(tls *libc.TLS, c uintptr) (r Txcb_get_keyboard_control_cookie_t) {
  19032. bp := tls.Alloc(80)
  19033. defer tls.Free(80)
  19034. var xcb_ret Txcb_get_keyboard_control_cookie_t
  19035. var _ /* xcb_out at bp+64 */ Txcb_get_keyboard_control_request_t
  19036. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19037. _ = xcb_ret
  19038. (*(*Txcb_get_keyboard_control_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  19039. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19040. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19041. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19042. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19043. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req217)))
  19044. return xcb_ret
  19045. }
  19046. var _xcb_req217 = Txcb_protocol_request_t{
  19047. Fcount: uint64(2),
  19048. Fopcode: uint8(m_XCB_GET_KEYBOARD_CONTROL),
  19049. }
  19050. func Xxcb_get_keyboard_control_reply(tls *libc.TLS, c uintptr, cookie Txcb_get_keyboard_control_cookie_t, e uintptr) (r uintptr) {
  19051. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  19052. }
  19053. func Xxcb_bell_checked(tls *libc.TLS, c uintptr, percent Tint8_t) (r Txcb_void_cookie_t) {
  19054. bp := tls.Alloc(80)
  19055. defer tls.Free(80)
  19056. var xcb_ret Txcb_void_cookie_t
  19057. var _ /* xcb_out at bp+64 */ Txcb_bell_request_t
  19058. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19059. _ = xcb_ret
  19060. (*(*Txcb_bell_request_t)(unsafe.Pointer(bp + 64))).Fpercent = percent
  19061. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19062. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19063. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19064. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19065. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req218)))
  19066. return xcb_ret
  19067. }
  19068. var _xcb_req218 = Txcb_protocol_request_t{
  19069. Fcount: uint64(2),
  19070. Fopcode: uint8(m_XCB_BELL),
  19071. Fisvoid: uint8(1),
  19072. }
  19073. func Xxcb_bell(tls *libc.TLS, c uintptr, percent Tint8_t) (r Txcb_void_cookie_t) {
  19074. bp := tls.Alloc(80)
  19075. defer tls.Free(80)
  19076. var xcb_ret Txcb_void_cookie_t
  19077. var _ /* xcb_out at bp+64 */ Txcb_bell_request_t
  19078. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19079. _ = xcb_ret
  19080. (*(*Txcb_bell_request_t)(unsafe.Pointer(bp + 64))).Fpercent = percent
  19081. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19082. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19083. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19084. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19085. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req219)))
  19086. return xcb_ret
  19087. }
  19088. var _xcb_req219 = Txcb_protocol_request_t{
  19089. Fcount: uint64(2),
  19090. Fopcode: uint8(m_XCB_BELL),
  19091. Fisvoid: uint8(1),
  19092. }
  19093. func Xxcb_change_pointer_control_checked(tls *libc.TLS, c uintptr, acceleration_numerator Tint16_t, acceleration_denominator Tint16_t, threshold Tint16_t, do_acceleration Tuint8_t, do_threshold Tuint8_t) (r Txcb_void_cookie_t) {
  19094. bp := tls.Alloc(80)
  19095. defer tls.Free(80)
  19096. var xcb_ret Txcb_void_cookie_t
  19097. var _ /* xcb_out at bp+64 */ Txcb_change_pointer_control_request_t
  19098. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19099. _ = xcb_ret
  19100. (*(*Txcb_change_pointer_control_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  19101. (*(*Txcb_change_pointer_control_request_t)(unsafe.Pointer(bp + 64))).Facceleration_numerator = acceleration_numerator
  19102. (*(*Txcb_change_pointer_control_request_t)(unsafe.Pointer(bp + 64))).Facceleration_denominator = acceleration_denominator
  19103. (*(*Txcb_change_pointer_control_request_t)(unsafe.Pointer(bp + 64))).Fthreshold = threshold
  19104. (*(*Txcb_change_pointer_control_request_t)(unsafe.Pointer(bp + 64))).Fdo_acceleration = do_acceleration
  19105. (*(*Txcb_change_pointer_control_request_t)(unsafe.Pointer(bp + 64))).Fdo_threshold = do_threshold
  19106. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19107. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  19108. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19109. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19110. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req220)))
  19111. return xcb_ret
  19112. }
  19113. var _xcb_req220 = Txcb_protocol_request_t{
  19114. Fcount: uint64(2),
  19115. Fopcode: uint8(m_XCB_CHANGE_POINTER_CONTROL),
  19116. Fisvoid: uint8(1),
  19117. }
  19118. func Xxcb_change_pointer_control(tls *libc.TLS, c uintptr, acceleration_numerator Tint16_t, acceleration_denominator Tint16_t, threshold Tint16_t, do_acceleration Tuint8_t, do_threshold Tuint8_t) (r Txcb_void_cookie_t) {
  19119. bp := tls.Alloc(80)
  19120. defer tls.Free(80)
  19121. var xcb_ret Txcb_void_cookie_t
  19122. var _ /* xcb_out at bp+64 */ Txcb_change_pointer_control_request_t
  19123. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19124. _ = xcb_ret
  19125. (*(*Txcb_change_pointer_control_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  19126. (*(*Txcb_change_pointer_control_request_t)(unsafe.Pointer(bp + 64))).Facceleration_numerator = acceleration_numerator
  19127. (*(*Txcb_change_pointer_control_request_t)(unsafe.Pointer(bp + 64))).Facceleration_denominator = acceleration_denominator
  19128. (*(*Txcb_change_pointer_control_request_t)(unsafe.Pointer(bp + 64))).Fthreshold = threshold
  19129. (*(*Txcb_change_pointer_control_request_t)(unsafe.Pointer(bp + 64))).Fdo_acceleration = do_acceleration
  19130. (*(*Txcb_change_pointer_control_request_t)(unsafe.Pointer(bp + 64))).Fdo_threshold = do_threshold
  19131. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19132. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  19133. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19134. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19135. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req221)))
  19136. return xcb_ret
  19137. }
  19138. var _xcb_req221 = Txcb_protocol_request_t{
  19139. Fcount: uint64(2),
  19140. Fopcode: uint8(m_XCB_CHANGE_POINTER_CONTROL),
  19141. Fisvoid: uint8(1),
  19142. }
  19143. func Xxcb_get_pointer_control(tls *libc.TLS, c uintptr) (r Txcb_get_pointer_control_cookie_t) {
  19144. bp := tls.Alloc(80)
  19145. defer tls.Free(80)
  19146. var xcb_ret Txcb_get_pointer_control_cookie_t
  19147. var _ /* xcb_out at bp+64 */ Txcb_get_pointer_control_request_t
  19148. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19149. _ = xcb_ret
  19150. (*(*Txcb_get_pointer_control_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  19151. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19152. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19153. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19154. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19155. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req222)))
  19156. return xcb_ret
  19157. }
  19158. var _xcb_req222 = Txcb_protocol_request_t{
  19159. Fcount: uint64(2),
  19160. Fopcode: uint8(m_XCB_GET_POINTER_CONTROL),
  19161. }
  19162. func Xxcb_get_pointer_control_unchecked(tls *libc.TLS, c uintptr) (r Txcb_get_pointer_control_cookie_t) {
  19163. bp := tls.Alloc(80)
  19164. defer tls.Free(80)
  19165. var xcb_ret Txcb_get_pointer_control_cookie_t
  19166. var _ /* xcb_out at bp+64 */ Txcb_get_pointer_control_request_t
  19167. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19168. _ = xcb_ret
  19169. (*(*Txcb_get_pointer_control_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  19170. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19171. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19172. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19173. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19174. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req223)))
  19175. return xcb_ret
  19176. }
  19177. var _xcb_req223 = Txcb_protocol_request_t{
  19178. Fcount: uint64(2),
  19179. Fopcode: uint8(m_XCB_GET_POINTER_CONTROL),
  19180. }
  19181. func Xxcb_get_pointer_control_reply(tls *libc.TLS, c uintptr, cookie Txcb_get_pointer_control_cookie_t, e uintptr) (r uintptr) {
  19182. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  19183. }
  19184. func Xxcb_set_screen_saver_checked(tls *libc.TLS, c uintptr, timeout Tint16_t, interval Tint16_t, prefer_blanking Tuint8_t, allow_exposures Tuint8_t) (r Txcb_void_cookie_t) {
  19185. bp := tls.Alloc(80)
  19186. defer tls.Free(80)
  19187. var xcb_ret Txcb_void_cookie_t
  19188. var _ /* xcb_out at bp+64 */ Txcb_set_screen_saver_request_t
  19189. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19190. _ = xcb_ret
  19191. (*(*Txcb_set_screen_saver_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  19192. (*(*Txcb_set_screen_saver_request_t)(unsafe.Pointer(bp + 64))).Ftimeout = timeout
  19193. (*(*Txcb_set_screen_saver_request_t)(unsafe.Pointer(bp + 64))).Finterval = interval
  19194. (*(*Txcb_set_screen_saver_request_t)(unsafe.Pointer(bp + 64))).Fprefer_blanking = prefer_blanking
  19195. (*(*Txcb_set_screen_saver_request_t)(unsafe.Pointer(bp + 64))).Fallow_exposures = allow_exposures
  19196. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19197. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(10)
  19198. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19199. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19200. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req224)))
  19201. return xcb_ret
  19202. }
  19203. var _xcb_req224 = Txcb_protocol_request_t{
  19204. Fcount: uint64(2),
  19205. Fopcode: uint8(m_XCB_SET_SCREEN_SAVER),
  19206. Fisvoid: uint8(1),
  19207. }
  19208. func Xxcb_set_screen_saver(tls *libc.TLS, c uintptr, timeout Tint16_t, interval Tint16_t, prefer_blanking Tuint8_t, allow_exposures Tuint8_t) (r Txcb_void_cookie_t) {
  19209. bp := tls.Alloc(80)
  19210. defer tls.Free(80)
  19211. var xcb_ret Txcb_void_cookie_t
  19212. var _ /* xcb_out at bp+64 */ Txcb_set_screen_saver_request_t
  19213. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19214. _ = xcb_ret
  19215. (*(*Txcb_set_screen_saver_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  19216. (*(*Txcb_set_screen_saver_request_t)(unsafe.Pointer(bp + 64))).Ftimeout = timeout
  19217. (*(*Txcb_set_screen_saver_request_t)(unsafe.Pointer(bp + 64))).Finterval = interval
  19218. (*(*Txcb_set_screen_saver_request_t)(unsafe.Pointer(bp + 64))).Fprefer_blanking = prefer_blanking
  19219. (*(*Txcb_set_screen_saver_request_t)(unsafe.Pointer(bp + 64))).Fallow_exposures = allow_exposures
  19220. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19221. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(10)
  19222. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19223. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19224. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req225)))
  19225. return xcb_ret
  19226. }
  19227. var _xcb_req225 = Txcb_protocol_request_t{
  19228. Fcount: uint64(2),
  19229. Fopcode: uint8(m_XCB_SET_SCREEN_SAVER),
  19230. Fisvoid: uint8(1),
  19231. }
  19232. func Xxcb_get_screen_saver(tls *libc.TLS, c uintptr) (r Txcb_get_screen_saver_cookie_t) {
  19233. bp := tls.Alloc(80)
  19234. defer tls.Free(80)
  19235. var xcb_ret Txcb_get_screen_saver_cookie_t
  19236. var _ /* xcb_out at bp+64 */ Txcb_get_screen_saver_request_t
  19237. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19238. _ = xcb_ret
  19239. (*(*Txcb_get_screen_saver_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  19240. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19241. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19242. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19243. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19244. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req226)))
  19245. return xcb_ret
  19246. }
  19247. var _xcb_req226 = Txcb_protocol_request_t{
  19248. Fcount: uint64(2),
  19249. Fopcode: uint8(m_XCB_GET_SCREEN_SAVER),
  19250. }
  19251. func Xxcb_get_screen_saver_unchecked(tls *libc.TLS, c uintptr) (r Txcb_get_screen_saver_cookie_t) {
  19252. bp := tls.Alloc(80)
  19253. defer tls.Free(80)
  19254. var xcb_ret Txcb_get_screen_saver_cookie_t
  19255. var _ /* xcb_out at bp+64 */ Txcb_get_screen_saver_request_t
  19256. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19257. _ = xcb_ret
  19258. (*(*Txcb_get_screen_saver_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  19259. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19260. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19261. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19262. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19263. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req227)))
  19264. return xcb_ret
  19265. }
  19266. var _xcb_req227 = Txcb_protocol_request_t{
  19267. Fcount: uint64(2),
  19268. Fopcode: uint8(m_XCB_GET_SCREEN_SAVER),
  19269. }
  19270. func Xxcb_get_screen_saver_reply(tls *libc.TLS, c uintptr, cookie Txcb_get_screen_saver_cookie_t, e uintptr) (r uintptr) {
  19271. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  19272. }
  19273. func Xxcb_change_hosts_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  19274. var _aux, xcb_tmp uintptr
  19275. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  19276. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  19277. xcb_tmp = _buffer
  19278. _aux = _buffer
  19279. xcb_buffer_len = uint32(0)
  19280. xcb_block_len = uint32(0)
  19281. xcb_pad = uint32(0)
  19282. xcb_align_to = uint32(0)
  19283. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(8))
  19284. xcb_tmp += uintptr(xcb_block_len)
  19285. xcb_buffer_len += xcb_block_len
  19286. xcb_block_len = uint32(0)
  19287. /* address */
  19288. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_change_hosts_request_t)(unsafe.Pointer(_aux)).Faddress_len)*libc.Uint64FromInt64(1))
  19289. xcb_tmp += uintptr(xcb_block_len)
  19290. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  19291. /* insert padding */
  19292. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  19293. xcb_buffer_len += xcb_block_len + xcb_pad
  19294. if uint32(0) != xcb_pad {
  19295. xcb_tmp += uintptr(xcb_pad)
  19296. xcb_pad = uint32(0)
  19297. }
  19298. xcb_block_len = uint32(0)
  19299. return libc.Int32FromUint32(xcb_buffer_len)
  19300. }
  19301. func Xxcb_change_hosts_checked(tls *libc.TLS, c uintptr, mode Tuint8_t, family Tuint8_t, address_len Tuint16_t, address uintptr) (r Txcb_void_cookie_t) {
  19302. bp := tls.Alloc(112)
  19303. defer tls.Free(112)
  19304. var xcb_ret Txcb_void_cookie_t
  19305. var _ /* xcb_out at bp+96 */ Txcb_change_hosts_request_t
  19306. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  19307. _ = xcb_ret
  19308. (*(*Txcb_change_hosts_request_t)(unsafe.Pointer(bp + 96))).Fmode = mode
  19309. (*(*Txcb_change_hosts_request_t)(unsafe.Pointer(bp + 96))).Ffamily = family
  19310. (*(*Txcb_change_hosts_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  19311. (*(*Txcb_change_hosts_request_t)(unsafe.Pointer(bp + 96))).Faddress_len = address_len
  19312. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  19313. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  19314. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19315. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19316. /* uint8_t address */
  19317. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = address
  19318. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(address_len) * uint64(1)
  19319. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  19320. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  19321. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req228)))
  19322. return xcb_ret
  19323. }
  19324. var _xcb_req228 = Txcb_protocol_request_t{
  19325. Fcount: uint64(4),
  19326. Fopcode: uint8(m_XCB_CHANGE_HOSTS),
  19327. Fisvoid: uint8(1),
  19328. }
  19329. func Xxcb_change_hosts(tls *libc.TLS, c uintptr, mode Tuint8_t, family Tuint8_t, address_len Tuint16_t, address uintptr) (r Txcb_void_cookie_t) {
  19330. bp := tls.Alloc(112)
  19331. defer tls.Free(112)
  19332. var xcb_ret Txcb_void_cookie_t
  19333. var _ /* xcb_out at bp+96 */ Txcb_change_hosts_request_t
  19334. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  19335. _ = xcb_ret
  19336. (*(*Txcb_change_hosts_request_t)(unsafe.Pointer(bp + 96))).Fmode = mode
  19337. (*(*Txcb_change_hosts_request_t)(unsafe.Pointer(bp + 96))).Ffamily = family
  19338. (*(*Txcb_change_hosts_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  19339. (*(*Txcb_change_hosts_request_t)(unsafe.Pointer(bp + 96))).Faddress_len = address_len
  19340. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  19341. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  19342. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19343. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19344. /* uint8_t address */
  19345. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = address
  19346. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(address_len) * uint64(1)
  19347. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  19348. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  19349. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req229)))
  19350. return xcb_ret
  19351. }
  19352. var _xcb_req229 = Txcb_protocol_request_t{
  19353. Fcount: uint64(4),
  19354. Fopcode: uint8(m_XCB_CHANGE_HOSTS),
  19355. Fisvoid: uint8(1),
  19356. }
  19357. func Xxcb_change_hosts_address(tls *libc.TLS, R uintptr) (r uintptr) {
  19358. return R + libc.UintptrFromInt32(1)*8
  19359. }
  19360. func Xxcb_change_hosts_address_length(tls *libc.TLS, R uintptr) (r int32) {
  19361. return libc.Int32FromUint16((*Txcb_change_hosts_request_t)(unsafe.Pointer(R)).Faddress_len)
  19362. }
  19363. func Xxcb_change_hosts_address_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  19364. var i Txcb_generic_iterator_t
  19365. _ = i
  19366. i.Fdata = R + libc.UintptrFromInt32(1)*8 + uintptr((*Txcb_change_hosts_request_t)(unsafe.Pointer(R)).Faddress_len)
  19367. i.Frem = 0
  19368. i.Findex = int32(int64(i.Fdata) - int64(R))
  19369. return i
  19370. }
  19371. func Xxcb_host_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  19372. var _aux, xcb_tmp uintptr
  19373. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  19374. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  19375. xcb_tmp = _buffer
  19376. _aux = _buffer
  19377. xcb_buffer_len = uint32(0)
  19378. xcb_block_len = uint32(0)
  19379. xcb_pad = uint32(0)
  19380. xcb_align_to = uint32(0)
  19381. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  19382. xcb_tmp += uintptr(xcb_block_len)
  19383. xcb_buffer_len += xcb_block_len
  19384. xcb_block_len = uint32(0)
  19385. /* address */
  19386. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_host_t)(unsafe.Pointer(_aux)).Faddress_len)*libc.Uint64FromInt64(1))
  19387. xcb_tmp += uintptr(xcb_block_len)
  19388. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  19389. xcb_align_to = uint32(4)
  19390. /* insert padding */
  19391. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  19392. xcb_buffer_len += xcb_block_len + xcb_pad
  19393. if uint32(0) != xcb_pad {
  19394. xcb_tmp += uintptr(xcb_pad)
  19395. xcb_pad = uint32(0)
  19396. }
  19397. xcb_block_len = uint32(0)
  19398. /* insert padding */
  19399. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  19400. xcb_buffer_len += xcb_block_len + xcb_pad
  19401. if uint32(0) != xcb_pad {
  19402. xcb_tmp += uintptr(xcb_pad)
  19403. xcb_pad = uint32(0)
  19404. }
  19405. xcb_block_len = uint32(0)
  19406. return libc.Int32FromUint32(xcb_buffer_len)
  19407. }
  19408. func Xxcb_host_address(tls *libc.TLS, R uintptr) (r uintptr) {
  19409. return R + libc.UintptrFromInt32(1)*4
  19410. }
  19411. func Xxcb_host_address_length(tls *libc.TLS, R uintptr) (r int32) {
  19412. return libc.Int32FromUint16((*Txcb_host_t)(unsafe.Pointer(R)).Faddress_len)
  19413. }
  19414. func Xxcb_host_address_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  19415. var i Txcb_generic_iterator_t
  19416. _ = i
  19417. i.Fdata = R + libc.UintptrFromInt32(1)*4 + uintptr((*Txcb_host_t)(unsafe.Pointer(R)).Faddress_len)
  19418. i.Frem = 0
  19419. i.Findex = int32(int64(i.Fdata) - int64(R))
  19420. return i
  19421. }
  19422. func Xxcb_host_next(tls *libc.TLS, i uintptr) {
  19423. var R uintptr
  19424. var child Txcb_generic_iterator_t
  19425. _, _ = R, child
  19426. R = (*Txcb_host_iterator_t)(unsafe.Pointer(i)).Fdata
  19427. child.Fdata = R + uintptr(Xxcb_host_sizeof(tls, R))
  19428. (*Txcb_host_iterator_t)(unsafe.Pointer(i)).Findex = int32(int64(child.Fdata) - int64((*Txcb_host_iterator_t)(unsafe.Pointer(i)).Fdata))
  19429. (*Txcb_host_iterator_t)(unsafe.Pointer(i)).Frem--
  19430. (*Txcb_host_iterator_t)(unsafe.Pointer(i)).Fdata = child.Fdata
  19431. }
  19432. func Xxcb_host_end(tls *libc.TLS, _i Txcb_host_iterator_t) (r Txcb_generic_iterator_t) {
  19433. bp := tls.Alloc(16)
  19434. defer tls.Free(16)
  19435. *(*Txcb_host_iterator_t)(unsafe.Pointer(bp)) = _i
  19436. var ret Txcb_generic_iterator_t
  19437. _ = ret
  19438. for (*(*Txcb_host_iterator_t)(unsafe.Pointer(bp))).Frem > 0 {
  19439. Xxcb_host_next(tls, bp)
  19440. }
  19441. ret.Fdata = (*(*Txcb_host_iterator_t)(unsafe.Pointer(bp))).Fdata
  19442. ret.Frem = (*(*Txcb_host_iterator_t)(unsafe.Pointer(bp))).Frem
  19443. ret.Findex = (*(*Txcb_host_iterator_t)(unsafe.Pointer(bp))).Findex
  19444. return ret
  19445. }
  19446. func Xxcb_list_hosts_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  19447. var _aux, xcb_tmp uintptr
  19448. var i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp_len uint32
  19449. _, _, _, _, _, _, _, _ = _aux, i, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp, xcb_tmp_len
  19450. xcb_tmp = _buffer
  19451. _aux = _buffer
  19452. xcb_buffer_len = uint32(0)
  19453. xcb_block_len = uint32(0)
  19454. xcb_pad = uint32(0)
  19455. xcb_align_to = uint32(0)
  19456. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(32))
  19457. xcb_tmp += uintptr(xcb_block_len)
  19458. xcb_buffer_len += xcb_block_len
  19459. xcb_block_len = uint32(0)
  19460. /* hosts */
  19461. i = uint32(0)
  19462. for {
  19463. if !(i < uint32((*Txcb_list_hosts_reply_t)(unsafe.Pointer(_aux)).Fhosts_len)) {
  19464. break
  19465. }
  19466. xcb_tmp_len = libc.Uint32FromInt32(Xxcb_host_sizeof(tls, xcb_tmp))
  19467. xcb_block_len += xcb_tmp_len
  19468. xcb_tmp += uintptr(xcb_tmp_len)
  19469. goto _1
  19470. _1:
  19471. ;
  19472. i++
  19473. }
  19474. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 2))
  19475. /* insert padding */
  19476. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  19477. xcb_buffer_len += xcb_block_len + xcb_pad
  19478. if uint32(0) != xcb_pad {
  19479. xcb_tmp += uintptr(xcb_pad)
  19480. xcb_pad = uint32(0)
  19481. }
  19482. xcb_block_len = uint32(0)
  19483. return libc.Int32FromUint32(xcb_buffer_len)
  19484. }
  19485. func Xxcb_list_hosts(tls *libc.TLS, c uintptr) (r Txcb_list_hosts_cookie_t) {
  19486. bp := tls.Alloc(80)
  19487. defer tls.Free(80)
  19488. var xcb_ret Txcb_list_hosts_cookie_t
  19489. var _ /* xcb_out at bp+64 */ Txcb_list_hosts_request_t
  19490. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19491. _ = xcb_ret
  19492. (*(*Txcb_list_hosts_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  19493. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19494. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19495. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19496. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19497. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req230)))
  19498. return xcb_ret
  19499. }
  19500. var _xcb_req230 = Txcb_protocol_request_t{
  19501. Fcount: uint64(2),
  19502. Fopcode: uint8(m_XCB_LIST_HOSTS),
  19503. }
  19504. func Xxcb_list_hosts_unchecked(tls *libc.TLS, c uintptr) (r Txcb_list_hosts_cookie_t) {
  19505. bp := tls.Alloc(80)
  19506. defer tls.Free(80)
  19507. var xcb_ret Txcb_list_hosts_cookie_t
  19508. var _ /* xcb_out at bp+64 */ Txcb_list_hosts_request_t
  19509. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19510. _ = xcb_ret
  19511. (*(*Txcb_list_hosts_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  19512. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19513. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19514. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19515. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19516. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req231)))
  19517. return xcb_ret
  19518. }
  19519. var _xcb_req231 = Txcb_protocol_request_t{
  19520. Fcount: uint64(2),
  19521. Fopcode: uint8(m_XCB_LIST_HOSTS),
  19522. }
  19523. func Xxcb_list_hosts_hosts_length(tls *libc.TLS, R uintptr) (r int32) {
  19524. return libc.Int32FromUint16((*Txcb_list_hosts_reply_t)(unsafe.Pointer(R)).Fhosts_len)
  19525. }
  19526. func Xxcb_list_hosts_hosts_iterator(tls *libc.TLS, R uintptr) (r Txcb_host_iterator_t) {
  19527. var i Txcb_host_iterator_t
  19528. _ = i
  19529. i.Fdata = R + libc.UintptrFromInt32(1)*32
  19530. i.Frem = libc.Int32FromUint16((*Txcb_list_hosts_reply_t)(unsafe.Pointer(R)).Fhosts_len)
  19531. i.Findex = int32(int64(i.Fdata) - int64(R))
  19532. return i
  19533. }
  19534. func Xxcb_list_hosts_reply(tls *libc.TLS, c uintptr, cookie Txcb_list_hosts_cookie_t, e uintptr) (r uintptr) {
  19535. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  19536. }
  19537. func Xxcb_set_access_control_checked(tls *libc.TLS, c uintptr, mode Tuint8_t) (r Txcb_void_cookie_t) {
  19538. bp := tls.Alloc(80)
  19539. defer tls.Free(80)
  19540. var xcb_ret Txcb_void_cookie_t
  19541. var _ /* xcb_out at bp+64 */ Txcb_set_access_control_request_t
  19542. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19543. _ = xcb_ret
  19544. (*(*Txcb_set_access_control_request_t)(unsafe.Pointer(bp + 64))).Fmode = mode
  19545. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19546. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19547. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19548. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19549. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req232)))
  19550. return xcb_ret
  19551. }
  19552. var _xcb_req232 = Txcb_protocol_request_t{
  19553. Fcount: uint64(2),
  19554. Fopcode: uint8(m_XCB_SET_ACCESS_CONTROL),
  19555. Fisvoid: uint8(1),
  19556. }
  19557. func Xxcb_set_access_control(tls *libc.TLS, c uintptr, mode Tuint8_t) (r Txcb_void_cookie_t) {
  19558. bp := tls.Alloc(80)
  19559. defer tls.Free(80)
  19560. var xcb_ret Txcb_void_cookie_t
  19561. var _ /* xcb_out at bp+64 */ Txcb_set_access_control_request_t
  19562. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19563. _ = xcb_ret
  19564. (*(*Txcb_set_access_control_request_t)(unsafe.Pointer(bp + 64))).Fmode = mode
  19565. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19566. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19567. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19568. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19569. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req233)))
  19570. return xcb_ret
  19571. }
  19572. var _xcb_req233 = Txcb_protocol_request_t{
  19573. Fcount: uint64(2),
  19574. Fopcode: uint8(m_XCB_SET_ACCESS_CONTROL),
  19575. Fisvoid: uint8(1),
  19576. }
  19577. func Xxcb_set_close_down_mode_checked(tls *libc.TLS, c uintptr, mode Tuint8_t) (r Txcb_void_cookie_t) {
  19578. bp := tls.Alloc(80)
  19579. defer tls.Free(80)
  19580. var xcb_ret Txcb_void_cookie_t
  19581. var _ /* xcb_out at bp+64 */ Txcb_set_close_down_mode_request_t
  19582. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19583. _ = xcb_ret
  19584. (*(*Txcb_set_close_down_mode_request_t)(unsafe.Pointer(bp + 64))).Fmode = mode
  19585. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19586. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19587. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19588. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19589. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req234)))
  19590. return xcb_ret
  19591. }
  19592. var _xcb_req234 = Txcb_protocol_request_t{
  19593. Fcount: uint64(2),
  19594. Fopcode: uint8(m_XCB_SET_CLOSE_DOWN_MODE),
  19595. Fisvoid: uint8(1),
  19596. }
  19597. func Xxcb_set_close_down_mode(tls *libc.TLS, c uintptr, mode Tuint8_t) (r Txcb_void_cookie_t) {
  19598. bp := tls.Alloc(80)
  19599. defer tls.Free(80)
  19600. var xcb_ret Txcb_void_cookie_t
  19601. var _ /* xcb_out at bp+64 */ Txcb_set_close_down_mode_request_t
  19602. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19603. _ = xcb_ret
  19604. (*(*Txcb_set_close_down_mode_request_t)(unsafe.Pointer(bp + 64))).Fmode = mode
  19605. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19606. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19607. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19608. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19609. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req235)))
  19610. return xcb_ret
  19611. }
  19612. var _xcb_req235 = Txcb_protocol_request_t{
  19613. Fcount: uint64(2),
  19614. Fopcode: uint8(m_XCB_SET_CLOSE_DOWN_MODE),
  19615. Fisvoid: uint8(1),
  19616. }
  19617. func Xxcb_kill_client_checked(tls *libc.TLS, c uintptr, resource Tuint32_t) (r Txcb_void_cookie_t) {
  19618. bp := tls.Alloc(80)
  19619. defer tls.Free(80)
  19620. var xcb_ret Txcb_void_cookie_t
  19621. var _ /* xcb_out at bp+64 */ Txcb_kill_client_request_t
  19622. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19623. _ = xcb_ret
  19624. (*(*Txcb_kill_client_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  19625. (*(*Txcb_kill_client_request_t)(unsafe.Pointer(bp + 64))).Fresource = resource
  19626. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19627. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  19628. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19629. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19630. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req236)))
  19631. return xcb_ret
  19632. }
  19633. var _xcb_req236 = Txcb_protocol_request_t{
  19634. Fcount: uint64(2),
  19635. Fopcode: uint8(m_XCB_KILL_CLIENT),
  19636. Fisvoid: uint8(1),
  19637. }
  19638. func Xxcb_kill_client(tls *libc.TLS, c uintptr, resource Tuint32_t) (r Txcb_void_cookie_t) {
  19639. bp := tls.Alloc(80)
  19640. defer tls.Free(80)
  19641. var xcb_ret Txcb_void_cookie_t
  19642. var _ /* xcb_out at bp+64 */ Txcb_kill_client_request_t
  19643. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19644. _ = xcb_ret
  19645. (*(*Txcb_kill_client_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  19646. (*(*Txcb_kill_client_request_t)(unsafe.Pointer(bp + 64))).Fresource = resource
  19647. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19648. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  19649. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19650. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19651. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req237)))
  19652. return xcb_ret
  19653. }
  19654. var _xcb_req237 = Txcb_protocol_request_t{
  19655. Fcount: uint64(2),
  19656. Fopcode: uint8(m_XCB_KILL_CLIENT),
  19657. Fisvoid: uint8(1),
  19658. }
  19659. func Xxcb_rotate_properties_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  19660. var _aux, xcb_tmp uintptr
  19661. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  19662. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  19663. xcb_tmp = _buffer
  19664. _aux = _buffer
  19665. xcb_buffer_len = uint32(0)
  19666. xcb_block_len = uint32(0)
  19667. xcb_pad = uint32(0)
  19668. xcb_align_to = uint32(0)
  19669. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(12))
  19670. xcb_tmp += uintptr(xcb_block_len)
  19671. xcb_buffer_len += xcb_block_len
  19672. xcb_block_len = uint32(0)
  19673. /* atoms */
  19674. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_rotate_properties_request_t)(unsafe.Pointer(_aux)).Fatoms_len)*libc.Uint64FromInt64(4))
  19675. xcb_tmp += uintptr(xcb_block_len)
  19676. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  19677. /* insert padding */
  19678. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  19679. xcb_buffer_len += xcb_block_len + xcb_pad
  19680. if uint32(0) != xcb_pad {
  19681. xcb_tmp += uintptr(xcb_pad)
  19682. xcb_pad = uint32(0)
  19683. }
  19684. xcb_block_len = uint32(0)
  19685. return libc.Int32FromUint32(xcb_buffer_len)
  19686. }
  19687. func Xxcb_rotate_properties_checked(tls *libc.TLS, c uintptr, window Txcb_window_t, atoms_len Tuint16_t, delta Tint16_t, atoms uintptr) (r Txcb_void_cookie_t) {
  19688. bp := tls.Alloc(112)
  19689. defer tls.Free(112)
  19690. var xcb_ret Txcb_void_cookie_t
  19691. var _ /* xcb_out at bp+96 */ Txcb_rotate_properties_request_t
  19692. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  19693. _ = xcb_ret
  19694. (*(*Txcb_rotate_properties_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  19695. (*(*Txcb_rotate_properties_request_t)(unsafe.Pointer(bp + 96))).Fwindow = window
  19696. (*(*Txcb_rotate_properties_request_t)(unsafe.Pointer(bp + 96))).Fatoms_len = atoms_len
  19697. (*(*Txcb_rotate_properties_request_t)(unsafe.Pointer(bp + 96))).Fdelta = delta
  19698. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  19699. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  19700. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19701. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19702. /* xcb_atom_t atoms */
  19703. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = atoms
  19704. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(atoms_len) * uint64(4)
  19705. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  19706. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  19707. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req238)))
  19708. return xcb_ret
  19709. }
  19710. var _xcb_req238 = Txcb_protocol_request_t{
  19711. Fcount: uint64(4),
  19712. Fopcode: uint8(m_XCB_ROTATE_PROPERTIES),
  19713. Fisvoid: uint8(1),
  19714. }
  19715. func Xxcb_rotate_properties(tls *libc.TLS, c uintptr, window Txcb_window_t, atoms_len Tuint16_t, delta Tint16_t, atoms uintptr) (r Txcb_void_cookie_t) {
  19716. bp := tls.Alloc(112)
  19717. defer tls.Free(112)
  19718. var xcb_ret Txcb_void_cookie_t
  19719. var _ /* xcb_out at bp+96 */ Txcb_rotate_properties_request_t
  19720. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  19721. _ = xcb_ret
  19722. (*(*Txcb_rotate_properties_request_t)(unsafe.Pointer(bp + 96))).Fpad0 = uint8(0)
  19723. (*(*Txcb_rotate_properties_request_t)(unsafe.Pointer(bp + 96))).Fwindow = window
  19724. (*(*Txcb_rotate_properties_request_t)(unsafe.Pointer(bp + 96))).Fatoms_len = atoms_len
  19725. (*(*Txcb_rotate_properties_request_t)(unsafe.Pointer(bp + 96))).Fdelta = delta
  19726. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  19727. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(12)
  19728. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19729. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19730. /* xcb_atom_t atoms */
  19731. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = atoms
  19732. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(atoms_len) * uint64(4)
  19733. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  19734. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  19735. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req239)))
  19736. return xcb_ret
  19737. }
  19738. var _xcb_req239 = Txcb_protocol_request_t{
  19739. Fcount: uint64(4),
  19740. Fopcode: uint8(m_XCB_ROTATE_PROPERTIES),
  19741. Fisvoid: uint8(1),
  19742. }
  19743. func Xxcb_rotate_properties_atoms(tls *libc.TLS, R uintptr) (r uintptr) {
  19744. return R + libc.UintptrFromInt32(1)*12
  19745. }
  19746. func Xxcb_rotate_properties_atoms_length(tls *libc.TLS, R uintptr) (r int32) {
  19747. return libc.Int32FromUint16((*Txcb_rotate_properties_request_t)(unsafe.Pointer(R)).Fatoms_len)
  19748. }
  19749. func Xxcb_rotate_properties_atoms_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  19750. var i Txcb_generic_iterator_t
  19751. _ = i
  19752. i.Fdata = R + libc.UintptrFromInt32(1)*12 + uintptr((*Txcb_rotate_properties_request_t)(unsafe.Pointer(R)).Fatoms_len)*4
  19753. i.Frem = 0
  19754. i.Findex = int32(int64(i.Fdata) - int64(R))
  19755. return i
  19756. }
  19757. func Xxcb_force_screen_saver_checked(tls *libc.TLS, c uintptr, mode Tuint8_t) (r Txcb_void_cookie_t) {
  19758. bp := tls.Alloc(80)
  19759. defer tls.Free(80)
  19760. var xcb_ret Txcb_void_cookie_t
  19761. var _ /* xcb_out at bp+64 */ Txcb_force_screen_saver_request_t
  19762. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19763. _ = xcb_ret
  19764. (*(*Txcb_force_screen_saver_request_t)(unsafe.Pointer(bp + 64))).Fmode = mode
  19765. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19766. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19767. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19768. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19769. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req240)))
  19770. return xcb_ret
  19771. }
  19772. var _xcb_req240 = Txcb_protocol_request_t{
  19773. Fcount: uint64(2),
  19774. Fopcode: uint8(m_XCB_FORCE_SCREEN_SAVER),
  19775. Fisvoid: uint8(1),
  19776. }
  19777. func Xxcb_force_screen_saver(tls *libc.TLS, c uintptr, mode Tuint8_t) (r Txcb_void_cookie_t) {
  19778. bp := tls.Alloc(80)
  19779. defer tls.Free(80)
  19780. var xcb_ret Txcb_void_cookie_t
  19781. var _ /* xcb_out at bp+64 */ Txcb_force_screen_saver_request_t
  19782. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19783. _ = xcb_ret
  19784. (*(*Txcb_force_screen_saver_request_t)(unsafe.Pointer(bp + 64))).Fmode = mode
  19785. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19786. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19787. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19788. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19789. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req241)))
  19790. return xcb_ret
  19791. }
  19792. var _xcb_req241 = Txcb_protocol_request_t{
  19793. Fcount: uint64(2),
  19794. Fopcode: uint8(m_XCB_FORCE_SCREEN_SAVER),
  19795. Fisvoid: uint8(1),
  19796. }
  19797. func Xxcb_set_pointer_mapping_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  19798. var _aux, xcb_tmp uintptr
  19799. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  19800. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  19801. xcb_tmp = _buffer
  19802. _aux = _buffer
  19803. xcb_buffer_len = uint32(0)
  19804. xcb_block_len = uint32(0)
  19805. xcb_pad = uint32(0)
  19806. xcb_align_to = uint32(0)
  19807. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  19808. xcb_tmp += uintptr(xcb_block_len)
  19809. xcb_buffer_len += xcb_block_len
  19810. xcb_block_len = uint32(0)
  19811. /* map */
  19812. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_set_pointer_mapping_request_t)(unsafe.Pointer(_aux)).Fmap_len)*libc.Uint64FromInt64(1))
  19813. xcb_tmp += uintptr(xcb_block_len)
  19814. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  19815. /* insert padding */
  19816. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  19817. xcb_buffer_len += xcb_block_len + xcb_pad
  19818. if uint32(0) != xcb_pad {
  19819. xcb_tmp += uintptr(xcb_pad)
  19820. xcb_pad = uint32(0)
  19821. }
  19822. xcb_block_len = uint32(0)
  19823. return libc.Int32FromUint32(xcb_buffer_len)
  19824. }
  19825. func Xxcb_set_pointer_mapping(tls *libc.TLS, c uintptr, map_len Tuint8_t, map1 uintptr) (r Txcb_set_pointer_mapping_cookie_t) {
  19826. bp := tls.Alloc(112)
  19827. defer tls.Free(112)
  19828. var xcb_ret Txcb_set_pointer_mapping_cookie_t
  19829. var _ /* xcb_out at bp+96 */ Txcb_set_pointer_mapping_request_t
  19830. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  19831. _ = xcb_ret
  19832. (*(*Txcb_set_pointer_mapping_request_t)(unsafe.Pointer(bp + 96))).Fmap_len = map_len
  19833. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  19834. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19835. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19836. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19837. /* uint8_t map */
  19838. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = map1
  19839. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(map_len) * uint64(1)
  19840. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  19841. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  19842. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req242)))
  19843. return xcb_ret
  19844. }
  19845. var _xcb_req242 = Txcb_protocol_request_t{
  19846. Fcount: uint64(4),
  19847. Fopcode: uint8(m_XCB_SET_POINTER_MAPPING),
  19848. }
  19849. func Xxcb_set_pointer_mapping_unchecked(tls *libc.TLS, c uintptr, map_len Tuint8_t, map1 uintptr) (r Txcb_set_pointer_mapping_cookie_t) {
  19850. bp := tls.Alloc(112)
  19851. defer tls.Free(112)
  19852. var xcb_ret Txcb_set_pointer_mapping_cookie_t
  19853. var _ /* xcb_out at bp+96 */ Txcb_set_pointer_mapping_request_t
  19854. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  19855. _ = xcb_ret
  19856. (*(*Txcb_set_pointer_mapping_request_t)(unsafe.Pointer(bp + 96))).Fmap_len = map_len
  19857. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  19858. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19859. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19860. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19861. /* uint8_t map */
  19862. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = map1
  19863. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = uint64(map_len) * uint64(1)
  19864. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  19865. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  19866. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req243)))
  19867. return xcb_ret
  19868. }
  19869. var _xcb_req243 = Txcb_protocol_request_t{
  19870. Fcount: uint64(4),
  19871. Fopcode: uint8(m_XCB_SET_POINTER_MAPPING),
  19872. }
  19873. func Xxcb_set_pointer_mapping_reply(tls *libc.TLS, c uintptr, cookie Txcb_set_pointer_mapping_cookie_t, e uintptr) (r uintptr) {
  19874. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  19875. }
  19876. func Xxcb_get_pointer_mapping_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  19877. var _aux, xcb_tmp uintptr
  19878. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  19879. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  19880. xcb_tmp = _buffer
  19881. _aux = _buffer
  19882. xcb_buffer_len = uint32(0)
  19883. xcb_block_len = uint32(0)
  19884. xcb_pad = uint32(0)
  19885. xcb_align_to = uint32(0)
  19886. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(32))
  19887. xcb_tmp += uintptr(xcb_block_len)
  19888. xcb_buffer_len += xcb_block_len
  19889. xcb_block_len = uint32(0)
  19890. /* map */
  19891. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_get_pointer_mapping_reply_t)(unsafe.Pointer(_aux)).Fmap_len)*libc.Uint64FromInt64(1))
  19892. xcb_tmp += uintptr(xcb_block_len)
  19893. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  19894. /* insert padding */
  19895. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  19896. xcb_buffer_len += xcb_block_len + xcb_pad
  19897. if uint32(0) != xcb_pad {
  19898. xcb_tmp += uintptr(xcb_pad)
  19899. xcb_pad = uint32(0)
  19900. }
  19901. xcb_block_len = uint32(0)
  19902. return libc.Int32FromUint32(xcb_buffer_len)
  19903. }
  19904. func Xxcb_get_pointer_mapping(tls *libc.TLS, c uintptr) (r Txcb_get_pointer_mapping_cookie_t) {
  19905. bp := tls.Alloc(80)
  19906. defer tls.Free(80)
  19907. var xcb_ret Txcb_get_pointer_mapping_cookie_t
  19908. var _ /* xcb_out at bp+64 */ Txcb_get_pointer_mapping_request_t
  19909. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19910. _ = xcb_ret
  19911. (*(*Txcb_get_pointer_mapping_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  19912. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19913. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19914. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19915. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19916. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req244)))
  19917. return xcb_ret
  19918. }
  19919. var _xcb_req244 = Txcb_protocol_request_t{
  19920. Fcount: uint64(2),
  19921. Fopcode: uint8(m_XCB_GET_POINTER_MAPPING),
  19922. }
  19923. func Xxcb_get_pointer_mapping_unchecked(tls *libc.TLS, c uintptr) (r Txcb_get_pointer_mapping_cookie_t) {
  19924. bp := tls.Alloc(80)
  19925. defer tls.Free(80)
  19926. var xcb_ret Txcb_get_pointer_mapping_cookie_t
  19927. var _ /* xcb_out at bp+64 */ Txcb_get_pointer_mapping_request_t
  19928. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  19929. _ = xcb_ret
  19930. (*(*Txcb_get_pointer_mapping_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  19931. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  19932. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19933. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19934. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19935. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req245)))
  19936. return xcb_ret
  19937. }
  19938. var _xcb_req245 = Txcb_protocol_request_t{
  19939. Fcount: uint64(2),
  19940. Fopcode: uint8(m_XCB_GET_POINTER_MAPPING),
  19941. }
  19942. func Xxcb_get_pointer_mapping_map(tls *libc.TLS, R uintptr) (r uintptr) {
  19943. return R + libc.UintptrFromInt32(1)*32
  19944. }
  19945. func Xxcb_get_pointer_mapping_map_length(tls *libc.TLS, R uintptr) (r int32) {
  19946. return libc.Int32FromUint8((*Txcb_get_pointer_mapping_reply_t)(unsafe.Pointer(R)).Fmap_len)
  19947. }
  19948. func Xxcb_get_pointer_mapping_map_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  19949. var i Txcb_generic_iterator_t
  19950. _ = i
  19951. i.Fdata = R + libc.UintptrFromInt32(1)*32 + uintptr((*Txcb_get_pointer_mapping_reply_t)(unsafe.Pointer(R)).Fmap_len)
  19952. i.Frem = 0
  19953. i.Findex = int32(int64(i.Fdata) - int64(R))
  19954. return i
  19955. }
  19956. func Xxcb_get_pointer_mapping_reply(tls *libc.TLS, c uintptr, cookie Txcb_get_pointer_mapping_cookie_t, e uintptr) (r uintptr) {
  19957. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  19958. }
  19959. func Xxcb_set_modifier_mapping_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  19960. var _aux, xcb_tmp uintptr
  19961. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  19962. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  19963. xcb_tmp = _buffer
  19964. _aux = _buffer
  19965. xcb_buffer_len = uint32(0)
  19966. xcb_block_len = uint32(0)
  19967. xcb_pad = uint32(0)
  19968. xcb_align_to = uint32(0)
  19969. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(4))
  19970. xcb_tmp += uintptr(xcb_block_len)
  19971. xcb_buffer_len += xcb_block_len
  19972. xcb_block_len = uint32(0)
  19973. /* keycodes */
  19974. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt32(libc.Int32FromUint8((*Txcb_set_modifier_mapping_request_t)(unsafe.Pointer(_aux)).Fkeycodes_per_modifier)*libc.Int32FromInt32(8))*libc.Uint64FromInt64(1))
  19975. xcb_tmp += uintptr(xcb_block_len)
  19976. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  19977. /* insert padding */
  19978. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  19979. xcb_buffer_len += xcb_block_len + xcb_pad
  19980. if uint32(0) != xcb_pad {
  19981. xcb_tmp += uintptr(xcb_pad)
  19982. xcb_pad = uint32(0)
  19983. }
  19984. xcb_block_len = uint32(0)
  19985. return libc.Int32FromUint32(xcb_buffer_len)
  19986. }
  19987. func Xxcb_set_modifier_mapping(tls *libc.TLS, c uintptr, keycodes_per_modifier Tuint8_t, keycodes uintptr) (r Txcb_set_modifier_mapping_cookie_t) {
  19988. bp := tls.Alloc(112)
  19989. defer tls.Free(112)
  19990. var xcb_ret Txcb_set_modifier_mapping_cookie_t
  19991. var _ /* xcb_out at bp+96 */ Txcb_set_modifier_mapping_request_t
  19992. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  19993. _ = xcb_ret
  19994. (*(*Txcb_set_modifier_mapping_request_t)(unsafe.Pointer(bp + 96))).Fkeycodes_per_modifier = keycodes_per_modifier
  19995. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  19996. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  19997. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  19998. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  19999. /* xcb_keycode_t keycodes */
  20000. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = keycodes
  20001. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(libc.Int32FromUint8(keycodes_per_modifier)*libc.Int32FromInt32(8)) * uint64(1)
  20002. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  20003. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  20004. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req246)))
  20005. return xcb_ret
  20006. }
  20007. var _xcb_req246 = Txcb_protocol_request_t{
  20008. Fcount: uint64(4),
  20009. Fopcode: uint8(m_XCB_SET_MODIFIER_MAPPING),
  20010. }
  20011. func Xxcb_set_modifier_mapping_unchecked(tls *libc.TLS, c uintptr, keycodes_per_modifier Tuint8_t, keycodes uintptr) (r Txcb_set_modifier_mapping_cookie_t) {
  20012. bp := tls.Alloc(112)
  20013. defer tls.Free(112)
  20014. var xcb_ret Txcb_set_modifier_mapping_cookie_t
  20015. var _ /* xcb_out at bp+96 */ Txcb_set_modifier_mapping_request_t
  20016. var _ /* xcb_parts at bp+0 */ [6]Tiovec
  20017. _ = xcb_ret
  20018. (*(*Txcb_set_modifier_mapping_request_t)(unsafe.Pointer(bp + 96))).Fkeycodes_per_modifier = keycodes_per_modifier
  20019. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 96
  20020. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  20021. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  20022. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  20023. /* xcb_keycode_t keycodes */
  20024. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_base = keycodes
  20025. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len = libc.Uint64FromInt32(libc.Int32FromUint8(keycodes_per_modifier)*libc.Int32FromInt32(8)) * uint64(1)
  20026. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_base = uintptr(0)
  20027. (*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(5)].Fiov_len = -(*(*[6]Tiovec)(unsafe.Pointer(bp)))[int32(4)].Fiov_len & uint64(3)
  20028. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req247)))
  20029. return xcb_ret
  20030. }
  20031. var _xcb_req247 = Txcb_protocol_request_t{
  20032. Fcount: uint64(4),
  20033. Fopcode: uint8(m_XCB_SET_MODIFIER_MAPPING),
  20034. }
  20035. func Xxcb_set_modifier_mapping_reply(tls *libc.TLS, c uintptr, cookie Txcb_set_modifier_mapping_cookie_t, e uintptr) (r uintptr) {
  20036. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  20037. }
  20038. func Xxcb_get_modifier_mapping_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  20039. var _aux, xcb_tmp uintptr
  20040. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  20041. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  20042. xcb_tmp = _buffer
  20043. _aux = _buffer
  20044. xcb_buffer_len = uint32(0)
  20045. xcb_block_len = uint32(0)
  20046. xcb_pad = uint32(0)
  20047. xcb_align_to = uint32(0)
  20048. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(32))
  20049. xcb_tmp += uintptr(xcb_block_len)
  20050. xcb_buffer_len += xcb_block_len
  20051. xcb_block_len = uint32(0)
  20052. /* keycodes */
  20053. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt32(libc.Int32FromUint8((*Txcb_get_modifier_mapping_reply_t)(unsafe.Pointer(_aux)).Fkeycodes_per_modifier)*libc.Int32FromInt32(8))*libc.Uint64FromInt64(1))
  20054. xcb_tmp += uintptr(xcb_block_len)
  20055. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 1))
  20056. /* insert padding */
  20057. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  20058. xcb_buffer_len += xcb_block_len + xcb_pad
  20059. if uint32(0) != xcb_pad {
  20060. xcb_tmp += uintptr(xcb_pad)
  20061. xcb_pad = uint32(0)
  20062. }
  20063. xcb_block_len = uint32(0)
  20064. return libc.Int32FromUint32(xcb_buffer_len)
  20065. }
  20066. func Xxcb_get_modifier_mapping(tls *libc.TLS, c uintptr) (r Txcb_get_modifier_mapping_cookie_t) {
  20067. bp := tls.Alloc(80)
  20068. defer tls.Free(80)
  20069. var xcb_ret Txcb_get_modifier_mapping_cookie_t
  20070. var _ /* xcb_out at bp+64 */ Txcb_get_modifier_mapping_request_t
  20071. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  20072. _ = xcb_ret
  20073. (*(*Txcb_get_modifier_mapping_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  20074. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  20075. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  20076. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  20077. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  20078. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req248)))
  20079. return xcb_ret
  20080. }
  20081. var _xcb_req248 = Txcb_protocol_request_t{
  20082. Fcount: uint64(2),
  20083. Fopcode: uint8(m_XCB_GET_MODIFIER_MAPPING),
  20084. }
  20085. func Xxcb_get_modifier_mapping_unchecked(tls *libc.TLS, c uintptr) (r Txcb_get_modifier_mapping_cookie_t) {
  20086. bp := tls.Alloc(80)
  20087. defer tls.Free(80)
  20088. var xcb_ret Txcb_get_modifier_mapping_cookie_t
  20089. var _ /* xcb_out at bp+64 */ Txcb_get_modifier_mapping_request_t
  20090. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  20091. _ = xcb_ret
  20092. (*(*Txcb_get_modifier_mapping_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  20093. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  20094. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  20095. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  20096. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  20097. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req249)))
  20098. return xcb_ret
  20099. }
  20100. var _xcb_req249 = Txcb_protocol_request_t{
  20101. Fcount: uint64(2),
  20102. Fopcode: uint8(m_XCB_GET_MODIFIER_MAPPING),
  20103. }
  20104. func Xxcb_get_modifier_mapping_keycodes(tls *libc.TLS, R uintptr) (r uintptr) {
  20105. return R + libc.UintptrFromInt32(1)*32
  20106. }
  20107. func Xxcb_get_modifier_mapping_keycodes_length(tls *libc.TLS, R uintptr) (r int32) {
  20108. return libc.Int32FromUint8((*Txcb_get_modifier_mapping_reply_t)(unsafe.Pointer(R)).Fkeycodes_per_modifier) * int32(8)
  20109. }
  20110. func Xxcb_get_modifier_mapping_keycodes_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  20111. var i Txcb_generic_iterator_t
  20112. _ = i
  20113. i.Fdata = R + libc.UintptrFromInt32(1)*32 + uintptr(libc.Int32FromUint8((*Txcb_get_modifier_mapping_reply_t)(unsafe.Pointer(R)).Fkeycodes_per_modifier)*libc.Int32FromInt32(8))
  20114. i.Frem = 0
  20115. i.Findex = int32(int64(i.Fdata) - int64(R))
  20116. return i
  20117. }
  20118. func Xxcb_get_modifier_mapping_reply(tls *libc.TLS, c uintptr, cookie Txcb_get_modifier_mapping_cookie_t, e uintptr) (r uintptr) {
  20119. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  20120. }
  20121. func Xxcb_no_operation_checked(tls *libc.TLS, c uintptr) (r Txcb_void_cookie_t) {
  20122. bp := tls.Alloc(80)
  20123. defer tls.Free(80)
  20124. var xcb_ret Txcb_void_cookie_t
  20125. var _ /* xcb_out at bp+64 */ Txcb_no_operation_request_t
  20126. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  20127. _ = xcb_ret
  20128. (*(*Txcb_no_operation_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  20129. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  20130. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  20131. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  20132. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  20133. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req250)))
  20134. return xcb_ret
  20135. }
  20136. var _xcb_req250 = Txcb_protocol_request_t{
  20137. Fcount: uint64(2),
  20138. Fopcode: uint8(m_XCB_NO_OPERATION),
  20139. Fisvoid: uint8(1),
  20140. }
  20141. func Xxcb_no_operation(tls *libc.TLS, c uintptr) (r Txcb_void_cookie_t) {
  20142. bp := tls.Alloc(80)
  20143. defer tls.Free(80)
  20144. var xcb_ret Txcb_void_cookie_t
  20145. var _ /* xcb_out at bp+64 */ Txcb_no_operation_request_t
  20146. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  20147. _ = xcb_ret
  20148. (*(*Txcb_no_operation_request_t)(unsafe.Pointer(bp + 64))).Fpad0 = uint8(0)
  20149. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  20150. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  20151. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  20152. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  20153. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req251)))
  20154. return xcb_ret
  20155. }
  20156. var _xcb_req251 = Txcb_protocol_request_t{
  20157. Fcount: uint64(2),
  20158. Fopcode: uint8(m_XCB_NO_OPERATION),
  20159. Fisvoid: uint8(1),
  20160. }
  20161. func Xxcb_big_requests_enable(tls *libc.TLS, c uintptr) (r Txcb_big_requests_enable_cookie_t) {
  20162. bp := tls.Alloc(80)
  20163. defer tls.Free(80)
  20164. var xcb_ret Txcb_big_requests_enable_cookie_t
  20165. var _ /* xcb_out at bp+64 */ Txcb_big_requests_enable_request_t
  20166. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  20167. _ = xcb_ret
  20168. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  20169. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  20170. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  20171. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  20172. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req252)))
  20173. return xcb_ret
  20174. }
  20175. var _xcb_req252 = Txcb_protocol_request_t{
  20176. Fcount: uint64(2),
  20177. Fext: uintptr(unsafe.Pointer(&Xxcb_big_requests_id)),
  20178. }
  20179. func Xxcb_big_requests_enable_unchecked(tls *libc.TLS, c uintptr) (r Txcb_big_requests_enable_cookie_t) {
  20180. bp := tls.Alloc(80)
  20181. defer tls.Free(80)
  20182. var xcb_ret Txcb_big_requests_enable_cookie_t
  20183. var _ /* xcb_out at bp+64 */ Txcb_big_requests_enable_request_t
  20184. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  20185. _ = xcb_ret
  20186. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  20187. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  20188. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  20189. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  20190. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req253)))
  20191. return xcb_ret
  20192. }
  20193. var _xcb_req253 = Txcb_protocol_request_t{
  20194. Fcount: uint64(2),
  20195. Fext: uintptr(unsafe.Pointer(&Xxcb_big_requests_id)),
  20196. }
  20197. func Xxcb_big_requests_enable_reply(tls *libc.TLS, c uintptr, cookie Txcb_big_requests_enable_cookie_t, e uintptr) (r uintptr) {
  20198. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  20199. }
  20200. func Xxcb_xc_misc_get_version(tls *libc.TLS, c uintptr, client_major_version Tuint16_t, client_minor_version Tuint16_t) (r Txcb_xc_misc_get_version_cookie_t) {
  20201. bp := tls.Alloc(80)
  20202. defer tls.Free(80)
  20203. var xcb_ret Txcb_xc_misc_get_version_cookie_t
  20204. var _ /* xcb_out at bp+64 */ Txcb_xc_misc_get_version_request_t
  20205. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  20206. _ = xcb_ret
  20207. (*(*Txcb_xc_misc_get_version_request_t)(unsafe.Pointer(bp + 64))).Fclient_major_version = client_major_version
  20208. (*(*Txcb_xc_misc_get_version_request_t)(unsafe.Pointer(bp + 64))).Fclient_minor_version = client_minor_version
  20209. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  20210. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  20211. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  20212. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  20213. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req254)))
  20214. return xcb_ret
  20215. }
  20216. var _xcb_req254 = Txcb_protocol_request_t{
  20217. Fcount: uint64(2),
  20218. Fext: uintptr(unsafe.Pointer(&Xxcb_xc_misc_id)),
  20219. }
  20220. func Xxcb_xc_misc_get_version_unchecked(tls *libc.TLS, c uintptr, client_major_version Tuint16_t, client_minor_version Tuint16_t) (r Txcb_xc_misc_get_version_cookie_t) {
  20221. bp := tls.Alloc(80)
  20222. defer tls.Free(80)
  20223. var xcb_ret Txcb_xc_misc_get_version_cookie_t
  20224. var _ /* xcb_out at bp+64 */ Txcb_xc_misc_get_version_request_t
  20225. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  20226. _ = xcb_ret
  20227. (*(*Txcb_xc_misc_get_version_request_t)(unsafe.Pointer(bp + 64))).Fclient_major_version = client_major_version
  20228. (*(*Txcb_xc_misc_get_version_request_t)(unsafe.Pointer(bp + 64))).Fclient_minor_version = client_minor_version
  20229. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  20230. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  20231. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  20232. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  20233. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req255)))
  20234. return xcb_ret
  20235. }
  20236. var _xcb_req255 = Txcb_protocol_request_t{
  20237. Fcount: uint64(2),
  20238. Fext: uintptr(unsafe.Pointer(&Xxcb_xc_misc_id)),
  20239. }
  20240. func Xxcb_xc_misc_get_version_reply(tls *libc.TLS, c uintptr, cookie Txcb_xc_misc_get_version_cookie_t, e uintptr) (r uintptr) {
  20241. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  20242. }
  20243. func Xxcb_xc_misc_get_xid_range(tls *libc.TLS, c uintptr) (r Txcb_xc_misc_get_xid_range_cookie_t) {
  20244. bp := tls.Alloc(80)
  20245. defer tls.Free(80)
  20246. var xcb_ret Txcb_xc_misc_get_xid_range_cookie_t
  20247. var _ /* xcb_out at bp+64 */ Txcb_xc_misc_get_xid_range_request_t
  20248. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  20249. _ = xcb_ret
  20250. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  20251. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  20252. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  20253. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  20254. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req256)))
  20255. return xcb_ret
  20256. }
  20257. var _xcb_req256 = Txcb_protocol_request_t{
  20258. Fcount: uint64(2),
  20259. Fext: uintptr(unsafe.Pointer(&Xxcb_xc_misc_id)),
  20260. Fopcode: uint8(m_XCB_XC_MISC_GET_XID_RANGE),
  20261. }
  20262. func Xxcb_xc_misc_get_xid_range_unchecked(tls *libc.TLS, c uintptr) (r Txcb_xc_misc_get_xid_range_cookie_t) {
  20263. bp := tls.Alloc(80)
  20264. defer tls.Free(80)
  20265. var xcb_ret Txcb_xc_misc_get_xid_range_cookie_t
  20266. var _ /* xcb_out at bp+64 */ Txcb_xc_misc_get_xid_range_request_t
  20267. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  20268. _ = xcb_ret
  20269. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  20270. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(4)
  20271. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  20272. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  20273. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req257)))
  20274. return xcb_ret
  20275. }
  20276. var _xcb_req257 = Txcb_protocol_request_t{
  20277. Fcount: uint64(2),
  20278. Fext: uintptr(unsafe.Pointer(&Xxcb_xc_misc_id)),
  20279. Fopcode: uint8(m_XCB_XC_MISC_GET_XID_RANGE),
  20280. }
  20281. func Xxcb_xc_misc_get_xid_range_reply(tls *libc.TLS, c uintptr, cookie Txcb_xc_misc_get_xid_range_cookie_t, e uintptr) (r uintptr) {
  20282. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  20283. }
  20284. func Xxcb_xc_misc_get_xid_list_sizeof(tls *libc.TLS, _buffer uintptr) (r int32) {
  20285. var _aux, xcb_tmp uintptr
  20286. var xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad uint32
  20287. _, _, _, _, _, _ = _aux, xcb_align_to, xcb_block_len, xcb_buffer_len, xcb_pad, xcb_tmp
  20288. xcb_tmp = _buffer
  20289. _aux = _buffer
  20290. xcb_buffer_len = uint32(0)
  20291. xcb_block_len = uint32(0)
  20292. xcb_pad = uint32(0)
  20293. xcb_align_to = uint32(0)
  20294. xcb_block_len = uint32(uint64(xcb_block_len) + libc.Uint64FromInt64(32))
  20295. xcb_tmp += uintptr(xcb_block_len)
  20296. xcb_buffer_len += xcb_block_len
  20297. xcb_block_len = uint32(0)
  20298. /* ids */
  20299. xcb_block_len = uint32(uint64(xcb_block_len) + uint64((*Txcb_xc_misc_get_xid_list_reply_t)(unsafe.Pointer(_aux)).Fids_len)*libc.Uint64FromInt64(4))
  20300. xcb_tmp += uintptr(xcb_block_len)
  20301. xcb_align_to = uint32(uint64(libc.UintptrFromInt32(0) + 4))
  20302. /* insert padding */
  20303. xcb_pad = -xcb_block_len & (xcb_align_to - uint32(1))
  20304. xcb_buffer_len += xcb_block_len + xcb_pad
  20305. if uint32(0) != xcb_pad {
  20306. xcb_tmp += uintptr(xcb_pad)
  20307. xcb_pad = uint32(0)
  20308. }
  20309. xcb_block_len = uint32(0)
  20310. return libc.Int32FromUint32(xcb_buffer_len)
  20311. }
  20312. func Xxcb_xc_misc_get_xid_list(tls *libc.TLS, c uintptr, count Tuint32_t) (r Txcb_xc_misc_get_xid_list_cookie_t) {
  20313. bp := tls.Alloc(80)
  20314. defer tls.Free(80)
  20315. var xcb_ret Txcb_xc_misc_get_xid_list_cookie_t
  20316. var _ /* xcb_out at bp+64 */ Txcb_xc_misc_get_xid_list_request_t
  20317. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  20318. _ = xcb_ret
  20319. (*(*Txcb_xc_misc_get_xid_list_request_t)(unsafe.Pointer(bp + 64))).Fcount = count
  20320. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  20321. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  20322. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  20323. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  20324. xcb_ret.Fsequence = Xxcb_send_request(tls, c, int32(_XCB_REQUEST_CHECKED), bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req258)))
  20325. return xcb_ret
  20326. }
  20327. var _xcb_req258 = Txcb_protocol_request_t{
  20328. Fcount: uint64(2),
  20329. Fext: uintptr(unsafe.Pointer(&Xxcb_xc_misc_id)),
  20330. Fopcode: uint8(m_XCB_XC_MISC_GET_XID_LIST),
  20331. }
  20332. func Xxcb_xc_misc_get_xid_list_unchecked(tls *libc.TLS, c uintptr, count Tuint32_t) (r Txcb_xc_misc_get_xid_list_cookie_t) {
  20333. bp := tls.Alloc(80)
  20334. defer tls.Free(80)
  20335. var xcb_ret Txcb_xc_misc_get_xid_list_cookie_t
  20336. var _ /* xcb_out at bp+64 */ Txcb_xc_misc_get_xid_list_request_t
  20337. var _ /* xcb_parts at bp+0 */ [4]Tiovec
  20338. _ = xcb_ret
  20339. (*(*Txcb_xc_misc_get_xid_list_request_t)(unsafe.Pointer(bp + 64))).Fcount = count
  20340. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_base = bp + 64
  20341. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len = uint64(8)
  20342. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_base = uintptr(0)
  20343. (*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(3)].Fiov_len = -(*(*[4]Tiovec)(unsafe.Pointer(bp)))[int32(2)].Fiov_len & uint64(3)
  20344. xcb_ret.Fsequence = Xxcb_send_request(tls, c, 0, bp+uintptr(2)*16, uintptr(unsafe.Pointer(&_xcb_req259)))
  20345. return xcb_ret
  20346. }
  20347. var _xcb_req259 = Txcb_protocol_request_t{
  20348. Fcount: uint64(2),
  20349. Fext: uintptr(unsafe.Pointer(&Xxcb_xc_misc_id)),
  20350. Fopcode: uint8(m_XCB_XC_MISC_GET_XID_LIST),
  20351. }
  20352. func Xxcb_xc_misc_get_xid_list_ids(tls *libc.TLS, R uintptr) (r uintptr) {
  20353. return R + libc.UintptrFromInt32(1)*32
  20354. }
  20355. func Xxcb_xc_misc_get_xid_list_ids_length(tls *libc.TLS, R uintptr) (r int32) {
  20356. return libc.Int32FromUint32((*Txcb_xc_misc_get_xid_list_reply_t)(unsafe.Pointer(R)).Fids_len)
  20357. }
  20358. func Xxcb_xc_misc_get_xid_list_ids_end(tls *libc.TLS, R uintptr) (r Txcb_generic_iterator_t) {
  20359. var i Txcb_generic_iterator_t
  20360. _ = i
  20361. i.Fdata = R + libc.UintptrFromInt32(1)*32 + uintptr((*Txcb_xc_misc_get_xid_list_reply_t)(unsafe.Pointer(R)).Fids_len)*4
  20362. i.Frem = 0
  20363. i.Findex = int32(int64(i.Fdata) - int64(R))
  20364. return i
  20365. }
  20366. func Xxcb_xc_misc_get_xid_list_reply(tls *libc.TLS, c uintptr, cookie Txcb_xc_misc_get_xid_list_cookie_t, e uintptr) (r uintptr) {
  20367. return Xxcb_wait_for_reply(tls, c, cookie.Fsequence, e)
  20368. }
  20369. func __ccgo_fp(f interface{}) uintptr {
  20370. type iface [2]uintptr
  20371. return (*iface)(unsafe.Pointer(&f))[1]
  20372. }
  20373. /**
  20374. * @}
  20375. */
  20376. var Xxcb_big_requests_id = Txcb_extension_t{
  20377. Fname: __ccgo_ts + 93,
  20378. }
  20379. /**
  20380. * @}
  20381. */
  20382. var Xxcb_xc_misc_id = Txcb_extension_t{
  20383. Fname: __ccgo_ts + 106,
  20384. }
  20385. var __ccgo_ts = (*reflect.StringHeader)(unsafe.Pointer(&__ccgo_ts1)).Data
  20386. var __ccgo_ts1 = "GLX\x00DISPLAY\x00unix\x00%s%d\x00tcp\x00inet\x00inet6\x00localhost\x00%hu\x00XDM-AUTHORIZATION-1\x00MIT-MAGIC-COOKIE-1\x00%d\x00BIG-REQUESTS\x00XC-MISC\x00"