ia2_api_all.idl 226 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793
  1. /*************************************************************************
  2. *
  3. * File Name (api_all_headers.idl)
  4. *
  5. * IAccessible2 IDL Specification
  6. *
  7. * Copyright (c) 2013 Linux Foundation
  8. * All rights reserved.
  9. *
  10. *
  11. * Redistribution and use in source and binary forms, with or without
  12. * modification, are permitted provided that the following conditions
  13. * are met:
  14. *
  15. * 1. Redistributions of source code must retain the above copyright
  16. * notice, this list of conditions and the following disclaimer.
  17. *
  18. * 2. Redistributions in binary form must reproduce the above
  19. * copyright notice, this list of conditions and the following
  20. * disclaimer in the documentation and/or other materials
  21. * provided with the distribution.
  22. *
  23. * 3. Neither the name of the Linux Foundation nor the names of its
  24. * contributors may be used to endorse or promote products
  25. * derived from this software without specific prior written
  26. * permission.
  27. *
  28. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  29. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  30. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  31. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  32. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  33. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  34. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  35. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  36. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  37. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  38. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  39. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  40. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  41. *
  42. * This BSD License conforms to the Open Source Initiative "Simplified
  43. * BSD License" as published at:
  44. * http://www.opensource.org/licenses/bsd-license.php
  45. *
  46. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  47. * mark may be used in accordance with the Linux Foundation Trademark
  48. * Policy to indicate compliance with the IAccessible2 specification.
  49. *
  50. ************************************************************************/
  51. import "objidl.idl";
  52. import "oaidl.idl";
  53. import "oleacc.idl";
  54. /*************************************************************************
  55. *
  56. * File Name (IA2CommonTypes.idl)
  57. *
  58. * IAccessible2 IDL Specification
  59. *
  60. * Copyright (c) 2007, 2010 Linux Foundation
  61. * Copyright (c) 2006 IBM Corporation
  62. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  63. * All rights reserved.
  64. *
  65. *
  66. * Redistribution and use in source and binary forms, with or without
  67. * modification, are permitted provided that the following conditions
  68. * are met:
  69. *
  70. * 1. Redistributions of source code must retain the above copyright
  71. * notice, this list of conditions and the following disclaimer.
  72. *
  73. * 2. Redistributions in binary form must reproduce the above
  74. * copyright notice, this list of conditions and the following
  75. * disclaimer in the documentation and/or other materials
  76. * provided with the distribution.
  77. *
  78. * 3. Neither the name of the Linux Foundation nor the names of its
  79. * contributors may be used to endorse or promote products
  80. * derived from this software without specific prior written
  81. * permission.
  82. *
  83. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  84. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  85. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  86. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  87. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  88. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  89. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  90. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  91. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  92. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  93. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  94. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  95. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  96. *
  97. * This BSD License conforms to the Open Source Initiative "Simplified
  98. * BSD License" as published at:
  99. * http://www.opensource.org/licenses/bsd-license.php
  100. *
  101. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  102. * mark may be used in accordance with the Linux Foundation Trademark
  103. * Policy to indicate compliance with the IAccessible2 specification.
  104. *
  105. ************************************************************************/
  106. /** These constants control the scrolling of an object or substring into a window.
  107. This enum is used in IAccessible2::scrollTo and IAccessibleText::scrollSubstringTo.
  108. */
  109. enum IA2ScrollType {
  110. /** Scroll the top left corner of the object or substring such that the top left
  111. corner (and as much as possible of the rest of the object or substring) is within
  112. the top level window. In cases where the entire object or substring fits within
  113. the top level window, the placement of the object or substring is dependent on
  114. the application. For example, the object or substring may be scrolled to the
  115. closest edge, the furthest edge, or midway between those two edges. In cases
  116. where there is a hierarchy of nested scrollable controls, more than one control
  117. may have to be scrolled.
  118. */
  119. IA2_SCROLL_TYPE_TOP_LEFT,
  120. /** Scroll the bottom right corner of the object or substring such that the bottom right
  121. corner (and as much as possible of the rest of the object or substring) is within
  122. the top level window. In cases where the entire object or substring fits within
  123. the top level window, the placement of the object or substring is dependent on
  124. the application. For example, the object or substring may be scrolled to the
  125. closest edge, the furthest edge, or midway between those two edges. In cases
  126. where there is a hierarchy of nested scrollable controls, more than one control
  127. may have to be scrolled.
  128. */
  129. IA2_SCROLL_TYPE_BOTTOM_RIGHT,
  130. /** Scroll the top edge of the object or substring such that the top edge
  131. (and as much as possible of the rest of the object or substring) is within the
  132. top level window. In cases where the entire object or substring fits within
  133. the top level window, the placement of the object or substring is dependent on
  134. the application. For example, the object or substring may be scrolled to the
  135. closest edge, the furthest edge, or midway between those two edges. In cases
  136. where there is a hierarchy of nested scrollable controls, more than one control
  137. may have to be scrolled.
  138. */
  139. IA2_SCROLL_TYPE_TOP_EDGE,
  140. /** Scroll the bottom edge of the object or substring such that the bottom edge
  141. (and as much as possible of the rest of the object or substring) is within the
  142. top level window. In cases where the entire object or substring fits within
  143. the top level window, the placement of the object or substring is dependent on
  144. the application. For example, the object or substring may be scrolled to the
  145. closest edge, the furthest edge, or midway between those two edges. In cases
  146. where there is a hierarchy of nested scrollable controls, more than one control
  147. may have to be scrolled.
  148. */
  149. IA2_SCROLL_TYPE_BOTTOM_EDGE,
  150. /** Scroll the left edge of the object or substring such that the left edge
  151. (and as much as possible of the rest of the object or substring) is within the
  152. top level window. In cases where the entire object or substring fits within
  153. the top level window, the placement of the object or substring is dependent on
  154. the application. For example, the object or substring may be scrolled to the
  155. closest edge, the furthest edge, or midway between those two edges. In cases
  156. where there is a hierarchy of nested scrollable controls, more than one control
  157. may have to be scrolled.
  158. */
  159. IA2_SCROLL_TYPE_LEFT_EDGE,
  160. /** Scroll the right edge of the object or substring such that the right edge
  161. (and as much as possible of the rest of the object or substring) is within the
  162. top level window. In cases where the entire object or substring fits within
  163. the top level window, the placement of the object or substring is dependent on
  164. the application. For example, the object or substring may be scrolled to the
  165. closest edge, the furthest edge, or midway between those two edges. In cases
  166. where there is a hierarchy of nested scrollable controls, more than one control
  167. may have to be scrolled.
  168. */
  169. IA2_SCROLL_TYPE_RIGHT_EDGE,
  170. /** Scroll the object or substring such that as much as possible of the
  171. object or substring is within the top level window. The placement of
  172. the object is dependent on the application. For example, the object or
  173. substring may be scrolled to to closest edge, the furthest edge, or midway
  174. between those two edges.
  175. */
  176. IA2_SCROLL_TYPE_ANYWHERE
  177. };
  178. /** These constants define which coordinate system a point is located in.
  179. This enum is used in IAccessible2::scrollToPoint, IAccessibleImage::imagePosition,
  180. IAccessibleText::characterExtents, and IAccessibleText::offsetAtPoint, and
  181. IAccessibleText::scrollSubstringToPoint.
  182. */
  183. enum IA2CoordinateType {
  184. /// The coordinates are relative to the screen.
  185. IA2_COORDTYPE_SCREEN_RELATIVE,
  186. /** The coordinates are relative to the upper left corner of the bounding box
  187. of the immediate parent.
  188. */
  189. IA2_COORDTYPE_PARENT_RELATIVE
  190. };
  191. /** Special offsets for use in IAccessibleText and IAccessibleEditableText methods
  192. Refer to @ref _specialOffsets
  193. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  194. for more information.
  195. */
  196. enum IA2TextSpecialOffsets {
  197. IA2_TEXT_OFFSET_LENGTH = -1, /**< This offset is equivalent to the length of the string. It eliminates
  198. the need to call IAccessibleText::nCharacters. */
  199. IA2_TEXT_OFFSET_CARET = -2 /**< This offset signifies that the text related to the physical location
  200. of the caret should be used. */
  201. };
  202. /** These constants specify the kind of change made to a table.
  203. This enum is used in the IA2TableModelChange struct which in turn is used by
  204. IAccessibleTable::modelChange and IAccessibleTable2::modelChange.
  205. */
  206. enum IA2TableModelChangeType {
  207. IA2_TABLE_MODEL_CHANGE_INSERT, // = 0;
  208. IA2_TABLE_MODEL_CHANGE_DELETE,
  209. IA2_TABLE_MODEL_CHANGE_UPDATE
  210. };
  211. /** A structure defining the type of and extents of changes made to a table
  212. IAccessibleTable::modelChange and IAccessibleTable2::modelChange return this struct.
  213. In the case of an insertion or change the row and column offsets define the boundaries
  214. of the inserted or changed subtable after the operation. In the case of a deletion
  215. the row and column offsets define the boundaries of the subtable being removed before
  216. the removal.
  217. */
  218. typedef struct IA2TableModelChange {
  219. enum IA2TableModelChangeType type; // insert, delete, update
  220. long firstRow; ///< 0 based, inclusive
  221. long lastRow; ///< 0 based, inclusive
  222. long firstColumn; ///< 0 based, inclusive
  223. long lastColumn; ///< 0 based, inclusive
  224. } IA2TableModelChange;
  225. /*************************************************************************
  226. *
  227. * File Name (AccessibleRelation.idl)
  228. *
  229. * IAccessible2 IDL Specification
  230. *
  231. * Copyright (c) 2007, 2013 Linux Foundation
  232. * Copyright (c) 2006 IBM Corporation
  233. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  234. * All rights reserved.
  235. *
  236. *
  237. * Redistribution and use in source and binary forms, with or without
  238. * modification, are permitted provided that the following conditions
  239. * are met:
  240. *
  241. * 1. Redistributions of source code must retain the above copyright
  242. * notice, this list of conditions and the following disclaimer.
  243. *
  244. * 2. Redistributions in binary form must reproduce the above
  245. * copyright notice, this list of conditions and the following
  246. * disclaimer in the documentation and/or other materials
  247. * provided with the distribution.
  248. *
  249. * 3. Neither the name of the Linux Foundation nor the names of its
  250. * contributors may be used to endorse or promote products
  251. * derived from this software without specific prior written
  252. * permission.
  253. *
  254. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  255. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  256. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  257. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  258. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  259. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  260. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  261. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  262. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  263. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  264. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  265. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  266. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  267. *
  268. * This BSD License conforms to the Open Source Initiative "Simplified
  269. * BSD License" as published at:
  270. * http://www.opensource.org/licenses/bsd-license.php
  271. *
  272. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  273. * mark may be used in accordance with the Linux Foundation Trademark
  274. * Policy to indicate compliance with the IAccessible2 specification.
  275. *
  276. ************************************************************************/
  277. /** @defgroup grpRelations Relations
  278. Use the following constants to compare against the BSTRs returned by
  279. IAccessibleRelation::relationType.
  280. */
  281. ///@{
  282. /** The target object is the containing application object. */
  283. const WCHAR *const IA2_RELATION_CONTAINING_APPLICATION = L"containingApplication";
  284. /** The target object is the containing document object. The target object implements
  285. the IAccessibleDocument interface.
  286. */
  287. const WCHAR *const IA2_RELATION_CONTAINING_DOCUMENT = L"containingDocument";
  288. /** The target object is the containing tab pane object. */
  289. const WCHAR *const IA2_RELATION_CONTAINING_TAB_PANE = L"containingTabPane";
  290. /** The target object is the containing window object. */
  291. const WCHAR *const IA2_RELATION_CONTAINING_WINDOW = L"containingWindow";
  292. /** Some attribute of this object is affected by a target object. */
  293. const WCHAR *const IA2_RELATION_CONTROLLED_BY = L"controlledBy";
  294. /** This object is interactive and controls some attribute of a target object. */
  295. const WCHAR *const IA2_RELATION_CONTROLLER_FOR = L"controllerFor";
  296. /** This object is described by the target object. */
  297. const WCHAR *const IA2_RELATION_DESCRIBED_BY = L"describedBy";
  298. /** This object is describes the target object. */
  299. const WCHAR *const IA2_RELATION_DESCRIPTION_FOR = L"descriptionFor";
  300. /** This object is embedded by a target object. */
  301. const WCHAR *const IA2_RELATION_EMBEDDED_BY = L"embeddedBy";
  302. /** This object embeds a target object. This relation can be used on the
  303. OBJID_CLIENT accessible for a top level window to show where the content
  304. areas are.
  305. */
  306. const WCHAR *const IA2_RELATION_EMBEDS = L"embeds";
  307. /** Content flows to this object from a target object.
  308. This relation and IA2_RELATION_FLOWS_TO are useful to tie text and non-text
  309. objects together in order to allow assistive technology to follow the
  310. intended reading order.
  311. */
  312. const WCHAR *const IA2_RELATION_FLOWS_FROM = L"flowsFrom";
  313. /** Content flows from this object to a target object. */
  314. const WCHAR *const IA2_RELATION_FLOWS_TO = L"flowsTo";
  315. /** This object is label for a target object. */
  316. const WCHAR *const IA2_RELATION_LABEL_FOR = L"labelFor";
  317. /** This object is labelled by a target object. Note that the double L spelling
  318. which follows is preferred. Please use it instead. This single L version may
  319. be removed in a later version.
  320. */
  321. const WCHAR *const IA2_RELATION_LABELED_BY = L"labelledBy";
  322. /** This object is labelled by a target object. */
  323. const WCHAR *const IA2_RELATION_LABELLED_BY = L"labelledBy";
  324. /** This object is a member of a group of one or more objects. When
  325. there is more than one object in the group each member may have one and the
  326. same target, e.g. a grouping object. It is also possible that each member has
  327. multiple additional targets, e.g. one for every other member in the group.
  328. */
  329. const WCHAR *const IA2_RELATION_MEMBER_OF = L"memberOf";
  330. /** The target object is the next object in the tab order. */
  331. const WCHAR *const IA2_RELATION_NEXT_TABBABLE = L"nextTabbable";
  332. /** This object is a logical child of a target object. This relation is the reciprocal
  333. of the IA2_RELATION_NODE_PARENT_OF relation. In some cases an application's accessible
  334. tree is such that objects can be in a logical parent-child relationship which is
  335. different from the hierarchy of the accessible tree. */
  336. const WCHAR *const IA2_RELATION_NODE_CHILD_OF = L"nodeChildOf";
  337. /** This object is a logical parent of a target object. This relation is the reciprocal
  338. of the IA2_RELATION_NODE_CHILD_OF relation. In some cases an application's accessible
  339. tree is such that objects can be in a logical parent-child relationship which is
  340. different from the hierarchy of the accessible tree. */
  341. const WCHAR *const IA2_RELATION_NODE_PARENT_OF = L"nodeParentOf";
  342. /** This object is a parent window of the target object. */
  343. const WCHAR *const IA2_RELATION_PARENT_WINDOW_OF = L"parentWindowOf";
  344. /** This object is a transient component related to the target object.
  345. When this object is activated the target object doesn't lose focus.
  346. */
  347. const WCHAR *const IA2_RELATION_POPUP_FOR = L"popupFor";
  348. /** The target object is the previous object in the tab order. */
  349. const WCHAR *const IA2_RELATION_PREVIOUS_TABBABLE = L"previousTabbable";
  350. /** This object is a sub window of a target object. */
  351. const WCHAR *const IA2_RELATION_SUBWINDOW_OF = L"subwindowOf";
  352. /** The target object provides the detailed, extended description for this
  353. object. It provides more detailed information than would normally be provided
  354. using the IA2_RELATION_DESCRIBED_BY relation. A common use for this relation is
  355. in digital publishing where an extended description needs to be conveyed in
  356. a book that requires structural markup or the embedding of other technology to
  357. provide illustrative content. */
  358. const WCHAR *const IA2_RELATION_DETAILS = L"details";
  359. /** This object provides the detailed, extended description for the target
  360. object. See IA2_RELATION_DETAILS. */
  361. const WCHAR *const IA2_RELATION_DETAILS_FOR = L"detailsFor";
  362. /** The target object is the error message for this object. */
  363. const WCHAR *const IA2_RELATION_ERROR = L"error";
  364. /** This object is the error message for the target object. */
  365. const WCHAR *const IA2_RELATION_ERROR_FOR = L"errorFor";
  366. ///@}
  367. /** This interface gives access to an object's set of relations.
  368. */
  369. [object, uuid(7CDF86EE-C3DA-496a-BDA4-281B336E1FDC)]
  370. interface IAccessibleRelation : IUnknown
  371. {
  372. /** @brief Returns the type of the relation.
  373. @param [out] relationType
  374. The strings returned are defined @ref grpRelations "in this section of the documentation".
  375. @retval S_OK
  376. */
  377. [propget] HRESULT relationType
  378. (
  379. [out, retval] BSTR *relationType
  380. );
  381. /** @brief Returns a localized version of the relation type.
  382. @param [out] localizedRelationType
  383. @retval S_OK
  384. */
  385. [propget] HRESULT localizedRelationType
  386. (
  387. [out, retval] BSTR *localizedRelationType
  388. );
  389. /** @brief Returns the number of targets for this relation.
  390. @param [out] nTargets
  391. @retval S_OK
  392. */
  393. [propget] HRESULT nTargets
  394. (
  395. [out, retval] long *nTargets
  396. );
  397. /** @brief Returns one accessible relation target.
  398. @param [in] targetIndex
  399. 0 based index
  400. @param [out] target
  401. @retval S_OK
  402. @retval E_INVALIDARG if bad [in] passed
  403. @note Use QueryInterface to get IAccessible2.
  404. */
  405. [propget] HRESULT target
  406. (
  407. [in] long targetIndex,
  408. [out, retval] IUnknown **target
  409. );
  410. /** @brief Returns multiple accessible relation targets
  411. @param [in] maxTargets
  412. maximum size of the array allocated by the client
  413. @param [out] targets
  414. The array of target objects. Note that this array is to be allocated by the
  415. client and freed when no longer needed. Refer to @ref _arrayConsideration
  416. "Special Consideration when using Arrays" for more details. You will need to use
  417. QueryInterface on the IUnknown to get the IAccessible2.
  418. @param [out] nTargets
  419. actual number of targets in the returned array (not more than maxTargets)
  420. @retval S_OK
  421. @retval E_INVALIDARG if bad [in] passed, e.g. a negative value
  422. */
  423. [propget] HRESULT targets
  424. (
  425. [in] long maxTargets,
  426. [out, size_is(maxTargets), length_is(*nTargets)]
  427. IUnknown **targets,
  428. [out, retval] long *nTargets
  429. );
  430. }
  431. /*************************************************************************
  432. *
  433. * File Name (AccessibleAction.idl)
  434. *
  435. * IAccessible2 IDL Specification
  436. *
  437. * Copyright (c) 2007, 2013 Linux Foundation
  438. * Copyright (c) 2006 IBM Corporation
  439. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  440. * All rights reserved.
  441. *
  442. *
  443. * Redistribution and use in source and binary forms, with or without
  444. * modification, are permitted provided that the following conditions
  445. * are met:
  446. *
  447. * 1. Redistributions of source code must retain the above copyright
  448. * notice, this list of conditions and the following disclaimer.
  449. *
  450. * 2. Redistributions in binary form must reproduce the above
  451. * copyright notice, this list of conditions and the following
  452. * disclaimer in the documentation and/or other materials
  453. * provided with the distribution.
  454. *
  455. * 3. Neither the name of the Linux Foundation nor the names of its
  456. * contributors may be used to endorse or promote products
  457. * derived from this software without specific prior written
  458. * permission.
  459. *
  460. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  461. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  462. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  463. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  464. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  465. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  466. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  467. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  468. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  469. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  470. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  471. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  472. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  473. *
  474. * This BSD License conforms to the Open Source Initiative "Simplified
  475. * BSD License" as published at:
  476. * http://www.opensource.org/licenses/bsd-license.php
  477. *
  478. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  479. * mark may be used in accordance with the Linux Foundation Trademark
  480. * Policy to indicate compliance with the IAccessible2 specification.
  481. *
  482. ************************************************************************/
  483. /** This enum defines values which are predefined actions for use when implementing
  484. support for media.
  485. This enum is used when specifying an action for IAccessibleAction::doAction.
  486. */
  487. enum IA2Actions {
  488. IA2_ACTION_OPEN = -1, /**< Used to inform the server that the client will
  489. signal via IA2_ACTION_COMPLETE when it has consumed
  490. the content provided by the object. This action
  491. allows the object's server to wait for all clients
  492. to signal their readiness for additional content.
  493. Any form of content generation that requires
  494. synchronization with an AT would require use of this
  495. action. One example is the generation of text describing
  496. visual content not obvious from a video's sound track.
  497. In this scenario the Text to Speech or Braille output
  498. may take more time than the related length of silence
  499. in the video's sound track. */
  500. IA2_ACTION_COMPLETE = -2, /**< Used by the client to inform the server that it has
  501. consumed the most recent content provided by this object. */
  502. IA2_ACTION_CLOSE = -3 /**< Used to inform the server that the client no longer
  503. requires synchronization. */
  504. };
  505. /** @brief This interface gives access to actions that can be executed
  506. for accessible objects.
  507. Every accessible object that can be manipulated via the native GUI beyond the
  508. methods available either in the MSAA IAccessible interface or in the set of
  509. IAccessible2 interfaces (other than this IAccessibleAction interface) should
  510. support the IAccessibleAction interface in order to provide Assistive Technology
  511. access to all the actions that can be performed by the object. Each action can
  512. be performed or queried for a name, description or associated key bindings.
  513. Actions are needed more for ATs that assist the mobility impaired, such as
  514. on-screen keyboards and voice command software. By providing actions directly,
  515. the AT can present them to the user without the user having to perform the extra
  516. steps to navigate a context menu.
  517. The first action should be equivalent to the MSAA default action. If there is
  518. only one action, %IAccessibleAction should also be implemented.
  519. */
  520. [object, uuid(B70D9F59-3B5A-4dba-AB9E-22012F607DF5)]
  521. interface IAccessibleAction : IUnknown
  522. {
  523. /** @brief Returns the number of accessible actions available in this object.
  524. If there are more than one, the first one is considered the
  525. "default" action of the object.
  526. @param [out] nActions
  527. The returned value of the number of actions is zero if there are
  528. no actions.
  529. @retval S_OK
  530. @note This method is missing a [propget] prefix in the IDL. The result is the
  531. method is named nActions in generated C++ code instead of get_nActions.
  532. */
  533. HRESULT nActions
  534. (
  535. [out,retval] long* nActions
  536. );
  537. /** @brief Performs the specified Action on the object.
  538. @param [in] actionIndex
  539. 0 based index specifying the action to perform. If it lies outside
  540. the valid range no action is performed.
  541. @retval S_OK
  542. @retval S_FALSE if action could not be performed
  543. @retval E_INVALIDARG if bad [in] passed
  544. @note If implementing support for media, refer to the predefined constants in the ::IA2Actions enum.
  545. */
  546. HRESULT doAction
  547. (
  548. [in] long actionIndex
  549. );
  550. /** @brief Returns a description of the specified action of the object.
  551. @param [in] actionIndex
  552. 0 based index specifying which action's description to return.
  553. If it lies outside the valid range an empty string is returned.
  554. @param [out] description
  555. The returned value is a localized string of the specified action.
  556. @retval S_OK
  557. @retval S_FALSE if there is nothing to return, [out] value is NULL
  558. @retval E_INVALIDARG if bad [in] passed
  559. */
  560. [propget] HRESULT description
  561. (
  562. [in] long actionIndex,
  563. [out, retval] BSTR *description
  564. );
  565. /** @brief Returns an array of BSTRs describing one or more key bindings, if
  566. there are any, associated with the specified action.
  567. The returned strings are the localized human readable key sequences to be
  568. used to activate each action, e.g. "Ctrl+Shift+D". Since these key
  569. sequences are to be used when the object has focus, they are like
  570. mnemonics (access keys), and not like shortcut (accelerator) keys.
  571. There is no need to implement this method for single action controls since
  572. that would be redundant with the standard MSAA programming practice of
  573. getting the mnemonic from get_accKeyboardShortcut.
  574. An AT such as an On Screen Keyboard might not expose these bindings but
  575. provide alternative means of activation.
  576. Note: the client allocates and passes in an array of pointers. The server
  577. allocates the BSTRs and passes back one or more pointers to these BSTRs into
  578. the array of pointers allocated by the client. The client is responsible
  579. for deallocating the BSTRs.
  580. @param [in] actionIndex
  581. 0 based index specifying which action's key bindings should be returned.
  582. @param [in] nMaxBindings
  583. This parameter is ignored. Refer to @ref _arrayConsideration
  584. "Special Consideration when using Arrays" for more details.
  585. @param [out] keyBindings
  586. An array of BSTRs, allocated by the server, one for each key binding.
  587. The client must free it with CoTaskMemFree.
  588. @param [out] nBindings
  589. The number of key bindings returned; the size of the returned array.
  590. @retval S_OK
  591. @retval S_FALSE if there are no key bindings, [out] values are NULL and 0 respectively
  592. @retval E_INVALIDARG if bad [in] passed
  593. */
  594. [propget] HRESULT keyBinding
  595. (
  596. [in] long actionIndex,
  597. [in] long nMaxBindings,
  598. [out, size_is(,nMaxBindings), length_is(,*nBindings)] BSTR **keyBindings,
  599. [out, retval] long *nBindings
  600. );
  601. /** @brief Returns the non-localized name of specified action.
  602. @param [in] actionIndex
  603. 0 based index specifying which action's non-localized name should be returned.
  604. @param [out] name
  605. @retval S_OK
  606. @retval S_FALSE if there is nothing to return, [out] value is NULL
  607. @retval E_INVALIDARG if bad [in] passed
  608. */
  609. [propget] HRESULT name
  610. (
  611. [in] long actionIndex,
  612. [out, retval] BSTR *name
  613. );
  614. /** @brief Returns the localized name of specified action.
  615. @param [in] actionIndex
  616. 0 based index specifying which action's localized name should be returned.
  617. @param [out] localizedName
  618. @retval S_OK
  619. @retval S_FALSE if there is nothing to return, [out] value is NULL
  620. @retval E_INVALIDARG if bad [in] passed
  621. */
  622. [propget] HRESULT localizedName
  623. (
  624. [in] long actionIndex,
  625. [out, retval] BSTR *localizedName
  626. );
  627. }
  628. /*************************************************************************
  629. *
  630. * File Name (AccessibleRole.idl)
  631. *
  632. * IAccessible2 IDL Specification
  633. *
  634. * Copyright (c) 2007-2018 Linux Foundation
  635. * Copyright (c) 2006 IBM Corporation
  636. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  637. * All rights reserved.
  638. *
  639. *
  640. * Redistribution and use in source and binary forms, with or without
  641. * modification, are permitted provided that the following conditions
  642. * are met:
  643. *
  644. * 1. Redistributions of source code must retain the above copyright
  645. * notice, this list of conditions and the following disclaimer.
  646. *
  647. * 2. Redistributions in binary form must reproduce the above
  648. * copyright notice, this list of conditions and the following
  649. * disclaimer in the documentation and/or other materials
  650. * provided with the distribution.
  651. *
  652. * 3. Neither the name of the Linux Foundation nor the names of its
  653. * contributors may be used to endorse or promote products
  654. * derived from this software without specific prior written
  655. * permission.
  656. *
  657. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  658. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  659. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  660. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  661. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  662. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  663. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  664. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  665. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  666. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  667. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  668. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  669. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  670. *
  671. * This BSD License conforms to the Open Source Initiative "Simplified
  672. * BSD License" as published at:
  673. * http://www.opensource.org/licenses/bsd-license.php
  674. *
  675. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  676. * mark may be used in accordance with the Linux Foundation Trademark
  677. * Policy to indicate compliance with the IAccessible2 specification.
  678. *
  679. ************************************************************************/
  680. /** Collection of roles
  681. This enumerator defines an extended set of accessible roles of objects implementing
  682. the %IAccessible2 interface. These roles are in addition to the MSAA roles obtained
  683. through the MSAA get_accRole method. Examples are 'footnote', 'heading', and
  684. 'label'. You obtain an object's %IAccessible2 roles by calling IAccessible2::role.
  685. */
  686. enum IA2Role {
  687. /** Unknown role. The object contains some Accessible information, but its
  688. role is not known.
  689. */
  690. IA2_ROLE_UNKNOWN = 0,
  691. /** An object that can be drawn into and to manage events from the objects
  692. drawn into it. Also refer to ::IA2_ROLE_FRAME,
  693. ::IA2_ROLE_GLASS_PANE, and ::IA2_ROLE_LAYERED_PANE.
  694. */
  695. IA2_ROLE_CANVAS = 0x401,
  696. /// A caption describing another object.
  697. IA2_ROLE_CAPTION,
  698. /// Used for check buttons that are menu items.
  699. IA2_ROLE_CHECK_MENU_ITEM,
  700. /// A specialized dialog that lets the user choose a color.
  701. IA2_ROLE_COLOR_CHOOSER,
  702. /// A date editor.
  703. IA2_ROLE_DATE_EDITOR,
  704. /** An iconified internal frame in an ::IA2_ROLE_DESKTOP_PANE.
  705. Also refer to ::IA2_ROLE_INTERNAL_FRAME.
  706. */
  707. IA2_ROLE_DESKTOP_ICON,
  708. /** A desktop pane. A pane that supports internal frames and iconified
  709. versions of those internal frames. Also refer to ::IA2_ROLE_INTERNAL_FRAME.
  710. */
  711. IA2_ROLE_DESKTOP_PANE,
  712. /** A directory pane. A pane that allows the user to navigate through
  713. and select the contents of a directory. May be used by a file chooser.
  714. Also refer to ::IA2_ROLE_FILE_CHOOSER.
  715. */
  716. IA2_ROLE_DIRECTORY_PANE,
  717. /** An editable text object in a toolbar. <b>Deprecated.</b>
  718. The edit bar role was meant for a text area in a tool bar. However, to detect
  719. a text area in a tool bar the AT can query the parent.
  720. */
  721. IA2_ROLE_EDITBAR,
  722. /// Embedded (OLE) object.
  723. IA2_ROLE_EMBEDDED_OBJECT,
  724. /// Text that is used as an endnote (footnote at the end of a chapter or section).
  725. IA2_ROLE_ENDNOTE,
  726. /** A file chooser. A specialized dialog that displays the files in the
  727. directory and lets the user select a file, browse a different directory,
  728. or specify a filename. May use the directory pane to show the contents of
  729. a directory.
  730. Also refer to ::IA2_ROLE_DIRECTORY_PANE.
  731. */
  732. IA2_ROLE_FILE_CHOOSER,
  733. /** A font chooser. A font chooser is a component that lets the user pick
  734. various attributes for fonts.
  735. */
  736. IA2_ROLE_FONT_CHOOSER,
  737. /** Footer of a document page.
  738. Also refer to ::IA2_ROLE_HEADER.
  739. */
  740. IA2_ROLE_FOOTER,
  741. /// Text that is used as a footnote. Also refer to ::IA2_ROLE_ENDNOTE.
  742. IA2_ROLE_FOOTNOTE,
  743. /** A container of form controls. An example of the use of this role is to
  744. represent an HTML FORM tag.
  745. */
  746. IA2_ROLE_FORM,
  747. /** Frame role. A top level window with a title bar, border, menu bar, etc.
  748. It is often used as the primary window for an application. Also refer to
  749. ::IA2_ROLE_CANVAS and the MSAA roles of dialog and window.
  750. */
  751. IA2_ROLE_FRAME,
  752. /** A glass pane. A pane that is guaranteed to be painted on top of all panes
  753. beneath it. Also refer to ::IA2_ROLE_CANVAS, ::IA2_ROLE_INTERNAL_FRAME, and
  754. ::IA2_ROLE_ROOT_PANE.
  755. */
  756. IA2_ROLE_GLASS_PANE,
  757. /** Header of a document page.
  758. Also refer to ::IA2_ROLE_FOOTER.
  759. */
  760. IA2_ROLE_HEADER,
  761. /// Heading. Use the IAccessible2::attributes level attribute to determine the heading level.
  762. IA2_ROLE_HEADING,
  763. /// A small fixed size picture, typically used to decorate components.
  764. IA2_ROLE_ICON,
  765. /** An image map object. Usually a graphic with multiple hotspots, where
  766. each hotspot can be activated resulting in the loading of another document
  767. or section of a document.
  768. */
  769. IA2_ROLE_IMAGE_MAP,
  770. /** An object which is used to allow input of characters not found on a keyboard,
  771. such as the input of Chinese characters on a Western keyboard.
  772. */
  773. IA2_ROLE_INPUT_METHOD_WINDOW,
  774. /** An internal frame. A frame-like object that is clipped by a desktop pane.
  775. The desktop pane, internal frame, and desktop icon objects are often used to
  776. create multiple document interfaces within an application.
  777. Also refer to ::IA2_ROLE_DESKTOP_ICON, ::IA2_ROLE_DESKTOP_PANE, and ::IA2_ROLE_FRAME.
  778. */
  779. IA2_ROLE_INTERNAL_FRAME,
  780. /// An object used to present an icon or short string in an interface.
  781. IA2_ROLE_LABEL,
  782. /** A layered pane. A specialized pane that allows its children to be drawn
  783. in layers, providing a form of stacking order. This is usually the pane that
  784. holds the menu bar as well as the pane that contains most of the visual
  785. components in a window.
  786. Also refer to ::IA2_ROLE_CANVAS, ::IA2_ROLE_GLASS_PANE, and ::IA2_ROLE_ROOT_PANE.
  787. */
  788. IA2_ROLE_LAYERED_PANE,
  789. /** A section whose content is parenthetic or ancillary to the main content
  790. of the resource.
  791. */
  792. IA2_ROLE_NOTE,
  793. /** A specialized pane whose primary use is inside a dialog.
  794. Also refer to MSAA's dialog role.
  795. */
  796. IA2_ROLE_OPTION_PANE,
  797. /** An object representing a page of document content. It is used in documents
  798. which are accessed by the user on a page by page basis.
  799. */
  800. IA2_ROLE_PAGE,
  801. /// A paragraph of text.
  802. IA2_ROLE_PARAGRAPH,
  803. /** A radio button that is a menu item.
  804. Also refer to MSAA's button and menu item roles.
  805. */
  806. IA2_ROLE_RADIO_MENU_ITEM,
  807. /** An object which is redundant with another object in the accessible hierarchy.
  808. ATs typically ignore objects with this role.
  809. */
  810. IA2_ROLE_REDUNDANT_OBJECT,
  811. /** A root pane. A specialized pane that has a glass pane and a layered pane
  812. as its children.
  813. Also refer to ::IA2_ROLE_GLASS_PANE and ::IA2_ROLE_LAYERED_PANE
  814. */
  815. IA2_ROLE_ROOT_PANE,
  816. /** A ruler such as those used in word processors.
  817. */
  818. IA2_ROLE_RULER,
  819. /** A scroll pane. An object that allows a user to incrementally view a large
  820. amount of information. Its children can include scroll bars and a viewport.
  821. Also refer to ::IA2_ROLE_VIEW_PORT and MSAA's scroll bar role.
  822. */
  823. IA2_ROLE_SCROLL_PANE,
  824. /** A container of document content. An example of the use of this role is to
  825. represent an HTML DIV tag. A section may be used as a region. A region is a
  826. group of elements that together form a perceivable unit. A region does not
  827. necessarily follow the logical structure of the content, but follows the
  828. perceivable structure of the page. A region may have an attribute in the set
  829. of IAccessible2::attributes which indicates that it is "live". A live region
  830. is content that is likely to change in response to a timed change, a user
  831. event, or some other programmed logic or event.
  832. */
  833. IA2_ROLE_SECTION,
  834. /// Object with graphical representation used to represent content on draw pages.
  835. IA2_ROLE_SHAPE,
  836. /** A split pane. A specialized panel that presents two other panels at the
  837. same time. Between the two panels is a divider the user can manipulate to make
  838. one panel larger and the other panel smaller.
  839. */
  840. IA2_ROLE_SPLIT_PANE,
  841. /** An object that forms part of a menu system but which can be "undocked"
  842. from or "torn off" the menu system to exist as a separate window.
  843. */
  844. IA2_ROLE_TEAR_OFF_MENU,
  845. /// An object used as a terminal emulator.
  846. IA2_ROLE_TERMINAL,
  847. /// Collection of objects that constitute a logical text entity.
  848. IA2_ROLE_TEXT_FRAME,
  849. /** A toggle button. A specialized push button that can be checked or unchecked,
  850. but does not provide a separate indicator for the current state.
  851. Also refer to MSAA's roles of push button, check box, and radio button.
  852. <BR><B>Note:</B> IA2_ROLE_TOGGLE_BUTTON should not be used. Instead, use MSAA's
  853. ROLE_SYSTEM_PUSHBUTTON and STATE_SYSTEM_PRESSED.
  854. */
  855. IA2_ROLE_TOGGLE_BUTTON,
  856. /** A viewport. An object usually used in a scroll pane. It represents the
  857. portion of the entire data that the user can see. As the user manipulates
  858. the scroll bars, the contents of the viewport can change.
  859. Also refer to ::IA2_ROLE_SCROLL_PANE.
  860. */
  861. IA2_ROLE_VIEW_PORT,
  862. /** An object containing content which is complementary to the main content of
  863. a document, but remains meaningful when separated from the main content. There
  864. are various types of content that would appropriately have this role. For example,
  865. in the case where content is delivered via a web portal to a web browser, this may
  866. include but not be limited to show times, current weather, related articles, or
  867. stocks to watch. The complementary role indicates that contained content is relevant
  868. to the main content. If the complementary content is completely separable main
  869. content, it may be appropriate to use a more general role.
  870. */
  871. IA2_ROLE_COMPLEMENTARY_CONTENT,
  872. /** An object representing a navigational landmark, a region on a page to
  873. which the user may want quick access, such as a navigation area, a search
  874. facility or the main content of a page.
  875. */
  876. IA2_ROLE_LANDMARK,
  877. /**
  878. * A bar that serves as a level indicator to, for instance, show
  879. * the strength of a password or the charge of a battery.
  880. */
  881. IA2_ROLE_LEVEL_BAR,
  882. /** Content previously deleted or proposed for deletion, e.g. in revision
  883. history or a content view providing suggestions from reviewers.
  884. */
  885. IA2_ROLE_CONTENT_DELETION,
  886. /** Content previously inserted or proposed for insertion, e.g. in revision
  887. history or a content view providing suggestions from reviewers.
  888. */
  889. IA2_ROLE_CONTENT_INSERTION,
  890. /// A section of content that is quoted from another source.
  891. IA2_ROLE_BLOCK_QUOTE,
  892. /** A run of content that is marked or highlighted, such as for reference
  893. purposes, or to call it out as having a special purpose that is clear from
  894. context. If the mark is used in conjuction with a related content section
  895. in the document, then IA2_RELATION_DETAILS should be used to link the
  896. related content (and the reverse relation IA2_RELATION_DETAILS_FOR should
  897. link back to the IA2_ROLE_MARK object). If the mark has related information
  898. in a tooltip, or as hidden text, then accDescription should be used to
  899. provide this information.
  900. */
  901. IA2_ROLE_MARK,
  902. /** A grouping for content that is called out as a proposed change from the
  903. current version of the document, such as by a reviewer of the content.
  904. Should include as children one or both of:
  905. IA2_ROLE_CONTENT_DELETION and IA2_ROLE_CONTENT_INSERTION, in any order,
  906. to indicate what the actual change is.
  907. If the suggestion is accepted, the implementation should change the role to
  908. a generic one such as IA2_ROLE_SECTION or IA2_ROLE_TEXT_FRAME.
  909. */
  910. IA2_ROLE_SUGGESTION,
  911. /** A single comment, typically user-generated content. Supports reply
  912. hierarchies via descendant structure, e.g. a child comment is a reply
  913. to the parent comment. Supports groupPosition() method to determine
  914. reply level (top comment is 1), as well as set size and position in set
  915. within that level.
  916. */
  917. IA2_ROLE_COMMENT
  918. };
  919. /*************************************************************************
  920. *
  921. * File Name (AccessibleStates.idl)
  922. *
  923. * IAccessible2 IDL Specification
  924. *
  925. * Copyright (c) 2007, 2010 Linux Foundation
  926. * Copyright (c) 2006 IBM Corporation
  927. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  928. * All rights reserved.
  929. *
  930. *
  931. * Redistribution and use in source and binary forms, with or without
  932. * modification, are permitted provided that the following conditions
  933. * are met:
  934. *
  935. * 1. Redistributions of source code must retain the above copyright
  936. * notice, this list of conditions and the following disclaimer.
  937. *
  938. * 2. Redistributions in binary form must reproduce the above
  939. * copyright notice, this list of conditions and the following
  940. * disclaimer in the documentation and/or other materials
  941. * provided with the distribution.
  942. *
  943. * 3. Neither the name of the Linux Foundation nor the names of its
  944. * contributors may be used to endorse or promote products
  945. * derived from this software without specific prior written
  946. * permission.
  947. *
  948. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  949. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  950. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  951. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  952. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  953. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  954. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  955. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  956. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  957. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  958. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  959. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  960. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  961. *
  962. * This BSD License conforms to the Open Source Initiative "Simplified
  963. * BSD License" as published at:
  964. * http://www.opensource.org/licenses/bsd-license.php
  965. *
  966. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  967. * mark may be used in accordance with the Linux Foundation Trademark
  968. * Policy to indicate compliance with the IAccessible2 specification.
  969. *
  970. ************************************************************************/
  971. typedef long AccessibleStates;
  972. /** %IAccessible2 specific state bit constants
  973. This enum defines the state bits returned by IAccessible2::states. The
  974. %IAccessible2 state bits are in addition to those returned by MSAA.
  975. */
  976. enum IA2States {
  977. /** Indicates a window is currently the active window, or is an active subelement
  978. within a container or table.
  979. This state can be used to indicate the current active item in a container, even
  980. if the container itself is not currently active. In other words this would indicate
  981. the item that will get focus if you tab to the container.
  982. This information is important for knowing what to report for trees and potentially
  983. other containers in a virtual buffer.
  984. Also, see ::IA2_STATE_MANAGES_DESCENDANTS for more information.
  985. */
  986. IA2_STATE_ACTIVE = 0x1,
  987. /** Indicates that the object is armed.
  988. Used to indicate that the control is "pressed" and will be invoked when the
  989. actuator, e.g. a mouse button, is "released". An AT which either monitors the
  990. mouse or synthesizes mouse events might need to know that, and possibly a talking
  991. interface would even let the user know about it. It could also potentially be
  992. useful to on screen keyboards or test tools since the information does indicate
  993. something about the state of the interface, for example, code operating asynchronously
  994. might need to wait for the armed state to change before doing something else.
  995. */
  996. IA2_STATE_ARMED = 0x2,
  997. /** Indicates the user interface object corresponding to this object no longer exists. */
  998. IA2_STATE_DEFUNCT = 0x4,
  999. /** An object with this state has a caret and implements the IAccessibleText interface.
  1000. Such fields may be read-only, so STATE_SYSTEM_READONLY is valid in combination
  1001. with IA2_STATE_EDITABLE.
  1002. */
  1003. IA2_STATE_EDITABLE = 0x8,
  1004. /** Indicates the orientation of this object is horizontal. */
  1005. IA2_STATE_HORIZONTAL = 0x10,
  1006. /** Indicates this object is minimized and is represented only by an icon. */
  1007. IA2_STATE_ICONIFIED = 0x20,
  1008. /** Indicates an input validation failure. */
  1009. IA2_STATE_INVALID_ENTRY = 0x40,
  1010. /** Indicates that this object manages its children.
  1011. Note: Due to the fact that MSAA's WinEvents don't allow the active child index
  1012. to be passed on the IA2_EVENT_ACTIVE_DESCENDANT_CHANGED event, the manages
  1013. descendants scheme can't be used. Instead the active child object has to fire
  1014. MSAA's EVENT_OBJECT_FOCUS. In a future release a new event mechanism may be
  1015. added to provide for event specific data to be passed with the event. At that
  1016. time the IA2_EVENT_ACTIVE_DECENDENT_CHANGED event and
  1017. IA2_STATE_MANAGES_DESCENDANTS state would be useful.
  1018. */
  1019. IA2_STATE_MANAGES_DESCENDANTS = 0x80,
  1020. /** Indicates that an object is modal.
  1021. Modal objects have the behavior that something must be done with the object
  1022. before the user can interact with an object in a different window.
  1023. */
  1024. IA2_STATE_MODAL = 0x100,
  1025. /** Indicates this text object can contain multiple lines of text. */
  1026. IA2_STATE_MULTI_LINE = 0x200,
  1027. /** Indicates this object paints every pixel within its rectangular region. */
  1028. IA2_STATE_OPAQUE = 0x400,
  1029. /** Indicates that user interaction is required.
  1030. An example of when this state is used is when a field in a form must be filled
  1031. before a form can be processed.
  1032. */
  1033. IA2_STATE_REQUIRED = 0x800,
  1034. /** Indicates an object which supports text selection.
  1035. Note: This is different than MSAA STATE_SYSTEM_SELECTABLE.
  1036. */
  1037. IA2_STATE_SELECTABLE_TEXT = 0x1000,
  1038. /** Indicates that this text object can contain only a single line of text. */
  1039. IA2_STATE_SINGLE_LINE = 0x2000,
  1040. /** Indicates that the accessible object is stale.
  1041. This state is used when the accessible object no longer accurately
  1042. represents the state of the object which it is representing such as when an
  1043. object is transient or when an object has been or is in the process of being
  1044. destroyed or when the object's index in its parent has changed.
  1045. */
  1046. IA2_STATE_STALE = 0x4000,
  1047. /** Indicates that the object implements autocompletion.
  1048. This state indicates that a text control will respond to the input of
  1049. one ore more characters and cause a sub-item to become selected. The
  1050. selection may also result in events fired on the parent object.
  1051. */
  1052. IA2_STATE_SUPPORTS_AUTOCOMPLETION = 0x8000,
  1053. /** Indicates this object is transient.
  1054. An object has this state when its parent object has the state ::IA2_STATE_MANAGES_DESCENDANTS.
  1055. For example, a list item object may be managed by its parent list object and may only
  1056. exist as long as the object is actually rendered. Similarly a table cell's accessible
  1057. object may exist only while the cell has focus. However, from the perspective of an
  1058. assistive technology a transient object behaves like a non-transient object. As a
  1059. result it is likely that this state is not of use to an assistive technology, but it
  1060. is provided in case an assistive technology determines that knowledge of the transient
  1061. nature of the object is useful and also for harmony with the Linux accessibility API.
  1062. Also, see ::IA2_STATE_MANAGES_DESCENDANTS for more information.
  1063. */
  1064. IA2_STATE_TRANSIENT = 0x10000,
  1065. /** Indicates the orientation of this object is vertical. */
  1066. IA2_STATE_VERTICAL = 0x20000,
  1067. /** Indicates this object is checkable.
  1068. The standard checkable objects are check boxes, radio buttons, check box menu
  1069. items, radio menu items, and toggle buttons. Since assistive technology will
  1070. determine that these objects are checkable via the object's role the checkable
  1071. state is not required. However, this state is necessary in those cases where
  1072. an object has a role which is not one of the previously mentioned roles. An
  1073. example is a table cell which indicates whether or not an email has an attachment,
  1074. whether or not an mail is considered spam, and whether or not an email has been read.
  1075. */
  1076. IA2_STATE_CHECKABLE = 0x40000,
  1077. /** Indicates this object is pinned.
  1078. This state indicates that an object is fixed at a certain location. One example
  1079. is a browser tab that when pinned cannot be moved until unpinned. Another example
  1080. is a movable or floating object that when pinned remains in its pinned location
  1081. until being unpinned.
  1082. */
  1083. IA2_STATE_PINNED = 0x80000
  1084. };
  1085. /*************************************************************************
  1086. *
  1087. * File Name (Accessible2.idl)
  1088. *
  1089. * IAccessible2 IDL Specification
  1090. *
  1091. * Copyright (c) 2007, 2013 Linux Foundation
  1092. * Copyright (c) 2006 IBM Corporation
  1093. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  1094. * All rights reserved.
  1095. *
  1096. *
  1097. * Redistribution and use in source and binary forms, with or without
  1098. * modification, are permitted provided that the following conditions
  1099. * are met:
  1100. *
  1101. * 1. Redistributions of source code must retain the above copyright
  1102. * notice, this list of conditions and the following disclaimer.
  1103. *
  1104. * 2. Redistributions in binary form must reproduce the above
  1105. * copyright notice, this list of conditions and the following
  1106. * disclaimer in the documentation and/or other materials
  1107. * provided with the distribution.
  1108. *
  1109. * 3. Neither the name of the Linux Foundation nor the names of its
  1110. * contributors may be used to endorse or promote products
  1111. * derived from this software without specific prior written
  1112. * permission.
  1113. *
  1114. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  1115. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  1116. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  1117. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  1118. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  1119. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  1120. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  1121. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  1122. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1123. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  1124. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  1125. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  1126. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  1127. *
  1128. * This BSD License conforms to the Open Source Initiative "Simplified
  1129. * BSD License" as published at:
  1130. * http://www.opensource.org/licenses/bsd-license.php
  1131. *
  1132. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  1133. * mark may be used in accordance with the Linux Foundation Trademark
  1134. * Policy to indicate compliance with the IAccessible2 specification.
  1135. *
  1136. ************************************************************************/
  1137. /** @mainpage
  1138. @section _interfaces Interfaces
  1139. IAccessible2\n
  1140. IAccessible2_2\n
  1141. IAccessible2_3\n
  1142. IAccessible2_4\n
  1143. IAccessibleAction\n
  1144. IAccessibleApplication\n
  1145. IAccessibleComponent\n
  1146. IAccessibleDocument\n
  1147. IAccessibleEditableText\n
  1148. IAccessibleHypertext\n
  1149. IAccessibleHypertext2\n
  1150. IAccessibleHyperlink\n
  1151. IAccessibleImage\n
  1152. IAccessibleRelation\n
  1153. IAccessibleTable [Deprecated]\n
  1154. IAccessibleTable2\n
  1155. IAccessibleTableCell\n
  1156. IAccessibleText\n
  1157. IAccessibleText2\n
  1158. IAccessibleTextSelectionContainer\n
  1159. IAccessibleValue
  1160. @section _structs Structs
  1161. IA2Locale\n
  1162. IA2Range\n
  1163. IA2TableModelChange\n
  1164. IA2TextSegment\n
  1165. IA2TextSelection
  1166. @section _enums Enums
  1167. ::IA2Actions values are predefined actions for use when implementing support for HTML5 media.\n
  1168. ::IA2CoordinateType values define the requested coordinate type (screen or parent window).\n
  1169. ::IA2EventID values identify events.\n
  1170. ::IA2Role values defines roles which are in addition to the existing MSAA roles.\n
  1171. ::IA2ScrollType values define where to place an object or substring on the screen.\n
  1172. ::IA2States values define states which are in addition to the existing MSAA states.\n
  1173. ::IA2TableModelChangeType values describe the kinds of changes made to a table (insert, delete, update).\n
  1174. ::IA2TextBoundaryType values define the requested text unit (character, word, sentence, line, paragraph).\n
  1175. ::IA2TextSpecialOffsets values define special offsets for use in the text interfaces.
  1176. @section _constants Constants
  1177. @ref grpRelations
  1178. @section _misc Miscellaneous
  1179. @ref _licensePage "BSD License"\n
  1180. @ref _generalInfo "General Information"\n
  1181. @page _licensePage BSD License
  1182. %IAccessible2 IDL Specification
  1183. Copyright (c) 2007, 2013 Linux Foundation\n
  1184. Copyright (c) 2006 IBM Corporation\n
  1185. Copyright (c) 2000, 2006 Sun Microsystems, Inc.\n
  1186. All rights reserved.
  1187. Redistribution and use in source and binary forms, with or without
  1188. modification, are permitted provided that the following conditions
  1189. are met:
  1190. 1. Redistributions of source code must retain the above copyright
  1191. notice, this list of conditions and the following disclaimer.
  1192. 2. Redistributions in binary form must reproduce the above
  1193. copyright notice, this list of conditions and the following
  1194. disclaimer in the documentation and/or other materials
  1195. provided with the distribution.
  1196. 3. Neither the name of the Linux Foundation nor the names of its
  1197. contributors may be used to endorse or promote products
  1198. derived from this software without specific prior written
  1199. permission.
  1200. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  1201. CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  1202. INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  1203. MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  1204. DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  1205. CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  1206. SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  1207. NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  1208. LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1209. HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  1210. CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  1211. OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  1212. EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  1213. This BSD License conforms to the Open Source Initiative "Simplified
  1214. BSD License" as published at:
  1215. http://www.opensource.org/licenses/bsd-license.php
  1216. %IAccessible2 is a trademark of the Linux Foundation. The %IAccessible2
  1217. mark may be used in accordance with the
  1218. <a href="http://www.linuxfoundation.org/collaborate/workgroups/accessibility/trademark-policy">
  1219. Linux Foundation Trademark Policy</a> to indicate compliance with the %IAccessible2 specification.
  1220. @page _generalInfo General Information
  1221. The following information is applicable to two or more interfaces.
  1222. @ref _errors\n
  1223. @ref _memory\n
  1224. &nbsp;&nbsp;@ref _arrayConsideration\n
  1225. @ref _indexes\n
  1226. @ref _enums\n
  1227. @ref _specialOffsets\n
  1228. @ref _dicoveringInterfaces\n
  1229. @ref _changingInterfaces\n
  1230. @ref _applicationInfo\n
  1231. @ref _childIDs\n
  1232. @ref _variants\n
  1233. @ref _iaaction-iahyperlink\n
  1234. @ref _trademark
  1235. @section _errors Error Handling
  1236. HRESULT values are defined by the Microsoft&reg; Win32&reg; API. For more information, refer to
  1237. <a href="http://msdn.microsoft.com/en-us/library/windows/desktop/aa378137%28v=vs.85%29.aspx">
  1238. Interpreting HRESULT Values</a> in MSDN&reg;.
  1239. Note that the S_FALSE return value is considered a non-error value and the
  1240. SUCCEEDED macro will return TRUE. S_FALSE is used when there is no failure
  1241. but there was nothing valid to return, e.g. in IAccessible2::attributes when
  1242. there are no attributes. When S_FALSE is returned [out] pointer types should
  1243. be NULL and [out] longs should generally be 0, but sometimes -1 is used such
  1244. as IAccessible2::indexInParent, IAccessibleText::caretOffset, and
  1245. IAccessibleHypertext::hyperlinkIndex.
  1246. Note that for BSTR [out] variables common COM practice is that the server does
  1247. the SysAllocString and the client does the SysFreeString. Also note that when
  1248. NULL is returned there is no need for the client to call SysFreeString. Please
  1249. refer to the documentation for each method for more details regarding error handling.
  1250. @section _memory Memory Management
  1251. The following memory management issues should be considered:
  1252. @li Although [out] BSTR variables are declared by the client, their space is
  1253. allocated by the server. They need to be freed with SysFreeString by the
  1254. client at end of life; the same is true when BSTRs are used in structs or
  1255. arrays which are passed to the server.
  1256. @li If there is no valid [out] BSTR to return, the server should return S_FALSE and
  1257. assign NULL to the output, e.g. *theOutBSTR = NULL;.
  1258. @li COM interfaces need to be referenced with AddRef when used and dereferenced
  1259. with Release at end of life.
  1260. @li Single [out] longs, HWNDs, booleans, and structs are declared by the caller
  1261. and passed by reference. The marshaller does all the memory management.
  1262. The following articles may be helpful for understanding memory management issues:
  1263. @li An article by Don Box in a
  1264. <a href="http://www.microsoft.com/msj/1196/activex1196.aspx">Q & A section</a>
  1265. of the November 1996 edition of the Microsoft Systems Journal.
  1266. @li A posting to a CodeGuru forum,
  1267. <a href="http://www.codeguru.com/forum/showthread.php?t=364511">Windows SDK
  1268. String: What are the rules for BSTR allocation and deallocation?</a>
  1269. @subsection _arrayConsideration Special Consideration when using Arrays
  1270. There are several methods which return arrays. In the case of IAccessible2::relations
  1271. and IAccessibleRelation::targets the client must allocate and free the arrays.
  1272. For the remaining methods which return arrays, the server must allocate the array
  1273. and the client must free the array when no longer needed. These methods are
  1274. IAccessible2::extendedStates, IAccessible2::localizedExtendedStates,
  1275. IAccessible2_2::relationTargetsOfType, IAccessibleAction::keyBinding,
  1276. IAccessibleHypertext2::hyperlinks, IAccessibleTable::selectedChildren,
  1277. IAccessibleTable::selectedColumns, IAccessibleTable::selectedRows,
  1278. IAccessibleTable2::selectedCells, IAccessibleTable2::selectedColumns,
  1279. IAccessibleTable2::selectedRows, IAccessibleTableCell::columnHeaderCells,
  1280. and IAccessibleTableCell::rowHeaderCells.
  1281. For those methods, the server must allocate both the top level array and any storage
  1282. associated with it, e.g. for BSTRs. The server must allocate the arrays with
  1283. CoTaskMemAlloc and any BSTRs with SysAllocString. The client must use CoTaskMemFree
  1284. to free the array and any BSTRs must be freed with SysFreeString.
  1285. Also, the IDL for IAccessible2::extendedStates, IAccessible2::localizedExtendedStates,
  1286. IAccessibleAction::keyBinding, IAccessibleTable::selectedChildren,
  1287. IAccessibleTable::selectedColumns, and IAccessibleTable::selectedRows includes an
  1288. extraneous [in] parameter for the caller to specify the max size of the array.
  1289. This parameter will be ignored by the COM server.
  1290. @section _indexes Zero and One Based Indexes
  1291. Unless otherwise specified all offsets and indexes are 0 based.
  1292. @section _enums Enums
  1293. Note that enums start at 0.
  1294. @section _specialOffsets Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods
  1295. IAccessibleText and IAccessibleEditableText can use one or more of the following
  1296. special offset values. They are defined in the ::IA2TextSpecialOffsets enum.
  1297. @li Using ::IA2_TEXT_OFFSET_LENGTH (-1) as an offset in any of the IAccessibleText or
  1298. IAccessibleEditableText methods is the same as specifying the length of the string.
  1299. @li Using ::IA2_TEXT_OFFSET_CARET (-2) as an offset for IAccessibleText::textBeforeOffset,
  1300. IAccessibleText::textAtOffset, and IAccessibleText::textAfterOffset indicates that the
  1301. text related to the physical location of the caret should be used. This is needed for
  1302. applications that consider the character offset of the end of one line (as reached by
  1303. pressing the End key) the same as the offset of the first character on the next line.
  1304. Since the same offset is associated with two different lines a special means is needed
  1305. to fetch text from the line where the caret is physically located.
  1306. @section _dicoveringInterfaces Discovery of Interfaces
  1307. In general AT (Assistive Technology) should try IAccessible2 interfaces, followed by using
  1308. the MSAA (Microsoft&reg; Active Accessibility&reg;) interfaces. (In cases where the an application
  1309. is known to have custom interfaces which provide information not supplied by IAccessible2
  1310. or MSAA, then those custom interfaces can be used.) The AT can then, by default, support
  1311. unknown IAccessible2/MSAA applications, without the application developers having to request
  1312. AT vendors for support on an individual application by application basis.
  1313. When you have a reference to an IAccessible and require a reference to an IAccessible2 use
  1314. QueryService as follows:
  1315. @code
  1316. // pAcc is a reference to the accessible object's IAccessible interface.
  1317. IServiceProvider *pService = NULL;
  1318. hr = pAcc->QueryInterface(IID_IServiceProvider, (void **)&pService);
  1319. if(SUCCEEDED(hr)) {
  1320. IAccessible2 *pIA2 = NULL;
  1321. hr = pService->QueryService(IID_IAccessible, IID_IAccessible2, (void**)&pIA2);
  1322. if (SUCCEEDED(hr) && pIA2) {
  1323. // The control supports IAccessible2.
  1324. // pIA2 is the reference to the accessible object's IAccessible2 interface.
  1325. }
  1326. }
  1327. @endcode
  1328. @section _changingInterfaces Changing between Accessible Interfaces
  1329. Note that developers must always implement MSAA's IAccessible and, if needed, some
  1330. of the interfaces in the set of IAccessible2 interfaces. Although the IAccessible2
  1331. IDL is coded such that IAccessible2 is a subclass of MSAA's IAccessible, none of
  1332. MSAA's IAccessible methods are redefined by IAccessible2.
  1333. QueryService must be used to switch from a reference to an MSAA IAccessible interface
  1334. to another interface. This has been
  1335. <a href="http://www.atia.org/files/public/Introducing_IAccessibleEx.doc">
  1336. documented</a> and the pertinent facts have been extracted below:
  1337. @par
  1338. Why use QueryService instead of just using QueryInterface to get IAccessibleEx
  1339. directly? The reason is that since MSAA 2.0, clients don't talk to a server's
  1340. IAccessible interface directly; instead they talk to an intermediate MSAA-provided
  1341. wrapper that calls through to the original IAccessible. This wrapper provides services
  1342. such as implementing IDispatch, supplying information from MSAA 2.0's Dynamic Annotation
  1343. service, and scaling locations when running on Windows Vista with DPI scaling enabled.
  1344. QueryService is the supported way to expose additional interfaces from an existing
  1345. IAccessible and was originally used by MSHTML to expose IHTMLElement objects corresponding
  1346. to IAccessibles. QueryService is often more convenient for servers to implement than
  1347. QueryInterface because it does not have the same requirements for preserving object
  1348. identity or symmetry/transitivity as QueryInterface, so QueryService allows servers to
  1349. easily implement the interface on the same object or a separate object. The latter is
  1350. often hard to do with QueryInterface unless the original object supports aggregation.
  1351. Two related references in MSDN&reg; are:
  1352. @li <a href="http://msdn.microsoft.com/en-us/library/ms696078(VS.85).aspx">
  1353. "Using QueryService to expose a native object model interface for an IAccessible object"</a>
  1354. @li <a href="http://msdn.microsoft.com/en-us/library/ms528415.aspx#acc_obj">
  1355. "Accessing the Internet Explorer Object Associated with an Accessible Object"</a>
  1356. Based on this information from Microsoft, QueryService must be used to switch back and forth
  1357. between a reference to an MSAA IAccessible interface and any of the IAccessible2 interfaces.
  1358. Regarding switching between any of the IAccessible2 interfaces, applications implementing
  1359. IAccessible2 should implement the IAccessible2 interfaces on a single object since ATs
  1360. will be using QueryInterface to switch between the IAccessilbe2 interfaces. Implementing
  1361. the IAccessible2 interfaces on separate objects would require the use of QueryService.
  1362. There is one exception, IAccessibleApplication can be implemented on a separate object so
  1363. its common code doesn't have to be included in each accessible object. ATs should use
  1364. QueryService to access IAccessibleApplication.
  1365. @section _applicationInfo Access to Information about the Application
  1366. Servers implementing IAccessible2 should provide access to the IAccessibleApplication
  1367. interface via QueryService from any object so that ATs can easily determine specific
  1368. information about the application such as its name or version.
  1369. @section _childIDs Child IDs
  1370. The IAccessible2 interfaces do not support child IDs, i.e. simple child elements.
  1371. Full accessible objects must be created for each object that supports IAccessible2.
  1372. Therefore MSAA's get_accChild should never return a child ID (other than CHILDID_SELF)
  1373. for an object that implements any of the IAccessible2 interfaces.
  1374. Microsoft's UI Automation specification has the same limitation and this was resolved
  1375. in the UI Automation Express specification by adding IAccessibleEx::GetObjectForChild
  1376. and IAccessibleEx::GetIAccessiblePair. These methods allow mapping back and forth
  1377. between an IAccessibleEx and an {IAccessible, Child ID} pair. A future version of
  1378. IAccessible2 may include similar methods to map back and forth between an IAccessible2
  1379. and an {IAccessible, Child ID} pair.
  1380. @section _variants VARIANTs
  1381. Some methods return a VARIANT. Implementers need to make sure that the return type is
  1382. specified, i.e. VT_I4, VT_IDISPATCH, etc. The methods that return VARIANTs are
  1383. IAccessibleHyperlink::anchor, IAccessibleHyperlink::anchorTarget, IAccessibleValue::currentValue,
  1384. IAccessibleValue::maximumValue, IAccessibleValue::minimumValue.
  1385. @section _iaaction-iahyperlink IAccessibleHyperlink as subclass of IAccessibleAction
  1386. In this version of the IDL, IAccessibleHyperlink is a subclass of IAccessibleAction.
  1387. However, there is no practical need for that inheritance and in some cases, such as
  1388. an image map of smart tags, it doesn't make sense because such an image map doesn't
  1389. have actionable objects; it's the secondary smart tags that are actionable. As a
  1390. result, implementations should not rely on the inheritance as it may be removed in
  1391. a later version of the IDL.
  1392. @section _trademark Trademark Attribution
  1393. The names of actual companies and products mentioned herein may be the trademarks of
  1394. their respective owners. In particular, Active Accessibility, Microsoft, MSDN, and Win32
  1395. are trademarks of the Microsoft group of companies in the U.S.A. and/or other countries.
  1396. **/
  1397. /** A structure defining the locale of an accessible object.
  1398. IAccessible2::locale returns this struct.
  1399. */
  1400. typedef struct IA2Locale {
  1401. BSTR language; ///< ISO 639-1 Alpha-2 two character language code
  1402. BSTR country; ///< ISO 3166-1 Alpha-2 two character country code
  1403. BSTR variant; ///< Application specific variant of the locale
  1404. } IA2Locale;
  1405. /** @brief This interface exposes the primary set of information about an
  1406. IAccessible2 enabled accessible object.
  1407. This interface must always be provided for objects that support some
  1408. portion of the collection of the %IAccessible2 interfaces.
  1409. Please refer to @ref _changingInterfaces "Changing between Accessible Interfaces"
  1410. for special considerations related to use of the MSAA IAccessible interface and
  1411. the set of %IAccessible2 interfaces.
  1412. */
  1413. [object, uuid(E89F726E-C4F4-4c19-BB19-B647D7FA8478)]
  1414. interface IAccessible2 : IAccessible
  1415. {
  1416. /** @brief Returns the number of accessible relations for this object.
  1417. @param [out] nRelations
  1418. @retval S_OK
  1419. */
  1420. [propget] HRESULT nRelations
  1421. (
  1422. [out, retval] long *nRelations
  1423. );
  1424. /** @brief Returns one accessible relation for this object.
  1425. @param [in] relationIndex
  1426. 0 based
  1427. @param [out] relation
  1428. @retval S_OK
  1429. @retval E_INVALIDARG if bad [in] passed
  1430. */
  1431. [propget] HRESULT relation
  1432. (
  1433. [in] long relationIndex,
  1434. [out, retval] IAccessibleRelation **relation
  1435. );
  1436. /** @brief Returns multiple accessible relations for this object.
  1437. @param [in] maxRelations
  1438. maximum size of the array allocated by the client
  1439. @param [out] relations
  1440. The array of accessible relation objects. Note that this array is to be
  1441. allocated by the client and freed when no longer needed. Refer to @ref
  1442. _arrayConsideration "Special Consideration when using Arrays" for more details.
  1443. @param [out] nRelations
  1444. actual number of relations in the returned array (not more than maxRelations)
  1445. @retval S_OK
  1446. @retval S_FALSE if there are no relations, nRelations is set to 0
  1447. @note As a performant alternative, client code should consider using IAccessible2_2::relationTargetsOfType.
  1448. */
  1449. [propget] HRESULT relations
  1450. (
  1451. [in] long maxRelations,
  1452. [out, size_is(maxRelations), length_is(*nRelations)]
  1453. IAccessibleRelation **relations,
  1454. [out, retval] long *nRelations
  1455. );
  1456. /** @brief Returns the role of an %IAccessible2 object.
  1457. @param [out] role
  1458. The role of an %IAccessible2 object.
  1459. @retval S_OK
  1460. @note
  1461. @li For convenience MSAA roles are also passed through this method so the
  1462. AT doesn't have to also fetch roles through MSAA's get_accRole.
  1463. @li %IAccessible2 roles should not be passed through MSAA's get_accRole.
  1464. @li For compatibility with non IAccessible2 enabled ATs, IAccessible2
  1465. applications should also add support to get_accRole to return the closest
  1466. MSAA role or ROLE_SYSTEM_CLIENT (the MSAA defined default role) if there
  1467. is not a good match.
  1468. @li This method is missing a [propget] prefix in the IDL. The result is the
  1469. method is named role in generated C++ code instead of get_role.
  1470. */
  1471. HRESULT role
  1472. (
  1473. [out, retval] long *role
  1474. );
  1475. /** @brief Makes an object visible on the screen.
  1476. @param [in] scrollType
  1477. Defines where the object should be placed on the screen.
  1478. @retval S_OK
  1479. @retval E_INVALIDARG if bad [in] passed
  1480. */
  1481. HRESULT scrollTo
  1482. (
  1483. [in] enum IA2ScrollType scrollType
  1484. );
  1485. /** @brief Moves the top left of an object to a specified location.
  1486. @param [in] coordinateType
  1487. Specifies whether the coordinates are relative to the screen or the parent object.
  1488. @param [in] x
  1489. Defines the x coordinate.
  1490. @param [in] y
  1491. Defines the y coordinate.
  1492. @retval S_OK
  1493. @retval E_INVALIDARG if bad [in] passed
  1494. */
  1495. HRESULT scrollToPoint
  1496. (
  1497. [in] enum IA2CoordinateType coordinateType,
  1498. [in] long x,
  1499. [in] long y
  1500. );
  1501. /** @brief Returns grouping information.
  1502. Used for tree items, list items, tab panel labels, radio buttons, etc.
  1503. Also used for collections of non-text objects.
  1504. @param [out] groupLevel
  1505. 1 based, 0 indicates that this value is not applicable
  1506. @param [out] similarItemsInGroup
  1507. 1 based, 0 indicates that this value is not applicable
  1508. @param [out] positionInGroup
  1509. 1 based, 0 indicates that this value is not applicable. This is an index
  1510. into the objects in the current group, not an index into all the objects
  1511. at the same group level.
  1512. @retval S_OK if at least one value is valid
  1513. @retval S_FALSE if no values are valid, [out] values are 0s
  1514. @note This method is meant to describe the nature of an object's containment
  1515. structure. It's exposed by trees, tree grids, nested lists, nested menus,
  1516. but not headings, which uses the level object attribute. It is also exposed
  1517. by radio buttons (with groupLevel == 0).
  1518. @note This is normally not implemented on a combo box to describe the nature
  1519. of its contents. Normally an AT will get that information from its child list
  1520. object. However, in some cases when non-edit combo boxes are not able to be structured
  1521. such that the list is a child of the combo box, this method is implemented on
  1522. the combo box itself. ATs can use this interface if a child list is not found.
  1523. */
  1524. [propget] HRESULT groupPosition
  1525. (
  1526. [out] long *groupLevel,
  1527. [out] long *similarItemsInGroup,
  1528. [out, retval] long *positionInGroup
  1529. );
  1530. /** @brief Returns the bit strip containing any IAccessible2 states.
  1531. The IAccessible2 states are in addition to the MSAA states and are defined in
  1532. the IA2States enum.
  1533. @param [out] states
  1534. @retval S_OK
  1535. */
  1536. [propget] HRESULT states
  1537. (
  1538. [out, retval] AccessibleStates *states
  1539. );
  1540. /** @brief Returns the extended role.
  1541. An extended role is a role which is dynamically generated by the application.
  1542. It is not predefined by the %IAccessible2 specification.
  1543. @param [out] extendedRole
  1544. @retval S_OK
  1545. @retval S_FALSE if there is nothing to return, [out] value is NULL
  1546. */
  1547. [propget] HRESULT extendedRole
  1548. (
  1549. [out, retval] BSTR *extendedRole
  1550. );
  1551. /** @brief Returns the localized extended role.
  1552. @param [out] localizedExtendedRole
  1553. @retval S_OK
  1554. @retval S_FALSE if there is nothing to return, [out] value is NULL
  1555. */
  1556. [propget] HRESULT localizedExtendedRole
  1557. (
  1558. [out, retval] BSTR *localizedExtendedRole
  1559. );
  1560. /** @brief Returns the number of extended states.
  1561. @param [out] nExtendedStates
  1562. @retval S_OK
  1563. */
  1564. [propget] HRESULT nExtendedStates
  1565. (
  1566. [out, retval] long *nExtendedStates
  1567. );
  1568. /** @brief Returns the extended states (array of strings).
  1569. An extended state is a state which is dynamically generated by the application.
  1570. It is not predefined by the %IAccessible2 specification.
  1571. @param [in] maxExtendedStates
  1572. This parameter is ignored. Refer to @ref _arrayConsideration
  1573. "Special Consideration when using Arrays" for more details.
  1574. @param [out] extendedStates
  1575. This array is allocated by the server. The client must free it with CoTaskMemFree.
  1576. @param [out] nExtendedStates
  1577. The number of extended states returned; the size of the returned array.
  1578. @retval S_OK
  1579. @retval S_FALSE if there are no states, [out] values are NULL and 0 respectively
  1580. */
  1581. [propget] HRESULT extendedStates
  1582. (
  1583. [in] long maxExtendedStates,
  1584. [out, size_is(,maxExtendedStates), length_is(,*nExtendedStates)] BSTR **extendedStates,
  1585. [out, retval] long *nExtendedStates
  1586. );
  1587. /** @brief Returns the localized extended states (array of strings).
  1588. @param [in] maxLocalizedExtendedStates
  1589. This parameter is ignored. Refer to @ref _arrayConsideration
  1590. "Special Consideration when using Arrays" for more details.
  1591. @param [out] localizedExtendedStates
  1592. This array is allocated by the server. The client must free it with CoTaskMemFree.
  1593. @param [out] nLocalizedExtendedStates
  1594. The number of localized extended states returned; the size of the returned array.
  1595. @retval S_OK
  1596. @retval S_FALSE if there are no states, [out] values are NULL and 0 respectively
  1597. */
  1598. [propget] HRESULT localizedExtendedStates
  1599. (
  1600. [in] long maxLocalizedExtendedStates,
  1601. [out, size_is(,maxLocalizedExtendedStates), length_is(,*nLocalizedExtendedStates)] BSTR **localizedExtendedStates,
  1602. [out, retval] long *nLocalizedExtendedStates
  1603. );
  1604. /** @brief Returns the unique ID.
  1605. The uniqueID is an identifier for this object, is unique within the
  1606. current window, and remains the same for the lifetime of the accessible
  1607. object.
  1608. The uniqueID is not related to:
  1609. - the MSAA objectID which is used by the server to disambiguate between
  1610. IAccessibles per HWND or
  1611. - the MSAA childID which is used to disambiguate between children being
  1612. managed by an IAccessible.
  1613. This value is provided so the AT can have access to a unique runtime persistent
  1614. identifier even when not handling an event for the object.
  1615. An example of when this value is useful is if the AT wants to build a cache.
  1616. The AT could cache the uniqueIDs in addition to other data being cached.
  1617. When an event is fired the AT could map the uniqueID to its internal model.
  1618. Thus, if there's a REORDER/SHOW/HIDE event the AT knows which part of the
  1619. internal structure has been invalidated and can refetch just that part.
  1620. This value can also be used by an AT to determine when the current control
  1621. has changed. If the role is the same for two controls that are adjacent in
  1622. the tab order, this can be used to detect the new control.
  1623. Another use of this value by an AT is to identify when a grouping object has
  1624. changed, e.g. when moving from a radio button in one group to a radio button in a
  1625. different group.
  1626. One means of implementing this would be to create a factory with a 32 bit number
  1627. generator and a reuse pool. The number generator would emit numbers starting
  1628. at 1. Each time an object's life cycle ended, its number would be saved into a
  1629. reuse pool. The number generator would be used whenever the reuse pool was empty.
  1630. Another way to create a unique ID is to generate it from a pointer value, e.g. an
  1631. object's address. That would be unique because no two active objects can use the
  1632. same allocated memory space.
  1633. @param [out] uniqueID
  1634. @retval S_OK
  1635. */
  1636. [propget] HRESULT uniqueID
  1637. (
  1638. [out, retval] long *uniqueID
  1639. );
  1640. /** @brief Returns the window handle for the parent window which contains this object.
  1641. This is the same window handle which will be passed for any events that occur on the
  1642. object, but is cached in the accessible object for use when it would be helpful to
  1643. access the window handle in cases where an event isn't fired on this object.
  1644. A use case is when a screen reader is grabbing an entire web page on a page load.
  1645. Without the availability of windowHandle, the AT would have to get the window handle
  1646. by using WindowFromAccessibleObject on each IAccessible, which is slow because it's
  1647. implemented by oleacc.dll as a loop which crawls up the ancestor chain and looks for
  1648. a ROLE_WINDOW object, mapping that back to a window handle.
  1649. @param [out] windowHandle
  1650. @retval S_OK
  1651. */
  1652. [propget] HRESULT windowHandle
  1653. (
  1654. [out, retval] HWND *windowHandle
  1655. );
  1656. /** @brief Returns the index of this object in its parent object.
  1657. @param [out] indexInParent
  1658. 0 based; -1 indicates there is no parent; the upper bound is the value
  1659. returned by the parent's IAccessible::get_accChildCount.
  1660. @retval S_OK
  1661. @retval S_FALSE if no parent, [out] value is -1
  1662. */
  1663. [propget] HRESULT indexInParent
  1664. (
  1665. [out, retval] long *indexInParent
  1666. );
  1667. /** @brief Returns the IA2Locale of the accessible object.
  1668. @param [out] locale
  1669. @retval S_OK
  1670. */
  1671. [propget] HRESULT locale
  1672. (
  1673. [out, retval] IA2Locale *locale
  1674. );
  1675. /** @brief Returns the attributes specific to this object, such as a cell's formula.
  1676. @param [out] attributes
  1677. @retval S_OK
  1678. @retval S_FALSE returned if there is nothing to return, [out] value is NULL
  1679. */
  1680. [propget] HRESULT attributes
  1681. (
  1682. [out, retval] BSTR *attributes
  1683. );
  1684. }
  1685. /*************************************************************************
  1686. *
  1687. * File Name (Accessible2_2.idl)
  1688. *
  1689. * IAccessible2 IDL Specification
  1690. *
  1691. * Copyright (c) 2007, 2013 Linux Foundation
  1692. * Copyright (c) 2006 IBM Corporation
  1693. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  1694. * All rights reserved.
  1695. *
  1696. *
  1697. * Redistribution and use in source and binary forms, with or without
  1698. * modification, are permitted provided that the following conditions
  1699. * are met:
  1700. *
  1701. * 1. Redistributions of source code must retain the above copyright
  1702. * notice, this list of conditions and the following disclaimer.
  1703. *
  1704. * 2. Redistributions in binary form must reproduce the above
  1705. * copyright notice, this list of conditions and the following
  1706. * disclaimer in the documentation and/or other materials
  1707. * provided with the distribution.
  1708. *
  1709. * 3. Neither the name of the Linux Foundation nor the names of its
  1710. * contributors may be used to endorse or promote products
  1711. * derived from this software without specific prior written
  1712. * permission.
  1713. *
  1714. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  1715. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  1716. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  1717. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  1718. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  1719. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  1720. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  1721. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  1722. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1723. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  1724. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  1725. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  1726. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  1727. *
  1728. * This BSD License conforms to the Open Source Initiative "Simplified
  1729. * BSD License" as published at:
  1730. * http://www.opensource.org/licenses/bsd-license.php
  1731. *
  1732. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  1733. * mark may be used in accordance with the Linux Foundation Trademark
  1734. * Policy to indicate compliance with the IAccessible2 specification.
  1735. *
  1736. ************************************************************************/
  1737. /** @brief This interface exposes the primary set of information about an
  1738. IAccessible2 enabled accessible object.
  1739. This interface must always be provided for objects that support some
  1740. portion of the collection of the %IAccessible2 interfaces.
  1741. Please refer to @ref _changingInterfaces "Changing between Accessible Interfaces"
  1742. for special considerations related to use of the MSAA IAccessible interface and
  1743. the set of %IAccessible2 interfaces.
  1744. */
  1745. [object, uuid(6C9430E9-299D-4E6F-BD01-A82A1E88D3FF)]
  1746. interface IAccessible2_2 : IAccessible2
  1747. {
  1748. /** @brief Returns the attribute value of a specified attribute specific to this object.
  1749. @param [in] name
  1750. @param [out] attribute
  1751. @retval S_OK
  1752. @retval S_FALSE returned if there is nothing to return, [out] value is NULL.
  1753. @retval E_INVALIDARG if bad [in] passed.
  1754. @note The output value is a VARIANT. Typically it will be a VT_BSTR, but there
  1755. are some cases where it will be a VT_I4 or VT_BOOL. Refer to the <a href=
  1756. "http://www.linuxfoundation.org/collaborate/workgroups/accessibility/iaccessible2/objectattributesIAccessible2">
  1757. Object Attributes specification</a> for more information.
  1758. */
  1759. [propget] HRESULT attribute
  1760. (
  1761. [in] BSTR name,
  1762. [out, retval] VARIANT *attribute
  1763. );
  1764. /** @brief Returns the deepest hypertext accessible in the subtree of this object, and the caret offset within it.
  1765. @param [out] accessible
  1766. @param [out] caretOffset
  1767. @retval S_OK
  1768. @retval S_FALSE returned if there is no caret in any of the objects in the subtree, [out] accessible is NULL and [out] caretOffset is -1.
  1769. */
  1770. [propget] HRESULT accessibleWithCaret
  1771. (
  1772. [out] IUnknown **accessible,
  1773. [out, retval] long *caretOffset
  1774. );
  1775. /** @brief Returns relation targets for a specified target type.
  1776. @param [in] type
  1777. The requested @ref grpRelations "relation type".
  1778. @param [in] maxTargets
  1779. The number of targets requested. 0 indicates that all targets should be returned.
  1780. @param [out] targets
  1781. This array is allocated by the server. The client must free it with CoTaskMemFree.
  1782. @param [out] nTargets
  1783. The number of targets returned; the size of the returned array.
  1784. @retval S_OK
  1785. @retval S_FALSE if there are no targets, [out] values are NULL and 0 respectively.
  1786. @retval E_INVALIDARG if bad [in] passed.
  1787. */
  1788. [propget] HRESULT relationTargetsOfType
  1789. (
  1790. [in] BSTR type,
  1791. [in] long maxTargets,
  1792. [out, size_is(,*nTargets)] IUnknown ***targets,
  1793. [out, retval] long *nTargets
  1794. );
  1795. }
  1796. /**
  1797. * This structure represents a directional range of the content. It is defined
  1798. * by two points in the content, where each one is defined by an accessible
  1799. * object and an offset relative to it. A typical case of a range point is
  1800. * a text accessible and text offset within it.
  1801. *
  1802. * The "anchor" is one point of the range and typically remains constant.
  1803. * The other point is the "active" point, which typically corresponds to
  1804. * the user's focus or point of interest. The user moves the active point to
  1805. * expand or collapse the range. In most cases, anchor is the start of the range
  1806. * and active is the end. However, in case of selection, when selecting
  1807. * backwards (e.g. pressing shift+left arrow in a text field), the start of
  1808. * the range is the active point, as the user moves this to manipulate
  1809. * the selection.
  1810. */
  1811. typedef struct IA2Range {
  1812. IUnknown* anchor;
  1813. long anchorOffset;
  1814. IUnknown* active;
  1815. long activeOffset;
  1816. } IA2Range;
  1817. /**
  1818. * @brief This interface is an extension of IAccessible2_2 and IAccessible2
  1819. * interfaces.
  1820. */
  1821. [object, uuid(5BE18059-762E-4E73-9476-ABA294FED411)]
  1822. interface IAccessible2_3 : IAccessible2_2
  1823. {
  1824. /**
  1825. * @brief Returns an array of ranges for selections within the accessible.
  1826. * @param [out] ranges
  1827. The array of selection ranges, allocated by the server. The client must
  1828. free it with CoTaskMemFree.
  1829. * @param [out] nRanges
  1830. the array length
  1831. * @retval S_OK
  1832. * @retval S_FALSE returned if there is no selection within the accessible
  1833. */
  1834. [propget] HRESULT selectionRanges
  1835. (
  1836. [out, size_is(,*nRanges)] IA2Range **ranges,
  1837. [out, retval] long *nRanges
  1838. );
  1839. }
  1840. /**
  1841. * @brief This interface is an extension of IAccessible2_3 which exposes a
  1842. * single method for setting the current selection given a number of selection
  1843. * ranges.
  1844. *
  1845. * This interface is preliminary as it has not been adopted by any standard yet.
  1846. */
  1847. [object, uuid(610a7bec-91bb-444d-a336-a0daf13c4c29)]
  1848. interface IAccessible2_4 : IAccessible2_3
  1849. {
  1850. /**
  1851. * @brief Sets the current selection to the provided ranges. The provided
  1852. * ranges don't need to be contained within this accessible.
  1853. * @param [in] nRanges
  1854. * The length of the array containing the selection ranges.
  1855. * @param [in] ranges
  1856. * The array of selection ranges, allocated by the client with
  1857. * CoTaskMemAlloc and freed by the client with CoTaskMemFree.
  1858. * @retval S_OK Returned if the selection was made successfully.
  1859. * @retval S_FALSE Returned if the selection could not be made.
  1860. * @retval E_INVALIDARG Returned if any of the input arguments are invalid.
  1861. */
  1862. HRESULT setSelectionRanges
  1863. (
  1864. [in] long nRanges,
  1865. [in, size_is(nRanges)] IA2Range* ranges
  1866. );
  1867. }
  1868. /*************************************************************************
  1869. *
  1870. * File Name (AccessibleComponent.idl)
  1871. *
  1872. * IAccessible2 IDL Specification
  1873. *
  1874. * Copyright (c) 2007, 2010 Linux Foundation
  1875. * Copyright (c) 2006 IBM Corporation
  1876. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  1877. * All rights reserved.
  1878. *
  1879. *
  1880. * Redistribution and use in source and binary forms, with or without
  1881. * modification, are permitted provided that the following conditions
  1882. * are met:
  1883. *
  1884. * 1. Redistributions of source code must retain the above copyright
  1885. * notice, this list of conditions and the following disclaimer.
  1886. *
  1887. * 2. Redistributions in binary form must reproduce the above
  1888. * copyright notice, this list of conditions and the following
  1889. * disclaimer in the documentation and/or other materials
  1890. * provided with the distribution.
  1891. *
  1892. * 3. Neither the name of the Linux Foundation nor the names of its
  1893. * contributors may be used to endorse or promote products
  1894. * derived from this software without specific prior written
  1895. * permission.
  1896. *
  1897. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  1898. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  1899. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  1900. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  1901. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  1902. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  1903. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  1904. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  1905. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1906. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  1907. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  1908. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  1909. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  1910. *
  1911. * This BSD License conforms to the Open Source Initiative "Simplified
  1912. * BSD License" as published at:
  1913. * http://www.opensource.org/licenses/bsd-license.php
  1914. *
  1915. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  1916. * mark may be used in accordance with the Linux Foundation Trademark
  1917. * Policy to indicate compliance with the IAccessible2 specification.
  1918. *
  1919. ************************************************************************/
  1920. /** A value specifying a color in ARGB format, where each 8 bit color component
  1921. specifies alpha, red, green, and blue respectively. The alpha value is optional.
  1922. */
  1923. typedef long IA2Color;
  1924. /** @brief This interface is implemented by any object that can be rendered
  1925. on the screen.
  1926. This interface provides the standard mechanism for an assistive technology
  1927. to retrieve information concerning the graphical representation of an object.
  1928. Coordinates used by the functions of this interface are specified in
  1929. different coordinate systems. Their scale is the same and is equal to
  1930. that of the screen coordinate system. In other words all coordinates
  1931. are measured in pixels. They differ in their respective origin:
  1932. <ul>
  1933. <li>The screen coordinate system has its origin in the upper left
  1934. corner of the current screen.</li>
  1935. <li>The origin of the parent coordinate system is the upper left corner
  1936. of the parent's bounding box. With no parent the screen coordinate
  1937. system is used instead.</li>
  1938. </ul>
  1939. */
  1940. [object, uuid(1546D4B0-4C98-4bda-89AE-9A64748BDDE4)]
  1941. interface IAccessibleComponent : IUnknown
  1942. {
  1943. /** @brief Returns the location of the upper left corner of the object's
  1944. bounding box relative to the immediate parent object.
  1945. The coordinates of the bounding box are given relative to the parent's
  1946. coordinate system. The coordinates of the returned position are relative
  1947. to this object's parent or relative to the screen on which this object
  1948. is rendered if it has no parent. If the object is not on any screen
  1949. the returned position is (0,0).
  1950. @param [out] x
  1951. @param [out] y
  1952. @retval S_OK
  1953. */
  1954. [propget] HRESULT locationInParent
  1955. (
  1956. [out] long *x,
  1957. [out, retval] long *y
  1958. );
  1959. /** @brief Returns the foreground color of this object.
  1960. @param [out] foreground
  1961. The returned color is the foreground color of this object or, if
  1962. that is not supported, the default foreground color.
  1963. @retval S_OK
  1964. */
  1965. [propget] HRESULT foreground
  1966. (
  1967. [out, retval] IA2Color *foreground
  1968. );
  1969. /** @brief Returns the background color of this object.
  1970. @param [out] background
  1971. The returned color is the background color of this object or, if
  1972. that is not supported, the default background color.
  1973. @retval S_OK
  1974. */
  1975. [propget] HRESULT background
  1976. (
  1977. [out, retval] IA2Color *background
  1978. );
  1979. }
  1980. /*************************************************************************
  1981. *
  1982. * File Name (AccessibleValue.idl)
  1983. *
  1984. * IAccessible2 IDL Specification
  1985. *
  1986. * Copyright (c) 2007, 2010 Linux Foundation
  1987. * Copyright (c) 2006 IBM Corporation
  1988. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  1989. * All rights reserved.
  1990. *
  1991. *
  1992. * Redistribution and use in source and binary forms, with or without
  1993. * modification, are permitted provided that the following conditions
  1994. * are met:
  1995. *
  1996. * 1. Redistributions of source code must retain the above copyright
  1997. * notice, this list of conditions and the following disclaimer.
  1998. *
  1999. * 2. Redistributions in binary form must reproduce the above
  2000. * copyright notice, this list of conditions and the following
  2001. * disclaimer in the documentation and/or other materials
  2002. * provided with the distribution.
  2003. *
  2004. * 3. Neither the name of the Linux Foundation nor the names of its
  2005. * contributors may be used to endorse or promote products
  2006. * derived from this software without specific prior written
  2007. * permission.
  2008. *
  2009. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  2010. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  2011. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  2012. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  2013. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  2014. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  2015. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  2016. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  2017. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2018. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  2019. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  2020. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  2021. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  2022. *
  2023. * This BSD License conforms to the Open Source Initiative "Simplified
  2024. * BSD License" as published at:
  2025. * http://www.opensource.org/licenses/bsd-license.php
  2026. *
  2027. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  2028. * mark may be used in accordance with the Linux Foundation Trademark
  2029. * Policy to indicate compliance with the IAccessible2 specification.
  2030. *
  2031. ************************************************************************/
  2032. /** @brief This interface gives access to a single numerical value.
  2033. The %IAccessibleValue interface represents a single numerical value and should
  2034. be implemented by any class that supports numerical value like progress bars
  2035. and spin boxes. This interface lets you access the value and its upper and
  2036. lower bounds.
  2037. */
  2038. [object, uuid(35855B5B-C566-4fd0-A7B1-E65465600394)]
  2039. interface IAccessibleValue : IUnknown
  2040. {
  2041. /** @brief Returns the value of this object as a number.
  2042. The exact return type is implementation dependent. Typical types are long and
  2043. double.
  2044. @param [out] currentValue
  2045. Returns the current value represented by this object. See the section about
  2046. @ref _variants "VARIANTs" for additional information.
  2047. @retval S_OK
  2048. @retval S_FALSE if there is nothing to return, [out] value is a VARIANT with vt = VT_EMPTY
  2049. */
  2050. [propget] HRESULT currentValue
  2051. (
  2052. [out, retval] VARIANT *currentValue
  2053. );
  2054. /** @brief Sets the value of this object to the given number.
  2055. The argument is clipped to the valid interval whose upper and lower
  2056. bounds are returned by the methods IAccessibleValue::maximumValue and
  2057. IAccessibleValue::minimumValue, i.e. if it is lower than the minimum
  2058. value the new value will be the minimum and if it is greater than the
  2059. maximum then the new value will be the maximum.
  2060. @param [in] value
  2061. The new value represented by this object. The set of admissible types for
  2062. this argument is implementation dependent.
  2063. @retval S_OK
  2064. */
  2065. HRESULT setCurrentValue
  2066. (
  2067. [in] VARIANT value
  2068. );
  2069. /** @brief Returns the maximal value that can be represented by this object.
  2070. The type of the returned value is implementation dependent. It does not have
  2071. to be the same type as that returned by method IAccessibleValue::currentValue.
  2072. @param [out] maximumValue
  2073. Returns the maximal value in an implementation dependent type. If this object
  2074. has no upper bound then an empty object is returned. See the section about
  2075. @ref _variants "VARIANTs" for additional information.
  2076. @retval S_OK
  2077. @retval S_FALSE if there is nothing to return, [out] value is a VARIANT with vt = VT_EMPTY
  2078. */
  2079. [propget] HRESULT maximumValue
  2080. (
  2081. [out, retval] VARIANT *maximumValue
  2082. );
  2083. /** @brief Returns the minimal value that can be represented by this object.
  2084. The type of the returned value is implementation dependent. It does not have
  2085. to be the same type as that returned by method IAccessibleValue::currentValue.
  2086. @param [out] minimumValue
  2087. Returns the minimal value in an implementation dependent type. If this object
  2088. has no lower bound then an empty object is returned. See the section about
  2089. @ref _variants "VARIANTs" for additional information.
  2090. @retval S_OK
  2091. @retval S_FALSE if there is nothing to return, [out] value is a VARIANT with vt = VT_EMPTY
  2092. */
  2093. [propget] HRESULT minimumValue
  2094. (
  2095. [out, retval] VARIANT *minimumValue
  2096. );
  2097. };
  2098. /*************************************************************************
  2099. *
  2100. * File Name (AccessibleText.idl)
  2101. *
  2102. * IAccessible2 IDL Specification
  2103. *
  2104. * Copyright (c) 2007, 2013 Linux Foundation
  2105. * Copyright (c) 2006 IBM Corporation
  2106. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  2107. * All rights reserved.
  2108. *
  2109. *
  2110. * Redistribution and use in source and binary forms, with or without
  2111. * modification, are permitted provided that the following conditions
  2112. * are met:
  2113. *
  2114. * 1. Redistributions of source code must retain the above copyright
  2115. * notice, this list of conditions and the following disclaimer.
  2116. *
  2117. * 2. Redistributions in binary form must reproduce the above
  2118. * copyright notice, this list of conditions and the following
  2119. * disclaimer in the documentation and/or other materials
  2120. * provided with the distribution.
  2121. *
  2122. * 3. Neither the name of the Linux Foundation nor the names of its
  2123. * contributors may be used to endorse or promote products
  2124. * derived from this software without specific prior written
  2125. * permission.
  2126. *
  2127. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  2128. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  2129. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  2130. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  2131. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  2132. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  2133. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  2134. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  2135. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2136. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  2137. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  2138. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  2139. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  2140. *
  2141. * This BSD License conforms to the Open Source Initiative "Simplified
  2142. * BSD License" as published at:
  2143. * http://www.opensource.org/licenses/bsd-license.php
  2144. *
  2145. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  2146. * mark may be used in accordance with the Linux Foundation Trademark
  2147. * Policy to indicate compliance with the IAccessible2 specification.
  2148. *
  2149. ************************************************************************/
  2150. /** A structure containing a substring and the start and end offsets in the enclosing string.
  2151. IAccessibleText::newText and IAccessibleText::oldText return this struct.
  2152. */
  2153. typedef struct IA2TextSegment {
  2154. BSTR text; ///< A copy of a segment of text taken from an enclosing paragraph.
  2155. long start; ///< Index of the first character of the segment in the enclosing text.
  2156. long end; ///< Index of the character following the last character of the segment in the enclosing text.
  2157. } IA2TextSegment;
  2158. /** This enum defines values which specify a text boundary type.
  2159. IA2_TEXT_BOUNDARY_SENTENCE is optional. When a method doesn't implement this
  2160. method it must return S_FALSE. Typically this feature would not be implemented
  2161. by an application. However, if the application developer was not satisfied with
  2162. how screen readers have handled the reading of sentences this boundary type
  2163. could be implemented and screen readers could use the application's version of a
  2164. sentence rather than the screen reader's.
  2165. The rest of the boundary types must be supported.
  2166. This enum is used in IAccessibleText::textBeforeOffset, IAccessibleText::textAtOffset,
  2167. and IAccessibleText::textAfterOffset.
  2168. */
  2169. enum IA2TextBoundaryType {
  2170. /** Typically, a single character is returned. In some cases more than one
  2171. character is returned, for example, when a document contains field data such
  2172. as a field containing a date, time, or footnote reference. In this case
  2173. the caret can move over several characters in one movement of the caret.
  2174. Note, that after the caret moves, the caret offset changes by the number of
  2175. characters in the field, e.g. by 8 characters in the following date: 03/26/07.
  2176. */
  2177. IA2_TEXT_BOUNDARY_CHAR,
  2178. /** The range provided matches the range observed when the application
  2179. processes the Ctrl + left arrow and Ctrl + right arrow key sequences.
  2180. Typically this is from the start of one word to the start of the next, but
  2181. various applications are inconsistent in the handling of the end of a line.
  2182. */
  2183. IA2_TEXT_BOUNDARY_WORD,
  2184. /** Range is from start of one sentence to the start of another sentence.
  2185. */
  2186. IA2_TEXT_BOUNDARY_SENTENCE,
  2187. /** Range is from start of one paragraph to the start of another paragraph.
  2188. */
  2189. IA2_TEXT_BOUNDARY_PARAGRAPH,
  2190. /** Range is from start of one line to the start of another line. This often
  2191. means that an end-of-line character will appear at the end of the range.
  2192. However in the case of some applications an end-of-line character indicates
  2193. the end of a paragraph and the lines composing the paragraph, other than
  2194. the last line, do not contain an end of line character.
  2195. */
  2196. IA2_TEXT_BOUNDARY_LINE,
  2197. /** <b>Deprecated.</b> Using this value will cause all text to be returned.
  2198. Note: IAccessibleText::text should be used instead.
  2199. */
  2200. IA2_TEXT_BOUNDARY_ALL
  2201. };
  2202. /** @brief This interface gives read-only access to text.
  2203. The %IAccessibleText interface should be implemented by all components
  2204. that present textual information on the display like buttons,
  2205. text entry fields, or text portions of the document window. The interface
  2206. provides access to the text's content, attributes, and spatial location.
  2207. However, text can not be modified with this interface. That is the task
  2208. of the IAccessibleEditableText interface.
  2209. The text length, i.e. the number of characters in the text, is
  2210. returned by IAccessibleText::nCharacters. All methods that operate
  2211. on particular characters (e.g. IAccessibleText::textAtOffset) use character
  2212. indices from 0 to length-1. All methods that operate on character positions
  2213. (e.g. IAccessibleText::text) use indices from 0 to length.
  2214. Please note that accessible text does not necessarily support selection.
  2215. In this case it should behave as if there where no selection. An empty
  2216. selection is used for example to express the current cursor position.
  2217. Refer to @ref _specialOffsets
  2218. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  2219. for information about special offsets that can be used in %IAccessibleText methods.
  2220. E_FAIL is returned in the following cases
  2221. @li endOffset < startOffset
  2222. @li endoffset > length
  2223. */
  2224. [object, uuid(24FD2FFB-3AAD-4a08-8335-A3AD89C0FB4B)]
  2225. interface IAccessibleText : IUnknown
  2226. {
  2227. /** @brief Adds a text selection
  2228. @param [in] startOffset
  2229. Starting offset ( 0 based).
  2230. @param [in] endOffset
  2231. Offset of first character after new selection (0 based).
  2232. @retval S_OK
  2233. @retval E_INVALIDARG if bad [in] passed
  2234. @note Refer to @ref _specialOffsets
  2235. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  2236. for information about special offsets that can be used in %IAccessibleText methods.
  2237. */
  2238. HRESULT addSelection
  2239. (
  2240. [in] long startOffset,
  2241. [in] long endOffset
  2242. );
  2243. /** @brief Returns text attributes.
  2244. @param [in] offset
  2245. Text offset (0 based). Refer to @ref _specialOffsets
  2246. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  2247. for information about special offsets that can be used in %IAccessibleText methods.
  2248. @param [out] startOffset
  2249. The starting offset of the character range over which all text attributes match
  2250. those of offset. (0 based)
  2251. @param [out] endOffset
  2252. The offset of the first character past the character range over which all text
  2253. attributes match those of offset. (0 based)
  2254. @param [out] textAttributes
  2255. A string of attributes describing the text. The attributes are described in the
  2256. <a href="http://www.linuxfoundation.org/en/Accessibility/IAccessible2/TextAttributes">
  2257. text attributes specification</a> on the %IAccessible2 web site.
  2258. @retval S_OK
  2259. @retval S_FALSE if there is nothing to return, [out] values are 0s and NULL respectively
  2260. @retval E_INVALIDARG if bad [in] passed
  2261. */
  2262. [propget] HRESULT attributes
  2263. (
  2264. [in] long offset,
  2265. [out] long *startOffset,
  2266. [out] long *endOffset,
  2267. [out, retval] BSTR *textAttributes
  2268. );
  2269. /** @brief Returns the position of the caret.
  2270. Returns the 0-based offset of the caret within the text. If the text is
  2271. implemented as a tree of text objects with embed characters in higher levels
  2272. representing substrings of child text objects and the caret is in one of the
  2273. child text objects, then the offset in the higher level text object would be
  2274. at the embed character representing child text object that contains the caret.
  2275. For example, if the string "one two three" is implemented as a two text objects,
  2276. with a top level text object containing an embed character "one ? three" and a
  2277. child text object containing "two" and if the caret is in the descendant object
  2278. just before the 'o' in "two", then:
  2279. <ul>
  2280. <li>the caretOffset for the "one ? three" object would be 4, matching the embed character</li>
  2281. <li>the caretOffset for "two" would be 2, matching the "o"</li>
  2282. </ul>
  2283. The caret position/offset is that of the character logically following it, e.g.
  2284. to the right of it in a left to right language, or to the left of it in a right
  2285. to left language.
  2286. @param [out] offset
  2287. The returned offset is relative to the text represented by this object.
  2288. @retval S_OK
  2289. @retval S_FALSE if the caret is not currently active on this object, i.e. the
  2290. caret is located on some other object. The returned offset value will be -1.
  2291. @note S_FALSE (and an offset of -1) will not be returned if the caret is somewhere
  2292. in the text object or one of its descendants.
  2293. */
  2294. [propget] HRESULT caretOffset
  2295. (
  2296. [out, retval] long *offset
  2297. );
  2298. /** @brief Returns the bounding box of the specified position.
  2299. The virtual character after the last character of the represented
  2300. text, i.e. the one at position length is a special case. It represents the
  2301. current input position and will therefore typically be queried by AT more
  2302. often than other positions. Because it does not represent an existing character
  2303. its bounding box is defined in relation to preceding characters. It should be
  2304. roughly equivalent to the bounding box of some character when inserted at the
  2305. end of the text. Its height typically being the maximal height of all the
  2306. characters in the text or the height of the preceding character, its width being
  2307. at least one pixel so that the bounding box is not degenerate.
  2308. Note that the index 'length' is not always valid. Whether it is or not is
  2309. implementation dependent. It typically is when text is editable or otherwise
  2310. when on the screen the caret can be placed behind the text. You can be sure
  2311. that the index is valid after you have received a ::IA2_EVENT_TEXT_CARET_MOVED
  2312. event for this index.
  2313. @param [in] offset
  2314. Index of the character for which to return its bounding box. The valid range
  2315. is 0..length. Refer to @ref _specialOffsets
  2316. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  2317. for information about special offsets that can be used in %IAccessibleText methods.
  2318. @param [in] coordType
  2319. Specifies if the coordinates are relative to the screen or to the parent window.
  2320. @param [out] x
  2321. X coordinate of the top left corner of the bounding box of the referenced character.
  2322. @param [out] y
  2323. Y coordinate of the top left corner of the bounding box of the referenced character.
  2324. @param [out] width
  2325. Width of the bounding box of the referenced character.
  2326. @param [out] height
  2327. Height of the bounding box of the referenced character.
  2328. @retval S_OK
  2329. @retval E_INVALIDARG if bad [in] passed
  2330. */
  2331. [propget] HRESULT characterExtents
  2332. (
  2333. [in] long offset,
  2334. [in] enum IA2CoordinateType coordType,
  2335. [out] long *x,
  2336. [out] long *y,
  2337. [out] long *width,
  2338. [out, retval] long *height
  2339. );
  2340. /** @brief Returns the number of active non-contiguous selections
  2341. @param [out] nSelections
  2342. @retval S_OK
  2343. */
  2344. [propget] HRESULT nSelections
  2345. (
  2346. [out, retval] long *nSelections
  2347. );
  2348. /** @brief Returns the text position for the specified screen position.
  2349. Given a point return the zero-based index of the character under that
  2350. point. The same functionality could be achieved by using the bounding
  2351. boxes for each character as returned by IAccessibleText::characterExtents.
  2352. The method IAccessibleText::offsetAtPoint, however, can be implemented
  2353. more efficiently.
  2354. @param [in] x
  2355. The position's x value for which to look up the index of the character that
  2356. is rendered on to the display at that point.
  2357. @param [in] y
  2358. The position's y value for which to look up the index of the character that
  2359. is rendered on to the display at that point.
  2360. @param [in] coordType
  2361. Screen coordinates or window coordinates.
  2362. @param [out] offset
  2363. Index of the character under the given point or -1 if the point
  2364. is invalid or there is no character under the point.
  2365. @retval S_OK
  2366. @retval S_FALSE if nothing to return, [out] value is -1
  2367. @retval E_INVALIDARG if bad [in] passed
  2368. */
  2369. [propget] HRESULT offsetAtPoint
  2370. (
  2371. [in] long x,
  2372. [in] long y,
  2373. [in] enum IA2CoordinateType coordType,
  2374. [out, retval] long *offset
  2375. );
  2376. /** @brief Returns the character offsets of Nth active text selection
  2377. Returns the 0-based starting and ending offsets of the Nth selection. If the
  2378. text is implemented as a tree of text objects with embed characters in higher
  2379. levels representing substrings of child text objects, consider the following.
  2380. If the starting selection offset is in one of the child text objects, then the
  2381. starting offset in the higher level text object would be at the embed character
  2382. representing the child text object that contains the starting selection offset.
  2383. If the ending selection offset is in one of the child text objects, then the
  2384. ending offset in the higher level text object would be just after the embed
  2385. character representing the child text object that contains the ending selection
  2386. offset.
  2387. For example, if the string "one two three" is implemented as a two text objects,
  2388. with a top level text object containing an embed character "one ? three" and a
  2389. child text object containing "two" and if the selection is the string "two" then:
  2390. <ul>
  2391. <li>the startOffset for the "one ? three" object would be 4, matching the embed character and the endOffset would be 5.</li>
  2392. <li>the startOffset for the "two" object would be 0, and the endOffset would be 3</li>
  2393. </ul>
  2394. Selection offsets are that of the character logically following it, e.g.
  2395. to the right of it in a left to right language or to the left of it in a right to left language.
  2396. @param [in] selectionIndex
  2397. Index of selection (0 based).
  2398. @param [out] startOffset
  2399. 0 based offset of first selected character
  2400. @param [out] endOffset
  2401. 0 based offset of one past the last selected character.
  2402. @retval S_OK
  2403. @retval E_INVALIDARG if bad [in] passed
  2404. */
  2405. [propget] HRESULT selection
  2406. (
  2407. [in] long selectionIndex,
  2408. [out] long *startOffset,
  2409. [out, retval] long *endOffset
  2410. );
  2411. /** @brief Returns the substring between the two given indices.
  2412. The substring starts with the character at startOffset (inclusive) and up to
  2413. the character at endOffset (exclusive), if startOffset is less or equal
  2414. endOffset. If endOffset is lower than startOffset, the result is the same
  2415. as a call with the two arguments being exchanged.
  2416. The whole text can be requested by passing the indices zero and
  2417. IAccessibleText::nCharacters. If both indices have the same value, an empty
  2418. string is returned.
  2419. @param [in] startOffset
  2420. Index of the first character to include in the returned string. The valid range
  2421. is 0..length.
  2422. @param [in] endOffset
  2423. Index of the last character to exclude in the returned string. The valid range
  2424. is 0..length.
  2425. @param [out] text
  2426. Returns the substring starting with the character at startOffset (inclusive)
  2427. and up to the character at endOffset (exclusive), if startOffset is less than
  2428. or equal to endOffset.
  2429. @retval S_OK
  2430. @retval E_INVALIDARG if bad [in] passed
  2431. @note
  2432. @li The returned string may be longer than endOffset-startOffset bytes if text
  2433. contains multi-byte characters.
  2434. @li Refer to @ref _specialOffsets
  2435. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  2436. for information about special offsets that can be used in %IAccessibleText methods.
  2437. */
  2438. [propget] HRESULT text
  2439. (
  2440. [in] long startOffset,
  2441. [in] long endOffset,
  2442. [out, retval] BSTR *text
  2443. );
  2444. /** @brief Returns a text portion before the given position.
  2445. Returns the substring of the specified text type that is located before the
  2446. given character and does not include it. The result of this method should be
  2447. same as a result for IAccessibleText::textAtOffset with a suitably decreased
  2448. index value.
  2449. For example, if text type is ::IA2_TEXT_BOUNDARY_WORD, then the complete
  2450. word that is closest to and located before offset is returned.
  2451. If the index is valid, but no text is found, S_FALSE is returned along with out
  2452. values of 0, 0, and a NULL pointer. This would happen for boundary types other
  2453. than character when the text consists entirely of whitespace.
  2454. @param [in] offset
  2455. Index of the character for which to return the text part before it. The index
  2456. character will not be part of the returned string. The valid range is 0..length.
  2457. Refer to @ref _specialOffsets
  2458. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  2459. for information about special offsets that can be used in %IAccessibleText methods.
  2460. @param [in] boundaryType
  2461. The type of the text portion to return. See ::IA2TextBoundaryType for the
  2462. complete list.
  2463. @param [out] startOffset
  2464. 0 based offset of first character.
  2465. @param [out] endOffset
  2466. 0 based offset of one past the last character.
  2467. @param [out] text
  2468. Returns the requested text portion. This portion may be empty or invalid when
  2469. no appropriate text portion is found or text type is invalid.
  2470. @retval S_OK
  2471. @retval S_FALSE if the requested boundary type is not implemented, such as
  2472. ::IA2_TEXT_BOUNDARY_SENTENCE, or if there is nothing to return;
  2473. [out] values are 0s and NULL respectively
  2474. @retval E_INVALIDARG if bad [in] passed
  2475. */
  2476. [propget] HRESULT textBeforeOffset
  2477. (
  2478. [in] long offset,
  2479. [in] enum IA2TextBoundaryType boundaryType,
  2480. [out] long *startOffset,
  2481. [out] long *endOffset,
  2482. [out, retval] BSTR *text
  2483. );
  2484. /** @brief Returns a text portion after the given position.
  2485. Returns the substring of the specified text type that is located after the
  2486. given character and does not include it. The result of this method should be
  2487. same as a result for IAccessibleText::textAtOffset with a suitably increased
  2488. index value.
  2489. For example, if text type is ::IA2_TEXT_BOUNDARY_WORD, then the complete
  2490. word that is closest to and located after offset is returned.
  2491. If the index is valid, but no text is found, S_FALSE is returned along with out
  2492. values of 0, 0, and a NULL pointer. This would happen for boundary types other
  2493. than character when the text consists entirely of whitespace.
  2494. @param [in] offset
  2495. Index of the character for which to return the text part after it. The index
  2496. character will not be part of the returned string. The valid range is 0..length.
  2497. Refer to @ref _specialOffsets
  2498. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  2499. for information about special offsets that can be used in %IAccessibleText methods.
  2500. @param [in] boundaryType
  2501. The type of the text portion to return. See ::IA2TextBoundaryType for the complete
  2502. list.
  2503. @param [out] startOffset
  2504. 0 based offset of first character.
  2505. @param [out] endOffset
  2506. 0 based offset of one past the last character.
  2507. @param [out] text
  2508. Returns the requested text portion. This portion may be empty or invalid when
  2509. no appropriate text portion is found or text type is invalid.
  2510. @retval S_OK
  2511. @retval S_FALSE if the requested boundary type is not implemented, such as
  2512. ::IA2_TEXT_BOUNDARY_SENTENCE, or if there is nothing to return;
  2513. [out] values are 0s and NULL respectively
  2514. @retval E_INVALIDARG if bad [in] passed
  2515. */
  2516. [propget] HRESULT textAfterOffset
  2517. (
  2518. [in] long offset,
  2519. [in] enum IA2TextBoundaryType boundaryType,
  2520. [out] long *startOffset,
  2521. [out] long *endOffset,
  2522. [out, retval] BSTR *text
  2523. );
  2524. /** @brief Returns a text portion that spans the given position.
  2525. Returns the substring defined by the specified boundary type at the specified
  2526. offset. Refer to IA2TextBoundaryType for more details.
  2527. For the word boundary type the returned string will contain the word at the
  2528. offset if the offset is inside a word and will contain the word before the
  2529. offset if the offset is not inside a word. All offsets from the first to the
  2530. last characters of a word are considered inside the word. Boundary types of
  2531. sentence and paragraph should exhibit similar behavior.
  2532. If the index is valid, but no text is found, S_FALSE is returned along with out
  2533. values of 0, 0, and a NULL pointer. This would happen for boundary types other
  2534. than character when the text consists entirely of whitespace.
  2535. @param [in] offset
  2536. Index of the character for which to return the text part it belongs to. The valid
  2537. range is 0..length.
  2538. Refer to @ref _specialOffsets
  2539. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  2540. for information about special offsets that can be used in %IAccessibleText methods.
  2541. @param [in] boundaryType
  2542. The type of the text portion to return. See ::IA2TextBoundaryType for the complete
  2543. list.
  2544. @param [out] startOffset
  2545. 0 based offset of first character.
  2546. @param [out] endOffset
  2547. 0 based offset of one past the last character.
  2548. @param [out] text
  2549. Returns the requested text portion. This portion may be empty or invalid when
  2550. no appropriate text portion is found or text type is invalid.
  2551. @retval S_OK
  2552. @retval S_FALSE if the requested boundary type is not implemented, such as
  2553. ::IA2_TEXT_BOUNDARY_SENTENCE, or if there is nothing to return;
  2554. [out] values are 0s and NULL respectively
  2555. @retval E_INVALIDARG if bad [in] passed
  2556. */
  2557. [propget] HRESULT textAtOffset
  2558. (
  2559. [in] long offset,
  2560. [in] enum IA2TextBoundaryType boundaryType,
  2561. [out] long *startOffset,
  2562. [out] long *endOffset,
  2563. [out, retval] BSTR *text
  2564. );
  2565. /** @brief Unselects a range of text.
  2566. @param [in] selectionIndex
  2567. Index of selection to remove (0 based).
  2568. @retval S_OK
  2569. @retval E_INVALIDARG if bad [in] passed
  2570. */
  2571. HRESULT removeSelection
  2572. (
  2573. [in] long selectionIndex
  2574. );
  2575. /** @brief Sets the position of the caret.
  2576. The caret position/offset is that of the character logically following it,
  2577. e.g. to the right of it in a left to right language.
  2578. Setting the caret position may or may not alter the current selection. A
  2579. change of the selection is notified to the accessibility event listeners with
  2580. an ::IA2_EVENT_TEXT_SELECTION_CHANGED event.
  2581. When the new caret position differs from the old one (which, of course, is the
  2582. standard case) this is notified to the accessibility event listeners with an
  2583. ::IA2_EVENT_TEXT_CARET_MOVED event.
  2584. @param [in] offset
  2585. The new index of the caret. This caret is actually placed to the left side of
  2586. the character with that index. An index of 0 places the caret so that the next
  2587. insertion goes before the first character. An index of IAccessibleText::nCharacters
  2588. leads to insertion after the last character. Refer to @ref _specialOffsets
  2589. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  2590. for information about special offsets that can be used in %IAccessibleText methods.
  2591. @retval S_OK
  2592. @retval E_FAIL if the caret cannot be set
  2593. @retval E_INVALIDARG if bad [in] passed
  2594. */
  2595. HRESULT setCaretOffset
  2596. (
  2597. [in] long offset
  2598. );
  2599. /** @brief Changes the bounds of an existing selection.
  2600. @param [in] selectionIndex
  2601. Index of selection to change (0 based)
  2602. @param [in] startOffset
  2603. New starting offset (0 based)
  2604. @param [in] endOffset
  2605. New ending offset (0 based) - the offset of the character just past the last character of the selection.
  2606. @retval S_OK
  2607. @retval E_INVALIDARG if bad [in] passed
  2608. @note Refer to @ref _specialOffsets
  2609. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  2610. for information about special offsets that can be used in %IAccessibleText methods.
  2611. */
  2612. HRESULT setSelection
  2613. (
  2614. [in] long selectionIndex,
  2615. [in] long startOffset,
  2616. [in] long endOffset
  2617. );
  2618. /** @brief Returns total number of characters.
  2619. Note that this may be different than the total number of bytes required to store the
  2620. text, if the text contains multi-byte characters.
  2621. @param [out] nCharacters
  2622. @retval S_OK
  2623. */
  2624. [propget] HRESULT nCharacters
  2625. (
  2626. [out, retval] long *nCharacters
  2627. );
  2628. /** @brief Makes a specific part of string visible on screen.
  2629. @param [in] startIndex
  2630. 0 based character offset.
  2631. @param [in] endIndex
  2632. 0 based character offset - the offset of the character just past the last character of the string.
  2633. @param [in] scrollType
  2634. Defines where the object should be placed on the screen.
  2635. @retval S_OK
  2636. @retval E_INVALIDARG if bad [in] passed
  2637. @note Refer to @ref _specialOffsets
  2638. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  2639. for information about special offsets that can be used in %IAccessibleText methods.
  2640. */
  2641. HRESULT scrollSubstringTo
  2642. (
  2643. [in] long startIndex,
  2644. [in] long endIndex,
  2645. [in] enum IA2ScrollType scrollType
  2646. );
  2647. /** @brief Moves the top left of a substring to a specified location.
  2648. @param [in] startIndex
  2649. 0 based character offset.
  2650. @param [in] endIndex
  2651. 0 based character offset - the offset of the character just past the last character of the string.
  2652. @param [in] coordinateType
  2653. Specifies whether the coordinates are relative to the screen or the parent object.
  2654. @param [in] x
  2655. Defines the x coordinate.
  2656. @param [in] y
  2657. Defines the y coordinate.
  2658. @retval S_OK
  2659. @retval S_FALSE if the object is already at the specified location.
  2660. @retval E_INVALIDARG if bad [in] passed
  2661. @note Refer to @ref _specialOffsets
  2662. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  2663. for information about special offsets that can be used in %IAccessibleText methods.
  2664. */
  2665. HRESULT scrollSubstringToPoint
  2666. (
  2667. [in] long startIndex,
  2668. [in] long endIndex,
  2669. [in] enum IA2CoordinateType coordinateType,
  2670. [in] long x,
  2671. [in] long y
  2672. );
  2673. /** @brief Returns any inserted text.
  2674. Provided for use by the ::IA2_EVENT_TEXT_INSERTED and ::IA2_EVENT_TEXT_UPDATED
  2675. event handlers.
  2676. This data is only guaranteed to be valid while the thread notifying the event
  2677. continues. Once the handler has returned, the validity of the data depends on
  2678. how the server manages the life cycle of its objects. Also, note that the server
  2679. may have different life cycle management strategies for controls depending on
  2680. whether or not a control manages its children. Lists, trees, and tables can have
  2681. a large number of children and thus it's possible that the child objects for those
  2682. controls would only be created as needed. Servers should document their life cycle
  2683. strategy as this will be of interest to assistive technology or script engines
  2684. accessing data out of process or from other threads. Servers only need to save the
  2685. last inserted block of text and a scope of the entire application is adequate.
  2686. @param [out] newText
  2687. The text that was just inserted.
  2688. @retval S_OK
  2689. @retval S_FALSE If there is nothing to return, the values of IA2TextSegment
  2690. struct are set as follows: text = NULL, start = 0, end = 0.
  2691. */
  2692. [propget] HRESULT newText
  2693. (
  2694. [out, retval] IA2TextSegment *newText
  2695. );
  2696. /** @brief Returns any removed text.
  2697. Provided for use by the IA2_EVENT_TEXT_REMOVED/UPDATED event handlers.
  2698. This data is only guaranteed to be valid while the thread notifying the event
  2699. continues. Once the handler has returned, the validity of the data depends on
  2700. how the server manages the life cycle of its objects. Also, note that the server
  2701. may have different life cycle management strategies for controls depending on
  2702. whether or not a control manages its children. Lists, trees, and tables can have
  2703. a large number of children and thus it's possible that the child objects for those
  2704. controls would only be created as needed. Servers should document their life cycle
  2705. strategy as this will be of interest to assistive technology or script engines
  2706. accessing data out of process or from other threads. Servers only need to save the
  2707. last removed block of text and a scope of the entire application is adequate.
  2708. @param [out] oldText
  2709. The text that was just removed.
  2710. @retval S_OK
  2711. @retval S_FALSE If there is nothing to return, the values of IA2TextSegment
  2712. struct are set as follows: text = NULL, start = 0, end = 0.
  2713. */
  2714. [propget] HRESULT oldText
  2715. (
  2716. [out, retval] IA2TextSegment *oldText
  2717. );
  2718. }
  2719. /*************************************************************************
  2720. *
  2721. * File Name (AccessibleText2.idl)
  2722. *
  2723. * IAccessible2 IDL Specification
  2724. *
  2725. * Copyright (c) 2007, 2013 Linux Foundation
  2726. * Copyright (c) 2006 IBM Corporation
  2727. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  2728. * All rights reserved.
  2729. *
  2730. *
  2731. * Redistribution and use in source and binary forms, with or without
  2732. * modification, are permitted provided that the following conditions
  2733. * are met:
  2734. *
  2735. * 1. Redistributions of source code must retain the above copyright
  2736. * notice, this list of conditions and the following disclaimer.
  2737. *
  2738. * 2. Redistributions in binary form must reproduce the above
  2739. * copyright notice, this list of conditions and the following
  2740. * disclaimer in the documentation and/or other materials
  2741. * provided with the distribution.
  2742. *
  2743. * 3. Neither the name of the Linux Foundation nor the names of its
  2744. * contributors may be used to endorse or promote products
  2745. * derived from this software without specific prior written
  2746. * permission.
  2747. *
  2748. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  2749. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  2750. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  2751. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  2752. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  2753. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  2754. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  2755. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  2756. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2757. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  2758. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  2759. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  2760. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  2761. *
  2762. * This BSD License conforms to the Open Source Initiative "Simplified
  2763. * BSD License" as published at:
  2764. * http://www.opensource.org/licenses/bsd-license.php
  2765. *
  2766. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  2767. * mark may be used in accordance with the Linux Foundation Trademark
  2768. * Policy to indicate compliance with the IAccessible2 specification.
  2769. *
  2770. ************************************************************************/
  2771. /** @brief This interface gives read-only access to text.
  2772. The %IAccessibleText2 interface extends the functionality of the
  2773. %IAccessibleText interface.
  2774. */
  2775. [object, uuid(9690A9CC-5C80-4DF5-852E-2D5AE4189A54)]
  2776. interface IAccessibleText2 : IAccessibleText
  2777. {
  2778. /** @brief Returns the range and of the specified set of attributes.
  2779. Return the range (start and end offsets) and text attributes that correspond
  2780. to the given attributes filter at the given offset.
  2781. @param [in] offset
  2782. The offset at which to search for the attributes specified in the filter.
  2783. @param [in] filter
  2784. The requested attribute names. The filter format is "attribute1, attribute2".
  2785. @param [out] startOffset
  2786. The starting (0-based) offset of the text containing the specified attributes.
  2787. @param [out] endOffset
  2788. The (0-based) offset one past the last character of the text containing the
  2789. specified attributes.
  2790. @param [out] attributeValues
  2791. The values of the requested attributes.
  2792. @retval S_OK
  2793. @retval S_FALSE if nothing to return, [out] values are -1, -1, NULL respectively.
  2794. @retval E_INVALIDARG if bad [in] passed.
  2795. */
  2796. [propget] HRESULT attributeRange
  2797. (
  2798. [in] long offset,
  2799. [in] BSTR filter,
  2800. [out] long *startOffset,
  2801. [out] long *endOffset,
  2802. [out, retval] BSTR *attributeValues
  2803. );
  2804. }
  2805. /*************************************************************************
  2806. *
  2807. * File Name (accessibleTextSelectionContainer.idl)
  2808. *
  2809. * IAccessible2 IDL Specification
  2810. *
  2811. * Copyright (c) 2007, 2022 Linux Foundation
  2812. * Copyright (c) 2006 IBM Corporation
  2813. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  2814. * All rights reserved.
  2815. *
  2816. *
  2817. * Redistribution and use in source and binary forms, with or without
  2818. * modification, are permitted provided that the following conditions
  2819. * are met:
  2820. *
  2821. * 1. Redistributions of source code must retain the above copyright
  2822. * notice, this list of conditions and the following disclaimer.
  2823. *
  2824. * 2. Redistributions in binary form must reproduce the above
  2825. * copyright notice, this list of conditions and the following
  2826. * disclaimer in the documentation and/or other materials
  2827. * provided with the distribution.
  2828. *
  2829. * 3. Neither the name of the Linux Foundation nor the names of its
  2830. * contributors may be used to endorse or promote products
  2831. * derived from this software without specific prior written
  2832. * permission.
  2833. *
  2834. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  2835. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  2836. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  2837. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  2838. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  2839. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  2840. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  2841. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  2842. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2843. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  2844. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  2845. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  2846. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  2847. *
  2848. * This BSD License conforms to the Open Source Initiative "Simplified
  2849. * BSD License" as published at:
  2850. * http://www.opensource.org/licenses/bsd-license.php
  2851. *
  2852. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  2853. * mark may be used in accordance with the Linux Foundation Trademark
  2854. * Policy to indicate compliance with the IAccessible2 specification.
  2855. *
  2856. ************************************************************************/
  2857. /**
  2858. This structure represents a single text selection within an accessibility
  2859. subtree. This could be within a document, or the subtree of a document. This
  2860. selection is defined by two points in the content, where each one is defined by
  2861. an accessible object supporting the IAccessibleTextInterface and an
  2862. IAccessibleText character offset relative to it.
  2863. The end object must appear after the start object in the accessibility tree,
  2864. i.e. the end object must be reachable from the start object by navigating
  2865. forward (next, first child etc).
  2866. This struct also contains a `startIsActive` boolean, to communicate if the
  2867. start of the selection is the active point or not.
  2868. The active point corresponds to the user's focus or point of interest. The user
  2869. moves the active point to expand or collapse the range. The anchor point is
  2870. the other point of the range and typically remains constant. In most cases,
  2871. anchor is the start of the range and active is the end. However, when selecting
  2872. backwards (e.g. pressing shift+left arrow in a text field), the start of the
  2873. range is the active point, as the user moves this to manipulate the selection.
  2874. */
  2875. typedef struct IA2TextSelection {
  2876. IAccessibleText* startObj;
  2877. long startOffset;
  2878. IAccessibleText* endObj;
  2879. long endOffset;
  2880. boolean startIsActive;
  2881. } IA2TextSelection;
  2882. /**
  2883. @brief an interface to get and set text selections in a document.
  2884. this interface can be supported on any object that also supports the
  2885. IAccessibleText and/or IAccessibleHypertext interfaces. This could be a
  2886. document, any subtree of a document, or a text input control.
  2887. */
  2888. [object, uuid(2118B599-733F-43D0-A569-0B31D125ED9A)]
  2889. interface IAccessibleTextSelectionContainer : IUnknown
  2890. {
  2891. /**
  2892. @brief Returns an array of selections within this subtree.
  2893. @param [out] selections
  2894. The array of selections, allocated by the server. The client must free it
  2895. with CoTaskMemFree. The selections returned will be cropped to fit entirely
  2896. within this subtree, i.e. to only reference descendant objects, even if the
  2897. physical selection may reach outside of this subtree. In the case where the
  2898. physical selection is entirely outside the subtree, an empty array will be
  2899. returned.
  2900. @param [out] nSelections
  2901. the array length
  2902. @retval S_OK
  2903. @retval S_FALSE returned if there are no selections within this subtree, or
  2904. the physical selection is entirely outside of this subtree.
  2905. */
  2906. [propget] HRESULT selections
  2907. (
  2908. [out, size_is(,*nSelections)] IA2TextSelection **selections,
  2909. [out, retval] long *nSelections
  2910. );
  2911. /**
  2912. @brief makes 1 or more selections within this subtree denoted by the given
  2913. array of IA2TextSelections.
  2914. Any existing physical selection (inside or outside this subtree) is replaced
  2915. by the new selections. All objects within the given selection ranges must be
  2916. descendants of this subtree, otherwise E_INVALIDARG will be returned.
  2917. @param [in] nSelections
  2918. The length of the array containing the selection ranges.
  2919. @param [in] selections
  2920. The array of selection ranges.
  2921. @retval S_OK Returned if the selections were made successfully.
  2922. @retval S_FALSE Returned if the selections could not be made.
  2923. @retval E_INVALIDARG Returned if any of the input arguments are invalid, or
  2924. any of the objects in the given ranges are outside of this subtree.
  2925. */
  2926. HRESULT setSelections
  2927. (
  2928. [in] long nSelections,
  2929. [in, size_is(nSelections)] IA2TextSelection* selections
  2930. );
  2931. }
  2932. /*************************************************************************
  2933. *
  2934. * File Name (AccessibleEditableText.idl)
  2935. *
  2936. * IAccessible2 IDL Specification
  2937. *
  2938. * Copyright (c) 2007, 2012 Linux Foundation
  2939. * Copyright (c) 2006 IBM Corporation
  2940. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  2941. * All rights reserved.
  2942. *
  2943. *
  2944. * Redistribution and use in source and binary forms, with or without
  2945. * modification, are permitted provided that the following conditions
  2946. * are met:
  2947. *
  2948. * 1. Redistributions of source code must retain the above copyright
  2949. * notice, this list of conditions and the following disclaimer.
  2950. *
  2951. * 2. Redistributions in binary form must reproduce the above
  2952. * copyright notice, this list of conditions and the following
  2953. * disclaimer in the documentation and/or other materials
  2954. * provided with the distribution.
  2955. *
  2956. * 3. Neither the name of the Linux Foundation nor the names of its
  2957. * contributors may be used to endorse or promote products
  2958. * derived from this software without specific prior written
  2959. * permission.
  2960. *
  2961. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  2962. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  2963. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  2964. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  2965. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  2966. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  2967. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  2968. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  2969. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2970. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  2971. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  2972. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  2973. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  2974. *
  2975. * This BSD License conforms to the Open Source Initiative "Simplified
  2976. * BSD License" as published at:
  2977. * http://www.opensource.org/licenses/bsd-license.php
  2978. *
  2979. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  2980. * mark may be used in accordance with the Linux Foundation Trademark
  2981. * Policy to indicate compliance with the IAccessible2 specification.
  2982. *
  2983. ************************************************************************/
  2984. /** @brief This interface provides clipboard capability to text objects.
  2985. This interface is typically used in conjunction with the IAccessibleText
  2986. interface and complements that interface with the additional capability of
  2987. clipboard operations. Note that even a read only text object can support
  2988. the copy capability so this interface is not limited to editable objects.
  2989. The substrings used with this interface are specified as follows:
  2990. If startOffset is less than endOffset, the substring starts with the
  2991. character at startOffset and ends with the character just before endOffset.
  2992. If endOffset is lower than startOffset, the result is the same as a call
  2993. with the two arguments exchanged. The whole text can be defined by passing
  2994. the indices zero and IAccessibleText::nCharacters. If both indices have the
  2995. same value, an empty string is defined.
  2996. Refer to the @ref _specialOffsets
  2997. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  2998. for information about a special offset constant that can be used in %IAccessibleEditableText methods.
  2999. */
  3000. [object, uuid(A59AA09A-7011-4b65-939D-32B1FB5547E3)]
  3001. interface IAccessibleEditableText : IUnknown
  3002. {
  3003. /** @brief Copies the text range into the clipboard.
  3004. The selection is set to the specified offsets and then selection is copied into
  3005. the system clipboard.
  3006. @param [in] startOffset
  3007. Start index of the text to moved into the clipboard.
  3008. The valid range is 0..length.
  3009. @param [in] endOffset
  3010. End index of the text to moved into the clipboard.
  3011. The valid range is 0..length.
  3012. @retval S_OK
  3013. @retval E_INVALIDARG if bad [in] passed
  3014. @note Refer to @ref _specialOffsets
  3015. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  3016. for information about special offsets that can be used in %IAccessibleEditableText
  3017. methods.
  3018. @deprecated This function is available via the application's GUI.
  3019. */
  3020. HRESULT copyText
  3021. (
  3022. [in] long startOffset,
  3023. [in] long endOffset
  3024. );
  3025. /** @brief Deletes a range of text.
  3026. The text between and including the two given indices is deleted
  3027. from the text represented by this object.
  3028. @param [in] startOffset
  3029. Start index of the text to be deleted.
  3030. The valid range is 0..length.
  3031. @param [in] endOffset
  3032. End index of the text to be deleted.
  3033. The valid range is 0..length.
  3034. @retval S_OK
  3035. @retval E_INVALIDARG if bad [in] passed
  3036. @note Refer to @ref _specialOffsets
  3037. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  3038. for information about special offsets that can be used in %IAccessibleEditableText
  3039. methods.
  3040. */
  3041. HRESULT deleteText
  3042. (
  3043. [in] long startOffset,
  3044. [in] long endOffset
  3045. );
  3046. /** @brief Inserts text at the specified position.
  3047. The specified string is inserted at the given index into the text
  3048. represented by this object.
  3049. @param [in] offset
  3050. Index at which to insert the text.
  3051. The valid range is 0..length.
  3052. Refer to @ref _specialOffsets
  3053. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  3054. for information about special offsets that can be used in %IAccessibleEditableText
  3055. methods.
  3056. @param [in] text
  3057. Text that is inserted.
  3058. @retval S_OK
  3059. @retval E_INVALIDARG if bad [in] passed
  3060. */
  3061. HRESULT insertText
  3062. (
  3063. [in] long offset,
  3064. [in] BSTR *text
  3065. );
  3066. /** @brief Deletes a range of text and copies it to the clipboard.
  3067. The selection is set to the specified offsets, the selection is then copied into
  3068. the system clipboard, and then the selection is deleted.
  3069. @param [in] startOffset
  3070. Start index of the text to be deleted.
  3071. The valid range is 0..length.
  3072. @param [in] endOffset
  3073. End index of the text to be deleted.
  3074. The valid range is 0..length.
  3075. @retval S_OK
  3076. @retval E_INVALIDARG if bad [in] passed
  3077. @note Refer to @ref _specialOffsets
  3078. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  3079. for information about special offsets that can be used in %IAccessibleEditableText
  3080. methods.
  3081. @deprecated This function is available via the application's GUI.
  3082. */
  3083. HRESULT cutText
  3084. (
  3085. [in] long startOffset,
  3086. [in] long endOffset
  3087. );
  3088. /** @brief Pastes content from the clipboard.
  3089. Any existing selection is removed, the clipboard content is then pasted into
  3090. this object's text at the given offset. This method is similar to the insertText
  3091. method. If the index is not valid the system clipboard content is not inserted. The
  3092. behavior is the same as when Ctrl+V is used, i.e. the pasted contents are not
  3093. necessarily plain text.
  3094. @param [in] offset
  3095. Index at which to insert the content from the system clipboard into
  3096. the text represented by this object.
  3097. The valid range is 0..length.
  3098. Refer to @ref _specialOffsets
  3099. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  3100. for information about special offsets that can be used in %IAccessibleEditableText
  3101. methods.
  3102. @retval S_OK
  3103. @retval E_INVALIDARG if bad [in] passed
  3104. @deprecated This function is available via the application's GUI.
  3105. */
  3106. HRESULT pasteText
  3107. (
  3108. [in] long offset
  3109. );
  3110. /** @brief Replaces text.
  3111. The text between the two given indices is replaced by the specified
  3112. replacement string. This method is equivalent to calling first
  3113. IAccessibleEditableText::deleteText with the two indices and then
  3114. calling IAccessibleEditableText::insertText with the replacement text
  3115. at the start index.
  3116. @param [in] startOffset
  3117. Start index of the text to be replaced.
  3118. The valid range is 0..length.
  3119. @param [in] endOffset
  3120. End index of the text to be replaced.
  3121. The valid range is 0..length.
  3122. @param [in] text
  3123. The Text that replaces the text between the given indices.
  3124. @retval S_OK
  3125. @retval E_INVALIDARG if bad [in] passed
  3126. @note Refer to @ref _specialOffsets
  3127. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  3128. for information about special offsets that can be used in %IAccessibleEditableText
  3129. methods.
  3130. */
  3131. HRESULT replaceText
  3132. (
  3133. [in] long startOffset,
  3134. [in] long endOffset,
  3135. [in] BSTR *text
  3136. );
  3137. /** @brief Replaces the attributes of a text range by the given set of attributes.
  3138. Sets the attributes for the text between the two given indices. The old
  3139. attributes are replaced by the new list of attributes.
  3140. @param [in] startOffset
  3141. Start index of the text whose attributes are modified.
  3142. The valid range is 0..length.
  3143. @param [in] endOffset
  3144. End index of the text whose attributes are modified.
  3145. The valid range is 0..length.
  3146. @param [in] attributes
  3147. Set of attributes that replaces the old list of attributes of
  3148. the specified text portion.
  3149. @retval S_OK
  3150. @retval E_INVALIDARG if bad [in] passed
  3151. @note Refer to @ref _specialOffsets
  3152. "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods"
  3153. for information about special offsets that can be used in %IAccessibleEditableText
  3154. methods.
  3155. */
  3156. HRESULT setAttributes
  3157. (
  3158. [in] long startOffset,
  3159. [in] long endOffset,
  3160. [in] BSTR *attributes
  3161. );
  3162. }
  3163. /*************************************************************************
  3164. *
  3165. * File Name (AccessibleHyperlink.idl)
  3166. *
  3167. * IAccessible2 IDL Specification
  3168. *
  3169. * Copyright (c) 2007, 2010 Linux Foundation
  3170. * Copyright (c) 2006 IBM Corporation
  3171. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  3172. * All rights reserved.
  3173. *
  3174. *
  3175. * Redistribution and use in source and binary forms, with or without
  3176. * modification, are permitted provided that the following conditions
  3177. * are met:
  3178. *
  3179. * 1. Redistributions of source code must retain the above copyright
  3180. * notice, this list of conditions and the following disclaimer.
  3181. *
  3182. * 2. Redistributions in binary form must reproduce the above
  3183. * copyright notice, this list of conditions and the following
  3184. * disclaimer in the documentation and/or other materials
  3185. * provided with the distribution.
  3186. *
  3187. * 3. Neither the name of the Linux Foundation nor the names of its
  3188. * contributors may be used to endorse or promote products
  3189. * derived from this software without specific prior written
  3190. * permission.
  3191. *
  3192. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  3193. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  3194. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  3195. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  3196. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  3197. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  3198. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  3199. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  3200. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  3201. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  3202. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  3203. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  3204. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  3205. *
  3206. * This BSD License conforms to the Open Source Initiative "Simplified
  3207. * BSD License" as published at:
  3208. * http://www.opensource.org/licenses/bsd-license.php
  3209. *
  3210. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  3211. * mark may be used in accordance with the Linux Foundation Trademark
  3212. * Policy to indicate compliance with the IAccessible2 specification.
  3213. *
  3214. ************************************************************************/
  3215. /** @brief This interface represents hyperlinks.
  3216. This interface represents a hyperlink associated with a single substring
  3217. of text or single non-text object. Non-text objects can have either a
  3218. single link or a collection of links such as when the non-text object is
  3219. an image map.
  3220. Linked objects and anchors are implementation dependent. This interface is derived
  3221. from IAccessibleAction. IAccessibleAction::nActions is one greater than the
  3222. maximum value for the indices used with the methods of this interface.
  3223. Furthermore, the object that implements this interface has to be connected
  3224. implicitly or explicitly with an object that implements IAccessibleText.
  3225. IAccessibleHyperlink::startIndex and IAccessibleHyperlink::endIndex are
  3226. indices with respect to the text exposed by IAccessibleText.
  3227. This interface provides access to a single object which can have multiple actions.
  3228. An example is an image map which is an image with multiple links each of which is
  3229. associated with a separate non-overlapping area of the image. This interface could
  3230. also be applied to other kinds of objects with multiple actions such as "smart tags"
  3231. which are objects, typically strings, which have multiple actions such as
  3232. "Activate URI", "Bookmark URI", etc.
  3233. An interesting use case is an image map where each area is associated with multiple
  3234. actions, e.g. an image map of smart tags. In this case you would have to implement
  3235. two levels of accessible hyperlinks. The first level hyperlinks would only implement
  3236. anchor and anchorTarget. The anchors would all reference the image object. The
  3237. anchorTargets would reference the second level accessible hyperlink objects. None
  3238. of the IAccessibleAction methods would be implemented on the first level hyperlink
  3239. objects. The second level hyperlink objects would implement the IAccessibleAction
  3240. methods. Their anchors would also reference the image object and their anchorTargets
  3241. would reference URLs or the objects that would be activated.
  3242. This use case demonstrates that in some cases there is no need for IAccessibleHyperlink
  3243. to derive from IAccessibleAction. As a result it may be removed in a later version of
  3244. the IDL and it is suggested that implementations should not rely on the inheritance.
  3245. */
  3246. [object, uuid(01C20F2B-3DD2-400f-949F-AD00BDAB1D41)]
  3247. interface IAccessibleHyperlink : IAccessibleAction
  3248. {
  3249. /** @brief Returns an object that represents the link anchor, as appropriate
  3250. for the link at the specified index.
  3251. @param [in] index
  3252. A 0 based index identifies the anchor when, as in the case of an image map,
  3253. there is more than one link represented by this object. The valid maximal
  3254. index is indicated by IAccessibleAction::nActions.
  3255. @param [out] anchor
  3256. This is an implementation dependent value. For example, for a text link this
  3257. method could return the substring of the containing string where the substring
  3258. is overridden with link behavior, and for an image link this method could return
  3259. an IUnknown VARIANT for IAccessibleImage. See the section about
  3260. @ref _variants "VARIANTs" for additional information.
  3261. @retval S_OK
  3262. @retval E_INVALIDARG if bad [in] passed
  3263. */
  3264. [propget] HRESULT anchor
  3265. (
  3266. [in] long index,
  3267. [out, retval] VARIANT *anchor
  3268. );
  3269. /** @brief Returns an object representing the target of the link, as appropriate
  3270. for the link at the specified index.
  3271. @param [in] index
  3272. A 0 based index identifies the anchor when, as in the case of an image map,
  3273. there is more than one link represented by this object. The valid maximal
  3274. index is indicated by IAccessibleAction::nActions.
  3275. @param [out] anchorTarget
  3276. This is an implementation dependent value. For example this method could
  3277. return a BSTR VARIANT of the URI. Alternatively this method could return an
  3278. IUnknown VARIANT of a COM interface representing a target object to be
  3279. activated when the link is activated. See the section about
  3280. @ref _variants "VARIANTs" for additional information.
  3281. @retval S_OK
  3282. @retval E_INVALIDARG if bad [in] passed
  3283. */
  3284. [propget] HRESULT anchorTarget
  3285. (
  3286. [in] long index,
  3287. [out, retval] VARIANT *anchorTarget
  3288. );
  3289. /** @brief Returns the 0 based character offset at which the textual representation of the hyperlink starts.
  3290. The returned value is related to the IAccessibleText interface of the object that
  3291. owns this hyperlink.
  3292. @param [out] index
  3293. @retval S_OK
  3294. */
  3295. [propget] HRESULT startIndex
  3296. (
  3297. [out, retval] long *index
  3298. );
  3299. /** @brief Returns the 0 based character offset at which the textual representation of the hyperlink ends.
  3300. The returned value is related to the IAccessibleText interface of the object that
  3301. owns this hyperlink. The character at the index is not part of the hypertext.
  3302. @param [out] index
  3303. @retval S_OK
  3304. */
  3305. [propget] HRESULT endIndex
  3306. (
  3307. [out, retval] long *index
  3308. );
  3309. /** @brief Returns whether the target object referenced by this link is still valid.
  3310. This is a volatile state that may change without sending an appropriate event.
  3311. Returns TRUE if the referenced target is still valid and FALSE otherwise.
  3312. This has also been used to indicate whether or not the URI of the anchorTarget
  3313. is malformed.
  3314. @param [out] valid
  3315. If false, one or more of the object's links are invalid.
  3316. If true, all of the object's links are valid.
  3317. @retval S_OK
  3318. @retval S_FALSE if there is nothing to return, [out] value is FALSE
  3319. @note This method is not being used, is deprecated, and should not be implemented or
  3320. used. It is likely that this method will be removed in a later version of the IDL.
  3321. */
  3322. [propget] HRESULT valid
  3323. (
  3324. [out, retval] boolean *valid
  3325. );
  3326. }
  3327. /*************************************************************************
  3328. *
  3329. * File Name (AccessibleHypertext.idl)
  3330. *
  3331. * IAccessible2 IDL Specification
  3332. *
  3333. * Copyright (c) 2007, 2010 Linux Foundation
  3334. * Copyright (c) 2006 IBM Corporation
  3335. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  3336. * All rights reserved.
  3337. *
  3338. *
  3339. * Redistribution and use in source and binary forms, with or without
  3340. * modification, are permitted provided that the following conditions
  3341. * are met:
  3342. *
  3343. * 1. Redistributions of source code must retain the above copyright
  3344. * notice, this list of conditions and the following disclaimer.
  3345. *
  3346. * 2. Redistributions in binary form must reproduce the above
  3347. * copyright notice, this list of conditions and the following
  3348. * disclaimer in the documentation and/or other materials
  3349. * provided with the distribution.
  3350. *
  3351. * 3. Neither the name of the Linux Foundation nor the names of its
  3352. * contributors may be used to endorse or promote products
  3353. * derived from this software without specific prior written
  3354. * permission.
  3355. *
  3356. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  3357. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  3358. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  3359. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  3360. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  3361. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  3362. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  3363. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  3364. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  3365. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  3366. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  3367. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  3368. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  3369. *
  3370. * This BSD License conforms to the Open Source Initiative "Simplified
  3371. * BSD License" as published at:
  3372. * http://www.opensource.org/licenses/bsd-license.php
  3373. *
  3374. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  3375. * mark may be used in accordance with the Linux Foundation Trademark
  3376. * Policy to indicate compliance with the IAccessible2 specification.
  3377. *
  3378. ************************************************************************/
  3379. /** @brief This interface exposes information about hypertext in a document.
  3380. The %IAccessibleHypertext interface is the main interface to expose
  3381. hyperlinks in a document, typically a text document, that are used
  3382. to reference other documents. A typical implementation is to implement
  3383. this interface on the smallest text object such as a paragraph of text.
  3384. */
  3385. [object, uuid(6B4F8BBF-F1F2-418a-B35E-A195BC4103B9)]
  3386. interface IAccessibleHypertext : IAccessibleText
  3387. {
  3388. /** @brief Returns the number of links and link groups contained within this hypertext
  3389. paragraph.
  3390. @param [out] hyperlinkCount
  3391. The number of links and link groups within this hypertext paragraph.
  3392. Returns 0 if there is no link.
  3393. @retval S_OK
  3394. */
  3395. [propget] HRESULT nHyperlinks
  3396. (
  3397. [out, retval] long *hyperlinkCount
  3398. );
  3399. /** @brief Returns the specified link.
  3400. The returned IAccessibleHyperlink object encapsulates the hyperlink and
  3401. provides several kinds of information describing it.
  3402. @param [in] index
  3403. This 0 based index specifies the hyperlink to return.
  3404. @param [out] hyperlink
  3405. If the given index is valid, i.e. lies in the interval from 0 to the number
  3406. of links minus one, a reference to the specified hyperlink object is returned.
  3407. If the index is invalid then a NULL pointer is returned.
  3408. @retval S_OK
  3409. @retval E_INVALIDARG if bad [in] passed
  3410. */
  3411. [propget] HRESULT hyperlink
  3412. (
  3413. [in] long index,
  3414. [out, retval] IAccessibleHyperlink **hyperlink
  3415. );
  3416. /** @brief Returns the index of the hyperlink that is associated with this character index.
  3417. This is the case when a link spans the given character index.
  3418. @param [in] charIndex
  3419. A 0 based index of the character for which to return the link index. If
  3420. IAccessibleText is used to represent the text containing the link, then the
  3421. character index is only valid if it is greater than or equal to zero and
  3422. lower than the number of characters in the text.
  3423. @param [out] hyperlinkIndex
  3424. Returns the 0 based index of the hyperlink that is associated with this
  3425. character index, or -1 if charIndex is not on a link.
  3426. @retval S_OK
  3427. @retval S_FALSE if there is nothing to return, [out] value is -1
  3428. @retval E_INVALIDARG if bad [in] passed
  3429. */
  3430. [propget] HRESULT hyperlinkIndex
  3431. (
  3432. [in] long charIndex,
  3433. [out, retval] long *hyperlinkIndex
  3434. );
  3435. }
  3436. /*************************************************************************
  3437. *
  3438. * File Name (AccessibleHypertext2.idl)
  3439. *
  3440. * IAccessible2 IDL Specification
  3441. *
  3442. * Copyright (c) 2007, 2013 Linux Foundation
  3443. * Copyright (c) 2006 IBM Corporation
  3444. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  3445. * All rights reserved.
  3446. *
  3447. *
  3448. * Redistribution and use in source and binary forms, with or without
  3449. * modification, are permitted provided that the following conditions
  3450. * are met:
  3451. *
  3452. * 1. Redistributions of source code must retain the above copyright
  3453. * notice, this list of conditions and the following disclaimer.
  3454. *
  3455. * 2. Redistributions in binary form must reproduce the above
  3456. * copyright notice, this list of conditions and the following
  3457. * disclaimer in the documentation and/or other materials
  3458. * provided with the distribution.
  3459. *
  3460. * 3. Neither the name of the Linux Foundation nor the names of its
  3461. * contributors may be used to endorse or promote products
  3462. * derived from this software without specific prior written
  3463. * permission.
  3464. *
  3465. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  3466. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  3467. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  3468. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  3469. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  3470. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  3471. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  3472. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  3473. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  3474. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  3475. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  3476. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  3477. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  3478. *
  3479. * This BSD License conforms to the Open Source Initiative "Simplified
  3480. * BSD License" as published at:
  3481. * http://www.opensource.org/licenses/bsd-license.php
  3482. *
  3483. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  3484. * mark may be used in accordance with the Linux Foundation Trademark
  3485. * Policy to indicate compliance with the IAccessible2 specification.
  3486. *
  3487. ************************************************************************/
  3488. /** @brief This interface exposes information about hypertext in a document.
  3489. The %IAccessibleHypertext2 interface extends the functinality of the
  3490. %IAccessibleHypertext inteface.
  3491. */
  3492. [object, uuid(CF64D89F-8287-4B44-8501-A827453A6077)]
  3493. interface IAccessibleHypertext2 : IAccessibleHypertext
  3494. {
  3495. /** @brief Returns the links for this object.
  3496. The returned IAccessibleHyperlink objects encapsulate the hyperlink and
  3497. provides several kinds of information describing it.
  3498. @param [out] hyperlinks
  3499. This array is allocated by the server. The client must free it with CoTaskMemFree.
  3500. @param [out] nHyperlinks
  3501. The number of links returned; the size of the returned array.
  3502. @retval S_OK
  3503. @retval S_FALSE if there are no links, [out] values are NULL and 0 respectively
  3504. */
  3505. [propget] HRESULT hyperlinks
  3506. (
  3507. [out, size_is(,*nHyperlinks)] IAccessibleHyperlink ***hyperlinks,
  3508. [out, retval] long *nHyperlinks
  3509. );
  3510. }
  3511. /*************************************************************************
  3512. *
  3513. * File Name (AccessibleTable.idl)
  3514. *
  3515. * IAccessible2 IDL Specification
  3516. *
  3517. * Copyright (c) 2007, 2013 Linux Foundation
  3518. * Copyright (c) 2006 IBM Corporation
  3519. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  3520. * All rights reserved.
  3521. *
  3522. *
  3523. * Redistribution and use in source and binary forms, with or without
  3524. * modification, are permitted provided that the following conditions
  3525. * are met:
  3526. *
  3527. * 1. Redistributions of source code must retain the above copyright
  3528. * notice, this list of conditions and the following disclaimer.
  3529. *
  3530. * 2. Redistributions in binary form must reproduce the above
  3531. * copyright notice, this list of conditions and the following
  3532. * disclaimer in the documentation and/or other materials
  3533. * provided with the distribution.
  3534. *
  3535. * 3. Neither the name of the Linux Foundation nor the names of its
  3536. * contributors may be used to endorse or promote products
  3537. * derived from this software without specific prior written
  3538. * permission.
  3539. *
  3540. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  3541. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  3542. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  3543. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  3544. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  3545. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  3546. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  3547. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  3548. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  3549. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  3550. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  3551. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  3552. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  3553. *
  3554. * This BSD License conforms to the Open Source Initiative "Simplified
  3555. * BSD License" as published at:
  3556. * http://www.opensource.org/licenses/bsd-license.php
  3557. *
  3558. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  3559. * mark may be used in accordance with the Linux Foundation Trademark
  3560. * Policy to indicate compliance with the IAccessible2 specification.
  3561. *
  3562. ************************************************************************/
  3563. /** @brief This interface gives access to a two-dimensional table.
  3564. Typically all accessible objects that represent cells or cell-clusters of a table
  3565. will be at the same time children of the table. In this case IAccessible2::indexInParent
  3566. will return the child index which then can be used when calling IAccessibleTable::rowIndex
  3567. and IAccessibleTable::columnIndex.
  3568. However, in some cases that kind of implementation will not be possible. When
  3569. the table cells are not direct children of a table, the object representing
  3570. the cell can define a "table-cell-index" object attribute identifying the 0
  3571. based table cell index. This object attribute is obtained by parsing the
  3572. attribute string returned by IAccessible2::attributes. The "table-cell-index"
  3573. attribute can be used just like a child index of the typical case. ATs should
  3574. first test for the presence of the "table-cell-index" attribute and if it is not
  3575. present then IAccessible2::indexInParent can be used as in the typical case
  3576. where cells are direct children of the table.
  3577. The range of valid coordinates for this interface are implementation dependent.
  3578. However, that range includes at least the intervals from the from the first row
  3579. or column with the index 0 up to the last (but not including) used row or column
  3580. as returned by IAccessibleTable::nRows and IAccessibleTable::nColumns.
  3581. Note that newer implementations are now using IAccessibleTable2 and IAccessibleTableCell
  3582. rather than this interface.
  3583. */
  3584. [object, uuid(35AD8070-C20C-4fb4-B094-F4F7275DD469)]
  3585. interface IAccessibleTable : IUnknown
  3586. {
  3587. /** @brief Returns the accessible object at the specified row and column in
  3588. the table. This object could be an IAccessible or an IAccessible2.
  3589. @param [in] row
  3590. The 0 based row index for which to retrieve the cell.
  3591. @param [in] column
  3592. The 0 based column index for which to retrieve the cell.
  3593. @param [out] accessible
  3594. If both row and column index are valid then the corresponding accessible
  3595. object is returned that represents the requested cell regardless of whether
  3596. the cell is currently visible (on the screen).
  3597. @retval S_OK
  3598. @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
  3599. */
  3600. [propget] HRESULT accessibleAt
  3601. (
  3602. [in] long row,
  3603. [in] long column,
  3604. [out, retval] IUnknown **accessible
  3605. );
  3606. /** @brief Returns the caption for the table. The returned object could be
  3607. an IAccessible or an IAccessible2.
  3608. @param [out] accessible
  3609. If the table has a caption then a reference to it is returned, else a NULL
  3610. pointer is returned.
  3611. @retval S_OK
  3612. @retval S_FALSE if there is nothing to return, [out] value is NULL
  3613. */
  3614. [propget] HRESULT caption
  3615. (
  3616. [out, retval] IUnknown **accessible
  3617. );
  3618. /** @brief Translates the given row and column indexes into the corresponding cell index.
  3619. @param [in] rowIndex
  3620. 0 based row index for the cell.
  3621. @param [in] columnIndex
  3622. 0 based column index for the cell.
  3623. @param [out] cellIndex
  3624. Returns the 0 based index of the cell at the specified row and column indexes.
  3625. @retval S_OK
  3626. @retval E_INVALIDARG if bad [in] passed, [out] value is 0
  3627. @note The returned value is not necessarily a child index of the immediate parent.
  3628. In cases where the table cells are not direct children of the table the index
  3629. is actually the cell index, i.e. conceptually it's an index into a one dimensional
  3630. array of cells laid out in row order.
  3631. */
  3632. [propget] HRESULT childIndex
  3633. (
  3634. [in] long rowIndex,
  3635. [in] long columnIndex,
  3636. [out, retval] long *cellIndex
  3637. );
  3638. /** @brief Returns the description text of the specified column in the table.
  3639. @param [in] column
  3640. The 0 based index of the column for which to retrieve the description.
  3641. @param [out] description
  3642. Returns the description text of the specified column in the table if such a
  3643. description exists. Otherwise a NULL pointer is returned.
  3644. @retval S_OK
  3645. @retval S_FALSE if there is nothing to return, [out] value is NULL
  3646. @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
  3647. */
  3648. [propget] HRESULT columnDescription
  3649. (
  3650. [in] long column,
  3651. [out, retval] BSTR *description
  3652. );
  3653. /** @brief Returns the number of columns occupied by the accessible object
  3654. at the specified row and column in the table.
  3655. The result is greater than 1 if the specified cell spans multiple columns.
  3656. @param [in] row
  3657. 0 based row index of the accessible for which to return the column extent.
  3658. @param [in] column
  3659. 0 based column index of the accessible for which to return the column extent.
  3660. @param [out] nColumnsSpanned
  3661. Returns the 1 based column extent of the specified cell.
  3662. @retval S_OK
  3663. @retval E_INVALIDARG if bad [in] passed, [out] value is 0
  3664. */
  3665. [propget] HRESULT columnExtentAt
  3666. (
  3667. [in] long row,
  3668. [in] long column,
  3669. [out, retval] long *nColumnsSpanned
  3670. );
  3671. /** @brief Returns the column headers as an %IAccessibleTable object.
  3672. Content and size of the returned table are implementation dependent.
  3673. @param [out] accessibleTable
  3674. The column header
  3675. @param [out] startingRowIndex
  3676. The 0 based row index where the header starts, usually 0.
  3677. @retval S_OK
  3678. @retval S_FALSE if there is no header, [out] values are NULL and 0 respectively
  3679. */
  3680. [propget] HRESULT columnHeader
  3681. (
  3682. [out] IAccessibleTable **accessibleTable,
  3683. [out, retval] long *startingRowIndex
  3684. );
  3685. /** @brief Translates the given cell index into the corresponding column index.
  3686. @param [in] cellIndex
  3687. 0 based index of the cell in the parent or closest ancestor table. Typically this
  3688. is the value returned from IAccessible2::indexInParent, but in the case where the
  3689. table cells are not direct children of the table this is the cell index specified
  3690. by the "table-cell-index" object attribute obtained from parsing the attributes
  3691. string returned by calling IAccessible2::attributes on the cell object.
  3692. @param [out] columnIndex
  3693. Returns the 0 based column index of the cell of the specified child or the index of
  3694. the first column if the child spans multiple columns.
  3695. @retval S_OK
  3696. @retval E_INVALIDARG if bad [in] passed, [out] value is 0
  3697. */
  3698. [propget] HRESULT columnIndex
  3699. (
  3700. [in] long cellIndex,
  3701. [out, retval] long *columnIndex
  3702. );
  3703. /** @brief Returns the total number of columns in table
  3704. @param [out] columnCount
  3705. Number of columns in table (including columns outside the current viewport)
  3706. @retval S_OK
  3707. */
  3708. [propget] HRESULT nColumns
  3709. (
  3710. [out, retval] long *columnCount
  3711. );
  3712. /** @brief Returns the total number of rows in table
  3713. @param [out] rowCount
  3714. Number of rows in table (including rows outside the current viewport)
  3715. @retval S_OK
  3716. */
  3717. [propget] HRESULT nRows
  3718. (
  3719. [out, retval] long *rowCount
  3720. );
  3721. /** @brief Returns the total number of selected cells
  3722. @param [out] cellCount
  3723. Number of cells currently selected
  3724. @retval S_OK
  3725. */
  3726. [propget] HRESULT nSelectedChildren
  3727. (
  3728. [out, retval] long *cellCount
  3729. );
  3730. /** @brief Returns the total number of selected columns
  3731. @param [out] columnCount
  3732. Number of columns currently selected
  3733. @retval S_OK
  3734. */
  3735. [propget] HRESULT nSelectedColumns
  3736. (
  3737. [out, retval] long *columnCount
  3738. );
  3739. /** @brief Returns the total number of selected rows
  3740. @param [out] rowCount
  3741. Number of rows currently selected
  3742. @retval S_OK
  3743. */
  3744. [propget] HRESULT nSelectedRows
  3745. (
  3746. [out, retval] long *rowCount
  3747. );
  3748. /** @brief Returns the description text of the specified row in the table.
  3749. @param [in] row
  3750. The 0 based index of the row for which to retrieve the description.
  3751. @param [out] description
  3752. Returns the description text of the specified row in the table if such a
  3753. description exists. Otherwise a NULL pointer is returned.
  3754. @retval S_OK
  3755. @retval S_FALSE if there is nothing to return, [out] value is NULL
  3756. @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
  3757. */
  3758. [propget] HRESULT rowDescription
  3759. (
  3760. [in] long row,
  3761. [out, retval] BSTR *description
  3762. );
  3763. /** @brief Returns the number of rows occupied by the accessible object
  3764. at the specified row and column in the table.
  3765. The result is greater than 1 if the specified cell spans multiple rows.
  3766. @param [in] row
  3767. 0 based row index of the accessible for which to return the row extent.
  3768. @param [in] column
  3769. 0 based column index of the accessible for which to return the row extent.
  3770. @param [out] nRowsSpanned
  3771. Returns the row extent of the specified cell.
  3772. @retval S_OK
  3773. @retval E_INVALIDARG if bad [in] passed, [out] value is 0
  3774. */
  3775. [propget] HRESULT rowExtentAt
  3776. (
  3777. [in] long row,
  3778. [in] long column,
  3779. [out, retval] long *nRowsSpanned
  3780. );
  3781. /** @brief Returns the row headers as an %IAccessibleTable object.
  3782. Content and size of the returned table are implementation dependent.
  3783. @param [out] accessibleTable
  3784. The row header.
  3785. @param [out] startingColumnIndex
  3786. The 0 based column index where the header starts, usually 0.
  3787. @retval S_OK
  3788. @retval S_FALSE if there is no header, [out] values are NULL and 0 respectively
  3789. */
  3790. [propget] HRESULT rowHeader
  3791. (
  3792. [out] IAccessibleTable **accessibleTable,
  3793. [out, retval] long *startingColumnIndex
  3794. );
  3795. /** @brief Translates the given cell index into a row index.
  3796. @param [in] cellIndex
  3797. 0 based index of the cell in the parent or closest ancestor table. Typically this
  3798. is the value returned from IAccessible2::indexInParent, but in the case where the
  3799. table cells are not direct children of the table this is the cell index specified
  3800. by the "table-cell-index" object attribute obtained from parsing the attributes
  3801. string returned by calling IAccessible2::attributes on the cell object.
  3802. @param [out] rowIndex
  3803. 0 based row index
  3804. @retval S_OK
  3805. @retval E_INVALIDARG if bad [in] passed, [out] value is 0
  3806. */
  3807. [propget] HRESULT rowIndex
  3808. (
  3809. [in] long cellIndex,
  3810. [out, retval] long *rowIndex
  3811. );
  3812. /** @brief Returns a list of cell indexes currently selected (0 based).
  3813. @param [in] maxChildren
  3814. This parameter is ignored. Refer to @ref _arrayConsideration
  3815. "Special Consideration when using Arrays" for more details.
  3816. @param [out] children
  3817. An array of cell indexes of selected cells (each index is 0 based),
  3818. allocated by the server. The client must free it with CoTaskMemFree.
  3819. @param [out] nChildren
  3820. The number of cell indexes returned; the size of the returned array.
  3821. @retval S_OK
  3822. @retval S_FALSE if there are none, [out] values are NULL and 0 respectively
  3823. */
  3824. [propget] HRESULT selectedChildren
  3825. (
  3826. [in] long maxChildren,
  3827. [out, size_is(,maxChildren), length_is(,*nChildren)] long **children,
  3828. [out, retval] long *nChildren
  3829. );
  3830. /** @brief Returns a list of column indexes currently selected (0 based).
  3831. @param [in] maxColumns
  3832. This parameter is ignored. Refer to @ref _arrayConsideration
  3833. "Special Consideration when using Arrays" for more details.
  3834. @param [out] columns
  3835. An array of column indexes of selected columns (each index is 0 based), allocated
  3836. by the server. The client must free it with CoTaskMemFree.
  3837. @param [out] nColumns
  3838. The number of column indexes returned; the size of the returned array.
  3839. @retval S_OK
  3840. @retval S_FALSE if there are none, [out] values are NULL and 0 respectively
  3841. */
  3842. [propget] HRESULT selectedColumns
  3843. (
  3844. [in] long maxColumns,
  3845. [out, size_is(,maxColumns), length_is(,*nColumns)] long **columns,
  3846. [out, retval] long *nColumns
  3847. );
  3848. /** @brief Returns a list of row indexes currently selected (0 based).
  3849. @param [in] maxRows
  3850. This parameter is ignored. Refer to @ref _arrayConsideration
  3851. "Special Consideration when using Arrays" for more details.
  3852. @param [out] rows
  3853. An array of row indexes of selected rows (each index is 0 based), allocated
  3854. by the server. The client must free it with CoTaskMemFree.
  3855. @param [out] nRows
  3856. The number of row indexes returned; the size of the returned array.
  3857. @retval S_OK
  3858. @retval S_FALSE if there are none, [out] values are NULL and 0 respectively
  3859. */
  3860. [propget] HRESULT selectedRows
  3861. (
  3862. [in] long maxRows,
  3863. [out, size_is(,maxRows), length_is(,*nRows)] long **rows,
  3864. [out, retval] long *nRows
  3865. );
  3866. /** @brief Returns the summary description of the table. The returned object could be
  3867. an IAccessible or an IAccessible2.
  3868. @param [out] accessible
  3869. Returns a reference to an implementation dependent accessible object
  3870. representing the table's summary or a NULL pointer if the table
  3871. does not support a summary.
  3872. @retval S_OK
  3873. @retval S_FALSE if there is nothing to return, [out] value is NULL
  3874. */
  3875. [propget] HRESULT summary
  3876. (
  3877. [out, retval] IUnknown **accessible
  3878. );
  3879. /** @brief Returns a boolean value indicating whether the specified column is
  3880. completely selected.
  3881. @param [in] column
  3882. 0 based index of the column for which to determine whether it is selected.
  3883. @param [out] isSelected
  3884. Returns TRUE if the specified column is selected completely and FALSE otherwise.
  3885. @retval S_OK
  3886. @retval E_INVALIDARG if bad [in] passed, [out] value is FALSE
  3887. */
  3888. [propget] HRESULT isColumnSelected
  3889. (
  3890. [in] long column,
  3891. [out, retval] boolean *isSelected
  3892. );
  3893. /** @brief Returns a boolean value indicating whether the specified row is completely
  3894. selected.
  3895. @param [in] row
  3896. 0 based index of the row for which to determine whether it is selected.
  3897. @param [out] isSelected
  3898. Returns TRUE if the specified row is selected completely and FALSE otherwise.
  3899. @retval S_OK
  3900. @retval E_INVALIDARG if bad [in] passed, [out] value is FALSE
  3901. */
  3902. [propget] HRESULT isRowSelected
  3903. (
  3904. [in] long row,
  3905. [out, retval] boolean *isSelected
  3906. );
  3907. /** @brief Returns a boolean value indicating whether the specified cell is selected.
  3908. @param [in] row
  3909. 0 based index of the row for the cell to determine whether it is selected.
  3910. @param [in] column
  3911. 0 based index of the column for the cell to determine whether it is selected.
  3912. @param [out] isSelected
  3913. Returns TRUE if the specified cell is selected and FALSE otherwise.
  3914. @retval S_OK
  3915. @retval E_INVALIDARG if bad [in] passed, [out] value is FALSE
  3916. */
  3917. [propget] HRESULT isSelected
  3918. (
  3919. [in] long row,
  3920. [in] long column,
  3921. [out, retval] boolean *isSelected
  3922. );
  3923. /** @brief Selects a row and unselects all previously selected rows.
  3924. @param [in] row
  3925. 0 based index of the row to be selected.
  3926. @retval S_OK
  3927. @retval E_INVALIDARG if bad [in] passed
  3928. */
  3929. HRESULT selectRow
  3930. (
  3931. [in] long row
  3932. );
  3933. /** @brief Selects a column and unselects all previously selected columns.
  3934. @param [in] column
  3935. 0 based index of the column to be selected.
  3936. @retval S_OK
  3937. @retval E_INVALIDARG if bad [in] passed
  3938. */
  3939. HRESULT selectColumn
  3940. (
  3941. [in] long column
  3942. );
  3943. /** @brief Unselects one row, leaving other selected rows selected (if any).
  3944. @param [in] row
  3945. 0 based index of the row to be unselected.
  3946. @retval S_OK
  3947. @retval E_INVALIDARG if bad [in] passed
  3948. */
  3949. HRESULT unselectRow
  3950. (
  3951. [in] long row
  3952. );
  3953. /** @brief Unselects one column, leaving other selected columns selected (if any).
  3954. @param [in] column
  3955. 0 based index of the column to be unselected.
  3956. @retval S_OK
  3957. @retval E_INVALIDARG if bad [in] passed
  3958. */
  3959. HRESULT unselectColumn
  3960. (
  3961. [in] long column
  3962. );
  3963. /** @brief Given a cell index, gets the row and column indexes and extents of a cell
  3964. and whether or not it is selected.
  3965. This is a convenience function. It is not mandatory to implement it.
  3966. @param [in] index
  3967. 0 based index of this cell in the table.
  3968. @param [out] row
  3969. 0 based row index.
  3970. @param [out] column
  3971. 0 based column index.
  3972. @param [out] rowExtents
  3973. Number of cells spanned by this cell in this row.
  3974. @param [out] columnExtents
  3975. Number of cells spanned by this cell in this column.
  3976. @param [out] isSelected
  3977. Indicates if the specified cell is selected.
  3978. @retval S_OK
  3979. @retval E_INVALIDARG if bad [in] passed, [out] values are 0s and FALSE respectively
  3980. */
  3981. [propget] HRESULT rowColumnExtentsAtIndex
  3982. (
  3983. [in] long index,
  3984. [out] long *row,
  3985. [out] long *column,
  3986. [out] long *rowExtents,
  3987. [out] long *columnExtents,
  3988. [out, retval] boolean *isSelected
  3989. );
  3990. /** @brief Returns the type and extents describing how a table changed.
  3991. Provided for use by the IA2_EVENT_TABLE_MODEL_CHANGED event handler.
  3992. This data is only guaranteed to be valid while the thread notifying the event
  3993. continues. Once the handler has returned, the validity of the data depends on
  3994. how the server manages the life cycle of its objects. Also, note that the server
  3995. may have different life cycle management strategies for controls depending on
  3996. whether or not a control manages its children. Lists, trees, and tables can have
  3997. a large number of children and thus it's possible that the child objects for those
  3998. controls would only be created as needed. Servers should document their life cycle
  3999. strategy as this will be of interest to assistive technology or script engines
  4000. accessing data out of process or from other threads. Servers only need to save the
  4001. most recent row and column values associated with the change and a scope of the
  4002. entire application is adequate.
  4003. @param [out] modelChange
  4004. A struct of (type(insert, delete, update), firstRow, lastRow, firstColumn, lastColumn).
  4005. @retval S_OK
  4006. @retval S_FALSE if there is nothing to return, [out] value is NULL
  4007. */
  4008. [propget] HRESULT modelChange
  4009. (
  4010. [out, retval] IA2TableModelChange *modelChange
  4011. );
  4012. }
  4013. /*************************************************************************
  4014. *
  4015. * File Name (AccessibleTable2.idl)
  4016. *
  4017. * IAccessible2 IDL Specification
  4018. *
  4019. * Copyright (c) 2007, 2012 Linux Foundation
  4020. * Copyright (c) 2006 IBM Corporation
  4021. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  4022. * All rights reserved.
  4023. *
  4024. *
  4025. * Redistribution and use in source and binary forms, with or without
  4026. * modification, are permitted provided that the following conditions
  4027. * are met:
  4028. *
  4029. * 1. Redistributions of source code must retain the above copyright
  4030. * notice, this list of conditions and the following disclaimer.
  4031. *
  4032. * 2. Redistributions in binary form must reproduce the above
  4033. * copyright notice, this list of conditions and the following
  4034. * disclaimer in the documentation and/or other materials
  4035. * provided with the distribution.
  4036. *
  4037. * 3. Neither the name of the Linux Foundation nor the names of its
  4038. * contributors may be used to endorse or promote products
  4039. * derived from this software without specific prior written
  4040. * permission.
  4041. *
  4042. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  4043. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  4044. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  4045. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  4046. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  4047. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  4048. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  4049. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  4050. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  4051. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  4052. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  4053. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  4054. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  4055. *
  4056. * This BSD License conforms to the Open Source Initiative "Simplified
  4057. * BSD License" as published at:
  4058. * http://www.opensource.org/licenses/bsd-license.php
  4059. *
  4060. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  4061. * mark may be used in accordance with the Linux Foundation Trademark
  4062. * Policy to indicate compliance with the IAccessible2 specification.
  4063. *
  4064. ************************************************************************/
  4065. /** @brief This interface gives access to a two-dimensional table.
  4066. Please also refer to the IAccessibleTableCell interface.
  4067. If you want to support older applications you should also support the
  4068. IAccessibleTable inteface.
  4069. */
  4070. [object, uuid(6167f295-06f0-4cdd-a1fa-02e25153d869)]
  4071. interface IAccessibleTable2 : IUnknown
  4072. {
  4073. /** @brief Returns the accessible object at the specified row and column in
  4074. the table. This object could be an IAccessible or an IAccessible2.
  4075. @param [in] row
  4076. The 0 based row index for which to retrieve the cell.
  4077. @param [in] column
  4078. The 0 based column index for which to retrieve the cell.
  4079. @param [out] cell
  4080. If both row and column index are valid then the corresponding accessible
  4081. object is returned that represents the requested cell regardless of whether
  4082. the cell is currently visible (on the screen).
  4083. @retval S_OK
  4084. @retval E_INVALIDARG if bad [in] passed
  4085. */
  4086. [propget] HRESULT cellAt
  4087. (
  4088. [in] long row,
  4089. [in] long column,
  4090. [out, retval] IUnknown **cell
  4091. );
  4092. /** @brief Returns the caption for the table. The returned object could be
  4093. an IAccessible or an IAccessible2.
  4094. @param [out] accessible
  4095. If the table has a caption then a reference to it is returned, else a NULL
  4096. pointer is returned.
  4097. @retval S_OK
  4098. @retval S_FALSE if there is nothing to return, [out] value is NULL
  4099. @deprecated use a describedBy relation
  4100. */
  4101. [propget] HRESULT caption
  4102. (
  4103. [out, retval] IUnknown **accessible
  4104. );
  4105. /** @brief Returns the description text of the specified column in the table.
  4106. @param [in] column
  4107. The 0 based index of the column for which to retrieve the description.
  4108. @param [out] description
  4109. Returns the description text of the specified column in the table if such a
  4110. description exists. Otherwise a NULL pointer is returned.
  4111. @retval S_OK
  4112. @retval S_FALSE if there is nothing to return, [out] value is NULL
  4113. @retval E_INVALIDARG if bad [in] passed
  4114. */
  4115. [propget] HRESULT columnDescription
  4116. (
  4117. [in] long column,
  4118. [out, retval] BSTR *description
  4119. );
  4120. /** @brief Returns the total number of columns in table
  4121. @param [out] columnCount
  4122. Number of columns in table (including columns outside the current viewport)
  4123. @retval S_OK
  4124. */
  4125. [propget] HRESULT nColumns
  4126. (
  4127. [out, retval] long *columnCount
  4128. );
  4129. /** @brief Returns the total number of rows in table
  4130. @param [out] rowCount
  4131. Number of rows in table (including rows outside the current viewport)
  4132. @retval S_OK
  4133. */
  4134. [propget] HRESULT nRows
  4135. (
  4136. [out, retval] long *rowCount
  4137. );
  4138. /** @brief Returns the total number of selected cells
  4139. @param [out] cellCount
  4140. Number of cells currently selected
  4141. @retval S_OK
  4142. */
  4143. [propget] HRESULT nSelectedCells
  4144. (
  4145. [out, retval] long *cellCount
  4146. );
  4147. /** @brief Returns the total number of selected columns
  4148. @param [out] columnCount
  4149. Number of columns currently selected
  4150. @retval S_OK
  4151. */
  4152. [propget] HRESULT nSelectedColumns
  4153. (
  4154. [out, retval] long *columnCount
  4155. );
  4156. /** @brief Returns the total number of selected rows
  4157. @param [out] rowCount
  4158. Number of rows currently selected
  4159. @retval S_OK
  4160. */
  4161. [propget] HRESULT nSelectedRows
  4162. (
  4163. [out, retval] long *rowCount
  4164. );
  4165. /** @brief Returns the description text of the specified row in the table.
  4166. @param [in] row
  4167. The 0 based index of the row for which to retrieve the description.
  4168. @param [out] description
  4169. Returns the description text of the specified row in the table if such a
  4170. description exists. Otherwise a NULL pointer is returned.
  4171. @retval S_OK
  4172. @retval S_FALSE if there is nothing to return, [out] value is NULL
  4173. @retval E_INVALIDARG if bad [in] passed
  4174. */
  4175. [propget] HRESULT rowDescription
  4176. (
  4177. [in] long row,
  4178. [out, retval] BSTR *description
  4179. );
  4180. /** @brief Returns a list of accessibles currently selected.
  4181. @param [out] cells
  4182. Pointer to an array of references to selected accessibles. The array is
  4183. allocated by the server with CoTaskMemAlloc and freed by the client with
  4184. CoTaskMemFree.
  4185. @param [out] nSelectedCells
  4186. The number of accessibles returned; the size of the returned array.
  4187. @retval S_OK
  4188. @retval S_FALSE if there are none, [out] values are NULL and 0 respectively
  4189. */
  4190. [propget] HRESULT selectedCells
  4191. (
  4192. [out, size_is(,*nSelectedCells)] IUnknown ***cells,
  4193. [out, retval] long *nSelectedCells
  4194. );
  4195. /** @brief Returns a list of column indexes currently selected (0 based).
  4196. @param [out] selectedColumns
  4197. A pointer to an array of column indexes of selected columns (each index is
  4198. 0 based). The array is allocated by the server with CoTaskMemAlloc and
  4199. freed by the client with CoTaskMemFree.
  4200. @param [out] nColumns
  4201. The number of column indexes returned; the size of the returned array.
  4202. @retval S_OK
  4203. @retval S_FALSE if there are none, [out] values are NULL and 0 respectively
  4204. */
  4205. [propget] HRESULT selectedColumns
  4206. (
  4207. [out, size_is(,*nColumns)] long **selectedColumns,
  4208. [out, retval] long *nColumns
  4209. );
  4210. /** @brief Returns a list of row indexes currently selected (0 based).
  4211. @param [out] selectedRows
  4212. An array of row indexes of selected rows (each index is 0 based). The array
  4213. is allocated by the server with CoTaskMemAlloc and freed by the client with
  4214. CoTaskMemFree.
  4215. @param [out] nRows
  4216. The number of row indexes returned; the size of the returned array.
  4217. @retval S_OK
  4218. @retval S_FALSE if there are none, [out] values are NULL and 0 respectively
  4219. */
  4220. [propget] HRESULT selectedRows
  4221. (
  4222. [out, size_is(,*nRows)] long **selectedRows,
  4223. [out, retval] long *nRows
  4224. );
  4225. /** @brief Returns the summary description of the table. The returned object could be
  4226. an IAccessible or an IAccessible2.
  4227. @param [out] accessible
  4228. Returns a reference to an implementation dependent accessible object
  4229. representing the table's summary or a NULL pointer if the table
  4230. does not support a summary.
  4231. @retval S_OK
  4232. @retval S_FALSE if there is nothing to return, [out] value is NULL
  4233. @deprecated Use the labeledBy relation
  4234. */
  4235. [propget] HRESULT summary
  4236. (
  4237. [out, retval] IUnknown **accessible
  4238. );
  4239. /** @brief Returns a boolean value indicating whether the specified column is
  4240. completely selected.
  4241. @param [in] column
  4242. 0 based index of the column for which to determine whether it is selected.
  4243. @param [out] isSelected
  4244. Returns TRUE if the specified column is selected completely and FALSE otherwise.
  4245. @retval S_OK
  4246. @retval E_INVALIDARG if bad [in] passed
  4247. */
  4248. [propget] HRESULT isColumnSelected
  4249. (
  4250. [in] long column,
  4251. [out, retval] boolean *isSelected
  4252. );
  4253. /** @brief Returns a boolean value indicating whether the specified row is completely
  4254. selected.
  4255. @param [in] row
  4256. 0 based index of the row for which to determine whether it is selected.
  4257. @param [out] isSelected
  4258. Returns TRUE if the specified row is selected completely and FALSE otherwise.
  4259. @retval S_OK
  4260. @retval E_INVALIDARG if bad [in] passed
  4261. */
  4262. [propget] HRESULT isRowSelected
  4263. (
  4264. [in] long row,
  4265. [out, retval] boolean *isSelected
  4266. );
  4267. /** @brief Selects a row and unselects all previously selected rows.
  4268. The behavior should mimic that of the application, but for those applications
  4269. which do not have a means in the GUI to select a full row of cells the behavior
  4270. should be as follows: First any selected rows in the table are unselected. Then
  4271. the entire row of cells for the specified row is selected. If any of the
  4272. cells in the selected row span additional rows, the cells in those rows
  4273. are also selected.
  4274. @param [in] row
  4275. 0 based index of the row to be selected.
  4276. @retval S_OK
  4277. @retval E_INVALIDARG if bad [in] passed
  4278. */
  4279. HRESULT selectRow
  4280. (
  4281. [in] long row
  4282. );
  4283. /** @brief Selects a column and unselects all previously selected columns.
  4284. The behavior should mimic that of the application, but for those applications
  4285. which do not have a means in the GUI to select a full column of cells the behavior
  4286. should be as follows: First any selected columns in the table are unselected. Then
  4287. the entire column of cells for the specified column is selected. If any of the
  4288. cells in the selected column span additional columns, the cells in those columns
  4289. are also selected.
  4290. @param [in] column
  4291. 0 based index of the column to be selected.
  4292. @retval S_OK
  4293. @retval E_INVALIDARG if bad [in] passed
  4294. */
  4295. HRESULT selectColumn
  4296. (
  4297. [in] long column
  4298. );
  4299. /** @brief Unselects one row, leaving other selected rows selected (if any).
  4300. The behavior should mimic that of the application, but for those applications
  4301. which do not have a means in the GUI to unselect a full row of cells the
  4302. behavior should be as follows: The entire row of cells for the specified
  4303. row is unselected. If any of the cells in the selected row span additional
  4304. rows, the cells in those rows are also unselected.
  4305. @param [in] row
  4306. 0 based index of the row to be unselected.
  4307. @retval S_OK
  4308. @retval E_INVALIDARG if bad [in] passed
  4309. */
  4310. HRESULT unselectRow
  4311. (
  4312. [in] long row
  4313. );
  4314. /** @brief Unselects one column, leaving other selected columns selected (if any).
  4315. The behavior should mimic that of the application, but for those applications
  4316. which do not have a means in the GUI to unselect a full column of cells the
  4317. behavior should be as follows: The entire column of cells for the specified
  4318. column is unselected. If any of the cells in the selected column span additional
  4319. columns, the cells in those columns are also unselected.
  4320. @param [in] column
  4321. 0 based index of the column to be unselected.
  4322. @retval S_OK
  4323. @retval E_INVALIDARG if bad [in] passed
  4324. */
  4325. HRESULT unselectColumn
  4326. (
  4327. [in] long column
  4328. );
  4329. /** @brief Returns the type and extents describing how a table changed.
  4330. Provided for use by the IA2_EVENT_TABLE_MODEL_CHANGED event handler.
  4331. This data is only guaranteed to be valid while the thread notifying the event
  4332. continues. Once the handler has returned, the validity of the data depends on
  4333. how the server manages the life cycle of its objects. Also, note that the server
  4334. may have different life cycle management strategies for controls depending on
  4335. whether or not a control manages its children. Lists, trees, and tables can have
  4336. a large number of children and thus it's possible that the child objects for those
  4337. controls would only be created as needed. Servers should document their life cycle
  4338. strategy as this will be of interest to assistive technology or script engines
  4339. accessing data out of process or from other threads. Servers only need to save the
  4340. most recent row and column values associated with the change and a scope of the
  4341. entire application is adequate.
  4342. @param [out] modelChange
  4343. A struct of (type(insert, delete, update), firstRow, lastRow, firstColumn, lastColumn).
  4344. @retval S_OK
  4345. @retval S_FALSE if there is nothing to return, [out] value is NULL
  4346. */
  4347. [propget] HRESULT modelChange
  4348. (
  4349. [out, retval] IA2TableModelChange *modelChange
  4350. );
  4351. }
  4352. /*************************************************************************
  4353. *
  4354. * File Name (AccessibleTableCell.idl)
  4355. *
  4356. * IAccessible2 IDL Specification
  4357. *
  4358. * Copyright (c) 2007, 2013 Linux Foundation
  4359. * Copyright (c) 2006 IBM Corporation
  4360. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  4361. * All rights reserved.
  4362. *
  4363. *
  4364. * Redistribution and use in source and binary forms, with or without
  4365. * modification, are permitted provided that the following conditions
  4366. * are met:
  4367. *
  4368. * 1. Redistributions of source code must retain the above copyright
  4369. * notice, this list of conditions and the following disclaimer.
  4370. *
  4371. * 2. Redistributions in binary form must reproduce the above
  4372. * copyright notice, this list of conditions and the following
  4373. * disclaimer in the documentation and/or other materials
  4374. * provided with the distribution.
  4375. *
  4376. * 3. Neither the name of the Linux Foundation nor the names of its
  4377. * contributors may be used to endorse or promote products
  4378. * derived from this software without specific prior written
  4379. * permission.
  4380. *
  4381. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  4382. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  4383. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  4384. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  4385. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  4386. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  4387. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  4388. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  4389. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  4390. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  4391. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  4392. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  4393. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  4394. *
  4395. * This BSD License conforms to the Open Source Initiative "Simplified
  4396. * BSD License" as published at:
  4397. * http://www.opensource.org/licenses/bsd-license.php
  4398. *
  4399. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  4400. * mark may be used in accordance with the Linux Foundation Trademark
  4401. * Policy to indicate compliance with the IAccessible2 specification.
  4402. *
  4403. ************************************************************************/
  4404. /** @brief This interface gives access to the cells of a two-dimensional table.
  4405. Please also refer to the IAccessibleTable2 interface.
  4406. */
  4407. [object, uuid(594116B1-C99F-4847-AD06-0A7A86ECE645)]
  4408. interface IAccessibleTableCell : IUnknown
  4409. {
  4410. /** @brief Returns the number of columns occupied by this cell accessible.
  4411. The result is greater than 1 if the specified cell spans multiple columns.
  4412. @param [out] nColumnsSpanned
  4413. Returns the 1 based column extent of the specified cell.
  4414. @retval S_OK
  4415. */
  4416. [propget] HRESULT columnExtent
  4417. (
  4418. [out, retval] long *nColumnsSpanned
  4419. );
  4420. /** @brief Returns the column headers as an array of cell accessibles.
  4421. @param [out] cellAccessibles
  4422. Pointer to an array of references to cell accessibles. The array is allocated
  4423. by the server. The client must free it with CoTaskMemFree.
  4424. @param [out] nColumnHeaderCells
  4425. The number of accessibles returned; the size of the returned array.
  4426. @retval S_OK
  4427. @retval S_FALSE if there is no header, [out] values are NULL and 0 respectively
  4428. */
  4429. [propget] HRESULT columnHeaderCells
  4430. (
  4431. [out, size_is(,*nColumnHeaderCells)] IUnknown ***cellAccessibles,
  4432. [out, retval] long *nColumnHeaderCells
  4433. );
  4434. /** @brief Translates this cell accessible into the corresponding column index.
  4435. @param [out] columnIndex
  4436. Returns the 0 based column index of the cell of the specified cell or the index of
  4437. the first column if the cell spans multiple columns.
  4438. @retval S_OK
  4439. */
  4440. [propget] HRESULT columnIndex
  4441. (
  4442. [out, retval] long *columnIndex
  4443. );
  4444. /** @brief Returns the number of rows occupied by this cell accessible.
  4445. @param [out] nRowsSpanned
  4446. Returns the row extent of the specified cell.
  4447. @retval S_OK
  4448. */
  4449. [propget] HRESULT rowExtent
  4450. (
  4451. [out, retval] long *nRowsSpanned
  4452. );
  4453. /** @brief Returns the row headers as an array of cell accessibles.
  4454. @param [out] cellAccessibles
  4455. Pointer to an array of references to cell accessibles. The array is allocated
  4456. by the server. The client must free it with CoTaskMemFree.
  4457. @param [out] nRowHeaderCells
  4458. The number of accessibles returned; the size of the returned array.
  4459. @retval S_OK
  4460. @retval S_FALSE if there is no header, [out] values are NULL and 0 respectively
  4461. */
  4462. [propget] HRESULT rowHeaderCells
  4463. (
  4464. [out, size_is(,*nRowHeaderCells)] IUnknown ***cellAccessibles,
  4465. [out, retval] long *nRowHeaderCells
  4466. );
  4467. /** @brief Translates this cell accessible into the corresponding row index.
  4468. @param [out] rowIndex
  4469. Returns the 0 based row index of the specified cell or the index of
  4470. the first row if the cell spans multiple rows.
  4471. @retval S_OK
  4472. */
  4473. [propget] HRESULT rowIndex
  4474. (
  4475. [out, retval] long *rowIndex
  4476. );
  4477. /** @brief Returns a boolean value indicating whether this cell is selected.
  4478. @param [out] isSelected
  4479. Returns TRUE if the specified cell is selected and FALSE otherwise.
  4480. @retval S_OK
  4481. */
  4482. [propget] HRESULT isSelected
  4483. (
  4484. [out, retval] boolean *isSelected
  4485. );
  4486. /** @brief Gets the row and column indexes and extents of this cell accessible
  4487. and whether or not it is selected.
  4488. This is a convenience function. It is not mandatory to implement it.
  4489. @param [out] row
  4490. 0 based row index.
  4491. @param [out] column
  4492. 0 based column index.
  4493. @param [out] rowExtents
  4494. Number of cells spanned by this cell in this row.
  4495. @param [out] columnExtents
  4496. Number of cells spanned by this cell in this column.
  4497. @param [out] isSelected
  4498. Indicates if the specified cell is selected.
  4499. @retval S_OK
  4500. */
  4501. [propget] HRESULT rowColumnExtents
  4502. (
  4503. [out] long *row,
  4504. [out] long *column,
  4505. [out] long *rowExtents,
  4506. [out] long *columnExtents,
  4507. [out, retval] boolean *isSelected
  4508. );
  4509. /** @brief Returns a reference to the accessbile of the containing table.
  4510. @param [out] table
  4511. Returns a reference to the IUnknown of the containing table.
  4512. @retval S_OK
  4513. */
  4514. [propget] HRESULT table
  4515. (
  4516. [out, retval] IUnknown **table
  4517. );
  4518. }
  4519. /*************************************************************************
  4520. *
  4521. * File Name (AccessibleImage.idl)
  4522. *
  4523. * IAccessible2 IDL Specification
  4524. *
  4525. * Copyright (c) 2007, 2010 Linux Foundation
  4526. * Copyright (c) 2006 IBM Corporation
  4527. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  4528. * All rights reserved.
  4529. *
  4530. *
  4531. * Redistribution and use in source and binary forms, with or without
  4532. * modification, are permitted provided that the following conditions
  4533. * are met:
  4534. *
  4535. * 1. Redistributions of source code must retain the above copyright
  4536. * notice, this list of conditions and the following disclaimer.
  4537. *
  4538. * 2. Redistributions in binary form must reproduce the above
  4539. * copyright notice, this list of conditions and the following
  4540. * disclaimer in the documentation and/or other materials
  4541. * provided with the distribution.
  4542. *
  4543. * 3. Neither the name of the Linux Foundation nor the names of its
  4544. * contributors may be used to endorse or promote products
  4545. * derived from this software without specific prior written
  4546. * permission.
  4547. *
  4548. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  4549. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  4550. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  4551. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  4552. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  4553. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  4554. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  4555. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  4556. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  4557. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  4558. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  4559. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  4560. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  4561. *
  4562. * This BSD License conforms to the Open Source Initiative "Simplified
  4563. * BSD License" as published at:
  4564. * http://www.opensource.org/licenses/bsd-license.php
  4565. *
  4566. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  4567. * mark may be used in accordance with the Linux Foundation Trademark
  4568. * Policy to indicate compliance with the IAccessible2 specification.
  4569. *
  4570. ************************************************************************/
  4571. /** @brief This interface represents images and icons.
  4572. This interface is used for a representation of images like icons on buttons.
  4573. %IAccessibleImage only needs to be implemented in certain situations. Some
  4574. examples are:
  4575. <ol>
  4576. <li>The accessible name and description are not enough to fully
  4577. describe the image, e.g. when the accessible description is used to define the
  4578. behavior of an actionable image and the image itself conveys semantically
  4579. significant information.
  4580. <li>The user can edit the content that includes an
  4581. image and therefore the user needs to be able to review the image's position.
  4582. </ol>
  4583. */
  4584. [object, uuid(FE5ABB3D-615E-4f7b-909F-5F0EDA9E8DDE)]
  4585. interface IAccessibleImage : IUnknown
  4586. {
  4587. /** @brief Returns the localized description of the image.
  4588. @param [out] description
  4589. @retval S_OK
  4590. @retval S_FALSE if there is nothing to return, [out] value is NULL
  4591. */
  4592. [propget] HRESULT description
  4593. (
  4594. [out, retval] BSTR *description
  4595. );
  4596. /** @brief Returns the coordinates of the image.
  4597. @param [in] coordinateType
  4598. Specifies whether the returned coordinates should be relative to the screen or the parent object.
  4599. @param [out] x
  4600. @param [out] y
  4601. @retval S_OK
  4602. */
  4603. [propget] HRESULT imagePosition
  4604. (
  4605. [in] enum IA2CoordinateType coordinateType,
  4606. [out] long *x,
  4607. [out, retval] long *y
  4608. );
  4609. /** @brief Returns the size of the image in units specified by parent's coordinate system.
  4610. @param [out] height
  4611. @param [out] width
  4612. @retval S_OK
  4613. */
  4614. [propget] HRESULT imageSize
  4615. (
  4616. [out] long *height,
  4617. [out, retval] long *width
  4618. );
  4619. }
  4620. /*************************************************************************
  4621. *
  4622. * File Name (AccessibleEventID.idl)
  4623. *
  4624. * IAccessible2 IDL Specification
  4625. *
  4626. * Copyright (c) 2007, 2010 Linux Foundation
  4627. * Copyright (c) 2006 IBM Corporation
  4628. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  4629. * All rights reserved.
  4630. *
  4631. *
  4632. * Redistribution and use in source and binary forms, with or without
  4633. * modification, are permitted provided that the following conditions
  4634. * are met:
  4635. *
  4636. * 1. Redistributions of source code must retain the above copyright
  4637. * notice, this list of conditions and the following disclaimer.
  4638. *
  4639. * 2. Redistributions in binary form must reproduce the above
  4640. * copyright notice, this list of conditions and the following
  4641. * disclaimer in the documentation and/or other materials
  4642. * provided with the distribution.
  4643. *
  4644. * 3. Neither the name of the Linux Foundation nor the names of its
  4645. * contributors may be used to endorse or promote products
  4646. * derived from this software without specific prior written
  4647. * permission.
  4648. *
  4649. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  4650. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  4651. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  4652. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  4653. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  4654. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  4655. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  4656. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  4657. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  4658. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  4659. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  4660. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  4661. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  4662. *
  4663. * This BSD License conforms to the Open Source Initiative "Simplified
  4664. * BSD License" as published at:
  4665. * http://www.opensource.org/licenses/bsd-license.php
  4666. *
  4667. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  4668. * mark may be used in accordance with the Linux Foundation Trademark
  4669. * Policy to indicate compliance with the IAccessible2 specification.
  4670. *
  4671. ************************************************************************/
  4672. /** %IAccessible2 specific event constants
  4673. This enum defines the event IDs fired by %IAccessible2 objects. The event IDs
  4674. are in addition to those used by MSAA.
  4675. */
  4676. enum IA2EventID {
  4677. /** The change of the number or attributes of actions of an accessible
  4678. object is signaled by events of this type.
  4679. */
  4680. IA2_EVENT_ACTION_CHANGED = 0x101,
  4681. /** <b>Deprecated.</b> The active descendant of a component has changed.
  4682. Note: This event constant is misspelled and thus is deprecated and will be
  4683. removed in a later version. Please use the correctly spelled version which
  4684. follows.
  4685. */
  4686. IA2_EVENT_ACTIVE_DECENDENT_CHANGED,
  4687. /** The active descendant of a component has changed. The active descendant
  4688. is used in objects with transient children.
  4689. Note: Due to the fact that MSAA's WinEvents don't allow the active child index
  4690. to be passed on the IA2_EVENT_ACTIVE_DESCENDANT_CHANGED event the manages
  4691. descendants scheme can't be used. Instead the active child object has to fire
  4692. MSAA's EVENT_OBJECT_FOCUS. In a future release a new event mechanism may be
  4693. added to provide for event specific data to be passed with the event. At that
  4694. time the IA2_EVENT_ACTIVE_DECENDENT_CHANGED event and
  4695. IA2_STATE_MANAGES_DESCENDANTS state would be useful.
  4696. */
  4697. IA2_EVENT_ACTIVE_DESCENDANT_CHANGED = IA2_EVENT_ACTIVE_DECENDENT_CHANGED,
  4698. /** The document wide attributes of the document object have changed.
  4699. */
  4700. IA2_EVENT_DOCUMENT_ATTRIBUTE_CHANGED,
  4701. /** The contents of the document have changed.
  4702. */
  4703. IA2_EVENT_DOCUMENT_CONTENT_CHANGED,
  4704. /** The loading of the document has completed.
  4705. */
  4706. IA2_EVENT_DOCUMENT_LOAD_COMPLETE,
  4707. /** The loading of the document was interrupted.
  4708. */
  4709. IA2_EVENT_DOCUMENT_LOAD_STOPPED,
  4710. /** The document contents are being reloaded.
  4711. */
  4712. IA2_EVENT_DOCUMENT_RELOAD,
  4713. /** The ending index of this link within the containing string has changed.
  4714. */
  4715. IA2_EVENT_HYPERLINK_END_INDEX_CHANGED,
  4716. /** The number of anchors associated with this hyperlink object has changed.
  4717. */
  4718. IA2_EVENT_HYPERLINK_NUMBER_OF_ANCHORS_CHANGED,
  4719. /** The hyperlink selected state changed from selected to unselected or
  4720. from unselected to selected.
  4721. */
  4722. IA2_EVENT_HYPERLINK_SELECTED_LINK_CHANGED,
  4723. /** One of the links associated with the hypertext object has been activated.
  4724. */
  4725. IA2_EVENT_HYPERTEXT_LINK_ACTIVATED,
  4726. /** One of the links associated with the hypertext object has been selected.
  4727. */
  4728. IA2_EVENT_HYPERTEXT_LINK_SELECTED,
  4729. /** The starting index of this link within the containing string has changed.
  4730. */
  4731. IA2_EVENT_HYPERLINK_START_INDEX_CHANGED,
  4732. /** Focus has changed from one hypertext object to another, or focus moved
  4733. from a non-hypertext object to a hypertext object, or focus moved from a
  4734. hypertext object to a non-hypertext object.
  4735. */
  4736. IA2_EVENT_HYPERTEXT_CHANGED,
  4737. /** The number of hyperlinks associated with a hypertext object changed
  4738. */
  4739. IA2_EVENT_HYPERTEXT_NLINKS_CHANGED,
  4740. /** An object's attributes changed.
  4741. Also see ::IA2_EVENT_TEXT_ATTRIBUTE_CHANGED.
  4742. */
  4743. IA2_EVENT_OBJECT_ATTRIBUTE_CHANGED,
  4744. /** A slide changed in a presentation document or a page boundary was
  4745. crossed in a word processing document.
  4746. */
  4747. IA2_EVENT_PAGE_CHANGED,
  4748. /** The caret moved from one section to the next.
  4749. */
  4750. IA2_EVENT_SECTION_CHANGED,
  4751. /** A table caption changed.
  4752. */
  4753. IA2_EVENT_TABLE_CAPTION_CHANGED,
  4754. /** A table's column description changed.
  4755. */
  4756. IA2_EVENT_TABLE_COLUMN_DESCRIPTION_CHANGED,
  4757. /** A table's column header changed.
  4758. */
  4759. IA2_EVENT_TABLE_COLUMN_HEADER_CHANGED,
  4760. /** A table's data changed.
  4761. */
  4762. IA2_EVENT_TABLE_MODEL_CHANGED,
  4763. /** A table's row description changed.
  4764. */
  4765. IA2_EVENT_TABLE_ROW_DESCRIPTION_CHANGED,
  4766. /** A table's row header changed.
  4767. */
  4768. IA2_EVENT_TABLE_ROW_HEADER_CHANGED,
  4769. /** A table's summary changed.
  4770. */
  4771. IA2_EVENT_TABLE_SUMMARY_CHANGED,
  4772. /** A text object's attributes changed.
  4773. Also see ::IA2_EVENT_OBJECT_ATTRIBUTE_CHANGED.
  4774. */
  4775. IA2_EVENT_TEXT_ATTRIBUTE_CHANGED,
  4776. /** The caret has moved to a new position.
  4777. */
  4778. IA2_EVENT_TEXT_CARET_MOVED,
  4779. /** <b>Deprecated.</b> This event is equivalent to ::IA2_EVENT_TEXT_UPDATED.
  4780. */
  4781. IA2_EVENT_TEXT_CHANGED,
  4782. /** The caret moved from one column to the next.
  4783. */
  4784. IA2_EVENT_TEXT_COLUMN_CHANGED,
  4785. /** Text was inserted.
  4786. */
  4787. IA2_EVENT_TEXT_INSERTED,
  4788. /** Text was removed.
  4789. */
  4790. IA2_EVENT_TEXT_REMOVED,
  4791. /** This event indicates general text changes, i.e. changes to text that are
  4792. exposed through the IAccessibleText interface. For compatibility with ATK/AT-SPI
  4793. which does not have an equivalent event, servers can alternatively fire
  4794. ::IA2_EVENT_TEXT_REMOVED and ::IA2_EVENT_TEXT_INSERTED.
  4795. */
  4796. IA2_EVENT_TEXT_UPDATED,
  4797. /** The text selection changed. Later versions of Microsoft development environments
  4798. have an equivalent event identified, EVENT_OBJECT_TEXTSELECTIONCHANGED. Servers
  4799. should use that if it is available and use IA2_EVENT_TEXT_SELECTION_CHANGED otherwise.
  4800. Clients should be prepared to respond to either event.
  4801. */
  4802. IA2_EVENT_TEXT_SELECTION_CHANGED,
  4803. /** A visible data event indicates the change of the visual appearance
  4804. of an accessible object. This includes for example most of the
  4805. attributes available via the IAccessibleComponent interface.
  4806. */
  4807. IA2_EVENT_VISIBLE_DATA_CHANGED,
  4808. /** The role changed. This should only be used if the interfaces supported by the object
  4809. did not also change. If the interfaces need to change, the object should be destroyed
  4810. and a new object created.
  4811. */
  4812. IA2_EVENT_ROLE_CHANGED
  4813. };
  4814. /*************************************************************************
  4815. *
  4816. * File Name (AccessibleApplication.idl)
  4817. *
  4818. * IAccessible2 IDL Specification
  4819. *
  4820. * Copyright (c) 2007, 2010 Linux Foundation
  4821. * Copyright (c) 2006 IBM Corporation
  4822. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  4823. * All rights reserved.
  4824. *
  4825. *
  4826. * Redistribution and use in source and binary forms, with or without
  4827. * modification, are permitted provided that the following conditions
  4828. * are met:
  4829. *
  4830. * 1. Redistributions of source code must retain the above copyright
  4831. * notice, this list of conditions and the following disclaimer.
  4832. *
  4833. * 2. Redistributions in binary form must reproduce the above
  4834. * copyright notice, this list of conditions and the following
  4835. * disclaimer in the documentation and/or other materials
  4836. * provided with the distribution.
  4837. *
  4838. * 3. Neither the name of the Linux Foundation nor the names of its
  4839. * contributors may be used to endorse or promote products
  4840. * derived from this software without specific prior written
  4841. * permission.
  4842. *
  4843. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  4844. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  4845. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  4846. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  4847. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  4848. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  4849. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  4850. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  4851. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  4852. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  4853. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  4854. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  4855. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  4856. *
  4857. * This BSD License conforms to the Open Source Initiative "Simplified
  4858. * BSD License" as published at:
  4859. * http://www.opensource.org/licenses/bsd-license.php
  4860. *
  4861. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  4862. * mark may be used in accordance with the Linux Foundation Trademark
  4863. * Policy to indicate compliance with the IAccessible2 specification.
  4864. *
  4865. ************************************************************************/
  4866. /** @brief This interface gives access to the application's name and version information.
  4867. This interface provides the AT with the information it needs to differentiate
  4868. this application from other applications, from other versions of this
  4869. application, or from other versions of this application running on different
  4870. versions of an accessibility bridge or accessibility toolkit.
  4871. Servers implementing IAccessible2 should provide access to the %IAccessibleApplication
  4872. interface via QueryService from any object so that ATs can easily determine specific
  4873. information about the application such as its name or version.
  4874. */
  4875. [object, uuid(D49DED83-5B25-43F4-9B95-93B44595979E)]
  4876. interface IAccessibleApplication : IUnknown
  4877. {
  4878. /** @brief Returns the application name.
  4879. @param [out] name
  4880. @retval S_OK
  4881. @retval S_FALSE if there is nothing to return, [out] value is NULL
  4882. */
  4883. [propget] HRESULT appName
  4884. (
  4885. [out, retval] BSTR *name
  4886. );
  4887. /** @brief Returns the application version.
  4888. @param [out] version
  4889. The version string must not contain levels when it is know beforehand that
  4890. this information will never require a change in a client's behavior.
  4891. For example, use "3.6.0" rather than "3.6.0.v201005131500".
  4892. @retval S_OK
  4893. @retval S_FALSE if there is nothing to return, [out] value is NULL
  4894. */
  4895. [propget] HRESULT appVersion
  4896. (
  4897. [out, retval] BSTR *version
  4898. );
  4899. /** @brief Returns the toolkit/bridge name.
  4900. @param [out] name
  4901. @retval S_OK
  4902. @retval S_FALSE if there is nothing to return, [out] value is NULL
  4903. */
  4904. [propget] HRESULT toolkitName
  4905. (
  4906. [out, retval] BSTR *name
  4907. );
  4908. /** @brief Returns the toolkit/bridge version.
  4909. @param [out] version
  4910. The version string must not contain levels when it is know beforehand that
  4911. this information will never require a change in a client's behavior.
  4912. For example, use "3.6.0" rather than "3.6.0.v201005131500".
  4913. @retval S_OK
  4914. @retval S_FALSE if there is nothing to return, [out] value is NULL
  4915. */
  4916. [propget] HRESULT toolkitVersion
  4917. (
  4918. [out, retval] BSTR *version
  4919. );
  4920. }
  4921. /*************************************************************************
  4922. *
  4923. * File Name (AccessibleDocument.idl)
  4924. *
  4925. * IAccessible2 IDL Specification
  4926. *
  4927. * Copyright (c) 2013 Linux Foundation
  4928. * All rights reserved.
  4929. *
  4930. *
  4931. * Redistribution and use in source and binary forms, with or without
  4932. * modification, are permitted provided that the following conditions
  4933. * are met:
  4934. *
  4935. * 1. Redistributions of source code must retain the above copyright
  4936. * notice, this list of conditions and the following disclaimer.
  4937. *
  4938. * 2. Redistributions in binary form must reproduce the above
  4939. * copyright notice, this list of conditions and the following
  4940. * disclaimer in the documentation and/or other materials
  4941. * provided with the distribution.
  4942. *
  4943. * 3. Neither the name of the Linux Foundation nor the names of its
  4944. * contributors may be used to endorse or promote products
  4945. * derived from this software without specific prior written
  4946. * permission.
  4947. *
  4948. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  4949. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  4950. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  4951. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  4952. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  4953. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  4954. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  4955. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  4956. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  4957. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  4958. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  4959. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  4960. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  4961. *
  4962. * This BSD License conforms to the Open Source Initiative "Simplified
  4963. * BSD License" as published at:
  4964. * http://www.opensource.org/licenses/bsd-license.php
  4965. *
  4966. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  4967. * mark may be used in accordance with the Linux Foundation Trademark
  4968. * Policy to indicate compliance with the IAccessible2 specification.
  4969. *
  4970. ************************************************************************/
  4971. /** @brief This interface represents documents.
  4972. This interface is used for a representation of documents.
  4973. */
  4974. [object, uuid(C48C7FCF-4AB5-4056-AFA6-902D6E1D1149)]
  4975. interface IAccessibleDocument : IUnknown
  4976. {
  4977. /** @brief Returns the most recently used anchor target within a document.
  4978. A document's most recently targeted in-page anchor is returned. A typical use
  4979. of this method is to fetch the anchor target within an HTML document. In this
  4980. case anchor targets are those which has been defined with the <a> tag.
  4981. @param [out] accessible
  4982. @retval S_OK
  4983. @retval S_FALSE if there are no existing valid anchor targets, [out] value is NULL.
  4984. */
  4985. [propget] HRESULT anchorTarget
  4986. (
  4987. [out, retval] IUnknown **accessible
  4988. );
  4989. }
  4990. /*************************************************************************
  4991. *
  4992. * File Name (IA2TypeLibrary.idl)
  4993. *
  4994. * IAccessible2 IDL Specification
  4995. *
  4996. * Copyright (c) 2007, 2012 Linux Foundation
  4997. * Copyright (c) 2006 IBM Corporation
  4998. * Copyright (c) 2000, 2006 Sun Microsystems, Inc.
  4999. * All rights reserved.
  5000. *
  5001. *
  5002. * Redistribution and use in source and binary forms, with or without
  5003. * modification, are permitted provided that the following conditions
  5004. * are met:
  5005. *
  5006. * 1. Redistributions of source code must retain the above copyright
  5007. * notice, this list of conditions and the following disclaimer.
  5008. *
  5009. * 2. Redistributions in binary form must reproduce the above
  5010. * copyright notice, this list of conditions and the following
  5011. * disclaimer in the documentation and/or other materials
  5012. * provided with the distribution.
  5013. *
  5014. * 3. Neither the name of the Linux Foundation nor the names of its
  5015. * contributors may be used to endorse or promote products
  5016. * derived from this software without specific prior written
  5017. * permission.
  5018. *
  5019. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
  5020. * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
  5021. * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  5022. * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  5023. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
  5024. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  5025. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  5026. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  5027. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  5028. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  5029. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  5030. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  5031. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  5032. *
  5033. * This BSD License conforms to the Open Source Initiative "Simplified
  5034. * BSD License" as published at:
  5035. * http://www.opensource.org/licenses/bsd-license.php
  5036. *
  5037. * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2
  5038. * mark may be used in accordance with the Linux Foundation Trademark
  5039. * Policy to indicate compliance with the IAccessible2 specification.
  5040. *
  5041. ************************************************************************/
  5042. // This is not a standalone file. It is to be appended to the end of the
  5043. // merged IDL file.
  5044. cpp_quote("")
  5045. cpp_quote("// Type Library Definitions")
  5046. cpp_quote("")
  5047. [
  5048. uuid(CE3F726E-D1D3-44FE-B995-FF1DB3B48B2B),
  5049. helpstring("IAccessible2 Type Library"),
  5050. version(1.3),
  5051. hidden
  5052. ]
  5053. library IAccessible2Lib
  5054. {
  5055. importlib ("stdole2.tlb");
  5056. importlib ("oleacc.dll");
  5057. interface IAccessible2;
  5058. interface IAccessible2_2;
  5059. interface IAccessible2_3;
  5060. interface IAccessibleAction;
  5061. interface IAccessibleApplication;
  5062. interface IAccessibleComponent;
  5063. interface IAccessibleDocument;
  5064. interface IAccessibleEditableText;
  5065. interface IAccessibleHyperlink;
  5066. interface IAccessibleHypertext;
  5067. interface IAccessibleHypertext2;
  5068. interface IAccessibleImage;
  5069. interface IAccessibleRelation;
  5070. interface IAccessibleTable;
  5071. interface IAccessibleTable2;
  5072. interface IAccessibleTableCell;
  5073. interface IAccessibleText;
  5074. interface IAccessibleText2;
  5075. interface IAccessibleTextSelectionContainer;
  5076. interface IAccessibleValue;
  5077. enum IA2CoordinateType;
  5078. enum IA2EventID;
  5079. enum IA2Role;
  5080. enum IA2ScrollType;
  5081. enum IA2States;
  5082. enum IA2TableModelChangeType;
  5083. enum IA2TextBoundaryType;
  5084. enum IA2TextSpecialOffsets;
  5085. }