; TeX output 1998.01.17:2003y>color push BlackY color pop?rcolor push Black color popwDtGGcmr17Pqackages7tinthe`graphics'bundle# (XQ cmr12D.PV.Carlisle37 1996/10/291č>Nff cmbx12Contents>"V cmbx101MIn9troQduction2>2MDriv9erTsuppQort2>3MColour" 3 MK`y cmr103.1dPackqageUUOptionse...........................color push Black3 color popM3.2dDe ningUUColoursc...........................color push Black4 color popM3.3dUsingUUColours荍.............................color push Black4 color popM3.4dNamedUUColoursMÍ............................color push Black5 color popM3.5dPageUUColourԍ..............................color push Black6 color popM3.6dBoxUUBackgrounds1F...........................color push Black6 color popM3.7dPossibleUUProblems[퍍..........................color push Black6 color pop>4MTheTGraphicspac9k\ragesЖ7M4.1dPackqageUUOptionse...........................color push Black7 color popM4.2dRotationM㍍................................color push Black8 color popM4.3dScalingA.................................color push Black8 color popM4.4dIncludingUUGraphicsFiles.......................color push Black9 color popM4.5dOtherUUcommandsinthem#R cmss10graphicspackqage2..............color push Black13 color popM4.6dGlobalUUsettingofkeys0........................color push Black15 color popM4.7dCompatibilityUUbGetweengraphicsandgraphicxY............color push Black15 color pop>5MRemainingTpac9k\ragesinthegraphicsbundlede15M5.1dEps g#B.................................color push Black15 color popM5.2dT*rig#L..................................color push Black16 color popM5.3dKeyvqal.................................color push Black16 color popM5.4dPstcol#C.................................color push Black16 color popM5.5dLscapGe .................................color push Black16 color pop>color push Black1Y color pop*y>color push BlackY color pop?>1VLIntros3duction>ThisdoGcumentservesasauser-manualforthepackqagescolor,'graphics,and >graphicx.F*urtherdoGcumentationmaybGeobtainedbyproGcessingthesource>(2VLDriverffsupps3ort>AllithesepackqagesrelyonfeaturesthatarenotinTU>'ExXitself.[Thesefeatures>must bGesuppliedbythe`driver'usedtoprintthedvi le.Unfortunatelynot>alldriverssuppGortthesamefeatures,+andeventheinternalmethoGdofaccessing>theseextensionsvqariesbGetweendrivers.E#Consequentlyallthesepackqagestake>optionsUUsuchas`dvips'tospGecifywhichdriverisbGeingused.>Y*ou)shouldtosetupasitedefaultfortheseoptions,_forthedriverthatyou>normally(use.SuppGosethatyouwishforthecolorL,packqagetoalwaysdefault>to BusespGecialsforthePostScriptdriver,7}dvipsone.Inthatcasecreatea le>color.cfgUUcontainingtheline:>\ExecuteOptions{dvipsone}>Normally&youwillwantanidentical legraphics.cfgtosetasimilardefault>forUUthegraphicspackqages.>TheUUfollowingdriveroptionsaredeclaredinthepackqages.>color push Black color popWdvips,UUxdvi,dvipdf,pdftex,dvipsone,dviwindo,emtex,Wdviwin,UUpctexps,pctexwin,pctexhp,pctex32,truetex,tcidvi,Woztex,UUtextures>IfyouuseadriverthatisnotinthelistabGoveyoumayaddanoptionfor>thatdriverbyputtingtheappropriate\DeclareOptionlineintographics.cfg>and)color.cfg,2bbGeforemakingitthedefaultoptionwith\ExecuteOptions,as>describGedUUabove.>F*orxexampletoaddtheoption`dvi2ps'fortheoriginalUnixdvitopsdriver,>andUUtomakethatthedefault,youjustneedcon guration lesloGokinglike:9color push Black color pop>ߤN cmtt9\DeclareOption{dvi2ps}{\def\Gin@driver{dvi2ps.def}} >\ExecuteOptions{dvi2ps}>ThereP$isasuitabledvi2ps.def leinthestandarddistribution.Itisnotenabled>byLdefaultasitisnotwelltestedasthedriverisnolongeravqailabletome.UThe>followingUUdriver lesaresimilarlydistributedbutnotenabledbydefault.>color push Black color popWdvi2ps,UUdvialw,dvilaser,dvitops,psprint,pubps,ln>color push Black2Y color popy>color push BlackY color pop?>Mostofthesedriver lesaregeneratedfromthesource ledrivers.dtx.\ lehasthesourcesforotherversions(forexampleolderversionsofdvipsand>textures)UUwhicharenotgeneratedbydefault.g獑>IfyouuseadriverthatisnotcoveredbyanyofthesepGossibilities,$[youmaytry>to5writea.def lebyanalogywithoneoftheexistingones,.andthenspGecify>asuitableoptioningraphics.cfgandcolor.cfg,#4asfortheabGoveexampleof>dvi2ps.&8/>3VLColourO>TheJcoloursuppGortisbuiltaroundtheideaofasystemof': cmti10Colour:Mo}'dels.nEThe>ColourUUmoGdelssupportedbyadrivervqary*,buttypicallyinclude79color push Blackrgb color popSRedОGreenBlue:hXANotethatthenamedmoGdelisreallyjustgivenasanexampleofacolourmodel>that$takesnamesratherthananumericspGeci cation. OtheroptionsmaybGe>providedloGcallythatprovidedi erentcolourmoGdels,/eg2pan9tone(Anindustry>standardosetofcolours),Yx11(ColournamesfromtheXWindowSystem),>etc.:The${standarddistributiondoGesnotcurrentlyhavesuchmoGdels,XEbutthe>named9moGdelcouldbeusedasanexampleofhowtode neanewcolourmodel.>TheZ@namesusedinthenamedmoGdelarethosesuggestedbyJimHafnerin>hiscolordviandfoiltexpackqages,.andimplementedoriginallyinthecolor.pro>headerUU leforthedvipsdriver.!$> N cmbx123.1\Pack@ageOptions;>MostDoftheoptionstothecolorѲpackqageDjustspGecifyadriver,e.g.,dvips,as>discussedUUinsection2.g獑>OnespGecialoptionforthecolorApackqagethatisofinterestismonochrome.If>this .optionisselectedthecolourcommandsarealldisabledsothattheydonot>color push Black3Y color pop)Ry>color push BlackY color pop?>generate1errors,butdonotgeneratecoloureither.:[Thisisusefulifpreviewing >withUUapreviewerthatcannotproGducecolour.>ThreeuotherpackqageoptionscontroltheuseofthenamedmoGdel.J(Thedvips>driveriy(bydefault)pre-de nes68colournames.3Thedvipsoptionnormally>makeslthesenamesavqailableinthenamedcolourmoGdel. Ifyoudonotwant>theseOnamestobGedeclaredinthismodel(SavingTU>'ExXsomememory)youmay>give,thenodvipsnamesoption.d-Conversely*,4ifyouareusinganotherdriver,4you>may^wishtoaddthesenamestothenamedmoGdelforthatdriver(espGeciallyif>you>areproGcessingadocumentoriginallyproducedondvips).j Inthiscaseyou>couldusethedvipsnamesoption.^HLastlytheusenamesoptionmakesallnames>inUUthenamedmoGdeldirectlyavqailable,asdescribedbelow.!h܍>3.2\De ningColours 퍑>Thecoloursblack,"gwhite,red,green,blue,cyan,magenta,yellowshouldbGe>prede ned, butvshouldyouwishtomixyourowncoloursusethe\definecolor>command.o$@ff1ͤLτ ffΟ1\definecolor{" cmsy9h#j cmti9name i}{hmodelpiA}{hcolourNThis$de nes !", cmsy10hname[i'asacolourwhichcanbGeusedinlatercolourcommands.>F*orUUexample9color push Black color pop>\definecolor{light-blue}{rgb}{0.8,0.85,1} >\definecolor{mygrey}{gray}{0.75}>Nowlight-blueandmygreymaybGeusedinadditiontotheprede nedcolours>abGove.>3.3\UsingColours 퍍>3.3.1a#UsingTprede nedcolours>TheL.syntaxforcolourchangesisdesignedtomimicfontchanges.VRThebasic >syntaxUUis:o$@ffOew1ͤLτ ffΟ1\color{hname i}͡ ff5ffOew阍>This?isade}'claration,like?\bfseriesItchangesthecurrentcolourtohname[i>untilUUtheendofthecurrentgrouporenvironment.>Anwvalternativecommandsyntaxistouseac}'ommandformthattakesthetext>to>bGecolouredasanar}'gument. Thisissimilartothefontcommandssuchas>\textbf:>color push Black4Y color pop6y>color push BlackY color pop?$@ffq1ͤLτ ffΟ1\textcolor{hname i}{htexti}͡ ff5ffq阍>SoUUtheabGoveUUisessentiallyequivqalentto{\color{hname[i H}text}.6>3.3.2a#UsingTcolourspQeci cationsdirectly"($ff*1ͤLτ ffΟ1\color[hmodelpiA]{hspeci cation9i8O@}8 ff ͤLτ ffΟ1\textcolor[hmodelpiA]{hspeci cation9i8O@}{htexti}͡ ff5ff*ō>Normally1onewouldpredeclareallthecoloursusedinapackqage,8orinthedoGc- >ument#preamble,butsometimesitisconvenienttodirectlyuseacolourwithout>namingit rst.=T*oachievethis\color(andalltheothercolourcommands)>take˄anoptionalargumentspGecifyingthemodel.CIfthisisusedthenthemanda->toryUUargumenttakesahc}'olourspeci cationciainsteadofahname[i#_.qF*orexample:>\color[rgb]{1,0.2,0.3}>wouldUUdirectlyselectthatcolour.>ThisUUisparticularlyusefulforaccessingthenamedmoGdel:>\color[named]{BrickRed}UUselectsthedvipscolourBrickRed.>RatherthanrepGeatedlyuse[named]youmayuse\definecolortoprovide>convenientUUaliases:>\definecolor{myred}{named}{WildStrawberry}UU...\color{myred}...>AlternativelywifyouarehappytousetheexistingnamesfromthenamedmoGdel,>you mayusetheusenamespackqageoption,whiche ectivelycalls\definecolor>onVeverycolourinthenamedmoGdel,WIthusallowing\color{WildStrawberry}>inUUadditionto\color[named]{WildStrawbery}.!6>3.4\NamedColoursuT>UsingbthenamedcolourmoGdelhascertainadvqantagesoverusingothercolour>moGdels.>Firstlyjasthedvi lecontainsarequestforacolourbyname,/theactualmix>ofsprimarycoloursusedtoobtaintherequestedcolourcanbGetunedtothe>characteristicsydofaparticularprinter.Inthedvipsdriverthemeaningsofthe>colour(namesarede nedintheheader lecolor.pro.X Usersareencouragedto>proGducedi erentversionsofthis leforanyprinterstheyuse.xBythismeans>the$"samedvi leshouldproGducecoloursofsimilarappearancewhenprintedon>printersUUwithdi erentcolourcharacteristics.>Secondly*,apart?fromthesocalled`proGcesscolours'thatareproducedbymixing>primarycoloursduringtheprintproGcess,njonemaywanttouse`spGot'or`custom'>colours.SHereaparticularcolournamedoGesnotrefertoamixofprimaries, but>toaparticularink.^ ThepartsofthedoGcumentusingthiscolourwillbeprinted>separatelyUUusingthisnamedinkcolour.>color push Black5Y color popAy>color push BlackY color pop?>3.5\PageColour"k$ffK1ͤLτ ffΟ1\pagecolor{hname i}I8I ff ͤLτ ffΟ1\pagecolor[hmodelpiA]{hspeci cation9i8O@}͡ ff5ffKō>TheibackgroundcolourofthewholepagecanbGesetusing\pagecolor.This >takesthesameargumentformsas\colorbutsetsthebackgroundcolourfor>thea#currentandallsubsequentpages.2Itisaglobaldeclaration,dsoyouneedto>useUU\pagecolor{white}to`getbacktonormal'.!6>3.6\BoxBackgroundsuT>TwoϢcommandssimilarto\fboxproGduceboxeswiththebackgroundsshaded>anUUappropriatecolour.-($ffv1ͤLτ ffΟ1\colorbox{hname i}{htexti}'+ ff ͤLτ ffΟ1\colorbox[hmodelpiA]{hspeci cation9i8O@}{htexti}V ffͤLτ ffΟ1\fcolorbox{hname16i"d}{hname26i}{htexti}cg ffͤLτ ffΟ1\fcolorbox[hmodelpiA]{hspeci cation16i=}{hspeci cation26i}{htexti}͡ ff5ffv(ō>TheformerproGducesaboxcolouredwithname color push gray 0.75color push gray 0.75 ( color popcolor push BlacklikeUUthis color pop( color pop.^;Thelatterissimilar>butUUputsaframeofcolourname1[aroundthebGoxcolouredname2.>Thesecommandsusethe\fboxparameters\fboxruleand\fboxseptodeter->mineUUthethicknessoftherule,andthesizeoftheshadedarea.>3.7\PossibleProblemsuT>TU>'ExXwasnotdesignedwithcolourinmind,QandproGducingcoloursrequiresa>lot ofhelpfromthedriverprogram.YThus,CdepGendingonthedriver,Csomeorall>featuresUUofthecolorxpackqageUUmaynotbGeavqailable.>SomekdriversdonotmaintainaspGecial`colourstack'.:Thesedriversarelikelyto>get\confusedifyounestcolourchanges,orusecoloursin oatingenvironments.>SomeSSdriversdonotmaintaincoloursoverapagebreak,sothatifthepage>breaks+inthemiddleofacolouredparagraph,thelastpartofthetextwill>incorrectlyUUbGeprintedinblack.>Therefisadi erenttypGeofproblemthatwilloccurforalldrivers..xDuetocertain>technicalbdiculties^ٓRcmr71|s,itispGossiblethatatpointswherethecolourchanges,the>sp}'acing Eis&a ected.bCF*orthisreasonthemonochromeoptiondoGesnotcompletely>disable&thecolourcommands,[itrede nesthemtowritetothelog le.This> color push Blackffffv J= "5-:Aacmr61L|{Ycmr8AÎtYleasttwocauses:H1)Thepresenceofa$Cscmtt8\specialK cmsy8h%#fcmti8whatsit[i&eprevents\addvspace`seeing' space+honthecurrenÎtverticallist,@socausingittoincorrectlyaddextraverticalspace.Q2)Ahwhatsit[i$asXthe rstitemina\vtopmoÎvesXthereferencepcolor push Black6Y color popNy>color push BlackY color pop?>willhavethesamee ectsonspacing,soyoucanproGducemonochromedrafts >ofUUyourdoGcument,atleastknowingthatthe nalspacingisbGeingshown.'č>4VLTheffGraphicspackages>ThereUUaretwoUUgraphicspackqages:9color push Black&kAH cmssbx10graphics color poph[TheUU`standard'graphicspackqage.9color push Blackgraphicx color popi#TheUU`extended'or`enhanced'graphicspackqage.>Thetwodi eronlyintheformatofoptionalargumentsforthecommands>de ned.qTheUQcommandnames,URandthemandatoryargumentsarethesamefor>theUUtwopackqages.!6>4.1\Pack@ageOptionsuT>As(discussedinsection2,1thegraphicspackqagessharethesame`driver'options>as,UthecolorOpackqage.As,Uforcolouryoushouldsetupasite-defaultina le,>graphics.cfg,UUcontainingtheline(fordvips):>\ExecuteOptions{dvips}>The,graphicspackqageshavesomeotheroptionsforcontrollinghowmanyofthe>featuresUUtoenable:9color push Blackdraft color pop[suppressallthe`spGecial'features.3Inparticulargraphics lesarenotWincludedj(buttheyarestillreadforsizeinfo)justthe lenameisprintedWinUUabGoxofthecorrectsize.9color push Black nal color popXThe!oppGositeofdraft.< Usefultoover-ride!aglobaldraftoptionspeci edWinUUthe\documentclasscommand.9color push Blackhiderotate color popvҲDoWnotshowrotatedtext(presumablybGecausethepreviewercanWnotUUrotate).9color push Blackhidescale color popoDonotshowscaledtext(presumablybGecausethepreviewercannotWscale).9color push Blackhiresbb color popgkLoGokaOforsizespeci cationsin%%HiResBoundingBoxlinesratherthanWstandardUU%%BoundingBoxlines.'ow cmss9NewTfeature 1996/10/29>color push Black7Y color pop]y>color push BlackY color pop?>4.2\Rotation a$ff01ͤLτ ffΟ1graphicso cmr9:01\rotatebox{hangle i}{htexti}BD ff ͤLτ ffΟ1graphicx:01\rotatebox[hkeyNThisVputstextHݲinabGox,V1likeV\mbox,butrotatesthebGoxthroughangle`degrees,?Wps: gsave currentpoint currentpoint translate 15 neg rotate neg exch neg exch translatelikeUUthis" ps: currentpoint grestore movetoa .>The4standardversionalwaysrotatesaroundthereferencepGointofthebGox,;Jbut >theUUkeyvalversiontakesthefollowingkeys:-($ffPX1ͤLτ ffΟ1origin=hlabelpi&ܡ ff ͤLτ ffΟ1x=hdimen9i>~ʡ ffͤLτ ffΟ1y=hdimen9i>~ʡ ffͤLτ ffΟ1units=hnumberi+r ff5ffPX%ō>So&:youmayspGecifybothxandy,ZswhichgivethecoGordinateofthecentreof>rotation2relativetothereferencepGointofthebGox,leg[x=2mm,?y=5mm].7Alterna->tively*,tforٻthemostcommonpGoints,tonemayuseoriginwithalab}'elDcontaining>oneortwoofthefollowing::lrctbBh(Bdenotesthebaseline,asforPST*ricks).>F*orexample,Zcompareadefaultrotationof180^ O!cmsy7+ײ...*Xps: gsave currentpoint currentpoint translate 180 neg rotate neg exch neg exch translateLikeUUThis)N= ps: currentpoint grestore moveto*...=tothee ects㎍>gainedUUbyusingtheoriginkey:>[origin?=c]UUrotatesabGoutthecentreofthebox,...*:Xps: gsave currentpoint currentpoint translate 180 neg rotate neg exch neg exch translateLikeUUThis)N= ps: currentpoint grestore moveto*...r>[origin?=tr]UUrotatesabGoutthetoprighthandcorner...*rXps: gsave currentpoint currentpoint translate 180 neg rotate neg exch neg exch translateLikeUUThis)N= ps: currentpoint grestore moveto*...>TheSunitskeyallowsachangefromthedefaultunitsofdegreesanti-cloGckwise.>GiveUUthenumbGerofunitsinonefullanti-cloGckwiserotation.qF*orexample:>[units?=-360]UUspGeci esdegreesclockwise.>[units=?6.283185]UUspGeci esradians.!6>4.3\ScalinguT>4.3.1a#ScalingTb9yscalefactoro$@ff1ͤLτ ffΟ1\scalebox{hh-scale i"ʐ}[hv-scale i"Q]{htexti}͡ ff5ff阍>Againrthisisbasicallylike\mboxbutscalesthetext.Ifv-sc}'aleKͲisnotspGeci ed>itdefaultstoh-sc}'ale.VIfitisspGeci edthetextisdistortedasthehorizontaland>verticalUUstretchesaredi erent,Nps: currentpoint currentpoint translate 3 .7 scale neg exch neg exch translateLikeThisZps: currentpoint currentpoint translate 1 3 div 1 .7 div scale neg exch neg exch translate@ .$@ff`R1ͤLτ ffΟ1\reflectbox{htexti}͡ ff5ff`R阍>AnUUabbreviationfor\scalebox{-1}[1]{htextظi}.>color push Black8Y color pop g"y>color push BlackY color pop?>4.3.2a#ScalingTtoarequestedsizeo$@ff1ͤLτ ffΟ1\resizebox*{hh-length9i'}{hv-length9i'O4}{htexti}͡ ff5ff阍>ScaleftextYYsothatthewidthish-length.JIf!isusedaseitherlengthargument, >the_otherargumentisusedtodetermineascalefactorthatisusedinbGoth>directions./Normally!xv-length۲referstotheheightofthebGox,Tbutinthestar>form, .itjreferstothe`height+depth'.AsnormalforL5ffA͉TU>'ExX2 b> cmmi10".~bGoxlength>arguments,\height,\width,\totalheight,\depthmaybGeusedtoreferto>theUUoriginalsizeofthebGox.>\resizebox{1in}{\height}{Some?text}:qYps: currentpoint currentpoint translate 1.63638 1.00003 scale neg exch neg exch translateSomeUUtexteps: currentpoint currentpoint translate 1 1.63638 div 1 1.00003 div scale neg exch neg exch translategv>\resizebox{1in}{!}{Some?text}:qYps: currentpoint currentpoint translate 1.63638 1.63638 scale neg exch neg exch translateSomeUUtexteps: currentpoint currentpoint translate 1 1.63638 div 1 1.63638 div scale neg exch neg exch translate!6>4.4\IncludingGraphicsFilesuT>Thefunctionsforgraphicsinclusiontrytogivethesameusersyntaxforinclud->inganykindofgraphics lethatcanbGeunderstoodbythedriver.]Thisrelies>onthe lehavinganextensionthatidenti esthe letypGe.^The`driveroptions'>will5de neacollectionof leextensionsthatthedrivercanhandle,Galthough>thisUUlistmaybGeextendedusingthedeclarationsdescribedbelow.>If|the le'sextensionisunknowntothedriver,-thesystemmaytryadefault> letypGe.V;ThePostScriptdriver lessetthisdefaulttobGeeps(PostScript),7but>thisUUbGehaviourmaybGecustomisedifotherdefaultsarerequired."($ff_1ͤLτ ffΟ1graphics:01\includegraphics*[hlxlx,llyUi ][hurx,uryUi%I]{h le i}͡ ff ͤLτ ffΟ1graphicx:01\includegraphics*[hkeyNIncludeUUagraphics le.>If*ispresent,thenthegraphicis`clippGed'tothesizespeci ed.UEIf*isomitted,>then anypartofthegraphicthatisoutsidethespGeci ed`boundingbox'will>over-printUUthesurroundingtext.>Iftheoptionalargumentsareomitted,U/thenthesizeofthegraphicwillbGe>determinedUUbyreadinganexternal leasdescribGedbelow.6>graphicsv9ersion Ifrv[hurx,ury}i(c]ispresent,ythenitshouldspGecifythecoordi->natesofthetoprightcorneroftheimage,asapairofTU>'ExXdimensions.Ifthe>unitsareomittedtheydefaulttobp.1So[1in,1in]and[72,72]areequivqa->lent.Ifw]onlyoneoptionalargumentappGears,thelowerleftcorneroftheimage>is(^assumedtobGeat[0,0].Otherwise[hllx,lly}i w]maybeusedtospecifythe>coGordinatesUUofthispoint.>color push Black9Y color pop vy>color push BlackY color pop?>graphicxyv9ersion HereEHthestarformisjustforcompatibilitywiththestandard >version.ItSjustaddscliptothelistofkeysspGeci ed.(Also,forincreased>compatibility*,dGiftwo|optionalargumentsareused,dGthe`standard'versionof>\includegraphicsUUisalwaysUUused,evenifthegraphicxpackqageisloaded.)>TheUUallowedkeysarelistedbGelow.9color push Blackbb color popOTheG&argumentshouldbGefourdimensions,}0separatedbyspaces.ThesedenoteWtheUU`BoundingBox'oftheprintedregionwithinthe le.9color push Blackbbllx,bblly ,bburx,bbury color pop SetߏthebGoundingbox. tMainlyforcompatibilityWwith:olderpackqages."SpGecifyingbbllx=a,bblly=b,bburx=c,bbury=disWequivqalentUUtospGecifyingbb?=abcd.9color push Blacknat9width,natheight color popNAgain)sanalternativetobb. natheight=h,natwidth=wWisUUequivqalenttobb?=00hw.9color push Blackhiresbb color popglBoGolean2vqaluedkey*.f/Ifsettotrue(justspecifyinghiresbbisequivqa-NewTfeature 1996/10/29WlentStohiresbb=true)thenTU>'ExXwillloGokfor%%HiResBoundingBoxlinesWrather79than%%BoundingBox.gItmaybGesettofalsetooverruleadefaultWsettingUUoftruesetbythehiresbbpackqageoption.9color push BlackviewpQort color popoThe.viewportkeytakesfourarguments,justlikebb. HoweverNewTfeature 1995/06/01WinthiscasethevqaluesaretakenrelativetotheoriginspGeci edbytheWbGoundingboxinthe le.3Soto`view'the1insquareinthebottomleftWhandbcorneroftheareaspGeci edbytheboundingbox,eHusetheargumentWviewport=0?07272.9color push Blacktrim color popXlSimilar%toviewpGort,gbutherethefourlengthsspecifytheamounttoNewTfeature 1995/06/01Wremove9oraddtoeachside.h^trim=?12349`crops'thepictureby1bpatWtheUUleft,2bpatthebGottom,3bpontherightand4bpatthetop.9color push Blackangle color pop]1RotationUUangle.9color push Blackorigin color pop`OriginUUforrotation.qSeethedoGcumentationof\rotatebox.NewTfeature 1995/09/289color push Blackwidth color pop_RequiredUUwidth.qThegraphicisscaledtothiswidth.9color push Blackheigh9t color popb%KRequiredUUheight.qThegraphicisscaledtothisheight.9color push Blacktotalheigh9t color popySpGecifythetotalheight(height+depth)ofthe gure.'ThiswillNewTfeature 1995/06/01Wdi er#fromthe`height'ifrotationhasoGccurred.a Inparticularifthe gureWhasUUbGeenrotatedby90^9thenitwillhavezeroheightbutlargedepth.9color push Blackk9eepaspQectratio color popBoGoleansvqaluedkeylike`clip'.!IfsettotruethenspGecifyingNewTfeature 1995/09/27WbGoth*`width'and`height'(or`totalheight')doGesnotdistortthe gurebutWscalesUUsuchthatneitherofthespGeci eddimensionsisexc}'eeded.9color push Blackscale color popZ߲ScaleUUfactor.>color push Black10Y color pop Ӡy>color push BlackY color pop?9color push Blackclip color popT㈲Either`true'or`false'(ornovqalue,'`whichisequivalentto`true').^Clipthe WgraphicUUtothebGoundingbox.9color push Blackdraft color pop[aUUbGooleanvqaluedkey*,like`clip'.qLoGcallyswitchestodraftmoGde.9color push Blackt9ypQe color popY3SpGecifyUUthegraphicstype.9color push Blackext color popRSpGecify the leextension.ThisshouldonlybeusedinconjunctionwithWtype.9color push Blackread color popXjSpGecifypthe leextensionofthe`read le'.ThisshouldonlybeusedinWconjunctionUUwithtype.9color push Blackcommand color popseCSpGecifyanycommandtobeappliedtothe le.KThisshouldonlybeWusedUUinconjunctionwithtype.č>F*or13thekeysspGecifyingtheoriginalsize(i.e,,8mtheboundingbox,8mtrimandview->pGortskeys)theunitscanbeomitted,:inwhichcasebp(i.e.,PostScriptpGoints)>areUUassumed.>The rstsevenkeysspGecifytheoriginalsizeoftheimage.aThissizeneedsto>bGespeci edinthecasethatthe lecannotbereadbyTU>'ExX,2oritcontainsan>incorrectUUsize`BoundingBox'spGeci cation.>bbllx...\bburyUUaremainlyforcompatibilityforolderpackqages.>bbllx=a,?bblly=b,bburx=c,bbury=d>isUUequivqalentto>bb?=abcd.>natheightandnatwidtharejustshorthandsforsettingthelowerleftcoGordi->nateUUto00andtheuppGerrightcoordinatetothespeci edwidthandheight.>ThepnextfewkeysspGecifyanyscalingorrotationtobGeappliedtotheimage.B&T*o>get0thesee ectsusingthestandardpackqage,fthe\includegraphicscallmust>bGeUUplacedinsidetheargumentofa\rotateboxor\scaleboxcommand.>TheDkeysarereadleft-to-right,@so[angle=90,?height=1in]meansrotateby>90Ydegrees,Z andthenscaletoaheightof1in.}[height=1in,?angle=90]would>resultUUina nalwidthof1in.>Ifthecalcpackqageisalsoloadedthelengthsmayusecalcsyntax,forinstance>to0spGecifyawidthof2cmlessthanthetextwidth:_[width=\textwidth-2cm].>TU>'ExXleavesthespacespGeci edeitherinthe le,orintheoptionalarguments.>If9anypartoftheimageisactuallyoutsidethisarea,ritwillbydefaultoverprint>thesurroundingtext.TIfthestarformisused,orclipspGeci ed,anypartofthe>imageUUoutsidethisareawillnotbGeprinted.>Thelastfourkeyssuppresstheparsingofthe lename.2Iftheyareused,fthe>mainp le1argumentshouldnothavethe leextension.TheycorrespGondtothe>argumentsUUof\DeclareGraphicsRuledescribGedbelow.>T*oseethee ectthatthevqariousoptionshaveconsiderthe lea.ps.This le>containsUUthebGoundingboxspeci cation>color push Black11Y color pop y>color push BlackY color pop?9color push Black color pop>%%BoundingBox:100100172172>Thatis,Гtheprintedregionconsistsofaone-inchsquare,Г100ptinfromthe >bGottomUUandlefthandedgesofthepaper.>InUUallthefollowingexamplestheinputwillbGeoftheform9color push Black color pop>left---\fbox{\includegraphics{a}}---right>WithUUdi erentoptionssuppliedto\includegraphics.>NoUUoptionalargument.NK>left|ffONENEff6PSfile="a.ps" llx=100 lly=100 urx=172 ury=172 rwi=720 NENEffffffOꎎO|right>graphics:h8\scalebox{0.5}{\includegraphics{a}} >graphicx:h8\includegraphics[scale=.5]{a}*ٍ>left|qff*[*"*"ff6PSfile="a.ps" llx=100 lly=100 urx=172 ury=172 rwi=360 *"*"ffffff*[*[|right>graphics:h8\includegraphics[115,110][135,145]{a}}>graphicx:h8\includegraphics[bb=?115110135145]{a})䍑>left|fff)!)!ff6PSfile="a.ps" llx=115 lly=110 urx=135 ury=145 rwi=200 3)!ffffff|right>graphics:h8\includegraphics*[115,110][135,145]{a}}>graphicx:h8\includegraphics[bb=?115110135145,clip]{a})䍑>left|fff)!)!ff:PSfile="a.ps" llx=115 lly=110 urx=135 ury=145 rwi=200 clip3)!ffffff|right>graphics:h8\scalebox{0.5}{\includegraphics{a}}UUanddraftoption.>graphicx:h8\includegraphics[scale=.5,?draft]{a}*ٍ>left|qff*[*"*"ff$"ffC׉ff$"UUa.psff$"#UÄ$"ff*"*"ffffff*[*[|right>color push Black12Y color pop y>color push BlackY color pop?>4.5\Othercommandsinthe(kAH cmssbx10graphicspack@ageo$@ffuޟ1ͤLτ ffΟ1\graphicspath{hdir-listi"}͡ ff5ffuގ阍>This!optionaldeclarationmaybGeusedtospecifyalistofdirectoriesinwhichto >searchMforgraphics les.TheformatisthesameasfortheL5ffA͉TU>'ExX2",Dprimitive>\input@path.^(Ajlistyofdirectories,&>eachina{}group(evenifthereisonlyone>inUUthelist).qF*orexample:>\graphicspath{{eps/}{tiff/}}>wouldcausethesystemtoloGokinthesubdirectoriesepsandtiffofthecurrent>directory*.qThisUUisunixsyntax,onaMacitwouldbGe:>\graphicspath{{:eps:}{:tiff:}}>Notethedi eringconventions,9aninitial:isneededonMacintoshsystemsto>denote.thecurrentfolder,ewhereasonunixaninitial/woulddenotethetop>levelUU`roGot'directory*.>Thedefaultsettingofthispathis\input@paththatis:graphics leswillbGe>foundUUwhereverTU>'ExX lesarefound.$@ffFB1ͤLτ ffΟ1\DeclareGraphicsExtensions{hext-listi"}͡ ff5ffFB阍>ThisAspGeci esthebehaviourofthesystemwhenno leextensionisspeci edinNewTdescription 1994/12/01>theargumentto\includegraphics.]4{hext-listظi%}shouldbGeacommaseparated>listof leextensions.V(WhitespaceisignoredbGetweentheentries.)A lename>isJbproGducedbyappendingoneextensionfromthelist.PIfa leisfound,the>systemactsasifthatextensionhadbGeenspeci ed.Ifnot,ǐthenextextension>inUUext-listH-istried.>NotemthatiftheextensionisnotspGeci edinthe\includegraphicscom->mand,^7the)=graphics lemustexistatthetimeL5ffA͉TU>'ExXisrun,astheexistence>ofothe leisusedtodeterminewhichextensionfromthelisttochoGose.How->ever~.ifa leextensionisPOspGeci ed,de.g.\includegraphics{a.ps}insteadof>\includegraphics{a},m#thenh`thegraphics leneednotexistatthetimeL5ffA͉TU>'ExX>is7$used.g(InparticularitmaybGecreatedonthe ybythehc}'ommandi8EspGeci ed>inthe\DeclareGraphicsRulecommanddescribGedbelow.):L5ffA͉TU>'ExXdoeshowever>needtobGeabletodeterminethesizeoftheimagesothissizemustbespeci ed>inUUarguments,orthe`read le'mustexistatthetimeL5ffA͉TU>'ExXisused.$@ffm1ͤLτ ffΟ1\DeclareGraphicsRule{hexti}{htype i}{hread- le i'}{hcommandpi.^V}͡ ff5ffm阍>AnyunumbGerofthesedeclarationscanbemade.2Theydeterminehowthesystem>bGehaveskwhena lewithextensionextCisspeci ed.e(Theextensionmaybe>spGeci edexplicitlyor,:iftheargumentto\includegraphicsdoesnothave>anzextension,:itmaybGeadefaultextensionfromtheext-listRspeci edwith>\DeclareGraphicsExtensions.)>ext^%thekM leextensionforwhichthisruleapplies.AsaspGecialcase,pextmaybGe>color push Black13Y color popy>color push BlackY color pop?>givenas*todenotethedefaultbGehaviourforallundeclaredextensions(seethe >exampleUUbGelow).꫍>typ}'elyisthe`typGe'of leinvolved.9`All lesofthesametypGewillbeinputwiththe>sameSpinternalcommand(whichmustbGede nedina`driver le').q%F*orexample> lesUUwithextensionsps,eps,ps.gzmayallbGeclassedastypGeeps.>r}'ead- le~Ndeterminestheextensionofthe lethatshouldbGereadtodetermine>sizeinformation.JNItmaybGethesameasextbutitmaybGedi erent,forexample>.ps.gz8 lesarenotreadableeasilybyTU>'ExX,qsoyoumaywanttoputthebGounding>bGoxinformationinaseparate lewithextension.ps.bb.UIfr}'ead- leE5isempty*,>{},|thentthesystemwillnottrytoloGcateanexternal leforsizeinfo,andthe>size,mustbGespeci edintheargumentsof\includegraphics.d0Ifthedriver le>spGeci esxMaprocedureforreadingsize lesfortyp}'e, thatwillbeused, otherwise>theproGcedureforreadingeps leswillbeused.Thusthesizeofbitmap les>mayIbGespeci edina lewithaPostScriptstyle%%BoundingBoxline,Lifnoother>spGeci cUUformatisavqailable.>As"aspGecialcase*maybeusedtodenotethesameextensionasthegraphic> le.+CThis~ismainlyofuseinconjunctionwithusing*astheextension, Hasin>thatUUcasetheparticulargraphicextensionisnotknown.qF*orexampleV9color push Black color popB\DeclareGraphicsRule{*}{eps}{*}{}V>This:woulddeclareadefaultrule,suchthatallunknownextensionswouldbGe>treatednasEPS les,4andthegraphic lewouldbGereadforaBoundingBox>comment.>c}'ommand_isWausuallyempty*,Wbutifnonemptyitisusedinplaceofthe lename>inžthe\special.AWithinthisargument,v#1maybGeusedtodenotethe lename.>ThusUUusingthedvipsdriver,onemayuse>\DeclareGraphicsRule{.ps.gz}{eps}{.ps.bb}{`zcat?#1}>ther nalargumentcausesdvipstousethezcatcommandtounzipthe lebGefore>insertingUUitintothePostScriptoutput.>NotethatL5ffA͉TU>'ExXwill ndthegraphics lebysearchingalongTEXINPUTS(and>pGossiblyotherplaces,Qasspeci edwith\graphicspath)howeveritmaybethat>thencommandyouspGecifyinthisargumentcannot ndsuch lesunlessthey>areRinthecurrentdirectory*.gOnsomesystemsitmaybGepossibletomodify>theSdcommandsothatitwill ndany lesthatL5ffA͉TU>'ExXcan nd.q!F*orexampleon>newer7web2cTU>'ExXreleasesonunix,qonemaymoGdifytheabovecommandsothat>theUUlastargumentis:>{`zcat?`kpsewhich-nlatextex#1`}>whichincantationcausesthekpsewhichprogramto ndthe le,Wbysearching>along4L5ffA͉TU>'ExX'spath,Ŭandthenpassthefullpathnametothezcatprogramso>thatK[itcanuncompressthe le.ntAnysuchusesareverysystemdepGendent,MZand>wouldtbGestbeplacedinagraphics.cfg le,{thuskeepingthedoGcumentitself>pGortable.>color push Black14Y color popy>color push BlackY color pop?>4.6\Globalsettingofkeys獑>MostvofthekeyvalkeysusedinthegraphicxpackqagemayalsobGesetusingthe >commandUU\setkeysprovidedbythekeyvalpackqage. >F*orinstance, suppGoseyouwantedallthe lestobGeincludedinthecurrentdoGc->umentYtobGescaledto75%ofthewidthofthelinesoftext,Ythenonecouldissue>theUUfollowingcommand:>\setkeys{Gin}{width=0.75\textwidth}>Here}`Gin'isthenameusedforthekeyvalkeysassoGciatedwith`Graphicsin->clusion'.TAll following\includegraphicscommands(withinthesamegroup>ornSenvironment)willactasif[width=0.75\textwidth]hadbGeenspeci ed,tin>additionUUtoanyotherkeysettingsactuallygivenintheoptionalargument.>Similarlyitomakeall\rotateboxargumentstakeanargumentinradians,none>justUUneedstospGecify:>\setkeys{Grot}{units=6.28318}P_>4.7\Compatibilityb`etweengraphicsandgraphicx獑>F*oradoGcumentauthor,0therearenotreallyanyproblemsofcompatibilitybGe->tween_\thetwo_\packqages.Y*oujustchoGosetheinterfacethatyoupGersonallyprefer,>andUUthenusetheappropriatepackqage.>F*or$apackqageorclasswriterthesituationisslightlydi erent.vSuppGosethat>youOarewritingaletterclassthatneedstoprintacompanylogoaspartofthe>letterhead.>AsStheauthoroftheclassyoumaywanttogivetheusersthepGossibilityofusing>eithereinterfaceintheirletters(shouldtheyneedtoincludeanyfurthergraphics>intotheletterbGody).3Inthiscasetheclassshouldloadthegraphicspackqage(not>graphicx,$as(thiswouldcommitanyusersoftheclasstothekeyvalinterface).>ThelogoshouldbGeincludedwith\includegraphicseitherwithno?optional>argumentF(ifthecorrectsizeinformationisinthe le)orb}'oth Boptionalarguments>otherwise.̜Dosnotusetheone3optionalargumentform,{.asthemeaningofthis>argumentwouldchange(andgenerateerrors)iftheuserweretoloadgraphicx>asUUwellasyourclass.$c퍍>5VLRemainingffpackagesinthegraphicsbundle>5.1\Eps g獑>Thisisasmallpackqageessentiallya`wrappGer'aroundthegraphicxpackqage,>de ningUUacommand\psfigwhichhasthesyntax>\psfig{file=xxx,...}UUratherthan\includegraphics[...]{xxx}.>ItFalsohasafewmorecommandstomakeitslightlymorecompatiblewiththe>oldUUL5ffA͉TU>'ExX2.09styleofthesamename.>color push Black15Y color pop&y>color push BlackY color pop?>5.2\TriguT>ThetrigpackqageisnotintendedtobGeuseddirectlyindocuments.TItcalculates >sine,4cosineandtangenttrigonometricfunctions.bTheseareusedtocalculate>thespacetakenupbyarotatedbGox.GThispackqageisalsousedbythefontinst>programUUwhichconvertsPostScript lestoaformusablebyTU>'ExX.>AswellasbGeingusedasaL5ffA͉TU>'ExXpackqage,themacrosmaybGeextractedwiththe>doGcstripoptionsplain,package.*InthiscasetheL5ffA͉TU>'ExXpackqagedeclarationsare>omittedfromthe le,CandthemacrosmaybGedirectlyusedaspartofanother>macroUU le(theyworkwithanyformatbasedonplainTU>'ExX.)!6>5.3\Keyv@al>ThekeyvalpackqageisintendedtobGeusedbyotherpackqages. Itprovidesa>genericwayofsetting`keys'asusedbythegraphicxpackqage,andsplittingup>theUUcommaseparatedlistsofhkey}ibv=hvalue[i%mղpairs.>Likew:thetrigDzpackqage,thesemacrosmaybGeextractedandusedaspartofanother>macro% le,/0basedonplainTU>'ExX,aswellasthestandarduseasaL5ffA͉TU>'ExXpackqage.!6>5.4\Pstcol>PST*ricks,ɻbyTimothyV*anZandtisanimmenselypGowerfulpackqagethatenables>aփveryfullfeaturedinterfacebGetweenPostScriptandTU>'ExX.QUnfortunatelythe>colour\suppGortinPST*ricksisslightlyincompatiblewiththecolourmechanism>de nedinthecolor;packqage.,Thepstcolpackageisa(hopGefullytemporary)>packqage*thatmoGdi esaverysmallnumbGerofinternalPST*ricksfunctions,Lto>removegIthisincompatibility*.If.fpstricksisloadedviathispackqage,kyoumayuse>any=_coloursde nedby`colorpackqage=_commandswithinpstrickscommands,B*and>viceUUversa.!6>5.5\Lscap`e>ThelscapGepackqagerequiresandtakesthesameoptionsasthegraphicspack->age.Ita]de nesalandscapeenvironmenta]withinwhichpagebGodiesa]arerotated>throughg90degrees.6ThepageheadandfoGotarenota ected,,theyappearin>theUUstandard(pGortrait)position.>color push Black16Y color popՊ;y (kAH cmssbx10'ow cmss9&kAH cmssbx10%#fcmti8$Cscmtt8#j cmti9" cmsy9 N cmbx12': cmti10ߤN cmtt9o cmr9 cmmi10K`y cmr10ٓRcmr7