; }5Gc@s(dklZdkZdkZdklZlZlZlZl Z l Z l Z l Z dkl ZeZyegWnej odZnXyegWnej odZnXdfdYZhZdZd Zd efd YZeeeid efd YZeeeidZdZdZdZdZdZdefdYZ de fdYZ!de fdYZ"de"fdYZ#de fdYZ$defdYZ%d e fd!YZ d"e fd#YZ&d$efd%YZ'd&efd'YZ(d(efd)YZ)ee)d*d+d,d-d.d/gd0efd1YZ*d2efd3YZ+d4e+fd5YZ,d6efd7YZ-ee-e-id8e"efd9YZ.d:efd;YZ/dS(<(s nested_scopesN(sattrsdecosstylescolorsunitscanvasspathsmesh(stextcCstd|dSdS(NcCs||S(N(sxsy(sxsy((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys&si(sreduceslist(slist((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pyssum%scCsttt||SdS(N(szipsxrangeslenslist(slist((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys enumerate,ss_stylecBsYtZdZgZgZdZdZdZdZdZ dZ dZ RS(sInterface class for graph styles Each graph style must support the methods described in this class. However, since a graph style might not need to perform actions on all the various events, it does not need to overwrite all methods of this base class (e.g. this class is not an abstract class in any respect). A style should never store private data by istance variables (i.e. accessing self), but it should use the sharedata and privatedata instances instead. A style instance can be used multiple times with different sharedata and privatedata instances at the very same time. The sharedata and privatedata instances act as data containers and sharedata allows for sharing information across several styles. Every style contains two class variables, which are not to be modified: - providesdata is a list of variable names a style offers via the sharedata instance. This list is used to determine whether all needs of subsequent styles are fullfilled. Otherwise getdefaultprovider should return a proper style to be used. - needsdata is a list of variable names the style needs to access in the sharedata instance. cCsgSdS(sSet column information This method is used setup the column name information to be accessible to the style later on. The style should analyse the list of column names. The method should return a list of column names which the style will make use of.N((sselfs privatedatas sharedatasgraphs columnnames((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys columnnamesLscCsdS(sAdjust axis range This method is called in order to adjust the axis range to the provided data. columnname is the column name (each style is subsequently called for all column names).N((sselfs privatedatas sharedatasgraphs columnnamesdata((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys adjustaxisUscCsdS(sSelect stroke/fill attributes This method is called to allow for the selection of changable attributes of a style.N((sselfs privatedatas sharedatasgraphs selectindexs selecttotal((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys selectstyle]scCsdS(s`Initialize drawing of data This method might be used to initialize the drawing of data.N((sselfs privatedatas sharedatasgraph((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysinitdrawpointsdscCsdS(sDraw data This method is called for each data point. The data is available in the dictionary point. The dictionary keys are the column names.N((sselfs privatedatas sharedatasgraphspoint((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys drawpointjscCsdS(sFinalize drawing of data This method is called after the last data point was drawn using the drawpoint method above.N((sselfs privatedatas sharedatasgraph((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysdonedrawpointsrscCsdS(sDraw graph keyN((sselfs privatedatas sharedatasgraphsx_ptsy_ptswidth_pts height_pt((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pyskey_ptys( s__name__s __module__s__doc__s providesdatas needsdatas columnnamess adjustaxiss selectstylesinitdrawpointss drawpointsdonedrawpointsskey_pt(((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys_style/s      cCs9x2|D]*}||ijp td|t|s[U  c CsVxO|iD]D\}}}}y||i@o&|i||d|i |d|i|i\}}|i |i |||i |indS(N( s sharedatas vposvalids privatedatas symbolattrssNonesgraphsvpos_ptsvpossx_ptsy_ptssymbols symbolcanvasssize_pt(sselfs privatedatas sharedatasgraphspointsx_ptsy_pt((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys drawpointscCs|i|idS(N(sgraphsinserts privatedatas symbolcanvas(sselfs privatedatas sharedatasgraph((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysdonedrawpointsscCsG|itj o3|i||d||d||i |indS(Nf0.5( s privatedatas symbolattrssNonessymbolsgraphsx_ptswidth_ptsy_pts height_ptssize_pt(sselfs privatedatas sharedatasgraphsx_ptsy_ptswidth_pts height_pt((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pyskey_pts()s__name__s __module__s needsdatasattrs changelists _crosssymbolscrosss _plussymbolspluss _squaresymbolssquares_trianglesymbolstriangles _circlesymbolscircles_diamondsymbolsdiamonds changecrosss changepluss changesquareschangetriangles changecircles changediamondschangesquaretwiceschangetriangletwiceschangecircletwiceschangediamondtwicesdecosstrokedsfilledschangestrokedfilledschangefilledstrokedsdefaultsymbolattrssunitsv_cms__init__s selectstylesinitdrawpointss drawpointsdonedrawpointsskey_pt(((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pyssymbols4 !!!!!!''''     s_linecBs5tZdZdZdZdZdZRS(NcCs%ti|_g|_t|_dS(N(spaths privatedataslinebasepointssNoneslastvpos(sselfs privatedata((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysinitpointstopaths cCst|idjo~|iiti|idt|idjo$|iiti|idq|iiti|idng|_dS(Niii(slens privatedataslinebasepointsspathsappends moveto_ptsmultilineto_pts lineto_pt(sselfs privatedata((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysaddpointstopaths  $$cCs||oAt|iob|o|ii||q:d}x't |i |D]\} }t }|djo7yd| || }Wqttfj oPqXn|djo4y| || }Wqttfj oPqXn|t j o ||jo |}qQqQWg}x9t |i |D]%\} }|i| || |q)W|ii|||i|n|i t j o|oJd}xt |i |D]\} }t }| djo7yd| || }Wqttfj oPqXn| djo4y| || }Wq@ttfj oPq@Xn|t j o ||jo |}qqWg}x9t |i |D]%\} }|i| || |qW|ii|||ii||q:d} d} xQt |i |D]\} }t }| djoI|djoPnyd| || }Wqattfj oPqaXn| djoF|djoPny| || }Wqttfj oPqXn|t j o || jo |} nt } |djo7yd| || } Wq"ttfj oPq"Xn|djo4y| || } Wqcttfj oPqcXn| t j o | | jo | } qqW| | jog}g} xRt |i |D]>\} }|i| || | | i| || | qW|ii|||ii|| |i|q:n||_ n1t|idjo|i|nt |_ dS(Nii(s vposavailableslens privatedataslinebasepointss vposvalidsappends graphvpos_ptsvposscutszipslastvpossvstartsvendsNonesnewcutsArithmeticErrors TypeErrorscutvpossselfsaddpointstopathscutfromscuttos newcutfromsnewcuttos cutfromvposs cuttovpos(sselfs privatedatas graphvpos_pts vposavailables vposvalidsvpossnewcutsvendscutsnewcuttosvstartscutfroms cuttovposscuttoscutvposs newcutfroms cutfromvpos((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysaddpoints                          cCs4t|idjo|i|nt|_dS(Ni(slens privatedataslinebasepointssselfsaddpointstopathsNoneslastvpos(sselfs privatedata((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys addinvalidcscCs2t|idjo|i|n|iSdS(Ni(slens privatedataslinebasepointssselfsaddpointstopathspath(sselfs privatedata((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysdonepointstopathhs(s__name__s __module__sinitpointstopathsaddpointstopathsaddpoints addinvalidsdonepointstopath(((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys_lines   s slinecBstZddddgZeieiieiieii eii gZ e gZ gdZ dZdZdZd Zd ZRS( Nsvposs vposmissings vposavailables vposvalidcCs ||_dS(N(s lineattrssself(sselfs lineattrs((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys__init__yscCsC|itj o&ti|i|i|||_n t|_dS(N( sselfs lineattrssNonesattrs selectattrssdefaultlineattrss selectindexs selecttotals privatedata(sselfs privatedatas sharedatasgraphs selectindexs selecttotal((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys selectstyle|s&cCs|i|dS(N(sselfsinitpointstopaths privatedata(sselfs privatedatas sharedatasgraph((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysinitdrawpointsscCs)|i||i|i|i|idS(N( sselfsaddpoints privatedatasgraphsvpos_pts sharedatas vposavailables vposvalidsvpos(sselfs privatedatas sharedatasgraphspoint((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys drawpointscCsG|i|}|itj o t|o|i||indS(N( sselfsdonepointstopaths privatedataspaths lineattrssNoneslensgraphsstroke(sselfs privatedatas sharedatasgraphspath((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysdonedrawpointsscCsQ|itj o=|iti||d||||d||indS(Nf0.5( s privatedatas lineattrssNonesgraphsstrokespathsline_ptsx_ptsy_pts height_ptswidth_pt(sselfs privatedatas sharedatasgraphsx_ptsy_ptswidth_pts height_pt((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pyskey_pts(s__name__s __module__s needsdatasattrs changelistsstyles linestylessolidsdashedsdotteds dashdottedschangelinestylesdefaultlineattrss__init__s selectstylesinitdrawpointss drawpointsdonedrawpointsskey_pt(((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pyslinens3      simpulsescBsztZdddddgZeigZgZgdgddZd Zd Z d Z d Z d Z dZ RS(Nsvposs vposmissings vposavailables vposvalidsposcolumnnamesiicCs(||_||_||_||_dS(N(s lineattrssselfs fromvalues frompathattrssvalueaxisindex(sselfs lineattrss fromvalues frompathattrssvalueaxisindex((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys__init__s   cCsR|dj|_|itj o&ti|i|i|||_n t|_dS(Ni( s selectindexs privatedatasinsertfrompathsselfs lineattrssNonesattrs selectattrssdefaultlineattrss selecttotal(sselfs privatedatas sharedatasgraphs selectindexs selecttotal((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys selectstyles&cCsy|itj oey|ii|}Wntj oquX||i jo%|i |i|i |igqundS(N( sselfs fromvaluesNones sharedatasposcolumnnamessindexs columnnamesis ValueErrorsvalueaxisindexsgraphsaxess adjustaxis(sselfs privatedatas sharedatasgraphs columnnamesdatasi((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys adjustaxisscCsti|_|itj o|i|i}|i |i |i|_ d|_|i djo d|_ n|i djo d|_ n|itj o|io1|i|i |i|i |i|iqn d|_ dS(Nii(scanvass privatedatasimpulsescanvassselfs fromvaluesNones sharedatasposcolumnnamessvalueaxisindexs valueaxisnamesgraphsaxessconverts vfromvalues vfromvaluecuts frompathattrssinsertfrompathsstrokes vgridpathsdefaultfrompathattrs(sselfs privatedatas sharedatasgraphs valueaxisname((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysinitdrawpointss   cCsb|io |itj oD|i}|i||i<|i i |i ||i|indS(N( s sharedatas vposvalids privatedatas lineattrssNonesvposs vfromvaluesselfsvalueaxisindexsimpulsescanvassstrokesgraphs vgeodesic(sselfs privatedatas sharedatasgraphspointsvpos((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys drawpoints cCs|i|idS(N(sgraphsinserts privatedatasimpulsescanvas(sselfs privatedatas sharedatasgraph((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysdonedrawpointsscCsQ|itj o=|iti||d||||d||indS(Nf0.5( s privatedatas lineattrssNonesgraphsstrokespathsline_ptsx_ptsy_pts height_ptswidth_pt(sselfs privatedatas sharedatasgraphsx_ptsy_ptswidth_pts height_pt((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pyskey_pts(s__name__s __module__s needsdataslineschangelinestylesdefaultlineattrssdefaultfrompathattrss__init__s selectstyles adjustaxissinitdrawpointss drawpointsdonedrawpointsskey_pt(((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysimpulsess     serrorbarcBsotZdddddddgZgZdeigd d Zd Zd Zd Z dZ dZ RS(Nsvposs vposmissings vposavailables vposvalidsvrangesvrangeminmissingsvrangemaxmissingf0.10000000000000001f1e-10cCs||_||_||_dS(N(ssizesselfs errorbarattrssepsilon(sselfssizes errorbarattrssepsilon((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys__init__s  cCsLxA|iD]6}||ijo ||ijotdq q WgSdS(Ns0position and range for a graph dimension missing(s sharedatas vposmissingsisvrangeminmissingsvrangemaxmissings ValueError(sselfs privatedatas sharedatasgraphs columnnamessi((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys columnnamess   cCsJtiti|i|||_ ti |i |i |||_ dS(N( sunitstoptsattrs selectattrsselfssizes selectindexs selecttotals privatedatas errorsize_pts selectattrssdefaulterrorbarattrss errorbarattrs(sselfs privatedatas sharedatasgraphs selectindexs selecttotal((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys selectstyles$cCsK|itj o7ti|i|_ttt|i |_ ndS(N( s privatedatas errorbarattrssNonescanvasserrorbarcanvasslistsxrangeslens sharedatasvposs dimensionlist(sselfs privatedatas sharedatasgraph((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysinitdrawpointssc Cs|itj ox|iD]}x|iD]_}||joD|i|tjp0|i||i jp|i|d|i joPq*q*W|i |dtjo|i|tjpY|i |dtjo|i|tjp-|i |dtjo|i |dtjoqn|i} |i |dtj o|i |d| ||djo1| tj o$| djo|tj o |djo|djo d}n|djo d}n| djo d} n|djo d}n|i|| || }|i |i || |||i |i |||||i |i |||| |i t i |ii||ii|dgndS(Niiscolor(s sharedatasvrangesxvminsxvmaxsyvminsyvmaxsNonesgraphs vgeodesicspsappends vgeodesic_elspaths closepaths privatedatas rectcanvassfillsselfsgradientsgetcolorspoint( sselfs privatedatas sharedatasgraphspointspsxvminsyvmaxsxvmaxsyvmin((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys drawpoints&h        cCstddS(Ns+Style currently doesn't provide a graph key(s RuntimeError(sselfs privatedatas sharedatasgraphsx_ptsy_ptswidth_pts height_pt((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pyskey_pts( s__name__s __module__s needsdatascolorsgradientsGreys__init__s columnnamessinitdrawpointss drawpointskey_pt(((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysrects   s histogramc BstZdddddgZeigZgZgddgdddddd Zd Zd Z d Z d Z dZ dZ dZdZdZdZdZRS(Nsvposs vposmissingsvrangesvrangeminmissingsvrangemaxmissingif0.5f1e-10c CsU||_||_||_||_||_||_||_||_| |_ dS(N( s lineattrssselfsstepss fromvalues frompathattrssfillablesrectkeysautohistogramaxisindexsautohistogrampointpossepsilon( sselfs lineattrssstepss fromvalues frompathattrssfillablesrectkeysautohistogramaxisindexsautohistogrampointpossepsilon((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys__init__s        cCst|idjotdnt|_xtt|iD]s}||i jp ||i jo$||i jot dqqE|itj ot dn||_qEW|itjo|i|_d|_n d|_gSdS(Nis4histogram style restricted on two-dimensional graphsspos and range missingsmultiple rangesii(slensgraphs axesnamess TypeErrorsNones privatedatasrangeaxisindexs builtinrangesis sharedatasvrangeminmissingsvrangemaxmissings vposmissings ValueErrorsselfsautohistogramaxisindexs autohistogram(sselfs privatedatas sharedatasgraphs columnnamessi((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys columnnamess       c Cs|io||i|ijot|djotdn|o^|d|d}|d|i |}|dd|i |}|i|i||gqnJ|itj o||id|ijo|i|i|igndS(NisDseveral data points needed for automatic histogram width calculationii(s privatedatas autohistograms columnnames sharedatasposcolumnnamessrangeaxisindexslensdatas ValueErrorsdeltasselfsautohistogrampointpossminsmaxsgraphsaxess adjustaxiss fromvaluesNone( sselfs privatedatas sharedatasgraphs columnnamesdatasmaxsminsdelta((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys adjustaxiss!"+cCsR|dj|_|itj o&ti|i|i|||_n t|_dS(Ni( s selectindexs privatedatasinsertfrompathsselfs lineattrssNonesattrs selectattrssdefaultlineattrss selecttotal(sselfs privatedatas sharedatasgraphs selectindexs selecttotal((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys selectstyles&cCs|i |jod|ijno&|i |jod|ijno\|io)|iiti|i ||q|iiti|i ||ndS(Ni( sselfsepsilonsvpossvvalues privatedatasrangeaxisindexspathsappends moveto_ptsgraphsvpos_pt(sselfs privatedatas sharedatasgraphsvpossvvalue((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysvmoveto sR )c Cs|i |jod|ijno_d}|djod}d}n|djod}d}nd}|djod}d}n|djod}d}nt||djo|o|i o\|i o)|i i t i |i||q.|i i t i |i||n|i o&|i i |i||||q|i i |i||||qndS(Niii(sselfsepsilonsvposs vvalue1cutsvvalue1s vvalue2cutsvvalue2sabssfillables privatedatasrangeaxisindexspathsappends moveto_ptsgraphsvpos_pts vgeodesic_el( sselfs privatedatas sharedatasgraphsvpossvvalue1svvalue2s vvalue2cuts vvalue1cut((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysvposlines.)         )) &c Cs|ioW||i jod}tidn|d|ijod}tidqan|ip&|i |jod|ijnod}|djod}d}n|djod}d}nd}|djod}d}n|djod}d}nt ||djo|o|io|i oQ|i it i|i|i||i i|i|i|||q@|i it i|i||i|i i|i||i||qD|i o)|i it i|i||qD|i it i|i||n|i o&|i i|i||||n#|i i|i|||||io|oitid|i o)|i i|i|||i|q|i i|i||||iqqndS(NisKcut at graph boundary adds artificial lines to fillable step histogram pathii(sselfsfillablesvvaluesepsilonswarningsswarnsvpos1cutsvpos1svpos2cutsvpos2sabss privatedatasrangeaxisindexspathsappends moveto_ptsgraphsvpos_pts vfromvalues vgeodesic_el( sselfs privatedatas sharedatasgraphsvvaluesvpos1svpos2svpos2cutsvpos1cut((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys vvalueline+sR 3          ()() )) &"  )cCs |tj o|tj o |tj }|io|i od| odSnd} ||i jod}d} n%|d|i jod}d} nd}||i jod}d}n|d|i jod}d}nd} ||i jod}d} n|d|i jod}d} nd} t | t |t | t |idjoLt | |djpt | |idjo d} qtidn,| oFd} |io|iiti|i|i||ii|i|i||i||ii|i|i||||ii|i||||q|iiti|i||i|ii|i||i||i|ii|i||i|||ii|i||||n|o@d} |io|iiti|i|||ii|i|||||ii|i|||i||ii|i|i||i|q|iiti|i|||ii|i|||||ii|i||||i|ii|i||i||in|io@d} |io|iiti|i|i||ii|i|i||||ii|i|||||ii|i|||i|q|iiti|i||i|ii|i||i|||ii|i|||||ii|i||||inN| oFd} |io|iiti|i|||ii|i|||i||ii|i|i||i||ii|i|i|||q|iiti|i|||ii|i||||i|ii|i||i||i|ii|i||i||n| o|io|iiti|i|i||ii|i|i||i||ii|i|i||||ii|i|||||ii|i|||i||iitiq|iiti|i||i|ii|i||i||i|ii|i||i|||ii|i|||||ii|i||||i|iitiq ny t ||i|i j} Wn"tttfj o d} nX|i tj o8|o1| o)|ip|i |i||idjo#|i!|||||i |n|i tj o|o-t |i |it ||ij} n|i tj o| p | p| oM|i!||||i|i |i|o|i$|||||q n|o|i tjp | p| o?|i$|||||i|i!|||||i|n|o2|i%||||||||_ ||_nt|_ |_dS(NiiisYmultiple cuts at graph boundary add artificial lines to fillable rectangle histogram path(&svminsNonesvmaxsvvalues currentvalidsselfsfillablesstepssvmincutsepsilonsvmaxcuts vvaluecutsdonesabss privatedatas vfromvaluecutswarningsswarnsrangeaxisindexspathsappends moveto_ptsgraphsvpos_pts vfromvalues vgeodesic_els closepathslastvmaxsgapsArithmeticErrors ValueErrors TypeErrors lastvvaluesvposlines sharedatas currentbiggersvmovetos vvalueline(sselfs privatedatas sharedatasgraphsvminsvmaxsvvaluesvmaxcuts currentvalids currentbiggers vvaluecutsdonesgapsvmincut((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys drawvalue[s&      41  ((%&((%& %"%,%"%,  (%")(%") %%()%%() ((%"%((%"%  K-'%    cCs"ti|_t|_|_t|_d|_|itj o|i d|i }|i|i|i|_d|_|idjod|_d|_n|idjod|_d|_n|itj o|io1|i|i|i|i|i|iqn d|_dS(Niii(spaths privatedatasNones lastvvalueslastvmaxs vcurrentpointscountsselfs fromvalues sharedatasposcolumnnamessrangeaxisindexs valueaxisnamesgraphsaxessconverts vfromvalues vfromvaluecuts frompathattrssinsertfrompathsstrokes vgridpathsdefaultfrompathattrs(sselfs privatedatas sharedatasgraphs valueaxisname((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysinitdrawpointss$       cCs|io]|id7_|idjo|iop|id|id|_|i ||||id|i |i|idd|i |i|idq|id|id|_|i ||||id|i |i|idd|i |i|idn|idjoo|io|id|id}n|id|id}t |i||i jotdqn|idjo|ioU|i ||||id|i |i|idd|i |i|idqV|i ||||id|i |i|idd|i |i|idn|i|_n|io=|i ||||idd|idd|idn:|i ||||idd|idd|iddS(NiiisIequal steps (in graph coordinates) needed for automatic width calculation(s privatedatas autohistogramscountsrangeaxisindexs sharedatasvposslastvpossvrangesselfs drawvaluesgraphsautohistogrampointpossabssepsilons ValueError(sselfs privatedatas sharedatasgraphspointsvrange((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys drawpointsH     .cCsZ|i|||ttt|itj o t|io|i |i|indS(N( sselfs drawvalues privatedatas sharedatasgraphsNones lineattrsslenspathsdraw(sselfs privatedatas sharedatasgraph((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysdonedrawpointss c Cs}|itj oi|ioti||||}n-ti ||d||||d|}|i||indS(Nf0.5(s privatedatas lineattrssNonesselfsrectkeyspathsrect_ptsx_ptsy_ptswidth_pts height_ptspsline_ptsgraphsdraw( sselfs privatedatas sharedatasgraphsx_ptsy_ptswidth_pts height_ptsp((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pyskey_pts  ,(s__name__s __module__s needsdatasdecosstrokedsdefaultlineattrssdefaultfrompathattrss__init__s columnnamess adjustaxiss selectstylesvmovetosvposlines vvaluelines drawvaluesinitdrawpointss drawpointsdonedrawpointsskey_pt(((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys histograms $     0 ~  , sbarposc BsztZddddddddd d g ZgZegd d Zd ZdZdZdZ dZ dZ RS(Nsvposs vposmissings vposavailables vposvalids vbarrangesbarposcolumnnamess barvalueindexs lastbarvalues stackedbarsstackedbardrawf1e-10cCs||_||_||_dS(N(s fromvaluesselfs frompathattrssepsilon(sselfs fromvalues frompathattrssepsilon((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys__init__.s  c Cs9g|_t|_xt|iD]\}}d}x|D]}||joG|itj ot dn||_|ii ||d7}n|d|jo"|ii |d|d7}n|djot dq;q;W| ot dq"q"W|itjot dng|_|iSdS(Nismultiple valuesisnamesmultiple names and valuesvalue/name missings missing value(s sharedatasbarposcolumnnamessNones barvalueindexs enumeratesgraphs axesnamess dimensions axisnamessfoundsaxisnames columnnamess ValueErrorsappends vposmissing( sselfs privatedatas sharedatasgraphs columnnamessaxisnames dimensions axisnamessfound((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys columnnames3s0       cCsZy |dWn=y"|d|i|d|fSWqV||fSqVXn X||fSdS(Nsii(svaluesselfs addsubvaluessubvalue(sselfsvaluessubvalue((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys addsubvalueKs "c Cs,y|ii|}Wntj onX||ijoT|it j o%|i |i|i |ign|i |i|i |n|i |i|d i gi}|D]}||i|dq~|i |i|d i gi}|D]}||i|dq~dS(Niii(s sharedatasbarposcolumnnamessindexs columnnamesis ValueErrors barvalueindexsselfs fromvaluesNonesgraphsaxess adjustaxissdatasappends_[1]sxs addsubvalue( sselfs privatedatas sharedatasgraphs columnnamesdatasis_[1]sx((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys adjustaxisVs%LcCs|dj|_dS(Ni(s selectindexs privatedatasinsertfrompath(sselfs privatedatas sharedatasgraphs selectindexs selecttotal((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys selectstyledscCs[tgt|i|_gi}|iD]7}|gi}t dD]}|tqG~q*~|_ d|_ |_ |itj o|i|i|idi|i|_|idjo d|_n|idjo d|_n|itj o|io?|i|i|i|idi|i|i|iqWn d|_dS(Niii(sNoneslens sharedatasbarposcolumnnamessvpossappends_[1]sxs_[2]sxrangesis vbarranges stackedbarsstackedbardrawsselfs fromvaluesgraphsaxess barvalueindexsconverts privatedatas vfromvalues frompathattrssinsertfrompathsstrokes vgridpathsdefaultfrompathattrs(sselfs privatedatas sharedatasgraphs_[1]sis_[2]sx((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysinitdrawpointsgsT*  *c Csd|_|_xt|iD]\}}||ijo|i |i |d<|||_ y3|i|i|i |i|<|i |d|djo1| tj o$| djo|tj o |djo|djo d}n|djo d}n| djo d} n|djo d}n|i|| || }|i |i || |||i |i |||||i |i |||| |i t i |i||n|i|tdS(Nii(s sharedatas vbarrangesxvminsxvmaxsyvminsyvmaxsNonesgraphs vgeodesicspsappends vgeodesic_elspaths closepathsselfs drawpointfills privatedata( sselfs privatedatas sharedatasgraphspointspsxvminsyvmaxsxvmaxsyvmin((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys drawpoints<  h        c Cs[|i}|id} |iti|||t | ||t | ||idS(Ni(s privatedatas stackedbars selectindexs sharedatas selecttotalsgraphsfillspathsrect_ptsx_ptswidth_ptsfloatsy_pts height_ptsbarattrs( sselfs privatedatas sharedatasgraphsx_ptsy_ptswidth_pts height_pts selectindexs selecttotal((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pyskey_pts  (s__name__s __module__s needsdatascolorsgradientsRainbowsdecosstrokedsgreysblacksdefaultbarattrss__init__s columnnamess selectstylesinitdrawpointss drawpointfills drawpointskey_pt(((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysbars $      $s changebarcBs5tZdZdZdZdZdZRS(NcCs!|djotdndS(NislChangebar can't change its appearance. Thus you can't use it to plot several bars side by side on a subaxis.(s selecttotals RuntimeError(sselfs privatedatas sharedatasgraphs selectindexs selecttotal((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys selectstyle s cCs#ti||||g|_dS(N(sbarsinitdrawpointssselfs privatedatas sharedatasgraphsbars(sselfs privatedatas sharedatasgraph((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysinitdrawpointsscCs|ii|dS(N(s privatedatasbarssappendsp(sselfs privatedatasp((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys drawpointfillscCspt|i}xZt|iD]I\}}|o6ti|i |i ||}|i i ||qqWdS(N(slens privatedatasbarss selecttotals enumerates selectindexspsattrs selectattrssselfsdefaultbarattrssbarattrss rectcanvassfill(sselfs privatedatas sharedatasgraphs selecttotalsps selectindexsbarattrs((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysdonedrawpointss  cCstddS(Ns+Style currently doesn't provide a graph key(s RuntimeError(sselfs privatedatas sharedatasgraphsx_ptsy_ptswidth_pts height_pt((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pyskey_pts(s__name__s __module__s selectstylesinitdrawpointss drawpointfillsdonedrawpointsskey_pt(((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys changebars     sgridposcBsVtZddddgZddddd d gZd d d dZdZdZRS(Nsvposs vposmissings vposavailables vposvalidsvalues1svalues2sdata12sdata21sindex1sindex2iif1e-10cCs||_||_||_dS(N(sindex1sselfsindex2sepsilon(sselfsindex1sindex2sepsilon((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pys__init__%s  cCs@|i|_|i|_h|_h|_h|_h|_dS(N(sselfsindex1s sharedatasindex2svalues1svalues2sdata12sdata21(sselfs privatedatas sharedatasgraph((sC/mnt/gmirror/ports/graphics/py-PyX/work/PyX-0.10/pyx/graph/style.pysinitdrawpoints*s      cCs|io|i|i|_|i|i|_|ii |i okxh|ii D]C}||i |ijo||i jno||_PqWqWWd|i|i}|.|'}8}5|.|,}} |.|+}}};}iYtj o||iZ|!|"|%djoiY}4}>}niYtj o||iZ|#|!|%djoiY}8}3}niYtj o||iZ|"|$|%djoiY}}};niYtj o||iZ|$|#|%djoiY} }5}q'n|i |%}i[||iZ|!|"|%|}4}>}i[||iZ|#|!|%|}8}3}i[||iZ|"|$|%|}}};i[||iZ|$|#|%|} }5}x\|@D]T\}}2|2djoE|it\i]t\i^|0|f|4t\i^|?|f|>t\i^||f|fi3tj oi5o|it\i]t\i^|i8|*i3t\i^|i8|"i3t\i^|i8|!i3f|it\i]t\i^|i8|*i3t\i^|i8|"i3t\i^|i8|Ai3fq q.|2djoE|it\i]t\i^| |7f|8t\i^|0|f|3t\i^||f|fi3tj oi4o|it\i]t\i^|i8|*i3t\i^|i8|#i3t\i^|i8|!i3f|it\i]t\i^|i8|*i3t\i^|i8|#i3t\i^|i8|&i3fq q.|2djoE|it\i]t\i^|?|f|t\i^||:f|t\i^||f|;fi3tj oi4o|it\i]t\i^|i8|Ai3t\i^|i8|$i3t\i^|i8|"i3f|it\i]t\i^|i8|Ai3t\i^|i8|$i3t\i^|i8|1i3fq q.|2djoE|it\i]t\i^||:f| t\i^| |7f|5t\i^||f|fi3tj oi5o|it\i]t\i^|i8|&i3t\i^|i8|$i3t\i^|i8|#i3f|it\i]t\i^|i8|&i3t\i^|i8|$i3t\i^|i8|1i3fq q.q.WqWqWt\i\|d d}6|i`|6dS( Nif0.5iiiisRsurface elements partially outside of the graph are (currently) skipped completelycCs|}|}xotdD]a}||joN||||||||||||||f\||<||