1
0

x11parse.inc 336 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868386938703871387238733874387538763877387838793880388138823883388438853886388738883889389038913892389338943895389638973898389939003901390239033904390539063907390839093910391139123913391439153916391739183919392039213922392339243925392639273928392939303931393239333934393539363937393839393940394139423943394439453946394739483949395039513952395339543955395639573958395939603961396239633964396539663967396839693970397139723973397439753976397739783979398039813982398339843985398639873988398939903991399239933994399539963997399839994000400140024003400440054006400740084009401040114012401340144015401640174018401940204021402240234024402540264027402840294030403140324033403440354036403740384039404040414042404340444045404640474048404940504051405240534054405540564057405840594060406140624063406440654066406740684069407040714072407340744075407640774078407940804081408240834084408540864087408840894090409140924093409440954096409740984099410041014102410341044105410641074108410941104111411241134114411541164117411841194120412141224123412441254126412741284129413041314132413341344135413641374138413941404141414241434144414541464147414841494150415141524153415441554156415741584159416041614162416341644165416641674168416941704171417241734174417541764177417841794180418141824183418441854186418741884189419041914192419341944195419641974198419942004201420242034204420542064207420842094210421142124213421442154216421742184219422042214222422342244225422642274228422942304231423242334234423542364237423842394240424142424243424442454246424742484249425042514252425342544255425642574258425942604261426242634264426542664267426842694270427142724273427442754276427742784279428042814282428342844285428642874288428942904291429242934294429542964297429842994300430143024303430443054306430743084309431043114312431343144315431643174318431943204321432243234324432543264327432843294330433143324333433443354336433743384339434043414342434343444345434643474348434943504351435243534354435543564357435843594360436143624363436443654366436743684369437043714372437343744375437643774378437943804381438243834384438543864387438843894390439143924393439443954396439743984399440044014402440344044405440644074408440944104411441244134414441544164417441844194420442144224423442444254426442744284429443044314432443344344435443644374438443944404441444244434444444544464447444844494450445144524453445444554456445744584459446044614462446344644465446644674468446944704471447244734474447544764477447844794480448144824483448444854486448744884489449044914492449344944495449644974498449945004501450245034504450545064507450845094510451145124513451445154516451745184519452045214522452345244525452645274528452945304531453245334534453545364537453845394540454145424543454445454546454745484549455045514552455345544555455645574558455945604561456245634564456545664567456845694570457145724573457445754576457745784579458045814582458345844585458645874588458945904591459245934594459545964597459845994600460146024603460446054606460746084609461046114612461346144615461646174618461946204621462246234624462546264627462846294630463146324633463446354636463746384639464046414642464346444645464646474648464946504651465246534654465546564657465846594660466146624663466446654666466746684669467046714672467346744675467646774678467946804681468246834684468546864687468846894690469146924693469446954696469746984699470047014702470347044705470647074708470947104711471247134714471547164717471847194720472147224723472447254726472747284729473047314732473347344735473647374738473947404741474247434744474547464747474847494750475147524753475447554756475747584759476047614762476347644765476647674768476947704771477247734774477547764777477847794780478147824783478447854786478747884789479047914792479347944795479647974798479948004801480248034804480548064807480848094810481148124813481448154816481748184819482048214822482348244825482648274828482948304831483248334834483548364837483848394840484148424843484448454846484748484849485048514852485348544855485648574858485948604861486248634864486548664867486848694870487148724873487448754876487748784879488048814882488348844885488648874888488948904891489248934894489548964897489848994900490149024903490449054906490749084909491049114912491349144915491649174918491949204921492249234924492549264927492849294930493149324933493449354936493749384939494049414942494349444945494649474948494949504951495249534954495549564957495849594960496149624963496449654966496749684969497049714972497349744975497649774978497949804981498249834984498549864987498849894990499149924993499449954996499749984999500050015002500350045005500650075008500950105011501250135014501550165017501850195020502150225023502450255026502750285029503050315032503350345035503650375038503950405041504250435044504550465047504850495050505150525053505450555056505750585059506050615062506350645065506650675068506950705071507250735074507550765077507850795080508150825083508450855086508750885089509050915092509350945095509650975098509951005101510251035104510551065107510851095110511151125113511451155116511751185119512051215122512351245125512651275128512951305131513251335134513551365137513851395140514151425143514451455146514751485149515051515152515351545155515651575158515951605161516251635164516551665167516851695170517151725173517451755176517751785179518051815182518351845185518651875188518951905191519251935194519551965197519851995200520152025203520452055206520752085209521052115212521352145215521652175218521952205221522252235224522552265227522852295230523152325233523452355236523752385239524052415242524352445245524652475248524952505251525252535254525552565257525852595260526152625263526452655266526752685269527052715272527352745275527652775278527952805281528252835284528552865287528852895290529152925293529452955296529752985299530053015302530353045305530653075308530953105311531253135314531553165317531853195320532153225323532453255326532753285329533053315332533353345335533653375338533953405341534253435344534553465347534853495350535153525353535453555356535753585359536053615362536353645365536653675368536953705371537253735374537553765377537853795380538153825383538453855386538753885389539053915392539353945395539653975398539954005401540254035404540554065407540854095410541154125413541454155416541754185419542054215422542354245425542654275428542954305431543254335434543554365437543854395440544154425443544454455446544754485449545054515452545354545455545654575458545954605461546254635464546554665467546854695470547154725473547454755476547754785479548054815482548354845485548654875488548954905491549254935494549554965497549854995500550155025503550455055506550755085509551055115512551355145515551655175518551955205521552255235524552555265527552855295530553155325533553455355536553755385539554055415542554355445545554655475548554955505551555255535554555555565557555855595560556155625563556455655566556755685569557055715572557355745575557655775578557955805581558255835584558555865587558855895590559155925593559455955596559755985599560056015602560356045605560656075608560956105611561256135614561556165617561856195620562156225623562456255626562756285629563056315632563356345635563656375638563956405641564256435644564556465647564856495650565156525653565456555656565756585659566056615662566356645665566656675668566956705671567256735674567556765677567856795680568156825683568456855686568756885689569056915692569356945695569656975698569957005701570257035704570557065707570857095710571157125713571457155716571757185719572057215722572357245725572657275728572957305731573257335734573557365737573857395740574157425743574457455746574757485749575057515752575357545755575657575758575957605761576257635764576557665767576857695770577157725773577457755776577757785779578057815782578357845785578657875788578957905791579257935794579557965797579857995800580158025803580458055806580758085809581058115812581358145815581658175818581958205821582258235824582558265827582858295830583158325833583458355836583758385839584058415842584358445845584658475848584958505851585258535854585558565857585858595860586158625863586458655866586758685869587058715872587358745875587658775878587958805881588258835884588558865887588858895890589158925893589458955896589758985899590059015902590359045905590659075908590959105911591259135914591559165917591859195920592159225923592459255926592759285929593059315932593359345935593659375938593959405941594259435944594559465947594859495950595159525953595459555956595759585959596059615962596359645965596659675968596959705971597259735974597559765977597859795980598159825983598459855986598759885989599059915992599359945995599659975998599960006001600260036004600560066007600860096010601160126013601460156016601760186019602060216022602360246025602660276028602960306031603260336034603560366037603860396040604160426043604460456046604760486049605060516052605360546055605660576058605960606061606260636064606560666067606860696070607160726073607460756076607760786079608060816082608360846085608660876088608960906091609260936094609560966097609860996100610161026103610461056106610761086109611061116112611361146115611661176118611961206121612261236124612561266127612861296130613161326133613461356136613761386139614061416142614361446145614661476148614961506151615261536154615561566157615861596160616161626163616461656166616761686169617061716172617361746175617661776178617961806181618261836184618561866187618861896190619161926193619461956196619761986199620062016202620362046205620662076208620962106211621262136214621562166217621862196220622162226223622462256226622762286229623062316232623362346235623662376238623962406241624262436244624562466247624862496250625162526253625462556256625762586259626062616262626362646265626662676268626962706271627262736274627562766277627862796280628162826283628462856286628762886289629062916292629362946295629662976298629963006301630263036304630563066307630863096310631163126313631463156316631763186319632063216322632363246325632663276328632963306331633263336334633563366337633863396340634163426343634463456346634763486349635063516352635363546355635663576358635963606361636263636364636563666367636863696370637163726373637463756376637763786379638063816382638363846385638663876388638963906391639263936394639563966397639863996400640164026403640464056406640764086409641064116412641364146415641664176418641964206421642264236424642564266427642864296430643164326433643464356436643764386439644064416442644364446445644664476448644964506451645264536454645564566457645864596460646164626463646464656466646764686469647064716472647364746475647664776478647964806481648264836484648564866487648864896490649164926493649464956496649764986499650065016502650365046505650665076508650965106511651265136514651565166517651865196520652165226523652465256526652765286529653065316532653365346535653665376538653965406541654265436544654565466547654865496550655165526553655465556556655765586559656065616562656365646565656665676568656965706571657265736574657565766577657865796580658165826583658465856586658765886589659065916592659365946595659665976598659966006601660266036604660566066607660866096610661166126613661466156616661766186619662066216622662366246625662666276628662966306631663266336634663566366637663866396640664166426643664466456646664766486649665066516652665366546655665666576658665966606661666266636664666566666667666866696670667166726673667466756676667766786679668066816682668366846685668666876688668966906691669266936694669566966697669866996700670167026703670467056706670767086709671067116712671367146715671667176718671967206721672267236724672567266727672867296730673167326733673467356736673767386739674067416742674367446745674667476748674967506751675267536754675567566757675867596760676167626763676467656766676767686769677067716772677367746775677667776778677967806781678267836784678567866787678867896790679167926793679467956796679767986799680068016802680368046805680668076808680968106811681268136814681568166817681868196820682168226823682468256826682768286829683068316832683368346835683668376838683968406841684268436844684568466847684868496850685168526853685468556856685768586859686068616862686368646865686668676868686968706871687268736874687568766877687868796880688168826883688468856886688768886889689068916892689368946895689668976898689969006901690269036904690569066907690869096910691169126913691469156916691769186919692069216922692369246925692669276928692969306931693269336934693569366937693869396940694169426943694469456946694769486949695069516952695369546955695669576958695969606961696269636964696569666967696869696970697169726973697469756976697769786979698069816982698369846985698669876988698969906991699269936994699569966997699869997000700170027003700470057006700770087009701070117012701370147015701670177018701970207021702270237024702570267027702870297030703170327033703470357036703770387039704070417042704370447045704670477048704970507051705270537054705570567057705870597060706170627063706470657066706770687069707070717072707370747075707670777078707970807081708270837084708570867087708870897090709170927093709470957096709770987099710071017102710371047105710671077108710971107111711271137114711571167117711871197120712171227123712471257126712771287129713071317132713371347135713671377138713971407141714271437144714571467147714871497150715171527153715471557156715771587159716071617162716371647165716671677168716971707171717271737174717571767177717871797180718171827183718471857186718771887189719071917192719371947195719671977198719972007201720272037204720572067207720872097210721172127213721472157216721772187219722072217222722372247225722672277228722972307231723272337234723572367237723872397240724172427243724472457246724772487249725072517252725372547255725672577258725972607261726272637264726572667267726872697270727172727273727472757276727772787279728072817282728372847285728672877288728972907291729272937294729572967297729872997300730173027303730473057306730773087309731073117312731373147315731673177318731973207321732273237324732573267327732873297330733173327333733473357336733773387339734073417342734373447345734673477348734973507351735273537354735573567357735873597360736173627363736473657366736773687369737073717372737373747375737673777378737973807381738273837384738573867387738873897390739173927393739473957396739773987399740074017402740374047405740674077408740974107411741274137414741574167417741874197420742174227423742474257426742774287429743074317432743374347435743674377438743974407441744274437444744574467447744874497450745174527453745474557456745774587459746074617462746374647465746674677468746974707471747274737474747574767477747874797480748174827483748474857486748774887489749074917492749374947495749674977498749975007501750275037504750575067507750875097510751175127513751475157516751775187519752075217522752375247525752675277528752975307531753275337534753575367537753875397540754175427543754475457546754775487549755075517552755375547555755675577558755975607561756275637564756575667567756875697570757175727573757475757576757775787579758075817582758375847585758675877588758975907591759275937594759575967597759875997600760176027603760476057606760776087609761076117612761376147615761676177618761976207621762276237624762576267627762876297630763176327633763476357636763776387639764076417642764376447645764676477648764976507651765276537654765576567657765876597660766176627663766476657666766776687669767076717672767376747675767676777678767976807681768276837684768576867687768876897690769176927693769476957696769776987699770077017702770377047705770677077708770977107711771277137714771577167717771877197720772177227723772477257726772777287729773077317732773377347735773677377738773977407741774277437744774577467747774877497750775177527753775477557756775777587759776077617762776377647765776677677768776977707771777277737774777577767777777877797780778177827783778477857786778777887789779077917792779377947795779677977798779978007801780278037804780578067807780878097810781178127813781478157816781778187819782078217822782378247825782678277828782978307831783278337834783578367837783878397840784178427843784478457846784778487849785078517852785378547855785678577858785978607861786278637864786578667867786878697870787178727873787478757876787778787879788078817882788378847885788678877888788978907891789278937894789578967897789878997900790179027903790479057906790779087909791079117912791379147915791679177918791979207921792279237924792579267927792879297930793179327933793479357936793779387939794079417942794379447945794679477948794979507951795279537954795579567957795879597960796179627963796479657966796779687969797079717972797379747975797679777978797979807981798279837984798579867987798879897990799179927993799479957996799779987999800080018002800380048005800680078008800980108011801280138014801580168017801880198020802180228023802480258026802780288029803080318032803380348035803680378038803980408041804280438044804580468047804880498050805180528053805480558056805780588059806080618062806380648065806680678068806980708071807280738074807580768077807880798080808180828083808480858086808780888089809080918092809380948095809680978098809981008101810281038104810581068107810881098110811181128113811481158116811781188119812081218122812381248125812681278128812981308131813281338134813581368137813881398140814181428143814481458146814781488149815081518152815381548155815681578158815981608161816281638164816581668167816881698170817181728173817481758176817781788179818081818182818381848185818681878188818981908191819281938194819581968197819881998200820182028203820482058206820782088209821082118212821382148215821682178218821982208221822282238224822582268227822882298230823182328233823482358236823782388239824082418242824382448245824682478248824982508251825282538254825582568257825882598260826182628263826482658266826782688269827082718272827382748275827682778278827982808281828282838284828582868287828882898290829182928293829482958296829782988299830083018302830383048305830683078308830983108311831283138314831583168317831883198320832183228323832483258326832783288329833083318332833383348335833683378338833983408341834283438344834583468347834883498350835183528353835483558356835783588359836083618362836383648365836683678368836983708371837283738374837583768377837883798380838183828383838483858386838783888389839083918392839383948395839683978398839984008401840284038404840584068407840884098410841184128413841484158416841784188419842084218422842384248425842684278428842984308431843284338434843584368437843884398440844184428443844484458446844784488449845084518452845384548455845684578458845984608461846284638464846584668467846884698470847184728473847484758476847784788479848084818482848384848485848684878488848984908491849284938494849584968497849884998500850185028503850485058506850785088509851085118512851385148515851685178518851985208521852285238524852585268527852885298530853185328533853485358536853785388539854085418542854385448545854685478548854985508551855285538554855585568557855885598560856185628563856485658566856785688569857085718572857385748575857685778578857985808581858285838584858585868587858885898590859185928593859485958596859785988599860086018602860386048605860686078608860986108611861286138614861586168617861886198620862186228623862486258626862786288629863086318632863386348635863686378638863986408641864286438644864586468647864886498650865186528653865486558656865786588659866086618662866386648665866686678668866986708671867286738674867586768677867886798680868186828683868486858686868786888689869086918692869386948695869686978698869987008701870287038704870587068707870887098710871187128713871487158716871787188719872087218722872387248725872687278728872987308731873287338734873587368737873887398740874187428743874487458746874787488749875087518752875387548755875687578758875987608761876287638764876587668767876887698770877187728773877487758776877787788779878087818782878387848785878687878788878987908791879287938794879587968797879887998800880188028803880488058806880788088809881088118812881388148815881688178818881988208821882288238824882588268827882888298830883188328833883488358836883788388839884088418842884388448845884688478848884988508851885288538854885588568857885888598860886188628863886488658866886788688869887088718872887388748875887688778878887988808881888288838884888588868887888888898890889188928893889488958896889788988899890089018902890389048905890689078908890989108911891289138914891589168917891889198920892189228923892489258926892789288929893089318932893389348935893689378938893989408941894289438944894589468947894889498950895189528953895489558956895789588959896089618962896389648965896689678968896989708971897289738974897589768977897889798980898189828983898489858986898789888989899089918992899389948995899689978998899990009001900290039004900590069007900890099010901190129013901490159016901790189019902090219022902390249025902690279028902990309031903290339034903590369037903890399040904190429043904490459046904790489049905090519052905390549055905690579058905990609061906290639064906590669067906890699070907190729073907490759076907790789079908090819082908390849085908690879088908990909091909290939094909590969097909890999100910191029103910491059106910791089109911091119112911391149115911691179118911991209121912291239124912591269127912891299130913191329133913491359136913791389139914091419142914391449145914691479148914991509151915291539154915591569157915891599160916191629163916491659166916791689169917091719172917391749175917691779178917991809181918291839184918591869187918891899190919191929193919491959196919791989199920092019202920392049205920692079208920992109211921292139214921592169217921892199220922192229223922492259226922792289229923092319232923392349235923692379238923992409241924292439244924592469247924892499250925192529253925492559256925792589259926092619262926392649265926692679268926992709271927292739274927592769277927892799280928192829283928492859286928792889289929092919292929392949295929692979298929993009301930293039304930593069307930893099310931193129313931493159316931793189319932093219322932393249325932693279328932993309331933293339334933593369337933893399340934193429343934493459346934793489349935093519352935393549355935693579358935993609361936293639364936593669367936893699370937193729373937493759376937793789379938093819382938393849385938693879388938993909391939293939394939593969397939893999400940194029403940494059406940794089409941094119412941394149415941694179418941994209421942294239424942594269427942894299430943194329433943494359436943794389439944094419442944394449445944694479448944994509451945294539454945594569457945894599460946194629463946494659466946794689469947094719472947394749475947694779478947994809481948294839484948594869487948894899490949194929493949494959496949794989499950095019502950395049505950695079508950995109511951295139514951595169517951895199520952195229523952495259526952795289529953095319532953395349535953695379538953995409541954295439544954595469547954895499550955195529553955495559556955795589559956095619562956395649565956695679568956995709571957295739574957595769577957895799580958195829583958495859586958795889589959095919592959395949595959695979598959996009601960296039604960596069607960896099610961196129613961496159616961796189619962096219622962396249625962696279628962996309631963296339634963596369637963896399640964196429643964496459646964796489649965096519652965396549655965696579658965996609661966296639664966596669667966896699670967196729673967496759676967796789679968096819682968396849685968696879688968996909691969296939694969596969697969896999700970197029703970497059706970797089709971097119712971397149715971697179718971997209721972297239724972597269727972897299730973197329733973497359736973797389739974097419742974397449745974697479748974997509751975297539754975597569757975897599760976197629763976497659766976797689769977097719772977397749775977697779778977997809781978297839784978597869787978897899790979197929793979497959796979797989799980098019802980398049805980698079808980998109811981298139814981598169817981898199820982198229823982498259826982798289829983098319832983398349835983698379838983998409841984298439844984598469847984898499850985198529853985498559856985798589859986098619862986398649865986698679868986998709871987298739874987598769877987898799880988198829883988498859886988798889889989098919892989398949895989698979898989999009901990299039904990599069907990899099910991199129913991499159916991799189919992099219922992399249925992699279928992999309931993299339934993599369937993899399940994199429943994499459946994799489949995099519952995399549955995699579958995999609961996299639964996599669967996899699970997199729973997499759976997799789979998099819982998399849985998699879988998999909991999299939994999599969997999899991000010001100021000310004100051000610007100081000910010100111001210013100141001510016100171001810019100201002110022100231002410025100261002710028100291003010031100321003310034100351003610037100381003910040100411004210043100441004510046100471004810049100501005110052100531005410055100561005710058100591006010061100621006310064100651006610067100681006910070100711007210073100741007510076100771007810079100801008110082100831008410085100861008710088100891009010091100921009310094100951009610097100981009910100101011010210103101041010510106101071010810109101101011110112101131011410115101161011710118101191012010121101221012310124101251012610127101281012910130101311013210133101341013510136101371013810139101401014110142101431014410145101461014710148101491015010151101521015310154101551015610157101581015910160101611016210163101641016510166101671016810169101701017110172101731017410175101761017710178101791018010181101821018310184101851018610187101881018910190101911019210193101941019510196101971019810199102001020110202102031020410205102061020710208102091021010211102121021310214102151021610217102181021910220102211022210223102241022510226102271022810229102301023110232102331023410235102361023710238102391024010241102421024310244102451024610247102481024910250102511025210253102541025510256102571025810259102601026110262102631026410265102661026710268102691027010271102721027310274102751027610277102781027910280102811028210283102841028510286102871028810289102901029110292102931029410295102961029710298102991030010301103021030310304103051030610307103081030910310103111031210313103141031510316103171031810319103201032110322103231032410325103261032710328103291033010331103321033310334103351033610337103381033910340103411034210343103441034510346103471034810349103501035110352103531035410355103561035710358103591036010361103621036310364103651036610367103681036910370103711037210373103741037510376103771037810379103801038110382103831038410385103861038710388103891039010391103921039310394103951039610397103981039910400104011040210403104041040510406104071040810409104101041110412104131041410415104161041710418104191042010421104221042310424104251042610427104281042910430104311043210433104341043510436104371043810439104401044110442104431044410445104461044710448104491045010451104521045310454104551045610457104581045910460104611046210463104641046510466104671046810469104701047110472104731047410475104761047710478104791048010481104821048310484104851048610487104881048910490104911049210493104941049510496104971049810499105001050110502105031050410505105061050710508105091051010511105121051310514105151051610517105181051910520105211052210523105241052510526105271052810529105301053110532105331053410535105361053710538105391054010541105421054310544105451054610547105481054910550105511055210553105541055510556105571055810559105601056110562105631056410565105661056710568105691057010571105721057310574105751057610577105781057910580105811058210583105841058510586105871058810589105901059110592105931059410595105961059710598105991060010601106021060310604106051060610607106081060910610106111061210613106141061510616106171061810619106201062110622106231062410625106261062710628106291063010631106321063310634106351063610637106381063910640106411064210643106441064510646106471064810649106501065110652106531065410655106561065710658106591066010661106621066310664106651066610667106681066910670106711067210673106741067510676106771067810679106801068110682106831068410685106861068710688106891069010691106921069310694106951069610697106981069910700107011070210703107041070510706107071070810709107101071110712107131071410715107161071710718107191072010721107221072310724107251072610727107281072910730107311073210733107341073510736107371073810739107401074110742107431074410745107461074710748107491075010751107521075310754107551075610757107581075910760107611076210763107641076510766107671076810769107701077110772107731077410775107761077710778107791078010781107821078310784107851078610787107881078910790107911079210793107941079510796107971079810799108001080110802108031080410805108061080710808108091081010811108121081310814108151081610817108181081910820108211082210823108241082510826108271082810829108301083110832108331083410835108361083710838108391084010841108421084310844108451084610847108481084910850108511085210853108541085510856108571085810859108601086110862108631086410865108661086710868108691087010871108721087310874108751087610877108781087910880108811088210883108841088510886108871088810889108901089110892108931089410895108961089710898108991090010901109021090310904109051090610907109081090910910109111091210913109141091510916109171091810919109201092110922109231092410925109261092710928109291093010931109321093310934109351093610937109381093910940109411094210943109441094510946109471094810949109501095110952109531095410955109561095710958109591096010961109621096310964109651096610967109681096910970109711097210973109741097510976109771097810979109801098110982109831098410985109861098710988109891099010991109921099310994109951099610997109981099911000110011100211003110041100511006110071100811009110101101111012110131101411015110161101711018110191102011021110221102311024110251102611027110281102911030110311103211033110341103511036110371103811039110401104111042110431104411045110461104711048110491105011051110521105311054110551105611057110581105911060110611106211063110641106511066110671106811069110701107111072110731107411075110761107711078110791108011081110821108311084110851108611087110881108911090110911109211093110941109511096110971109811099111001110111102111031110411105111061110711108111091111011111111121111311114111151111611117111181111911120111211112211123111241112511126111271112811129111301113111132111331113411135111361113711138111391114011141111421114311144111451114611147111481114911150111511115211153111541115511156111571115811159111601116111162111631116411165111661116711168111691117011171111721117311174111751117611177111781117911180111811118211183111841118511186111871118811189111901119111192111931119411195111961119711198111991120011201112021120311204112051120611207112081120911210112111121211213112141121511216112171121811219112201122111222112231122411225112261122711228112291123011231112321123311234112351123611237112381123911240112411124211243112441124511246112471124811249112501125111252112531125411255112561125711258112591126011261112621126311264112651126611267112681126911270112711127211273112741127511276112771127811279112801128111282112831128411285112861128711288112891129011291112921129311294112951129611297112981129911300113011130211303113041130511306113071130811309113101131111312113131131411315113161131711318113191132011321113221132311324113251132611327113281132911330113311133211333113341133511336113371133811339113401134111342113431134411345113461134711348113491135011351113521135311354113551135611357113581135911360113611136211363113641136511366113671136811369113701137111372113731137411375113761137711378113791138011381113821138311384113851138611387113881138911390113911139211393113941139511396113971139811399114001140111402114031140411405114061140711408114091141011411114121141311414114151141611417114181141911420114211142211423114241142511426114271142811429114301143111432114331143411435114361143711438114391144011441114421144311444114451144611447114481144911450114511145211453114541145511456114571145811459114601146111462114631146411465114661146711468114691147011471114721147311474114751147611477114781147911480114811148211483114841148511486114871148811489114901149111492114931149411495114961149711498114991150011501115021150311504115051150611507115081150911510115111151211513115141151511516115171151811519115201152111522115231152411525115261152711528115291153011531115321153311534115351153611537115381153911540115411154211543115441154511546115471154811549115501155111552115531155411555115561155711558115591156011561115621156311564115651156611567115681156911570115711157211573115741157511576115771157811579115801158111582115831158411585115861158711588115891159011591115921159311594115951159611597115981159911600116011160211603116041160511606116071160811609116101161111612116131161411615116161161711618116191162011621116221162311624116251162611627116281162911630116311163211633116341163511636116371163811639116401164111642116431164411645116461164711648116491165011651116521165311654116551165611657116581165911660116611166211663116641166511666116671166811669116701167111672116731167411675116761167711678116791168011681116821168311684116851168611687116881168911690116911169211693116941169511696116971169811699117001170111702117031170411705117061170711708117091171011711117121171311714117151171611717117181171911720117211172211723117241172511726117271172811729117301173111732117331173411735117361173711738117391174011741117421174311744117451174611747117481174911750117511175211753117541175511756117571175811759117601176111762117631176411765117661176711768117691177011771117721177311774117751177611777117781177911780117811178211783117841178511786117871178811789117901179111792117931179411795117961179711798117991180011801118021180311804118051180611807118081180911810118111181211813118141181511816118171181811819118201182111822118231182411825118261182711828118291183011831118321183311834118351183611837118381183911840118411184211843118441184511846118471184811849118501185111852118531185411855118561185711858118591186011861118621186311864118651186611867118681186911870118711187211873118741187511876118771187811879118801188111882118831188411885118861188711888118891189011891118921189311894118951189611897118981189911900119011190211903119041190511906119071190811909119101191111912119131191411915119161191711918119191192011921119221192311924119251192611927119281192911930119311193211933119341193511936119371193811939119401194111942119431194411945119461194711948119491195011951119521195311954119551195611957119581195911960119611196211963119641196511966119671196811969119701197111972119731197411975119761197711978119791198011981119821198311984119851198611987119881198911990119911199211993119941199511996119971199811999120001200112002120031200412005120061200712008120091201012011120121201312014120151201612017120181201912020120211202212023120241202512026120271202812029120301203112032120331203412035120361203712038120391204012041120421204312044120451204612047120481204912050120511205212053120541205512056120571205812059120601206112062120631206412065120661206712068120691207012071120721207312074120751207612077120781207912080120811208212083120841208512086120871208812089120901209112092120931209412095120961209712098120991210012101121021210312104121051210612107121081210912110121111211212113121141211512116121171211812119121201212112122121231212412125121261212712128121291213012131121321213312134121351213612137121381213912140121411214212143121441214512146121471214812149121501215112152121531215412155121561215712158121591216012161121621216312164121651216612167121681216912170121711217212173121741217512176121771217812179121801218112182121831218412185121861218712188121891219012191121921219312194121951219612197121981219912200122011220212203122041220512206122071220812209122101221112212122131221412215122161221712218122191222012221122221222312224122251222612227122281222912230122311223212233122341223512236122371223812239122401224112242122431224412245122461224712248122491225012251122521225312254122551225612257122581225912260122611226212263122641226512266122671226812269122701227112272122731227412275122761227712278122791228012281122821228312284122851228612287122881228912290122911229212293122941229512296122971229812299123001230112302123031230412305123061230712308123091231012311123121231312314123151231612317123181231912320123211232212323123241232512326123271232812329123301233112332123331233412335123361233712338123391234012341123421234312344123451234612347123481234912350123511235212353123541235512356123571235812359123601236112362123631236412365123661236712368123691237012371123721237312374123751237612377123781237912380123811238212383123841238512386123871238812389123901239112392123931239412395123961239712398123991240012401124021240312404124051240612407124081240912410124111241212413124141241512416124171241812419124201242112422124231242412425124261242712428124291243012431124321243312434124351243612437124381243912440124411244212443124441244512446124471244812449124501245112452124531245412455124561245712458124591246012461124621246312464124651246612467124681246912470124711247212473124741247512476124771247812479124801248112482124831248412485124861248712488124891249012491124921249312494124951249612497124981249912500125011250212503125041250512506125071250812509125101251112512125131251412515125161251712518125191252012521125221252312524125251252612527125281252912530125311253212533125341253512536125371253812539125401254112542125431254412545125461254712548125491255012551125521255312554125551255612557125581255912560125611256212563125641256512566125671256812569125701257112572125731257412575125761257712578125791258012581125821258312584125851258612587125881258912590125911259212593125941259512596125971259812599126001260112602126031260412605126061260712608126091261012611126121261312614126151261612617126181261912620126211262212623126241262512626126271262812629126301263112632126331263412635126361263712638126391264012641126421264312644126451264612647126481264912650126511265212653126541265512656126571265812659126601266112662126631266412665126661266712668126691267012671126721267312674126751267612677126781267912680126811268212683126841268512686126871268812689126901269112692126931269412695126961269712698126991270012701127021270312704127051270612707127081270912710127111271212713127141271512716127171271812719127201272112722127231272412725127261272712728127291273012731127321273312734127351273612737127381273912740127411274212743127441274512746127471274812749127501275112752127531275412755127561275712758127591276012761127621276312764127651276612767127681276912770127711277212773127741277512776127771277812779127801278112782127831278412785127861278712788127891279012791127921279312794127951279612797127981279912800128011280212803128041280512806128071280812809128101281112812128131281412815128161281712818128191282012821128221282312824128251282612827128281282912830128311283212833128341283512836128371283812839128401284112842128431284412845128461284712848128491285012851128521285312854128551285612857128581285912860128611286212863128641286512866128671286812869128701287112872128731287412875128761287712878128791288012881128821288312884128851288612887128881288912890128911289212893128941289512896128971289812899129001290112902129031290412905129061290712908129091291012911129121291312914129151291612917129181291912920129211292212923129241292512926129271292812929129301293112932129331293412935129361293712938129391294012941129421294312944129451294612947129481294912950129511295212953129541295512956129571295812959129601296112962129631296412965129661296712968129691297012971129721297312974129751297612977129781297912980129811298212983129841298512986129871298812989129901299112992129931299412995129961299712998129991300013001130021300313004130051300613007130081300913010130111301213013130141301513016130171301813019130201302113022130231302413025130261302713028130291303013031130321303313034130351303613037130381303913040130411304213043130441304513046130471304813049130501305113052130531305413055130561305713058130591306013061130621306313064130651306613067130681306913070130711307213073130741307513076130771307813079130801308113082130831308413085130861308713088130891309013091130921309313094130951309613097130981309913100131011310213103131041310513106131071310813109131101311113112131131311413115131161311713118131191312013121131221312313124131251312613127131281312913130131311313213133131341313513136131371313813139131401314113142131431314413145131461314713148131491315013151131521315313154131551315613157131581315913160131611316213163131641316513166131671316813169131701317113172131731317413175131761317713178131791318013181131821318313184131851318613187131881318913190131911319213193131941319513196131971319813199132001320113202132031320413205132061320713208132091321013211132121321313214132151321613217132181321913220132211322213223132241322513226132271322813229132301323113232132331323413235132361323713238132391324013241132421324313244132451324613247132481324913250132511325213253132541325513256132571325813259132601326113262132631326413265132661326713268132691327013271132721327313274132751327613277132781327913280132811328213283132841328513286132871328813289132901329113292132931329413295132961329713298132991330013301133021330313304133051330613307133081330913310133111331213313133141331513316133171331813319133201332113322133231332413325133261332713328133291333013331133321333313334133351333613337133381333913340133411334213343133441334513346133471334813349133501335113352133531335413355133561335713358133591336013361133621336313364133651336613367133681336913370133711337213373133741337513376133771337813379133801338113382133831338413385133861338713388133891339013391133921339313394133951339613397133981339913400134011340213403134041340513406134071340813409134101341113412134131341413415134161341713418134191342013421134221342313424134251342613427134281342913430134311343213433134341343513436134371343813439134401344113442134431344413445134461344713448134491345013451134521345313454134551345613457134581345913460134611346213463134641346513466134671346813469134701347113472134731347413475134761347713478134791348013481134821348313484134851348613487134881348913490134911349213493134941349513496134971349813499135001350113502135031350413505135061350713508135091351013511135121351313514135151351613517135181351913520135211352213523135241352513526135271352813529135301353113532135331353413535135361353713538135391354013541135421354313544135451354613547135481354913550135511355213553135541355513556135571355813559135601356113562135631356413565135661356713568135691357013571135721357313574135751357613577135781357913580135811358213583135841358513586135871358813589135901359113592135931359413595135961359713598135991360013601136021360313604136051360613607136081360913610136111361213613136141361513616136171361813619136201362113622136231362413625136261362713628136291363013631136321363313634136351363613637136381363913640136411364213643136441364513646136471364813649136501365113652136531365413655136561365713658136591366013661136621366313664136651366613667136681366913670136711367213673136741367513676136771367813679136801368113682136831368413685136861368713688136891369013691136921369313694136951369613697136981369913700137011370213703137041370513706137071370813709137101371113712137131371413715137161371713718137191372013721137221372313724137251372613727137281372913730137311373213733137341373513736137371373813739137401374113742137431374413745137461374713748137491375013751137521375313754137551375613757137581375913760137611376213763137641376513766137671376813769137701377113772137731377413775137761377713778137791378013781137821378313784137851378613787137881378913790137911379213793137941379513796137971379813799138001380113802138031380413805138061380713808138091381013811138121381313814138151381613817138181381913820138211382213823138241382513826138271382813829138301383113832138331383413835138361383713838138391384013841138421384313844138451384613847138481384913850138511385213853138541385513856138571385813859138601386113862138631386413865138661386713868138691387013871138721387313874138751387613877138781387913880138811388213883138841388513886138871388813889138901389113892138931389413895138961389713898138991390013901139021390313904139051390613907139081390913910139111391213913139141391513916139171391813919139201392113922139231392413925139261392713928139291393013931139321393313934139351393613937139381393913940139411394213943139441394513946139471394813949139501395113952139531395413955139561395713958139591396013961139621396313964139651396613967139681396913970139711397213973139741397513976139771397813979139801398113982139831398413985139861398713988139891399013991139921399313994139951399613997139981399914000140011400214003140041400514006140071400814009140101401114012140131401414015140161401714018140191402014021140221402314024140251402614027140281402914030140311403214033140341403514036140371403814039140401404114042140431404414045140461404714048140491405014051140521405314054140551405614057140581405914060140611406214063140641406514066140671406814069140701407114072140731407414075140761407714078140791408014081140821408314084140851408614087140881408914090140911409214093140941409514096140971409814099141001410114102141031410414105141061410714108141091411014111141121411314114141151411614117141181411914120141211412214123141241412514126141271412814129141301413114132141331413414135141361413714138141391414014141141421414314144141451414614147141481414914150141511415214153141541415514156141571415814159141601416114162141631416414165141661416714168141691417014171141721417314174141751417614177141781417914180141811418214183141841418514186141871418814189141901419114192141931419414195141961419714198141991420014201142021420314204142051420614207142081420914210142111421214213142141421514216142171421814219142201422114222142231422414225142261422714228142291423014231142321423314234142351423614237142381423914240142411424214243142441424514246142471424814249142501425114252142531425414255142561425714258142591426014261142621426314264142651426614267142681426914270142711427214273142741427514276142771427814279142801428114282142831428414285142861428714288142891429014291142921429314294142951429614297142981429914300143011430214303143041430514306143071430814309143101431114312143131431414315143161431714318143191432014321143221432314324143251432614327143281432914330143311433214333143341433514336143371433814339143401434114342143431434414345143461434714348143491435014351143521435314354143551435614357143581435914360143611436214363143641436514366143671436814369143701437114372143731437414375143761437714378143791438014381143821438314384143851438614387143881438914390143911439214393143941439514396143971439814399144001440114402144031440414405144061440714408144091441014411144121441314414144151441614417144181441914420144211442214423144241442514426144271442814429144301443114432144331443414435144361443714438144391444014441144421444314444144451444614447144481444914450144511445214453144541445514456144571445814459144601446114462144631446414465144661446714468144691447014471144721447314474144751447614477144781447914480144811448214483144841448514486144871448814489144901449114492144931449414495144961449714498144991450014501145021450314504145051450614507145081450914510145111451214513145141451514516145171451814519145201452114522145231452414525145261452714528145291453014531145321453314534145351453614537145381453914540145411454214543145441454514546145471454814549145501455114552145531455414555145561455714558145591456014561145621456314564145651456614567145681456914570145711457214573145741457514576145771457814579145801458114582145831458414585145861458714588145891459014591145921459314594145951459614597145981459914600146011460214603146041460514606146071460814609146101461114612146131461414615146161461714618146191462014621146221462314624146251462614627146281462914630146311463214633146341463514636146371463814639146401464114642146431464414645146461464714648146491465014651146521465314654146551465614657146581465914660146611466214663146641466514666146671466814669146701467114672146731467414675146761467714678146791468014681146821468314684146851468614687146881468914690146911469214693146941469514696146971469814699147001470114702147031470414705147061470714708147091471014711147121471314714147151471614717147181471914720147211472214723147241472514726147271472814729147301473114732147331473414735147361473714738147391474014741147421474314744147451474614747147481474914750147511475214753147541475514756147571475814759147601476114762147631476414765147661476714768147691477014771147721477314774147751477614777147781477914780147811478214783147841478514786147871478814789147901479114792147931479414795147961479714798147991480014801148021480314804148051480614807148081480914810148111481214813148141481514816148171481814819148201482114822148231482414825148261482714828148291483014831148321483314834148351483614837148381483914840148411484214843148441484514846148471484814849148501485114852148531485414855148561485714858148591486014861148621486314864148651486614867148681486914870148711487214873148741487514876148771487814879148801488114882148831488414885148861488714888148891489014891148921489314894148951489614897148981489914900149011490214903149041490514906149071490814909149101491114912149131491414915149161491714918149191492014921149221492314924149251492614927149281492914930149311493214933149341493514936149371493814939149401494114942149431494414945149461494714948149491495014951149521495314954149551495614957149581495914960149611496214963149641496514966149671496814969149701497114972149731497414975149761497714978149791498014981149821498314984149851498614987149881498914990149911499214993149941499514996149971499814999150001500115002150031500415005150061500715008150091501015011150121501315014150151501615017150181501915020150211502215023150241502515026150271502815029150301503115032150331503415035150361503715038150391504015041150421504315044150451504615047150481504915050150511505215053150541505515056150571505815059150601506115062150631506415065150661506715068150691507015071150721507315074150751507615077150781507915080150811508215083150841508515086150871508815089150901509115092150931509415095150961509715098150991510015101151021510315104151051510615107151081510915110151111511215113151141511515116151171511815119151201512115122151231512415125151261512715128151291513015131151321513315134151351513615137151381513915140151411514215143151441514515146151471514815149151501515115152151531515415155151561515715158151591516015161151621516315164151651516615167151681516915170151711517215173151741517515176151771517815179151801518115182151831518415185151861518715188151891519015191151921519315194151951519615197151981519915200152011520215203152041520515206152071520815209152101521115212152131521415215152161521715218152191522015221152221522315224152251522615227152281522915230152311523215233152341523515236152371523815239152401524115242152431524415245152461524715248152491525015251152521525315254152551525615257152581525915260152611526215263152641526515266152671526815269152701527115272152731527415275152761527715278152791528015281152821528315284152851528615287152881528915290152911529215293152941529515296152971529815299153001530115302153031530415305153061530715308153091531015311153121531315314153151531615317153181531915320153211532215323153241532515326153271532815329153301533115332153331533415335153361533715338153391534015341153421534315344153451534615347153481534915350153511535215353153541535515356153571535815359153601536115362153631536415365153661536715368153691537015371153721537315374153751537615377153781537915380153811538215383153841538515386153871538815389153901539115392153931539415395153961539715398153991540015401154021540315404154051540615407154081540915410154111541215413154141541515416154171541815419154201542115422154231542415425154261542715428154291543015431154321543315434154351543615437154381543915440154411544215443154441544515446154471544815449154501545115452154531545415455154561545715458154591546015461154621546315464154651546615467154681546915470154711547215473154741547515476154771547815479154801548115482154831548415485154861548715488154891549015491154921549315494154951549615497154981549915500155011550215503155041550515506155071550815509155101551115512155131551415515155161551715518155191552015521155221552315524155251552615527155281552915530155311553215533155341553515536155371553815539155401554115542155431554415545155461554715548155491555015551155521555315554155551555615557155581555915560155611556215563155641556515566155671556815569155701557115572155731557415575155761557715578155791558015581155821558315584155851558615587155881558915590155911559215593155941559515596155971559815599156001560115602156031560415605156061560715608156091561015611156121561315614156151561615617156181561915620156211562215623156241562515626156271562815629156301563115632156331563415635156361563715638156391564015641156421564315644156451564615647156481564915650156511565215653156541565515656156571565815659156601566115662156631566415665156661566715668156691567015671156721567315674156751567615677156781567915680156811568215683156841568515686156871568815689156901569115692156931569415695156961569715698156991570015701157021570315704157051570615707157081570915710157111571215713157141571515716157171571815719157201572115722157231572415725157261572715728157291573015731157321573315734157351573615737157381573915740157411574215743157441574515746157471574815749157501575115752157531575415755157561575715758157591576015761157621576315764157651576615767157681576915770157711577215773157741577515776157771577815779157801578115782157831578415785157861578715788157891579015791157921579315794157951579615797157981579915800158011580215803158041580515806158071580815809158101581115812158131581415815158161581715818158191582015821158221582315824158251582615827158281582915830158311583215833158341583515836158371583815839158401584115842158431584415845158461584715848158491585015851158521585315854158551585615857158581585915860158611586215863158641586515866158671586815869158701587115872158731587415875158761587715878158791588015881158821588315884158851588615887158881588915890158911589215893158941589515896158971589815899159001590115902159031590415905159061590715908159091591015911159121591315914159151591615917159181591915920159211592215923159241592515926159271592815929159301593115932159331593415935159361593715938159391594015941159421594315944159451594615947159481594915950159511595215953159541595515956159571595815959159601596115962159631596415965159661596715968159691597015971159721597315974159751597615977159781597915980159811598215983159841598515986159871598815989159901599115992159931599415995159961599715998159991600016001160021600316004160051600616007160081600916010160111601216013160141601516016160171601816019160201602116022160231602416025160261602716028160291603016031160321603316034160351603616037160381603916040160411604216043160441604516046160471604816049160501605116052160531605416055160561605716058160591606016061160621606316064160651606616067160681606916070160711607216073160741607516076160771607816079160801608116082160831608416085160861608716088160891609016091160921609316094160951609616097160981609916100161011610216103161041610516106161071610816109161101611116112161131611416115161161611716118161191612016121161221612316124161251612616127161281612916130161311613216133161341613516136161371613816139161401614116142161431614416145161461614716148161491615016151161521615316154161551615616157161581615916160161611616216163161641616516166161671616816169161701617116172161731617416175161761617716178161791618016181161821618316184161851618616187161881618916190161911619216193161941619516196161971619816199162001620116202162031620416205162061620716208162091621016211162121621316214162151621616217162181621916220162211622216223162241622516226162271622816229162301623116232162331623416235162361623716238162391624016241162421624316244162451624616247162481624916250162511625216253162541625516256162571625816259162601626116262162631626416265162661626716268162691627016271162721627316274162751627616277162781627916280162811628216283162841628516286162871628816289162901629116292162931629416295162961629716298162991630016301163021630316304163051630616307163081630916310163111631216313163141631516316163171631816319163201632116322163231632416325
  1. /*
  2. Legal:
  3. Version: MPL 1.1
  4. The contents of this file are subject to the Mozilla Public License Version
  5. 1.1 the "License"; you may not use this file except in compliance with
  6. the License. You may obtain a copy of the License at
  7. http://www.mozilla.org/MPL/
  8. Software distributed under the License is distributed on an "AS IS" basis,
  9. WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
  10. for the specific language governing rights and limitations under the
  11. License.
  12. The Original Code is the YSI framework.
  13. The Initial Developer of the Original Code is Alex "Y_Less" Cole.
  14. Portions created by the Initial Developer are Copyright C 2011
  15. the Initial Developer. All Rights Reserved.
  16. Contributors:
  17. Y_Less
  18. koolk
  19. JoeBullet/Google63
  20. g_aSlice/Slice
  21. Misiur
  22. samphunter
  23. tianmeta
  24. maddinat0r
  25. spacemud
  26. Crayder
  27. Dayvison
  28. Ahmad45123
  29. Zeex
  30. irinel1996
  31. Yiin-
  32. Chaprnks
  33. Konstantinos
  34. Masterchen09
  35. Southclaws
  36. PatchwerkQWER
  37. m0k1
  38. paulommu
  39. udan111
  40. Thanks:
  41. JoeBullet/Google63 - Handy arbitrary ASM jump code using SCTRL.
  42. ZeeX - Very productive conversations.
  43. koolk - IsPlayerinAreaEx code.
  44. TheAlpha - Danish translation.
  45. breadfish - German translation.
  46. Fireburn - Dutch translation.
  47. yom - French translation.
  48. 50p - Polish translation.
  49. Zamaroht - Spanish translation.
  50. Los - Portuguese translation.
  51. Dracoblue, sintax, mabako, Xtreme, other coders - Producing other modes for
  52. me to strive to better.
  53. Pixels^ - Running XScripters where the idea was born.
  54. Matite - Pestering me to release it and using it.
  55. Very special thanks to:
  56. Thiadmer - PAWN, whose limits continue to amaze me!
  57. Kye/Kalcor - SA:MP.
  58. SA:MP Team past, present and future - SA:MP.
  59. Optional plugins:
  60. Gamer_Z - GPS.
  61. Incognito - Streamer.
  62. Me - sscanf2, fixes2, Whirlpool.
  63. */
  64. #define _X11_SPACE_CHECK(%0) (checkSpace && str[(%0)] == ' ')
  65. #define _X11_SPACE_SWITCH: ' ':if(checkSpace)
  66. /*(str[9] == ' ' || str[9] == '_')
  67. ((checkSpace && _X11_SPACE_CHECK()) || str[9] == '_')
  68. (str[9] != ' ' && str[9] != '_')
  69. (!(checkSpace && _X11_SPACE_CHECK(9)) && str[9] != '_')*/
  70. switch (str[0] | 0x20)
  71. {
  72. case 'a':
  73. {
  74. switch (str[1] | 0x20)
  75. {
  76. case 'l':
  77. {
  78. if (!str[2] || strcmp(str[2], !"ICE", true, 3))
  79. {
  80. return -1;
  81. }
  82. switch (str[5] | 0x20)
  83. {
  84. case _X11_SPACE_SWITCH: // ' '
  85. {
  86. if (str[5])
  87. {
  88. if (str[6] && !strcmp(str[6], !"BLUE", true, 4))
  89. {
  90. idx += 10;
  91. return X11_ALICE_BLUE;
  92. }
  93. }
  94. }
  95. case '_' | 0x20:
  96. {
  97. if (str[6] && !strcmp(str[6], !"BLUE", true, 4))
  98. {
  99. idx += 10;
  100. return X11_ALICE_BLUE;
  101. }
  102. }
  103. case 'b':
  104. {
  105. if (str[6] && !strcmp(str[6], !"LUE", true, 3))
  106. {
  107. idx += 9;
  108. return X11_ALICEBLUE;
  109. }
  110. }
  111. }
  112. }
  113. case 'n':
  114. {
  115. if (!str[2] || strcmp(str[2], !"TIQUE", true, 5))
  116. {
  117. return -1;
  118. }
  119. switch (str[7] | 0x20)
  120. {
  121. case _X11_SPACE_SWITCH: // ' '
  122. {
  123. if (str[7])
  124. {
  125. if (!str[8] || strcmp(str[8], !"WHITE", true, 5))
  126. {
  127. return -1;
  128. }
  129. switch (str[13] | 0x20)
  130. {
  131. case _X11_SPACE_SWITCH: // ' '
  132. {
  133. if (str[13])
  134. {
  135. switch (str[14] | 0x20)
  136. {
  137. case '1':
  138. {
  139. idx += 15;
  140. return X11_ANTIQUE_WHITE_1;
  141. }
  142. case '2':
  143. {
  144. idx += 15;
  145. return X11_ANTIQUE_WHITE_2;
  146. }
  147. case '3':
  148. {
  149. idx += 15;
  150. return X11_ANTIQUE_WHITE_3;
  151. }
  152. case '4':
  153. {
  154. idx += 15;
  155. return X11_ANTIQUE_WHITE_4;
  156. }
  157. }
  158. }
  159. }
  160. case '_' | 0x20:
  161. {
  162. switch (str[14] | 0x20)
  163. {
  164. case '1':
  165. {
  166. idx += 15;
  167. return X11_ANTIQUE_WHITE_1;
  168. }
  169. case '2':
  170. {
  171. idx += 15;
  172. return X11_ANTIQUE_WHITE_2;
  173. }
  174. case '3':
  175. {
  176. idx += 15;
  177. return X11_ANTIQUE_WHITE_3;
  178. }
  179. case '4':
  180. {
  181. idx += 15;
  182. return X11_ANTIQUE_WHITE_4;
  183. }
  184. }
  185. }
  186. }
  187. idx += 13;
  188. return X11_ANTIQUE_WHITE;
  189. }
  190. }
  191. case '_' | 0x20:
  192. {
  193. if (!str[8] || strcmp(str[8], !"WHITE", true, 5))
  194. {
  195. return -1;
  196. }
  197. switch (str[13] | 0x20)
  198. {
  199. case _X11_SPACE_SWITCH: // ' '
  200. {
  201. if (str[13])
  202. {
  203. switch (str[14] | 0x20)
  204. {
  205. case '1':
  206. {
  207. idx += 15;
  208. return X11_ANTIQUE_WHITE_1;
  209. }
  210. case '2':
  211. {
  212. idx += 15;
  213. return X11_ANTIQUE_WHITE_2;
  214. }
  215. case '3':
  216. {
  217. idx += 15;
  218. return X11_ANTIQUE_WHITE_3;
  219. }
  220. case '4':
  221. {
  222. idx += 15;
  223. return X11_ANTIQUE_WHITE_4;
  224. }
  225. }
  226. }
  227. }
  228. case '_' | 0x20:
  229. {
  230. switch (str[14] | 0x20)
  231. {
  232. case '1':
  233. {
  234. idx += 15;
  235. return X11_ANTIQUE_WHITE_1;
  236. }
  237. case '2':
  238. {
  239. idx += 15;
  240. return X11_ANTIQUE_WHITE_2;
  241. }
  242. case '3':
  243. {
  244. idx += 15;
  245. return X11_ANTIQUE_WHITE_3;
  246. }
  247. case '4':
  248. {
  249. idx += 15;
  250. return X11_ANTIQUE_WHITE_4;
  251. }
  252. }
  253. }
  254. }
  255. idx += 13;
  256. return X11_ANTIQUE_WHITE;
  257. }
  258. case 'w':
  259. {
  260. if (!str[8] || strcmp(str[8], !"HITE", true, 4))
  261. {
  262. return -1;
  263. }
  264. switch (str[12] | 0x20)
  265. {
  266. case '1':
  267. {
  268. idx += 13;
  269. return X11_ANTIQUEWHITE1;
  270. }
  271. case '2':
  272. {
  273. idx += 13;
  274. return X11_ANTIQUEWHITE2;
  275. }
  276. case '3':
  277. {
  278. idx += 13;
  279. return X11_ANTIQUEWHITE3;
  280. }
  281. case '4':
  282. {
  283. idx += 13;
  284. return X11_ANTIQUEWHITE4;
  285. }
  286. }
  287. idx += 12;
  288. return X11_ANTIQUEWHITE;
  289. }
  290. }
  291. }
  292. case 'q':
  293. {
  294. if (!str[2] || strcmp(str[2], !"UAMARINE", true, 8))
  295. {
  296. return -1;
  297. }
  298. switch (str[10] | 0x20)
  299. {
  300. case _X11_SPACE_SWITCH: // ' '
  301. {
  302. if (str[10])
  303. {
  304. switch (str[11] | 0x20)
  305. {
  306. case '1':
  307. {
  308. idx += 12;
  309. return X11_AQUAMARINE_1;
  310. }
  311. case '2':
  312. {
  313. idx += 12;
  314. return X11_AQUAMARINE_2;
  315. }
  316. case '3':
  317. {
  318. idx += 12;
  319. return X11_AQUAMARINE_3;
  320. }
  321. case '4':
  322. {
  323. idx += 12;
  324. return X11_AQUAMARINE_4;
  325. }
  326. }
  327. }
  328. }
  329. case '_' | 0x20:
  330. {
  331. switch (str[11] | 0x20)
  332. {
  333. case '1':
  334. {
  335. idx += 12;
  336. return X11_AQUAMARINE_1;
  337. }
  338. case '2':
  339. {
  340. idx += 12;
  341. return X11_AQUAMARINE_2;
  342. }
  343. case '3':
  344. {
  345. idx += 12;
  346. return X11_AQUAMARINE_3;
  347. }
  348. case '4':
  349. {
  350. idx += 12;
  351. return X11_AQUAMARINE_4;
  352. }
  353. }
  354. }
  355. case '1':
  356. {
  357. idx += 11;
  358. return X11_AQUAMARINE1;
  359. }
  360. case '2':
  361. {
  362. idx += 11;
  363. return X11_AQUAMARINE2;
  364. }
  365. case '3':
  366. {
  367. idx += 11;
  368. return X11_AQUAMARINE3;
  369. }
  370. case '4':
  371. {
  372. idx += 11;
  373. return X11_AQUAMARINE4;
  374. }
  375. }
  376. idx += 10;
  377. return X11_AQUAMARINE;
  378. }
  379. case 'z':
  380. {
  381. if (!str[2] || strcmp(str[2], !"URE", true, 3))
  382. {
  383. return -1;
  384. }
  385. switch (str[5] | 0x20)
  386. {
  387. case _X11_SPACE_SWITCH: // ' '
  388. {
  389. if (str[5])
  390. {
  391. switch (str[6] | 0x20)
  392. {
  393. case '1':
  394. {
  395. idx += 7;
  396. return X11_AZURE_1;
  397. }
  398. case '2':
  399. {
  400. idx += 7;
  401. return X11_AZURE_2;
  402. }
  403. case '3':
  404. {
  405. idx += 7;
  406. return X11_AZURE_3;
  407. }
  408. case '4':
  409. {
  410. idx += 7;
  411. return X11_AZURE_4;
  412. }
  413. }
  414. }
  415. }
  416. case '_' | 0x20:
  417. {
  418. switch (str[6] | 0x20)
  419. {
  420. case '1':
  421. {
  422. idx += 7;
  423. return X11_AZURE_1;
  424. }
  425. case '2':
  426. {
  427. idx += 7;
  428. return X11_AZURE_2;
  429. }
  430. case '3':
  431. {
  432. idx += 7;
  433. return X11_AZURE_3;
  434. }
  435. case '4':
  436. {
  437. idx += 7;
  438. return X11_AZURE_4;
  439. }
  440. }
  441. }
  442. case '1':
  443. {
  444. idx += 6;
  445. return X11_AZURE1;
  446. }
  447. case '2':
  448. {
  449. idx += 6;
  450. return X11_AZURE2;
  451. }
  452. case '3':
  453. {
  454. idx += 6;
  455. return X11_AZURE3;
  456. }
  457. case '4':
  458. {
  459. idx += 6;
  460. return X11_AZURE4;
  461. }
  462. }
  463. idx += 5;
  464. return X11_AZURE;
  465. }
  466. }
  467. }
  468. case 'b':
  469. {
  470. switch (str[1] | 0x20)
  471. {
  472. case 'e':
  473. {
  474. if (str[2] && !strcmp(str[2], !"IGE", true, 3))
  475. {
  476. idx += 5;
  477. return X11_BEIGE;
  478. }
  479. }
  480. case 'i':
  481. {
  482. if (!str[2] || strcmp(str[2], !"SQUE", true, 4))
  483. {
  484. return -1;
  485. }
  486. switch (str[6] | 0x20)
  487. {
  488. case _X11_SPACE_SWITCH: // ' '
  489. {
  490. if (str[6])
  491. {
  492. switch (str[7] | 0x20)
  493. {
  494. case '1':
  495. {
  496. idx += 8;
  497. return X11_BISQUE_1;
  498. }
  499. case '2':
  500. {
  501. idx += 8;
  502. return X11_BISQUE_2;
  503. }
  504. case '3':
  505. {
  506. idx += 8;
  507. return X11_BISQUE_3;
  508. }
  509. case '4':
  510. {
  511. idx += 8;
  512. return X11_BISQUE_4;
  513. }
  514. }
  515. }
  516. }
  517. case '_' | 0x20:
  518. {
  519. switch (str[7] | 0x20)
  520. {
  521. case '1':
  522. {
  523. idx += 8;
  524. return X11_BISQUE_1;
  525. }
  526. case '2':
  527. {
  528. idx += 8;
  529. return X11_BISQUE_2;
  530. }
  531. case '3':
  532. {
  533. idx += 8;
  534. return X11_BISQUE_3;
  535. }
  536. case '4':
  537. {
  538. idx += 8;
  539. return X11_BISQUE_4;
  540. }
  541. }
  542. }
  543. case '1':
  544. {
  545. idx += 7;
  546. return X11_BISQUE1;
  547. }
  548. case '2':
  549. {
  550. idx += 7;
  551. return X11_BISQUE2;
  552. }
  553. case '3':
  554. {
  555. idx += 7;
  556. return X11_BISQUE3;
  557. }
  558. case '4':
  559. {
  560. idx += 7;
  561. return X11_BISQUE4;
  562. }
  563. }
  564. idx += 6;
  565. return X11_BISQUE;
  566. }
  567. case 'l':
  568. {
  569. switch (str[2] | 0x20)
  570. {
  571. case 'a':
  572. {
  573. switch (str[3] | 0x20)
  574. {
  575. case 'c':
  576. {
  577. if (str[4] | 0x20 == 'k')
  578. {
  579. idx += 5;
  580. return X11_BLACK;
  581. }
  582. }
  583. case 'n':
  584. {
  585. if (!str[4] || strcmp(str[4], !"CHED", true, 4))
  586. {
  587. return -1;
  588. }
  589. switch (str[8] | 0x20)
  590. {
  591. case _X11_SPACE_SWITCH: // ' '
  592. {
  593. if (str[8])
  594. {
  595. if (str[9] && !strcmp(str[9], !"ALMOND", true, 6))
  596. {
  597. idx += 15;
  598. return X11_BLANCHED_ALMOND;
  599. }
  600. }
  601. }
  602. case '_' | 0x20:
  603. {
  604. if (str[9] && !strcmp(str[9], !"ALMOND", true, 6))
  605. {
  606. idx += 15;
  607. return X11_BLANCHED_ALMOND;
  608. }
  609. }
  610. case 'a':
  611. {
  612. if (str[9] && !strcmp(str[9], !"LMOND", true, 5))
  613. {
  614. idx += 14;
  615. return X11_BLANCHEDALMOND;
  616. }
  617. }
  618. }
  619. }
  620. }
  621. }
  622. case 'u':
  623. {
  624. if (str[3] | 0x20 != 'e')
  625. {
  626. return -1;
  627. }
  628. switch (str[4] | 0x20)
  629. {
  630. case _X11_SPACE_SWITCH: // ' '
  631. {
  632. if (str[4])
  633. {
  634. switch (str[5] | 0x20)
  635. {
  636. case '1':
  637. {
  638. idx += 6;
  639. return X11_BLUE_1;
  640. }
  641. case '2':
  642. {
  643. idx += 6;
  644. return X11_BLUE_2;
  645. }
  646. case '3':
  647. {
  648. idx += 6;
  649. return X11_BLUE_3;
  650. }
  651. case '4':
  652. {
  653. idx += 6;
  654. return X11_BLUE_4;
  655. }
  656. case 'v':
  657. {
  658. if (str[6] && !strcmp(str[6], !"IOLET", true, 5))
  659. {
  660. idx += 11;
  661. return X11_BLUE_VIOLET;
  662. }
  663. }
  664. }
  665. }
  666. }
  667. case '_' | 0x20:
  668. {
  669. switch (str[5] | 0x20)
  670. {
  671. case '1':
  672. {
  673. idx += 6;
  674. return X11_BLUE_1;
  675. }
  676. case '2':
  677. {
  678. idx += 6;
  679. return X11_BLUE_2;
  680. }
  681. case '3':
  682. {
  683. idx += 6;
  684. return X11_BLUE_3;
  685. }
  686. case '4':
  687. {
  688. idx += 6;
  689. return X11_BLUE_4;
  690. }
  691. case 'v':
  692. {
  693. if (str[6] && !strcmp(str[6], !"IOLET", true, 5))
  694. {
  695. idx += 11;
  696. return X11_BLUE_VIOLET;
  697. }
  698. }
  699. }
  700. }
  701. case '1':
  702. {
  703. idx += 5;
  704. return X11_BLUE1;
  705. }
  706. case '2':
  707. {
  708. idx += 5;
  709. return X11_BLUE2;
  710. }
  711. case '3':
  712. {
  713. idx += 5;
  714. return X11_BLUE3;
  715. }
  716. case '4':
  717. {
  718. idx += 5;
  719. return X11_BLUE4;
  720. }
  721. case 'v':
  722. {
  723. if (str[5] && !strcmp(str[5], !"IOLET", true, 5))
  724. {
  725. idx += 10;
  726. return X11_BLUEVIOLET;
  727. }
  728. }
  729. }
  730. idx += 4;
  731. return X11_BLUE;
  732. }
  733. }
  734. }
  735. case 'r':
  736. {
  737. if (!str[2] || strcmp(str[2], !"OWN", true, 3))
  738. {
  739. return -1;
  740. }
  741. switch (str[5] | 0x20)
  742. {
  743. case _X11_SPACE_SWITCH: // ' '
  744. {
  745. if (str[5])
  746. {
  747. switch (str[6] | 0x20)
  748. {
  749. case '1':
  750. {
  751. idx += 7;
  752. return X11_BROWN_1;
  753. }
  754. case '2':
  755. {
  756. idx += 7;
  757. return X11_BROWN_2;
  758. }
  759. case '3':
  760. {
  761. idx += 7;
  762. return X11_BROWN_3;
  763. }
  764. case '4':
  765. {
  766. idx += 7;
  767. return X11_BROWN_4;
  768. }
  769. }
  770. }
  771. }
  772. case '_' | 0x20:
  773. {
  774. switch (str[6] | 0x20)
  775. {
  776. case '1':
  777. {
  778. idx += 7;
  779. return X11_BROWN_1;
  780. }
  781. case '2':
  782. {
  783. idx += 7;
  784. return X11_BROWN_2;
  785. }
  786. case '3':
  787. {
  788. idx += 7;
  789. return X11_BROWN_3;
  790. }
  791. case '4':
  792. {
  793. idx += 7;
  794. return X11_BROWN_4;
  795. }
  796. }
  797. }
  798. case '1':
  799. {
  800. idx += 6;
  801. return X11_BROWN1;
  802. }
  803. case '2':
  804. {
  805. idx += 6;
  806. return X11_BROWN2;
  807. }
  808. case '3':
  809. {
  810. idx += 6;
  811. return X11_BROWN3;
  812. }
  813. case '4':
  814. {
  815. idx += 6;
  816. return X11_BROWN4;
  817. }
  818. }
  819. idx += 5;
  820. return X11_BROWN;
  821. }
  822. case 'u':
  823. {
  824. if (!str[2] || strcmp(str[2], !"RLYWOOD", true, 7))
  825. {
  826. return -1;
  827. }
  828. switch (str[9] | 0x20)
  829. {
  830. case _X11_SPACE_SWITCH: // ' '
  831. {
  832. if (str[9])
  833. {
  834. switch (str[10] | 0x20)
  835. {
  836. case '1':
  837. {
  838. idx += 11;
  839. return X11_BURLYWOOD_1;
  840. }
  841. case '2':
  842. {
  843. idx += 11;
  844. return X11_BURLYWOOD_2;
  845. }
  846. case '3':
  847. {
  848. idx += 11;
  849. return X11_BURLYWOOD_3;
  850. }
  851. case '4':
  852. {
  853. idx += 11;
  854. return X11_BURLYWOOD_4;
  855. }
  856. }
  857. }
  858. }
  859. case '_' | 0x20:
  860. {
  861. switch (str[10] | 0x20)
  862. {
  863. case '1':
  864. {
  865. idx += 11;
  866. return X11_BURLYWOOD_1;
  867. }
  868. case '2':
  869. {
  870. idx += 11;
  871. return X11_BURLYWOOD_2;
  872. }
  873. case '3':
  874. {
  875. idx += 11;
  876. return X11_BURLYWOOD_3;
  877. }
  878. case '4':
  879. {
  880. idx += 11;
  881. return X11_BURLYWOOD_4;
  882. }
  883. }
  884. }
  885. case '1':
  886. {
  887. idx += 10;
  888. return X11_BURLYWOOD1;
  889. }
  890. case '2':
  891. {
  892. idx += 10;
  893. return X11_BURLYWOOD2;
  894. }
  895. case '3':
  896. {
  897. idx += 10;
  898. return X11_BURLYWOOD3;
  899. }
  900. case '4':
  901. {
  902. idx += 10;
  903. return X11_BURLYWOOD4;
  904. }
  905. }
  906. idx += 9;
  907. return X11_BURLYWOOD;
  908. }
  909. }
  910. }
  911. case 'c':
  912. {
  913. switch (str[1] | 0x20)
  914. {
  915. case 'a':
  916. {
  917. if (!str[2] || strcmp(str[2], !"DET", true, 3))
  918. {
  919. return -1;
  920. }
  921. switch (str[5] | 0x20)
  922. {
  923. case _X11_SPACE_SWITCH: // ' '
  924. {
  925. if (str[5])
  926. {
  927. if (!str[6] || strcmp(str[6], !"BLUE", true, 4))
  928. {
  929. return -1;
  930. }
  931. switch (str[10] | 0x20)
  932. {
  933. case _X11_SPACE_SWITCH: // ' '
  934. {
  935. if (str[10])
  936. {
  937. switch (str[11] | 0x20)
  938. {
  939. case '1':
  940. {
  941. idx += 12;
  942. return X11_CADET_BLUE_1;
  943. }
  944. case '2':
  945. {
  946. idx += 12;
  947. return X11_CADET_BLUE_2;
  948. }
  949. case '3':
  950. {
  951. idx += 12;
  952. return X11_CADET_BLUE_3;
  953. }
  954. case '4':
  955. {
  956. idx += 12;
  957. return X11_CADET_BLUE_4;
  958. }
  959. }
  960. }
  961. }
  962. case '_' | 0x20:
  963. {
  964. switch (str[11] | 0x20)
  965. {
  966. case '1':
  967. {
  968. idx += 12;
  969. return X11_CADET_BLUE_1;
  970. }
  971. case '2':
  972. {
  973. idx += 12;
  974. return X11_CADET_BLUE_2;
  975. }
  976. case '3':
  977. {
  978. idx += 12;
  979. return X11_CADET_BLUE_3;
  980. }
  981. case '4':
  982. {
  983. idx += 12;
  984. return X11_CADET_BLUE_4;
  985. }
  986. }
  987. }
  988. }
  989. idx += 10;
  990. return X11_CADET_BLUE;
  991. }
  992. }
  993. case '_' | 0x20:
  994. {
  995. if (!str[6] || strcmp(str[6], !"BLUE", true, 4))
  996. {
  997. return -1;
  998. }
  999. switch (str[10] | 0x20)
  1000. {
  1001. case _X11_SPACE_SWITCH: // ' '
  1002. {
  1003. if (str[10])
  1004. {
  1005. switch (str[11] | 0x20)
  1006. {
  1007. case '1':
  1008. {
  1009. idx += 12;
  1010. return X11_CADET_BLUE_1;
  1011. }
  1012. case '2':
  1013. {
  1014. idx += 12;
  1015. return X11_CADET_BLUE_2;
  1016. }
  1017. case '3':
  1018. {
  1019. idx += 12;
  1020. return X11_CADET_BLUE_3;
  1021. }
  1022. case '4':
  1023. {
  1024. idx += 12;
  1025. return X11_CADET_BLUE_4;
  1026. }
  1027. }
  1028. }
  1029. }
  1030. case '_' | 0x20:
  1031. {
  1032. switch (str[11] | 0x20)
  1033. {
  1034. case '1':
  1035. {
  1036. idx += 12;
  1037. return X11_CADET_BLUE_1;
  1038. }
  1039. case '2':
  1040. {
  1041. idx += 12;
  1042. return X11_CADET_BLUE_2;
  1043. }
  1044. case '3':
  1045. {
  1046. idx += 12;
  1047. return X11_CADET_BLUE_3;
  1048. }
  1049. case '4':
  1050. {
  1051. idx += 12;
  1052. return X11_CADET_BLUE_4;
  1053. }
  1054. }
  1055. }
  1056. }
  1057. idx += 10;
  1058. return X11_CADET_BLUE;
  1059. }
  1060. case 'b':
  1061. {
  1062. if (!str[6] || strcmp(str[6], !"LUE", true, 3))
  1063. {
  1064. return -1;
  1065. }
  1066. switch (str[9] | 0x20)
  1067. {
  1068. case '1':
  1069. {
  1070. idx += 10;
  1071. return X11_CADETBLUE1;
  1072. }
  1073. case '2':
  1074. {
  1075. idx += 10;
  1076. return X11_CADETBLUE2;
  1077. }
  1078. case '3':
  1079. {
  1080. idx += 10;
  1081. return X11_CADETBLUE3;
  1082. }
  1083. case '4':
  1084. {
  1085. idx += 10;
  1086. return X11_CADETBLUE4;
  1087. }
  1088. }
  1089. idx += 9;
  1090. return X11_CADETBLUE;
  1091. }
  1092. }
  1093. }
  1094. case 'h':
  1095. {
  1096. switch (str[2] | 0x20)
  1097. {
  1098. case 'a':
  1099. {
  1100. if (!str[3] || strcmp(str[3], !"RTREUSE", true, 7))
  1101. {
  1102. return -1;
  1103. }
  1104. switch (str[10] | 0x20)
  1105. {
  1106. case _X11_SPACE_SWITCH: // ' '
  1107. {
  1108. if (str[10])
  1109. {
  1110. switch (str[11] | 0x20)
  1111. {
  1112. case '1':
  1113. {
  1114. idx += 12;
  1115. return X11_CHARTREUSE_1;
  1116. }
  1117. case '2':
  1118. {
  1119. idx += 12;
  1120. return X11_CHARTREUSE_2;
  1121. }
  1122. case '3':
  1123. {
  1124. idx += 12;
  1125. return X11_CHARTREUSE_3;
  1126. }
  1127. case '4':
  1128. {
  1129. idx += 12;
  1130. return X11_CHARTREUSE_4;
  1131. }
  1132. }
  1133. }
  1134. }
  1135. case '_' | 0x20:
  1136. {
  1137. switch (str[11] | 0x20)
  1138. {
  1139. case '1':
  1140. {
  1141. idx += 12;
  1142. return X11_CHARTREUSE_1;
  1143. }
  1144. case '2':
  1145. {
  1146. idx += 12;
  1147. return X11_CHARTREUSE_2;
  1148. }
  1149. case '3':
  1150. {
  1151. idx += 12;
  1152. return X11_CHARTREUSE_3;
  1153. }
  1154. case '4':
  1155. {
  1156. idx += 12;
  1157. return X11_CHARTREUSE_4;
  1158. }
  1159. }
  1160. }
  1161. case '1':
  1162. {
  1163. idx += 11;
  1164. return X11_CHARTREUSE1;
  1165. }
  1166. case '2':
  1167. {
  1168. idx += 11;
  1169. return X11_CHARTREUSE2;
  1170. }
  1171. case '3':
  1172. {
  1173. idx += 11;
  1174. return X11_CHARTREUSE3;
  1175. }
  1176. case '4':
  1177. {
  1178. idx += 11;
  1179. return X11_CHARTREUSE4;
  1180. }
  1181. }
  1182. idx += 10;
  1183. return X11_CHARTREUSE;
  1184. }
  1185. case 'o':
  1186. {
  1187. if (!str[3] || strcmp(str[3], !"COLATE", true, 6))
  1188. {
  1189. return -1;
  1190. }
  1191. switch (str[9] | 0x20)
  1192. {
  1193. case _X11_SPACE_SWITCH: // ' '
  1194. {
  1195. if (str[9])
  1196. {
  1197. switch (str[10] | 0x20)
  1198. {
  1199. case '1':
  1200. {
  1201. idx += 11;
  1202. return X11_CHOCOLATE_1;
  1203. }
  1204. case '2':
  1205. {
  1206. idx += 11;
  1207. return X11_CHOCOLATE_2;
  1208. }
  1209. case '3':
  1210. {
  1211. idx += 11;
  1212. return X11_CHOCOLATE_3;
  1213. }
  1214. case '4':
  1215. {
  1216. idx += 11;
  1217. return X11_CHOCOLATE_4;
  1218. }
  1219. }
  1220. }
  1221. }
  1222. case '_' | 0x20:
  1223. {
  1224. switch (str[10] | 0x20)
  1225. {
  1226. case '1':
  1227. {
  1228. idx += 11;
  1229. return X11_CHOCOLATE_1;
  1230. }
  1231. case '2':
  1232. {
  1233. idx += 11;
  1234. return X11_CHOCOLATE_2;
  1235. }
  1236. case '3':
  1237. {
  1238. idx += 11;
  1239. return X11_CHOCOLATE_3;
  1240. }
  1241. case '4':
  1242. {
  1243. idx += 11;
  1244. return X11_CHOCOLATE_4;
  1245. }
  1246. }
  1247. }
  1248. case '1':
  1249. {
  1250. idx += 10;
  1251. return X11_CHOCOLATE1;
  1252. }
  1253. case '2':
  1254. {
  1255. idx += 10;
  1256. return X11_CHOCOLATE2;
  1257. }
  1258. case '3':
  1259. {
  1260. idx += 10;
  1261. return X11_CHOCOLATE3;
  1262. }
  1263. case '4':
  1264. {
  1265. idx += 10;
  1266. return X11_CHOCOLATE4;
  1267. }
  1268. }
  1269. idx += 9;
  1270. return X11_CHOCOLATE;
  1271. }
  1272. }
  1273. }
  1274. case 'o':
  1275. {
  1276. if (str[2] | 0x20 != 'r')
  1277. {
  1278. return -1;
  1279. }
  1280. switch (str[3] | 0x20)
  1281. {
  1282. case 'a':
  1283. {
  1284. if (str[4] | 0x20 != 'l')
  1285. {
  1286. return -1;
  1287. }
  1288. switch (str[5] | 0x20)
  1289. {
  1290. case _X11_SPACE_SWITCH: // ' '
  1291. {
  1292. if (str[5])
  1293. {
  1294. switch (str[6] | 0x20)
  1295. {
  1296. case '1':
  1297. {
  1298. idx += 7;
  1299. return X11_CORAL_1;
  1300. }
  1301. case '2':
  1302. {
  1303. idx += 7;
  1304. return X11_CORAL_2;
  1305. }
  1306. case '3':
  1307. {
  1308. idx += 7;
  1309. return X11_CORAL_3;
  1310. }
  1311. case '4':
  1312. {
  1313. idx += 7;
  1314. return X11_CORAL_4;
  1315. }
  1316. }
  1317. }
  1318. }
  1319. case '_' | 0x20:
  1320. {
  1321. switch (str[6] | 0x20)
  1322. {
  1323. case '1':
  1324. {
  1325. idx += 7;
  1326. return X11_CORAL_1;
  1327. }
  1328. case '2':
  1329. {
  1330. idx += 7;
  1331. return X11_CORAL_2;
  1332. }
  1333. case '3':
  1334. {
  1335. idx += 7;
  1336. return X11_CORAL_3;
  1337. }
  1338. case '4':
  1339. {
  1340. idx += 7;
  1341. return X11_CORAL_4;
  1342. }
  1343. }
  1344. }
  1345. case '1':
  1346. {
  1347. idx += 6;
  1348. return X11_CORAL1;
  1349. }
  1350. case '2':
  1351. {
  1352. idx += 6;
  1353. return X11_CORAL2;
  1354. }
  1355. case '3':
  1356. {
  1357. idx += 6;
  1358. return X11_CORAL3;
  1359. }
  1360. case '4':
  1361. {
  1362. idx += 6;
  1363. return X11_CORAL4;
  1364. }
  1365. }
  1366. idx += 5;
  1367. return X11_CORAL;
  1368. }
  1369. case 'n':
  1370. {
  1371. switch (str[4] | 0x20)
  1372. {
  1373. case 'f':
  1374. {
  1375. if (!str[5] || strcmp(str[5], !"LOWER", true, 5))
  1376. {
  1377. return -1;
  1378. }
  1379. switch (str[10] | 0x20)
  1380. {
  1381. case _X11_SPACE_SWITCH: // ' '
  1382. {
  1383. if (str[10])
  1384. {
  1385. if (str[11] && !strcmp(str[11], !"BLUE", true, 4))
  1386. {
  1387. idx += 15;
  1388. return X11_CORNFLOWER_BLUE;
  1389. }
  1390. }
  1391. }
  1392. case '_' | 0x20:
  1393. {
  1394. if (str[11] && !strcmp(str[11], !"BLUE", true, 4))
  1395. {
  1396. idx += 15;
  1397. return X11_CORNFLOWER_BLUE;
  1398. }
  1399. }
  1400. case 'b':
  1401. {
  1402. if (str[11] && !strcmp(str[11], !"LUE", true, 3))
  1403. {
  1404. idx += 14;
  1405. return X11_CORNFLOWERBLUE;
  1406. }
  1407. }
  1408. }
  1409. }
  1410. case 's':
  1411. {
  1412. if (!str[5] || strcmp(str[5], !"ILK", true, 3))
  1413. {
  1414. return -1;
  1415. }
  1416. switch (str[8] | 0x20)
  1417. {
  1418. case _X11_SPACE_SWITCH: // ' '
  1419. {
  1420. if (str[8])
  1421. {
  1422. switch (str[9] | 0x20)
  1423. {
  1424. case '1':
  1425. {
  1426. idx += 10;
  1427. return X11_CORNSILK_1;
  1428. }
  1429. case '2':
  1430. {
  1431. idx += 10;
  1432. return X11_CORNSILK_2;
  1433. }
  1434. case '3':
  1435. {
  1436. idx += 10;
  1437. return X11_CORNSILK_3;
  1438. }
  1439. case '4':
  1440. {
  1441. idx += 10;
  1442. return X11_CORNSILK_4;
  1443. }
  1444. }
  1445. }
  1446. }
  1447. case '_' | 0x20:
  1448. {
  1449. switch (str[9] | 0x20)
  1450. {
  1451. case '1':
  1452. {
  1453. idx += 10;
  1454. return X11_CORNSILK_1;
  1455. }
  1456. case '2':
  1457. {
  1458. idx += 10;
  1459. return X11_CORNSILK_2;
  1460. }
  1461. case '3':
  1462. {
  1463. idx += 10;
  1464. return X11_CORNSILK_3;
  1465. }
  1466. case '4':
  1467. {
  1468. idx += 10;
  1469. return X11_CORNSILK_4;
  1470. }
  1471. }
  1472. }
  1473. case '1':
  1474. {
  1475. idx += 9;
  1476. return X11_CORNSILK1;
  1477. }
  1478. case '2':
  1479. {
  1480. idx += 9;
  1481. return X11_CORNSILK2;
  1482. }
  1483. case '3':
  1484. {
  1485. idx += 9;
  1486. return X11_CORNSILK3;
  1487. }
  1488. case '4':
  1489. {
  1490. idx += 9;
  1491. return X11_CORNSILK4;
  1492. }
  1493. }
  1494. idx += 8;
  1495. return X11_CORNSILK;
  1496. }
  1497. }
  1498. }
  1499. }
  1500. }
  1501. case 'y':
  1502. {
  1503. if (!str[2] || strcmp(str[2], !"AN", true, 2))
  1504. {
  1505. return -1;
  1506. }
  1507. switch (str[4] | 0x20)
  1508. {
  1509. case _X11_SPACE_SWITCH: // ' '
  1510. {
  1511. if (str[4])
  1512. {
  1513. switch (str[5] | 0x20)
  1514. {
  1515. case '1':
  1516. {
  1517. idx += 6;
  1518. return X11_CYAN_1;
  1519. }
  1520. case '2':
  1521. {
  1522. idx += 6;
  1523. return X11_CYAN_2;
  1524. }
  1525. case '3':
  1526. {
  1527. idx += 6;
  1528. return X11_CYAN_3;
  1529. }
  1530. case '4':
  1531. {
  1532. idx += 6;
  1533. return X11_CYAN_4;
  1534. }
  1535. }
  1536. }
  1537. }
  1538. case '_' | 0x20:
  1539. {
  1540. switch (str[5] | 0x20)
  1541. {
  1542. case '1':
  1543. {
  1544. idx += 6;
  1545. return X11_CYAN_1;
  1546. }
  1547. case '2':
  1548. {
  1549. idx += 6;
  1550. return X11_CYAN_2;
  1551. }
  1552. case '3':
  1553. {
  1554. idx += 6;
  1555. return X11_CYAN_3;
  1556. }
  1557. case '4':
  1558. {
  1559. idx += 6;
  1560. return X11_CYAN_4;
  1561. }
  1562. }
  1563. }
  1564. case '1':
  1565. {
  1566. idx += 5;
  1567. return X11_CYAN1;
  1568. }
  1569. case '2':
  1570. {
  1571. idx += 5;
  1572. return X11_CYAN2;
  1573. }
  1574. case '3':
  1575. {
  1576. idx += 5;
  1577. return X11_CYAN3;
  1578. }
  1579. case '4':
  1580. {
  1581. idx += 5;
  1582. return X11_CYAN4;
  1583. }
  1584. }
  1585. idx += 4;
  1586. return X11_CYAN;
  1587. }
  1588. }
  1589. }
  1590. case 'd':
  1591. {
  1592. switch (str[1] | 0x20)
  1593. {
  1594. case 'a':
  1595. {
  1596. if (!str[2] || strcmp(str[2], !"RK", true, 2))
  1597. {
  1598. return -1;
  1599. }
  1600. switch (str[4] | 0x20)
  1601. {
  1602. case _X11_SPACE_SWITCH: // ' '
  1603. {
  1604. if (str[4])
  1605. {
  1606. switch (str[5] | 0x20)
  1607. {
  1608. case 'b':
  1609. {
  1610. if (str[6] && !strcmp(str[6], !"LUE", true, 3))
  1611. {
  1612. idx += 9;
  1613. return X11_DARK_BLUE;
  1614. }
  1615. }
  1616. case 'c':
  1617. {
  1618. if (str[6] && !strcmp(str[6], !"YAN", true, 3))
  1619. {
  1620. idx += 9;
  1621. return X11_DARK_CYAN;
  1622. }
  1623. }
  1624. case 'g':
  1625. {
  1626. switch (str[6] | 0x20)
  1627. {
  1628. case 'o':
  1629. {
  1630. if (!str[7] || strcmp(str[7], !"LDENROD", true, 7))
  1631. {
  1632. return -1;
  1633. }
  1634. switch (str[14] | 0x20)
  1635. {
  1636. case _X11_SPACE_SWITCH: // ' '
  1637. {
  1638. if (str[14])
  1639. {
  1640. switch (str[15] | 0x20)
  1641. {
  1642. case '1':
  1643. {
  1644. idx += 16;
  1645. return X11_DARK_GOLDENROD_1;
  1646. }
  1647. case '2':
  1648. {
  1649. idx += 16;
  1650. return X11_DARK_GOLDENROD_2;
  1651. }
  1652. case '3':
  1653. {
  1654. idx += 16;
  1655. return X11_DARK_GOLDENROD_3;
  1656. }
  1657. case '4':
  1658. {
  1659. idx += 16;
  1660. return X11_DARK_GOLDENROD_4;
  1661. }
  1662. }
  1663. }
  1664. }
  1665. case '_' | 0x20:
  1666. {
  1667. switch (str[15] | 0x20)
  1668. {
  1669. case '1':
  1670. {
  1671. idx += 16;
  1672. return X11_DARK_GOLDENROD_1;
  1673. }
  1674. case '2':
  1675. {
  1676. idx += 16;
  1677. return X11_DARK_GOLDENROD_2;
  1678. }
  1679. case '3':
  1680. {
  1681. idx += 16;
  1682. return X11_DARK_GOLDENROD_3;
  1683. }
  1684. case '4':
  1685. {
  1686. idx += 16;
  1687. return X11_DARK_GOLDENROD_4;
  1688. }
  1689. }
  1690. }
  1691. }
  1692. idx += 14;
  1693. return X11_DARK_GOLDENROD;
  1694. }
  1695. case 'r':
  1696. {
  1697. switch (str[7] | 0x20)
  1698. {
  1699. case 'a':
  1700. {
  1701. if (str[8] | 0x20 == 'y')
  1702. {
  1703. idx += 9;
  1704. return X11_DARK_GRAY;
  1705. }
  1706. }
  1707. case 'e':
  1708. {
  1709. switch (str[8] | 0x20)
  1710. {
  1711. case 'e':
  1712. {
  1713. if (str[9] | 0x20 == 'n')
  1714. {
  1715. idx += 10;
  1716. return X11_DARK_GREEN;
  1717. }
  1718. }
  1719. case 'y':
  1720. {
  1721. idx += 9;
  1722. return X11_DARK_GREY;
  1723. }
  1724. }
  1725. }
  1726. }
  1727. }
  1728. }
  1729. }
  1730. case 'k':
  1731. {
  1732. if (str[6] && !strcmp(str[6], !"HAKI", true, 4))
  1733. {
  1734. idx += 10;
  1735. return X11_DARK_KHAKI;
  1736. }
  1737. }
  1738. case 'm':
  1739. {
  1740. if (str[6] && !strcmp(str[6], !"AGENTA", true, 6))
  1741. {
  1742. idx += 12;
  1743. return X11_DARK_MAGENTA;
  1744. }
  1745. }
  1746. case 'o':
  1747. {
  1748. switch (str[6] | 0x20)
  1749. {
  1750. case 'l':
  1751. {
  1752. if (!str[7] || strcmp(str[7], !"IVE", true, 3) || (!_X11_SPACE_CHECK(10) && str[10] != '_') || strcmp(str[11], !"GREEN", true, 5))
  1753. //if (!str[7] || strcmp(str[7], !"IVE_GREEN", true, 9))
  1754. {
  1755. return -1;
  1756. }
  1757. switch (str[16] | 0x20)
  1758. {
  1759. case _X11_SPACE_SWITCH: // ' '
  1760. {
  1761. if (str[16])
  1762. {
  1763. switch (str[17] | 0x20)
  1764. {
  1765. case '1':
  1766. {
  1767. idx += 18;
  1768. return X11_DARK_OLIVE_GREEN_1;
  1769. }
  1770. case '2':
  1771. {
  1772. idx += 18;
  1773. return X11_DARK_OLIVE_GREEN_2;
  1774. }
  1775. case '3':
  1776. {
  1777. idx += 18;
  1778. return X11_DARK_OLIVE_GREEN_3;
  1779. }
  1780. case '4':
  1781. {
  1782. idx += 18;
  1783. return X11_DARK_OLIVE_GREEN_4;
  1784. }
  1785. }
  1786. }
  1787. }
  1788. case '_' | 0x20:
  1789. {
  1790. switch (str[17] | 0x20)
  1791. {
  1792. case '1':
  1793. {
  1794. idx += 18;
  1795. return X11_DARK_OLIVE_GREEN_1;
  1796. }
  1797. case '2':
  1798. {
  1799. idx += 18;
  1800. return X11_DARK_OLIVE_GREEN_2;
  1801. }
  1802. case '3':
  1803. {
  1804. idx += 18;
  1805. return X11_DARK_OLIVE_GREEN_3;
  1806. }
  1807. case '4':
  1808. {
  1809. idx += 18;
  1810. return X11_DARK_OLIVE_GREEN_4;
  1811. }
  1812. }
  1813. }
  1814. }
  1815. idx += 16;
  1816. return X11_DARK_OLIVE_GREEN;
  1817. }
  1818. case 'r':
  1819. {
  1820. switch (str[7] | 0x20)
  1821. {
  1822. case 'a':
  1823. {
  1824. if (!str[8] || strcmp(str[8], !"NGE", true, 3))
  1825. {
  1826. return -1;
  1827. }
  1828. switch (str[11] | 0x20)
  1829. {
  1830. case _X11_SPACE_SWITCH: // ' '
  1831. {
  1832. if (str[11])
  1833. {
  1834. switch (str[12] | 0x20)
  1835. {
  1836. case '1':
  1837. {
  1838. idx += 13;
  1839. return X11_DARK_ORANGE_1;
  1840. }
  1841. case '2':
  1842. {
  1843. idx += 13;
  1844. return X11_DARK_ORANGE_2;
  1845. }
  1846. case '3':
  1847. {
  1848. idx += 13;
  1849. return X11_DARK_ORANGE_3;
  1850. }
  1851. case '4':
  1852. {
  1853. idx += 13;
  1854. return X11_DARK_ORANGE_4;
  1855. }
  1856. }
  1857. }
  1858. }
  1859. case '_' | 0x20:
  1860. {
  1861. switch (str[12] | 0x20)
  1862. {
  1863. case '1':
  1864. {
  1865. idx += 13;
  1866. return X11_DARK_ORANGE_1;
  1867. }
  1868. case '2':
  1869. {
  1870. idx += 13;
  1871. return X11_DARK_ORANGE_2;
  1872. }
  1873. case '3':
  1874. {
  1875. idx += 13;
  1876. return X11_DARK_ORANGE_3;
  1877. }
  1878. case '4':
  1879. {
  1880. idx += 13;
  1881. return X11_DARK_ORANGE_4;
  1882. }
  1883. }
  1884. }
  1885. }
  1886. idx += 11;
  1887. return X11_DARK_ORANGE;
  1888. }
  1889. case 'c':
  1890. {
  1891. if (!str[8] || strcmp(str[8], !"HID", true, 3))
  1892. {
  1893. return -1;
  1894. }
  1895. switch (str[11] | 0x20)
  1896. {
  1897. case _X11_SPACE_SWITCH: // ' '
  1898. {
  1899. if (str[11])
  1900. {
  1901. switch (str[12] | 0x20)
  1902. {
  1903. case '1':
  1904. {
  1905. idx += 13;
  1906. return X11_DARK_ORCHID_1;
  1907. }
  1908. case '2':
  1909. {
  1910. idx += 13;
  1911. return X11_DARK_ORCHID_2;
  1912. }
  1913. case '3':
  1914. {
  1915. idx += 13;
  1916. return X11_DARK_ORCHID_3;
  1917. }
  1918. case '4':
  1919. {
  1920. idx += 13;
  1921. return X11_DARK_ORCHID_4;
  1922. }
  1923. }
  1924. }
  1925. }
  1926. case '_' | 0x20:
  1927. {
  1928. switch (str[12] | 0x20)
  1929. {
  1930. case '1':
  1931. {
  1932. idx += 13;
  1933. return X11_DARK_ORCHID_1;
  1934. }
  1935. case '2':
  1936. {
  1937. idx += 13;
  1938. return X11_DARK_ORCHID_2;
  1939. }
  1940. case '3':
  1941. {
  1942. idx += 13;
  1943. return X11_DARK_ORCHID_3;
  1944. }
  1945. case '4':
  1946. {
  1947. idx += 13;
  1948. return X11_DARK_ORCHID_4;
  1949. }
  1950. }
  1951. }
  1952. }
  1953. idx += 11;
  1954. return X11_DARK_ORCHID;
  1955. }
  1956. }
  1957. }
  1958. }
  1959. }
  1960. case 'r':
  1961. {
  1962. if (str[6] && !strcmp(str[6], !"ED", true, 2))
  1963. {
  1964. idx += 8;
  1965. return X11_DARK_RED;
  1966. }
  1967. }
  1968. case 's':
  1969. {
  1970. switch (str[6] | 0x20)
  1971. {
  1972. case 'a':
  1973. {
  1974. if (str[7] && !strcmp(str[7], !"LMON", true, 4))
  1975. {
  1976. idx += 11;
  1977. return X11_DARK_SALMON;
  1978. }
  1979. }
  1980. case 'e':
  1981. {
  1982. if (str[7] | 0x20 != 'a' || (!_X11_SPACE_CHECK(8) && str[8] != '_') || strcmp(str[9], !"GREEN", true, 5))
  1983. //if (!str[7] || strcmp(str[7], !"A_GREEN", true, 7))
  1984. {
  1985. return -1;
  1986. }
  1987. switch (str[14] | 0x20)
  1988. {
  1989. case _X11_SPACE_SWITCH: // ' '
  1990. {
  1991. if (str[14])
  1992. {
  1993. switch (str[15] | 0x20)
  1994. {
  1995. case '1':
  1996. {
  1997. idx += 16;
  1998. return X11_DARK_SEA_GREEN_1;
  1999. }
  2000. case '2':
  2001. {
  2002. idx += 16;
  2003. return X11_DARK_SEA_GREEN_2;
  2004. }
  2005. case '3':
  2006. {
  2007. idx += 16;
  2008. return X11_DARK_SEA_GREEN_3;
  2009. }
  2010. case '4':
  2011. {
  2012. idx += 16;
  2013. return X11_DARK_SEA_GREEN_4;
  2014. }
  2015. }
  2016. }
  2017. }
  2018. case '_' | 0x20:
  2019. {
  2020. switch (str[15] | 0x20)
  2021. {
  2022. case '1':
  2023. {
  2024. idx += 16;
  2025. return X11_DARK_SEA_GREEN_1;
  2026. }
  2027. case '2':
  2028. {
  2029. idx += 16;
  2030. return X11_DARK_SEA_GREEN_2;
  2031. }
  2032. case '3':
  2033. {
  2034. idx += 16;
  2035. return X11_DARK_SEA_GREEN_3;
  2036. }
  2037. case '4':
  2038. {
  2039. idx += 16;
  2040. return X11_DARK_SEA_GREEN_4;
  2041. }
  2042. }
  2043. }
  2044. }
  2045. idx += 14;
  2046. return X11_DARK_SEA_GREEN;
  2047. }
  2048. case 'l':
  2049. {
  2050. if (!str[7] || strcmp(str[7], !"ATE", true, 3) || (!_X11_SPACE_CHECK(10) && str[10] != '_'))
  2051. //if (!str[7] || strcmp(str[7], !"ATE_", true, 4))
  2052. {
  2053. return -1;
  2054. }
  2055. switch (str[11] | 0x20)
  2056. {
  2057. case 'b':
  2058. {
  2059. if (str[12] && !strcmp(str[12], !"LUE", true, 3))
  2060. {
  2061. idx += 15;
  2062. return X11_DARK_SLATE_BLUE;
  2063. }
  2064. }
  2065. case 'g':
  2066. {
  2067. if (str[12] | 0x20 != 'r')
  2068. {
  2069. return -1;
  2070. }
  2071. switch (str[13] | 0x20)
  2072. {
  2073. case 'a':
  2074. {
  2075. if (str[14] | 0x20 != 'y')
  2076. {
  2077. return -1;
  2078. }
  2079. switch (str[15] | 0x20)
  2080. {
  2081. case _X11_SPACE_SWITCH: // ' '
  2082. {
  2083. if (str[15])
  2084. {
  2085. switch (str[16] | 0x20)
  2086. {
  2087. case '1':
  2088. {
  2089. idx += 17;
  2090. return X11_DARK_SLATE_GRAY_1;
  2091. }
  2092. case '2':
  2093. {
  2094. idx += 17;
  2095. return X11_DARK_SLATE_GRAY_2;
  2096. }
  2097. case '3':
  2098. {
  2099. idx += 17;
  2100. return X11_DARK_SLATE_GRAY_3;
  2101. }
  2102. case '4':
  2103. {
  2104. idx += 17;
  2105. return X11_DARK_SLATE_GRAY_4;
  2106. }
  2107. }
  2108. }
  2109. }
  2110. case '_' | 0x20:
  2111. {
  2112. switch (str[16] | 0x20)
  2113. {
  2114. case '1':
  2115. {
  2116. idx += 17;
  2117. return X11_DARK_SLATE_GRAY_1;
  2118. }
  2119. case '2':
  2120. {
  2121. idx += 17;
  2122. return X11_DARK_SLATE_GRAY_2;
  2123. }
  2124. case '3':
  2125. {
  2126. idx += 17;
  2127. return X11_DARK_SLATE_GRAY_3;
  2128. }
  2129. case '4':
  2130. {
  2131. idx += 17;
  2132. return X11_DARK_SLATE_GRAY_4;
  2133. }
  2134. }
  2135. }
  2136. }
  2137. idx += 15;
  2138. return X11_DARK_SLATE_GRAY;
  2139. }
  2140. case 'e':
  2141. {
  2142. if (str[14] | 0x20 != 'y')
  2143. {
  2144. return -1;
  2145. }
  2146. switch (str[15] | 0x20)
  2147. {
  2148. case _X11_SPACE_SWITCH: // ' '
  2149. {
  2150. if (str[15])
  2151. {
  2152. switch (str[16] | 0x20)
  2153. {
  2154. case '1':
  2155. {
  2156. idx += 17;
  2157. return X11_DARK_SLATE_GREY_1;
  2158. }
  2159. case '2':
  2160. {
  2161. idx += 17;
  2162. return X11_DARK_SLATE_GREY_2;
  2163. }
  2164. case '3':
  2165. {
  2166. idx += 17;
  2167. return X11_DARK_SLATE_GREY_3;
  2168. }
  2169. case '4':
  2170. {
  2171. idx += 17;
  2172. return X11_DARK_SLATE_GREY_4;
  2173. }
  2174. }
  2175. }
  2176. }
  2177. case '_' | 0x20:
  2178. {
  2179. switch (str[16] | 0x20)
  2180. {
  2181. case '1':
  2182. {
  2183. idx += 17;
  2184. return X11_DARK_SLATE_GREY_1;
  2185. }
  2186. case '2':
  2187. {
  2188. idx += 17;
  2189. return X11_DARK_SLATE_GREY_2;
  2190. }
  2191. case '3':
  2192. {
  2193. idx += 17;
  2194. return X11_DARK_SLATE_GREY_3;
  2195. }
  2196. case '4':
  2197. {
  2198. idx += 17;
  2199. return X11_DARK_SLATE_GREY_4;
  2200. }
  2201. }
  2202. }
  2203. }
  2204. idx += 15;
  2205. return X11_DARK_SLATE_GRAY;
  2206. }
  2207. }
  2208. }
  2209. }
  2210. }
  2211. }
  2212. }
  2213. case 't':
  2214. {
  2215. if (str[6] && !strcmp(str[6], !"URQUOISE", true, 8))
  2216. {
  2217. idx += 14;
  2218. return X11_DARK_TURQUOISE;
  2219. }
  2220. }
  2221. case 'v':
  2222. {
  2223. if (str[6] && !strcmp(str[6], !"IOLET", true, 5))
  2224. {
  2225. idx += 11;
  2226. return X11_DARK_VIOLET;
  2227. }
  2228. }
  2229. }
  2230. }
  2231. }
  2232. case '_' | 0x20:
  2233. {
  2234. switch (str[5] | 0x20)
  2235. {
  2236. case 'b':
  2237. {
  2238. if (str[6] && !strcmp(str[6], !"LUE", true, 3))
  2239. {
  2240. idx += 9;
  2241. return X11_DARK_BLUE;
  2242. }
  2243. }
  2244. case 'c':
  2245. {
  2246. if (str[6] && !strcmp(str[6], !"YAN", true, 3))
  2247. {
  2248. idx += 9;
  2249. return X11_DARK_CYAN;
  2250. }
  2251. }
  2252. case 'g':
  2253. {
  2254. switch (str[6] | 0x20)
  2255. {
  2256. case 'o':
  2257. {
  2258. if (!str[7] || strcmp(str[7], !"LDENROD", true, 7))
  2259. {
  2260. return -1;
  2261. }
  2262. switch (str[14] | 0x20)
  2263. {
  2264. case _X11_SPACE_SWITCH: // ' '
  2265. {
  2266. if (str[14])
  2267. {
  2268. switch (str[15] | 0x20)
  2269. {
  2270. case '1':
  2271. {
  2272. idx += 16;
  2273. return X11_DARK_GOLDENROD_1;
  2274. }
  2275. case '2':
  2276. {
  2277. idx += 16;
  2278. return X11_DARK_GOLDENROD_2;
  2279. }
  2280. case '3':
  2281. {
  2282. idx += 16;
  2283. return X11_DARK_GOLDENROD_3;
  2284. }
  2285. case '4':
  2286. {
  2287. idx += 16;
  2288. return X11_DARK_GOLDENROD_4;
  2289. }
  2290. }
  2291. }
  2292. }
  2293. case '_' | 0x20:
  2294. {
  2295. switch (str[15] | 0x20)
  2296. {
  2297. case '1':
  2298. {
  2299. idx += 16;
  2300. return X11_DARK_GOLDENROD_1;
  2301. }
  2302. case '2':
  2303. {
  2304. idx += 16;
  2305. return X11_DARK_GOLDENROD_2;
  2306. }
  2307. case '3':
  2308. {
  2309. idx += 16;
  2310. return X11_DARK_GOLDENROD_3;
  2311. }
  2312. case '4':
  2313. {
  2314. idx += 16;
  2315. return X11_DARK_GOLDENROD_4;
  2316. }
  2317. }
  2318. }
  2319. }
  2320. idx += 14;
  2321. return X11_DARK_GOLDENROD;
  2322. }
  2323. case 'r':
  2324. {
  2325. switch (str[7] | 0x20)
  2326. {
  2327. case 'a':
  2328. {
  2329. if (str[8] | 0x20 == 'y')
  2330. {
  2331. idx += 9;
  2332. return X11_DARK_GRAY;
  2333. }
  2334. }
  2335. case 'e':
  2336. {
  2337. switch (str[8] | 0x20)
  2338. {
  2339. case 'e':
  2340. {
  2341. if (str[9] | 0x20 == 'n')
  2342. {
  2343. idx += 10;
  2344. return X11_DARK_GREEN;
  2345. }
  2346. }
  2347. case 'y':
  2348. {
  2349. idx += 9;
  2350. return X11_DARK_GREY;
  2351. }
  2352. }
  2353. }
  2354. }
  2355. }
  2356. }
  2357. }
  2358. case 'k':
  2359. {
  2360. if (str[6] && !strcmp(str[6], !"HAKI", true, 4))
  2361. {
  2362. idx += 10;
  2363. return X11_DARK_KHAKI;
  2364. }
  2365. }
  2366. case 'm':
  2367. {
  2368. if (str[6] && !strcmp(str[6], !"AGENTA", true, 6))
  2369. {
  2370. idx += 12;
  2371. return X11_DARK_MAGENTA;
  2372. }
  2373. }
  2374. case 'o':
  2375. {
  2376. switch (str[6] | 0x20)
  2377. {
  2378. case 'l':
  2379. {
  2380. if (!str[7] || strcmp(str[7], !"IVE", true, 3) || (!_X11_SPACE_CHECK(10) && str[10] != '_') || strcmp(str[11], !"GREEN", true, 5))
  2381. {
  2382. return -1;
  2383. }
  2384. switch (str[16] | 0x20)
  2385. {
  2386. case _X11_SPACE_SWITCH: // ' '
  2387. {
  2388. if (str[16])
  2389. {
  2390. switch (str[17] | 0x20)
  2391. {
  2392. case '1':
  2393. {
  2394. idx += 18;
  2395. return X11_DARK_OLIVE_GREEN_1;
  2396. }
  2397. case '2':
  2398. {
  2399. idx += 18;
  2400. return X11_DARK_OLIVE_GREEN_2;
  2401. }
  2402. case '3':
  2403. {
  2404. idx += 18;
  2405. return X11_DARK_OLIVE_GREEN_3;
  2406. }
  2407. case '4':
  2408. {
  2409. idx += 18;
  2410. return X11_DARK_OLIVE_GREEN_4;
  2411. }
  2412. }
  2413. }
  2414. }
  2415. case '_' | 0x20:
  2416. {
  2417. switch (str[17] | 0x20)
  2418. {
  2419. case '1':
  2420. {
  2421. idx += 18;
  2422. return X11_DARK_OLIVE_GREEN_1;
  2423. }
  2424. case '2':
  2425. {
  2426. idx += 18;
  2427. return X11_DARK_OLIVE_GREEN_2;
  2428. }
  2429. case '3':
  2430. {
  2431. idx += 18;
  2432. return X11_DARK_OLIVE_GREEN_3;
  2433. }
  2434. case '4':
  2435. {
  2436. idx += 18;
  2437. return X11_DARK_OLIVE_GREEN_4;
  2438. }
  2439. }
  2440. }
  2441. }
  2442. idx += 16;
  2443. return X11_DARK_OLIVE_GREEN;
  2444. }
  2445. case 'r':
  2446. {
  2447. switch (str[7] | 0x20)
  2448. {
  2449. case 'a':
  2450. {
  2451. if (!str[8] || strcmp(str[8], !"NGE", true, 3))
  2452. {
  2453. return -1;
  2454. }
  2455. switch (str[11] | 0x20)
  2456. {
  2457. case _X11_SPACE_SWITCH: // ' '
  2458. {
  2459. if (str[11])
  2460. {
  2461. switch (str[12] | 0x20)
  2462. {
  2463. case '1':
  2464. {
  2465. idx += 13;
  2466. return X11_DARK_ORANGE_1;
  2467. }
  2468. case '2':
  2469. {
  2470. idx += 13;
  2471. return X11_DARK_ORANGE_2;
  2472. }
  2473. case '3':
  2474. {
  2475. idx += 13;
  2476. return X11_DARK_ORANGE_3;
  2477. }
  2478. case '4':
  2479. {
  2480. idx += 13;
  2481. return X11_DARK_ORANGE_4;
  2482. }
  2483. }
  2484. }
  2485. }
  2486. case '_' | 0x20:
  2487. {
  2488. switch (str[12] | 0x20)
  2489. {
  2490. case '1':
  2491. {
  2492. idx += 13;
  2493. return X11_DARK_ORANGE_1;
  2494. }
  2495. case '2':
  2496. {
  2497. idx += 13;
  2498. return X11_DARK_ORANGE_2;
  2499. }
  2500. case '3':
  2501. {
  2502. idx += 13;
  2503. return X11_DARK_ORANGE_3;
  2504. }
  2505. case '4':
  2506. {
  2507. idx += 13;
  2508. return X11_DARK_ORANGE_4;
  2509. }
  2510. }
  2511. }
  2512. }
  2513. idx += 11;
  2514. return X11_DARK_ORANGE;
  2515. }
  2516. case 'c':
  2517. {
  2518. if (!str[8] || strcmp(str[8], !"HID", true, 3))
  2519. {
  2520. return -1;
  2521. }
  2522. switch (str[11] | 0x20)
  2523. {
  2524. case _X11_SPACE_SWITCH: // ' '
  2525. {
  2526. if (str[11])
  2527. {
  2528. switch (str[12] | 0x20)
  2529. {
  2530. case '1':
  2531. {
  2532. idx += 13;
  2533. return X11_DARK_ORCHID_1;
  2534. }
  2535. case '2':
  2536. {
  2537. idx += 13;
  2538. return X11_DARK_ORCHID_2;
  2539. }
  2540. case '3':
  2541. {
  2542. idx += 13;
  2543. return X11_DARK_ORCHID_3;
  2544. }
  2545. case '4':
  2546. {
  2547. idx += 13;
  2548. return X11_DARK_ORCHID_4;
  2549. }
  2550. }
  2551. }
  2552. }
  2553. case '_' | 0x20:
  2554. {
  2555. switch (str[12] | 0x20)
  2556. {
  2557. case '1':
  2558. {
  2559. idx += 13;
  2560. return X11_DARK_ORCHID_1;
  2561. }
  2562. case '2':
  2563. {
  2564. idx += 13;
  2565. return X11_DARK_ORCHID_2;
  2566. }
  2567. case '3':
  2568. {
  2569. idx += 13;
  2570. return X11_DARK_ORCHID_3;
  2571. }
  2572. case '4':
  2573. {
  2574. idx += 13;
  2575. return X11_DARK_ORCHID_4;
  2576. }
  2577. }
  2578. }
  2579. }
  2580. idx += 11;
  2581. return X11_DARK_ORCHID;
  2582. }
  2583. }
  2584. }
  2585. }
  2586. }
  2587. case 'r':
  2588. {
  2589. if (str[6] && !strcmp(str[6], !"ED", true, 2))
  2590. {
  2591. idx += 8;
  2592. return X11_DARK_RED;
  2593. }
  2594. }
  2595. case 's':
  2596. {
  2597. switch (str[6] | 0x20)
  2598. {
  2599. case 'a':
  2600. {
  2601. if (str[7] && !strcmp(str[7], !"LMON", true, 4))
  2602. {
  2603. idx += 11;
  2604. return X11_DARK_SALMON;
  2605. }
  2606. }
  2607. case 'e':
  2608. {
  2609. //if (!str[7] || strcmp(str[7], !"A_GREEN", true, 7))
  2610. if (str[7] | 0x20 != 'a' || (!_X11_SPACE_CHECK(8) && str[8] != '_') || strcmp(str[9], !"GREEN", true, 5))
  2611. {
  2612. return -1;
  2613. }
  2614. switch (str[14] | 0x20)
  2615. {
  2616. case _X11_SPACE_SWITCH: // ' '
  2617. {
  2618. if (str[14])
  2619. {
  2620. switch (str[15] | 0x20)
  2621. {
  2622. case '1':
  2623. {
  2624. idx += 16;
  2625. return X11_DARK_SEA_GREEN_1;
  2626. }
  2627. case '2':
  2628. {
  2629. idx += 16;
  2630. return X11_DARK_SEA_GREEN_2;
  2631. }
  2632. case '3':
  2633. {
  2634. idx += 16;
  2635. return X11_DARK_SEA_GREEN_3;
  2636. }
  2637. case '4':
  2638. {
  2639. idx += 16;
  2640. return X11_DARK_SEA_GREEN_4;
  2641. }
  2642. }
  2643. }
  2644. }
  2645. case '_' | 0x20:
  2646. {
  2647. switch (str[15] | 0x20)
  2648. {
  2649. case '1':
  2650. {
  2651. idx += 16;
  2652. return X11_DARK_SEA_GREEN_1;
  2653. }
  2654. case '2':
  2655. {
  2656. idx += 16;
  2657. return X11_DARK_SEA_GREEN_2;
  2658. }
  2659. case '3':
  2660. {
  2661. idx += 16;
  2662. return X11_DARK_SEA_GREEN_3;
  2663. }
  2664. case '4':
  2665. {
  2666. idx += 16;
  2667. return X11_DARK_SEA_GREEN_4;
  2668. }
  2669. }
  2670. }
  2671. }
  2672. idx += 14;
  2673. return X11_DARK_SEA_GREEN;
  2674. }
  2675. case 'l':
  2676. {
  2677. //if (!str[7] || strcmp(str[7], !"ATE_", true, 4))
  2678. if (!str[7] || strcmp(str[7], !"ATE", true, 3) || (!_X11_SPACE_CHECK(10) && str[10] != '_'))
  2679. {
  2680. return -1;
  2681. }
  2682. switch (str[11] | 0x20)
  2683. {
  2684. case 'b':
  2685. {
  2686. if (str[12] && !strcmp(str[12], !"LUE", true, 3))
  2687. {
  2688. idx += 15;
  2689. return X11_DARK_SLATE_BLUE;
  2690. }
  2691. }
  2692. case 'g':
  2693. {
  2694. if (str[12] | 0x20 != 'r')
  2695. {
  2696. return -1;
  2697. }
  2698. switch (str[13] | 0x20)
  2699. {
  2700. case 'a':
  2701. {
  2702. if (str[14] | 0x20 != 'y')
  2703. {
  2704. return -1;
  2705. }
  2706. switch (str[15] | 0x20)
  2707. {
  2708. case _X11_SPACE_SWITCH: // ' '
  2709. {
  2710. if (str[15])
  2711. {
  2712. switch (str[16] | 0x20)
  2713. {
  2714. case '1':
  2715. {
  2716. idx += 17;
  2717. return X11_DARK_SLATE_GRAY_1;
  2718. }
  2719. case '2':
  2720. {
  2721. idx += 17;
  2722. return X11_DARK_SLATE_GRAY_2;
  2723. }
  2724. case '3':
  2725. {
  2726. idx += 17;
  2727. return X11_DARK_SLATE_GRAY_3;
  2728. }
  2729. case '4':
  2730. {
  2731. idx += 17;
  2732. return X11_DARK_SLATE_GRAY_4;
  2733. }
  2734. }
  2735. }
  2736. }
  2737. case '_' | 0x20:
  2738. {
  2739. switch (str[16] | 0x20)
  2740. {
  2741. case '1':
  2742. {
  2743. idx += 17;
  2744. return X11_DARK_SLATE_GRAY_1;
  2745. }
  2746. case '2':
  2747. {
  2748. idx += 17;
  2749. return X11_DARK_SLATE_GRAY_2;
  2750. }
  2751. case '3':
  2752. {
  2753. idx += 17;
  2754. return X11_DARK_SLATE_GRAY_3;
  2755. }
  2756. case '4':
  2757. {
  2758. idx += 17;
  2759. return X11_DARK_SLATE_GRAY_4;
  2760. }
  2761. }
  2762. }
  2763. }
  2764. idx += 15;
  2765. return X11_DARK_SLATE_GRAY;
  2766. }
  2767. case 'e':
  2768. {
  2769. if (str[14] | 0x20 != 'y')
  2770. {
  2771. return -1;
  2772. }
  2773. switch (str[15] | 0x20)
  2774. {
  2775. case _X11_SPACE_SWITCH: // ' '
  2776. {
  2777. if (str[15])
  2778. {
  2779. switch (str[16] | 0x20)
  2780. {
  2781. case '1':
  2782. {
  2783. idx += 17;
  2784. return X11_DARK_SLATE_GREY_1;
  2785. }
  2786. case '2':
  2787. {
  2788. idx += 17;
  2789. return X11_DARK_SLATE_GREY_2;
  2790. }
  2791. case '3':
  2792. {
  2793. idx += 17;
  2794. return X11_DARK_SLATE_GREY_3;
  2795. }
  2796. case '4':
  2797. {
  2798. idx += 17;
  2799. return X11_DARK_SLATE_GREY_4;
  2800. }
  2801. }
  2802. }
  2803. }
  2804. case '_' | 0x20:
  2805. {
  2806. switch (str[16] | 0x20)
  2807. {
  2808. case '1':
  2809. {
  2810. idx += 17;
  2811. return X11_DARK_SLATE_GREY_1;
  2812. }
  2813. case '2':
  2814. {
  2815. idx += 17;
  2816. return X11_DARK_SLATE_GREY_2;
  2817. }
  2818. case '3':
  2819. {
  2820. idx += 17;
  2821. return X11_DARK_SLATE_GREY_3;
  2822. }
  2823. case '4':
  2824. {
  2825. idx += 17;
  2826. return X11_DARK_SLATE_GREY_4;
  2827. }
  2828. }
  2829. }
  2830. }
  2831. idx += 15;
  2832. return X11_DARK_SLATE_GRAY;
  2833. }
  2834. }
  2835. }
  2836. }
  2837. }
  2838. }
  2839. }
  2840. case 't':
  2841. {
  2842. if (str[6] && !strcmp(str[6], !"URQUOISE", true, 8))
  2843. {
  2844. idx += 14;
  2845. return X11_DARK_TURQUOISE;
  2846. }
  2847. }
  2848. case 'v':
  2849. {
  2850. if (str[6] && !strcmp(str[6], !"IOLET", true, 5))
  2851. {
  2852. idx += 11;
  2853. return X11_DARK_VIOLET;
  2854. }
  2855. }
  2856. }
  2857. }
  2858. case 'b':
  2859. {
  2860. if (str[5] && !strcmp(str[5], !"LUE", true, 3))
  2861. {
  2862. idx += 8;
  2863. return X11_DARKBLUE;
  2864. }
  2865. }
  2866. case 'c':
  2867. {
  2868. if (str[5] && !strcmp(str[5], !"YAN", true, 3))
  2869. {
  2870. idx += 8;
  2871. return X11_DARKCYAN;
  2872. }
  2873. }
  2874. case 'g':
  2875. {
  2876. switch (str[5] | 0x20)
  2877. {
  2878. case 'o':
  2879. {
  2880. if (!str[6] || strcmp(str[6], !"LDENROD", true, 7))
  2881. {
  2882. return -1;
  2883. }
  2884. switch (str[13] | 0x20)
  2885. {
  2886. case '1':
  2887. {
  2888. idx += 14;
  2889. return X11_DARKGOLDENROD1;
  2890. }
  2891. case '2':
  2892. {
  2893. idx += 14;
  2894. return X11_DARKGOLDENROD2;
  2895. }
  2896. case '3':
  2897. {
  2898. idx += 14;
  2899. return X11_DARKGOLDENROD3;
  2900. }
  2901. case '4':
  2902. {
  2903. idx += 14;
  2904. return X11_DARKGOLDENROD4;
  2905. }
  2906. }
  2907. idx += 13;
  2908. return X11_DARKGOLDENROD;
  2909. }
  2910. case 'r':
  2911. {
  2912. switch (str[6] | 0x20)
  2913. {
  2914. case 'a':
  2915. {
  2916. if (str[7] | 0x20 == 'y')
  2917. {
  2918. idx += 8;
  2919. return X11_DARKGRAY;
  2920. }
  2921. }
  2922. case 'e':
  2923. {
  2924. switch (str[7] | 0x20)
  2925. {
  2926. case 'e':
  2927. {
  2928. if (str[8] | 0x20 == 'n')
  2929. {
  2930. idx += 9;
  2931. return X11_DARKGREEN;
  2932. }
  2933. }
  2934. case 'y':
  2935. {
  2936. idx += 8;
  2937. return X11_DARKGREY;
  2938. }
  2939. }
  2940. }
  2941. }
  2942. }
  2943. }
  2944. }
  2945. case 'k':
  2946. {
  2947. if (str[5] && !strcmp(str[5], !"HAKI", true, 4))
  2948. {
  2949. idx += 9;
  2950. return X11_DARKKHAKI;
  2951. }
  2952. }
  2953. case 'm':
  2954. {
  2955. if (str[5] && !strcmp(str[5], !"AGENTA", true, 6))
  2956. {
  2957. idx += 11;
  2958. return X11_DARKMAGENTA;
  2959. }
  2960. }
  2961. case 'o':
  2962. {
  2963. switch (str[5] | 0x20)
  2964. {
  2965. case 'l':
  2966. {
  2967. if (!str[6] || strcmp(str[6], !"IVEGREEN", true, 8))
  2968. {
  2969. return -1;
  2970. }
  2971. switch (str[14] | 0x20)
  2972. {
  2973. case '1':
  2974. {
  2975. idx += 15;
  2976. return X11_DARKOLIVEGREEN1;
  2977. }
  2978. case '2':
  2979. {
  2980. idx += 15;
  2981. return X11_DARKOLIVEGREEN2;
  2982. }
  2983. case '3':
  2984. {
  2985. idx += 15;
  2986. return X11_DARKOLIVEGREEN3;
  2987. }
  2988. case '4':
  2989. {
  2990. idx += 15;
  2991. return X11_DARKOLIVEGREEN4;
  2992. }
  2993. }
  2994. idx += 14;
  2995. return X11_DARKOLIVEGREEN;
  2996. }
  2997. case 'r':
  2998. {
  2999. switch (str[6] | 0x20)
  3000. {
  3001. case 'a':
  3002. {
  3003. if (!str[7] || strcmp(str[7], !"NGE", true, 3))
  3004. {
  3005. return -1;
  3006. }
  3007. switch (str[10] | 0x20)
  3008. {
  3009. case '1':
  3010. {
  3011. idx += 11;
  3012. return X11_DARKORANGE1;
  3013. }
  3014. case '2':
  3015. {
  3016. idx += 11;
  3017. return X11_DARKORANGE2;
  3018. }
  3019. case '3':
  3020. {
  3021. idx += 11;
  3022. return X11_DARKORANGE3;
  3023. }
  3024. case '4':
  3025. {
  3026. idx += 11;
  3027. return X11_DARKORANGE4;
  3028. }
  3029. }
  3030. idx += 10;
  3031. return X11_DARKORANGE;
  3032. }
  3033. case 'c':
  3034. {
  3035. if (!str[7] || strcmp(str[7], !"HID", true, 3))
  3036. {
  3037. return -1;
  3038. }
  3039. switch (str[10] | 0x20)
  3040. {
  3041. case '1':
  3042. {
  3043. idx += 11;
  3044. return X11_DARKORCHID1;
  3045. }
  3046. case '2':
  3047. {
  3048. idx += 11;
  3049. return X11_DARKORCHID2;
  3050. }
  3051. case '3':
  3052. {
  3053. idx += 11;
  3054. return X11_DARKORCHID3;
  3055. }
  3056. case '4':
  3057. {
  3058. idx += 11;
  3059. return X11_DARKORCHID4;
  3060. }
  3061. }
  3062. idx += 10;
  3063. return X11_DARKORCHID;
  3064. }
  3065. }
  3066. }
  3067. }
  3068. }
  3069. case 'r':
  3070. {
  3071. if (str[5] && !strcmp(str[5], !"ED", true, 2))
  3072. {
  3073. idx += 7;
  3074. return X11_DARKRED;
  3075. }
  3076. }
  3077. case 's':
  3078. {
  3079. switch (str[5] | 0x20)
  3080. {
  3081. case 'a':
  3082. {
  3083. if (str[6] && !strcmp(str[6], !"LMON", true, 4))
  3084. {
  3085. idx += 10;
  3086. return X11_DARKSALMON;
  3087. }
  3088. }
  3089. case 'e':
  3090. {
  3091. if (!str[6] || strcmp(str[6], !"AGREEN", true, 6))
  3092. {
  3093. return -1;
  3094. }
  3095. switch (str[12] | 0x20)
  3096. {
  3097. case '1':
  3098. {
  3099. idx += 13;
  3100. return X11_DARKSEAGREEN1;
  3101. }
  3102. case '2':
  3103. {
  3104. idx += 13;
  3105. return X11_DARKSEAGREEN2;
  3106. }
  3107. case '3':
  3108. {
  3109. idx += 13;
  3110. return X11_DARKSEAGREEN3;
  3111. }
  3112. case '4':
  3113. {
  3114. idx += 13;
  3115. return X11_DARKSEAGREEN4;
  3116. }
  3117. }
  3118. idx += 12;
  3119. return X11_DARKSEAGREEN;
  3120. }
  3121. case 'l':
  3122. {
  3123. if (!str[6] || strcmp(str[6], !"ATE", true, 3))
  3124. {
  3125. return -1;
  3126. }
  3127. switch (str[9] | 0x20)
  3128. {
  3129. case 'b':
  3130. {
  3131. if (str[10] && !strcmp(str[10], !"LUE", true, 3))
  3132. {
  3133. idx += 13;
  3134. return X11_DARKSLATEBLUE;
  3135. }
  3136. }
  3137. case 'g':
  3138. {
  3139. if (str[10] | 0x20 != 'r')
  3140. {
  3141. return -1;
  3142. }
  3143. switch (str[11] | 0x20)
  3144. {
  3145. case 'a':
  3146. {
  3147. if (str[12] | 0x20 != 'y')
  3148. {
  3149. return -1;
  3150. }
  3151. switch (str[13] | 0x20)
  3152. {
  3153. case '1':
  3154. {
  3155. idx += 14;
  3156. return X11_DARKSLATEGRAY1;
  3157. }
  3158. case '2':
  3159. {
  3160. idx += 14;
  3161. return X11_DARKSLATEGRAY2;
  3162. }
  3163. case '3':
  3164. {
  3165. idx += 14;
  3166. return X11_DARKSLATEGRAY3;
  3167. }
  3168. case '4':
  3169. {
  3170. idx += 14;
  3171. return X11_DARKSLATEGRAY4;
  3172. }
  3173. }
  3174. idx += 13;
  3175. return X11_DARKSLATEGRAY;
  3176. }
  3177. case 'e':
  3178. {
  3179. if (str[12] | 0x20 != 'y')
  3180. {
  3181. return -1;
  3182. }
  3183. switch (str[13] | 0x20)
  3184. {
  3185. case '1':
  3186. {
  3187. idx += 14;
  3188. return X11_DARKSLATEGREY1;
  3189. }
  3190. case '2':
  3191. {
  3192. idx += 14;
  3193. return X11_DARKSLATEGREY2;
  3194. }
  3195. case '3':
  3196. {
  3197. idx += 14;
  3198. return X11_DARKSLATEGREY3;
  3199. }
  3200. case '4':
  3201. {
  3202. idx += 14;
  3203. return X11_DARKSLATEGREY4;
  3204. }
  3205. }
  3206. idx += 13;
  3207. return X11_DARKSLATEGREY;
  3208. }
  3209. }
  3210. }
  3211. }
  3212. }
  3213. }
  3214. }
  3215. case 't':
  3216. {
  3217. if (str[5] && !strcmp(str[5], !"URQUOISE", true, 8))
  3218. {
  3219. idx += 13;
  3220. return X11_DARKTURQUOISE;
  3221. }
  3222. }
  3223. case 'v':
  3224. {
  3225. if (str[5] && !strcmp(str[5], !"IOLET", true, 5))
  3226. {
  3227. idx += 10;
  3228. return X11_DARKVIOLET;
  3229. }
  3230. }
  3231. }
  3232. }
  3233. case 'e':
  3234. {
  3235. if (!str[2] || strcmp(str[2], !"EP", true, 2))
  3236. {
  3237. return -1;
  3238. }
  3239. switch (str[4] | 0x20)
  3240. {
  3241. case _X11_SPACE_SWITCH: // ' '
  3242. {
  3243. if (str[4])
  3244. {
  3245. switch (str[5] | 0x20)
  3246. {
  3247. case 'p':
  3248. {
  3249. if (!str[6] || strcmp(str[6], !"INK", true, 3))
  3250. {
  3251. return -1;
  3252. }
  3253. switch (str[9] | 0x20)
  3254. {
  3255. case _X11_SPACE_SWITCH: // ' '
  3256. {
  3257. if (str[9])
  3258. {
  3259. switch (str[10] | 0x20)
  3260. {
  3261. case '1':
  3262. {
  3263. idx += 11;
  3264. return X11_DEEP_PINK_1;
  3265. }
  3266. case '2':
  3267. {
  3268. idx += 11;
  3269. return X11_DEEP_PINK_2;
  3270. }
  3271. case '3':
  3272. {
  3273. idx += 11;
  3274. return X11_DEEP_PINK_3;
  3275. }
  3276. case '4':
  3277. {
  3278. idx += 11;
  3279. return X11_DEEP_PINK_4;
  3280. }
  3281. }
  3282. }
  3283. }
  3284. case '_' | 0x20:
  3285. {
  3286. switch (str[10] | 0x20)
  3287. {
  3288. case '1':
  3289. {
  3290. idx += 11;
  3291. return X11_DEEP_PINK_1;
  3292. }
  3293. case '2':
  3294. {
  3295. idx += 11;
  3296. return X11_DEEP_PINK_2;
  3297. }
  3298. case '3':
  3299. {
  3300. idx += 11;
  3301. return X11_DEEP_PINK_3;
  3302. }
  3303. case '4':
  3304. {
  3305. idx += 11;
  3306. return X11_DEEP_PINK_4;
  3307. }
  3308. }
  3309. }
  3310. }
  3311. idx += 9;
  3312. return X11_DEEP_PINK;
  3313. }
  3314. case 's':
  3315. {
  3316. //if (!str[6] || strcmp(str[6], !"KY_BLUE", true, 7))
  3317. if (!str[6] || strcmp(str[6], !"KY", true, 2) || (!_X11_SPACE_CHECK(8) && str[8] != '_') || strcmp(str[9], !"BLUE", true, 4))
  3318. {
  3319. return -1;
  3320. }
  3321. switch (str[13] | 0x20)
  3322. {
  3323. case _X11_SPACE_SWITCH: // ' '
  3324. {
  3325. if (str[13])
  3326. {
  3327. switch (str[14] | 0x20)
  3328. {
  3329. case '1':
  3330. {
  3331. idx += 15;
  3332. return X11_DEEP_SKY_BLUE_1;
  3333. }
  3334. case '2':
  3335. {
  3336. idx += 15;
  3337. return X11_DEEP_SKY_BLUE_2;
  3338. }
  3339. case '3':
  3340. {
  3341. idx += 15;
  3342. return X11_DEEP_SKY_BLUE_3;
  3343. }
  3344. case '4':
  3345. {
  3346. idx += 15;
  3347. return X11_DEEP_SKY_BLUE_4;
  3348. }
  3349. }
  3350. }
  3351. }
  3352. case '_' | 0x20:
  3353. {
  3354. switch (str[14] | 0x20)
  3355. {
  3356. case '1':
  3357. {
  3358. idx += 15;
  3359. return X11_DEEP_SKY_BLUE_1;
  3360. }
  3361. case '2':
  3362. {
  3363. idx += 15;
  3364. return X11_DEEP_SKY_BLUE_2;
  3365. }
  3366. case '3':
  3367. {
  3368. idx += 15;
  3369. return X11_DEEP_SKY_BLUE_3;
  3370. }
  3371. case '4':
  3372. {
  3373. idx += 15;
  3374. return X11_DEEP_SKY_BLUE_4;
  3375. }
  3376. }
  3377. }
  3378. }
  3379. idx += 13;
  3380. return X11_DEEP_SKY_BLUE;
  3381. }
  3382. }
  3383. }
  3384. }
  3385. case '_' | 0x20:
  3386. {
  3387. switch (str[5] | 0x20)
  3388. {
  3389. case 'p':
  3390. {
  3391. if (!str[6] || strcmp(str[6], !"INK", true, 3))
  3392. {
  3393. return -1;
  3394. }
  3395. switch (str[9] | 0x20)
  3396. {
  3397. case _X11_SPACE_SWITCH: // ' '
  3398. {
  3399. if (str[9])
  3400. {
  3401. switch (str[10] | 0x20)
  3402. {
  3403. case '1':
  3404. {
  3405. idx += 11;
  3406. return X11_DEEP_PINK_1;
  3407. }
  3408. case '2':
  3409. {
  3410. idx += 11;
  3411. return X11_DEEP_PINK_2;
  3412. }
  3413. case '3':
  3414. {
  3415. idx += 11;
  3416. return X11_DEEP_PINK_3;
  3417. }
  3418. case '4':
  3419. {
  3420. idx += 11;
  3421. return X11_DEEP_PINK_4;
  3422. }
  3423. }
  3424. }
  3425. }
  3426. case '_' | 0x20:
  3427. {
  3428. switch (str[10] | 0x20)
  3429. {
  3430. case '1':
  3431. {
  3432. idx += 11;
  3433. return X11_DEEP_PINK_1;
  3434. }
  3435. case '2':
  3436. {
  3437. idx += 11;
  3438. return X11_DEEP_PINK_2;
  3439. }
  3440. case '3':
  3441. {
  3442. idx += 11;
  3443. return X11_DEEP_PINK_3;
  3444. }
  3445. case '4':
  3446. {
  3447. idx += 11;
  3448. return X11_DEEP_PINK_4;
  3449. }
  3450. }
  3451. }
  3452. }
  3453. idx += 9;
  3454. return X11_DEEP_PINK;
  3455. }
  3456. case 's':
  3457. {
  3458. //if (!str[6] || strcmp(str[6], !"KY_BLUE", true, 7))
  3459. if (!str[6] || strcmp(str[6], !"KY", true, 2) || (!_X11_SPACE_CHECK(8) && str[8] != '_') || strcmp(str[9], !"BLUE", true, 4))
  3460. {
  3461. return -1;
  3462. }
  3463. switch (str[13] | 0x20)
  3464. {
  3465. case _X11_SPACE_SWITCH: // ' '
  3466. {
  3467. if (str[13])
  3468. {
  3469. switch (str[14] | 0x20)
  3470. {
  3471. case '1':
  3472. {
  3473. idx += 15;
  3474. return X11_DEEP_SKY_BLUE_1;
  3475. }
  3476. case '2':
  3477. {
  3478. idx += 15;
  3479. return X11_DEEP_SKY_BLUE_2;
  3480. }
  3481. case '3':
  3482. {
  3483. idx += 15;
  3484. return X11_DEEP_SKY_BLUE_3;
  3485. }
  3486. case '4':
  3487. {
  3488. idx += 15;
  3489. return X11_DEEP_SKY_BLUE_4;
  3490. }
  3491. }
  3492. }
  3493. }
  3494. case '_' | 0x20:
  3495. {
  3496. switch (str[14] | 0x20)
  3497. {
  3498. case '1':
  3499. {
  3500. idx += 15;
  3501. return X11_DEEP_SKY_BLUE_1;
  3502. }
  3503. case '2':
  3504. {
  3505. idx += 15;
  3506. return X11_DEEP_SKY_BLUE_2;
  3507. }
  3508. case '3':
  3509. {
  3510. idx += 15;
  3511. return X11_DEEP_SKY_BLUE_3;
  3512. }
  3513. case '4':
  3514. {
  3515. idx += 15;
  3516. return X11_DEEP_SKY_BLUE_4;
  3517. }
  3518. }
  3519. }
  3520. }
  3521. idx += 13;
  3522. return X11_DEEP_SKY_BLUE;
  3523. }
  3524. }
  3525. }
  3526. case 'p':
  3527. {
  3528. if (!str[5] || strcmp(str[5], !"INK", true, 3))
  3529. {
  3530. return -1;
  3531. }
  3532. switch (str[8] | 0x20)
  3533. {
  3534. case '1':
  3535. {
  3536. idx += 9;
  3537. return X11_DEEPPINK1;
  3538. }
  3539. case '2':
  3540. {
  3541. idx += 9;
  3542. return X11_DEEPPINK2;
  3543. }
  3544. case '3':
  3545. {
  3546. idx += 9;
  3547. return X11_DEEPPINK3;
  3548. }
  3549. case '4':
  3550. {
  3551. idx += 9;
  3552. return X11_DEEPPINK4;
  3553. }
  3554. }
  3555. idx += 8;
  3556. return X11_DEEPPINK;
  3557. }
  3558. case 's':
  3559. {
  3560. if (!str[5] || strcmp(str[5], !"KYBLUE", true, 6))
  3561. {
  3562. return -1;
  3563. }
  3564. switch (str[11] | 0x20)
  3565. {
  3566. case '1':
  3567. {
  3568. idx += 12;
  3569. return X11_DEEPSKYBLUE1;
  3570. }
  3571. case '2':
  3572. {
  3573. idx += 12;
  3574. return X11_DEEPSKYBLUE2;
  3575. }
  3576. case '3':
  3577. {
  3578. idx += 12;
  3579. return X11_DEEPSKYBLUE3;
  3580. }
  3581. case '4':
  3582. {
  3583. idx += 12;
  3584. return X11_DEEPSKYBLUE4;
  3585. }
  3586. }
  3587. idx += 11;
  3588. return X11_DEEPSKYBLUE;
  3589. }
  3590. }
  3591. }
  3592. case 'i':
  3593. {
  3594. if (str[2] | 0x20 != 'm')
  3595. {
  3596. return -1;
  3597. }
  3598. switch (str[3] | 0x20)
  3599. {
  3600. case _X11_SPACE_SWITCH: // ' '
  3601. {
  3602. if (str[3])
  3603. {
  3604. if (!str[4] || strcmp(str[4], !"GR", true, 2))
  3605. {
  3606. return -1;
  3607. }
  3608. switch (str[6] | 0x20)
  3609. {
  3610. case 'a':
  3611. {
  3612. if (str[7] | 0x20 == 'y')
  3613. {
  3614. idx += 8;
  3615. return X11_DIM_GRAY;
  3616. }
  3617. }
  3618. case 'e':
  3619. {
  3620. if (str[7] | 0x20 == 'y')
  3621. {
  3622. idx += 8;
  3623. return X11_DIM_GREY;
  3624. }
  3625. }
  3626. }
  3627. }
  3628. }
  3629. case '_' | 0x20:
  3630. {
  3631. if (!str[4] || strcmp(str[4], !"GR", true, 2))
  3632. {
  3633. return -1;
  3634. }
  3635. switch (str[6] | 0x20)
  3636. {
  3637. case 'a':
  3638. {
  3639. if (str[7] | 0x20 == 'y')
  3640. {
  3641. idx += 8;
  3642. return X11_DIM_GRAY;
  3643. }
  3644. }
  3645. case 'e':
  3646. {
  3647. if (str[7] | 0x20 == 'y')
  3648. {
  3649. idx += 8;
  3650. return X11_DIM_GREY;
  3651. }
  3652. }
  3653. }
  3654. }
  3655. case 'g':
  3656. {
  3657. if (str[4] | 0x20 != 'r')
  3658. {
  3659. return -1;
  3660. }
  3661. switch (str[5] | 0x20)
  3662. {
  3663. case 'a':
  3664. {
  3665. if (str[6] | 0x20 == 'y')
  3666. {
  3667. idx += 7;
  3668. return X11_DIMGRAY;
  3669. }
  3670. }
  3671. case 'e':
  3672. {
  3673. if (str[6] | 0x20 == 'y')
  3674. {
  3675. idx += 7;
  3676. return X11_DIMGREY;
  3677. }
  3678. }
  3679. }
  3680. }
  3681. }
  3682. }
  3683. case 'o':
  3684. {
  3685. if (!str[2] || strcmp(str[2], !"DGER", true, 4))
  3686. {
  3687. return -1;
  3688. }
  3689. switch (str[6] | 0x20)
  3690. {
  3691. case _X11_SPACE_SWITCH: // ' '
  3692. {
  3693. if (str[6])
  3694. {
  3695. if (!str[7] || strcmp(str[7], !"BLUE", true, 4))
  3696. {
  3697. return -1;
  3698. }
  3699. switch (str[11] | 0x20)
  3700. {
  3701. case _X11_SPACE_SWITCH: // ' '
  3702. {
  3703. if (str[11])
  3704. {
  3705. switch (str[12] | 0x20)
  3706. {
  3707. case '1':
  3708. {
  3709. idx += 13;
  3710. return X11_DODGER_BLUE_1;
  3711. }
  3712. case '2':
  3713. {
  3714. idx += 13;
  3715. return X11_DODGER_BLUE_2;
  3716. }
  3717. case '3':
  3718. {
  3719. idx += 13;
  3720. return X11_DODGER_BLUE_3;
  3721. }
  3722. case '4':
  3723. {
  3724. idx += 13;
  3725. return X11_DODGER_BLUE_4;
  3726. }
  3727. }
  3728. }
  3729. }
  3730. case '_' | 0x20:
  3731. {
  3732. switch (str[12] | 0x20)
  3733. {
  3734. case '1':
  3735. {
  3736. idx += 13;
  3737. return X11_DODGER_BLUE_1;
  3738. }
  3739. case '2':
  3740. {
  3741. idx += 13;
  3742. return X11_DODGER_BLUE_2;
  3743. }
  3744. case '3':
  3745. {
  3746. idx += 13;
  3747. return X11_DODGER_BLUE_3;
  3748. }
  3749. case '4':
  3750. {
  3751. idx += 13;
  3752. return X11_DODGER_BLUE_4;
  3753. }
  3754. }
  3755. }
  3756. }
  3757. idx += 11;
  3758. return X11_DODGER_BLUE;
  3759. }
  3760. }
  3761. case '_' | 0x20:
  3762. {
  3763. if (!str[7] || strcmp(str[7], !"BLUE", true, 4))
  3764. {
  3765. return -1;
  3766. }
  3767. switch (str[11] | 0x20)
  3768. {
  3769. case _X11_SPACE_SWITCH: // ' '
  3770. {
  3771. if (str[11])
  3772. {
  3773. switch (str[12] | 0x20)
  3774. {
  3775. case '1':
  3776. {
  3777. idx += 13;
  3778. return X11_DODGER_BLUE_1;
  3779. }
  3780. case '2':
  3781. {
  3782. idx += 13;
  3783. return X11_DODGER_BLUE_2;
  3784. }
  3785. case '3':
  3786. {
  3787. idx += 13;
  3788. return X11_DODGER_BLUE_3;
  3789. }
  3790. case '4':
  3791. {
  3792. idx += 13;
  3793. return X11_DODGER_BLUE_4;
  3794. }
  3795. }
  3796. }
  3797. }
  3798. case '_' | 0x20:
  3799. {
  3800. switch (str[12] | 0x20)
  3801. {
  3802. case '1':
  3803. {
  3804. idx += 13;
  3805. return X11_DODGER_BLUE_1;
  3806. }
  3807. case '2':
  3808. {
  3809. idx += 13;
  3810. return X11_DODGER_BLUE_2;
  3811. }
  3812. case '3':
  3813. {
  3814. idx += 13;
  3815. return X11_DODGER_BLUE_3;
  3816. }
  3817. case '4':
  3818. {
  3819. idx += 13;
  3820. return X11_DODGER_BLUE_4;
  3821. }
  3822. }
  3823. }
  3824. }
  3825. idx += 11;
  3826. return X11_DODGER_BLUE;
  3827. }
  3828. case 'b':
  3829. {
  3830. if (!str[7] || strcmp(str[7], !"LUE", true, 3))
  3831. {
  3832. return -1;
  3833. }
  3834. switch (str[10] | 0x20)
  3835. {
  3836. case '1':
  3837. {
  3838. idx += 11;
  3839. return X11_DODGERBLUE1;
  3840. }
  3841. case '2':
  3842. {
  3843. idx += 11;
  3844. return X11_DODGERBLUE2;
  3845. }
  3846. case '3':
  3847. {
  3848. idx += 11;
  3849. return X11_DODGERBLUE3;
  3850. }
  3851. case '4':
  3852. {
  3853. idx += 11;
  3854. return X11_DODGERBLUE4;
  3855. }
  3856. }
  3857. idx += 10;
  3858. return X11_DODGERBLUE;
  3859. }
  3860. }
  3861. }
  3862. }
  3863. }
  3864. case 'f':
  3865. {
  3866. switch (str[1] | 0x20)
  3867. {
  3868. case 'i':
  3869. {
  3870. if (!str[2] || strcmp(str[2], !"REBRICK", true, 7))
  3871. {
  3872. return -1;
  3873. }
  3874. switch (str[9] | 0x20)
  3875. {
  3876. case _X11_SPACE_SWITCH: // ' '
  3877. {
  3878. if (str[9])
  3879. {
  3880. switch (str[10] | 0x20)
  3881. {
  3882. case '1':
  3883. {
  3884. idx += 11;
  3885. return X11_FIREBRICK_1;
  3886. }
  3887. case '2':
  3888. {
  3889. idx += 11;
  3890. return X11_FIREBRICK_2;
  3891. }
  3892. case '3':
  3893. {
  3894. idx += 11;
  3895. return X11_FIREBRICK_3;
  3896. }
  3897. case '4':
  3898. {
  3899. idx += 11;
  3900. return X11_FIREBRICK_4;
  3901. }
  3902. }
  3903. }
  3904. }
  3905. case '_' | 0x20:
  3906. {
  3907. switch (str[10] | 0x20)
  3908. {
  3909. case '1':
  3910. {
  3911. idx += 11;
  3912. return X11_FIREBRICK_1;
  3913. }
  3914. case '2':
  3915. {
  3916. idx += 11;
  3917. return X11_FIREBRICK_2;
  3918. }
  3919. case '3':
  3920. {
  3921. idx += 11;
  3922. return X11_FIREBRICK_3;
  3923. }
  3924. case '4':
  3925. {
  3926. idx += 11;
  3927. return X11_FIREBRICK_4;
  3928. }
  3929. }
  3930. }
  3931. case '1':
  3932. {
  3933. idx += 10;
  3934. return X11_FIREBRICK1;
  3935. }
  3936. case '2':
  3937. {
  3938. idx += 10;
  3939. return X11_FIREBRICK2;
  3940. }
  3941. case '3':
  3942. {
  3943. idx += 10;
  3944. return X11_FIREBRICK3;
  3945. }
  3946. case '4':
  3947. {
  3948. idx += 10;
  3949. return X11_FIREBRICK4;
  3950. }
  3951. }
  3952. idx += 9;
  3953. return X11_FIREBRICK;
  3954. }
  3955. case 'l':
  3956. {
  3957. if (!str[2] || strcmp(str[2], !"ORAL", true, 4))
  3958. {
  3959. return -1;
  3960. }
  3961. switch (str[6] | 0x20)
  3962. {
  3963. case _X11_SPACE_SWITCH: // ' '
  3964. {
  3965. if (str[6])
  3966. {
  3967. if (str[7] && !strcmp(str[7], !"WHITE", true, 5))
  3968. {
  3969. idx += 12;
  3970. return X11_FLORAL_WHITE;
  3971. }
  3972. }
  3973. }
  3974. case '_' | 0x20:
  3975. {
  3976. if (str[7] && !strcmp(str[7], !"WHITE", true, 5))
  3977. {
  3978. idx += 12;
  3979. return X11_FLORAL_WHITE;
  3980. }
  3981. }
  3982. case 'w':
  3983. {
  3984. if (str[7] && !strcmp(str[7], !"HITE", true, 4))
  3985. {
  3986. idx += 11;
  3987. return X11_FLORALWHITE;
  3988. }
  3989. }
  3990. }
  3991. }
  3992. case 'o':
  3993. {
  3994. if (!str[2] || strcmp(str[2], !"REST", true, 4))
  3995. {
  3996. return -1;
  3997. }
  3998. switch (str[6] | 0x20)
  3999. {
  4000. case _X11_SPACE_SWITCH: // ' '
  4001. {
  4002. if (str[6])
  4003. {
  4004. if (str[7] && !strcmp(str[7], !"GREEN", true, 5))
  4005. {
  4006. idx += 12;
  4007. return X11_FOREST_GREEN;
  4008. }
  4009. }
  4010. }
  4011. case '_' | 0x20:
  4012. {
  4013. if (str[7] && !strcmp(str[7], !"GREEN", true, 5))
  4014. {
  4015. idx += 12;
  4016. return X11_FOREST_GREEN;
  4017. }
  4018. }
  4019. case 'g':
  4020. {
  4021. if (str[7] && !strcmp(str[7], !"REEN", true, 4))
  4022. {
  4023. idx += 11;
  4024. return X11_FORESTGREEN;
  4025. }
  4026. }
  4027. }
  4028. }
  4029. }
  4030. }
  4031. case 'g':
  4032. {
  4033. switch (str[1] | 0x20)
  4034. {
  4035. case 'a':
  4036. {
  4037. if (str[2] && !strcmp(str[2], !"INSBORO", true, 7))
  4038. {
  4039. idx += 9;
  4040. return X11_GAINSBORO;
  4041. }
  4042. }
  4043. case 'h':
  4044. {
  4045. if (!str[2] || strcmp(str[2], !"OST", true, 3))
  4046. {
  4047. return -1;
  4048. }
  4049. switch (str[5] | 0x20)
  4050. {
  4051. case _X11_SPACE_SWITCH: // ' '
  4052. {
  4053. if (str[5])
  4054. {
  4055. if (str[6] && !strcmp(str[6], !"WHITE", true, 5))
  4056. {
  4057. idx += 11;
  4058. return X11_GHOST_WHITE;
  4059. }
  4060. }
  4061. }
  4062. case '_' | 0x20:
  4063. {
  4064. if (str[6] && !strcmp(str[6], !"WHITE", true, 5))
  4065. {
  4066. idx += 11;
  4067. return X11_GHOST_WHITE;
  4068. }
  4069. }
  4070. case 'w':
  4071. {
  4072. if (str[6] && !strcmp(str[6], !"HITE", true, 4))
  4073. {
  4074. idx += 10;
  4075. return X11_GHOSTWHITE;
  4076. }
  4077. }
  4078. }
  4079. }
  4080. case 'o':
  4081. {
  4082. if (!str[2] || strcmp(str[2], !"LD", true, 2))
  4083. {
  4084. return -1;
  4085. }
  4086. switch (str[4] | 0x20)
  4087. {
  4088. case _X11_SPACE_SWITCH: // ' '
  4089. {
  4090. if (str[4])
  4091. {
  4092. switch (str[5] | 0x20)
  4093. {
  4094. case '1':
  4095. {
  4096. idx += 6;
  4097. return X11_GOLD_1;
  4098. }
  4099. case '2':
  4100. {
  4101. idx += 6;
  4102. return X11_GOLD_2;
  4103. }
  4104. case '3':
  4105. {
  4106. idx += 6;
  4107. return X11_GOLD_3;
  4108. }
  4109. case '4':
  4110. {
  4111. idx += 6;
  4112. return X11_GOLD_4;
  4113. }
  4114. }
  4115. }
  4116. }
  4117. case '_' | 0x20:
  4118. {
  4119. switch (str[5] | 0x20)
  4120. {
  4121. case '1':
  4122. {
  4123. idx += 6;
  4124. return X11_GOLD_1;
  4125. }
  4126. case '2':
  4127. {
  4128. idx += 6;
  4129. return X11_GOLD_2;
  4130. }
  4131. case '3':
  4132. {
  4133. idx += 6;
  4134. return X11_GOLD_3;
  4135. }
  4136. case '4':
  4137. {
  4138. idx += 6;
  4139. return X11_GOLD_4;
  4140. }
  4141. }
  4142. }
  4143. case '1':
  4144. {
  4145. idx += 5;
  4146. return X11_GOLD1;
  4147. }
  4148. case '2':
  4149. {
  4150. idx += 5;
  4151. return X11_GOLD2;
  4152. }
  4153. case '3':
  4154. {
  4155. idx += 5;
  4156. return X11_GOLD3;
  4157. }
  4158. case '4':
  4159. {
  4160. idx += 5;
  4161. return X11_GOLD4;
  4162. }
  4163. case 'e':
  4164. {
  4165. if (!str[5] || strcmp(str[5], !"NROD", true, 4))
  4166. {
  4167. return -1;
  4168. }
  4169. switch (str[9] | 0x20)
  4170. {
  4171. case _X11_SPACE_SWITCH: // ' '
  4172. {
  4173. if (str[9])
  4174. {
  4175. switch (str[10] | 0x20)
  4176. {
  4177. case '1':
  4178. {
  4179. idx += 11;
  4180. return X11_GOLDENROD_1;
  4181. }
  4182. case '2':
  4183. {
  4184. idx += 11;
  4185. return X11_GOLDENROD_2;
  4186. }
  4187. case '3':
  4188. {
  4189. idx += 11;
  4190. return X11_GOLDENROD_3;
  4191. }
  4192. case '4':
  4193. {
  4194. idx += 11;
  4195. return X11_GOLDENROD_4;
  4196. }
  4197. }
  4198. }
  4199. }
  4200. case '_' | 0x20:
  4201. {
  4202. switch (str[10] | 0x20)
  4203. {
  4204. case '1':
  4205. {
  4206. idx += 11;
  4207. return X11_GOLDENROD_1;
  4208. }
  4209. case '2':
  4210. {
  4211. idx += 11;
  4212. return X11_GOLDENROD_2;
  4213. }
  4214. case '3':
  4215. {
  4216. idx += 11;
  4217. return X11_GOLDENROD_3;
  4218. }
  4219. case '4':
  4220. {
  4221. idx += 11;
  4222. return X11_GOLDENROD_4;
  4223. }
  4224. }
  4225. }
  4226. case '1':
  4227. {
  4228. idx += 10;
  4229. return X11_GOLDENROD1;
  4230. }
  4231. case '2':
  4232. {
  4233. idx += 10;
  4234. return X11_GOLDENROD2;
  4235. }
  4236. case '3':
  4237. {
  4238. idx += 10;
  4239. return X11_GOLDENROD3;
  4240. }
  4241. case '4':
  4242. {
  4243. idx += 10;
  4244. return X11_GOLDENROD4;
  4245. }
  4246. }
  4247. idx += 9;
  4248. return X11_GOLDENROD;
  4249. }
  4250. }
  4251. idx += 4;
  4252. return X11_GOLD;
  4253. }
  4254. case 'r':
  4255. {
  4256. switch (str[2] | 0x20)
  4257. {
  4258. case 'a':
  4259. {
  4260. if (str[3] | 0x20 != 'y')
  4261. {
  4262. return -1;
  4263. }
  4264. switch (str[4] | 0x20)
  4265. {
  4266. case _X11_SPACE_SWITCH: // ' '
  4267. {
  4268. if (str[4])
  4269. {
  4270. switch (str[5] | 0x20)
  4271. {
  4272. case '0':
  4273. {
  4274. idx += 6;
  4275. return X11_GRAY_0;
  4276. }
  4277. case '1':
  4278. {
  4279. switch (str[6] | 0x20)
  4280. {
  4281. case '0':
  4282. {
  4283. switch (str[7] | 0x20)
  4284. {
  4285. case '0':
  4286. {
  4287. idx += 8;
  4288. return X11_GRAY_100;
  4289. }
  4290. }
  4291. idx += 7;
  4292. return X11_GRAY_10;
  4293. }
  4294. case '1':
  4295. {
  4296. idx += 7;
  4297. return X11_GRAY_11;
  4298. }
  4299. case '2':
  4300. {
  4301. idx += 7;
  4302. return X11_GRAY_12;
  4303. }
  4304. case '3':
  4305. {
  4306. idx += 7;
  4307. return X11_GRAY_13;
  4308. }
  4309. case '4':
  4310. {
  4311. idx += 7;
  4312. return X11_GRAY_14;
  4313. }
  4314. case '5':
  4315. {
  4316. idx += 7;
  4317. return X11_GRAY_15;
  4318. }
  4319. case '6':
  4320. {
  4321. idx += 7;
  4322. return X11_GRAY_16;
  4323. }
  4324. case '7':
  4325. {
  4326. idx += 7;
  4327. return X11_GRAY_17;
  4328. }
  4329. case '8':
  4330. {
  4331. idx += 7;
  4332. return X11_GRAY_18;
  4333. }
  4334. case '9':
  4335. {
  4336. idx += 7;
  4337. return X11_GRAY_19;
  4338. }
  4339. }
  4340. idx += 6;
  4341. return X11_GRAY_1;
  4342. }
  4343. case '2':
  4344. {
  4345. switch (str[6] | 0x20)
  4346. {
  4347. case '0':
  4348. {
  4349. idx += 7;
  4350. return X11_GRAY_20;
  4351. }
  4352. case '1':
  4353. {
  4354. idx += 7;
  4355. return X11_GRAY_21;
  4356. }
  4357. case '2':
  4358. {
  4359. idx += 7;
  4360. return X11_GRAY_22;
  4361. }
  4362. case '3':
  4363. {
  4364. idx += 7;
  4365. return X11_GRAY_23;
  4366. }
  4367. case '4':
  4368. {
  4369. idx += 7;
  4370. return X11_GRAY_24;
  4371. }
  4372. case '5':
  4373. {
  4374. idx += 7;
  4375. return X11_GRAY_25;
  4376. }
  4377. case '6':
  4378. {
  4379. idx += 7;
  4380. return X11_GRAY_26;
  4381. }
  4382. case '7':
  4383. {
  4384. idx += 7;
  4385. return X11_GRAY_27;
  4386. }
  4387. case '8':
  4388. {
  4389. idx += 7;
  4390. return X11_GRAY_28;
  4391. }
  4392. case '9':
  4393. {
  4394. idx += 7;
  4395. return X11_GRAY_29;
  4396. }
  4397. }
  4398. idx += 6;
  4399. return X11_GRAY_2;
  4400. }
  4401. case '3':
  4402. {
  4403. switch (str[6] | 0x20)
  4404. {
  4405. case '0':
  4406. {
  4407. idx += 7;
  4408. return X11_GRAY_30;
  4409. }
  4410. case '1':
  4411. {
  4412. idx += 7;
  4413. return X11_GRAY_31;
  4414. }
  4415. case '2':
  4416. {
  4417. idx += 7;
  4418. return X11_GRAY_32;
  4419. }
  4420. case '3':
  4421. {
  4422. idx += 7;
  4423. return X11_GRAY_33;
  4424. }
  4425. case '4':
  4426. {
  4427. idx += 7;
  4428. return X11_GRAY_34;
  4429. }
  4430. case '5':
  4431. {
  4432. idx += 7;
  4433. return X11_GRAY_35;
  4434. }
  4435. case '6':
  4436. {
  4437. idx += 7;
  4438. return X11_GRAY_36;
  4439. }
  4440. case '7':
  4441. {
  4442. idx += 7;
  4443. return X11_GRAY_37;
  4444. }
  4445. case '8':
  4446. {
  4447. idx += 7;
  4448. return X11_GRAY_38;
  4449. }
  4450. case '9':
  4451. {
  4452. idx += 7;
  4453. return X11_GRAY_39;
  4454. }
  4455. }
  4456. idx += 6;
  4457. return X11_GRAY_3;
  4458. }
  4459. case '4':
  4460. {
  4461. switch (str[6] | 0x20)
  4462. {
  4463. case '0':
  4464. {
  4465. idx += 7;
  4466. return X11_GRAY_40;
  4467. }
  4468. case '1':
  4469. {
  4470. idx += 7;
  4471. return X11_GRAY_41;
  4472. }
  4473. case '2':
  4474. {
  4475. idx += 7;
  4476. return X11_GRAY_42;
  4477. }
  4478. case '3':
  4479. {
  4480. idx += 7;
  4481. return X11_GRAY_43;
  4482. }
  4483. case '4':
  4484. {
  4485. idx += 7;
  4486. return X11_GRAY_44;
  4487. }
  4488. case '5':
  4489. {
  4490. idx += 7;
  4491. return X11_GRAY_45;
  4492. }
  4493. case '6':
  4494. {
  4495. idx += 7;
  4496. return X11_GRAY_46;
  4497. }
  4498. case '7':
  4499. {
  4500. idx += 7;
  4501. return X11_GRAY_47;
  4502. }
  4503. case '8':
  4504. {
  4505. idx += 7;
  4506. return X11_GRAY_48;
  4507. }
  4508. case '9':
  4509. {
  4510. idx += 7;
  4511. return X11_GRAY_49;
  4512. }
  4513. }
  4514. idx += 6;
  4515. return X11_GRAY_4;
  4516. }
  4517. case '5':
  4518. {
  4519. switch (str[6] | 0x20)
  4520. {
  4521. case '0':
  4522. {
  4523. idx += 7;
  4524. return X11_GRAY_50;
  4525. }
  4526. case '1':
  4527. {
  4528. idx += 7;
  4529. return X11_GRAY_51;
  4530. }
  4531. case '2':
  4532. {
  4533. idx += 7;
  4534. return X11_GRAY_52;
  4535. }
  4536. case '3':
  4537. {
  4538. idx += 7;
  4539. return X11_GRAY_53;
  4540. }
  4541. case '4':
  4542. {
  4543. idx += 7;
  4544. return X11_GRAY_54;
  4545. }
  4546. case '5':
  4547. {
  4548. idx += 7;
  4549. return X11_GRAY_55;
  4550. }
  4551. case '6':
  4552. {
  4553. idx += 7;
  4554. return X11_GRAY_56;
  4555. }
  4556. case '7':
  4557. {
  4558. idx += 7;
  4559. return X11_GRAY_57;
  4560. }
  4561. case '8':
  4562. {
  4563. idx += 7;
  4564. return X11_GRAY_58;
  4565. }
  4566. case '9':
  4567. {
  4568. idx += 7;
  4569. return X11_GRAY_59;
  4570. }
  4571. }
  4572. idx += 6;
  4573. return X11_GRAY_5;
  4574. }
  4575. case '6':
  4576. {
  4577. switch (str[6] | 0x20)
  4578. {
  4579. case '0':
  4580. {
  4581. idx += 7;
  4582. return X11_GRAY_60;
  4583. }
  4584. case '1':
  4585. {
  4586. idx += 7;
  4587. return X11_GRAY_61;
  4588. }
  4589. case '2':
  4590. {
  4591. idx += 7;
  4592. return X11_GRAY_62;
  4593. }
  4594. case '3':
  4595. {
  4596. idx += 7;
  4597. return X11_GRAY_63;
  4598. }
  4599. case '4':
  4600. {
  4601. idx += 7;
  4602. return X11_GRAY_64;
  4603. }
  4604. case '5':
  4605. {
  4606. idx += 7;
  4607. return X11_GRAY_65;
  4608. }
  4609. case '6':
  4610. {
  4611. idx += 7;
  4612. return X11_GRAY_66;
  4613. }
  4614. case '7':
  4615. {
  4616. idx += 7;
  4617. return X11_GRAY_67;
  4618. }
  4619. case '8':
  4620. {
  4621. idx += 7;
  4622. return X11_GRAY_68;
  4623. }
  4624. case '9':
  4625. {
  4626. idx += 7;
  4627. return X11_GRAY_69;
  4628. }
  4629. }
  4630. idx += 6;
  4631. return X11_GRAY_6;
  4632. }
  4633. case '7':
  4634. {
  4635. switch (str[6] | 0x20)
  4636. {
  4637. case '0':
  4638. {
  4639. idx += 7;
  4640. return X11_GRAY_70;
  4641. }
  4642. case '1':
  4643. {
  4644. idx += 7;
  4645. return X11_GRAY_71;
  4646. }
  4647. case '2':
  4648. {
  4649. idx += 7;
  4650. return X11_GRAY_72;
  4651. }
  4652. case '3':
  4653. {
  4654. idx += 7;
  4655. return X11_GRAY_73;
  4656. }
  4657. case '4':
  4658. {
  4659. idx += 7;
  4660. return X11_GRAY_74;
  4661. }
  4662. case '5':
  4663. {
  4664. idx += 7;
  4665. return X11_GRAY_75;
  4666. }
  4667. case '6':
  4668. {
  4669. idx += 7;
  4670. return X11_GRAY_76;
  4671. }
  4672. case '7':
  4673. {
  4674. idx += 7;
  4675. return X11_GRAY_77;
  4676. }
  4677. case '8':
  4678. {
  4679. idx += 7;
  4680. return X11_GRAY_78;
  4681. }
  4682. case '9':
  4683. {
  4684. idx += 7;
  4685. return X11_GRAY_79;
  4686. }
  4687. }
  4688. idx += 6;
  4689. return X11_GRAY_7;
  4690. }
  4691. case '8':
  4692. {
  4693. switch (str[6] | 0x20)
  4694. {
  4695. case '0':
  4696. {
  4697. idx += 7;
  4698. return X11_GRAY_80;
  4699. }
  4700. case '1':
  4701. {
  4702. idx += 7;
  4703. return X11_GRAY_81;
  4704. }
  4705. case '2':
  4706. {
  4707. idx += 7;
  4708. return X11_GRAY_82;
  4709. }
  4710. case '3':
  4711. {
  4712. idx += 7;
  4713. return X11_GRAY_83;
  4714. }
  4715. case '4':
  4716. {
  4717. idx += 7;
  4718. return X11_GRAY_84;
  4719. }
  4720. case '5':
  4721. {
  4722. idx += 7;
  4723. return X11_GRAY_85;
  4724. }
  4725. case '6':
  4726. {
  4727. idx += 7;
  4728. return X11_GRAY_86;
  4729. }
  4730. case '7':
  4731. {
  4732. idx += 7;
  4733. return X11_GRAY_87;
  4734. }
  4735. case '8':
  4736. {
  4737. idx += 7;
  4738. return X11_GRAY_88;
  4739. }
  4740. case '9':
  4741. {
  4742. idx += 7;
  4743. return X11_GRAY_89;
  4744. }
  4745. }
  4746. idx += 6;
  4747. return X11_GRAY_8;
  4748. }
  4749. case '9':
  4750. {
  4751. switch (str[6] | 0x20)
  4752. {
  4753. case '0':
  4754. {
  4755. idx += 7;
  4756. return X11_GRAY_90;
  4757. }
  4758. case '1':
  4759. {
  4760. idx += 7;
  4761. return X11_GRAY_91;
  4762. }
  4763. case '2':
  4764. {
  4765. idx += 7;
  4766. return X11_GRAY_92;
  4767. }
  4768. case '3':
  4769. {
  4770. idx += 7;
  4771. return X11_GRAY_93;
  4772. }
  4773. case '4':
  4774. {
  4775. idx += 7;
  4776. return X11_GRAY_94;
  4777. }
  4778. case '5':
  4779. {
  4780. idx += 7;
  4781. return X11_GRAY_95;
  4782. }
  4783. case '6':
  4784. {
  4785. idx += 7;
  4786. return X11_GRAY_96;
  4787. }
  4788. case '7':
  4789. {
  4790. idx += 7;
  4791. return X11_GRAY_97;
  4792. }
  4793. case '8':
  4794. {
  4795. idx += 7;
  4796. return X11_GRAY_98;
  4797. }
  4798. case '9':
  4799. {
  4800. idx += 7;
  4801. return X11_GRAY_99;
  4802. }
  4803. }
  4804. idx += 6;
  4805. return X11_GRAY_9;
  4806. }
  4807. }
  4808. }
  4809. }
  4810. case '_' | 0x20:
  4811. {
  4812. switch (str[5] | 0x20)
  4813. {
  4814. case '0':
  4815. {
  4816. idx += 6;
  4817. return X11_GRAY_0;
  4818. }
  4819. case '1':
  4820. {
  4821. switch (str[6] | 0x20)
  4822. {
  4823. case '0':
  4824. {
  4825. switch (str[7] | 0x20)
  4826. {
  4827. case '0':
  4828. {
  4829. idx += 8;
  4830. return X11_GRAY_100;
  4831. }
  4832. }
  4833. idx += 7;
  4834. return X11_GRAY_10;
  4835. }
  4836. case '1':
  4837. {
  4838. idx += 7;
  4839. return X11_GRAY_11;
  4840. }
  4841. case '2':
  4842. {
  4843. idx += 7;
  4844. return X11_GRAY_12;
  4845. }
  4846. case '3':
  4847. {
  4848. idx += 7;
  4849. return X11_GRAY_13;
  4850. }
  4851. case '4':
  4852. {
  4853. idx += 7;
  4854. return X11_GRAY_14;
  4855. }
  4856. case '5':
  4857. {
  4858. idx += 7;
  4859. return X11_GRAY_15;
  4860. }
  4861. case '6':
  4862. {
  4863. idx += 7;
  4864. return X11_GRAY_16;
  4865. }
  4866. case '7':
  4867. {
  4868. idx += 7;
  4869. return X11_GRAY_17;
  4870. }
  4871. case '8':
  4872. {
  4873. idx += 7;
  4874. return X11_GRAY_18;
  4875. }
  4876. case '9':
  4877. {
  4878. idx += 7;
  4879. return X11_GRAY_19;
  4880. }
  4881. }
  4882. idx += 6;
  4883. return X11_GRAY_1;
  4884. }
  4885. case '2':
  4886. {
  4887. switch (str[6] | 0x20)
  4888. {
  4889. case '0':
  4890. {
  4891. idx += 7;
  4892. return X11_GRAY_20;
  4893. }
  4894. case '1':
  4895. {
  4896. idx += 7;
  4897. return X11_GRAY_21;
  4898. }
  4899. case '2':
  4900. {
  4901. idx += 7;
  4902. return X11_GRAY_22;
  4903. }
  4904. case '3':
  4905. {
  4906. idx += 7;
  4907. return X11_GRAY_23;
  4908. }
  4909. case '4':
  4910. {
  4911. idx += 7;
  4912. return X11_GRAY_24;
  4913. }
  4914. case '5':
  4915. {
  4916. idx += 7;
  4917. return X11_GRAY_25;
  4918. }
  4919. case '6':
  4920. {
  4921. idx += 7;
  4922. return X11_GRAY_26;
  4923. }
  4924. case '7':
  4925. {
  4926. idx += 7;
  4927. return X11_GRAY_27;
  4928. }
  4929. case '8':
  4930. {
  4931. idx += 7;
  4932. return X11_GRAY_28;
  4933. }
  4934. case '9':
  4935. {
  4936. idx += 7;
  4937. return X11_GRAY_29;
  4938. }
  4939. }
  4940. idx += 6;
  4941. return X11_GRAY_2;
  4942. }
  4943. case '3':
  4944. {
  4945. switch (str[6] | 0x20)
  4946. {
  4947. case '0':
  4948. {
  4949. idx += 7;
  4950. return X11_GRAY_30;
  4951. }
  4952. case '1':
  4953. {
  4954. idx += 7;
  4955. return X11_GRAY_31;
  4956. }
  4957. case '2':
  4958. {
  4959. idx += 7;
  4960. return X11_GRAY_32;
  4961. }
  4962. case '3':
  4963. {
  4964. idx += 7;
  4965. return X11_GRAY_33;
  4966. }
  4967. case '4':
  4968. {
  4969. idx += 7;
  4970. return X11_GRAY_34;
  4971. }
  4972. case '5':
  4973. {
  4974. idx += 7;
  4975. return X11_GRAY_35;
  4976. }
  4977. case '6':
  4978. {
  4979. idx += 7;
  4980. return X11_GRAY_36;
  4981. }
  4982. case '7':
  4983. {
  4984. idx += 7;
  4985. return X11_GRAY_37;
  4986. }
  4987. case '8':
  4988. {
  4989. idx += 7;
  4990. return X11_GRAY_38;
  4991. }
  4992. case '9':
  4993. {
  4994. idx += 7;
  4995. return X11_GRAY_39;
  4996. }
  4997. }
  4998. idx += 6;
  4999. return X11_GRAY_3;
  5000. }
  5001. case '4':
  5002. {
  5003. switch (str[6] | 0x20)
  5004. {
  5005. case '0':
  5006. {
  5007. idx += 7;
  5008. return X11_GRAY_40;
  5009. }
  5010. case '1':
  5011. {
  5012. idx += 7;
  5013. return X11_GRAY_41;
  5014. }
  5015. case '2':
  5016. {
  5017. idx += 7;
  5018. return X11_GRAY_42;
  5019. }
  5020. case '3':
  5021. {
  5022. idx += 7;
  5023. return X11_GRAY_43;
  5024. }
  5025. case '4':
  5026. {
  5027. idx += 7;
  5028. return X11_GRAY_44;
  5029. }
  5030. case '5':
  5031. {
  5032. idx += 7;
  5033. return X11_GRAY_45;
  5034. }
  5035. case '6':
  5036. {
  5037. idx += 7;
  5038. return X11_GRAY_46;
  5039. }
  5040. case '7':
  5041. {
  5042. idx += 7;
  5043. return X11_GRAY_47;
  5044. }
  5045. case '8':
  5046. {
  5047. idx += 7;
  5048. return X11_GRAY_48;
  5049. }
  5050. case '9':
  5051. {
  5052. idx += 7;
  5053. return X11_GRAY_49;
  5054. }
  5055. }
  5056. idx += 6;
  5057. return X11_GRAY_4;
  5058. }
  5059. case '5':
  5060. {
  5061. switch (str[6] | 0x20)
  5062. {
  5063. case '0':
  5064. {
  5065. idx += 7;
  5066. return X11_GRAY_50;
  5067. }
  5068. case '1':
  5069. {
  5070. idx += 7;
  5071. return X11_GRAY_51;
  5072. }
  5073. case '2':
  5074. {
  5075. idx += 7;
  5076. return X11_GRAY_52;
  5077. }
  5078. case '3':
  5079. {
  5080. idx += 7;
  5081. return X11_GRAY_53;
  5082. }
  5083. case '4':
  5084. {
  5085. idx += 7;
  5086. return X11_GRAY_54;
  5087. }
  5088. case '5':
  5089. {
  5090. idx += 7;
  5091. return X11_GRAY_55;
  5092. }
  5093. case '6':
  5094. {
  5095. idx += 7;
  5096. return X11_GRAY_56;
  5097. }
  5098. case '7':
  5099. {
  5100. idx += 7;
  5101. return X11_GRAY_57;
  5102. }
  5103. case '8':
  5104. {
  5105. idx += 7;
  5106. return X11_GRAY_58;
  5107. }
  5108. case '9':
  5109. {
  5110. idx += 7;
  5111. return X11_GRAY_59;
  5112. }
  5113. }
  5114. idx += 6;
  5115. return X11_GRAY_5;
  5116. }
  5117. case '6':
  5118. {
  5119. switch (str[6] | 0x20)
  5120. {
  5121. case '0':
  5122. {
  5123. idx += 7;
  5124. return X11_GRAY_60;
  5125. }
  5126. case '1':
  5127. {
  5128. idx += 7;
  5129. return X11_GRAY_61;
  5130. }
  5131. case '2':
  5132. {
  5133. idx += 7;
  5134. return X11_GRAY_62;
  5135. }
  5136. case '3':
  5137. {
  5138. idx += 7;
  5139. return X11_GRAY_63;
  5140. }
  5141. case '4':
  5142. {
  5143. idx += 7;
  5144. return X11_GRAY_64;
  5145. }
  5146. case '5':
  5147. {
  5148. idx += 7;
  5149. return X11_GRAY_65;
  5150. }
  5151. case '6':
  5152. {
  5153. idx += 7;
  5154. return X11_GRAY_66;
  5155. }
  5156. case '7':
  5157. {
  5158. idx += 7;
  5159. return X11_GRAY_67;
  5160. }
  5161. case '8':
  5162. {
  5163. idx += 7;
  5164. return X11_GRAY_68;
  5165. }
  5166. case '9':
  5167. {
  5168. idx += 7;
  5169. return X11_GRAY_69;
  5170. }
  5171. }
  5172. idx += 6;
  5173. return X11_GRAY_6;
  5174. }
  5175. case '7':
  5176. {
  5177. switch (str[6] | 0x20)
  5178. {
  5179. case '0':
  5180. {
  5181. idx += 7;
  5182. return X11_GRAY_70;
  5183. }
  5184. case '1':
  5185. {
  5186. idx += 7;
  5187. return X11_GRAY_71;
  5188. }
  5189. case '2':
  5190. {
  5191. idx += 7;
  5192. return X11_GRAY_72;
  5193. }
  5194. case '3':
  5195. {
  5196. idx += 7;
  5197. return X11_GRAY_73;
  5198. }
  5199. case '4':
  5200. {
  5201. idx += 7;
  5202. return X11_GRAY_74;
  5203. }
  5204. case '5':
  5205. {
  5206. idx += 7;
  5207. return X11_GRAY_75;
  5208. }
  5209. case '6':
  5210. {
  5211. idx += 7;
  5212. return X11_GRAY_76;
  5213. }
  5214. case '7':
  5215. {
  5216. idx += 7;
  5217. return X11_GRAY_77;
  5218. }
  5219. case '8':
  5220. {
  5221. idx += 7;
  5222. return X11_GRAY_78;
  5223. }
  5224. case '9':
  5225. {
  5226. idx += 7;
  5227. return X11_GRAY_79;
  5228. }
  5229. }
  5230. idx += 6;
  5231. return X11_GRAY_7;
  5232. }
  5233. case '8':
  5234. {
  5235. switch (str[6] | 0x20)
  5236. {
  5237. case '0':
  5238. {
  5239. idx += 7;
  5240. return X11_GRAY_80;
  5241. }
  5242. case '1':
  5243. {
  5244. idx += 7;
  5245. return X11_GRAY_81;
  5246. }
  5247. case '2':
  5248. {
  5249. idx += 7;
  5250. return X11_GRAY_82;
  5251. }
  5252. case '3':
  5253. {
  5254. idx += 7;
  5255. return X11_GRAY_83;
  5256. }
  5257. case '4':
  5258. {
  5259. idx += 7;
  5260. return X11_GRAY_84;
  5261. }
  5262. case '5':
  5263. {
  5264. idx += 7;
  5265. return X11_GRAY_85;
  5266. }
  5267. case '6':
  5268. {
  5269. idx += 7;
  5270. return X11_GRAY_86;
  5271. }
  5272. case '7':
  5273. {
  5274. idx += 7;
  5275. return X11_GRAY_87;
  5276. }
  5277. case '8':
  5278. {
  5279. idx += 7;
  5280. return X11_GRAY_88;
  5281. }
  5282. case '9':
  5283. {
  5284. idx += 7;
  5285. return X11_GRAY_89;
  5286. }
  5287. }
  5288. idx += 6;
  5289. return X11_GRAY_8;
  5290. }
  5291. case '9':
  5292. {
  5293. switch (str[6] | 0x20)
  5294. {
  5295. case '0':
  5296. {
  5297. idx += 7;
  5298. return X11_GRAY_90;
  5299. }
  5300. case '1':
  5301. {
  5302. idx += 7;
  5303. return X11_GRAY_91;
  5304. }
  5305. case '2':
  5306. {
  5307. idx += 7;
  5308. return X11_GRAY_92;
  5309. }
  5310. case '3':
  5311. {
  5312. idx += 7;
  5313. return X11_GRAY_93;
  5314. }
  5315. case '4':
  5316. {
  5317. idx += 7;
  5318. return X11_GRAY_94;
  5319. }
  5320. case '5':
  5321. {
  5322. idx += 7;
  5323. return X11_GRAY_95;
  5324. }
  5325. case '6':
  5326. {
  5327. idx += 7;
  5328. return X11_GRAY_96;
  5329. }
  5330. case '7':
  5331. {
  5332. idx += 7;
  5333. return X11_GRAY_97;
  5334. }
  5335. case '8':
  5336. {
  5337. idx += 7;
  5338. return X11_GRAY_98;
  5339. }
  5340. case '9':
  5341. {
  5342. idx += 7;
  5343. return X11_GRAY_99;
  5344. }
  5345. }
  5346. idx += 6;
  5347. return X11_GRAY_9;
  5348. }
  5349. }
  5350. }
  5351. case '0':
  5352. {
  5353. idx += 5;
  5354. return X11_GRAY0;
  5355. }
  5356. case '1':
  5357. {
  5358. switch (str[5] | 0x20)
  5359. {
  5360. case '0':
  5361. {
  5362. switch (str[6] | 0x20)
  5363. {
  5364. case '0':
  5365. {
  5366. idx += 7;
  5367. return X11_GRAY100;
  5368. }
  5369. }
  5370. idx += 6;
  5371. return X11_GRAY10;
  5372. }
  5373. case '1':
  5374. {
  5375. idx += 6;
  5376. return X11_GRAY11;
  5377. }
  5378. case '2':
  5379. {
  5380. idx += 6;
  5381. return X11_GRAY12;
  5382. }
  5383. case '3':
  5384. {
  5385. idx += 6;
  5386. return X11_GRAY13;
  5387. }
  5388. case '4':
  5389. {
  5390. idx += 6;
  5391. return X11_GRAY14;
  5392. }
  5393. case '5':
  5394. {
  5395. idx += 6;
  5396. return X11_GRAY15;
  5397. }
  5398. case '6':
  5399. {
  5400. idx += 6;
  5401. return X11_GRAY16;
  5402. }
  5403. case '7':
  5404. {
  5405. idx += 6;
  5406. return X11_GRAY17;
  5407. }
  5408. case '8':
  5409. {
  5410. idx += 6;
  5411. return X11_GRAY18;
  5412. }
  5413. case '9':
  5414. {
  5415. idx += 6;
  5416. return X11_GRAY19;
  5417. }
  5418. }
  5419. idx += 5;
  5420. return X11_GRAY1;
  5421. }
  5422. case '2':
  5423. {
  5424. switch (str[5] | 0x20)
  5425. {
  5426. case '0':
  5427. {
  5428. idx += 6;
  5429. return X11_GRAY20;
  5430. }
  5431. case '1':
  5432. {
  5433. idx += 6;
  5434. return X11_GRAY21;
  5435. }
  5436. case '2':
  5437. {
  5438. idx += 6;
  5439. return X11_GRAY22;
  5440. }
  5441. case '3':
  5442. {
  5443. idx += 6;
  5444. return X11_GRAY23;
  5445. }
  5446. case '4':
  5447. {
  5448. idx += 6;
  5449. return X11_GRAY24;
  5450. }
  5451. case '5':
  5452. {
  5453. idx += 6;
  5454. return X11_GRAY25;
  5455. }
  5456. case '6':
  5457. {
  5458. idx += 6;
  5459. return X11_GRAY26;
  5460. }
  5461. case '7':
  5462. {
  5463. idx += 6;
  5464. return X11_GRAY27;
  5465. }
  5466. case '8':
  5467. {
  5468. idx += 6;
  5469. return X11_GRAY28;
  5470. }
  5471. case '9':
  5472. {
  5473. idx += 6;
  5474. return X11_GRAY29;
  5475. }
  5476. }
  5477. idx += 5;
  5478. return X11_GRAY2;
  5479. }
  5480. case '3':
  5481. {
  5482. switch (str[5] | 0x20)
  5483. {
  5484. case '0':
  5485. {
  5486. idx += 6;
  5487. return X11_GRAY30;
  5488. }
  5489. case '1':
  5490. {
  5491. idx += 6;
  5492. return X11_GRAY31;
  5493. }
  5494. case '2':
  5495. {
  5496. idx += 6;
  5497. return X11_GRAY32;
  5498. }
  5499. case '3':
  5500. {
  5501. idx += 6;
  5502. return X11_GRAY33;
  5503. }
  5504. case '4':
  5505. {
  5506. idx += 6;
  5507. return X11_GRAY34;
  5508. }
  5509. case '5':
  5510. {
  5511. idx += 6;
  5512. return X11_GRAY35;
  5513. }
  5514. case '6':
  5515. {
  5516. idx += 6;
  5517. return X11_GRAY36;
  5518. }
  5519. case '7':
  5520. {
  5521. idx += 6;
  5522. return X11_GRAY37;
  5523. }
  5524. case '8':
  5525. {
  5526. idx += 6;
  5527. return X11_GRAY38;
  5528. }
  5529. case '9':
  5530. {
  5531. idx += 6;
  5532. return X11_GRAY39;
  5533. }
  5534. }
  5535. idx += 5;
  5536. return X11_GRAY3;
  5537. }
  5538. case '4':
  5539. {
  5540. switch (str[5] | 0x20)
  5541. {
  5542. case '0':
  5543. {
  5544. idx += 6;
  5545. return X11_GRAY40;
  5546. }
  5547. case '1':
  5548. {
  5549. idx += 6;
  5550. return X11_GRAY41;
  5551. }
  5552. case '2':
  5553. {
  5554. idx += 6;
  5555. return X11_GRAY42;
  5556. }
  5557. case '3':
  5558. {
  5559. idx += 6;
  5560. return X11_GRAY43;
  5561. }
  5562. case '4':
  5563. {
  5564. idx += 6;
  5565. return X11_GRAY44;
  5566. }
  5567. case '5':
  5568. {
  5569. idx += 6;
  5570. return X11_GRAY45;
  5571. }
  5572. case '6':
  5573. {
  5574. idx += 6;
  5575. return X11_GRAY46;
  5576. }
  5577. case '7':
  5578. {
  5579. idx += 6;
  5580. return X11_GRAY47;
  5581. }
  5582. case '8':
  5583. {
  5584. idx += 6;
  5585. return X11_GRAY48;
  5586. }
  5587. case '9':
  5588. {
  5589. idx += 6;
  5590. return X11_GRAY49;
  5591. }
  5592. }
  5593. idx += 5;
  5594. return X11_GRAY4;
  5595. }
  5596. case '5':
  5597. {
  5598. switch (str[5] | 0x20)
  5599. {
  5600. case '0':
  5601. {
  5602. idx += 6;
  5603. return X11_GRAY50;
  5604. }
  5605. case '1':
  5606. {
  5607. idx += 6;
  5608. return X11_GRAY51;
  5609. }
  5610. case '2':
  5611. {
  5612. idx += 6;
  5613. return X11_GRAY52;
  5614. }
  5615. case '3':
  5616. {
  5617. idx += 6;
  5618. return X11_GRAY53;
  5619. }
  5620. case '4':
  5621. {
  5622. idx += 6;
  5623. return X11_GRAY54;
  5624. }
  5625. case '5':
  5626. {
  5627. idx += 6;
  5628. return X11_GRAY55;
  5629. }
  5630. case '6':
  5631. {
  5632. idx += 6;
  5633. return X11_GRAY56;
  5634. }
  5635. case '7':
  5636. {
  5637. idx += 6;
  5638. return X11_GRAY57;
  5639. }
  5640. case '8':
  5641. {
  5642. idx += 6;
  5643. return X11_GRAY58;
  5644. }
  5645. case '9':
  5646. {
  5647. idx += 6;
  5648. return X11_GRAY59;
  5649. }
  5650. }
  5651. idx += 5;
  5652. return X11_GRAY5;
  5653. }
  5654. case '6':
  5655. {
  5656. switch (str[5] | 0x20)
  5657. {
  5658. case '0':
  5659. {
  5660. idx += 6;
  5661. return X11_GRAY60;
  5662. }
  5663. case '1':
  5664. {
  5665. idx += 6;
  5666. return X11_GRAY61;
  5667. }
  5668. case '2':
  5669. {
  5670. idx += 6;
  5671. return X11_GRAY62;
  5672. }
  5673. case '3':
  5674. {
  5675. idx += 6;
  5676. return X11_GRAY63;
  5677. }
  5678. case '4':
  5679. {
  5680. idx += 6;
  5681. return X11_GRAY64;
  5682. }
  5683. case '5':
  5684. {
  5685. idx += 6;
  5686. return X11_GRAY65;
  5687. }
  5688. case '6':
  5689. {
  5690. idx += 6;
  5691. return X11_GRAY66;
  5692. }
  5693. case '7':
  5694. {
  5695. idx += 6;
  5696. return X11_GRAY67;
  5697. }
  5698. case '8':
  5699. {
  5700. idx += 6;
  5701. return X11_GRAY68;
  5702. }
  5703. case '9':
  5704. {
  5705. idx += 6;
  5706. return X11_GRAY69;
  5707. }
  5708. }
  5709. idx += 5;
  5710. return X11_GRAY6;
  5711. }
  5712. case '7':
  5713. {
  5714. switch (str[5] | 0x20)
  5715. {
  5716. case '0':
  5717. {
  5718. idx += 6;
  5719. return X11_GRAY70;
  5720. }
  5721. case '1':
  5722. {
  5723. idx += 6;
  5724. return X11_GRAY71;
  5725. }
  5726. case '2':
  5727. {
  5728. idx += 6;
  5729. return X11_GRAY72;
  5730. }
  5731. case '3':
  5732. {
  5733. idx += 6;
  5734. return X11_GRAY73;
  5735. }
  5736. case '4':
  5737. {
  5738. idx += 6;
  5739. return X11_GRAY74;
  5740. }
  5741. case '5':
  5742. {
  5743. idx += 6;
  5744. return X11_GRAY75;
  5745. }
  5746. case '6':
  5747. {
  5748. idx += 6;
  5749. return X11_GRAY76;
  5750. }
  5751. case '7':
  5752. {
  5753. idx += 6;
  5754. return X11_GRAY77;
  5755. }
  5756. case '8':
  5757. {
  5758. idx += 6;
  5759. return X11_GRAY78;
  5760. }
  5761. case '9':
  5762. {
  5763. idx += 6;
  5764. return X11_GRAY79;
  5765. }
  5766. }
  5767. idx += 5;
  5768. return X11_GRAY7;
  5769. }
  5770. case '8':
  5771. {
  5772. switch (str[5] | 0x20)
  5773. {
  5774. case '0':
  5775. {
  5776. idx += 6;
  5777. return X11_GRAY80;
  5778. }
  5779. case '1':
  5780. {
  5781. idx += 6;
  5782. return X11_GRAY81;
  5783. }
  5784. case '2':
  5785. {
  5786. idx += 6;
  5787. return X11_GRAY82;
  5788. }
  5789. case '3':
  5790. {
  5791. idx += 6;
  5792. return X11_GRAY83;
  5793. }
  5794. case '4':
  5795. {
  5796. idx += 6;
  5797. return X11_GRAY84;
  5798. }
  5799. case '5':
  5800. {
  5801. idx += 6;
  5802. return X11_GRAY85;
  5803. }
  5804. case '6':
  5805. {
  5806. idx += 6;
  5807. return X11_GRAY86;
  5808. }
  5809. case '7':
  5810. {
  5811. idx += 6;
  5812. return X11_GRAY87;
  5813. }
  5814. case '8':
  5815. {
  5816. idx += 6;
  5817. return X11_GRAY88;
  5818. }
  5819. case '9':
  5820. {
  5821. idx += 6;
  5822. return X11_GRAY89;
  5823. }
  5824. }
  5825. idx += 5;
  5826. return X11_GRAY8;
  5827. }
  5828. case '9':
  5829. {
  5830. switch (str[5] | 0x20)
  5831. {
  5832. case '0':
  5833. {
  5834. idx += 6;
  5835. return X11_GRAY90;
  5836. }
  5837. case '1':
  5838. {
  5839. idx += 6;
  5840. return X11_GRAY91;
  5841. }
  5842. case '2':
  5843. {
  5844. idx += 6;
  5845. return X11_GRAY92;
  5846. }
  5847. case '3':
  5848. {
  5849. idx += 6;
  5850. return X11_GRAY93;
  5851. }
  5852. case '4':
  5853. {
  5854. idx += 6;
  5855. return X11_GRAY94;
  5856. }
  5857. case '5':
  5858. {
  5859. idx += 6;
  5860. return X11_GRAY95;
  5861. }
  5862. case '6':
  5863. {
  5864. idx += 6;
  5865. return X11_GRAY96;
  5866. }
  5867. case '7':
  5868. {
  5869. idx += 6;
  5870. return X11_GRAY97;
  5871. }
  5872. case '8':
  5873. {
  5874. idx += 6;
  5875. return X11_GRAY98;
  5876. }
  5877. case '9':
  5878. {
  5879. idx += 6;
  5880. return X11_GRAY99;
  5881. }
  5882. }
  5883. idx += 5;
  5884. return X11_GRAY9;
  5885. }
  5886. }
  5887. idx += 4;
  5888. return X11_GRAY;
  5889. }
  5890. case 'e':
  5891. {
  5892. switch (str[3] | 0x20)
  5893. {
  5894. case 'e':
  5895. {
  5896. if (str[4] | 0x20 != 'n')
  5897. {
  5898. return -1;
  5899. }
  5900. switch (str[5] | 0x20)
  5901. {
  5902. case _X11_SPACE_SWITCH: // ' '
  5903. {
  5904. if (str[5])
  5905. {
  5906. switch (str[6] | 0x20)
  5907. {
  5908. case '1':
  5909. {
  5910. idx += 7;
  5911. return X11_GREEN_1;
  5912. }
  5913. case '2':
  5914. {
  5915. idx += 7;
  5916. return X11_GREEN_2;
  5917. }
  5918. case '3':
  5919. {
  5920. idx += 7;
  5921. return X11_GREEN_3;
  5922. }
  5923. case '4':
  5924. {
  5925. idx += 7;
  5926. return X11_GREEN_4;
  5927. }
  5928. case 'y':
  5929. {
  5930. if (str[7] && !strcmp(str[7], !"ELLOW", true, 5))
  5931. {
  5932. idx += 12;
  5933. return X11_GREEN_YELLOW;
  5934. }
  5935. }
  5936. }
  5937. }
  5938. }
  5939. case '_' | 0x20:
  5940. {
  5941. switch (str[6] | 0x20)
  5942. {
  5943. case '1':
  5944. {
  5945. idx += 7;
  5946. return X11_GREEN_1;
  5947. }
  5948. case '2':
  5949. {
  5950. idx += 7;
  5951. return X11_GREEN_2;
  5952. }
  5953. case '3':
  5954. {
  5955. idx += 7;
  5956. return X11_GREEN_3;
  5957. }
  5958. case '4':
  5959. {
  5960. idx += 7;
  5961. return X11_GREEN_4;
  5962. }
  5963. case 'y':
  5964. {
  5965. if (str[7] && !strcmp(str[7], !"ELLOW", true, 5))
  5966. {
  5967. idx += 12;
  5968. return X11_GREEN_YELLOW;
  5969. }
  5970. }
  5971. }
  5972. }
  5973. case '1':
  5974. {
  5975. idx += 6;
  5976. return X11_GREEN1;
  5977. }
  5978. case '2':
  5979. {
  5980. idx += 6;
  5981. return X11_GREEN2;
  5982. }
  5983. case '3':
  5984. {
  5985. idx += 6;
  5986. return X11_GREEN3;
  5987. }
  5988. case '4':
  5989. {
  5990. idx += 6;
  5991. return X11_GREEN4;
  5992. }
  5993. case 'y':
  5994. {
  5995. if (str[6] && !strcmp(str[6], !"ELLOW", true, 5))
  5996. {
  5997. idx += 11;
  5998. return X11_GREENYELLOW;
  5999. }
  6000. }
  6001. }
  6002. idx += 5;
  6003. return X11_GREEN;
  6004. }
  6005. case 'y':
  6006. {
  6007. switch (str[4] | 0x20)
  6008. {
  6009. case _X11_SPACE_SWITCH: // ' '
  6010. {
  6011. if (str[4])
  6012. {
  6013. switch (str[5] | 0x20)
  6014. {
  6015. case '0':
  6016. {
  6017. idx += 6;
  6018. return X11_GREY_0;
  6019. }
  6020. case '1':
  6021. {
  6022. switch (str[6] | 0x20)
  6023. {
  6024. case '0':
  6025. {
  6026. switch (str[7] | 0x20)
  6027. {
  6028. case '0':
  6029. {
  6030. idx += 8;
  6031. return X11_GREY_100;
  6032. }
  6033. }
  6034. idx += 7;
  6035. return X11_GREY_10;
  6036. }
  6037. case '1':
  6038. {
  6039. idx += 7;
  6040. return X11_GREY_11;
  6041. }
  6042. case '2':
  6043. {
  6044. idx += 7;
  6045. return X11_GREY_12;
  6046. }
  6047. case '3':
  6048. {
  6049. idx += 7;
  6050. return X11_GREY_13;
  6051. }
  6052. case '4':
  6053. {
  6054. idx += 7;
  6055. return X11_GREY_14;
  6056. }
  6057. case '5':
  6058. {
  6059. idx += 7;
  6060. return X11_GREY_15;
  6061. }
  6062. case '6':
  6063. {
  6064. idx += 7;
  6065. return X11_GREY_16;
  6066. }
  6067. case '7':
  6068. {
  6069. idx += 7;
  6070. return X11_GREY_17;
  6071. }
  6072. case '8':
  6073. {
  6074. idx += 7;
  6075. return X11_GREY_18;
  6076. }
  6077. case '9':
  6078. {
  6079. idx += 7;
  6080. return X11_GREY_19;
  6081. }
  6082. }
  6083. idx += 6;
  6084. return X11_GREY_1;
  6085. }
  6086. case '2':
  6087. {
  6088. switch (str[6] | 0x20)
  6089. {
  6090. case '0':
  6091. {
  6092. idx += 7;
  6093. return X11_GREY_20;
  6094. }
  6095. case '1':
  6096. {
  6097. idx += 7;
  6098. return X11_GREY_21;
  6099. }
  6100. case '2':
  6101. {
  6102. idx += 7;
  6103. return X11_GREY_22;
  6104. }
  6105. case '3':
  6106. {
  6107. idx += 7;
  6108. return X11_GREY_23;
  6109. }
  6110. case '4':
  6111. {
  6112. idx += 7;
  6113. return X11_GREY_24;
  6114. }
  6115. case '5':
  6116. {
  6117. idx += 7;
  6118. return X11_GREY_25;
  6119. }
  6120. case '6':
  6121. {
  6122. idx += 7;
  6123. return X11_GREY_26;
  6124. }
  6125. case '7':
  6126. {
  6127. idx += 7;
  6128. return X11_GREY_27;
  6129. }
  6130. case '8':
  6131. {
  6132. idx += 7;
  6133. return X11_GREY_28;
  6134. }
  6135. case '9':
  6136. {
  6137. idx += 7;
  6138. return X11_GREY_29;
  6139. }
  6140. }
  6141. idx += 6;
  6142. return X11_GREY_2;
  6143. }
  6144. case '3':
  6145. {
  6146. switch (str[6] | 0x20)
  6147. {
  6148. case '0':
  6149. {
  6150. idx += 7;
  6151. return X11_GREY_30;
  6152. }
  6153. case '1':
  6154. {
  6155. idx += 7;
  6156. return X11_GREY_31;
  6157. }
  6158. case '2':
  6159. {
  6160. idx += 7;
  6161. return X11_GREY_32;
  6162. }
  6163. case '3':
  6164. {
  6165. idx += 7;
  6166. return X11_GREY_33;
  6167. }
  6168. case '4':
  6169. {
  6170. idx += 7;
  6171. return X11_GREY_34;
  6172. }
  6173. case '5':
  6174. {
  6175. idx += 7;
  6176. return X11_GREY_35;
  6177. }
  6178. case '6':
  6179. {
  6180. idx += 7;
  6181. return X11_GREY_36;
  6182. }
  6183. case '7':
  6184. {
  6185. idx += 7;
  6186. return X11_GREY_37;
  6187. }
  6188. case '8':
  6189. {
  6190. idx += 7;
  6191. return X11_GREY_38;
  6192. }
  6193. case '9':
  6194. {
  6195. idx += 7;
  6196. return X11_GREY_39;
  6197. }
  6198. }
  6199. idx += 6;
  6200. return X11_GREY_3;
  6201. }
  6202. case '4':
  6203. {
  6204. switch (str[6] | 0x20)
  6205. {
  6206. case '0':
  6207. {
  6208. idx += 7;
  6209. return X11_GREY_40;
  6210. }
  6211. case '1':
  6212. {
  6213. idx += 7;
  6214. return X11_GREY_41;
  6215. }
  6216. case '2':
  6217. {
  6218. idx += 7;
  6219. return X11_GREY_42;
  6220. }
  6221. case '3':
  6222. {
  6223. idx += 7;
  6224. return X11_GREY_43;
  6225. }
  6226. case '4':
  6227. {
  6228. idx += 7;
  6229. return X11_GREY_44;
  6230. }
  6231. case '5':
  6232. {
  6233. idx += 7;
  6234. return X11_GREY_45;
  6235. }
  6236. case '6':
  6237. {
  6238. idx += 7;
  6239. return X11_GREY_46;
  6240. }
  6241. case '7':
  6242. {
  6243. idx += 7;
  6244. return X11_GREY_47;
  6245. }
  6246. case '8':
  6247. {
  6248. idx += 7;
  6249. return X11_GREY_48;
  6250. }
  6251. case '9':
  6252. {
  6253. idx += 7;
  6254. return X11_GREY_49;
  6255. }
  6256. }
  6257. idx += 6;
  6258. return X11_GREY_4;
  6259. }
  6260. case '5':
  6261. {
  6262. switch (str[6] | 0x20)
  6263. {
  6264. case '0':
  6265. {
  6266. idx += 7;
  6267. return X11_GREY_50;
  6268. }
  6269. case '1':
  6270. {
  6271. idx += 7;
  6272. return X11_GREY_51;
  6273. }
  6274. case '2':
  6275. {
  6276. idx += 7;
  6277. return X11_GREY_52;
  6278. }
  6279. case '3':
  6280. {
  6281. idx += 7;
  6282. return X11_GREY_53;
  6283. }
  6284. case '4':
  6285. {
  6286. idx += 7;
  6287. return X11_GREY_54;
  6288. }
  6289. case '5':
  6290. {
  6291. idx += 7;
  6292. return X11_GREY_55;
  6293. }
  6294. case '6':
  6295. {
  6296. idx += 7;
  6297. return X11_GREY_56;
  6298. }
  6299. case '7':
  6300. {
  6301. idx += 7;
  6302. return X11_GREY_57;
  6303. }
  6304. case '8':
  6305. {
  6306. idx += 7;
  6307. return X11_GREY_58;
  6308. }
  6309. case '9':
  6310. {
  6311. idx += 7;
  6312. return X11_GREY_59;
  6313. }
  6314. }
  6315. idx += 6;
  6316. return X11_GREY_5;
  6317. }
  6318. case '6':
  6319. {
  6320. switch (str[6] | 0x20)
  6321. {
  6322. case '0':
  6323. {
  6324. idx += 7;
  6325. return X11_GREY_60;
  6326. }
  6327. case '1':
  6328. {
  6329. idx += 7;
  6330. return X11_GREY_61;
  6331. }
  6332. case '2':
  6333. {
  6334. idx += 7;
  6335. return X11_GREY_62;
  6336. }
  6337. case '3':
  6338. {
  6339. idx += 7;
  6340. return X11_GREY_63;
  6341. }
  6342. case '4':
  6343. {
  6344. idx += 7;
  6345. return X11_GREY_64;
  6346. }
  6347. case '5':
  6348. {
  6349. idx += 7;
  6350. return X11_GREY_65;
  6351. }
  6352. case '6':
  6353. {
  6354. idx += 7;
  6355. return X11_GREY_66;
  6356. }
  6357. case '7':
  6358. {
  6359. idx += 7;
  6360. return X11_GREY_67;
  6361. }
  6362. case '8':
  6363. {
  6364. idx += 7;
  6365. return X11_GREY_68;
  6366. }
  6367. case '9':
  6368. {
  6369. idx += 7;
  6370. return X11_GREY_69;
  6371. }
  6372. }
  6373. idx += 6;
  6374. return X11_GREY_6;
  6375. }
  6376. case '7':
  6377. {
  6378. switch (str[6] | 0x20)
  6379. {
  6380. case '0':
  6381. {
  6382. idx += 7;
  6383. return X11_GREY_70;
  6384. }
  6385. case '1':
  6386. {
  6387. idx += 7;
  6388. return X11_GREY_71;
  6389. }
  6390. case '2':
  6391. {
  6392. idx += 7;
  6393. return X11_GREY_72;
  6394. }
  6395. case '3':
  6396. {
  6397. idx += 7;
  6398. return X11_GREY_73;
  6399. }
  6400. case '4':
  6401. {
  6402. idx += 7;
  6403. return X11_GREY_74;
  6404. }
  6405. case '5':
  6406. {
  6407. idx += 7;
  6408. return X11_GREY_75;
  6409. }
  6410. case '6':
  6411. {
  6412. idx += 7;
  6413. return X11_GREY_76;
  6414. }
  6415. case '7':
  6416. {
  6417. idx += 7;
  6418. return X11_GREY_77;
  6419. }
  6420. case '8':
  6421. {
  6422. idx += 7;
  6423. return X11_GREY_78;
  6424. }
  6425. case '9':
  6426. {
  6427. idx += 7;
  6428. return X11_GREY_79;
  6429. }
  6430. }
  6431. idx += 6;
  6432. return X11_GREY_7;
  6433. }
  6434. case '8':
  6435. {
  6436. switch (str[6] | 0x20)
  6437. {
  6438. case '0':
  6439. {
  6440. idx += 7;
  6441. return X11_GREY_80;
  6442. }
  6443. case '1':
  6444. {
  6445. idx += 7;
  6446. return X11_GREY_81;
  6447. }
  6448. case '2':
  6449. {
  6450. idx += 7;
  6451. return X11_GREY_82;
  6452. }
  6453. case '3':
  6454. {
  6455. idx += 7;
  6456. return X11_GREY_83;
  6457. }
  6458. case '4':
  6459. {
  6460. idx += 7;
  6461. return X11_GREY_84;
  6462. }
  6463. case '5':
  6464. {
  6465. idx += 7;
  6466. return X11_GREY_85;
  6467. }
  6468. case '6':
  6469. {
  6470. idx += 7;
  6471. return X11_GREY_86;
  6472. }
  6473. case '7':
  6474. {
  6475. idx += 7;
  6476. return X11_GREY_87;
  6477. }
  6478. case '8':
  6479. {
  6480. idx += 7;
  6481. return X11_GREY_88;
  6482. }
  6483. case '9':
  6484. {
  6485. idx += 7;
  6486. return X11_GREY_89;
  6487. }
  6488. }
  6489. idx += 6;
  6490. return X11_GREY_8;
  6491. }
  6492. case '9':
  6493. {
  6494. switch (str[6] | 0x20)
  6495. {
  6496. case '0':
  6497. {
  6498. idx += 7;
  6499. return X11_GREY_90;
  6500. }
  6501. case '1':
  6502. {
  6503. idx += 7;
  6504. return X11_GREY_91;
  6505. }
  6506. case '2':
  6507. {
  6508. idx += 7;
  6509. return X11_GREY_92;
  6510. }
  6511. case '3':
  6512. {
  6513. idx += 7;
  6514. return X11_GREY_93;
  6515. }
  6516. case '4':
  6517. {
  6518. idx += 7;
  6519. return X11_GREY_94;
  6520. }
  6521. case '5':
  6522. {
  6523. idx += 7;
  6524. return X11_GREY_95;
  6525. }
  6526. case '6':
  6527. {
  6528. idx += 7;
  6529. return X11_GREY_96;
  6530. }
  6531. case '7':
  6532. {
  6533. idx += 7;
  6534. return X11_GREY_97;
  6535. }
  6536. case '8':
  6537. {
  6538. idx += 7;
  6539. return X11_GREY_98;
  6540. }
  6541. case '9':
  6542. {
  6543. idx += 7;
  6544. return X11_GREY_99;
  6545. }
  6546. }
  6547. idx += 6;
  6548. return X11_GREY_9;
  6549. }
  6550. }
  6551. }
  6552. }
  6553. case '_' | 0x20:
  6554. {
  6555. switch (str[5] | 0x20)
  6556. {
  6557. case '0':
  6558. {
  6559. idx += 6;
  6560. return X11_GREY_0;
  6561. }
  6562. case '1':
  6563. {
  6564. switch (str[6] | 0x20)
  6565. {
  6566. case '0':
  6567. {
  6568. switch (str[7] | 0x20)
  6569. {
  6570. case '0':
  6571. {
  6572. idx += 8;
  6573. return X11_GREY_100;
  6574. }
  6575. }
  6576. idx += 7;
  6577. return X11_GREY_10;
  6578. }
  6579. case '1':
  6580. {
  6581. idx += 7;
  6582. return X11_GREY_11;
  6583. }
  6584. case '2':
  6585. {
  6586. idx += 7;
  6587. return X11_GREY_12;
  6588. }
  6589. case '3':
  6590. {
  6591. idx += 7;
  6592. return X11_GREY_13;
  6593. }
  6594. case '4':
  6595. {
  6596. idx += 7;
  6597. return X11_GREY_14;
  6598. }
  6599. case '5':
  6600. {
  6601. idx += 7;
  6602. return X11_GREY_15;
  6603. }
  6604. case '6':
  6605. {
  6606. idx += 7;
  6607. return X11_GREY_16;
  6608. }
  6609. case '7':
  6610. {
  6611. idx += 7;
  6612. return X11_GREY_17;
  6613. }
  6614. case '8':
  6615. {
  6616. idx += 7;
  6617. return X11_GREY_18;
  6618. }
  6619. case '9':
  6620. {
  6621. idx += 7;
  6622. return X11_GREY_19;
  6623. }
  6624. }
  6625. idx += 6;
  6626. return X11_GREY_1;
  6627. }
  6628. case '2':
  6629. {
  6630. switch (str[6] | 0x20)
  6631. {
  6632. case '0':
  6633. {
  6634. idx += 7;
  6635. return X11_GREY_20;
  6636. }
  6637. case '1':
  6638. {
  6639. idx += 7;
  6640. return X11_GREY_21;
  6641. }
  6642. case '2':
  6643. {
  6644. idx += 7;
  6645. return X11_GREY_22;
  6646. }
  6647. case '3':
  6648. {
  6649. idx += 7;
  6650. return X11_GREY_23;
  6651. }
  6652. case '4':
  6653. {
  6654. idx += 7;
  6655. return X11_GREY_24;
  6656. }
  6657. case '5':
  6658. {
  6659. idx += 7;
  6660. return X11_GREY_25;
  6661. }
  6662. case '6':
  6663. {
  6664. idx += 7;
  6665. return X11_GREY_26;
  6666. }
  6667. case '7':
  6668. {
  6669. idx += 7;
  6670. return X11_GREY_27;
  6671. }
  6672. case '8':
  6673. {
  6674. idx += 7;
  6675. return X11_GREY_28;
  6676. }
  6677. case '9':
  6678. {
  6679. idx += 7;
  6680. return X11_GREY_29;
  6681. }
  6682. }
  6683. idx += 6;
  6684. return X11_GREY_2;
  6685. }
  6686. case '3':
  6687. {
  6688. switch (str[6] | 0x20)
  6689. {
  6690. case '0':
  6691. {
  6692. idx += 7;
  6693. return X11_GREY_30;
  6694. }
  6695. case '1':
  6696. {
  6697. idx += 7;
  6698. return X11_GREY_31;
  6699. }
  6700. case '2':
  6701. {
  6702. idx += 7;
  6703. return X11_GREY_32;
  6704. }
  6705. case '3':
  6706. {
  6707. idx += 7;
  6708. return X11_GREY_33;
  6709. }
  6710. case '4':
  6711. {
  6712. idx += 7;
  6713. return X11_GREY_34;
  6714. }
  6715. case '5':
  6716. {
  6717. idx += 7;
  6718. return X11_GREY_35;
  6719. }
  6720. case '6':
  6721. {
  6722. idx += 7;
  6723. return X11_GREY_36;
  6724. }
  6725. case '7':
  6726. {
  6727. idx += 7;
  6728. return X11_GREY_37;
  6729. }
  6730. case '8':
  6731. {
  6732. idx += 7;
  6733. return X11_GREY_38;
  6734. }
  6735. case '9':
  6736. {
  6737. idx += 7;
  6738. return X11_GREY_39;
  6739. }
  6740. }
  6741. idx += 6;
  6742. return X11_GREY_3;
  6743. }
  6744. case '4':
  6745. {
  6746. switch (str[6] | 0x20)
  6747. {
  6748. case '0':
  6749. {
  6750. idx += 7;
  6751. return X11_GREY_40;
  6752. }
  6753. case '1':
  6754. {
  6755. idx += 7;
  6756. return X11_GREY_41;
  6757. }
  6758. case '2':
  6759. {
  6760. idx += 7;
  6761. return X11_GREY_42;
  6762. }
  6763. case '3':
  6764. {
  6765. idx += 7;
  6766. return X11_GREY_43;
  6767. }
  6768. case '4':
  6769. {
  6770. idx += 7;
  6771. return X11_GREY_44;
  6772. }
  6773. case '5':
  6774. {
  6775. idx += 7;
  6776. return X11_GREY_45;
  6777. }
  6778. case '6':
  6779. {
  6780. idx += 7;
  6781. return X11_GREY_46;
  6782. }
  6783. case '7':
  6784. {
  6785. idx += 7;
  6786. return X11_GREY_47;
  6787. }
  6788. case '8':
  6789. {
  6790. idx += 7;
  6791. return X11_GREY_48;
  6792. }
  6793. case '9':
  6794. {
  6795. idx += 7;
  6796. return X11_GREY_49;
  6797. }
  6798. }
  6799. idx += 6;
  6800. return X11_GREY_4;
  6801. }
  6802. case '5':
  6803. {
  6804. switch (str[6] | 0x20)
  6805. {
  6806. case '0':
  6807. {
  6808. idx += 7;
  6809. return X11_GREY_50;
  6810. }
  6811. case '1':
  6812. {
  6813. idx += 7;
  6814. return X11_GREY_51;
  6815. }
  6816. case '2':
  6817. {
  6818. idx += 7;
  6819. return X11_GREY_52;
  6820. }
  6821. case '3':
  6822. {
  6823. idx += 7;
  6824. return X11_GREY_53;
  6825. }
  6826. case '4':
  6827. {
  6828. idx += 7;
  6829. return X11_GREY_54;
  6830. }
  6831. case '5':
  6832. {
  6833. idx += 7;
  6834. return X11_GREY_55;
  6835. }
  6836. case '6':
  6837. {
  6838. idx += 7;
  6839. return X11_GREY_56;
  6840. }
  6841. case '7':
  6842. {
  6843. idx += 7;
  6844. return X11_GREY_57;
  6845. }
  6846. case '8':
  6847. {
  6848. idx += 7;
  6849. return X11_GREY_58;
  6850. }
  6851. case '9':
  6852. {
  6853. idx += 7;
  6854. return X11_GREY_59;
  6855. }
  6856. }
  6857. idx += 6;
  6858. return X11_GREY_5;
  6859. }
  6860. case '6':
  6861. {
  6862. switch (str[6] | 0x20)
  6863. {
  6864. case '0':
  6865. {
  6866. idx += 7;
  6867. return X11_GREY_60;
  6868. }
  6869. case '1':
  6870. {
  6871. idx += 7;
  6872. return X11_GREY_61;
  6873. }
  6874. case '2':
  6875. {
  6876. idx += 7;
  6877. return X11_GREY_62;
  6878. }
  6879. case '3':
  6880. {
  6881. idx += 7;
  6882. return X11_GREY_63;
  6883. }
  6884. case '4':
  6885. {
  6886. idx += 7;
  6887. return X11_GREY_64;
  6888. }
  6889. case '5':
  6890. {
  6891. idx += 7;
  6892. return X11_GREY_65;
  6893. }
  6894. case '6':
  6895. {
  6896. idx += 7;
  6897. return X11_GREY_66;
  6898. }
  6899. case '7':
  6900. {
  6901. idx += 7;
  6902. return X11_GREY_67;
  6903. }
  6904. case '8':
  6905. {
  6906. idx += 7;
  6907. return X11_GREY_68;
  6908. }
  6909. case '9':
  6910. {
  6911. idx += 7;
  6912. return X11_GREY_69;
  6913. }
  6914. }
  6915. idx += 6;
  6916. return X11_GREY_6;
  6917. }
  6918. case '7':
  6919. {
  6920. switch (str[6] | 0x20)
  6921. {
  6922. case '0':
  6923. {
  6924. idx += 7;
  6925. return X11_GREY_70;
  6926. }
  6927. case '1':
  6928. {
  6929. idx += 7;
  6930. return X11_GREY_71;
  6931. }
  6932. case '2':
  6933. {
  6934. idx += 7;
  6935. return X11_GREY_72;
  6936. }
  6937. case '3':
  6938. {
  6939. idx += 7;
  6940. return X11_GREY_73;
  6941. }
  6942. case '4':
  6943. {
  6944. idx += 7;
  6945. return X11_GREY_74;
  6946. }
  6947. case '5':
  6948. {
  6949. idx += 7;
  6950. return X11_GREY_75;
  6951. }
  6952. case '6':
  6953. {
  6954. idx += 7;
  6955. return X11_GREY_76;
  6956. }
  6957. case '7':
  6958. {
  6959. idx += 7;
  6960. return X11_GREY_77;
  6961. }
  6962. case '8':
  6963. {
  6964. idx += 7;
  6965. return X11_GREY_78;
  6966. }
  6967. case '9':
  6968. {
  6969. idx += 7;
  6970. return X11_GREY_79;
  6971. }
  6972. }
  6973. idx += 6;
  6974. return X11_GREY_7;
  6975. }
  6976. case '8':
  6977. {
  6978. switch (str[6] | 0x20)
  6979. {
  6980. case '0':
  6981. {
  6982. idx += 7;
  6983. return X11_GREY_80;
  6984. }
  6985. case '1':
  6986. {
  6987. idx += 7;
  6988. return X11_GREY_81;
  6989. }
  6990. case '2':
  6991. {
  6992. idx += 7;
  6993. return X11_GREY_82;
  6994. }
  6995. case '3':
  6996. {
  6997. idx += 7;
  6998. return X11_GREY_83;
  6999. }
  7000. case '4':
  7001. {
  7002. idx += 7;
  7003. return X11_GREY_84;
  7004. }
  7005. case '5':
  7006. {
  7007. idx += 7;
  7008. return X11_GREY_85;
  7009. }
  7010. case '6':
  7011. {
  7012. idx += 7;
  7013. return X11_GREY_86;
  7014. }
  7015. case '7':
  7016. {
  7017. idx += 7;
  7018. return X11_GREY_87;
  7019. }
  7020. case '8':
  7021. {
  7022. idx += 7;
  7023. return X11_GREY_88;
  7024. }
  7025. case '9':
  7026. {
  7027. idx += 7;
  7028. return X11_GREY_89;
  7029. }
  7030. }
  7031. idx += 6;
  7032. return X11_GREY_8;
  7033. }
  7034. case '9':
  7035. {
  7036. switch (str[6] | 0x20)
  7037. {
  7038. case '0':
  7039. {
  7040. idx += 7;
  7041. return X11_GREY_90;
  7042. }
  7043. case '1':
  7044. {
  7045. idx += 7;
  7046. return X11_GREY_91;
  7047. }
  7048. case '2':
  7049. {
  7050. idx += 7;
  7051. return X11_GREY_92;
  7052. }
  7053. case '3':
  7054. {
  7055. idx += 7;
  7056. return X11_GREY_93;
  7057. }
  7058. case '4':
  7059. {
  7060. idx += 7;
  7061. return X11_GREY_94;
  7062. }
  7063. case '5':
  7064. {
  7065. idx += 7;
  7066. return X11_GREY_95;
  7067. }
  7068. case '6':
  7069. {
  7070. idx += 7;
  7071. return X11_GREY_96;
  7072. }
  7073. case '7':
  7074. {
  7075. idx += 7;
  7076. return X11_GREY_97;
  7077. }
  7078. case '8':
  7079. {
  7080. idx += 7;
  7081. return X11_GREY_98;
  7082. }
  7083. case '9':
  7084. {
  7085. idx += 7;
  7086. return X11_GREY_99;
  7087. }
  7088. }
  7089. idx += 6;
  7090. return X11_GREY_9;
  7091. }
  7092. }
  7093. }
  7094. case '0':
  7095. {
  7096. idx += 5;
  7097. return X11_GREY0;
  7098. }
  7099. case '1':
  7100. {
  7101. switch (str[5] | 0x20)
  7102. {
  7103. case '0':
  7104. {
  7105. switch (str[6] | 0x20)
  7106. {
  7107. case '0':
  7108. {
  7109. idx += 7;
  7110. return X11_GREY100;
  7111. }
  7112. }
  7113. idx += 6;
  7114. return X11_GREY10;
  7115. }
  7116. case '1':
  7117. {
  7118. idx += 6;
  7119. return X11_GREY11;
  7120. }
  7121. case '2':
  7122. {
  7123. idx += 6;
  7124. return X11_GREY12;
  7125. }
  7126. case '3':
  7127. {
  7128. idx += 6;
  7129. return X11_GREY13;
  7130. }
  7131. case '4':
  7132. {
  7133. idx += 6;
  7134. return X11_GREY14;
  7135. }
  7136. case '5':
  7137. {
  7138. idx += 6;
  7139. return X11_GREY15;
  7140. }
  7141. case '6':
  7142. {
  7143. idx += 6;
  7144. return X11_GREY16;
  7145. }
  7146. case '7':
  7147. {
  7148. idx += 6;
  7149. return X11_GREY17;
  7150. }
  7151. case '8':
  7152. {
  7153. idx += 6;
  7154. return X11_GREY18;
  7155. }
  7156. case '9':
  7157. {
  7158. idx += 6;
  7159. return X11_GREY19;
  7160. }
  7161. }
  7162. idx += 5;
  7163. return X11_GREY1;
  7164. }
  7165. case '2':
  7166. {
  7167. switch (str[5] | 0x20)
  7168. {
  7169. case '0':
  7170. {
  7171. idx += 6;
  7172. return X11_GREY20;
  7173. }
  7174. case '1':
  7175. {
  7176. idx += 6;
  7177. return X11_GREY21;
  7178. }
  7179. case '2':
  7180. {
  7181. idx += 6;
  7182. return X11_GREY22;
  7183. }
  7184. case '3':
  7185. {
  7186. idx += 6;
  7187. return X11_GREY23;
  7188. }
  7189. case '4':
  7190. {
  7191. idx += 6;
  7192. return X11_GREY24;
  7193. }
  7194. case '5':
  7195. {
  7196. idx += 6;
  7197. return X11_GREY25;
  7198. }
  7199. case '6':
  7200. {
  7201. idx += 6;
  7202. return X11_GREY26;
  7203. }
  7204. case '7':
  7205. {
  7206. idx += 6;
  7207. return X11_GREY27;
  7208. }
  7209. case '8':
  7210. {
  7211. idx += 6;
  7212. return X11_GREY28;
  7213. }
  7214. case '9':
  7215. {
  7216. idx += 6;
  7217. return X11_GREY29;
  7218. }
  7219. }
  7220. idx += 5;
  7221. return X11_GREY2;
  7222. }
  7223. case '3':
  7224. {
  7225. switch (str[5] | 0x20)
  7226. {
  7227. case '0':
  7228. {
  7229. idx += 6;
  7230. return X11_GREY30;
  7231. }
  7232. case '1':
  7233. {
  7234. idx += 6;
  7235. return X11_GREY31;
  7236. }
  7237. case '2':
  7238. {
  7239. idx += 6;
  7240. return X11_GREY32;
  7241. }
  7242. case '3':
  7243. {
  7244. idx += 6;
  7245. return X11_GREY33;
  7246. }
  7247. case '4':
  7248. {
  7249. idx += 6;
  7250. return X11_GREY34;
  7251. }
  7252. case '5':
  7253. {
  7254. idx += 6;
  7255. return X11_GREY35;
  7256. }
  7257. case '6':
  7258. {
  7259. idx += 6;
  7260. return X11_GREY36;
  7261. }
  7262. case '7':
  7263. {
  7264. idx += 6;
  7265. return X11_GREY37;
  7266. }
  7267. case '8':
  7268. {
  7269. idx += 6;
  7270. return X11_GREY38;
  7271. }
  7272. case '9':
  7273. {
  7274. idx += 6;
  7275. return X11_GREY39;
  7276. }
  7277. }
  7278. idx += 5;
  7279. return X11_GREY3;
  7280. }
  7281. case '4':
  7282. {
  7283. switch (str[5] | 0x20)
  7284. {
  7285. case '0':
  7286. {
  7287. idx += 6;
  7288. return X11_GREY40;
  7289. }
  7290. case '1':
  7291. {
  7292. idx += 6;
  7293. return X11_GREY41;
  7294. }
  7295. case '2':
  7296. {
  7297. idx += 6;
  7298. return X11_GREY42;
  7299. }
  7300. case '3':
  7301. {
  7302. idx += 6;
  7303. return X11_GREY43;
  7304. }
  7305. case '4':
  7306. {
  7307. idx += 6;
  7308. return X11_GREY44;
  7309. }
  7310. case '5':
  7311. {
  7312. idx += 6;
  7313. return X11_GREY45;
  7314. }
  7315. case '6':
  7316. {
  7317. idx += 6;
  7318. return X11_GREY46;
  7319. }
  7320. case '7':
  7321. {
  7322. idx += 6;
  7323. return X11_GREY47;
  7324. }
  7325. case '8':
  7326. {
  7327. idx += 6;
  7328. return X11_GREY48;
  7329. }
  7330. case '9':
  7331. {
  7332. idx += 6;
  7333. return X11_GREY49;
  7334. }
  7335. }
  7336. idx += 5;
  7337. return X11_GREY4;
  7338. }
  7339. case '5':
  7340. {
  7341. switch (str[5] | 0x20)
  7342. {
  7343. case '0':
  7344. {
  7345. idx += 6;
  7346. return X11_GREY50;
  7347. }
  7348. case '1':
  7349. {
  7350. idx += 6;
  7351. return X11_GREY51;
  7352. }
  7353. case '2':
  7354. {
  7355. idx += 6;
  7356. return X11_GREY52;
  7357. }
  7358. case '3':
  7359. {
  7360. idx += 6;
  7361. return X11_GREY53;
  7362. }
  7363. case '4':
  7364. {
  7365. idx += 6;
  7366. return X11_GREY54;
  7367. }
  7368. case '5':
  7369. {
  7370. idx += 6;
  7371. return X11_GREY55;
  7372. }
  7373. case '6':
  7374. {
  7375. idx += 6;
  7376. return X11_GREY56;
  7377. }
  7378. case '7':
  7379. {
  7380. idx += 6;
  7381. return X11_GREY57;
  7382. }
  7383. case '8':
  7384. {
  7385. idx += 6;
  7386. return X11_GREY58;
  7387. }
  7388. case '9':
  7389. {
  7390. idx += 6;
  7391. return X11_GREY59;
  7392. }
  7393. }
  7394. idx += 5;
  7395. return X11_GREY5;
  7396. }
  7397. case '6':
  7398. {
  7399. switch (str[5] | 0x20)
  7400. {
  7401. case '0':
  7402. {
  7403. idx += 6;
  7404. return X11_GREY60;
  7405. }
  7406. case '1':
  7407. {
  7408. idx += 6;
  7409. return X11_GREY61;
  7410. }
  7411. case '2':
  7412. {
  7413. idx += 6;
  7414. return X11_GREY62;
  7415. }
  7416. case '3':
  7417. {
  7418. idx += 6;
  7419. return X11_GREY63;
  7420. }
  7421. case '4':
  7422. {
  7423. idx += 6;
  7424. return X11_GREY64;
  7425. }
  7426. case '5':
  7427. {
  7428. idx += 6;
  7429. return X11_GREY65;
  7430. }
  7431. case '6':
  7432. {
  7433. idx += 6;
  7434. return X11_GREY66;
  7435. }
  7436. case '7':
  7437. {
  7438. idx += 6;
  7439. return X11_GREY67;
  7440. }
  7441. case '8':
  7442. {
  7443. idx += 6;
  7444. return X11_GREY68;
  7445. }
  7446. case '9':
  7447. {
  7448. idx += 6;
  7449. return X11_GREY69;
  7450. }
  7451. }
  7452. idx += 5;
  7453. return X11_GREY6;
  7454. }
  7455. case '7':
  7456. {
  7457. switch (str[5] | 0x20)
  7458. {
  7459. case '0':
  7460. {
  7461. idx += 6;
  7462. return X11_GREY70;
  7463. }
  7464. case '1':
  7465. {
  7466. idx += 6;
  7467. return X11_GREY71;
  7468. }
  7469. case '2':
  7470. {
  7471. idx += 6;
  7472. return X11_GREY72;
  7473. }
  7474. case '3':
  7475. {
  7476. idx += 6;
  7477. return X11_GREY73;
  7478. }
  7479. case '4':
  7480. {
  7481. idx += 6;
  7482. return X11_GREY74;
  7483. }
  7484. case '5':
  7485. {
  7486. idx += 6;
  7487. return X11_GREY75;
  7488. }
  7489. case '6':
  7490. {
  7491. idx += 6;
  7492. return X11_GREY76;
  7493. }
  7494. case '7':
  7495. {
  7496. idx += 6;
  7497. return X11_GREY77;
  7498. }
  7499. case '8':
  7500. {
  7501. idx += 6;
  7502. return X11_GREY78;
  7503. }
  7504. case '9':
  7505. {
  7506. idx += 6;
  7507. return X11_GREY79;
  7508. }
  7509. }
  7510. idx += 5;
  7511. return X11_GREY7;
  7512. }
  7513. case '8':
  7514. {
  7515. switch (str[5] | 0x20)
  7516. {
  7517. case '0':
  7518. {
  7519. idx += 6;
  7520. return X11_GREY80;
  7521. }
  7522. case '1':
  7523. {
  7524. idx += 6;
  7525. return X11_GREY81;
  7526. }
  7527. case '2':
  7528. {
  7529. idx += 6;
  7530. return X11_GREY82;
  7531. }
  7532. case '3':
  7533. {
  7534. idx += 6;
  7535. return X11_GREY83;
  7536. }
  7537. case '4':
  7538. {
  7539. idx += 6;
  7540. return X11_GREY84;
  7541. }
  7542. case '5':
  7543. {
  7544. idx += 6;
  7545. return X11_GREY85;
  7546. }
  7547. case '6':
  7548. {
  7549. idx += 6;
  7550. return X11_GREY86;
  7551. }
  7552. case '7':
  7553. {
  7554. idx += 6;
  7555. return X11_GREY87;
  7556. }
  7557. case '8':
  7558. {
  7559. idx += 6;
  7560. return X11_GREY88;
  7561. }
  7562. case '9':
  7563. {
  7564. idx += 6;
  7565. return X11_GREY89;
  7566. }
  7567. }
  7568. idx += 5;
  7569. return X11_GREY8;
  7570. }
  7571. case '9':
  7572. {
  7573. switch (str[5] | 0x20)
  7574. {
  7575. case '0':
  7576. {
  7577. idx += 6;
  7578. return X11_GREY90;
  7579. }
  7580. case '1':
  7581. {
  7582. idx += 6;
  7583. return X11_GREY91;
  7584. }
  7585. case '2':
  7586. {
  7587. idx += 6;
  7588. return X11_GREY92;
  7589. }
  7590. case '3':
  7591. {
  7592. idx += 6;
  7593. return X11_GREY93;
  7594. }
  7595. case '4':
  7596. {
  7597. idx += 6;
  7598. return X11_GREY94;
  7599. }
  7600. case '5':
  7601. {
  7602. idx += 6;
  7603. return X11_GREY95;
  7604. }
  7605. case '6':
  7606. {
  7607. idx += 6;
  7608. return X11_GREY96;
  7609. }
  7610. case '7':
  7611. {
  7612. idx += 6;
  7613. return X11_GREY97;
  7614. }
  7615. case '8':
  7616. {
  7617. idx += 6;
  7618. return X11_GREY98;
  7619. }
  7620. case '9':
  7621. {
  7622. idx += 6;
  7623. return X11_GREY99;
  7624. }
  7625. }
  7626. idx += 5;
  7627. return X11_GREY9;
  7628. }
  7629. }
  7630. idx += 4;
  7631. return X11_GREY;
  7632. }
  7633. }
  7634. }
  7635. }
  7636. }
  7637. }
  7638. }
  7639. case 'h':
  7640. {
  7641. if (str[1] | 0x20 != 'o')
  7642. {
  7643. return -1;
  7644. }
  7645. switch (str[2] | 0x20)
  7646. {
  7647. case 'n':
  7648. {
  7649. if (!str[3] || strcmp(str[3], !"EYDEW", true, 5))
  7650. {
  7651. return -1;
  7652. }
  7653. switch (str[8] | 0x20)
  7654. {
  7655. case _X11_SPACE_SWITCH: // ' '
  7656. {
  7657. if (str[8])
  7658. {
  7659. switch (str[9] | 0x20)
  7660. {
  7661. case '1':
  7662. {
  7663. idx += 10;
  7664. return X11_HONEYDEW_1;
  7665. }
  7666. case '2':
  7667. {
  7668. idx += 10;
  7669. return X11_HONEYDEW_2;
  7670. }
  7671. case '3':
  7672. {
  7673. idx += 10;
  7674. return X11_HONEYDEW_3;
  7675. }
  7676. case '4':
  7677. {
  7678. idx += 10;
  7679. return X11_HONEYDEW_4;
  7680. }
  7681. }
  7682. }
  7683. }
  7684. case '_' | 0x20:
  7685. {
  7686. switch (str[9] | 0x20)
  7687. {
  7688. case '1':
  7689. {
  7690. idx += 10;
  7691. return X11_HONEYDEW_1;
  7692. }
  7693. case '2':
  7694. {
  7695. idx += 10;
  7696. return X11_HONEYDEW_2;
  7697. }
  7698. case '3':
  7699. {
  7700. idx += 10;
  7701. return X11_HONEYDEW_3;
  7702. }
  7703. case '4':
  7704. {
  7705. idx += 10;
  7706. return X11_HONEYDEW_4;
  7707. }
  7708. }
  7709. }
  7710. case '1':
  7711. {
  7712. idx += 9;
  7713. return X11_HONEYDEW1;
  7714. }
  7715. case '2':
  7716. {
  7717. idx += 9;
  7718. return X11_HONEYDEW2;
  7719. }
  7720. case '3':
  7721. {
  7722. idx += 9;
  7723. return X11_HONEYDEW3;
  7724. }
  7725. case '4':
  7726. {
  7727. idx += 9;
  7728. return X11_HONEYDEW4;
  7729. }
  7730. }
  7731. idx += 8;
  7732. return X11_HONEYDEW;
  7733. }
  7734. case 't':
  7735. {
  7736. switch (str[3] | 0x20)
  7737. {
  7738. case _X11_SPACE_SWITCH: // ' '
  7739. {
  7740. if (str[3])
  7741. {
  7742. if (!str[4] || strcmp(str[4], !"PINK", true, 4))
  7743. {
  7744. return -1;
  7745. }
  7746. switch (str[8] | 0x20)
  7747. {
  7748. case _X11_SPACE_SWITCH: // ' '
  7749. {
  7750. if (str[8])
  7751. {
  7752. switch (str[9] | 0x20)
  7753. {
  7754. case '1':
  7755. {
  7756. idx += 10;
  7757. return X11_HOT_PINK_1;
  7758. }
  7759. case '2':
  7760. {
  7761. idx += 10;
  7762. return X11_HOT_PINK_2;
  7763. }
  7764. case '3':
  7765. {
  7766. idx += 10;
  7767. return X11_HOT_PINK_3;
  7768. }
  7769. case '4':
  7770. {
  7771. idx += 10;
  7772. return X11_HOT_PINK_4;
  7773. }
  7774. }
  7775. }
  7776. }
  7777. case '_' | 0x20:
  7778. {
  7779. switch (str[9] | 0x20)
  7780. {
  7781. case '1':
  7782. {
  7783. idx += 10;
  7784. return X11_HOT_PINK_1;
  7785. }
  7786. case '2':
  7787. {
  7788. idx += 10;
  7789. return X11_HOT_PINK_2;
  7790. }
  7791. case '3':
  7792. {
  7793. idx += 10;
  7794. return X11_HOT_PINK_3;
  7795. }
  7796. case '4':
  7797. {
  7798. idx += 10;
  7799. return X11_HOT_PINK_4;
  7800. }
  7801. }
  7802. }
  7803. }
  7804. idx += 8;
  7805. return X11_HOT_PINK;
  7806. }
  7807. }
  7808. case '_' | 0x20:
  7809. {
  7810. if (!str[4] || strcmp(str[4], !"PINK", true, 4))
  7811. {
  7812. return -1;
  7813. }
  7814. switch (str[8] | 0x20)
  7815. {
  7816. case _X11_SPACE_SWITCH: // ' '
  7817. {
  7818. if (str[8])
  7819. {
  7820. switch (str[9] | 0x20)
  7821. {
  7822. case '1':
  7823. {
  7824. idx += 10;
  7825. return X11_HOT_PINK_1;
  7826. }
  7827. case '2':
  7828. {
  7829. idx += 10;
  7830. return X11_HOT_PINK_2;
  7831. }
  7832. case '3':
  7833. {
  7834. idx += 10;
  7835. return X11_HOT_PINK_3;
  7836. }
  7837. case '4':
  7838. {
  7839. idx += 10;
  7840. return X11_HOT_PINK_4;
  7841. }
  7842. }
  7843. }
  7844. }
  7845. case '_' | 0x20:
  7846. {
  7847. switch (str[9] | 0x20)
  7848. {
  7849. case '1':
  7850. {
  7851. idx += 10;
  7852. return X11_HOT_PINK_1;
  7853. }
  7854. case '2':
  7855. {
  7856. idx += 10;
  7857. return X11_HOT_PINK_2;
  7858. }
  7859. case '3':
  7860. {
  7861. idx += 10;
  7862. return X11_HOT_PINK_3;
  7863. }
  7864. case '4':
  7865. {
  7866. idx += 10;
  7867. return X11_HOT_PINK_4;
  7868. }
  7869. }
  7870. }
  7871. }
  7872. idx += 8;
  7873. return X11_HOT_PINK;
  7874. }
  7875. case 'p':
  7876. {
  7877. if (!str[4] || strcmp(str[4], !"INK", true, 3))
  7878. {
  7879. return -1;
  7880. }
  7881. switch (str[7] | 0x20)
  7882. {
  7883. case '1':
  7884. {
  7885. idx += 8;
  7886. return X11_HOTPINK1;
  7887. }
  7888. case '2':
  7889. {
  7890. idx += 8;
  7891. return X11_HOTPINK2;
  7892. }
  7893. case '3':
  7894. {
  7895. idx += 8;
  7896. return X11_HOTPINK3;
  7897. }
  7898. case '4':
  7899. {
  7900. idx += 8;
  7901. return X11_HOTPINK4;
  7902. }
  7903. }
  7904. idx += 7;
  7905. return X11_HOTPINK;
  7906. }
  7907. }
  7908. }
  7909. }
  7910. }
  7911. case 'i':
  7912. {
  7913. switch (str[1] | 0x20)
  7914. {
  7915. case 'n':
  7916. {
  7917. if (!str[2] || strcmp(str[2], !"DIAN", true, 4))
  7918. {
  7919. return -1;
  7920. }
  7921. switch (str[6] | 0x20)
  7922. {
  7923. case _X11_SPACE_SWITCH: // ' '
  7924. {
  7925. if (str[6])
  7926. {
  7927. if (!str[7] || strcmp(str[7], !"RED", true, 3))
  7928. {
  7929. return -1;
  7930. }
  7931. switch (str[10] | 0x20)
  7932. {
  7933. case _X11_SPACE_SWITCH: // ' '
  7934. {
  7935. if (str[10])
  7936. {
  7937. switch (str[11] | 0x20)
  7938. {
  7939. case '1':
  7940. {
  7941. idx += 12;
  7942. return X11_INDIAN_RED_1;
  7943. }
  7944. case '2':
  7945. {
  7946. idx += 12;
  7947. return X11_INDIAN_RED_2;
  7948. }
  7949. case '3':
  7950. {
  7951. idx += 12;
  7952. return X11_INDIAN_RED_3;
  7953. }
  7954. case '4':
  7955. {
  7956. idx += 12;
  7957. return X11_INDIAN_RED_4;
  7958. }
  7959. }
  7960. }
  7961. }
  7962. case '_' | 0x20:
  7963. {
  7964. switch (str[11] | 0x20)
  7965. {
  7966. case '1':
  7967. {
  7968. idx += 12;
  7969. return X11_INDIAN_RED_1;
  7970. }
  7971. case '2':
  7972. {
  7973. idx += 12;
  7974. return X11_INDIAN_RED_2;
  7975. }
  7976. case '3':
  7977. {
  7978. idx += 12;
  7979. return X11_INDIAN_RED_3;
  7980. }
  7981. case '4':
  7982. {
  7983. idx += 12;
  7984. return X11_INDIAN_RED_4;
  7985. }
  7986. }
  7987. }
  7988. }
  7989. idx += 10;
  7990. return X11_INDIAN_RED;
  7991. }
  7992. }
  7993. case '_' | 0x20:
  7994. {
  7995. if (!str[7] || strcmp(str[7], !"RED", true, 3))
  7996. {
  7997. return -1;
  7998. }
  7999. switch (str[10] | 0x20)
  8000. {
  8001. case _X11_SPACE_SWITCH: // ' '
  8002. {
  8003. if (str[10])
  8004. {
  8005. switch (str[11] | 0x20)
  8006. {
  8007. case '1':
  8008. {
  8009. idx += 12;
  8010. return X11_INDIAN_RED_1;
  8011. }
  8012. case '2':
  8013. {
  8014. idx += 12;
  8015. return X11_INDIAN_RED_2;
  8016. }
  8017. case '3':
  8018. {
  8019. idx += 12;
  8020. return X11_INDIAN_RED_3;
  8021. }
  8022. case '4':
  8023. {
  8024. idx += 12;
  8025. return X11_INDIAN_RED_4;
  8026. }
  8027. }
  8028. }
  8029. }
  8030. case '_' | 0x20:
  8031. {
  8032. switch (str[11] | 0x20)
  8033. {
  8034. case '1':
  8035. {
  8036. idx += 12;
  8037. return X11_INDIAN_RED_1;
  8038. }
  8039. case '2':
  8040. {
  8041. idx += 12;
  8042. return X11_INDIAN_RED_2;
  8043. }
  8044. case '3':
  8045. {
  8046. idx += 12;
  8047. return X11_INDIAN_RED_3;
  8048. }
  8049. case '4':
  8050. {
  8051. idx += 12;
  8052. return X11_INDIAN_RED_4;
  8053. }
  8054. }
  8055. }
  8056. }
  8057. idx += 10;
  8058. return X11_INDIAN_RED;
  8059. }
  8060. case 'r':
  8061. {
  8062. if (!str[7] || strcmp(str[7], !"ED", true, 2))
  8063. {
  8064. return -1;
  8065. }
  8066. switch (str[9] | 0x20)
  8067. {
  8068. case '1':
  8069. {
  8070. idx += 10;
  8071. return X11_INDIANRED1;
  8072. }
  8073. case '2':
  8074. {
  8075. idx += 10;
  8076. return X11_INDIANRED2;
  8077. }
  8078. case '3':
  8079. {
  8080. idx += 10;
  8081. return X11_INDIANRED3;
  8082. }
  8083. case '4':
  8084. {
  8085. idx += 10;
  8086. return X11_INDIANRED4;
  8087. }
  8088. }
  8089. idx += 9;
  8090. return X11_INDIANRED;
  8091. }
  8092. }
  8093. }
  8094. case 'v':
  8095. {
  8096. if (!str[2] || strcmp(str[2], !"ORY", true, 3))
  8097. {
  8098. return -1;
  8099. }
  8100. switch (str[5] | 0x20)
  8101. {
  8102. case _X11_SPACE_SWITCH: // ' '
  8103. {
  8104. if (str[5])
  8105. {
  8106. switch (str[6] | 0x20)
  8107. {
  8108. case '1':
  8109. {
  8110. idx += 7;
  8111. return X11_IVORY_1;
  8112. }
  8113. case '2':
  8114. {
  8115. idx += 7;
  8116. return X11_IVORY_2;
  8117. }
  8118. case '3':
  8119. {
  8120. idx += 7;
  8121. return X11_IVORY_3;
  8122. }
  8123. case '4':
  8124. {
  8125. idx += 7;
  8126. return X11_IVORY_4;
  8127. }
  8128. }
  8129. }
  8130. }
  8131. case '_' | 0x20:
  8132. {
  8133. switch (str[6] | 0x20)
  8134. {
  8135. case '1':
  8136. {
  8137. idx += 7;
  8138. return X11_IVORY_1;
  8139. }
  8140. case '2':
  8141. {
  8142. idx += 7;
  8143. return X11_IVORY_2;
  8144. }
  8145. case '3':
  8146. {
  8147. idx += 7;
  8148. return X11_IVORY_3;
  8149. }
  8150. case '4':
  8151. {
  8152. idx += 7;
  8153. return X11_IVORY_4;
  8154. }
  8155. }
  8156. }
  8157. case '1':
  8158. {
  8159. idx += 6;
  8160. return X11_IVORY1;
  8161. }
  8162. case '2':
  8163. {
  8164. idx += 6;
  8165. return X11_IVORY2;
  8166. }
  8167. case '3':
  8168. {
  8169. idx += 6;
  8170. return X11_IVORY3;
  8171. }
  8172. case '4':
  8173. {
  8174. idx += 6;
  8175. return X11_IVORY4;
  8176. }
  8177. }
  8178. idx += 5;
  8179. return X11_IVORY;
  8180. }
  8181. }
  8182. }
  8183. case 'k':
  8184. {
  8185. if (!str[1] || strcmp(str[1], !"HAKI", true, 4))
  8186. {
  8187. return -1;
  8188. }
  8189. switch (str[5] | 0x20)
  8190. {
  8191. case _X11_SPACE_SWITCH: // ' '
  8192. {
  8193. if (str[5])
  8194. {
  8195. switch (str[6] | 0x20)
  8196. {
  8197. case '1':
  8198. {
  8199. idx += 7;
  8200. return X11_KHAKI_1;
  8201. }
  8202. case '2':
  8203. {
  8204. idx += 7;
  8205. return X11_KHAKI_2;
  8206. }
  8207. case '3':
  8208. {
  8209. idx += 7;
  8210. return X11_KHAKI_3;
  8211. }
  8212. case '4':
  8213. {
  8214. idx += 7;
  8215. return X11_KHAKI_4;
  8216. }
  8217. }
  8218. }
  8219. }
  8220. case '_' | 0x20:
  8221. {
  8222. switch (str[6] | 0x20)
  8223. {
  8224. case '1':
  8225. {
  8226. idx += 7;
  8227. return X11_KHAKI_1;
  8228. }
  8229. case '2':
  8230. {
  8231. idx += 7;
  8232. return X11_KHAKI_2;
  8233. }
  8234. case '3':
  8235. {
  8236. idx += 7;
  8237. return X11_KHAKI_3;
  8238. }
  8239. case '4':
  8240. {
  8241. idx += 7;
  8242. return X11_KHAKI_4;
  8243. }
  8244. }
  8245. }
  8246. case '1':
  8247. {
  8248. idx += 6;
  8249. return X11_KHAKI1;
  8250. }
  8251. case '2':
  8252. {
  8253. idx += 6;
  8254. return X11_KHAKI2;
  8255. }
  8256. case '3':
  8257. {
  8258. idx += 6;
  8259. return X11_KHAKI3;
  8260. }
  8261. case '4':
  8262. {
  8263. idx += 6;
  8264. return X11_KHAKI4;
  8265. }
  8266. }
  8267. idx += 5;
  8268. return X11_KHAKI;
  8269. }
  8270. case 'l':
  8271. {
  8272. switch (str[1] | 0x20)
  8273. {
  8274. case 'a':
  8275. {
  8276. switch (str[2] | 0x20)
  8277. {
  8278. case 'v':
  8279. {
  8280. if (!str[3] || strcmp(str[3], !"ENDER", true, 5))
  8281. {
  8282. return -1;
  8283. }
  8284. switch (str[8] | 0x20)
  8285. {
  8286. case _X11_SPACE_SWITCH: // ' '
  8287. {
  8288. if (str[8])
  8289. {
  8290. if (!str[9] || strcmp(str[9], !"BLUSH", true, 5))
  8291. {
  8292. return -1;
  8293. }
  8294. switch (str[14] | 0x20)
  8295. {
  8296. case _X11_SPACE_SWITCH: // ' '
  8297. {
  8298. if (str[14])
  8299. {
  8300. switch (str[15] | 0x20)
  8301. {
  8302. case '1':
  8303. {
  8304. idx += 16;
  8305. return X11_LAVENDER_BLUSH_1;
  8306. }
  8307. case '2':
  8308. {
  8309. idx += 16;
  8310. return X11_LAVENDER_BLUSH_2;
  8311. }
  8312. case '3':
  8313. {
  8314. idx += 16;
  8315. return X11_LAVENDER_BLUSH_3;
  8316. }
  8317. case '4':
  8318. {
  8319. idx += 16;
  8320. return X11_LAVENDER_BLUSH_4;
  8321. }
  8322. }
  8323. }
  8324. }
  8325. case '_' | 0x20:
  8326. {
  8327. switch (str[15] | 0x20)
  8328. {
  8329. case '1':
  8330. {
  8331. idx += 16;
  8332. return X11_LAVENDER_BLUSH_1;
  8333. }
  8334. case '2':
  8335. {
  8336. idx += 16;
  8337. return X11_LAVENDER_BLUSH_2;
  8338. }
  8339. case '3':
  8340. {
  8341. idx += 16;
  8342. return X11_LAVENDER_BLUSH_3;
  8343. }
  8344. case '4':
  8345. {
  8346. idx += 16;
  8347. return X11_LAVENDER_BLUSH_4;
  8348. }
  8349. }
  8350. }
  8351. }
  8352. idx += 14;
  8353. return X11_LAVENDER_BLUSH;
  8354. }
  8355. }
  8356. case '_' | 0x20:
  8357. {
  8358. if (!str[9] || strcmp(str[9], !"BLUSH", true, 5))
  8359. {
  8360. return -1;
  8361. }
  8362. switch (str[14] | 0x20)
  8363. {
  8364. case _X11_SPACE_SWITCH: // ' '
  8365. {
  8366. if (str[14])
  8367. {
  8368. switch (str[15] | 0x20)
  8369. {
  8370. case '1':
  8371. {
  8372. idx += 16;
  8373. return X11_LAVENDER_BLUSH_1;
  8374. }
  8375. case '2':
  8376. {
  8377. idx += 16;
  8378. return X11_LAVENDER_BLUSH_2;
  8379. }
  8380. case '3':
  8381. {
  8382. idx += 16;
  8383. return X11_LAVENDER_BLUSH_3;
  8384. }
  8385. case '4':
  8386. {
  8387. idx += 16;
  8388. return X11_LAVENDER_BLUSH_4;
  8389. }
  8390. }
  8391. }
  8392. }
  8393. case '_' | 0x20:
  8394. {
  8395. switch (str[15] | 0x20)
  8396. {
  8397. case '1':
  8398. {
  8399. idx += 16;
  8400. return X11_LAVENDER_BLUSH_1;
  8401. }
  8402. case '2':
  8403. {
  8404. idx += 16;
  8405. return X11_LAVENDER_BLUSH_2;
  8406. }
  8407. case '3':
  8408. {
  8409. idx += 16;
  8410. return X11_LAVENDER_BLUSH_3;
  8411. }
  8412. case '4':
  8413. {
  8414. idx += 16;
  8415. return X11_LAVENDER_BLUSH_4;
  8416. }
  8417. }
  8418. }
  8419. }
  8420. idx += 14;
  8421. return X11_LAVENDER_BLUSH;
  8422. }
  8423. case 'b':
  8424. {
  8425. if (!str[9] || strcmp(str[9], !"LUSH", true, 4))
  8426. {
  8427. return -1;
  8428. }
  8429. switch (str[13] | 0x20)
  8430. {
  8431. case '1':
  8432. {
  8433. idx += 14;
  8434. return X11_LAVENDERBLUSH1;
  8435. }
  8436. case '2':
  8437. {
  8438. idx += 14;
  8439. return X11_LAVENDERBLUSH2;
  8440. }
  8441. case '3':
  8442. {
  8443. idx += 14;
  8444. return X11_LAVENDERBLUSH3;
  8445. }
  8446. case '4':
  8447. {
  8448. idx += 14;
  8449. return X11_LAVENDERBLUSH4;
  8450. }
  8451. }
  8452. idx += 13;
  8453. return X11_LAVENDERBLUSH;
  8454. }
  8455. }
  8456. idx += 8;
  8457. return X11_LAVENDER;
  8458. }
  8459. case 'w':
  8460. {
  8461. if (str[3] | 0x20 != 'n')
  8462. {
  8463. return -1;
  8464. }
  8465. switch (str[4] | 0x20)
  8466. {
  8467. case _X11_SPACE_SWITCH: // ' '
  8468. {
  8469. if (str[4])
  8470. {
  8471. if (str[5] && !strcmp(str[5], !"GREEN", true, 5))
  8472. {
  8473. idx += 10;
  8474. return X11_LAWN_GREEN;
  8475. }
  8476. }
  8477. }
  8478. case '_' | 0x20:
  8479. {
  8480. if (str[5] && !strcmp(str[5], !"GREEN", true, 5))
  8481. {
  8482. idx += 10;
  8483. return X11_LAWN_GREEN;
  8484. }
  8485. }
  8486. case 'g':
  8487. {
  8488. if (str[5] && !strcmp(str[5], !"REEN", true, 4))
  8489. {
  8490. idx += 9;
  8491. return X11_LAWNGREEN;
  8492. }
  8493. }
  8494. }
  8495. }
  8496. }
  8497. }
  8498. case 'e':
  8499. {
  8500. if (!str[2] || strcmp(str[2], !"MON", true, 3))
  8501. {
  8502. return -1;
  8503. }
  8504. switch (str[5] | 0x20)
  8505. {
  8506. case _X11_SPACE_SWITCH: // ' '
  8507. {
  8508. if (str[5])
  8509. {
  8510. if (!str[6] || strcmp(str[6], !"CHIFFON", true, 7))
  8511. {
  8512. return -1;
  8513. }
  8514. switch (str[13] | 0x20)
  8515. {
  8516. case _X11_SPACE_SWITCH: // ' '
  8517. {
  8518. if (str[13])
  8519. {
  8520. switch (str[14] | 0x20)
  8521. {
  8522. case '1':
  8523. {
  8524. idx += 15;
  8525. return X11_LEMON_CHIFFON_1;
  8526. }
  8527. case '2':
  8528. {
  8529. idx += 15;
  8530. return X11_LEMON_CHIFFON_2;
  8531. }
  8532. case '3':
  8533. {
  8534. idx += 15;
  8535. return X11_LEMON_CHIFFON_3;
  8536. }
  8537. case '4':
  8538. {
  8539. idx += 15;
  8540. return X11_LEMON_CHIFFON_4;
  8541. }
  8542. }
  8543. }
  8544. }
  8545. case '_' | 0x20:
  8546. {
  8547. switch (str[14] | 0x20)
  8548. {
  8549. case '1':
  8550. {
  8551. idx += 15;
  8552. return X11_LEMON_CHIFFON_1;
  8553. }
  8554. case '2':
  8555. {
  8556. idx += 15;
  8557. return X11_LEMON_CHIFFON_2;
  8558. }
  8559. case '3':
  8560. {
  8561. idx += 15;
  8562. return X11_LEMON_CHIFFON_3;
  8563. }
  8564. case '4':
  8565. {
  8566. idx += 15;
  8567. return X11_LEMON_CHIFFON_4;
  8568. }
  8569. }
  8570. }
  8571. }
  8572. idx += 13;
  8573. return X11_LEMON_CHIFFON;
  8574. }
  8575. }
  8576. case '_' | 0x20:
  8577. {
  8578. if (!str[6] || strcmp(str[6], !"CHIFFON", true, 7))
  8579. {
  8580. return -1;
  8581. }
  8582. switch (str[13] | 0x20)
  8583. {
  8584. case _X11_SPACE_SWITCH: // ' '
  8585. {
  8586. if (str[13])
  8587. {
  8588. switch (str[14] | 0x20)
  8589. {
  8590. case '1':
  8591. {
  8592. idx += 15;
  8593. return X11_LEMON_CHIFFON_1;
  8594. }
  8595. case '2':
  8596. {
  8597. idx += 15;
  8598. return X11_LEMON_CHIFFON_2;
  8599. }
  8600. case '3':
  8601. {
  8602. idx += 15;
  8603. return X11_LEMON_CHIFFON_3;
  8604. }
  8605. case '4':
  8606. {
  8607. idx += 15;
  8608. return X11_LEMON_CHIFFON_4;
  8609. }
  8610. }
  8611. }
  8612. }
  8613. case '_' | 0x20:
  8614. {
  8615. switch (str[14] | 0x20)
  8616. {
  8617. case '1':
  8618. {
  8619. idx += 15;
  8620. return X11_LEMON_CHIFFON_1;
  8621. }
  8622. case '2':
  8623. {
  8624. idx += 15;
  8625. return X11_LEMON_CHIFFON_2;
  8626. }
  8627. case '3':
  8628. {
  8629. idx += 15;
  8630. return X11_LEMON_CHIFFON_3;
  8631. }
  8632. case '4':
  8633. {
  8634. idx += 15;
  8635. return X11_LEMON_CHIFFON_4;
  8636. }
  8637. }
  8638. }
  8639. }
  8640. idx += 13;
  8641. return X11_LEMON_CHIFFON;
  8642. }
  8643. case 'c':
  8644. {
  8645. if (!str[6] || strcmp(str[6], !"HIFFON", true, 6))
  8646. {
  8647. return -1;
  8648. }
  8649. switch (str[12] | 0x20)
  8650. {
  8651. case '1':
  8652. {
  8653. idx += 13;
  8654. return X11_LEMONCHIFFON1;
  8655. }
  8656. case '2':
  8657. {
  8658. idx += 13;
  8659. return X11_LEMONCHIFFON2;
  8660. }
  8661. case '3':
  8662. {
  8663. idx += 13;
  8664. return X11_LEMONCHIFFON3;
  8665. }
  8666. case '4':
  8667. {
  8668. idx += 13;
  8669. return X11_LEMONCHIFFON4;
  8670. }
  8671. }
  8672. idx += 12;
  8673. return X11_LEMONCHIFFON;
  8674. }
  8675. }
  8676. }
  8677. case 'i':
  8678. {
  8679. switch (str[2] | 0x20)
  8680. {
  8681. case 'g':
  8682. {
  8683. if (!str[3] || strcmp(str[3], !"HT", true, 2))
  8684. {
  8685. return -1;
  8686. }
  8687. switch (str[5] | 0x20)
  8688. {
  8689. case _X11_SPACE_SWITCH: // ' '
  8690. {
  8691. if (str[5])
  8692. {
  8693. switch (str[6] | 0x20)
  8694. {
  8695. case 'b':
  8696. {
  8697. if (!str[7] || strcmp(str[7], !"LUE", true, 3))
  8698. {
  8699. return -1;
  8700. }
  8701. switch (str[10] | 0x20)
  8702. {
  8703. case _X11_SPACE_SWITCH: // ' '
  8704. {
  8705. if (str[10])
  8706. {
  8707. switch (str[11] | 0x20)
  8708. {
  8709. case '1':
  8710. {
  8711. idx += 12;
  8712. return X11_LIGHT_BLUE_1;
  8713. }
  8714. case '2':
  8715. {
  8716. idx += 12;
  8717. return X11_LIGHT_BLUE_2;
  8718. }
  8719. case '3':
  8720. {
  8721. idx += 12;
  8722. return X11_LIGHT_BLUE_3;
  8723. }
  8724. case '4':
  8725. {
  8726. idx += 12;
  8727. return X11_LIGHT_BLUE_4;
  8728. }
  8729. }
  8730. }
  8731. }
  8732. case '_' | 0x20:
  8733. {
  8734. switch (str[11] | 0x20)
  8735. {
  8736. case '1':
  8737. {
  8738. idx += 12;
  8739. return X11_LIGHT_BLUE_1;
  8740. }
  8741. case '2':
  8742. {
  8743. idx += 12;
  8744. return X11_LIGHT_BLUE_2;
  8745. }
  8746. case '3':
  8747. {
  8748. idx += 12;
  8749. return X11_LIGHT_BLUE_3;
  8750. }
  8751. case '4':
  8752. {
  8753. idx += 12;
  8754. return X11_LIGHT_BLUE_4;
  8755. }
  8756. }
  8757. }
  8758. }
  8759. idx += 10;
  8760. return X11_LIGHT_BLUE;
  8761. }
  8762. case 'c':
  8763. {
  8764. switch (str[7] | 0x20)
  8765. {
  8766. case 'o':
  8767. {
  8768. if (str[8] && !strcmp(str[8], !"RAL", true, 3))
  8769. {
  8770. idx += 11;
  8771. return X11_LIGHT_CORAL;
  8772. }
  8773. }
  8774. case 'y':
  8775. {
  8776. if (!str[8] || strcmp(str[8], !"AN", true, 2))
  8777. {
  8778. return -1;
  8779. }
  8780. switch (str[10] | 0x20)
  8781. {
  8782. case _X11_SPACE_SWITCH: // ' '
  8783. {
  8784. if (str[10])
  8785. {
  8786. switch (str[11] | 0x20)
  8787. {
  8788. case '1':
  8789. {
  8790. idx += 12;
  8791. return X11_LIGHT_CYAN_1;
  8792. }
  8793. case '2':
  8794. {
  8795. idx += 12;
  8796. return X11_LIGHT_CYAN_2;
  8797. }
  8798. case '3':
  8799. {
  8800. idx += 12;
  8801. return X11_LIGHT_CYAN_3;
  8802. }
  8803. case '4':
  8804. {
  8805. idx += 12;
  8806. return X11_LIGHT_CYAN_4;
  8807. }
  8808. }
  8809. }
  8810. }
  8811. case '_' | 0x20:
  8812. {
  8813. switch (str[11] | 0x20)
  8814. {
  8815. case '1':
  8816. {
  8817. idx += 12;
  8818. return X11_LIGHT_CYAN_1;
  8819. }
  8820. case '2':
  8821. {
  8822. idx += 12;
  8823. return X11_LIGHT_CYAN_2;
  8824. }
  8825. case '3':
  8826. {
  8827. idx += 12;
  8828. return X11_LIGHT_CYAN_3;
  8829. }
  8830. case '4':
  8831. {
  8832. idx += 12;
  8833. return X11_LIGHT_CYAN_4;
  8834. }
  8835. }
  8836. }
  8837. }
  8838. idx += 10;
  8839. return X11_LIGHT_CYAN;
  8840. }
  8841. }
  8842. }
  8843. case 'g':
  8844. {
  8845. switch (str[7] | 0x20)
  8846. {
  8847. case 'o':
  8848. {
  8849. if (!str[8] || strcmp(str[8], !"LDENROD", true, 7))
  8850. {
  8851. return -1;
  8852. }
  8853. switch (str[15] | 0x20)
  8854. {
  8855. case _X11_SPACE_SWITCH: // ' '
  8856. {
  8857. if (str[15])
  8858. {
  8859. switch (str[16] | 0x20)
  8860. {
  8861. case '1':
  8862. {
  8863. idx += 17;
  8864. return X11_LIGHT_GOLDENROD_1;
  8865. }
  8866. case '2':
  8867. {
  8868. idx += 17;
  8869. return X11_LIGHT_GOLDENROD_2;
  8870. }
  8871. case '3':
  8872. {
  8873. idx += 17;
  8874. return X11_LIGHT_GOLDENROD_3;
  8875. }
  8876. case '4':
  8877. {
  8878. idx += 17;
  8879. return X11_LIGHT_GOLDENROD_4;
  8880. }
  8881. case 'y':
  8882. {
  8883. if (str[17] && !strcmp(str[17], !"ELLOW", true, 5))
  8884. {
  8885. idx += 22;
  8886. return X11_LIGHT_GOLDENROD_YELLOW;
  8887. }
  8888. }
  8889. }
  8890. }
  8891. }
  8892. case '_' | 0x20:
  8893. {
  8894. switch (str[16] | 0x20)
  8895. {
  8896. case '1':
  8897. {
  8898. idx += 17;
  8899. return X11_LIGHT_GOLDENROD_1;
  8900. }
  8901. case '2':
  8902. {
  8903. idx += 17;
  8904. return X11_LIGHT_GOLDENROD_2;
  8905. }
  8906. case '3':
  8907. {
  8908. idx += 17;
  8909. return X11_LIGHT_GOLDENROD_3;
  8910. }
  8911. case '4':
  8912. {
  8913. idx += 17;
  8914. return X11_LIGHT_GOLDENROD_4;
  8915. }
  8916. case 'y':
  8917. {
  8918. if (str[17] && !strcmp(str[17], !"ELLOW", true, 5))
  8919. {
  8920. idx += 22;
  8921. return X11_LIGHT_GOLDENROD_YELLOW;
  8922. }
  8923. }
  8924. }
  8925. }
  8926. }
  8927. idx += 15;
  8928. return X11_LIGHT_GOLDENROD;
  8929. }
  8930. case 'r':
  8931. {
  8932. switch (str[8] | 0x20)
  8933. {
  8934. case 'a':
  8935. {
  8936. if (str[9] | 0x20 == 'y')
  8937. {
  8938. idx += 10;
  8939. return X11_LIGHT_GRAY;
  8940. }
  8941. }
  8942. case 'e':
  8943. {
  8944. switch (str[9] | 0x20)
  8945. {
  8946. case 'e':
  8947. {
  8948. if (str[10] | 0x20 == 'n')
  8949. {
  8950. idx += 11;
  8951. return X11_LIGHT_GREEN;
  8952. }
  8953. }
  8954. case 'y':
  8955. {
  8956. idx += 10;
  8957. return X11_LIGHT_GREY;
  8958. }
  8959. }
  8960. }
  8961. }
  8962. }
  8963. }
  8964. }
  8965. case 'p':
  8966. {
  8967. if (!str[7] || strcmp(str[7], !"INK", true, 3))
  8968. {
  8969. return -1;
  8970. }
  8971. switch (str[10] | 0x20)
  8972. {
  8973. case _X11_SPACE_SWITCH: // ' '
  8974. {
  8975. if (str[10])
  8976. {
  8977. switch (str[11] | 0x20)
  8978. {
  8979. case '1':
  8980. {
  8981. idx += 12;
  8982. return X11_LIGHT_PINK_1;
  8983. }
  8984. case '2':
  8985. {
  8986. idx += 12;
  8987. return X11_LIGHT_PINK_2;
  8988. }
  8989. case '3':
  8990. {
  8991. idx += 12;
  8992. return X11_LIGHT_PINK_3;
  8993. }
  8994. case '4':
  8995. {
  8996. idx += 12;
  8997. return X11_LIGHT_PINK_4;
  8998. }
  8999. }
  9000. }
  9001. }
  9002. case '_' | 0x20:
  9003. {
  9004. switch (str[11] | 0x20)
  9005. {
  9006. case '1':
  9007. {
  9008. idx += 12;
  9009. return X11_LIGHT_PINK_1;
  9010. }
  9011. case '2':
  9012. {
  9013. idx += 12;
  9014. return X11_LIGHT_PINK_2;
  9015. }
  9016. case '3':
  9017. {
  9018. idx += 12;
  9019. return X11_LIGHT_PINK_3;
  9020. }
  9021. case '4':
  9022. {
  9023. idx += 12;
  9024. return X11_LIGHT_PINK_4;
  9025. }
  9026. }
  9027. }
  9028. }
  9029. idx += 10;
  9030. return X11_LIGHT_PINK;
  9031. }
  9032. case 's':
  9033. {
  9034. switch (str[7] | 0x20)
  9035. {
  9036. case 'a':
  9037. {
  9038. if (!str[8] || strcmp(str[8], !"LMON", true, 4))
  9039. {
  9040. return -1;
  9041. }
  9042. switch (str[12] | 0x20)
  9043. {
  9044. case _X11_SPACE_SWITCH: // ' '
  9045. {
  9046. if (str[12])
  9047. {
  9048. switch (str[13] | 0x20)
  9049. {
  9050. case '1':
  9051. {
  9052. idx += 14;
  9053. return X11_LIGHT_SALMON_1;
  9054. }
  9055. case '2':
  9056. {
  9057. idx += 14;
  9058. return X11_LIGHT_SALMON_2;
  9059. }
  9060. case '3':
  9061. {
  9062. idx += 14;
  9063. return X11_LIGHT_SALMON_3;
  9064. }
  9065. case '4':
  9066. {
  9067. idx += 14;
  9068. return X11_LIGHT_SALMON_4;
  9069. }
  9070. }
  9071. }
  9072. }
  9073. case '_' | 0x20:
  9074. {
  9075. switch (str[13] | 0x20)
  9076. {
  9077. case '1':
  9078. {
  9079. idx += 14;
  9080. return X11_LIGHT_SALMON_1;
  9081. }
  9082. case '2':
  9083. {
  9084. idx += 14;
  9085. return X11_LIGHT_SALMON_2;
  9086. }
  9087. case '3':
  9088. {
  9089. idx += 14;
  9090. return X11_LIGHT_SALMON_3;
  9091. }
  9092. case '4':
  9093. {
  9094. idx += 14;
  9095. return X11_LIGHT_SALMON_4;
  9096. }
  9097. }
  9098. }
  9099. }
  9100. idx += 12;
  9101. return X11_LIGHT_SALMON;
  9102. }
  9103. case 'e':
  9104. {
  9105. //if (str[8] && !strcmp(str[8], !"A_GREEN", true, 7))
  9106. if (str[8] | 0x20 == 'a' && (_X11_SPACE_CHECK(9) || str[9] == '_') && !strcmp(str[10], !"GREEN", true, 5))
  9107. {
  9108. idx += 15;
  9109. return X11_LIGHT_SEA_GREEN;
  9110. }
  9111. }
  9112. case 'k':
  9113. {
  9114. //if (!str[8] || strcmp(str[8], !"Y_BLUE", true, 6))
  9115. if (str[8] | 0x20 != 'y' || (!_X11_SPACE_CHECK(9) && str[9] != '_') || strcmp(str[10], !"BLUE", true, 4))
  9116. {
  9117. return -1;
  9118. }
  9119. switch (str[14] | 0x20)
  9120. {
  9121. case _X11_SPACE_SWITCH: // ' '
  9122. {
  9123. if (str[14])
  9124. {
  9125. switch (str[15] | 0x20)
  9126. {
  9127. case '1':
  9128. {
  9129. idx += 16;
  9130. return X11_LIGHT_SKY_BLUE_1;
  9131. }
  9132. case '2':
  9133. {
  9134. idx += 16;
  9135. return X11_LIGHT_SKY_BLUE_2;
  9136. }
  9137. case '3':
  9138. {
  9139. idx += 16;
  9140. return X11_LIGHT_SKY_BLUE_3;
  9141. }
  9142. case '4':
  9143. {
  9144. idx += 16;
  9145. return X11_LIGHT_SKY_BLUE_4;
  9146. }
  9147. }
  9148. }
  9149. }
  9150. case '_' | 0x20:
  9151. {
  9152. switch (str[15] | 0x20)
  9153. {
  9154. case '1':
  9155. {
  9156. idx += 16;
  9157. return X11_LIGHT_SKY_BLUE_1;
  9158. }
  9159. case '2':
  9160. {
  9161. idx += 16;
  9162. return X11_LIGHT_SKY_BLUE_2;
  9163. }
  9164. case '3':
  9165. {
  9166. idx += 16;
  9167. return X11_LIGHT_SKY_BLUE_3;
  9168. }
  9169. case '4':
  9170. {
  9171. idx += 16;
  9172. return X11_LIGHT_SKY_BLUE_4;
  9173. }
  9174. }
  9175. }
  9176. }
  9177. idx += 14;
  9178. return X11_LIGHT_SKY_BLUE;
  9179. }
  9180. case 'l':
  9181. {
  9182. //if (!str[8] || strcmp(str[8], !"ATE_", true, 4))
  9183. if (!str[8] || strcmp(str[8], !"ATE", true, 3) || (!_X11_SPACE_CHECK(11) && str[11] != '_'))
  9184. {
  9185. return -1;
  9186. }
  9187. switch (str[12] | 0x20)
  9188. {
  9189. case 'b':
  9190. {
  9191. if (str[13] && !strcmp(str[13], !"LUE", true, 3))
  9192. {
  9193. idx += 16;
  9194. return X11_LIGHT_SLATE_BLUE;
  9195. }
  9196. }
  9197. case 'g':
  9198. {
  9199. if (str[13] | 0x20 != 'r')
  9200. {
  9201. return -1;
  9202. }
  9203. switch (str[14] | 0x20)
  9204. {
  9205. case 'a':
  9206. {
  9207. if (str[15] | 0x20 == 'y')
  9208. {
  9209. idx += 16;
  9210. return X11_LIGHT_SLATE_GRAY;
  9211. }
  9212. }
  9213. case 'e':
  9214. {
  9215. if (str[15] | 0x20 == 'y')
  9216. {
  9217. idx += 16;
  9218. return X11_LIGHT_SLATE_GREY;
  9219. }
  9220. }
  9221. }
  9222. }
  9223. }
  9224. }
  9225. case 't':
  9226. {
  9227. //if (!str[8] || strcmp(str[8], !"EEL_BLUE", true, 8))
  9228. if (!str[8] || strcmp(str[8], !"EEL", true, 3) || (!_X11_SPACE_CHECK(11) && str[11] != '_') || strcmp(str[12], !"BLUE", true, 4))
  9229. {
  9230. return -1;
  9231. }
  9232. switch (str[16] | 0x20)
  9233. {
  9234. case _X11_SPACE_SWITCH: // ' '
  9235. {
  9236. if (str[16])
  9237. {
  9238. switch (str[17] | 0x20)
  9239. {
  9240. case '1':
  9241. {
  9242. idx += 18;
  9243. return X11_LIGHT_STEEL_BLUE_1;
  9244. }
  9245. case '2':
  9246. {
  9247. idx += 18;
  9248. return X11_LIGHT_STEEL_BLUE_2;
  9249. }
  9250. case '3':
  9251. {
  9252. idx += 18;
  9253. return X11_LIGHT_STEEL_BLUE_3;
  9254. }
  9255. case '4':
  9256. {
  9257. idx += 18;
  9258. return X11_LIGHT_STEEL_BLUE_4;
  9259. }
  9260. }
  9261. }
  9262. }
  9263. case '_' | 0x20:
  9264. {
  9265. switch (str[17] | 0x20)
  9266. {
  9267. case '1':
  9268. {
  9269. idx += 18;
  9270. return X11_LIGHT_STEEL_BLUE_1;
  9271. }
  9272. case '2':
  9273. {
  9274. idx += 18;
  9275. return X11_LIGHT_STEEL_BLUE_2;
  9276. }
  9277. case '3':
  9278. {
  9279. idx += 18;
  9280. return X11_LIGHT_STEEL_BLUE_3;
  9281. }
  9282. case '4':
  9283. {
  9284. idx += 18;
  9285. return X11_LIGHT_STEEL_BLUE_4;
  9286. }
  9287. }
  9288. }
  9289. }
  9290. idx += 16;
  9291. return X11_LIGHT_STEEL_BLUE;
  9292. }
  9293. }
  9294. }
  9295. case 'y':
  9296. {
  9297. if (!str[7] || strcmp(str[7], !"ELLOW", true, 5))
  9298. {
  9299. return -1;
  9300. }
  9301. switch (str[12] | 0x20)
  9302. {
  9303. case _X11_SPACE_SWITCH: // ' '
  9304. {
  9305. if (str[12])
  9306. {
  9307. switch (str[13] | 0x20)
  9308. {
  9309. case '1':
  9310. {
  9311. idx += 14;
  9312. return X11_LIGHT_YELLOW_1;
  9313. }
  9314. case '2':
  9315. {
  9316. idx += 14;
  9317. return X11_LIGHT_YELLOW_2;
  9318. }
  9319. case '3':
  9320. {
  9321. idx += 14;
  9322. return X11_LIGHT_YELLOW_3;
  9323. }
  9324. case '4':
  9325. {
  9326. idx += 14;
  9327. return X11_LIGHT_YELLOW_4;
  9328. }
  9329. }
  9330. }
  9331. }
  9332. case '_' | 0x20:
  9333. {
  9334. switch (str[13] | 0x20)
  9335. {
  9336. case '1':
  9337. {
  9338. idx += 14;
  9339. return X11_LIGHT_YELLOW_1;
  9340. }
  9341. case '2':
  9342. {
  9343. idx += 14;
  9344. return X11_LIGHT_YELLOW_2;
  9345. }
  9346. case '3':
  9347. {
  9348. idx += 14;
  9349. return X11_LIGHT_YELLOW_3;
  9350. }
  9351. case '4':
  9352. {
  9353. idx += 14;
  9354. return X11_LIGHT_YELLOW_4;
  9355. }
  9356. }
  9357. }
  9358. }
  9359. idx += 12;
  9360. return X11_LIGHT_YELLOW;
  9361. }
  9362. }
  9363. }
  9364. }
  9365. case '_' | 0x20:
  9366. {
  9367. switch (str[6] | 0x20)
  9368. {
  9369. case 'b':
  9370. {
  9371. if (!str[7] || strcmp(str[7], !"LUE", true, 3))
  9372. {
  9373. return -1;
  9374. }
  9375. switch (str[10] | 0x20)
  9376. {
  9377. case _X11_SPACE_SWITCH: // ' '
  9378. {
  9379. if (str[10])
  9380. {
  9381. switch (str[11] | 0x20)
  9382. {
  9383. case '1':
  9384. {
  9385. idx += 12;
  9386. return X11_LIGHT_BLUE_1;
  9387. }
  9388. case '2':
  9389. {
  9390. idx += 12;
  9391. return X11_LIGHT_BLUE_2;
  9392. }
  9393. case '3':
  9394. {
  9395. idx += 12;
  9396. return X11_LIGHT_BLUE_3;
  9397. }
  9398. case '4':
  9399. {
  9400. idx += 12;
  9401. return X11_LIGHT_BLUE_4;
  9402. }
  9403. }
  9404. }
  9405. }
  9406. case '_' | 0x20:
  9407. {
  9408. switch (str[11] | 0x20)
  9409. {
  9410. case '1':
  9411. {
  9412. idx += 12;
  9413. return X11_LIGHT_BLUE_1;
  9414. }
  9415. case '2':
  9416. {
  9417. idx += 12;
  9418. return X11_LIGHT_BLUE_2;
  9419. }
  9420. case '3':
  9421. {
  9422. idx += 12;
  9423. return X11_LIGHT_BLUE_3;
  9424. }
  9425. case '4':
  9426. {
  9427. idx += 12;
  9428. return X11_LIGHT_BLUE_4;
  9429. }
  9430. }
  9431. }
  9432. }
  9433. idx += 10;
  9434. return X11_LIGHT_BLUE;
  9435. }
  9436. case 'c':
  9437. {
  9438. switch (str[7] | 0x20)
  9439. {
  9440. case 'o':
  9441. {
  9442. if (str[8] && !strcmp(str[8], !"RAL", true, 3))
  9443. {
  9444. idx += 11;
  9445. return X11_LIGHT_CORAL;
  9446. }
  9447. }
  9448. case 'y':
  9449. {
  9450. if (!str[8] || strcmp(str[8], !"AN", true, 2))
  9451. {
  9452. return -1;
  9453. }
  9454. switch (str[10] | 0x20)
  9455. {
  9456. case _X11_SPACE_SWITCH: // ' '
  9457. {
  9458. if (str[10])
  9459. {
  9460. switch (str[11] | 0x20)
  9461. {
  9462. case '1':
  9463. {
  9464. idx += 12;
  9465. return X11_LIGHT_CYAN_1;
  9466. }
  9467. case '2':
  9468. {
  9469. idx += 12;
  9470. return X11_LIGHT_CYAN_2;
  9471. }
  9472. case '3':
  9473. {
  9474. idx += 12;
  9475. return X11_LIGHT_CYAN_3;
  9476. }
  9477. case '4':
  9478. {
  9479. idx += 12;
  9480. return X11_LIGHT_CYAN_4;
  9481. }
  9482. }
  9483. }
  9484. }
  9485. case '_' | 0x20:
  9486. {
  9487. switch (str[11] | 0x20)
  9488. {
  9489. case '1':
  9490. {
  9491. idx += 12;
  9492. return X11_LIGHT_CYAN_1;
  9493. }
  9494. case '2':
  9495. {
  9496. idx += 12;
  9497. return X11_LIGHT_CYAN_2;
  9498. }
  9499. case '3':
  9500. {
  9501. idx += 12;
  9502. return X11_LIGHT_CYAN_3;
  9503. }
  9504. case '4':
  9505. {
  9506. idx += 12;
  9507. return X11_LIGHT_CYAN_4;
  9508. }
  9509. }
  9510. }
  9511. }
  9512. idx += 10;
  9513. return X11_LIGHT_CYAN;
  9514. }
  9515. }
  9516. }
  9517. case 'g':
  9518. {
  9519. switch (str[7] | 0x20)
  9520. {
  9521. case 'o':
  9522. {
  9523. if (!str[8] || strcmp(str[8], !"LDENROD", true, 7))
  9524. {
  9525. return -1;
  9526. }
  9527. switch (str[15] | 0x20)
  9528. {
  9529. case _X11_SPACE_SWITCH: // ' '
  9530. {
  9531. if (str[15])
  9532. {
  9533. switch (str[16] | 0x20)
  9534. {
  9535. case '1':
  9536. {
  9537. idx += 17;
  9538. return X11_LIGHT_GOLDENROD_1;
  9539. }
  9540. case '2':
  9541. {
  9542. idx += 17;
  9543. return X11_LIGHT_GOLDENROD_2;
  9544. }
  9545. case '3':
  9546. {
  9547. idx += 17;
  9548. return X11_LIGHT_GOLDENROD_3;
  9549. }
  9550. case '4':
  9551. {
  9552. idx += 17;
  9553. return X11_LIGHT_GOLDENROD_4;
  9554. }
  9555. case 'y':
  9556. {
  9557. if (str[17] && !strcmp(str[17], !"ELLOW", true, 5))
  9558. {
  9559. idx += 22;
  9560. return X11_LIGHT_GOLDENROD_YELLOW;
  9561. }
  9562. }
  9563. }
  9564. }
  9565. }
  9566. case '_' | 0x20:
  9567. {
  9568. switch (str[16] | 0x20)
  9569. {
  9570. case '1':
  9571. {
  9572. idx += 17;
  9573. return X11_LIGHT_GOLDENROD_1;
  9574. }
  9575. case '2':
  9576. {
  9577. idx += 17;
  9578. return X11_LIGHT_GOLDENROD_2;
  9579. }
  9580. case '3':
  9581. {
  9582. idx += 17;
  9583. return X11_LIGHT_GOLDENROD_3;
  9584. }
  9585. case '4':
  9586. {
  9587. idx += 17;
  9588. return X11_LIGHT_GOLDENROD_4;
  9589. }
  9590. case 'y':
  9591. {
  9592. if (str[17] && !strcmp(str[17], !"ELLOW", true, 5))
  9593. {
  9594. idx += 22;
  9595. return X11_LIGHT_GOLDENROD_YELLOW;
  9596. }
  9597. }
  9598. }
  9599. }
  9600. }
  9601. idx += 15;
  9602. return X11_LIGHT_GOLDENROD;
  9603. }
  9604. case 'r':
  9605. {
  9606. switch (str[8] | 0x20)
  9607. {
  9608. case 'a':
  9609. {
  9610. if (str[9] | 0x20 == 'y')
  9611. {
  9612. idx += 10;
  9613. return X11_LIGHT_GRAY;
  9614. }
  9615. }
  9616. case 'e':
  9617. {
  9618. switch (str[9] | 0x20)
  9619. {
  9620. case 'e':
  9621. {
  9622. if (str[10] | 0x20 == 'n')
  9623. {
  9624. idx += 11;
  9625. return X11_LIGHT_GREEN;
  9626. }
  9627. }
  9628. case 'y':
  9629. {
  9630. idx += 10;
  9631. return X11_LIGHT_GREY;
  9632. }
  9633. }
  9634. }
  9635. }
  9636. }
  9637. }
  9638. }
  9639. case 'p':
  9640. {
  9641. if (!str[7] || strcmp(str[7], !"INK", true, 3))
  9642. {
  9643. return -1;
  9644. }
  9645. switch (str[10] | 0x20)
  9646. {
  9647. case _X11_SPACE_SWITCH: // ' '
  9648. {
  9649. if (str[10])
  9650. {
  9651. switch (str[11] | 0x20)
  9652. {
  9653. case '1':
  9654. {
  9655. idx += 12;
  9656. return X11_LIGHT_PINK_1;
  9657. }
  9658. case '2':
  9659. {
  9660. idx += 12;
  9661. return X11_LIGHT_PINK_2;
  9662. }
  9663. case '3':
  9664. {
  9665. idx += 12;
  9666. return X11_LIGHT_PINK_3;
  9667. }
  9668. case '4':
  9669. {
  9670. idx += 12;
  9671. return X11_LIGHT_PINK_4;
  9672. }
  9673. }
  9674. }
  9675. }
  9676. case '_' | 0x20:
  9677. {
  9678. switch (str[11] | 0x20)
  9679. {
  9680. case '1':
  9681. {
  9682. idx += 12;
  9683. return X11_LIGHT_PINK_1;
  9684. }
  9685. case '2':
  9686. {
  9687. idx += 12;
  9688. return X11_LIGHT_PINK_2;
  9689. }
  9690. case '3':
  9691. {
  9692. idx += 12;
  9693. return X11_LIGHT_PINK_3;
  9694. }
  9695. case '4':
  9696. {
  9697. idx += 12;
  9698. return X11_LIGHT_PINK_4;
  9699. }
  9700. }
  9701. }
  9702. }
  9703. idx += 10;
  9704. return X11_LIGHT_PINK;
  9705. }
  9706. case 's':
  9707. {
  9708. switch (str[7] | 0x20)
  9709. {
  9710. case 'a':
  9711. {
  9712. if (!str[8] || strcmp(str[8], !"LMON", true, 4))
  9713. {
  9714. return -1;
  9715. }
  9716. switch (str[12] | 0x20)
  9717. {
  9718. case _X11_SPACE_SWITCH: // ' '
  9719. {
  9720. if (str[12])
  9721. {
  9722. switch (str[13] | 0x20)
  9723. {
  9724. case '1':
  9725. {
  9726. idx += 14;
  9727. return X11_LIGHT_SALMON_1;
  9728. }
  9729. case '2':
  9730. {
  9731. idx += 14;
  9732. return X11_LIGHT_SALMON_2;
  9733. }
  9734. case '3':
  9735. {
  9736. idx += 14;
  9737. return X11_LIGHT_SALMON_3;
  9738. }
  9739. case '4':
  9740. {
  9741. idx += 14;
  9742. return X11_LIGHT_SALMON_4;
  9743. }
  9744. }
  9745. }
  9746. }
  9747. case '_' | 0x20:
  9748. {
  9749. switch (str[13] | 0x20)
  9750. {
  9751. case '1':
  9752. {
  9753. idx += 14;
  9754. return X11_LIGHT_SALMON_1;
  9755. }
  9756. case '2':
  9757. {
  9758. idx += 14;
  9759. return X11_LIGHT_SALMON_2;
  9760. }
  9761. case '3':
  9762. {
  9763. idx += 14;
  9764. return X11_LIGHT_SALMON_3;
  9765. }
  9766. case '4':
  9767. {
  9768. idx += 14;
  9769. return X11_LIGHT_SALMON_4;
  9770. }
  9771. }
  9772. }
  9773. }
  9774. idx += 12;
  9775. return X11_LIGHT_SALMON;
  9776. }
  9777. case 'e':
  9778. {
  9779. //if (str[8] && !strcmp(str[8], !"A_GREEN", true, 7))
  9780. if (str[8] | 0x20 == 'a' && (_X11_SPACE_CHECK(9) || str[9] == '_') && !strcmp(str[10], !"GREEN", true, 5))
  9781. {
  9782. idx += 15;
  9783. return X11_LIGHT_SEA_GREEN;
  9784. }
  9785. }
  9786. case 'k':
  9787. {
  9788. //if (!str[8] || strcmp(str[8], !"Y_BLUE", true, 6))
  9789. if (str[8] | 0x20 != 'y' || (!_X11_SPACE_CHECK(9) && str[9] != '_') || strcmp(str[10], !"BLUE", true, 4))
  9790. {
  9791. return -1;
  9792. }
  9793. switch (str[14] | 0x20)
  9794. {
  9795. case _X11_SPACE_SWITCH: // ' '
  9796. {
  9797. if (str[14])
  9798. {
  9799. switch (str[15] | 0x20)
  9800. {
  9801. case '1':
  9802. {
  9803. idx += 16;
  9804. return X11_LIGHT_SKY_BLUE_1;
  9805. }
  9806. case '2':
  9807. {
  9808. idx += 16;
  9809. return X11_LIGHT_SKY_BLUE_2;
  9810. }
  9811. case '3':
  9812. {
  9813. idx += 16;
  9814. return X11_LIGHT_SKY_BLUE_3;
  9815. }
  9816. case '4':
  9817. {
  9818. idx += 16;
  9819. return X11_LIGHT_SKY_BLUE_4;
  9820. }
  9821. }
  9822. }
  9823. }
  9824. case '_' | 0x20:
  9825. {
  9826. switch (str[15] | 0x20)
  9827. {
  9828. case '1':
  9829. {
  9830. idx += 16;
  9831. return X11_LIGHT_SKY_BLUE_1;
  9832. }
  9833. case '2':
  9834. {
  9835. idx += 16;
  9836. return X11_LIGHT_SKY_BLUE_2;
  9837. }
  9838. case '3':
  9839. {
  9840. idx += 16;
  9841. return X11_LIGHT_SKY_BLUE_3;
  9842. }
  9843. case '4':
  9844. {
  9845. idx += 16;
  9846. return X11_LIGHT_SKY_BLUE_4;
  9847. }
  9848. }
  9849. }
  9850. }
  9851. idx += 14;
  9852. return X11_LIGHT_SKY_BLUE;
  9853. }
  9854. case 'l':
  9855. {
  9856. //if (!str[8] || strcmp(str[8], !"ATE_", true, 4))
  9857. if (!str[8] || strcmp(str[8], !"ATE", true, 3) || (!_X11_SPACE_CHECK(11) && str[11] != '_'))
  9858. {
  9859. return -1;
  9860. }
  9861. switch (str[12] | 0x20)
  9862. {
  9863. case 'b':
  9864. {
  9865. if (str[13] && !strcmp(str[13], !"LUE", true, 3))
  9866. {
  9867. idx += 16;
  9868. return X11_LIGHT_SLATE_BLUE;
  9869. }
  9870. }
  9871. case 'g':
  9872. {
  9873. if (str[13] | 0x20 != 'r')
  9874. {
  9875. return -1;
  9876. }
  9877. switch (str[14] | 0x20)
  9878. {
  9879. case 'a':
  9880. {
  9881. if (str[15] | 0x20 == 'y')
  9882. {
  9883. idx += 16;
  9884. return X11_LIGHT_SLATE_GRAY;
  9885. }
  9886. }
  9887. case 'e':
  9888. {
  9889. if (str[15] | 0x20 == 'y')
  9890. {
  9891. idx += 16;
  9892. return X11_LIGHT_SLATE_GREY;
  9893. }
  9894. }
  9895. }
  9896. }
  9897. }
  9898. }
  9899. case 't':
  9900. {
  9901. //if (!str[8] || strcmp(str[8], !"EEL_BLUE", true, 8))
  9902. if (!str[8] || strcmp(str[8], !"EEL", true, 3) || (!_X11_SPACE_CHECK(11) && str[11] != '_') || strcmp(str[12], !"BLUE", true, 4))
  9903. {
  9904. return -1;
  9905. }
  9906. switch (str[16] | 0x20)
  9907. {
  9908. case _X11_SPACE_SWITCH: // ' '
  9909. {
  9910. if (str[16])
  9911. {
  9912. switch (str[17] | 0x20)
  9913. {
  9914. case '1':
  9915. {
  9916. idx += 18;
  9917. return X11_LIGHT_STEEL_BLUE_1;
  9918. }
  9919. case '2':
  9920. {
  9921. idx += 18;
  9922. return X11_LIGHT_STEEL_BLUE_2;
  9923. }
  9924. case '3':
  9925. {
  9926. idx += 18;
  9927. return X11_LIGHT_STEEL_BLUE_3;
  9928. }
  9929. case '4':
  9930. {
  9931. idx += 18;
  9932. return X11_LIGHT_STEEL_BLUE_4;
  9933. }
  9934. }
  9935. }
  9936. }
  9937. case '_' | 0x20:
  9938. {
  9939. switch (str[17] | 0x20)
  9940. {
  9941. case '1':
  9942. {
  9943. idx += 18;
  9944. return X11_LIGHT_STEEL_BLUE_1;
  9945. }
  9946. case '2':
  9947. {
  9948. idx += 18;
  9949. return X11_LIGHT_STEEL_BLUE_2;
  9950. }
  9951. case '3':
  9952. {
  9953. idx += 18;
  9954. return X11_LIGHT_STEEL_BLUE_3;
  9955. }
  9956. case '4':
  9957. {
  9958. idx += 18;
  9959. return X11_LIGHT_STEEL_BLUE_4;
  9960. }
  9961. }
  9962. }
  9963. }
  9964. idx += 16;
  9965. return X11_LIGHT_STEEL_BLUE;
  9966. }
  9967. }
  9968. }
  9969. case 'y':
  9970. {
  9971. if (!str[7] || strcmp(str[7], !"ELLOW", true, 5))
  9972. {
  9973. return -1;
  9974. }
  9975. switch (str[12] | 0x20)
  9976. {
  9977. case _X11_SPACE_SWITCH: // ' '
  9978. {
  9979. if (str[12])
  9980. {
  9981. switch (str[13] | 0x20)
  9982. {
  9983. case '1':
  9984. {
  9985. idx += 14;
  9986. return X11_LIGHT_YELLOW_1;
  9987. }
  9988. case '2':
  9989. {
  9990. idx += 14;
  9991. return X11_LIGHT_YELLOW_2;
  9992. }
  9993. case '3':
  9994. {
  9995. idx += 14;
  9996. return X11_LIGHT_YELLOW_3;
  9997. }
  9998. case '4':
  9999. {
  10000. idx += 14;
  10001. return X11_LIGHT_YELLOW_4;
  10002. }
  10003. }
  10004. }
  10005. }
  10006. case '_' | 0x20:
  10007. {
  10008. switch (str[13] | 0x20)
  10009. {
  10010. case '1':
  10011. {
  10012. idx += 14;
  10013. return X11_LIGHT_YELLOW_1;
  10014. }
  10015. case '2':
  10016. {
  10017. idx += 14;
  10018. return X11_LIGHT_YELLOW_2;
  10019. }
  10020. case '3':
  10021. {
  10022. idx += 14;
  10023. return X11_LIGHT_YELLOW_3;
  10024. }
  10025. case '4':
  10026. {
  10027. idx += 14;
  10028. return X11_LIGHT_YELLOW_4;
  10029. }
  10030. }
  10031. }
  10032. }
  10033. idx += 12;
  10034. return X11_LIGHT_YELLOW;
  10035. }
  10036. }
  10037. }
  10038. case 'b':
  10039. {
  10040. if (!str[6] || strcmp(str[6], !"LUE", true, 3))
  10041. {
  10042. return -1;
  10043. }
  10044. switch (str[9] | 0x20)
  10045. {
  10046. case '1':
  10047. {
  10048. idx += 10;
  10049. return X11_LIGHTBLUE1;
  10050. }
  10051. case '2':
  10052. {
  10053. idx += 10;
  10054. return X11_LIGHTBLUE2;
  10055. }
  10056. case '3':
  10057. {
  10058. idx += 10;
  10059. return X11_LIGHTBLUE3;
  10060. }
  10061. case '4':
  10062. {
  10063. idx += 10;
  10064. return X11_LIGHTBLUE4;
  10065. }
  10066. }
  10067. idx += 9;
  10068. return X11_LIGHTBLUE;
  10069. }
  10070. case 'c':
  10071. {
  10072. switch (str[6] | 0x20)
  10073. {
  10074. case 'o':
  10075. {
  10076. if (str[7] && !strcmp(str[7], !"RAL", true, 3))
  10077. {
  10078. idx += 10;
  10079. return X11_LIGHTCORAL;
  10080. }
  10081. }
  10082. case 'y':
  10083. {
  10084. if (!str[7] || strcmp(str[7], !"AN", true, 2))
  10085. {
  10086. return -1;
  10087. }
  10088. switch (str[9] | 0x20)
  10089. {
  10090. case '1':
  10091. {
  10092. idx += 10;
  10093. return X11_LIGHTCYAN1;
  10094. }
  10095. case '2':
  10096. {
  10097. idx += 10;
  10098. return X11_LIGHTCYAN2;
  10099. }
  10100. case '3':
  10101. {
  10102. idx += 10;
  10103. return X11_LIGHTCYAN3;
  10104. }
  10105. case '4':
  10106. {
  10107. idx += 10;
  10108. return X11_LIGHTCYAN4;
  10109. }
  10110. }
  10111. idx += 9;
  10112. return X11_LIGHTCYAN;
  10113. }
  10114. }
  10115. }
  10116. case 'g':
  10117. {
  10118. switch (str[6] | 0x20)
  10119. {
  10120. case 'o':
  10121. {
  10122. if (!str[7] || strcmp(str[7], !"LDENROD", true, 7))
  10123. {
  10124. return -1;
  10125. }
  10126. switch (str[14] | 0x20)
  10127. {
  10128. case '1':
  10129. {
  10130. idx += 15;
  10131. return X11_LIGHTGOLDENROD1;
  10132. }
  10133. case '2':
  10134. {
  10135. idx += 15;
  10136. return X11_LIGHTGOLDENROD2;
  10137. }
  10138. case '3':
  10139. {
  10140. idx += 15;
  10141. return X11_LIGHTGOLDENROD3;
  10142. }
  10143. case '4':
  10144. {
  10145. idx += 15;
  10146. return X11_LIGHTGOLDENROD4;
  10147. }
  10148. case 'y':
  10149. {
  10150. if (str[15] && !strcmp(str[15], !"ELLOW", true, 5))
  10151. {
  10152. idx += 20;
  10153. return X11_LIGHTGOLDENRODYELLOW;
  10154. }
  10155. }
  10156. }
  10157. idx += 14;
  10158. return X11_LIGHTGOLDENROD;
  10159. }
  10160. case 'r':
  10161. {
  10162. switch (str[7] | 0x20)
  10163. {
  10164. case 'a':
  10165. {
  10166. if (str[8] | 0x20 == 'y')
  10167. {
  10168. idx += 9;
  10169. return X11_LIGHTGRAY;
  10170. }
  10171. }
  10172. case 'e':
  10173. {
  10174. switch (str[8] | 0x20)
  10175. {
  10176. case 'e':
  10177. {
  10178. if (str[9] | 0x20 == 'n')
  10179. {
  10180. idx += 10;
  10181. return X11_LIGHTGREEN;
  10182. }
  10183. }
  10184. case 'y':
  10185. {
  10186. idx += 9;
  10187. return X11_LIGHTGREY;
  10188. }
  10189. }
  10190. }
  10191. }
  10192. }
  10193. }
  10194. }
  10195. case 'p':
  10196. {
  10197. if (!str[6] || strcmp(str[6], !"INK", true, 3))
  10198. {
  10199. return -1;
  10200. }
  10201. switch (str[9] | 0x20)
  10202. {
  10203. case '1':
  10204. {
  10205. idx += 10;
  10206. return X11_LIGHTPINK1;
  10207. }
  10208. case '2':
  10209. {
  10210. idx += 10;
  10211. return X11_LIGHTPINK2;
  10212. }
  10213. case '3':
  10214. {
  10215. idx += 10;
  10216. return X11_LIGHTPINK3;
  10217. }
  10218. case '4':
  10219. {
  10220. idx += 10;
  10221. return X11_LIGHTPINK4;
  10222. }
  10223. }
  10224. idx += 9;
  10225. return X11_LIGHTPINK;
  10226. }
  10227. case 's':
  10228. {
  10229. switch (str[6] | 0x20)
  10230. {
  10231. case 'a':
  10232. {
  10233. if (!str[7] || strcmp(str[7], !"LMON", true, 4))
  10234. {
  10235. return -1;
  10236. }
  10237. switch (str[11] | 0x20)
  10238. {
  10239. case '1':
  10240. {
  10241. idx += 12;
  10242. return X11_LIGHTSALMON1;
  10243. }
  10244. case '2':
  10245. {
  10246. idx += 12;
  10247. return X11_LIGHTSALMON2;
  10248. }
  10249. case '3':
  10250. {
  10251. idx += 12;
  10252. return X11_LIGHTSALMON3;
  10253. }
  10254. case '4':
  10255. {
  10256. idx += 12;
  10257. return X11_LIGHTSALMON4;
  10258. }
  10259. }
  10260. idx += 11;
  10261. return X11_LIGHTSALMON;
  10262. }
  10263. case 'e':
  10264. {
  10265. if (str[7] && !strcmp(str[7], !"AGREEN", true, 6))
  10266. {
  10267. idx += 13;
  10268. return X11_LIGHTSEAGREEN;
  10269. }
  10270. }
  10271. case 'k':
  10272. {
  10273. if (!str[7] || strcmp(str[7], !"YBLUE", true, 5))
  10274. {
  10275. return -1;
  10276. }
  10277. switch (str[12] | 0x20)
  10278. {
  10279. case '1':
  10280. {
  10281. idx += 13;
  10282. return X11_LIGHTSKYBLUE1;
  10283. }
  10284. case '2':
  10285. {
  10286. idx += 13;
  10287. return X11_LIGHTSKYBLUE2;
  10288. }
  10289. case '3':
  10290. {
  10291. idx += 13;
  10292. return X11_LIGHTSKYBLUE3;
  10293. }
  10294. case '4':
  10295. {
  10296. idx += 13;
  10297. return X11_LIGHTSKYBLUE4;
  10298. }
  10299. }
  10300. idx += 12;
  10301. return X11_LIGHTSKYBLUE;
  10302. }
  10303. case 'l':
  10304. {
  10305. if (!str[7] || strcmp(str[7], !"ATE", true, 3))
  10306. {
  10307. return -1;
  10308. }
  10309. switch (str[10] | 0x20)
  10310. {
  10311. case 'b':
  10312. {
  10313. if (str[11] && !strcmp(str[11], !"LUE", true, 3))
  10314. {
  10315. idx += 14;
  10316. return X11_LIGHTSLATEBLUE;
  10317. }
  10318. }
  10319. case 'g':
  10320. {
  10321. if (str[11] | 0x20 != 'r')
  10322. {
  10323. return -1;
  10324. }
  10325. switch (str[12] | 0x20)
  10326. {
  10327. case 'a':
  10328. {
  10329. if (str[13] | 0x20 == 'y')
  10330. {
  10331. idx += 14;
  10332. return X11_LIGHTSLATEGRAY;
  10333. }
  10334. }
  10335. case 'e':
  10336. {
  10337. if (str[13] | 0x20 == 'y')
  10338. {
  10339. idx += 14;
  10340. return X11_LIGHTSLATEGREY;
  10341. }
  10342. }
  10343. }
  10344. }
  10345. }
  10346. }
  10347. case 't':
  10348. {
  10349. if (!str[7] || strcmp(str[7], !"EELBLUE", true, 7))
  10350. {
  10351. return -1;
  10352. }
  10353. switch (str[14] | 0x20)
  10354. {
  10355. case '1':
  10356. {
  10357. idx += 15;
  10358. return X11_LIGHTSTEELBLUE1;
  10359. }
  10360. case '2':
  10361. {
  10362. idx += 15;
  10363. return X11_LIGHTSTEELBLUE2;
  10364. }
  10365. case '3':
  10366. {
  10367. idx += 15;
  10368. return X11_LIGHTSTEELBLUE3;
  10369. }
  10370. case '4':
  10371. {
  10372. idx += 15;
  10373. return X11_LIGHTSTEELBLUE4;
  10374. }
  10375. }
  10376. idx += 14;
  10377. return X11_LIGHTSTEELBLUE;
  10378. }
  10379. }
  10380. }
  10381. case 'y':
  10382. {
  10383. if (!str[6] || strcmp(str[6], !"ELLOW", true, 5))
  10384. {
  10385. return -1;
  10386. }
  10387. switch (str[11] | 0x20)
  10388. {
  10389. case '1':
  10390. {
  10391. idx += 12;
  10392. return X11_LIGHTYELLOW1;
  10393. }
  10394. case '2':
  10395. {
  10396. idx += 12;
  10397. return X11_LIGHTYELLOW2;
  10398. }
  10399. case '3':
  10400. {
  10401. idx += 12;
  10402. return X11_LIGHTYELLOW3;
  10403. }
  10404. case '4':
  10405. {
  10406. idx += 12;
  10407. return X11_LIGHTYELLOW4;
  10408. }
  10409. }
  10410. idx += 11;
  10411. return X11_LIGHTYELLOW;
  10412. }
  10413. }
  10414. }
  10415. case 'm':
  10416. {
  10417. if (str[3] | 0x20 != 'e')
  10418. {
  10419. return -1;
  10420. }
  10421. switch (str[4] | 0x20)
  10422. {
  10423. case _X11_SPACE_SWITCH: // ' '
  10424. {
  10425. if (str[4])
  10426. {
  10427. if (str[5] && !strcmp(str[5], !"GREEN", true, 5))
  10428. {
  10429. idx += 10;
  10430. return X11_LIME_GREEN;
  10431. }
  10432. }
  10433. }
  10434. case '_' | 0x20:
  10435. {
  10436. if (str[5] && !strcmp(str[5], !"GREEN", true, 5))
  10437. {
  10438. idx += 10;
  10439. return X11_LIME_GREEN;
  10440. }
  10441. }
  10442. case 'g':
  10443. {
  10444. if (str[5] && !strcmp(str[5], !"REEN", true, 4))
  10445. {
  10446. idx += 9;
  10447. return X11_LIMEGREEN;
  10448. }
  10449. }
  10450. }
  10451. }
  10452. case 'n':
  10453. {
  10454. if (str[3] && !strcmp(str[3], !"EN", true, 2))
  10455. {
  10456. idx += 5;
  10457. return X11_LINEN;
  10458. }
  10459. }
  10460. }
  10461. }
  10462. }
  10463. }
  10464. case 'm':
  10465. {
  10466. switch (str[1] | 0x20)
  10467. {
  10468. case 'a':
  10469. {
  10470. switch (str[2] | 0x20)
  10471. {
  10472. case 'g':
  10473. {
  10474. if (!str[3] || strcmp(str[3], !"ENTA", true, 4))
  10475. {
  10476. return -1;
  10477. }
  10478. switch (str[7] | 0x20)
  10479. {
  10480. case _X11_SPACE_SWITCH: // ' '
  10481. {
  10482. if (str[7])
  10483. {
  10484. switch (str[8] | 0x20)
  10485. {
  10486. case '1':
  10487. {
  10488. idx += 9;
  10489. return X11_MAGENTA_1;
  10490. }
  10491. case '2':
  10492. {
  10493. idx += 9;
  10494. return X11_MAGENTA_2;
  10495. }
  10496. case '3':
  10497. {
  10498. idx += 9;
  10499. return X11_MAGENTA_3;
  10500. }
  10501. case '4':
  10502. {
  10503. idx += 9;
  10504. return X11_MAGENTA_4;
  10505. }
  10506. }
  10507. }
  10508. }
  10509. case '_' | 0x20:
  10510. {
  10511. switch (str[8] | 0x20)
  10512. {
  10513. case '1':
  10514. {
  10515. idx += 9;
  10516. return X11_MAGENTA_1;
  10517. }
  10518. case '2':
  10519. {
  10520. idx += 9;
  10521. return X11_MAGENTA_2;
  10522. }
  10523. case '3':
  10524. {
  10525. idx += 9;
  10526. return X11_MAGENTA_3;
  10527. }
  10528. case '4':
  10529. {
  10530. idx += 9;
  10531. return X11_MAGENTA_4;
  10532. }
  10533. }
  10534. }
  10535. case '1':
  10536. {
  10537. idx += 8;
  10538. return X11_MAGENTA1;
  10539. }
  10540. case '2':
  10541. {
  10542. idx += 8;
  10543. return X11_MAGENTA2;
  10544. }
  10545. case '3':
  10546. {
  10547. idx += 8;
  10548. return X11_MAGENTA3;
  10549. }
  10550. case '4':
  10551. {
  10552. idx += 8;
  10553. return X11_MAGENTA4;
  10554. }
  10555. }
  10556. idx += 7;
  10557. return X11_MAGENTA;
  10558. }
  10559. case 'r':
  10560. {
  10561. if (!str[3] || strcmp(str[3], !"OON", true, 3))
  10562. {
  10563. return -1;
  10564. }
  10565. switch (str[6] | 0x20)
  10566. {
  10567. case _X11_SPACE_SWITCH: // ' '
  10568. {
  10569. if (str[6])
  10570. {
  10571. switch (str[7] | 0x20)
  10572. {
  10573. case '1':
  10574. {
  10575. idx += 8;
  10576. return X11_MAROON_1;
  10577. }
  10578. case '2':
  10579. {
  10580. idx += 8;
  10581. return X11_MAROON_2;
  10582. }
  10583. case '3':
  10584. {
  10585. idx += 8;
  10586. return X11_MAROON_3;
  10587. }
  10588. case '4':
  10589. {
  10590. idx += 8;
  10591. return X11_MAROON_4;
  10592. }
  10593. }
  10594. }
  10595. }
  10596. case '_' | 0x20:
  10597. {
  10598. switch (str[7] | 0x20)
  10599. {
  10600. case '1':
  10601. {
  10602. idx += 8;
  10603. return X11_MAROON_1;
  10604. }
  10605. case '2':
  10606. {
  10607. idx += 8;
  10608. return X11_MAROON_2;
  10609. }
  10610. case '3':
  10611. {
  10612. idx += 8;
  10613. return X11_MAROON_3;
  10614. }
  10615. case '4':
  10616. {
  10617. idx += 8;
  10618. return X11_MAROON_4;
  10619. }
  10620. }
  10621. }
  10622. case '1':
  10623. {
  10624. idx += 7;
  10625. return X11_MAROON1;
  10626. }
  10627. case '2':
  10628. {
  10629. idx += 7;
  10630. return X11_MAROON2;
  10631. }
  10632. case '3':
  10633. {
  10634. idx += 7;
  10635. return X11_MAROON3;
  10636. }
  10637. case '4':
  10638. {
  10639. idx += 7;
  10640. return X11_MAROON4;
  10641. }
  10642. }
  10643. idx += 6;
  10644. return X11_MAROON;
  10645. }
  10646. }
  10647. }
  10648. case 'e':
  10649. {
  10650. if (!str[2] || strcmp(str[2], !"DIUM", true, 4))
  10651. {
  10652. return -1;
  10653. }
  10654. switch (str[6] | 0x20)
  10655. {
  10656. case _X11_SPACE_SWITCH: // ' '
  10657. {
  10658. if (str[6])
  10659. {
  10660. switch (str[7] | 0x20)
  10661. {
  10662. case 'a':
  10663. {
  10664. if (str[8] && !strcmp(str[8], !"QUAMARINE", true, 9))
  10665. {
  10666. idx += 17;
  10667. return X11_MEDIUM_AQUAMARINE;
  10668. }
  10669. }
  10670. case 'b':
  10671. {
  10672. if (str[8] && !strcmp(str[8], !"LUE", true, 3))
  10673. {
  10674. idx += 11;
  10675. return X11_MEDIUM_BLUE;
  10676. }
  10677. }
  10678. case 'o':
  10679. {
  10680. if (!str[8] || strcmp(str[8], !"RCHID", true, 5))
  10681. {
  10682. return -1;
  10683. }
  10684. switch (str[13] | 0x20)
  10685. {
  10686. case _X11_SPACE_SWITCH: // ' '
  10687. {
  10688. if (str[13])
  10689. {
  10690. switch (str[14] | 0x20)
  10691. {
  10692. case '1':
  10693. {
  10694. idx += 15;
  10695. return X11_MEDIUM_ORCHID_1;
  10696. }
  10697. case '2':
  10698. {
  10699. idx += 15;
  10700. return X11_MEDIUM_ORCHID_2;
  10701. }
  10702. case '3':
  10703. {
  10704. idx += 15;
  10705. return X11_MEDIUM_ORCHID_3;
  10706. }
  10707. case '4':
  10708. {
  10709. idx += 15;
  10710. return X11_MEDIUM_ORCHID_4;
  10711. }
  10712. }
  10713. }
  10714. }
  10715. case '_' | 0x20:
  10716. {
  10717. switch (str[14] | 0x20)
  10718. {
  10719. case '1':
  10720. {
  10721. idx += 15;
  10722. return X11_MEDIUM_ORCHID_1;
  10723. }
  10724. case '2':
  10725. {
  10726. idx += 15;
  10727. return X11_MEDIUM_ORCHID_2;
  10728. }
  10729. case '3':
  10730. {
  10731. idx += 15;
  10732. return X11_MEDIUM_ORCHID_3;
  10733. }
  10734. case '4':
  10735. {
  10736. idx += 15;
  10737. return X11_MEDIUM_ORCHID_4;
  10738. }
  10739. }
  10740. }
  10741. }
  10742. idx += 13;
  10743. return X11_MEDIUM_ORCHID;
  10744. }
  10745. case 'p':
  10746. {
  10747. if (!str[8] || strcmp(str[8], !"URPLE", true, 5))
  10748. {
  10749. return -1;
  10750. }
  10751. switch (str[13] | 0x20)
  10752. {
  10753. case _X11_SPACE_SWITCH: // ' '
  10754. {
  10755. if (str[13])
  10756. {
  10757. switch (str[14] | 0x20)
  10758. {
  10759. case '1':
  10760. {
  10761. idx += 15;
  10762. return X11_MEDIUM_PURPLE_1;
  10763. }
  10764. case '2':
  10765. {
  10766. idx += 15;
  10767. return X11_MEDIUM_PURPLE_2;
  10768. }
  10769. case '3':
  10770. {
  10771. idx += 15;
  10772. return X11_MEDIUM_PURPLE_3;
  10773. }
  10774. case '4':
  10775. {
  10776. idx += 15;
  10777. return X11_MEDIUM_PURPLE_4;
  10778. }
  10779. }
  10780. }
  10781. }
  10782. case '_' | 0x20:
  10783. {
  10784. switch (str[14] | 0x20)
  10785. {
  10786. case '1':
  10787. {
  10788. idx += 15;
  10789. return X11_MEDIUM_PURPLE_1;
  10790. }
  10791. case '2':
  10792. {
  10793. idx += 15;
  10794. return X11_MEDIUM_PURPLE_2;
  10795. }
  10796. case '3':
  10797. {
  10798. idx += 15;
  10799. return X11_MEDIUM_PURPLE_3;
  10800. }
  10801. case '4':
  10802. {
  10803. idx += 15;
  10804. return X11_MEDIUM_PURPLE_4;
  10805. }
  10806. }
  10807. }
  10808. }
  10809. idx += 13;
  10810. return X11_MEDIUM_PURPLE;
  10811. }
  10812. case 's':
  10813. {
  10814. switch (str[8] | 0x20)
  10815. {
  10816. case 'e':
  10817. {
  10818. //if (str[9] && !strcmp(str[9], !"A_GREEN", true, 7))
  10819. if (str[9] | 0x20 == 'a' && (_X11_SPACE_CHECK(10) || str[10] == '_') && !strcmp(str[11], !"GREEN", true, 5))
  10820. {
  10821. idx += 16;
  10822. return X11_MEDIUM_SEA_GREEN;
  10823. }
  10824. }
  10825. case 'l':
  10826. {
  10827. //if (str[9] && !strcmp(str[9], !"ATE_BLUE", true, 8))
  10828. if (str[9] && !strcmp(str[9], !"ATE", true, 3) && (_X11_SPACE_CHECK(12) || str[12] == '_') && !strcmp(str[13], !"BLUE", true, 4))
  10829. {
  10830. idx += 17;
  10831. return X11_MEDIUM_SLATE_BLUE;
  10832. }
  10833. }
  10834. case 'p':
  10835. {
  10836. //if (str[9] && !strcmp(str[9], !"RING_GREEN", true, 10))
  10837. if (str[9] && !strcmp(str[9], !"RING", true, 4) && (_X11_SPACE_CHECK(13) || str[13] == '_') && !strcmp(str[14], !"GREEN", true, 5))
  10838. {
  10839. idx += 19;
  10840. return X11_MEDIUM_SPRING_GREEN;
  10841. }
  10842. }
  10843. }
  10844. }
  10845. case 't':
  10846. {
  10847. if (str[8] && !strcmp(str[8], !"URQUOISE", true, 8))
  10848. {
  10849. idx += 16;
  10850. return X11_MEDIUM_TURQUOISE;
  10851. }
  10852. }
  10853. case 'v':
  10854. {
  10855. //if (str[8] && !strcmp(str[8], !"IOLET_RED", true, 9))
  10856. if (str[8] && !strcmp(str[8], !"IOLET", true, 5) && (_X11_SPACE_CHECK(13) || str[13] == '_') && !strcmp(str[14], !"RED", true, 3))
  10857. {
  10858. idx += 17;
  10859. return X11_MEDIUM_VIOLET_RED;
  10860. }
  10861. }
  10862. }
  10863. }
  10864. }
  10865. case '_' | 0x20:
  10866. {
  10867. switch (str[7] | 0x20)
  10868. {
  10869. case 'a':
  10870. {
  10871. if (str[8] && !strcmp(str[8], !"QUAMARINE", true, 9))
  10872. {
  10873. idx += 17;
  10874. return X11_MEDIUM_AQUAMARINE;
  10875. }
  10876. }
  10877. case 'b':
  10878. {
  10879. if (str[8] && !strcmp(str[8], !"LUE", true, 3))
  10880. {
  10881. idx += 11;
  10882. return X11_MEDIUM_BLUE;
  10883. }
  10884. }
  10885. case 'o':
  10886. {
  10887. if (!str[8] || strcmp(str[8], !"RCHID", true, 5))
  10888. {
  10889. return -1;
  10890. }
  10891. switch (str[13] | 0x20)
  10892. {
  10893. case _X11_SPACE_SWITCH: // ' '
  10894. {
  10895. if (str[13])
  10896. {
  10897. switch (str[14] | 0x20)
  10898. {
  10899. case '1':
  10900. {
  10901. idx += 15;
  10902. return X11_MEDIUM_ORCHID_1;
  10903. }
  10904. case '2':
  10905. {
  10906. idx += 15;
  10907. return X11_MEDIUM_ORCHID_2;
  10908. }
  10909. case '3':
  10910. {
  10911. idx += 15;
  10912. return X11_MEDIUM_ORCHID_3;
  10913. }
  10914. case '4':
  10915. {
  10916. idx += 15;
  10917. return X11_MEDIUM_ORCHID_4;
  10918. }
  10919. }
  10920. }
  10921. }
  10922. case '_' | 0x20:
  10923. {
  10924. switch (str[14] | 0x20)
  10925. {
  10926. case '1':
  10927. {
  10928. idx += 15;
  10929. return X11_MEDIUM_ORCHID_1;
  10930. }
  10931. case '2':
  10932. {
  10933. idx += 15;
  10934. return X11_MEDIUM_ORCHID_2;
  10935. }
  10936. case '3':
  10937. {
  10938. idx += 15;
  10939. return X11_MEDIUM_ORCHID_3;
  10940. }
  10941. case '4':
  10942. {
  10943. idx += 15;
  10944. return X11_MEDIUM_ORCHID_4;
  10945. }
  10946. }
  10947. }
  10948. }
  10949. idx += 13;
  10950. return X11_MEDIUM_ORCHID;
  10951. }
  10952. case 'p':
  10953. {
  10954. if (!str[8] || strcmp(str[8], !"URPLE", true, 5))
  10955. {
  10956. return -1;
  10957. }
  10958. switch (str[13] | 0x20)
  10959. {
  10960. case _X11_SPACE_SWITCH: // ' '
  10961. {
  10962. if (str[13])
  10963. {
  10964. switch (str[14] | 0x20)
  10965. {
  10966. case '1':
  10967. {
  10968. idx += 15;
  10969. return X11_MEDIUM_PURPLE_1;
  10970. }
  10971. case '2':
  10972. {
  10973. idx += 15;
  10974. return X11_MEDIUM_PURPLE_2;
  10975. }
  10976. case '3':
  10977. {
  10978. idx += 15;
  10979. return X11_MEDIUM_PURPLE_3;
  10980. }
  10981. case '4':
  10982. {
  10983. idx += 15;
  10984. return X11_MEDIUM_PURPLE_4;
  10985. }
  10986. }
  10987. }
  10988. }
  10989. case '_' | 0x20:
  10990. {
  10991. switch (str[14] | 0x20)
  10992. {
  10993. case '1':
  10994. {
  10995. idx += 15;
  10996. return X11_MEDIUM_PURPLE_1;
  10997. }
  10998. case '2':
  10999. {
  11000. idx += 15;
  11001. return X11_MEDIUM_PURPLE_2;
  11002. }
  11003. case '3':
  11004. {
  11005. idx += 15;
  11006. return X11_MEDIUM_PURPLE_3;
  11007. }
  11008. case '4':
  11009. {
  11010. idx += 15;
  11011. return X11_MEDIUM_PURPLE_4;
  11012. }
  11013. }
  11014. }
  11015. }
  11016. idx += 13;
  11017. return X11_MEDIUM_PURPLE;
  11018. }
  11019. case 's':
  11020. {
  11021. switch (str[8] | 0x20)
  11022. {
  11023. case 'e':
  11024. {
  11025. //if (str[9] && !strcmp(str[9], !"A_GREEN", true, 7))
  11026. if (str[9] | 0x20 == 'a' && (_X11_SPACE_CHECK(10) || str[10] == '_') && !strcmp(str[11], !"GREEN", true, 5))
  11027. {
  11028. idx += 16;
  11029. return X11_MEDIUM_SEA_GREEN;
  11030. }
  11031. }
  11032. case 'l':
  11033. {
  11034. //if (str[9] && !strcmp(str[9], !"ATE_BLUE", true, 8))
  11035. if (str[9] && !strcmp(str[9], !"ATE", true, 3) && (_X11_SPACE_CHECK(12) || str[12] == '_') && !strcmp(str[13], !"BLUE", true, 4))
  11036. {
  11037. idx += 17;
  11038. return X11_MEDIUM_SLATE_BLUE;
  11039. }
  11040. }
  11041. case 'p':
  11042. {
  11043. //if (str[9] && !strcmp(str[9], !"RING_GREEN", true, 10))
  11044. if (str[9] && !strcmp(str[9], !"RING", true, 4) && (_X11_SPACE_CHECK(13) || str[13] == '_') && !strcmp(str[14], !"GREEN", true, 5))
  11045. {
  11046. idx += 19;
  11047. return X11_MEDIUM_SPRING_GREEN;
  11048. }
  11049. }
  11050. }
  11051. }
  11052. case 't':
  11053. {
  11054. if (str[8] && !strcmp(str[8], !"URQUOISE", true, 8))
  11055. {
  11056. idx += 16;
  11057. return X11_MEDIUM_TURQUOISE;
  11058. }
  11059. }
  11060. case 'v':
  11061. {
  11062. if (str[8] && !strcmp(str[8], !"IOLET", true, 5) && (_X11_SPACE_CHECK(13) || str[13] == '_') && !strcmp(str[14], !"RED", true, 3))
  11063. //if (str[8] && !strcmp(str[8], !"IOLET_RED", true, 9))
  11064. {
  11065. idx += 17;
  11066. return X11_MEDIUM_VIOLET_RED;
  11067. }
  11068. }
  11069. }
  11070. }
  11071. case 'a':
  11072. {
  11073. if (str[7] && !strcmp(str[7], !"QUAMARINE", true, 9))
  11074. {
  11075. idx += 16;
  11076. return X11_MEDIUMAQUAMARINE;
  11077. }
  11078. }
  11079. case 'b':
  11080. {
  11081. if (str[7] && !strcmp(str[7], !"LUE", true, 3))
  11082. {
  11083. idx += 10;
  11084. return X11_MEDIUMBLUE;
  11085. }
  11086. }
  11087. case 'o':
  11088. {
  11089. if (!str[7] || strcmp(str[7], !"RCHID", true, 5))
  11090. {
  11091. return -1;
  11092. }
  11093. switch (str[12] | 0x20)
  11094. {
  11095. case '1':
  11096. {
  11097. idx += 13;
  11098. return X11_MEDIUMORCHID1;
  11099. }
  11100. case '2':
  11101. {
  11102. idx += 13;
  11103. return X11_MEDIUMORCHID2;
  11104. }
  11105. case '3':
  11106. {
  11107. idx += 13;
  11108. return X11_MEDIUMORCHID3;
  11109. }
  11110. case '4':
  11111. {
  11112. idx += 13;
  11113. return X11_MEDIUMORCHID4;
  11114. }
  11115. }
  11116. idx += 12;
  11117. return X11_MEDIUMORCHID;
  11118. }
  11119. case 'p':
  11120. {
  11121. if (!str[7] || strcmp(str[7], !"URPLE", true, 5))
  11122. {
  11123. return -1;
  11124. }
  11125. switch (str[12] | 0x20)
  11126. {
  11127. case '1':
  11128. {
  11129. idx += 13;
  11130. return X11_MEDIUMPURPLE1;
  11131. }
  11132. case '2':
  11133. {
  11134. idx += 13;
  11135. return X11_MEDIUMPURPLE2;
  11136. }
  11137. case '3':
  11138. {
  11139. idx += 13;
  11140. return X11_MEDIUMPURPLE3;
  11141. }
  11142. case '4':
  11143. {
  11144. idx += 13;
  11145. return X11_MEDIUMPURPLE4;
  11146. }
  11147. }
  11148. idx += 12;
  11149. return X11_MEDIUMPURPLE;
  11150. }
  11151. case 's':
  11152. {
  11153. switch (str[7] | 0x20)
  11154. {
  11155. case 'e':
  11156. {
  11157. if (str[8] && !strcmp(str[8], !"AGREEN", true, 6))
  11158. {
  11159. idx += 14;
  11160. return X11_MEDIUMSEAGREEN;
  11161. }
  11162. }
  11163. case 'l':
  11164. {
  11165. if (str[8] && !strcmp(str[8], !"ATEBLUE", true, 7))
  11166. {
  11167. idx += 15;
  11168. return X11_MEDIUMSLATEBLUE;
  11169. }
  11170. }
  11171. case 'p':
  11172. {
  11173. if (str[8] && !strcmp(str[8], !"RINGGREEN", true, 9))
  11174. {
  11175. idx += 17;
  11176. return X11_MEDIUMSPRINGGREEN;
  11177. }
  11178. }
  11179. }
  11180. }
  11181. case 't':
  11182. {
  11183. if (str[7] && !strcmp(str[7], !"URQUOISE", true, 8))
  11184. {
  11185. idx += 15;
  11186. return X11_MEDIUMTURQUOISE;
  11187. }
  11188. }
  11189. case 'v':
  11190. {
  11191. if (str[7] && !strcmp(str[7], !"IOLETRED", true, 8))
  11192. {
  11193. idx += 15;
  11194. return X11_MEDIUMVIOLETRED;
  11195. }
  11196. }
  11197. }
  11198. }
  11199. case 'i':
  11200. {
  11201. switch (str[2] | 0x20)
  11202. {
  11203. case 'd':
  11204. {
  11205. if (!str[3] || strcmp(str[3], !"NIGHT", true, 5))
  11206. {
  11207. return -1;
  11208. }
  11209. switch (str[8] | 0x20)
  11210. {
  11211. case _X11_SPACE_SWITCH: // ' '
  11212. {
  11213. if (str[8])
  11214. {
  11215. if (str[9] && !strcmp(str[9], !"BLUE", true, 4))
  11216. {
  11217. idx += 13;
  11218. return X11_MIDNIGHT_BLUE;
  11219. }
  11220. }
  11221. }
  11222. case '_' | 0x20:
  11223. {
  11224. if (str[9] && !strcmp(str[9], !"BLUE", true, 4))
  11225. {
  11226. idx += 13;
  11227. return X11_MIDNIGHT_BLUE;
  11228. }
  11229. }
  11230. case 'b':
  11231. {
  11232. if (str[9] && !strcmp(str[9], !"LUE", true, 3))
  11233. {
  11234. idx += 12;
  11235. return X11_MIDNIGHTBLUE;
  11236. }
  11237. }
  11238. }
  11239. }
  11240. case 'n':
  11241. {
  11242. if (str[3] | 0x20 != 't')
  11243. {
  11244. return -1;
  11245. }
  11246. switch (str[4] | 0x20)
  11247. {
  11248. case _X11_SPACE_SWITCH: // ' '
  11249. {
  11250. if (str[4])
  11251. {
  11252. if (str[5] && !strcmp(str[5], !"CREAM", true, 5))
  11253. {
  11254. idx += 10;
  11255. return X11_MINT_CREAM;
  11256. }
  11257. }
  11258. }
  11259. case '_' | 0x20:
  11260. {
  11261. if (str[5] && !strcmp(str[5], !"CREAM", true, 5))
  11262. {
  11263. idx += 10;
  11264. return X11_MINT_CREAM;
  11265. }
  11266. }
  11267. case 'c':
  11268. {
  11269. if (str[5] && !strcmp(str[5], !"REAM", true, 4))
  11270. {
  11271. idx += 9;
  11272. return X11_MINTCREAM;
  11273. }
  11274. }
  11275. }
  11276. }
  11277. case 's':
  11278. {
  11279. if (!str[3] || strcmp(str[3], !"TY", true, 2))
  11280. {
  11281. return -1;
  11282. }
  11283. switch (str[5] | 0x20)
  11284. {
  11285. case _X11_SPACE_SWITCH: // ' '
  11286. {
  11287. if (str[5])
  11288. {
  11289. if (!str[6] || strcmp(str[6], !"ROSE", true, 4))
  11290. {
  11291. return -1;
  11292. }
  11293. switch (str[10] | 0x20)
  11294. {
  11295. case _X11_SPACE_SWITCH: // ' '
  11296. {
  11297. if (str[10])
  11298. {
  11299. switch (str[11] | 0x20)
  11300. {
  11301. case '1':
  11302. {
  11303. idx += 12;
  11304. return X11_MISTY_ROSE_1;
  11305. }
  11306. case '2':
  11307. {
  11308. idx += 12;
  11309. return X11_MISTY_ROSE_2;
  11310. }
  11311. case '3':
  11312. {
  11313. idx += 12;
  11314. return X11_MISTY_ROSE_3;
  11315. }
  11316. case '4':
  11317. {
  11318. idx += 12;
  11319. return X11_MISTY_ROSE_4;
  11320. }
  11321. }
  11322. }
  11323. }
  11324. case '_' | 0x20:
  11325. {
  11326. switch (str[11] | 0x20)
  11327. {
  11328. case '1':
  11329. {
  11330. idx += 12;
  11331. return X11_MISTY_ROSE_1;
  11332. }
  11333. case '2':
  11334. {
  11335. idx += 12;
  11336. return X11_MISTY_ROSE_2;
  11337. }
  11338. case '3':
  11339. {
  11340. idx += 12;
  11341. return X11_MISTY_ROSE_3;
  11342. }
  11343. case '4':
  11344. {
  11345. idx += 12;
  11346. return X11_MISTY_ROSE_4;
  11347. }
  11348. }
  11349. }
  11350. }
  11351. idx += 10;
  11352. return X11_MISTY_ROSE;
  11353. }
  11354. }
  11355. case '_' | 0x20:
  11356. {
  11357. if (!str[6] || strcmp(str[6], !"ROSE", true, 4))
  11358. {
  11359. return -1;
  11360. }
  11361. switch (str[10] | 0x20)
  11362. {
  11363. case _X11_SPACE_SWITCH: // ' '
  11364. {
  11365. if (str[10])
  11366. {
  11367. switch (str[11] | 0x20)
  11368. {
  11369. case '1':
  11370. {
  11371. idx += 12;
  11372. return X11_MISTY_ROSE_1;
  11373. }
  11374. case '2':
  11375. {
  11376. idx += 12;
  11377. return X11_MISTY_ROSE_2;
  11378. }
  11379. case '3':
  11380. {
  11381. idx += 12;
  11382. return X11_MISTY_ROSE_3;
  11383. }
  11384. case '4':
  11385. {
  11386. idx += 12;
  11387. return X11_MISTY_ROSE_4;
  11388. }
  11389. }
  11390. }
  11391. }
  11392. case '_' | 0x20:
  11393. {
  11394. switch (str[11] | 0x20)
  11395. {
  11396. case '1':
  11397. {
  11398. idx += 12;
  11399. return X11_MISTY_ROSE_1;
  11400. }
  11401. case '2':
  11402. {
  11403. idx += 12;
  11404. return X11_MISTY_ROSE_2;
  11405. }
  11406. case '3':
  11407. {
  11408. idx += 12;
  11409. return X11_MISTY_ROSE_3;
  11410. }
  11411. case '4':
  11412. {
  11413. idx += 12;
  11414. return X11_MISTY_ROSE_4;
  11415. }
  11416. }
  11417. }
  11418. }
  11419. idx += 10;
  11420. return X11_MISTY_ROSE;
  11421. }
  11422. case 'r':
  11423. {
  11424. if (!str[6] || strcmp(str[6], !"OSE", true, 3))
  11425. {
  11426. return -1;
  11427. }
  11428. switch (str[9] | 0x20)
  11429. {
  11430. case '1':
  11431. {
  11432. idx += 10;
  11433. return X11_MISTYROSE1;
  11434. }
  11435. case '2':
  11436. {
  11437. idx += 10;
  11438. return X11_MISTYROSE2;
  11439. }
  11440. case '3':
  11441. {
  11442. idx += 10;
  11443. return X11_MISTYROSE3;
  11444. }
  11445. case '4':
  11446. {
  11447. idx += 10;
  11448. return X11_MISTYROSE4;
  11449. }
  11450. }
  11451. idx += 9;
  11452. return X11_MISTYROSE;
  11453. }
  11454. }
  11455. }
  11456. }
  11457. }
  11458. case 'o':
  11459. {
  11460. if (str[2] && !strcmp(str[2], !"CCASIN", true, 6))
  11461. {
  11462. idx += 8;
  11463. return X11_MOCCASIN;
  11464. }
  11465. }
  11466. }
  11467. }
  11468. case 'n':
  11469. {
  11470. if (!str[1] || strcmp(str[1], !"AV", true, 2))
  11471. {
  11472. return -1;
  11473. }
  11474. switch (str[3] | 0x20)
  11475. {
  11476. case 'a':
  11477. {
  11478. if (!str[4] || strcmp(str[4], !"JO", true, 2))
  11479. {
  11480. return -1;
  11481. }
  11482. switch (str[6] | 0x20)
  11483. {
  11484. case _X11_SPACE_SWITCH: // ' '
  11485. {
  11486. if (str[6])
  11487. {
  11488. if (!str[7] || strcmp(str[7], !"WHITE", true, 5))
  11489. {
  11490. return -1;
  11491. }
  11492. switch (str[12] | 0x20)
  11493. {
  11494. case _X11_SPACE_SWITCH: // ' '
  11495. {
  11496. if (str[12])
  11497. {
  11498. switch (str[13] | 0x20)
  11499. {
  11500. case '1':
  11501. {
  11502. idx += 14;
  11503. return X11_NAVAJO_WHITE_1;
  11504. }
  11505. case '2':
  11506. {
  11507. idx += 14;
  11508. return X11_NAVAJO_WHITE_2;
  11509. }
  11510. case '3':
  11511. {
  11512. idx += 14;
  11513. return X11_NAVAJO_WHITE_3;
  11514. }
  11515. case '4':
  11516. {
  11517. idx += 14;
  11518. return X11_NAVAJO_WHITE_4;
  11519. }
  11520. }
  11521. }
  11522. }
  11523. case '_' | 0x20:
  11524. {
  11525. switch (str[13] | 0x20)
  11526. {
  11527. case '1':
  11528. {
  11529. idx += 14;
  11530. return X11_NAVAJO_WHITE_1;
  11531. }
  11532. case '2':
  11533. {
  11534. idx += 14;
  11535. return X11_NAVAJO_WHITE_2;
  11536. }
  11537. case '3':
  11538. {
  11539. idx += 14;
  11540. return X11_NAVAJO_WHITE_3;
  11541. }
  11542. case '4':
  11543. {
  11544. idx += 14;
  11545. return X11_NAVAJO_WHITE_4;
  11546. }
  11547. }
  11548. }
  11549. }
  11550. idx += 12;
  11551. return X11_NAVAJO_WHITE;
  11552. }
  11553. }
  11554. case '_' | 0x20:
  11555. {
  11556. if (!str[7] || strcmp(str[7], !"WHITE", true, 5))
  11557. {
  11558. return -1;
  11559. }
  11560. switch (str[12] | 0x20)
  11561. {
  11562. case _X11_SPACE_SWITCH: // ' '
  11563. {
  11564. if (str[12])
  11565. {
  11566. switch (str[13] | 0x20)
  11567. {
  11568. case '1':
  11569. {
  11570. idx += 14;
  11571. return X11_NAVAJO_WHITE_1;
  11572. }
  11573. case '2':
  11574. {
  11575. idx += 14;
  11576. return X11_NAVAJO_WHITE_2;
  11577. }
  11578. case '3':
  11579. {
  11580. idx += 14;
  11581. return X11_NAVAJO_WHITE_3;
  11582. }
  11583. case '4':
  11584. {
  11585. idx += 14;
  11586. return X11_NAVAJO_WHITE_4;
  11587. }
  11588. }
  11589. }
  11590. }
  11591. case '_' | 0x20:
  11592. {
  11593. switch (str[13] | 0x20)
  11594. {
  11595. case '1':
  11596. {
  11597. idx += 14;
  11598. return X11_NAVAJO_WHITE_1;
  11599. }
  11600. case '2':
  11601. {
  11602. idx += 14;
  11603. return X11_NAVAJO_WHITE_2;
  11604. }
  11605. case '3':
  11606. {
  11607. idx += 14;
  11608. return X11_NAVAJO_WHITE_3;
  11609. }
  11610. case '4':
  11611. {
  11612. idx += 14;
  11613. return X11_NAVAJO_WHITE_4;
  11614. }
  11615. }
  11616. }
  11617. }
  11618. idx += 12;
  11619. return X11_NAVAJO_WHITE;
  11620. }
  11621. case 'w':
  11622. {
  11623. if (!str[7] || strcmp(str[7], !"HITE", true, 4))
  11624. {
  11625. return -1;
  11626. }
  11627. switch (str[11] | 0x20)
  11628. {
  11629. case '1':
  11630. {
  11631. idx += 12;
  11632. return X11_NAVAJOWHITE1;
  11633. }
  11634. case '2':
  11635. {
  11636. idx += 12;
  11637. return X11_NAVAJOWHITE2;
  11638. }
  11639. case '3':
  11640. {
  11641. idx += 12;
  11642. return X11_NAVAJOWHITE3;
  11643. }
  11644. case '4':
  11645. {
  11646. idx += 12;
  11647. return X11_NAVAJOWHITE4;
  11648. }
  11649. }
  11650. idx += 11;
  11651. return X11_NAVAJOWHITE;
  11652. }
  11653. }
  11654. }
  11655. case 'y':
  11656. {
  11657. switch (str[4] | 0x20)
  11658. {
  11659. case _X11_SPACE_SWITCH: // ' '
  11660. {
  11661. if (str[4])
  11662. {
  11663. if (str[5] && !strcmp(str[5], !"BLUE", true, 4))
  11664. {
  11665. idx += 9;
  11666. return X11_NAVY_BLUE;
  11667. }
  11668. }
  11669. }
  11670. case '_' | 0x20:
  11671. {
  11672. if (str[5] && !strcmp(str[5], !"BLUE", true, 4))
  11673. {
  11674. idx += 9;
  11675. return X11_NAVY_BLUE;
  11676. }
  11677. }
  11678. case 'b':
  11679. {
  11680. if (str[5] && !strcmp(str[5], !"LUE", true, 3))
  11681. {
  11682. idx += 8;
  11683. return X11_NAVYBLUE;
  11684. }
  11685. }
  11686. }
  11687. idx += 4;
  11688. return X11_NAVY;
  11689. }
  11690. }
  11691. }
  11692. case 'o':
  11693. {
  11694. switch (str[1] | 0x20)
  11695. {
  11696. case 'l':
  11697. {
  11698. switch (str[2] | 0x20)
  11699. {
  11700. case 'd':
  11701. {
  11702. switch (str[3] | 0x20)
  11703. {
  11704. case _X11_SPACE_SWITCH: // ' '
  11705. {
  11706. if (str[3])
  11707. {
  11708. if (str[4] && !strcmp(str[4], !"LACE", true, 4))
  11709. {
  11710. idx += 8;
  11711. return X11_OLD_LACE;
  11712. }
  11713. }
  11714. }
  11715. case '_' | 0x20:
  11716. {
  11717. if (str[4] && !strcmp(str[4], !"LACE", true, 4))
  11718. {
  11719. idx += 8;
  11720. return X11_OLD_LACE;
  11721. }
  11722. }
  11723. case 'l':
  11724. {
  11725. if (str[4] && !strcmp(str[4], !"ACE", true, 3))
  11726. {
  11727. idx += 7;
  11728. return X11_OLDLACE;
  11729. }
  11730. }
  11731. }
  11732. }
  11733. case 'i':
  11734. {
  11735. if (!str[3] || strcmp(str[3], !"VE", true, 2))
  11736. {
  11737. return -1;
  11738. }
  11739. switch (str[5] | 0x20)
  11740. {
  11741. case _X11_SPACE_SWITCH: // ' '
  11742. {
  11743. if (str[5])
  11744. {
  11745. if (!str[6] || strcmp(str[6], !"DRAB", true, 4))
  11746. {
  11747. return -1;
  11748. }
  11749. switch (str[10] | 0x20)
  11750. {
  11751. case _X11_SPACE_SWITCH: // ' '
  11752. {
  11753. if (str[10])
  11754. {
  11755. switch (str[11] | 0x20)
  11756. {
  11757. case '1':
  11758. {
  11759. idx += 12;
  11760. return X11_OLIVE_DRAB_1;
  11761. }
  11762. case '2':
  11763. {
  11764. idx += 12;
  11765. return X11_OLIVE_DRAB_2;
  11766. }
  11767. case '3':
  11768. {
  11769. idx += 12;
  11770. return X11_OLIVE_DRAB_3;
  11771. }
  11772. case '4':
  11773. {
  11774. idx += 12;
  11775. return X11_OLIVE_DRAB_4;
  11776. }
  11777. }
  11778. }
  11779. }
  11780. case '_' | 0x20:
  11781. {
  11782. switch (str[11] | 0x20)
  11783. {
  11784. case '1':
  11785. {
  11786. idx += 12;
  11787. return X11_OLIVE_DRAB_1;
  11788. }
  11789. case '2':
  11790. {
  11791. idx += 12;
  11792. return X11_OLIVE_DRAB_2;
  11793. }
  11794. case '3':
  11795. {
  11796. idx += 12;
  11797. return X11_OLIVE_DRAB_3;
  11798. }
  11799. case '4':
  11800. {
  11801. idx += 12;
  11802. return X11_OLIVE_DRAB_4;
  11803. }
  11804. }
  11805. }
  11806. }
  11807. idx += 10;
  11808. return X11_OLIVE_DRAB;
  11809. }
  11810. }
  11811. case '_' | 0x20:
  11812. {
  11813. if (!str[6] || strcmp(str[6], !"DRAB", true, 4))
  11814. {
  11815. return -1;
  11816. }
  11817. switch (str[10] | 0x20)
  11818. {
  11819. case _X11_SPACE_SWITCH: // ' '
  11820. {
  11821. if (str[10])
  11822. {
  11823. switch (str[11] | 0x20)
  11824. {
  11825. case '1':
  11826. {
  11827. idx += 12;
  11828. return X11_OLIVE_DRAB_1;
  11829. }
  11830. case '2':
  11831. {
  11832. idx += 12;
  11833. return X11_OLIVE_DRAB_2;
  11834. }
  11835. case '3':
  11836. {
  11837. idx += 12;
  11838. return X11_OLIVE_DRAB_3;
  11839. }
  11840. case '4':
  11841. {
  11842. idx += 12;
  11843. return X11_OLIVE_DRAB_4;
  11844. }
  11845. }
  11846. }
  11847. }
  11848. case '_' | 0x20:
  11849. {
  11850. switch (str[11] | 0x20)
  11851. {
  11852. case '1':
  11853. {
  11854. idx += 12;
  11855. return X11_OLIVE_DRAB_1;
  11856. }
  11857. case '2':
  11858. {
  11859. idx += 12;
  11860. return X11_OLIVE_DRAB_2;
  11861. }
  11862. case '3':
  11863. {
  11864. idx += 12;
  11865. return X11_OLIVE_DRAB_3;
  11866. }
  11867. case '4':
  11868. {
  11869. idx += 12;
  11870. return X11_OLIVE_DRAB_4;
  11871. }
  11872. }
  11873. }
  11874. }
  11875. idx += 10;
  11876. return X11_OLIVE_DRAB;
  11877. }
  11878. case 'd':
  11879. {
  11880. if (!str[6] || strcmp(str[6], !"RAB", true, 3))
  11881. {
  11882. return -1;
  11883. }
  11884. switch (str[9] | 0x20)
  11885. {
  11886. case '1':
  11887. {
  11888. idx += 10;
  11889. return X11_OLIVEDRAB1;
  11890. }
  11891. case '2':
  11892. {
  11893. idx += 10;
  11894. return X11_OLIVEDRAB2;
  11895. }
  11896. case '3':
  11897. {
  11898. idx += 10;
  11899. return X11_OLIVEDRAB3;
  11900. }
  11901. case '4':
  11902. {
  11903. idx += 10;
  11904. return X11_OLIVEDRAB4;
  11905. }
  11906. }
  11907. idx += 9;
  11908. return X11_OLIVEDRAB;
  11909. }
  11910. }
  11911. }
  11912. }
  11913. }
  11914. case 'r':
  11915. {
  11916. switch (str[2] | 0x20)
  11917. {
  11918. case 'a':
  11919. {
  11920. if (!str[3] || strcmp(str[3], !"NGE", true, 3))
  11921. {
  11922. return -1;
  11923. }
  11924. switch (str[6] | 0x20)
  11925. {
  11926. case _X11_SPACE_SWITCH: // ' '
  11927. {
  11928. if (str[6])
  11929. {
  11930. switch (str[7] | 0x20)
  11931. {
  11932. case '1':
  11933. {
  11934. idx += 8;
  11935. return X11_ORANGE_1;
  11936. }
  11937. case '2':
  11938. {
  11939. idx += 8;
  11940. return X11_ORANGE_2;
  11941. }
  11942. case '3':
  11943. {
  11944. idx += 8;
  11945. return X11_ORANGE_3;
  11946. }
  11947. case '4':
  11948. {
  11949. idx += 8;
  11950. return X11_ORANGE_4;
  11951. }
  11952. case 'r':
  11953. {
  11954. if (!str[8] || strcmp(str[8], !"ED", true, 2))
  11955. {
  11956. return -1;
  11957. }
  11958. switch (str[10] | 0x20)
  11959. {
  11960. case _X11_SPACE_SWITCH: // ' '
  11961. {
  11962. if (str[10])
  11963. {
  11964. switch (str[11] | 0x20)
  11965. {
  11966. case '1':
  11967. {
  11968. idx += 12;
  11969. return X11_ORANGE_RED_1;
  11970. }
  11971. case '2':
  11972. {
  11973. idx += 12;
  11974. return X11_ORANGE_RED_2;
  11975. }
  11976. case '3':
  11977. {
  11978. idx += 12;
  11979. return X11_ORANGE_RED_3;
  11980. }
  11981. case '4':
  11982. {
  11983. idx += 12;
  11984. return X11_ORANGE_RED_4;
  11985. }
  11986. }
  11987. }
  11988. }
  11989. case '_' | 0x20:
  11990. {
  11991. switch (str[11] | 0x20)
  11992. {
  11993. case '1':
  11994. {
  11995. idx += 12;
  11996. return X11_ORANGE_RED_1;
  11997. }
  11998. case '2':
  11999. {
  12000. idx += 12;
  12001. return X11_ORANGE_RED_2;
  12002. }
  12003. case '3':
  12004. {
  12005. idx += 12;
  12006. return X11_ORANGE_RED_3;
  12007. }
  12008. case '4':
  12009. {
  12010. idx += 12;
  12011. return X11_ORANGE_RED_4;
  12012. }
  12013. }
  12014. }
  12015. }
  12016. idx += 10;
  12017. return X11_ORANGE_RED;
  12018. }
  12019. }
  12020. }
  12021. }
  12022. case '_' | 0x20:
  12023. {
  12024. switch (str[7] | 0x20)
  12025. {
  12026. case '1':
  12027. {
  12028. idx += 8;
  12029. return X11_ORANGE_1;
  12030. }
  12031. case '2':
  12032. {
  12033. idx += 8;
  12034. return X11_ORANGE_2;
  12035. }
  12036. case '3':
  12037. {
  12038. idx += 8;
  12039. return X11_ORANGE_3;
  12040. }
  12041. case '4':
  12042. {
  12043. idx += 8;
  12044. return X11_ORANGE_4;
  12045. }
  12046. case 'r':
  12047. {
  12048. if (!str[8] || strcmp(str[8], !"ED", true, 2))
  12049. {
  12050. return -1;
  12051. }
  12052. switch (str[10] | 0x20)
  12053. {
  12054. case _X11_SPACE_SWITCH: // ' '
  12055. {
  12056. if (str[10])
  12057. {
  12058. switch (str[11] | 0x20)
  12059. {
  12060. case '1':
  12061. {
  12062. idx += 12;
  12063. return X11_ORANGE_RED_1;
  12064. }
  12065. case '2':
  12066. {
  12067. idx += 12;
  12068. return X11_ORANGE_RED_2;
  12069. }
  12070. case '3':
  12071. {
  12072. idx += 12;
  12073. return X11_ORANGE_RED_3;
  12074. }
  12075. case '4':
  12076. {
  12077. idx += 12;
  12078. return X11_ORANGE_RED_4;
  12079. }
  12080. }
  12081. }
  12082. }
  12083. case '_' | 0x20:
  12084. {
  12085. switch (str[11] | 0x20)
  12086. {
  12087. case '1':
  12088. {
  12089. idx += 12;
  12090. return X11_ORANGE_RED_1;
  12091. }
  12092. case '2':
  12093. {
  12094. idx += 12;
  12095. return X11_ORANGE_RED_2;
  12096. }
  12097. case '3':
  12098. {
  12099. idx += 12;
  12100. return X11_ORANGE_RED_3;
  12101. }
  12102. case '4':
  12103. {
  12104. idx += 12;
  12105. return X11_ORANGE_RED_4;
  12106. }
  12107. }
  12108. }
  12109. }
  12110. idx += 10;
  12111. return X11_ORANGE_RED;
  12112. }
  12113. }
  12114. }
  12115. case '1':
  12116. {
  12117. idx += 7;
  12118. return X11_ORANGE1;
  12119. }
  12120. case '2':
  12121. {
  12122. idx += 7;
  12123. return X11_ORANGE2;
  12124. }
  12125. case '3':
  12126. {
  12127. idx += 7;
  12128. return X11_ORANGE3;
  12129. }
  12130. case '4':
  12131. {
  12132. idx += 7;
  12133. return X11_ORANGE4;
  12134. }
  12135. case 'r':
  12136. {
  12137. if (!str[7] || strcmp(str[7], !"ED", true, 2))
  12138. {
  12139. return -1;
  12140. }
  12141. switch (str[9] | 0x20)
  12142. {
  12143. case '1':
  12144. {
  12145. idx += 10;
  12146. return X11_ORANGERED1;
  12147. }
  12148. case '2':
  12149. {
  12150. idx += 10;
  12151. return X11_ORANGERED2;
  12152. }
  12153. case '3':
  12154. {
  12155. idx += 10;
  12156. return X11_ORANGERED3;
  12157. }
  12158. case '4':
  12159. {
  12160. idx += 10;
  12161. return X11_ORANGERED4;
  12162. }
  12163. }
  12164. idx += 9;
  12165. return X11_ORANGERED;
  12166. }
  12167. }
  12168. idx += 6;
  12169. return X11_ORANGE;
  12170. }
  12171. case 'c':
  12172. {
  12173. if (!str[3] || strcmp(str[3], !"HID", true, 3))
  12174. {
  12175. return -1;
  12176. }
  12177. switch (str[6] | 0x20)
  12178. {
  12179. case _X11_SPACE_SWITCH: // ' '
  12180. {
  12181. if (str[6])
  12182. {
  12183. switch (str[7] | 0x20)
  12184. {
  12185. case '1':
  12186. {
  12187. idx += 8;
  12188. return X11_ORCHID_1;
  12189. }
  12190. case '2':
  12191. {
  12192. idx += 8;
  12193. return X11_ORCHID_2;
  12194. }
  12195. case '3':
  12196. {
  12197. idx += 8;
  12198. return X11_ORCHID_3;
  12199. }
  12200. case '4':
  12201. {
  12202. idx += 8;
  12203. return X11_ORCHID_4;
  12204. }
  12205. }
  12206. }
  12207. }
  12208. case '_' | 0x20:
  12209. {
  12210. switch (str[7] | 0x20)
  12211. {
  12212. case '1':
  12213. {
  12214. idx += 8;
  12215. return X11_ORCHID_1;
  12216. }
  12217. case '2':
  12218. {
  12219. idx += 8;
  12220. return X11_ORCHID_2;
  12221. }
  12222. case '3':
  12223. {
  12224. idx += 8;
  12225. return X11_ORCHID_3;
  12226. }
  12227. case '4':
  12228. {
  12229. idx += 8;
  12230. return X11_ORCHID_4;
  12231. }
  12232. }
  12233. }
  12234. case '1':
  12235. {
  12236. idx += 7;
  12237. return X11_ORCHID1;
  12238. }
  12239. case '2':
  12240. {
  12241. idx += 7;
  12242. return X11_ORCHID2;
  12243. }
  12244. case '3':
  12245. {
  12246. idx += 7;
  12247. return X11_ORCHID3;
  12248. }
  12249. case '4':
  12250. {
  12251. idx += 7;
  12252. return X11_ORCHID4;
  12253. }
  12254. }
  12255. idx += 6;
  12256. return X11_ORCHID;
  12257. }
  12258. }
  12259. }
  12260. }
  12261. }
  12262. case 'p':
  12263. {
  12264. switch (str[1] | 0x20)
  12265. {
  12266. case 'a':
  12267. {
  12268. switch (str[2] | 0x20)
  12269. {
  12270. case 'l':
  12271. {
  12272. if (str[3] | 0x20 != 'e')
  12273. {
  12274. return -1;
  12275. }
  12276. switch (str[4] | 0x20)
  12277. {
  12278. case _X11_SPACE_SWITCH: // ' '
  12279. {
  12280. if (str[4])
  12281. {
  12282. switch (str[5] | 0x20)
  12283. {
  12284. case 'g':
  12285. {
  12286. switch (str[6] | 0x20)
  12287. {
  12288. case 'o':
  12289. {
  12290. if (str[7] && !strcmp(str[7], !"LDENROD", true, 7))
  12291. {
  12292. idx += 14;
  12293. return X11_PALE_GOLDENROD;
  12294. }
  12295. }
  12296. case 'r':
  12297. {
  12298. if (!str[7] || strcmp(str[7], !"EEN", true, 3))
  12299. {
  12300. return -1;
  12301. }
  12302. switch (str[10] | 0x20)
  12303. {
  12304. case _X11_SPACE_SWITCH: // ' '
  12305. {
  12306. if (str[10])
  12307. {
  12308. switch (str[11] | 0x20)
  12309. {
  12310. case '1':
  12311. {
  12312. idx += 12;
  12313. return X11_PALE_GREEN_1;
  12314. }
  12315. case '2':
  12316. {
  12317. idx += 12;
  12318. return X11_PALE_GREEN_2;
  12319. }
  12320. case '3':
  12321. {
  12322. idx += 12;
  12323. return X11_PALE_GREEN_3;
  12324. }
  12325. case '4':
  12326. {
  12327. idx += 12;
  12328. return X11_PALE_GREEN_4;
  12329. }
  12330. }
  12331. }
  12332. }
  12333. case '_' | 0x20:
  12334. {
  12335. switch (str[11] | 0x20)
  12336. {
  12337. case '1':
  12338. {
  12339. idx += 12;
  12340. return X11_PALE_GREEN_1;
  12341. }
  12342. case '2':
  12343. {
  12344. idx += 12;
  12345. return X11_PALE_GREEN_2;
  12346. }
  12347. case '3':
  12348. {
  12349. idx += 12;
  12350. return X11_PALE_GREEN_3;
  12351. }
  12352. case '4':
  12353. {
  12354. idx += 12;
  12355. return X11_PALE_GREEN_4;
  12356. }
  12357. }
  12358. }
  12359. }
  12360. idx += 10;
  12361. return X11_PALE_GREEN;
  12362. }
  12363. }
  12364. }
  12365. case 't':
  12366. {
  12367. if (!str[6] || strcmp(str[6], !"URQUOISE", true, 8))
  12368. {
  12369. return -1;
  12370. }
  12371. switch (str[14] | 0x20)
  12372. {
  12373. case _X11_SPACE_SWITCH: // ' '
  12374. {
  12375. if (str[14])
  12376. {
  12377. switch (str[15] | 0x20)
  12378. {
  12379. case '1':
  12380. {
  12381. idx += 16;
  12382. return X11_PALE_TURQUOISE_1;
  12383. }
  12384. case '2':
  12385. {
  12386. idx += 16;
  12387. return X11_PALE_TURQUOISE_2;
  12388. }
  12389. case '3':
  12390. {
  12391. idx += 16;
  12392. return X11_PALE_TURQUOISE_3;
  12393. }
  12394. case '4':
  12395. {
  12396. idx += 16;
  12397. return X11_PALE_TURQUOISE_4;
  12398. }
  12399. }
  12400. }
  12401. }
  12402. case '_' | 0x20:
  12403. {
  12404. switch (str[15] | 0x20)
  12405. {
  12406. case '1':
  12407. {
  12408. idx += 16;
  12409. return X11_PALE_TURQUOISE_1;
  12410. }
  12411. case '2':
  12412. {
  12413. idx += 16;
  12414. return X11_PALE_TURQUOISE_2;
  12415. }
  12416. case '3':
  12417. {
  12418. idx += 16;
  12419. return X11_PALE_TURQUOISE_3;
  12420. }
  12421. case '4':
  12422. {
  12423. idx += 16;
  12424. return X11_PALE_TURQUOISE_4;
  12425. }
  12426. }
  12427. }
  12428. }
  12429. idx += 14;
  12430. return X11_PALE_TURQUOISE;
  12431. }
  12432. case 'v':
  12433. {
  12434. if (!str[6] || strcmp(str[6], !"IOLET", true, 5) || (!_X11_SPACE_CHECK(11) && str[11] != '_') || strcmp(str[12], !"RED", true, 3))
  12435. //if (!str[6] || strcmp(str[6], !"IOLET_RED", true, 9))
  12436. {
  12437. return -1;
  12438. }
  12439. switch (str[15] | 0x20)
  12440. {
  12441. case _X11_SPACE_SWITCH: // ' '
  12442. {
  12443. if (str[15])
  12444. {
  12445. switch (str[16] | 0x20)
  12446. {
  12447. case '1':
  12448. {
  12449. idx += 17;
  12450. return X11_PALE_VIOLET_RED_1;
  12451. }
  12452. case '2':
  12453. {
  12454. idx += 17;
  12455. return X11_PALE_VIOLET_RED_2;
  12456. }
  12457. case '3':
  12458. {
  12459. idx += 17;
  12460. return X11_PALE_VIOLET_RED_3;
  12461. }
  12462. case '4':
  12463. {
  12464. idx += 17;
  12465. return X11_PALE_VIOLET_RED_4;
  12466. }
  12467. }
  12468. }
  12469. }
  12470. case '_' | 0x20:
  12471. {
  12472. switch (str[16] | 0x20)
  12473. {
  12474. case '1':
  12475. {
  12476. idx += 17;
  12477. return X11_PALE_VIOLET_RED_1;
  12478. }
  12479. case '2':
  12480. {
  12481. idx += 17;
  12482. return X11_PALE_VIOLET_RED_2;
  12483. }
  12484. case '3':
  12485. {
  12486. idx += 17;
  12487. return X11_PALE_VIOLET_RED_3;
  12488. }
  12489. case '4':
  12490. {
  12491. idx += 17;
  12492. return X11_PALE_VIOLET_RED_4;
  12493. }
  12494. }
  12495. }
  12496. }
  12497. idx += 15;
  12498. return X11_PALE_VIOLET_RED;
  12499. }
  12500. }
  12501. }
  12502. }
  12503. case '_' | 0x20:
  12504. {
  12505. switch (str[5] | 0x20)
  12506. {
  12507. case 'g':
  12508. {
  12509. switch (str[6] | 0x20)
  12510. {
  12511. case 'o':
  12512. {
  12513. if (str[7] && !strcmp(str[7], !"LDENROD", true, 7))
  12514. {
  12515. idx += 14;
  12516. return X11_PALE_GOLDENROD;
  12517. }
  12518. }
  12519. case 'r':
  12520. {
  12521. if (!str[7] || strcmp(str[7], !"EEN", true, 3))
  12522. {
  12523. return -1;
  12524. }
  12525. switch (str[10] | 0x20)
  12526. {
  12527. case _X11_SPACE_SWITCH: // ' '
  12528. {
  12529. if (str[10])
  12530. {
  12531. switch (str[11] | 0x20)
  12532. {
  12533. case '1':
  12534. {
  12535. idx += 12;
  12536. return X11_PALE_GREEN_1;
  12537. }
  12538. case '2':
  12539. {
  12540. idx += 12;
  12541. return X11_PALE_GREEN_2;
  12542. }
  12543. case '3':
  12544. {
  12545. idx += 12;
  12546. return X11_PALE_GREEN_3;
  12547. }
  12548. case '4':
  12549. {
  12550. idx += 12;
  12551. return X11_PALE_GREEN_4;
  12552. }
  12553. }
  12554. }
  12555. }
  12556. case '_' | 0x20:
  12557. {
  12558. switch (str[11] | 0x20)
  12559. {
  12560. case '1':
  12561. {
  12562. idx += 12;
  12563. return X11_PALE_GREEN_1;
  12564. }
  12565. case '2':
  12566. {
  12567. idx += 12;
  12568. return X11_PALE_GREEN_2;
  12569. }
  12570. case '3':
  12571. {
  12572. idx += 12;
  12573. return X11_PALE_GREEN_3;
  12574. }
  12575. case '4':
  12576. {
  12577. idx += 12;
  12578. return X11_PALE_GREEN_4;
  12579. }
  12580. }
  12581. }
  12582. }
  12583. idx += 10;
  12584. return X11_PALE_GREEN;
  12585. }
  12586. }
  12587. }
  12588. case 't':
  12589. {
  12590. if (!str[6] || strcmp(str[6], !"URQUOISE", true, 8))
  12591. {
  12592. return -1;
  12593. }
  12594. switch (str[14] | 0x20)
  12595. {
  12596. case _X11_SPACE_SWITCH: // ' '
  12597. {
  12598. if (str[14])
  12599. {
  12600. switch (str[15] | 0x20)
  12601. {
  12602. case '1':
  12603. {
  12604. idx += 16;
  12605. return X11_PALE_TURQUOISE_1;
  12606. }
  12607. case '2':
  12608. {
  12609. idx += 16;
  12610. return X11_PALE_TURQUOISE_2;
  12611. }
  12612. case '3':
  12613. {
  12614. idx += 16;
  12615. return X11_PALE_TURQUOISE_3;
  12616. }
  12617. case '4':
  12618. {
  12619. idx += 16;
  12620. return X11_PALE_TURQUOISE_4;
  12621. }
  12622. }
  12623. }
  12624. }
  12625. case '_' | 0x20:
  12626. {
  12627. switch (str[15] | 0x20)
  12628. {
  12629. case '1':
  12630. {
  12631. idx += 16;
  12632. return X11_PALE_TURQUOISE_1;
  12633. }
  12634. case '2':
  12635. {
  12636. idx += 16;
  12637. return X11_PALE_TURQUOISE_2;
  12638. }
  12639. case '3':
  12640. {
  12641. idx += 16;
  12642. return X11_PALE_TURQUOISE_3;
  12643. }
  12644. case '4':
  12645. {
  12646. idx += 16;
  12647. return X11_PALE_TURQUOISE_4;
  12648. }
  12649. }
  12650. }
  12651. }
  12652. idx += 14;
  12653. return X11_PALE_TURQUOISE;
  12654. }
  12655. case 'v':
  12656. {
  12657. if (!str[6] || strcmp(str[6], !"IOLET", true, 5) || (!_X11_SPACE_CHECK(11) && str[11] != '_') || strcmp(str[12], !"RED", true, 3))
  12658. //if (!str[6] || strcmp(str[6], !"IOLET_RED", true, 9))
  12659. {
  12660. return -1;
  12661. }
  12662. switch (str[15] | 0x20)
  12663. {
  12664. case _X11_SPACE_SWITCH: // ' '
  12665. {
  12666. if (str[15])
  12667. {
  12668. switch (str[16] | 0x20)
  12669. {
  12670. case '1':
  12671. {
  12672. idx += 17;
  12673. return X11_PALE_VIOLET_RED_1;
  12674. }
  12675. case '2':
  12676. {
  12677. idx += 17;
  12678. return X11_PALE_VIOLET_RED_2;
  12679. }
  12680. case '3':
  12681. {
  12682. idx += 17;
  12683. return X11_PALE_VIOLET_RED_3;
  12684. }
  12685. case '4':
  12686. {
  12687. idx += 17;
  12688. return X11_PALE_VIOLET_RED_4;
  12689. }
  12690. }
  12691. }
  12692. }
  12693. case '_' | 0x20:
  12694. {
  12695. switch (str[16] | 0x20)
  12696. {
  12697. case '1':
  12698. {
  12699. idx += 17;
  12700. return X11_PALE_VIOLET_RED_1;
  12701. }
  12702. case '2':
  12703. {
  12704. idx += 17;
  12705. return X11_PALE_VIOLET_RED_2;
  12706. }
  12707. case '3':
  12708. {
  12709. idx += 17;
  12710. return X11_PALE_VIOLET_RED_3;
  12711. }
  12712. case '4':
  12713. {
  12714. idx += 17;
  12715. return X11_PALE_VIOLET_RED_4;
  12716. }
  12717. }
  12718. }
  12719. }
  12720. idx += 15;
  12721. return X11_PALE_VIOLET_RED;
  12722. }
  12723. }
  12724. }
  12725. case 'g':
  12726. {
  12727. switch (str[5] | 0x20)
  12728. {
  12729. case 'o':
  12730. {
  12731. if (str[6] && !strcmp(str[6], !"LDENROD", true, 7))
  12732. {
  12733. idx += 13;
  12734. return X11_PALEGOLDENROD;
  12735. }
  12736. }
  12737. case 'r':
  12738. {
  12739. if (!str[6] || strcmp(str[6], !"EEN", true, 3))
  12740. {
  12741. return -1;
  12742. }
  12743. switch (str[9] | 0x20)
  12744. {
  12745. case '1':
  12746. {
  12747. idx += 10;
  12748. return X11_PALEGREEN1;
  12749. }
  12750. case '2':
  12751. {
  12752. idx += 10;
  12753. return X11_PALEGREEN2;
  12754. }
  12755. case '3':
  12756. {
  12757. idx += 10;
  12758. return X11_PALEGREEN3;
  12759. }
  12760. case '4':
  12761. {
  12762. idx += 10;
  12763. return X11_PALEGREEN4;
  12764. }
  12765. }
  12766. idx += 9;
  12767. return X11_PALEGREEN;
  12768. }
  12769. }
  12770. }
  12771. case 't':
  12772. {
  12773. if (!str[5] || strcmp(str[5], !"URQUOISE", true, 8))
  12774. {
  12775. return -1;
  12776. }
  12777. switch (str[13] | 0x20)
  12778. {
  12779. case '1':
  12780. {
  12781. idx += 14;
  12782. return X11_PALETURQUOISE1;
  12783. }
  12784. case '2':
  12785. {
  12786. idx += 14;
  12787. return X11_PALETURQUOISE2;
  12788. }
  12789. case '3':
  12790. {
  12791. idx += 14;
  12792. return X11_PALETURQUOISE3;
  12793. }
  12794. case '4':
  12795. {
  12796. idx += 14;
  12797. return X11_PALETURQUOISE4;
  12798. }
  12799. }
  12800. idx += 13;
  12801. return X11_PALETURQUOISE;
  12802. }
  12803. case 'v':
  12804. {
  12805. if (!str[5] || strcmp(str[5], !"IOLETRED", true, 8))
  12806. {
  12807. return -1;
  12808. }
  12809. switch (str[13] | 0x20)
  12810. {
  12811. case '1':
  12812. {
  12813. idx += 14;
  12814. return X11_PALEVIOLETRED1;
  12815. }
  12816. case '2':
  12817. {
  12818. idx += 14;
  12819. return X11_PALEVIOLETRED2;
  12820. }
  12821. case '3':
  12822. {
  12823. idx += 14;
  12824. return X11_PALEVIOLETRED3;
  12825. }
  12826. case '4':
  12827. {
  12828. idx += 14;
  12829. return X11_PALEVIOLETRED4;
  12830. }
  12831. }
  12832. idx += 13;
  12833. return X11_PALEVIOLETRED;
  12834. }
  12835. }
  12836. }
  12837. case 'p':
  12838. {
  12839. if (!str[3] || strcmp(str[3], !"AYA", true, 3))
  12840. {
  12841. return -1;
  12842. }
  12843. switch (str[6] | 0x20)
  12844. {
  12845. case _X11_SPACE_SWITCH: // ' '
  12846. {
  12847. if (str[6])
  12848. {
  12849. if (str[7] && !strcmp(str[7], !"WHIP", true, 4))
  12850. {
  12851. idx += 11;
  12852. return X11_PAPAYA_WHIP;
  12853. }
  12854. }
  12855. }
  12856. case '_' | 0x20:
  12857. {
  12858. if (str[7] && !strcmp(str[7], !"WHIP", true, 4))
  12859. {
  12860. idx += 11;
  12861. return X11_PAPAYA_WHIP;
  12862. }
  12863. }
  12864. case 'w':
  12865. {
  12866. if (str[7] && !strcmp(str[7], !"HIP", true, 3))
  12867. {
  12868. idx += 10;
  12869. return X11_PAPAYAWHIP;
  12870. }
  12871. }
  12872. }
  12873. }
  12874. }
  12875. }
  12876. case 'e':
  12877. {
  12878. switch (str[2] | 0x20)
  12879. {
  12880. case 'a':
  12881. {
  12882. if (!str[3] || strcmp(str[3], !"CH", true, 2))
  12883. {
  12884. return -1;
  12885. }
  12886. switch (str[5] | 0x20)
  12887. {
  12888. case _X11_SPACE_SWITCH: // ' '
  12889. {
  12890. if (str[5])
  12891. {
  12892. if (!str[6] || strcmp(str[6], !"PUFF", true, 4))
  12893. {
  12894. return -1;
  12895. }
  12896. switch (str[10] | 0x20)
  12897. {
  12898. case _X11_SPACE_SWITCH: // ' '
  12899. {
  12900. if (str[10])
  12901. {
  12902. switch (str[11] | 0x20)
  12903. {
  12904. case '1':
  12905. {
  12906. idx += 12;
  12907. return X11_PEACH_PUFF_1;
  12908. }
  12909. case '2':
  12910. {
  12911. idx += 12;
  12912. return X11_PEACH_PUFF_2;
  12913. }
  12914. case '3':
  12915. {
  12916. idx += 12;
  12917. return X11_PEACH_PUFF_3;
  12918. }
  12919. case '4':
  12920. {
  12921. idx += 12;
  12922. return X11_PEACH_PUFF_4;
  12923. }
  12924. }
  12925. }
  12926. }
  12927. case '_' | 0x20:
  12928. {
  12929. switch (str[11] | 0x20)
  12930. {
  12931. case '1':
  12932. {
  12933. idx += 12;
  12934. return X11_PEACH_PUFF_1;
  12935. }
  12936. case '2':
  12937. {
  12938. idx += 12;
  12939. return X11_PEACH_PUFF_2;
  12940. }
  12941. case '3':
  12942. {
  12943. idx += 12;
  12944. return X11_PEACH_PUFF_3;
  12945. }
  12946. case '4':
  12947. {
  12948. idx += 12;
  12949. return X11_PEACH_PUFF_4;
  12950. }
  12951. }
  12952. }
  12953. }
  12954. idx += 10;
  12955. return X11_PEACH_PUFF;
  12956. }
  12957. }
  12958. case '_' | 0x20:
  12959. {
  12960. if (!str[6] || strcmp(str[6], !"PUFF", true, 4))
  12961. {
  12962. return -1;
  12963. }
  12964. switch (str[10] | 0x20)
  12965. {
  12966. case _X11_SPACE_SWITCH: // ' '
  12967. {
  12968. if (str[10])
  12969. {
  12970. switch (str[11] | 0x20)
  12971. {
  12972. case '1':
  12973. {
  12974. idx += 12;
  12975. return X11_PEACH_PUFF_1;
  12976. }
  12977. case '2':
  12978. {
  12979. idx += 12;
  12980. return X11_PEACH_PUFF_2;
  12981. }
  12982. case '3':
  12983. {
  12984. idx += 12;
  12985. return X11_PEACH_PUFF_3;
  12986. }
  12987. case '4':
  12988. {
  12989. idx += 12;
  12990. return X11_PEACH_PUFF_4;
  12991. }
  12992. }
  12993. }
  12994. }
  12995. case '_' | 0x20:
  12996. {
  12997. switch (str[11] | 0x20)
  12998. {
  12999. case '1':
  13000. {
  13001. idx += 12;
  13002. return X11_PEACH_PUFF_1;
  13003. }
  13004. case '2':
  13005. {
  13006. idx += 12;
  13007. return X11_PEACH_PUFF_2;
  13008. }
  13009. case '3':
  13010. {
  13011. idx += 12;
  13012. return X11_PEACH_PUFF_3;
  13013. }
  13014. case '4':
  13015. {
  13016. idx += 12;
  13017. return X11_PEACH_PUFF_4;
  13018. }
  13019. }
  13020. }
  13021. }
  13022. idx += 10;
  13023. return X11_PEACH_PUFF;
  13024. }
  13025. case 'p':
  13026. {
  13027. if (!str[6] || strcmp(str[6], !"UFF", true, 3))
  13028. {
  13029. return -1;
  13030. }
  13031. switch (str[9] | 0x20)
  13032. {
  13033. case '1':
  13034. {
  13035. idx += 10;
  13036. return X11_PEACHPUFF1;
  13037. }
  13038. case '2':
  13039. {
  13040. idx += 10;
  13041. return X11_PEACHPUFF2;
  13042. }
  13043. case '3':
  13044. {
  13045. idx += 10;
  13046. return X11_PEACHPUFF3;
  13047. }
  13048. case '4':
  13049. {
  13050. idx += 10;
  13051. return X11_PEACHPUFF4;
  13052. }
  13053. }
  13054. idx += 9;
  13055. return X11_PEACHPUFF;
  13056. }
  13057. }
  13058. }
  13059. case 'r':
  13060. {
  13061. if (str[3] | 0x20 == 'u')
  13062. {
  13063. idx += 4;
  13064. return X11_PERU;
  13065. }
  13066. }
  13067. }
  13068. }
  13069. case 'i':
  13070. {
  13071. if (!str[2] || strcmp(str[2], !"NK", true, 2))
  13072. {
  13073. return -1;
  13074. }
  13075. switch (str[4] | 0x20)
  13076. {
  13077. case _X11_SPACE_SWITCH: // ' '
  13078. {
  13079. if (str[4])
  13080. {
  13081. switch (str[5] | 0x20)
  13082. {
  13083. case '1':
  13084. {
  13085. idx += 6;
  13086. return X11_PINK_1;
  13087. }
  13088. case '2':
  13089. {
  13090. idx += 6;
  13091. return X11_PINK_2;
  13092. }
  13093. case '3':
  13094. {
  13095. idx += 6;
  13096. return X11_PINK_3;
  13097. }
  13098. case '4':
  13099. {
  13100. idx += 6;
  13101. return X11_PINK_4;
  13102. }
  13103. }
  13104. }
  13105. }
  13106. case '_' | 0x20:
  13107. {
  13108. switch (str[5] | 0x20)
  13109. {
  13110. case '1':
  13111. {
  13112. idx += 6;
  13113. return X11_PINK_1;
  13114. }
  13115. case '2':
  13116. {
  13117. idx += 6;
  13118. return X11_PINK_2;
  13119. }
  13120. case '3':
  13121. {
  13122. idx += 6;
  13123. return X11_PINK_3;
  13124. }
  13125. case '4':
  13126. {
  13127. idx += 6;
  13128. return X11_PINK_4;
  13129. }
  13130. }
  13131. }
  13132. case '1':
  13133. {
  13134. idx += 5;
  13135. return X11_PINK1;
  13136. }
  13137. case '2':
  13138. {
  13139. idx += 5;
  13140. return X11_PINK2;
  13141. }
  13142. case '3':
  13143. {
  13144. idx += 5;
  13145. return X11_PINK3;
  13146. }
  13147. case '4':
  13148. {
  13149. idx += 5;
  13150. return X11_PINK4;
  13151. }
  13152. }
  13153. idx += 4;
  13154. return X11_PINK;
  13155. }
  13156. case 'l':
  13157. {
  13158. if (!str[2] || strcmp(str[2], !"UM", true, 2))
  13159. {
  13160. return -1;
  13161. }
  13162. switch (str[4] | 0x20)
  13163. {
  13164. case _X11_SPACE_SWITCH: // ' '
  13165. {
  13166. if (str[4])
  13167. {
  13168. switch (str[5] | 0x20)
  13169. {
  13170. case '1':
  13171. {
  13172. idx += 6;
  13173. return X11_PLUM_1;
  13174. }
  13175. case '2':
  13176. {
  13177. idx += 6;
  13178. return X11_PLUM_2;
  13179. }
  13180. case '3':
  13181. {
  13182. idx += 6;
  13183. return X11_PLUM_3;
  13184. }
  13185. case '4':
  13186. {
  13187. idx += 6;
  13188. return X11_PLUM_4;
  13189. }
  13190. }
  13191. }
  13192. }
  13193. case '_' | 0x20:
  13194. {
  13195. switch (str[5] | 0x20)
  13196. {
  13197. case '1':
  13198. {
  13199. idx += 6;
  13200. return X11_PLUM_1;
  13201. }
  13202. case '2':
  13203. {
  13204. idx += 6;
  13205. return X11_PLUM_2;
  13206. }
  13207. case '3':
  13208. {
  13209. idx += 6;
  13210. return X11_PLUM_3;
  13211. }
  13212. case '4':
  13213. {
  13214. idx += 6;
  13215. return X11_PLUM_4;
  13216. }
  13217. }
  13218. }
  13219. case '1':
  13220. {
  13221. idx += 5;
  13222. return X11_PLUM1;
  13223. }
  13224. case '2':
  13225. {
  13226. idx += 5;
  13227. return X11_PLUM2;
  13228. }
  13229. case '3':
  13230. {
  13231. idx += 5;
  13232. return X11_PLUM3;
  13233. }
  13234. case '4':
  13235. {
  13236. idx += 5;
  13237. return X11_PLUM4;
  13238. }
  13239. }
  13240. idx += 4;
  13241. return X11_PLUM;
  13242. }
  13243. case 'o':
  13244. {
  13245. if (!str[2] || strcmp(str[2], !"WDER", true, 4))
  13246. {
  13247. return -1;
  13248. }
  13249. switch (str[6] | 0x20)
  13250. {
  13251. case _X11_SPACE_SWITCH: // ' '
  13252. {
  13253. if (str[6])
  13254. {
  13255. if (str[7] && !strcmp(str[7], !"BLUE", true, 4))
  13256. {
  13257. idx += 11;
  13258. return X11_POWDER_BLUE;
  13259. }
  13260. }
  13261. }
  13262. case '_' | 0x20:
  13263. {
  13264. if (str[7] && !strcmp(str[7], !"BLUE", true, 4))
  13265. {
  13266. idx += 11;
  13267. return X11_POWDER_BLUE;
  13268. }
  13269. }
  13270. case 'b':
  13271. {
  13272. if (str[7] && !strcmp(str[7], !"LUE", true, 3))
  13273. {
  13274. idx += 10;
  13275. return X11_POWDERBLUE;
  13276. }
  13277. }
  13278. }
  13279. }
  13280. case 'u':
  13281. {
  13282. if (!str[2] || strcmp(str[2], !"RPLE", true, 4))
  13283. {
  13284. return -1;
  13285. }
  13286. switch (str[6] | 0x20)
  13287. {
  13288. case _X11_SPACE_SWITCH: // ' '
  13289. {
  13290. if (str[6])
  13291. {
  13292. switch (str[7] | 0x20)
  13293. {
  13294. case '1':
  13295. {
  13296. idx += 8;
  13297. return X11_PURPLE_1;
  13298. }
  13299. case '2':
  13300. {
  13301. idx += 8;
  13302. return X11_PURPLE_2;
  13303. }
  13304. case '3':
  13305. {
  13306. idx += 8;
  13307. return X11_PURPLE_3;
  13308. }
  13309. case '4':
  13310. {
  13311. idx += 8;
  13312. return X11_PURPLE_4;
  13313. }
  13314. }
  13315. }
  13316. }
  13317. case '_' | 0x20:
  13318. {
  13319. switch (str[7] | 0x20)
  13320. {
  13321. case '1':
  13322. {
  13323. idx += 8;
  13324. return X11_PURPLE_1;
  13325. }
  13326. case '2':
  13327. {
  13328. idx += 8;
  13329. return X11_PURPLE_2;
  13330. }
  13331. case '3':
  13332. {
  13333. idx += 8;
  13334. return X11_PURPLE_3;
  13335. }
  13336. case '4':
  13337. {
  13338. idx += 8;
  13339. return X11_PURPLE_4;
  13340. }
  13341. }
  13342. }
  13343. case '1':
  13344. {
  13345. idx += 7;
  13346. return X11_PURPLE1;
  13347. }
  13348. case '2':
  13349. {
  13350. idx += 7;
  13351. return X11_PURPLE2;
  13352. }
  13353. case '3':
  13354. {
  13355. idx += 7;
  13356. return X11_PURPLE3;
  13357. }
  13358. case '4':
  13359. {
  13360. idx += 7;
  13361. return X11_PURPLE4;
  13362. }
  13363. }
  13364. idx += 6;
  13365. return X11_PURPLE;
  13366. }
  13367. }
  13368. }
  13369. case 'r':
  13370. {
  13371. switch (str[1] | 0x20)
  13372. {
  13373. case 'e':
  13374. {
  13375. if (str[2] | 0x20 != 'd')
  13376. {
  13377. return -1;
  13378. }
  13379. switch (str[3] | 0x20)
  13380. {
  13381. case _X11_SPACE_SWITCH: // ' '
  13382. {
  13383. if (str[3])
  13384. {
  13385. switch (str[4] | 0x20)
  13386. {
  13387. case '1':
  13388. {
  13389. idx += 5;
  13390. return X11_RED_1;
  13391. }
  13392. case '2':
  13393. {
  13394. idx += 5;
  13395. return X11_RED_2;
  13396. }
  13397. case '3':
  13398. {
  13399. idx += 5;
  13400. return X11_RED_3;
  13401. }
  13402. case '4':
  13403. {
  13404. idx += 5;
  13405. return X11_RED_4;
  13406. }
  13407. }
  13408. }
  13409. }
  13410. case '_' | 0x20:
  13411. {
  13412. switch (str[4] | 0x20)
  13413. {
  13414. case '1':
  13415. {
  13416. idx += 5;
  13417. return X11_RED_1;
  13418. }
  13419. case '2':
  13420. {
  13421. idx += 5;
  13422. return X11_RED_2;
  13423. }
  13424. case '3':
  13425. {
  13426. idx += 5;
  13427. return X11_RED_3;
  13428. }
  13429. case '4':
  13430. {
  13431. idx += 5;
  13432. return X11_RED_4;
  13433. }
  13434. }
  13435. }
  13436. case '1':
  13437. {
  13438. idx += 4;
  13439. return X11_RED1;
  13440. }
  13441. case '2':
  13442. {
  13443. idx += 4;
  13444. return X11_RED2;
  13445. }
  13446. case '3':
  13447. {
  13448. idx += 4;
  13449. return X11_RED3;
  13450. }
  13451. case '4':
  13452. {
  13453. idx += 4;
  13454. return X11_RED4;
  13455. }
  13456. }
  13457. idx += 3;
  13458. return X11_RED;
  13459. }
  13460. case 'o':
  13461. {
  13462. switch (str[2] | 0x20)
  13463. {
  13464. case 's':
  13465. {
  13466. if (str[3] | 0x20 != 'y')
  13467. {
  13468. return -1;
  13469. }
  13470. switch (str[4] | 0x20)
  13471. {
  13472. case _X11_SPACE_SWITCH: // ' '
  13473. {
  13474. if (str[4])
  13475. {
  13476. if (!str[5] || strcmp(str[5], !"BROWN", true, 5))
  13477. {
  13478. return -1;
  13479. }
  13480. switch (str[10] | 0x20)
  13481. {
  13482. case _X11_SPACE_SWITCH: // ' '
  13483. {
  13484. if (str[10])
  13485. {
  13486. switch (str[11] | 0x20)
  13487. {
  13488. case '1':
  13489. {
  13490. idx += 12;
  13491. return X11_ROSY_BROWN_1;
  13492. }
  13493. case '2':
  13494. {
  13495. idx += 12;
  13496. return X11_ROSY_BROWN_2;
  13497. }
  13498. case '3':
  13499. {
  13500. idx += 12;
  13501. return X11_ROSY_BROWN_3;
  13502. }
  13503. case '4':
  13504. {
  13505. idx += 12;
  13506. return X11_ROSY_BROWN_4;
  13507. }
  13508. }
  13509. }
  13510. }
  13511. case '_' | 0x20:
  13512. {
  13513. switch (str[11] | 0x20)
  13514. {
  13515. case '1':
  13516. {
  13517. idx += 12;
  13518. return X11_ROSY_BROWN_1;
  13519. }
  13520. case '2':
  13521. {
  13522. idx += 12;
  13523. return X11_ROSY_BROWN_2;
  13524. }
  13525. case '3':
  13526. {
  13527. idx += 12;
  13528. return X11_ROSY_BROWN_3;
  13529. }
  13530. case '4':
  13531. {
  13532. idx += 12;
  13533. return X11_ROSY_BROWN_4;
  13534. }
  13535. }
  13536. }
  13537. }
  13538. idx += 10;
  13539. return X11_ROSY_BROWN;
  13540. }
  13541. }
  13542. case '_' | 0x20:
  13543. {
  13544. if (!str[5] || strcmp(str[5], !"BROWN", true, 5))
  13545. {
  13546. return -1;
  13547. }
  13548. switch (str[10] | 0x20)
  13549. {
  13550. case _X11_SPACE_SWITCH: // ' '
  13551. {
  13552. if (str[10])
  13553. {
  13554. switch (str[11] | 0x20)
  13555. {
  13556. case '1':
  13557. {
  13558. idx += 12;
  13559. return X11_ROSY_BROWN_1;
  13560. }
  13561. case '2':
  13562. {
  13563. idx += 12;
  13564. return X11_ROSY_BROWN_2;
  13565. }
  13566. case '3':
  13567. {
  13568. idx += 12;
  13569. return X11_ROSY_BROWN_3;
  13570. }
  13571. case '4':
  13572. {
  13573. idx += 12;
  13574. return X11_ROSY_BROWN_4;
  13575. }
  13576. }
  13577. }
  13578. }
  13579. case '_' | 0x20:
  13580. {
  13581. switch (str[11] | 0x20)
  13582. {
  13583. case '1':
  13584. {
  13585. idx += 12;
  13586. return X11_ROSY_BROWN_1;
  13587. }
  13588. case '2':
  13589. {
  13590. idx += 12;
  13591. return X11_ROSY_BROWN_2;
  13592. }
  13593. case '3':
  13594. {
  13595. idx += 12;
  13596. return X11_ROSY_BROWN_3;
  13597. }
  13598. case '4':
  13599. {
  13600. idx += 12;
  13601. return X11_ROSY_BROWN_4;
  13602. }
  13603. }
  13604. }
  13605. }
  13606. idx += 10;
  13607. return X11_ROSY_BROWN;
  13608. }
  13609. case 'b':
  13610. {
  13611. if (!str[5] || strcmp(str[5], !"ROWN", true, 4))
  13612. {
  13613. return -1;
  13614. }
  13615. switch (str[9] | 0x20)
  13616. {
  13617. case '1':
  13618. {
  13619. idx += 10;
  13620. return X11_ROSYBROWN1;
  13621. }
  13622. case '2':
  13623. {
  13624. idx += 10;
  13625. return X11_ROSYBROWN2;
  13626. }
  13627. case '3':
  13628. {
  13629. idx += 10;
  13630. return X11_ROSYBROWN3;
  13631. }
  13632. case '4':
  13633. {
  13634. idx += 10;
  13635. return X11_ROSYBROWN4;
  13636. }
  13637. }
  13638. idx += 9;
  13639. return X11_ROSYBROWN;
  13640. }
  13641. }
  13642. }
  13643. case 'y':
  13644. {
  13645. if (!str[3] || strcmp(str[3], !"AL", true, 2))
  13646. {
  13647. return -1;
  13648. }
  13649. switch (str[5] | 0x20)
  13650. {
  13651. case _X11_SPACE_SWITCH: // ' '
  13652. {
  13653. if (str[5])
  13654. {
  13655. if (!str[6] || strcmp(str[6], !"BLUE", true, 4))
  13656. {
  13657. return -1;
  13658. }
  13659. switch (str[10] | 0x20)
  13660. {
  13661. case _X11_SPACE_SWITCH: // ' '
  13662. {
  13663. if (str[10])
  13664. {
  13665. switch (str[11] | 0x20)
  13666. {
  13667. case '1':
  13668. {
  13669. idx += 12;
  13670. return X11_ROYAL_BLUE_1;
  13671. }
  13672. case '2':
  13673. {
  13674. idx += 12;
  13675. return X11_ROYAL_BLUE_2;
  13676. }
  13677. case '3':
  13678. {
  13679. idx += 12;
  13680. return X11_ROYAL_BLUE_3;
  13681. }
  13682. case '4':
  13683. {
  13684. idx += 12;
  13685. return X11_ROYAL_BLUE_4;
  13686. }
  13687. }
  13688. }
  13689. }
  13690. case '_' | 0x20:
  13691. {
  13692. switch (str[11] | 0x20)
  13693. {
  13694. case '1':
  13695. {
  13696. idx += 12;
  13697. return X11_ROYAL_BLUE_1;
  13698. }
  13699. case '2':
  13700. {
  13701. idx += 12;
  13702. return X11_ROYAL_BLUE_2;
  13703. }
  13704. case '3':
  13705. {
  13706. idx += 12;
  13707. return X11_ROYAL_BLUE_3;
  13708. }
  13709. case '4':
  13710. {
  13711. idx += 12;
  13712. return X11_ROYAL_BLUE_4;
  13713. }
  13714. }
  13715. }
  13716. }
  13717. idx += 10;
  13718. return X11_ROYAL_BLUE;
  13719. }
  13720. }
  13721. case '_' | 0x20:
  13722. {
  13723. if (!str[6] || strcmp(str[6], !"BLUE", true, 4))
  13724. {
  13725. return -1;
  13726. }
  13727. switch (str[10] | 0x20)
  13728. {
  13729. case _X11_SPACE_SWITCH: // ' '
  13730. {
  13731. if (str[10])
  13732. {
  13733. switch (str[11] | 0x20)
  13734. {
  13735. case '1':
  13736. {
  13737. idx += 12;
  13738. return X11_ROYAL_BLUE_1;
  13739. }
  13740. case '2':
  13741. {
  13742. idx += 12;
  13743. return X11_ROYAL_BLUE_2;
  13744. }
  13745. case '3':
  13746. {
  13747. idx += 12;
  13748. return X11_ROYAL_BLUE_3;
  13749. }
  13750. case '4':
  13751. {
  13752. idx += 12;
  13753. return X11_ROYAL_BLUE_4;
  13754. }
  13755. }
  13756. }
  13757. }
  13758. case '_' | 0x20:
  13759. {
  13760. switch (str[11] | 0x20)
  13761. {
  13762. case '1':
  13763. {
  13764. idx += 12;
  13765. return X11_ROYAL_BLUE_1;
  13766. }
  13767. case '2':
  13768. {
  13769. idx += 12;
  13770. return X11_ROYAL_BLUE_2;
  13771. }
  13772. case '3':
  13773. {
  13774. idx += 12;
  13775. return X11_ROYAL_BLUE_3;
  13776. }
  13777. case '4':
  13778. {
  13779. idx += 12;
  13780. return X11_ROYAL_BLUE_4;
  13781. }
  13782. }
  13783. }
  13784. }
  13785. idx += 10;
  13786. return X11_ROYAL_BLUE;
  13787. }
  13788. case 'b':
  13789. {
  13790. if (!str[6] || strcmp(str[6], !"LUE", true, 3))
  13791. {
  13792. return -1;
  13793. }
  13794. switch (str[9] | 0x20)
  13795. {
  13796. case '1':
  13797. {
  13798. idx += 10;
  13799. return X11_ROYALBLUE1;
  13800. }
  13801. case '2':
  13802. {
  13803. idx += 10;
  13804. return X11_ROYALBLUE2;
  13805. }
  13806. case '3':
  13807. {
  13808. idx += 10;
  13809. return X11_ROYALBLUE3;
  13810. }
  13811. case '4':
  13812. {
  13813. idx += 10;
  13814. return X11_ROYALBLUE4;
  13815. }
  13816. }
  13817. idx += 9;
  13818. return X11_ROYALBLUE;
  13819. }
  13820. }
  13821. }
  13822. }
  13823. }
  13824. }
  13825. }
  13826. case 's':
  13827. {
  13828. switch (str[1] | 0x20)
  13829. {
  13830. case 'a':
  13831. {
  13832. switch (str[2] | 0x20)
  13833. {
  13834. case 'd':
  13835. {
  13836. if (!str[3] || strcmp(str[3], !"DLE", true, 3))
  13837. {
  13838. return -1;
  13839. }
  13840. switch (str[6] | 0x20)
  13841. {
  13842. case _X11_SPACE_SWITCH: // ' '
  13843. {
  13844. if (str[6])
  13845. {
  13846. if (str[7] && !strcmp(str[7], !"BROWN", true, 5))
  13847. {
  13848. idx += 12;
  13849. return X11_SADDLE_BROWN;
  13850. }
  13851. }
  13852. }
  13853. case '_' | 0x20:
  13854. {
  13855. if (str[7] && !strcmp(str[7], !"BROWN", true, 5))
  13856. {
  13857. idx += 12;
  13858. return X11_SADDLE_BROWN;
  13859. }
  13860. }
  13861. case 'b':
  13862. {
  13863. if (str[7] && !strcmp(str[7], !"ROWN", true, 4))
  13864. {
  13865. idx += 11;
  13866. return X11_SADDLEBROWN;
  13867. }
  13868. }
  13869. }
  13870. }
  13871. case 'l':
  13872. {
  13873. if (!str[3] || strcmp(str[3], !"MON", true, 3))
  13874. {
  13875. return -1;
  13876. }
  13877. switch (str[6] | 0x20)
  13878. {
  13879. case _X11_SPACE_SWITCH: // ' '
  13880. {
  13881. if (str[6])
  13882. {
  13883. switch (str[7] | 0x20)
  13884. {
  13885. case '1':
  13886. {
  13887. idx += 8;
  13888. return X11_SALMON_1;
  13889. }
  13890. case '2':
  13891. {
  13892. idx += 8;
  13893. return X11_SALMON_2;
  13894. }
  13895. case '3':
  13896. {
  13897. idx += 8;
  13898. return X11_SALMON_3;
  13899. }
  13900. case '4':
  13901. {
  13902. idx += 8;
  13903. return X11_SALMON_4;
  13904. }
  13905. }
  13906. }
  13907. }
  13908. case '_' | 0x20:
  13909. {
  13910. switch (str[7] | 0x20)
  13911. {
  13912. case '1':
  13913. {
  13914. idx += 8;
  13915. return X11_SALMON_1;
  13916. }
  13917. case '2':
  13918. {
  13919. idx += 8;
  13920. return X11_SALMON_2;
  13921. }
  13922. case '3':
  13923. {
  13924. idx += 8;
  13925. return X11_SALMON_3;
  13926. }
  13927. case '4':
  13928. {
  13929. idx += 8;
  13930. return X11_SALMON_4;
  13931. }
  13932. }
  13933. }
  13934. case '1':
  13935. {
  13936. idx += 7;
  13937. return X11_SALMON1;
  13938. }
  13939. case '2':
  13940. {
  13941. idx += 7;
  13942. return X11_SALMON2;
  13943. }
  13944. case '3':
  13945. {
  13946. idx += 7;
  13947. return X11_SALMON3;
  13948. }
  13949. case '4':
  13950. {
  13951. idx += 7;
  13952. return X11_SALMON4;
  13953. }
  13954. }
  13955. idx += 6;
  13956. return X11_SALMON;
  13957. }
  13958. case 'n':
  13959. {
  13960. if (!str[3] || strcmp(str[3], !"DY", true, 2))
  13961. {
  13962. return -1;
  13963. }
  13964. switch (str[5] | 0x20)
  13965. {
  13966. case _X11_SPACE_SWITCH: // ' '
  13967. {
  13968. if (str[5])
  13969. {
  13970. if (str[6] && !strcmp(str[6], !"BROWN", true, 5))
  13971. {
  13972. idx += 11;
  13973. return X11_SANDY_BROWN;
  13974. }
  13975. }
  13976. }
  13977. case '_' | 0x20:
  13978. {
  13979. if (str[6] && !strcmp(str[6], !"BROWN", true, 5))
  13980. {
  13981. idx += 11;
  13982. return X11_SANDY_BROWN;
  13983. }
  13984. }
  13985. case 'b':
  13986. {
  13987. if (str[6] && !strcmp(str[6], !"ROWN", true, 4))
  13988. {
  13989. idx += 10;
  13990. return X11_SANDYBROWN;
  13991. }
  13992. }
  13993. }
  13994. }
  13995. }
  13996. }
  13997. case 'e':
  13998. {
  13999. if (str[2] | 0x20 != 'a')
  14000. {
  14001. return -1;
  14002. }
  14003. switch (str[3] | 0x20)
  14004. {
  14005. case _X11_SPACE_SWITCH: // ' '
  14006. {
  14007. if (str[3])
  14008. {
  14009. if (!str[4] || strcmp(str[4], !"GREEN", true, 5))
  14010. {
  14011. return -1;
  14012. }
  14013. switch (str[9] | 0x20)
  14014. {
  14015. case _X11_SPACE_SWITCH: // ' '
  14016. {
  14017. if (str[9])
  14018. {
  14019. switch (str[10] | 0x20)
  14020. {
  14021. case '1':
  14022. {
  14023. idx += 11;
  14024. return X11_SEA_GREEN_1;
  14025. }
  14026. case '2':
  14027. {
  14028. idx += 11;
  14029. return X11_SEA_GREEN_2;
  14030. }
  14031. case '3':
  14032. {
  14033. idx += 11;
  14034. return X11_SEA_GREEN_3;
  14035. }
  14036. case '4':
  14037. {
  14038. idx += 11;
  14039. return X11_SEA_GREEN_4;
  14040. }
  14041. }
  14042. }
  14043. }
  14044. case '_' | 0x20:
  14045. {
  14046. switch (str[10] | 0x20)
  14047. {
  14048. case '1':
  14049. {
  14050. idx += 11;
  14051. return X11_SEA_GREEN_1;
  14052. }
  14053. case '2':
  14054. {
  14055. idx += 11;
  14056. return X11_SEA_GREEN_2;
  14057. }
  14058. case '3':
  14059. {
  14060. idx += 11;
  14061. return X11_SEA_GREEN_3;
  14062. }
  14063. case '4':
  14064. {
  14065. idx += 11;
  14066. return X11_SEA_GREEN_4;
  14067. }
  14068. }
  14069. }
  14070. }
  14071. idx += 9;
  14072. return X11_SEA_GREEN;
  14073. }
  14074. }
  14075. case '_' | 0x20:
  14076. {
  14077. if (!str[4] || strcmp(str[4], !"GREEN", true, 5))
  14078. {
  14079. return -1;
  14080. }
  14081. switch (str[9] | 0x20)
  14082. {
  14083. case _X11_SPACE_SWITCH: // ' '
  14084. {
  14085. if (str[9])
  14086. {
  14087. switch (str[10] | 0x20)
  14088. {
  14089. case '1':
  14090. {
  14091. idx += 11;
  14092. return X11_SEA_GREEN_1;
  14093. }
  14094. case '2':
  14095. {
  14096. idx += 11;
  14097. return X11_SEA_GREEN_2;
  14098. }
  14099. case '3':
  14100. {
  14101. idx += 11;
  14102. return X11_SEA_GREEN_3;
  14103. }
  14104. case '4':
  14105. {
  14106. idx += 11;
  14107. return X11_SEA_GREEN_4;
  14108. }
  14109. }
  14110. }
  14111. }
  14112. case '_' | 0x20:
  14113. {
  14114. switch (str[10] | 0x20)
  14115. {
  14116. case '1':
  14117. {
  14118. idx += 11;
  14119. return X11_SEA_GREEN_1;
  14120. }
  14121. case '2':
  14122. {
  14123. idx += 11;
  14124. return X11_SEA_GREEN_2;
  14125. }
  14126. case '3':
  14127. {
  14128. idx += 11;
  14129. return X11_SEA_GREEN_3;
  14130. }
  14131. case '4':
  14132. {
  14133. idx += 11;
  14134. return X11_SEA_GREEN_4;
  14135. }
  14136. }
  14137. }
  14138. }
  14139. idx += 9;
  14140. return X11_SEA_GREEN;
  14141. }
  14142. case 'g':
  14143. {
  14144. if (!str[4] || strcmp(str[4], !"REEN", true, 4))
  14145. {
  14146. return -1;
  14147. }
  14148. switch (str[8] | 0x20)
  14149. {
  14150. case '1':
  14151. {
  14152. idx += 9;
  14153. return X11_SEAGREEN1;
  14154. }
  14155. case '2':
  14156. {
  14157. idx += 9;
  14158. return X11_SEAGREEN2;
  14159. }
  14160. case '3':
  14161. {
  14162. idx += 9;
  14163. return X11_SEAGREEN3;
  14164. }
  14165. case '4':
  14166. {
  14167. idx += 9;
  14168. return X11_SEAGREEN4;
  14169. }
  14170. }
  14171. idx += 8;
  14172. return X11_SEAGREEN;
  14173. }
  14174. case 's':
  14175. {
  14176. if (!str[4] || strcmp(str[4], !"HELL", true, 4))
  14177. {
  14178. return -1;
  14179. }
  14180. switch (str[8] | 0x20)
  14181. {
  14182. case _X11_SPACE_SWITCH: // ' '
  14183. {
  14184. if (str[8])
  14185. {
  14186. switch (str[9] | 0x20)
  14187. {
  14188. case '1':
  14189. {
  14190. idx += 10;
  14191. return X11_SEASHELL_1;
  14192. }
  14193. case '2':
  14194. {
  14195. idx += 10;
  14196. return X11_SEASHELL_2;
  14197. }
  14198. case '3':
  14199. {
  14200. idx += 10;
  14201. return X11_SEASHELL_3;
  14202. }
  14203. case '4':
  14204. {
  14205. idx += 10;
  14206. return X11_SEASHELL_4;
  14207. }
  14208. }
  14209. }
  14210. }
  14211. case '_' | 0x20:
  14212. {
  14213. switch (str[9] | 0x20)
  14214. {
  14215. case '1':
  14216. {
  14217. idx += 10;
  14218. return X11_SEASHELL_1;
  14219. }
  14220. case '2':
  14221. {
  14222. idx += 10;
  14223. return X11_SEASHELL_2;
  14224. }
  14225. case '3':
  14226. {
  14227. idx += 10;
  14228. return X11_SEASHELL_3;
  14229. }
  14230. case '4':
  14231. {
  14232. idx += 10;
  14233. return X11_SEASHELL_4;
  14234. }
  14235. }
  14236. }
  14237. case '1':
  14238. {
  14239. idx += 9;
  14240. return X11_SEASHELL1;
  14241. }
  14242. case '2':
  14243. {
  14244. idx += 9;
  14245. return X11_SEASHELL2;
  14246. }
  14247. case '3':
  14248. {
  14249. idx += 9;
  14250. return X11_SEASHELL3;
  14251. }
  14252. case '4':
  14253. {
  14254. idx += 9;
  14255. return X11_SEASHELL4;
  14256. }
  14257. }
  14258. idx += 8;
  14259. return X11_SEASHELL;
  14260. }
  14261. }
  14262. }
  14263. case 'i':
  14264. {
  14265. if (!str[2] || strcmp(str[2], !"ENNA", true, 4))
  14266. {
  14267. return -1;
  14268. }
  14269. switch (str[6] | 0x20)
  14270. {
  14271. case _X11_SPACE_SWITCH: // ' '
  14272. {
  14273. if (str[6])
  14274. {
  14275. switch (str[7] | 0x20)
  14276. {
  14277. case '1':
  14278. {
  14279. idx += 8;
  14280. return X11_SIENNA_1;
  14281. }
  14282. case '2':
  14283. {
  14284. idx += 8;
  14285. return X11_SIENNA_2;
  14286. }
  14287. case '3':
  14288. {
  14289. idx += 8;
  14290. return X11_SIENNA_3;
  14291. }
  14292. case '4':
  14293. {
  14294. idx += 8;
  14295. return X11_SIENNA_4;
  14296. }
  14297. }
  14298. }
  14299. }
  14300. case '_' | 0x20:
  14301. {
  14302. switch (str[7] | 0x20)
  14303. {
  14304. case '1':
  14305. {
  14306. idx += 8;
  14307. return X11_SIENNA_1;
  14308. }
  14309. case '2':
  14310. {
  14311. idx += 8;
  14312. return X11_SIENNA_2;
  14313. }
  14314. case '3':
  14315. {
  14316. idx += 8;
  14317. return X11_SIENNA_3;
  14318. }
  14319. case '4':
  14320. {
  14321. idx += 8;
  14322. return X11_SIENNA_4;
  14323. }
  14324. }
  14325. }
  14326. case '1':
  14327. {
  14328. idx += 7;
  14329. return X11_SIENNA1;
  14330. }
  14331. case '2':
  14332. {
  14333. idx += 7;
  14334. return X11_SIENNA2;
  14335. }
  14336. case '3':
  14337. {
  14338. idx += 7;
  14339. return X11_SIENNA3;
  14340. }
  14341. case '4':
  14342. {
  14343. idx += 7;
  14344. return X11_SIENNA4;
  14345. }
  14346. }
  14347. idx += 6;
  14348. return X11_SIENNA;
  14349. }
  14350. case 'k':
  14351. {
  14352. if (str[2] | 0x20 != 'y')
  14353. {
  14354. return -1;
  14355. }
  14356. switch (str[3] | 0x20)
  14357. {
  14358. case _X11_SPACE_SWITCH: // ' '
  14359. {
  14360. if (str[3])
  14361. {
  14362. if (!str[4] || strcmp(str[4], !"BLUE", true, 4))
  14363. {
  14364. return -1;
  14365. }
  14366. switch (str[8] | 0x20)
  14367. {
  14368. case _X11_SPACE_SWITCH: // ' '
  14369. {
  14370. if (str[8])
  14371. {
  14372. switch (str[9] | 0x20)
  14373. {
  14374. case '1':
  14375. {
  14376. idx += 10;
  14377. return X11_SKY_BLUE_1;
  14378. }
  14379. case '2':
  14380. {
  14381. idx += 10;
  14382. return X11_SKY_BLUE_2;
  14383. }
  14384. case '3':
  14385. {
  14386. idx += 10;
  14387. return X11_SKY_BLUE_3;
  14388. }
  14389. case '4':
  14390. {
  14391. idx += 10;
  14392. return X11_SKY_BLUE_4;
  14393. }
  14394. }
  14395. }
  14396. }
  14397. case '_' | 0x20:
  14398. {
  14399. switch (str[9] | 0x20)
  14400. {
  14401. case '1':
  14402. {
  14403. idx += 10;
  14404. return X11_SKY_BLUE_1;
  14405. }
  14406. case '2':
  14407. {
  14408. idx += 10;
  14409. return X11_SKY_BLUE_2;
  14410. }
  14411. case '3':
  14412. {
  14413. idx += 10;
  14414. return X11_SKY_BLUE_3;
  14415. }
  14416. case '4':
  14417. {
  14418. idx += 10;
  14419. return X11_SKY_BLUE_4;
  14420. }
  14421. }
  14422. }
  14423. }
  14424. idx += 8;
  14425. return X11_SKY_BLUE;
  14426. }
  14427. }
  14428. case '_' | 0x20:
  14429. {
  14430. if (!str[4] || strcmp(str[4], !"BLUE", true, 4))
  14431. {
  14432. return -1;
  14433. }
  14434. switch (str[8] | 0x20)
  14435. {
  14436. case _X11_SPACE_SWITCH: // ' '
  14437. {
  14438. if (str[8])
  14439. {
  14440. switch (str[9] | 0x20)
  14441. {
  14442. case '1':
  14443. {
  14444. idx += 10;
  14445. return X11_SKY_BLUE_1;
  14446. }
  14447. case '2':
  14448. {
  14449. idx += 10;
  14450. return X11_SKY_BLUE_2;
  14451. }
  14452. case '3':
  14453. {
  14454. idx += 10;
  14455. return X11_SKY_BLUE_3;
  14456. }
  14457. case '4':
  14458. {
  14459. idx += 10;
  14460. return X11_SKY_BLUE_4;
  14461. }
  14462. }
  14463. }
  14464. }
  14465. case '_' | 0x20:
  14466. {
  14467. switch (str[9] | 0x20)
  14468. {
  14469. case '1':
  14470. {
  14471. idx += 10;
  14472. return X11_SKY_BLUE_1;
  14473. }
  14474. case '2':
  14475. {
  14476. idx += 10;
  14477. return X11_SKY_BLUE_2;
  14478. }
  14479. case '3':
  14480. {
  14481. idx += 10;
  14482. return X11_SKY_BLUE_3;
  14483. }
  14484. case '4':
  14485. {
  14486. idx += 10;
  14487. return X11_SKY_BLUE_4;
  14488. }
  14489. }
  14490. }
  14491. }
  14492. idx += 8;
  14493. return X11_SKY_BLUE;
  14494. }
  14495. case 'b':
  14496. {
  14497. if (!str[4] || strcmp(str[4], !"LUE", true, 3))
  14498. {
  14499. return -1;
  14500. }
  14501. switch (str[7] | 0x20)
  14502. {
  14503. case '1':
  14504. {
  14505. idx += 8;
  14506. return X11_SKYBLUE1;
  14507. }
  14508. case '2':
  14509. {
  14510. idx += 8;
  14511. return X11_SKYBLUE2;
  14512. }
  14513. case '3':
  14514. {
  14515. idx += 8;
  14516. return X11_SKYBLUE3;
  14517. }
  14518. case '4':
  14519. {
  14520. idx += 8;
  14521. return X11_SKYBLUE4;
  14522. }
  14523. }
  14524. idx += 7;
  14525. return X11_SKYBLUE;
  14526. }
  14527. }
  14528. }
  14529. case 'l':
  14530. {
  14531. if (!str[2] || strcmp(str[2], !"ATE", true, 3))
  14532. {
  14533. return -1;
  14534. }
  14535. switch (str[5] | 0x20)
  14536. {
  14537. case _X11_SPACE_SWITCH: // ' '
  14538. {
  14539. if (str[5])
  14540. {
  14541. switch (str[6] | 0x20)
  14542. {
  14543. case 'b':
  14544. {
  14545. if (!str[7] || strcmp(str[7], !"LUE", true, 3))
  14546. {
  14547. return -1;
  14548. }
  14549. switch (str[10] | 0x20)
  14550. {
  14551. case _X11_SPACE_SWITCH: // ' '
  14552. {
  14553. if (str[10])
  14554. {
  14555. switch (str[11] | 0x20)
  14556. {
  14557. case '1':
  14558. {
  14559. idx += 12;
  14560. return X11_SLATE_BLUE_1;
  14561. }
  14562. case '2':
  14563. {
  14564. idx += 12;
  14565. return X11_SLATE_BLUE_2;
  14566. }
  14567. case '3':
  14568. {
  14569. idx += 12;
  14570. return X11_SLATE_BLUE_3;
  14571. }
  14572. case '4':
  14573. {
  14574. idx += 12;
  14575. return X11_SLATE_BLUE_4;
  14576. }
  14577. }
  14578. }
  14579. }
  14580. case '_' | 0x20:
  14581. {
  14582. switch (str[11] | 0x20)
  14583. {
  14584. case '1':
  14585. {
  14586. idx += 12;
  14587. return X11_SLATE_BLUE_1;
  14588. }
  14589. case '2':
  14590. {
  14591. idx += 12;
  14592. return X11_SLATE_BLUE_2;
  14593. }
  14594. case '3':
  14595. {
  14596. idx += 12;
  14597. return X11_SLATE_BLUE_3;
  14598. }
  14599. case '4':
  14600. {
  14601. idx += 12;
  14602. return X11_SLATE_BLUE_4;
  14603. }
  14604. }
  14605. }
  14606. }
  14607. idx += 10;
  14608. return X11_SLATE_BLUE;
  14609. }
  14610. case 'g':
  14611. {
  14612. if (str[7] | 0x20 != 'r')
  14613. {
  14614. return -1;
  14615. }
  14616. switch (str[8] | 0x20)
  14617. {
  14618. case 'a':
  14619. {
  14620. if (str[9] | 0x20 != 'y')
  14621. {
  14622. return -1;
  14623. }
  14624. switch (str[10] | 0x20)
  14625. {
  14626. case _X11_SPACE_SWITCH: // ' '
  14627. {
  14628. if (str[10])
  14629. {
  14630. switch (str[11] | 0x20)
  14631. {
  14632. case '1':
  14633. {
  14634. idx += 12;
  14635. return X11_SLATE_GRAY_1;
  14636. }
  14637. case '2':
  14638. {
  14639. idx += 12;
  14640. return X11_SLATE_GRAY_2;
  14641. }
  14642. case '3':
  14643. {
  14644. idx += 12;
  14645. return X11_SLATE_GRAY_3;
  14646. }
  14647. case '4':
  14648. {
  14649. idx += 12;
  14650. return X11_SLATE_GRAY_4;
  14651. }
  14652. }
  14653. }
  14654. }
  14655. case '_' | 0x20:
  14656. {
  14657. switch (str[11] | 0x20)
  14658. {
  14659. case '1':
  14660. {
  14661. idx += 12;
  14662. return X11_SLATE_GRAY_1;
  14663. }
  14664. case '2':
  14665. {
  14666. idx += 12;
  14667. return X11_SLATE_GRAY_2;
  14668. }
  14669. case '3':
  14670. {
  14671. idx += 12;
  14672. return X11_SLATE_GRAY_3;
  14673. }
  14674. case '4':
  14675. {
  14676. idx += 12;
  14677. return X11_SLATE_GRAY_4;
  14678. }
  14679. }
  14680. }
  14681. }
  14682. idx += 10;
  14683. return X11_SLATE_GRAY;
  14684. }
  14685. case 'e':
  14686. {
  14687. if (str[9] | 0x20 != 'y')
  14688. {
  14689. return -1;
  14690. }
  14691. switch (str[10] | 0x20)
  14692. {
  14693. case _X11_SPACE_SWITCH: // ' '
  14694. {
  14695. if (str[10])
  14696. {
  14697. switch (str[11] | 0x20)
  14698. {
  14699. case '1':
  14700. {
  14701. idx += 12;
  14702. return X11_SLATE_GREY_1;
  14703. }
  14704. case '2':
  14705. {
  14706. idx += 12;
  14707. return X11_SLATE_GREY_2;
  14708. }
  14709. case '3':
  14710. {
  14711. idx += 12;
  14712. return X11_SLATE_GREY_3;
  14713. }
  14714. case '4':
  14715. {
  14716. idx += 12;
  14717. return X11_SLATE_GREY_4;
  14718. }
  14719. }
  14720. }
  14721. }
  14722. case '_' | 0x20:
  14723. {
  14724. switch (str[11] | 0x20)
  14725. {
  14726. case '1':
  14727. {
  14728. idx += 12;
  14729. return X11_SLATE_GREY_1;
  14730. }
  14731. case '2':
  14732. {
  14733. idx += 12;
  14734. return X11_SLATE_GREY_2;
  14735. }
  14736. case '3':
  14737. {
  14738. idx += 12;
  14739. return X11_SLATE_GREY_3;
  14740. }
  14741. case '4':
  14742. {
  14743. idx += 12;
  14744. return X11_SLATE_GREY_4;
  14745. }
  14746. }
  14747. }
  14748. }
  14749. idx += 10;
  14750. return X11_SLATE_GREY;
  14751. }
  14752. }
  14753. }
  14754. }
  14755. }
  14756. }
  14757. case '_' | 0x20:
  14758. {
  14759. switch (str[6] | 0x20)
  14760. {
  14761. case 'b':
  14762. {
  14763. if (!str[7] || strcmp(str[7], !"LUE", true, 3))
  14764. {
  14765. return -1;
  14766. }
  14767. switch (str[10] | 0x20)
  14768. {
  14769. case _X11_SPACE_SWITCH: // ' '
  14770. {
  14771. if (str[10])
  14772. {
  14773. switch (str[11] | 0x20)
  14774. {
  14775. case '1':
  14776. {
  14777. idx += 12;
  14778. return X11_SLATE_BLUE_1;
  14779. }
  14780. case '2':
  14781. {
  14782. idx += 12;
  14783. return X11_SLATE_BLUE_2;
  14784. }
  14785. case '3':
  14786. {
  14787. idx += 12;
  14788. return X11_SLATE_BLUE_3;
  14789. }
  14790. case '4':
  14791. {
  14792. idx += 12;
  14793. return X11_SLATE_BLUE_4;
  14794. }
  14795. }
  14796. }
  14797. }
  14798. case '_' | 0x20:
  14799. {
  14800. switch (str[11] | 0x20)
  14801. {
  14802. case '1':
  14803. {
  14804. idx += 12;
  14805. return X11_SLATE_BLUE_1;
  14806. }
  14807. case '2':
  14808. {
  14809. idx += 12;
  14810. return X11_SLATE_BLUE_2;
  14811. }
  14812. case '3':
  14813. {
  14814. idx += 12;
  14815. return X11_SLATE_BLUE_3;
  14816. }
  14817. case '4':
  14818. {
  14819. idx += 12;
  14820. return X11_SLATE_BLUE_4;
  14821. }
  14822. }
  14823. }
  14824. }
  14825. idx += 10;
  14826. return X11_SLATE_BLUE;
  14827. }
  14828. case 'g':
  14829. {
  14830. if (str[7] | 0x20 != 'r')
  14831. {
  14832. return -1;
  14833. }
  14834. switch (str[8] | 0x20)
  14835. {
  14836. case 'a':
  14837. {
  14838. if (str[9] | 0x20 != 'y')
  14839. {
  14840. return -1;
  14841. }
  14842. switch (str[10] | 0x20)
  14843. {
  14844. case _X11_SPACE_SWITCH: // ' '
  14845. {
  14846. if (str[10])
  14847. {
  14848. switch (str[11] | 0x20)
  14849. {
  14850. case '1':
  14851. {
  14852. idx += 12;
  14853. return X11_SLATE_GRAY_1;
  14854. }
  14855. case '2':
  14856. {
  14857. idx += 12;
  14858. return X11_SLATE_GRAY_2;
  14859. }
  14860. case '3':
  14861. {
  14862. idx += 12;
  14863. return X11_SLATE_GRAY_3;
  14864. }
  14865. case '4':
  14866. {
  14867. idx += 12;
  14868. return X11_SLATE_GRAY_4;
  14869. }
  14870. }
  14871. }
  14872. }
  14873. case '_' | 0x20:
  14874. {
  14875. switch (str[11] | 0x20)
  14876. {
  14877. case '1':
  14878. {
  14879. idx += 12;
  14880. return X11_SLATE_GRAY_1;
  14881. }
  14882. case '2':
  14883. {
  14884. idx += 12;
  14885. return X11_SLATE_GRAY_2;
  14886. }
  14887. case '3':
  14888. {
  14889. idx += 12;
  14890. return X11_SLATE_GRAY_3;
  14891. }
  14892. case '4':
  14893. {
  14894. idx += 12;
  14895. return X11_SLATE_GRAY_4;
  14896. }
  14897. }
  14898. }
  14899. }
  14900. idx += 10;
  14901. return X11_SLATE_GRAY;
  14902. }
  14903. case 'e':
  14904. {
  14905. if (str[9] | 0x20 != 'y')
  14906. {
  14907. return -1;
  14908. }
  14909. switch (str[10] | 0x20)
  14910. {
  14911. case _X11_SPACE_SWITCH: // ' '
  14912. {
  14913. if (str[10])
  14914. {
  14915. switch (str[11] | 0x20)
  14916. {
  14917. case '1':
  14918. {
  14919. idx += 12;
  14920. return X11_SLATE_GREY_1;
  14921. }
  14922. case '2':
  14923. {
  14924. idx += 12;
  14925. return X11_SLATE_GREY_2;
  14926. }
  14927. case '3':
  14928. {
  14929. idx += 12;
  14930. return X11_SLATE_GREY_3;
  14931. }
  14932. case '4':
  14933. {
  14934. idx += 12;
  14935. return X11_SLATE_GREY_4;
  14936. }
  14937. }
  14938. }
  14939. }
  14940. case '_' | 0x20:
  14941. {
  14942. switch (str[11] | 0x20)
  14943. {
  14944. case '1':
  14945. {
  14946. idx += 12;
  14947. return X11_SLATE_GREY_1;
  14948. }
  14949. case '2':
  14950. {
  14951. idx += 12;
  14952. return X11_SLATE_GREY_2;
  14953. }
  14954. case '3':
  14955. {
  14956. idx += 12;
  14957. return X11_SLATE_GREY_3;
  14958. }
  14959. case '4':
  14960. {
  14961. idx += 12;
  14962. return X11_SLATE_GREY_4;
  14963. }
  14964. }
  14965. }
  14966. }
  14967. idx += 10;
  14968. return X11_SLATE_GRAY;
  14969. }
  14970. }
  14971. }
  14972. }
  14973. }
  14974. case 'b':
  14975. {
  14976. if (!str[6] || strcmp(str[6], !"LUE", true, 3))
  14977. {
  14978. return -1;
  14979. }
  14980. switch (str[9] | 0x20)
  14981. {
  14982. case '1':
  14983. {
  14984. idx += 10;
  14985. return X11_SLATEBLUE1;
  14986. }
  14987. case '2':
  14988. {
  14989. idx += 10;
  14990. return X11_SLATEBLUE2;
  14991. }
  14992. case '3':
  14993. {
  14994. idx += 10;
  14995. return X11_SLATEBLUE3;
  14996. }
  14997. case '4':
  14998. {
  14999. idx += 10;
  15000. return X11_SLATEBLUE4;
  15001. }
  15002. }
  15003. idx += 9;
  15004. return X11_SLATEBLUE;
  15005. }
  15006. case 'g':
  15007. {
  15008. if (str[6] | 0x20 != 'r')
  15009. {
  15010. return -1;
  15011. }
  15012. switch (str[7] | 0x20)
  15013. {
  15014. case 'a':
  15015. {
  15016. if (str[8] | 0x20 != 'y')
  15017. {
  15018. return -1;
  15019. }
  15020. switch (str[9] | 0x20)
  15021. {
  15022. case '1':
  15023. {
  15024. idx += 10;
  15025. return X11_SLATEGRAY1;
  15026. }
  15027. case '2':
  15028. {
  15029. idx += 10;
  15030. return X11_SLATEGRAY2;
  15031. }
  15032. case '3':
  15033. {
  15034. idx += 10;
  15035. return X11_SLATEGRAY3;
  15036. }
  15037. case '4':
  15038. {
  15039. idx += 10;
  15040. return X11_SLATEGRAY4;
  15041. }
  15042. }
  15043. idx += 9;
  15044. return X11_SLATEGRAY;
  15045. }
  15046. case 'e':
  15047. {
  15048. if (str[8] | 0x20 != 'y')
  15049. {
  15050. return -1;
  15051. }
  15052. switch (str[9] | 0x20)
  15053. {
  15054. case '1':
  15055. {
  15056. idx += 10;
  15057. return X11_SLATEGREY1;
  15058. }
  15059. case '2':
  15060. {
  15061. idx += 10;
  15062. return X11_SLATEGREY2;
  15063. }
  15064. case '3':
  15065. {
  15066. idx += 10;
  15067. return X11_SLATEGREY3;
  15068. }
  15069. case '4':
  15070. {
  15071. idx += 10;
  15072. return X11_SLATEGREY4;
  15073. }
  15074. }
  15075. idx += 9;
  15076. return X11_SLATEGREY;
  15077. }
  15078. }
  15079. }
  15080. }
  15081. }
  15082. case 'n':
  15083. {
  15084. if (!str[2] || strcmp(str[2], !"OW", true, 2))
  15085. {
  15086. return -1;
  15087. }
  15088. switch (str[4] | 0x20)
  15089. {
  15090. case _X11_SPACE_SWITCH: // ' '
  15091. {
  15092. if (str[4])
  15093. {
  15094. switch (str[5] | 0x20)
  15095. {
  15096. case '1':
  15097. {
  15098. idx += 6;
  15099. return X11_SNOW_1;
  15100. }
  15101. case '2':
  15102. {
  15103. idx += 6;
  15104. return X11_SNOW_2;
  15105. }
  15106. case '3':
  15107. {
  15108. idx += 6;
  15109. return X11_SNOW_3;
  15110. }
  15111. case '4':
  15112. {
  15113. idx += 6;
  15114. return X11_SNOW_4;
  15115. }
  15116. }
  15117. }
  15118. }
  15119. case '_' | 0x20:
  15120. {
  15121. switch (str[5] | 0x20)
  15122. {
  15123. case '1':
  15124. {
  15125. idx += 6;
  15126. return X11_SNOW_1;
  15127. }
  15128. case '2':
  15129. {
  15130. idx += 6;
  15131. return X11_SNOW_2;
  15132. }
  15133. case '3':
  15134. {
  15135. idx += 6;
  15136. return X11_SNOW_3;
  15137. }
  15138. case '4':
  15139. {
  15140. idx += 6;
  15141. return X11_SNOW_4;
  15142. }
  15143. }
  15144. }
  15145. case '1':
  15146. {
  15147. idx += 5;
  15148. return X11_SNOW1;
  15149. }
  15150. case '2':
  15151. {
  15152. idx += 5;
  15153. return X11_SNOW2;
  15154. }
  15155. case '3':
  15156. {
  15157. idx += 5;
  15158. return X11_SNOW3;
  15159. }
  15160. case '4':
  15161. {
  15162. idx += 5;
  15163. return X11_SNOW4;
  15164. }
  15165. }
  15166. idx += 4;
  15167. return X11_SNOW;
  15168. }
  15169. case 'p':
  15170. {
  15171. if (!str[2] || strcmp(str[2], !"RING", true, 4))
  15172. {
  15173. return -1;
  15174. }
  15175. switch (str[6] | 0x20)
  15176. {
  15177. case _X11_SPACE_SWITCH: // ' '
  15178. {
  15179. if (str[6])
  15180. {
  15181. if (!str[7] || strcmp(str[7], !"GREEN", true, 5))
  15182. {
  15183. return -1;
  15184. }
  15185. switch (str[12] | 0x20)
  15186. {
  15187. case _X11_SPACE_SWITCH: // ' '
  15188. {
  15189. if (str[12])
  15190. {
  15191. switch (str[13] | 0x20)
  15192. {
  15193. case '1':
  15194. {
  15195. idx += 14;
  15196. return X11_SPRING_GREEN_1;
  15197. }
  15198. case '2':
  15199. {
  15200. idx += 14;
  15201. return X11_SPRING_GREEN_2;
  15202. }
  15203. case '3':
  15204. {
  15205. idx += 14;
  15206. return X11_SPRING_GREEN_3;
  15207. }
  15208. case '4':
  15209. {
  15210. idx += 14;
  15211. return X11_SPRING_GREEN_4;
  15212. }
  15213. }
  15214. }
  15215. }
  15216. case '_' | 0x20:
  15217. {
  15218. switch (str[13] | 0x20)
  15219. {
  15220. case '1':
  15221. {
  15222. idx += 14;
  15223. return X11_SPRING_GREEN_1;
  15224. }
  15225. case '2':
  15226. {
  15227. idx += 14;
  15228. return X11_SPRING_GREEN_2;
  15229. }
  15230. case '3':
  15231. {
  15232. idx += 14;
  15233. return X11_SPRING_GREEN_3;
  15234. }
  15235. case '4':
  15236. {
  15237. idx += 14;
  15238. return X11_SPRING_GREEN_4;
  15239. }
  15240. }
  15241. }
  15242. }
  15243. idx += 12;
  15244. return X11_SPRING_GREEN;
  15245. }
  15246. }
  15247. case '_' | 0x20:
  15248. {
  15249. if (!str[7] || strcmp(str[7], !"GREEN", true, 5))
  15250. {
  15251. return -1;
  15252. }
  15253. switch (str[12] | 0x20)
  15254. {
  15255. case _X11_SPACE_SWITCH: // ' '
  15256. {
  15257. if (str[12])
  15258. {
  15259. switch (str[13] | 0x20)
  15260. {
  15261. case '1':
  15262. {
  15263. idx += 14;
  15264. return X11_SPRING_GREEN_1;
  15265. }
  15266. case '2':
  15267. {
  15268. idx += 14;
  15269. return X11_SPRING_GREEN_2;
  15270. }
  15271. case '3':
  15272. {
  15273. idx += 14;
  15274. return X11_SPRING_GREEN_3;
  15275. }
  15276. case '4':
  15277. {
  15278. idx += 14;
  15279. return X11_SPRING_GREEN_4;
  15280. }
  15281. }
  15282. }
  15283. }
  15284. case '_' | 0x20:
  15285. {
  15286. switch (str[13] | 0x20)
  15287. {
  15288. case '1':
  15289. {
  15290. idx += 14;
  15291. return X11_SPRING_GREEN_1;
  15292. }
  15293. case '2':
  15294. {
  15295. idx += 14;
  15296. return X11_SPRING_GREEN_2;
  15297. }
  15298. case '3':
  15299. {
  15300. idx += 14;
  15301. return X11_SPRING_GREEN_3;
  15302. }
  15303. case '4':
  15304. {
  15305. idx += 14;
  15306. return X11_SPRING_GREEN_4;
  15307. }
  15308. }
  15309. }
  15310. }
  15311. idx += 12;
  15312. return X11_SPRING_GREEN;
  15313. }
  15314. case 'g':
  15315. {
  15316. if (!str[7] || strcmp(str[7], !"REEN", true, 4))
  15317. {
  15318. return -1;
  15319. }
  15320. switch (str[11] | 0x20)
  15321. {
  15322. case '1':
  15323. {
  15324. idx += 12;
  15325. return X11_SPRINGGREEN1;
  15326. }
  15327. case '2':
  15328. {
  15329. idx += 12;
  15330. return X11_SPRINGGREEN2;
  15331. }
  15332. case '3':
  15333. {
  15334. idx += 12;
  15335. return X11_SPRINGGREEN3;
  15336. }
  15337. case '4':
  15338. {
  15339. idx += 12;
  15340. return X11_SPRINGGREEN4;
  15341. }
  15342. }
  15343. idx += 11;
  15344. return X11_SPRINGGREEN;
  15345. }
  15346. }
  15347. }
  15348. case 't':
  15349. {
  15350. if (!str[2] || strcmp(str[2], !"EEL", true, 3))
  15351. {
  15352. return -1;
  15353. }
  15354. switch (str[5] | 0x20)
  15355. {
  15356. case _X11_SPACE_SWITCH: // ' '
  15357. {
  15358. if (str[5])
  15359. {
  15360. if (!str[6] || strcmp(str[6], !"BLUE", true, 4))
  15361. {
  15362. return -1;
  15363. }
  15364. switch (str[10] | 0x20)
  15365. {
  15366. case _X11_SPACE_SWITCH: // ' '
  15367. {
  15368. if (str[10])
  15369. {
  15370. switch (str[11] | 0x20)
  15371. {
  15372. case '1':
  15373. {
  15374. idx += 12;
  15375. return X11_STEEL_BLUE_1;
  15376. }
  15377. case '2':
  15378. {
  15379. idx += 12;
  15380. return X11_STEEL_BLUE_2;
  15381. }
  15382. case '3':
  15383. {
  15384. idx += 12;
  15385. return X11_STEEL_BLUE_3;
  15386. }
  15387. case '4':
  15388. {
  15389. idx += 12;
  15390. return X11_STEEL_BLUE_4;
  15391. }
  15392. }
  15393. }
  15394. }
  15395. case '_' | 0x20:
  15396. {
  15397. switch (str[11] | 0x20)
  15398. {
  15399. case '1':
  15400. {
  15401. idx += 12;
  15402. return X11_STEEL_BLUE_1;
  15403. }
  15404. case '2':
  15405. {
  15406. idx += 12;
  15407. return X11_STEEL_BLUE_2;
  15408. }
  15409. case '3':
  15410. {
  15411. idx += 12;
  15412. return X11_STEEL_BLUE_3;
  15413. }
  15414. case '4':
  15415. {
  15416. idx += 12;
  15417. return X11_STEEL_BLUE_4;
  15418. }
  15419. }
  15420. }
  15421. }
  15422. idx += 10;
  15423. return X11_STEEL_BLUE;
  15424. }
  15425. }
  15426. case '_' | 0x20:
  15427. {
  15428. if (!str[6] || strcmp(str[6], !"BLUE", true, 4))
  15429. {
  15430. return -1;
  15431. }
  15432. switch (str[10] | 0x20)
  15433. {
  15434. case _X11_SPACE_SWITCH: // ' '
  15435. {
  15436. if (str[10])
  15437. {
  15438. switch (str[11] | 0x20)
  15439. {
  15440. case '1':
  15441. {
  15442. idx += 12;
  15443. return X11_STEEL_BLUE_1;
  15444. }
  15445. case '2':
  15446. {
  15447. idx += 12;
  15448. return X11_STEEL_BLUE_2;
  15449. }
  15450. case '3':
  15451. {
  15452. idx += 12;
  15453. return X11_STEEL_BLUE_3;
  15454. }
  15455. case '4':
  15456. {
  15457. idx += 12;
  15458. return X11_STEEL_BLUE_4;
  15459. }
  15460. }
  15461. }
  15462. }
  15463. case '_' | 0x20:
  15464. {
  15465. switch (str[11] | 0x20)
  15466. {
  15467. case '1':
  15468. {
  15469. idx += 12;
  15470. return X11_STEEL_BLUE_1;
  15471. }
  15472. case '2':
  15473. {
  15474. idx += 12;
  15475. return X11_STEEL_BLUE_2;
  15476. }
  15477. case '3':
  15478. {
  15479. idx += 12;
  15480. return X11_STEEL_BLUE_3;
  15481. }
  15482. case '4':
  15483. {
  15484. idx += 12;
  15485. return X11_STEEL_BLUE_4;
  15486. }
  15487. }
  15488. }
  15489. }
  15490. idx += 10;
  15491. return X11_STEEL_BLUE;
  15492. }
  15493. case 'b':
  15494. {
  15495. if (!str[6] || strcmp(str[6], !"LUE", true, 3))
  15496. {
  15497. return -1;
  15498. }
  15499. switch (str[9] | 0x20)
  15500. {
  15501. case '1':
  15502. {
  15503. idx += 10;
  15504. return X11_STEELBLUE1;
  15505. }
  15506. case '2':
  15507. {
  15508. idx += 10;
  15509. return X11_STEELBLUE2;
  15510. }
  15511. case '3':
  15512. {
  15513. idx += 10;
  15514. return X11_STEELBLUE3;
  15515. }
  15516. case '4':
  15517. {
  15518. idx += 10;
  15519. return X11_STEELBLUE4;
  15520. }
  15521. }
  15522. idx += 9;
  15523. return X11_STEELBLUE;
  15524. }
  15525. }
  15526. }
  15527. }
  15528. }
  15529. case 't':
  15530. {
  15531. switch (str[1] | 0x20)
  15532. {
  15533. case 'a':
  15534. {
  15535. if (str[2] | 0x20 != 'n')
  15536. {
  15537. return -1;
  15538. }
  15539. switch (str[3] | 0x20)
  15540. {
  15541. case _X11_SPACE_SWITCH: // ' '
  15542. {
  15543. if (str[3])
  15544. {
  15545. switch (str[4] | 0x20)
  15546. {
  15547. case '1':
  15548. {
  15549. idx += 5;
  15550. return X11_TAN_1;
  15551. }
  15552. case '2':
  15553. {
  15554. idx += 5;
  15555. return X11_TAN_2;
  15556. }
  15557. case '3':
  15558. {
  15559. idx += 5;
  15560. return X11_TAN_3;
  15561. }
  15562. case '4':
  15563. {
  15564. idx += 5;
  15565. return X11_TAN_4;
  15566. }
  15567. }
  15568. }
  15569. }
  15570. case '_' | 0x20:
  15571. {
  15572. switch (str[4] | 0x20)
  15573. {
  15574. case '1':
  15575. {
  15576. idx += 5;
  15577. return X11_TAN_1;
  15578. }
  15579. case '2':
  15580. {
  15581. idx += 5;
  15582. return X11_TAN_2;
  15583. }
  15584. case '3':
  15585. {
  15586. idx += 5;
  15587. return X11_TAN_3;
  15588. }
  15589. case '4':
  15590. {
  15591. idx += 5;
  15592. return X11_TAN_4;
  15593. }
  15594. }
  15595. }
  15596. case '1':
  15597. {
  15598. idx += 4;
  15599. return X11_TAN1;
  15600. }
  15601. case '2':
  15602. {
  15603. idx += 4;
  15604. return X11_TAN2;
  15605. }
  15606. case '3':
  15607. {
  15608. idx += 4;
  15609. return X11_TAN3;
  15610. }
  15611. case '4':
  15612. {
  15613. idx += 4;
  15614. return X11_TAN4;
  15615. }
  15616. }
  15617. idx += 3;
  15618. return X11_TAN;
  15619. }
  15620. case 'h':
  15621. {
  15622. if (!str[2] || strcmp(str[2], !"ISTLE", true, 5))
  15623. {
  15624. return -1;
  15625. }
  15626. switch (str[7] | 0x20)
  15627. {
  15628. case _X11_SPACE_SWITCH: // ' '
  15629. {
  15630. if (str[7])
  15631. {
  15632. switch (str[8] | 0x20)
  15633. {
  15634. case '1':
  15635. {
  15636. idx += 9;
  15637. return X11_THISTLE_1;
  15638. }
  15639. case '2':
  15640. {
  15641. idx += 9;
  15642. return X11_THISTLE_2;
  15643. }
  15644. case '3':
  15645. {
  15646. idx += 9;
  15647. return X11_THISTLE_3;
  15648. }
  15649. case '4':
  15650. {
  15651. idx += 9;
  15652. return X11_THISTLE_4;
  15653. }
  15654. }
  15655. }
  15656. }
  15657. case '_' | 0x20:
  15658. {
  15659. switch (str[8] | 0x20)
  15660. {
  15661. case '1':
  15662. {
  15663. idx += 9;
  15664. return X11_THISTLE_1;
  15665. }
  15666. case '2':
  15667. {
  15668. idx += 9;
  15669. return X11_THISTLE_2;
  15670. }
  15671. case '3':
  15672. {
  15673. idx += 9;
  15674. return X11_THISTLE_3;
  15675. }
  15676. case '4':
  15677. {
  15678. idx += 9;
  15679. return X11_THISTLE_4;
  15680. }
  15681. }
  15682. }
  15683. case '1':
  15684. {
  15685. idx += 8;
  15686. return X11_THISTLE1;
  15687. }
  15688. case '2':
  15689. {
  15690. idx += 8;
  15691. return X11_THISTLE2;
  15692. }
  15693. case '3':
  15694. {
  15695. idx += 8;
  15696. return X11_THISTLE3;
  15697. }
  15698. case '4':
  15699. {
  15700. idx += 8;
  15701. return X11_THISTLE4;
  15702. }
  15703. }
  15704. idx += 7;
  15705. return X11_THISTLE;
  15706. }
  15707. case 'o':
  15708. {
  15709. if (!str[2] || strcmp(str[2], !"MATO", true, 4))
  15710. {
  15711. return -1;
  15712. }
  15713. switch (str[6] | 0x20)
  15714. {
  15715. case _X11_SPACE_SWITCH: // ' '
  15716. {
  15717. if (str[6])
  15718. {
  15719. switch (str[7] | 0x20)
  15720. {
  15721. case '1':
  15722. {
  15723. idx += 8;
  15724. return X11_TOMATO_1;
  15725. }
  15726. case '2':
  15727. {
  15728. idx += 8;
  15729. return X11_TOMATO_2;
  15730. }
  15731. case '3':
  15732. {
  15733. idx += 8;
  15734. return X11_TOMATO_3;
  15735. }
  15736. case '4':
  15737. {
  15738. idx += 8;
  15739. return X11_TOMATO_4;
  15740. }
  15741. }
  15742. }
  15743. }
  15744. case '_' | 0x20:
  15745. {
  15746. switch (str[7] | 0x20)
  15747. {
  15748. case '1':
  15749. {
  15750. idx += 8;
  15751. return X11_TOMATO_1;
  15752. }
  15753. case '2':
  15754. {
  15755. idx += 8;
  15756. return X11_TOMATO_2;
  15757. }
  15758. case '3':
  15759. {
  15760. idx += 8;
  15761. return X11_TOMATO_3;
  15762. }
  15763. case '4':
  15764. {
  15765. idx += 8;
  15766. return X11_TOMATO_4;
  15767. }
  15768. }
  15769. }
  15770. case '1':
  15771. {
  15772. idx += 7;
  15773. return X11_TOMATO1;
  15774. }
  15775. case '2':
  15776. {
  15777. idx += 7;
  15778. return X11_TOMATO2;
  15779. }
  15780. case '3':
  15781. {
  15782. idx += 7;
  15783. return X11_TOMATO3;
  15784. }
  15785. case '4':
  15786. {
  15787. idx += 7;
  15788. return X11_TOMATO4;
  15789. }
  15790. }
  15791. idx += 6;
  15792. return X11_TOMATO;
  15793. }
  15794. case 'u':
  15795. {
  15796. if (!str[2] || strcmp(str[2], !"RQUOISE", true, 7))
  15797. {
  15798. return -1;
  15799. }
  15800. switch (str[9] | 0x20)
  15801. {
  15802. case _X11_SPACE_SWITCH: // ' '
  15803. {
  15804. if (str[9])
  15805. {
  15806. switch (str[10] | 0x20)
  15807. {
  15808. case '1':
  15809. {
  15810. idx += 11;
  15811. return X11_TURQUOISE_1;
  15812. }
  15813. case '2':
  15814. {
  15815. idx += 11;
  15816. return X11_TURQUOISE_2;
  15817. }
  15818. case '3':
  15819. {
  15820. idx += 11;
  15821. return X11_TURQUOISE_3;
  15822. }
  15823. case '4':
  15824. {
  15825. idx += 11;
  15826. return X11_TURQUOISE_4;
  15827. }
  15828. }
  15829. }
  15830. }
  15831. case '_' | 0x20:
  15832. {
  15833. switch (str[10] | 0x20)
  15834. {
  15835. case '1':
  15836. {
  15837. idx += 11;
  15838. return X11_TURQUOISE_1;
  15839. }
  15840. case '2':
  15841. {
  15842. idx += 11;
  15843. return X11_TURQUOISE_2;
  15844. }
  15845. case '3':
  15846. {
  15847. idx += 11;
  15848. return X11_TURQUOISE_3;
  15849. }
  15850. case '4':
  15851. {
  15852. idx += 11;
  15853. return X11_TURQUOISE_4;
  15854. }
  15855. }
  15856. }
  15857. case '1':
  15858. {
  15859. idx += 10;
  15860. return X11_TURQUOISE1;
  15861. }
  15862. case '2':
  15863. {
  15864. idx += 10;
  15865. return X11_TURQUOISE2;
  15866. }
  15867. case '3':
  15868. {
  15869. idx += 10;
  15870. return X11_TURQUOISE3;
  15871. }
  15872. case '4':
  15873. {
  15874. idx += 10;
  15875. return X11_TURQUOISE4;
  15876. }
  15877. }
  15878. idx += 9;
  15879. return X11_TURQUOISE;
  15880. }
  15881. }
  15882. }
  15883. case 'v':
  15884. {
  15885. if (!str[1] || strcmp(str[1], !"IOLET", true, 5))
  15886. {
  15887. return -1;
  15888. }
  15889. switch (str[6] | 0x20)
  15890. {
  15891. case _X11_SPACE_SWITCH: // ' '
  15892. {
  15893. if (str[6])
  15894. {
  15895. if (!str[7] || strcmp(str[7], !"RED", true, 3))
  15896. {
  15897. return -1;
  15898. }
  15899. switch (str[10] | 0x20)
  15900. {
  15901. case _X11_SPACE_SWITCH: // ' '
  15902. {
  15903. if (str[10])
  15904. {
  15905. switch (str[11] | 0x20)
  15906. {
  15907. case '1':
  15908. {
  15909. idx += 12;
  15910. return X11_VIOLET_RED_1;
  15911. }
  15912. case '2':
  15913. {
  15914. idx += 12;
  15915. return X11_VIOLET_RED_2;
  15916. }
  15917. case '3':
  15918. {
  15919. idx += 12;
  15920. return X11_VIOLET_RED_3;
  15921. }
  15922. case '4':
  15923. {
  15924. idx += 12;
  15925. return X11_VIOLET_RED_4;
  15926. }
  15927. }
  15928. }
  15929. }
  15930. case '_' | 0x20:
  15931. {
  15932. switch (str[11] | 0x20)
  15933. {
  15934. case '1':
  15935. {
  15936. idx += 12;
  15937. return X11_VIOLET_RED_1;
  15938. }
  15939. case '2':
  15940. {
  15941. idx += 12;
  15942. return X11_VIOLET_RED_2;
  15943. }
  15944. case '3':
  15945. {
  15946. idx += 12;
  15947. return X11_VIOLET_RED_3;
  15948. }
  15949. case '4':
  15950. {
  15951. idx += 12;
  15952. return X11_VIOLET_RED_4;
  15953. }
  15954. }
  15955. }
  15956. }
  15957. idx += 10;
  15958. return X11_VIOLET_RED;
  15959. }
  15960. }
  15961. case '_' | 0x20:
  15962. {
  15963. if (!str[7] || strcmp(str[7], !"RED", true, 3))
  15964. {
  15965. return -1;
  15966. }
  15967. switch (str[10] | 0x20)
  15968. {
  15969. case _X11_SPACE_SWITCH: // ' '
  15970. {
  15971. if (str[10])
  15972. {
  15973. switch (str[11] | 0x20)
  15974. {
  15975. case '1':
  15976. {
  15977. idx += 12;
  15978. return X11_VIOLET_RED_1;
  15979. }
  15980. case '2':
  15981. {
  15982. idx += 12;
  15983. return X11_VIOLET_RED_2;
  15984. }
  15985. case '3':
  15986. {
  15987. idx += 12;
  15988. return X11_VIOLET_RED_3;
  15989. }
  15990. case '4':
  15991. {
  15992. idx += 12;
  15993. return X11_VIOLET_RED_4;
  15994. }
  15995. }
  15996. }
  15997. }
  15998. case '_' | 0x20:
  15999. {
  16000. switch (str[11] | 0x20)
  16001. {
  16002. case '1':
  16003. {
  16004. idx += 12;
  16005. return X11_VIOLET_RED_1;
  16006. }
  16007. case '2':
  16008. {
  16009. idx += 12;
  16010. return X11_VIOLET_RED_2;
  16011. }
  16012. case '3':
  16013. {
  16014. idx += 12;
  16015. return X11_VIOLET_RED_3;
  16016. }
  16017. case '4':
  16018. {
  16019. idx += 12;
  16020. return X11_VIOLET_RED_4;
  16021. }
  16022. }
  16023. }
  16024. }
  16025. idx += 10;
  16026. return X11_VIOLET_RED;
  16027. }
  16028. case 'r':
  16029. {
  16030. if (!str[7] || strcmp(str[7], !"ED", true, 2))
  16031. {
  16032. return -1;
  16033. }
  16034. switch (str[9] | 0x20)
  16035. {
  16036. case '1':
  16037. {
  16038. idx += 10;
  16039. return X11_VIOLETRED1;
  16040. }
  16041. case '2':
  16042. {
  16043. idx += 10;
  16044. return X11_VIOLETRED2;
  16045. }
  16046. case '3':
  16047. {
  16048. idx += 10;
  16049. return X11_VIOLETRED3;
  16050. }
  16051. case '4':
  16052. {
  16053. idx += 10;
  16054. return X11_VIOLETRED4;
  16055. }
  16056. }
  16057. idx += 9;
  16058. return X11_VIOLETRED;
  16059. }
  16060. }
  16061. idx += 6;
  16062. return X11_VIOLET;
  16063. }
  16064. case 'w':
  16065. {
  16066. if (str[1] | 0x20 != 'h')
  16067. {
  16068. return -1;
  16069. }
  16070. switch (str[2] | 0x20)
  16071. {
  16072. case 'e':
  16073. {
  16074. if (!str[3] || strcmp(str[3], !"AT", true, 2))
  16075. {
  16076. return -1;
  16077. }
  16078. switch (str[5] | 0x20)
  16079. {
  16080. case _X11_SPACE_SWITCH: // ' '
  16081. {
  16082. if (str[5])
  16083. {
  16084. switch (str[6] | 0x20)
  16085. {
  16086. case '1':
  16087. {
  16088. idx += 7;
  16089. return X11_WHEAT_1;
  16090. }
  16091. case '2':
  16092. {
  16093. idx += 7;
  16094. return X11_WHEAT_2;
  16095. }
  16096. case '3':
  16097. {
  16098. idx += 7;
  16099. return X11_WHEAT_3;
  16100. }
  16101. case '4':
  16102. {
  16103. idx += 7;
  16104. return X11_WHEAT_4;
  16105. }
  16106. }
  16107. }
  16108. }
  16109. case '_' | 0x20:
  16110. {
  16111. switch (str[6] | 0x20)
  16112. {
  16113. case '1':
  16114. {
  16115. idx += 7;
  16116. return X11_WHEAT_1;
  16117. }
  16118. case '2':
  16119. {
  16120. idx += 7;
  16121. return X11_WHEAT_2;
  16122. }
  16123. case '3':
  16124. {
  16125. idx += 7;
  16126. return X11_WHEAT_3;
  16127. }
  16128. case '4':
  16129. {
  16130. idx += 7;
  16131. return X11_WHEAT_4;
  16132. }
  16133. }
  16134. }
  16135. case '1':
  16136. {
  16137. idx += 6;
  16138. return X11_WHEAT1;
  16139. }
  16140. case '2':
  16141. {
  16142. idx += 6;
  16143. return X11_WHEAT2;
  16144. }
  16145. case '3':
  16146. {
  16147. idx += 6;
  16148. return X11_WHEAT3;
  16149. }
  16150. case '4':
  16151. {
  16152. idx += 6;
  16153. return X11_WHEAT4;
  16154. }
  16155. }
  16156. idx += 5;
  16157. return X11_WHEAT;
  16158. }
  16159. case 'i':
  16160. {
  16161. if (!str[3] || strcmp(str[3], !"TE", true, 2))
  16162. {
  16163. return -1;
  16164. }
  16165. switch (str[5] | 0x20)
  16166. {
  16167. case _X11_SPACE_SWITCH: // ' '
  16168. {
  16169. if (str[5])
  16170. {
  16171. if (str[6] && !strcmp(str[6], !"SMOKE", true, 5))
  16172. {
  16173. idx += 11;
  16174. return X11_WHITE_SMOKE;
  16175. }
  16176. }
  16177. }
  16178. case '_' | 0x20:
  16179. {
  16180. if (str[6] && !strcmp(str[6], !"SMOKE", true, 5))
  16181. {
  16182. idx += 11;
  16183. return X11_WHITE_SMOKE;
  16184. }
  16185. }
  16186. case 's':
  16187. {
  16188. if (str[6] && !strcmp(str[6], !"MOKE", true, 4))
  16189. {
  16190. idx += 10;
  16191. return X11_WHITESMOKE;
  16192. }
  16193. }
  16194. }
  16195. idx += 5;
  16196. return X11_WHITE;
  16197. }
  16198. }
  16199. }
  16200. case 'y':
  16201. {
  16202. if (!str[1] || strcmp(str[1], !"ELLOW", true, 5))
  16203. {
  16204. return -1;
  16205. }
  16206. switch (str[6] | 0x20)
  16207. {
  16208. case _X11_SPACE_SWITCH: // ' '
  16209. {
  16210. if (str[6])
  16211. {
  16212. switch (str[7] | 0x20)
  16213. {
  16214. case '1':
  16215. {
  16216. idx += 8;
  16217. return X11_YELLOW_1;
  16218. }
  16219. case '2':
  16220. {
  16221. idx += 8;
  16222. return X11_YELLOW_2;
  16223. }
  16224. case '3':
  16225. {
  16226. idx += 8;
  16227. return X11_YELLOW_3;
  16228. }
  16229. case '4':
  16230. {
  16231. idx += 8;
  16232. return X11_YELLOW_4;
  16233. }
  16234. case 'g':
  16235. {
  16236. if (str[8] && !strcmp(str[8], !"REEN", true, 4))
  16237. {
  16238. idx += 12;
  16239. return X11_YELLOW_GREEN;
  16240. }
  16241. }
  16242. }
  16243. }
  16244. }
  16245. case '_' | 0x20:
  16246. {
  16247. switch (str[7] | 0x20)
  16248. {
  16249. case '1':
  16250. {
  16251. idx += 8;
  16252. return X11_YELLOW_1;
  16253. }
  16254. case '2':
  16255. {
  16256. idx += 8;
  16257. return X11_YELLOW_2;
  16258. }
  16259. case '3':
  16260. {
  16261. idx += 8;
  16262. return X11_YELLOW_3;
  16263. }
  16264. case '4':
  16265. {
  16266. idx += 8;
  16267. return X11_YELLOW_4;
  16268. }
  16269. case 'g':
  16270. {
  16271. if (str[8] && !strcmp(str[8], !"REEN", true, 4))
  16272. {
  16273. idx += 12;
  16274. return X11_YELLOW_GREEN;
  16275. }
  16276. }
  16277. }
  16278. }
  16279. case '1':
  16280. {
  16281. idx += 7;
  16282. return X11_YELLOW1;
  16283. }
  16284. case '2':
  16285. {
  16286. idx += 7;
  16287. return X11_YELLOW2;
  16288. }
  16289. case '3':
  16290. {
  16291. idx += 7;
  16292. return X11_YELLOW3;
  16293. }
  16294. case '4':
  16295. {
  16296. idx += 7;
  16297. return X11_YELLOW4;
  16298. }
  16299. case 'g':
  16300. {
  16301. if (str[7] && !strcmp(str[7], !"REEN", true, 4))
  16302. {
  16303. idx += 11;
  16304. return X11_YELLOWGREEN;
  16305. }
  16306. }
  16307. }
  16308. idx += 6;
  16309. return X11_YELLOW;
  16310. }
  16311. }