+
    	iv                         R t ^ RIHtHtHtHtHtHtHt ^RI	H
t
 ^RIHt ^RIHt ^RIHt ^RIHtHt RtR tR tR	 tR
 tRR ltR tR tRR ltR tR tR# )zDraw borders.)ceilcosfloorpisinsqrttan)boxes)replaced)
percentage)Matrix)	get_colorstyled_colorc           
        VP                   R,          ^ ,          R8X  g   VP                  f   R# VP                  4       w  r#rErgr\        W#R7      p
WP                  ,          p
V P                  W#WEVP                   R,          4      p\        WVP                  VP                   R,          VP                   R,          VP                   R,          VP                   R	,          4       R# )
z5Set ``box`` mask border as alpha state on ``stream``.mask_border_sourcenoneNefmask_border_modemask_border_slicemask_border_repeatmask_border_outsetmask_border_width)stylemask_border_imagerounded_border_boxr   ctmset_alpha_statedraw_border_image)streamboxxywhtltrbrblmatrixmask_streams   &&          \/Users/agent/.openclaw/workspace/venv/lib/python3.14/site-packages/weasyprint/draw/border.pyset_mask_borderr-      s    
yy%&q)V3s7L7L7T!$!7!7!9A!aF
jjF((qSYY?Q5RSK#//;N1O		&'3G)H		%&(    c                2   ^ ^ ^ VP                   R,          3pRpVP                   EFW  pVP                   R,          R8X  d   RpK   V'       d   RpK,  V P                  4       ;_uu_ 4        VP                   R,          pVP                   R,          pVP                   R,          R8X  d   VP                   R	,          pM2\        VP                   R,          VP                   VP                  4      pVP
                  VP                   R,          V,           ^,          ,
          pWP                  WTP                  3p	\        WVR
W4       \        V\        VP                   R4      R
4      p
\        W	W&V
4       RRR4       EKZ  	  R#   + '       g   i     EKp  ; i)z1Draw the column rules to a ``pdf.stream.Stream``.column_rule_widthTcolumn_spanallFcolumn_rule_style
column_gapnormal	font_sizeleftcolumn_rule_colorN)r   childrenstackedr   width
position_x
position_yheightclip_border_segmentr   r   draw_rect_border)r    r!   border_widths	skip_nextchild
rule_width
rule_stylegapr<   
border_boxcolors   &&         r,   draw_column_rulesrI      sE   1cii(;<=MI;;}%.II^^#67J#67Jyy&(2ii, <!8#))SYYO  CII.A$BS$HA#MM #%5%5z<<OJJ
S Icii1DEvOEVER   s   *DFFc                   VP                   R,          R8w  d   R# \        V\        P                  4      ;'       d5    VP                   R,          R8g  ;'       g    VP                   R,          R8g  pV'       dF   VP                   R,          '       d-   V P	                  4       ;_uu_ 4        \        W4       RRR4       VP                   R,          ^ ,          R	8w  d   VP                  e   V P	                  4       ;_uu_ 4        \        WVP                  VP                   R
,          VP                   R,          VP                   R,          VP                   R,          4       RRR4       R# \         Uu. uF  p\        VRV R24      NK  	  pp\        V4      ^ 08X  d   R# \         Uu. uF  p\        VP                   RV R24      NK  	  pp\        \        4       UUu. uF6  w  rcWV,          P                  ;'       d    VP                   RV R2,          NK8  	  ppp\        V4      R0R039   p\        \        V4      4      ^8H  p	^ V9  p
V'       dO   V	'       dG   V
'       d?   V P	                  4       ;_uu_ 4        \        WV^ ,          V^ ,          4       RRR4       R# \!        \#        \        WEV4      4      pR F  pW,          w  r=rV^ 8X  g	   V'       g   K  V P	                  4       ;_uu_ 4        V P%                  4       ;_uu_ 4        \'        WWVP)                  4       R,          WAP)                  4       R,          4       \        WV\+        WV4      4       RRR4       RRR4       K  	  R#   + '       g   i     EL; i  + '       g   i     R# ; iu upi u upi u uppi   + '       g   i     R# ; i  + '       g   i     Lj; i  + '       g   i     EK'  ; i)zADraw the box borders and column rules to a ``pdf.stream.Stream``.
visibilityvisibleNcolumn_widthautocolumn_countr0   border_image_sourcer   border_image_sliceborder_image_repeatborder_image_outsetborder_image_widthborder__width_color_stylesoliddoubleN   N:r\   NN)             )r   
isinstancer	   BlockContainerBoxartifactrI   border_imager   SIDESgetattrsetr   	enumeratealphalendraw_rounded_bordertuplezipr:   r?   r   r   )r    r!   columnssidewidthscolorsistylessimple_stylesingle_color
four_sidesvaluesindexr;   rH   r   s   &&              r,   draw_borderry   8   s    yy)+ 	3//0 	1 	1IIn%/ 0 0IIn%/  399011__f*  yy&'*f49I9I9U__S--syy9M/N		/0#))<Q2R		./1 
 	?DEutgcWTF&12uFE
6{qcGLMuti		WTF&#9:uFM #5)+)IQ 		==CIIvV&<==)  + v;G9xj"99Ls6{#q(L&J__VAYq	B 
 3uff56F$*M!UA:U__ 0 0uC,B,B,DR,H..046  ULt4TU	 !1	 I 
 
 	E N+  !1 0sb   *M6AN
4N*#N#!N(N(>N.7OAO O6N	
N	.N?	OOO'c                  a aaa4a5 SP                  S P                  R,          S P                  R,          4      w  rxp	\        P                  ! WxV	RRS P	                  4       S P                  4       R7      w  o5o4VR,          p
V^,          pR pV! V
^ ,          S44      pV! V
^,          S54      pV! V
^,          S44      pV! V
^,          S54      pVw  ppS P                  4       w  ppppppppS P                  4       w  pppppp p!p"VV,
          p#VV,
          p$VV,
          V#,
          p%VV,
          V$,
          p&R p'V'! V^ ,          V$4      p(V'! V^,          V%4      p)V'! V^,          V&4      p*V'! V^,          V#4      p+VV+,          pVV(,          pVV+V),           ,          pVV(V*,           ,          pR p,V,! V^ ,          V$VV4      p$V,! V^,          V%VV4      p%V,! V^,          V&VV4      p&V,! V^,          V#VV4      p#RV VV4V5V3R	 llp-V-! VVV#V$^ ^ VV4      w  p.p/V-! VV,           V%,
          VV%V$S5V,
          ^ W4       V-! VV,           V%,
          VV,           V&,
          V%V&S5V,
          S4V,
          W4      w  p0p1V-! VVV,           V&,
          V#V&^ S4V,
          VV4       VV,           S58  ;p2'       d~   V-! VV#,           VVV#,
          V%,
          V$V^ S5V,
          V,
          VVR
7	       V-! VV#,           VV,           V&,
          VV#,
          V%,
          V&VS4V,
          S5V,
          V,
          VVR
7	       W,           S48  ;p3'       d~   V-! VV,           V%,
          VV$,           V%VV$,
          V&,
          S5V,
          VVS4V,
          V,
          VR7	       V-! VVV$,           V#VV$,
          V&,
          ^ VVS4V,
          V,
          VR7	       V'       d   V2'       d{   V3'       dq   T-! VV#,           VV$,           VV#,
          V%,
          VV$,
          V&,
          TTS5V,
          V,
          S4V,
          V,
          TTT.;'       g    T0T/;'       g    T1R7       R# R# R# R# )zHDraw ``image`` as a border image for ``box`` on ``stream`` as specified.image_resolutionr6   N)specified_widthspecified_heightdefault_widthdefault_heightr[   c                     \        V \        \        34      '       d   \        W4      # V P                  R 8X  g   Q h\        ^dV P
                  4      ^d,          V,          # )%)ra   intfloatminunitvalue)	dimension	intrinsics   &&r,   compute_slice_dimension2draw_border_image.<locals>.compute_slice_dimension   sK    i#u..y,,>>S(((sIOO,s2Y>>r.   c                     V P                   f   V P                  V,          # V P                   R8X  g   Q hV P                  # )Npx)r   r   )r   from_borders   &&r,   compute_outset_dimension3draw_border_image.<locals>.compute_outset_dimension   s7    >>!??[00>>T)))??"r.   c                     V R 8X  d   V# \        V \        \        34      '       d	   W,          # V P                  R8X  d   V P                  ^d,          V,          # V P                  R8X  g   Q hV P                  # )rN   r   r   )ra   r   r   r   r   )r   originalr   area_dimensions   &&&&r,   compute_width_adjustment3draw_border_image.<locals>.compute_width_adjustment   sf    	C<00''^^s"??S(>99>>T)))??"r.   c                    < ^ SW&39   d   ^ p
M^ pV
'       g   V'       d   V'       d	   W7,          M^p
VR8X  d   \        W&,          V
,          4      pMVR8X  d=   \        W&,          V
,          4      pW*,          W,          ,
          V^,           ,          pMCVR8X  d3   \        ^\        W&,          V
,          4      4      pW-V,          ,          p
M
^pW&,          p
^ SW739   d   ^ pM^ pV'       g   V'       d   V'       d	   W&,          M^pV	R8X  d   \        W7,          V,          4      pMV	R8X  d=   \        W7,          V,          4      pW;,          W,          ,
          V^,           ,          pMCV	R8X  d3   \        ^\        W7,          V,          4      4      pW?V,          ,          pM
^pW7,          p^ W39   d   W3# SV
,          pSV,          pVV,          S,          pVV,          S,          pSP	                  4       ;_uu_ 4        SP                  WW#4       SP                  4        SP                  4        SP                  V V,
          X,           VV,
          X,           R7       SP                  WR7       \        X4       F  p\        X4       F  pSP	                  4       ;_uu_ 4        VWl,           ,          pVW~,           ,          pSP                  VVR7       SP                  VV
,          VV,          Wg4       SP                  4        SP                  4        SP                  SSSSP                  4       RRR4       K  	  K  	  RRR4       W3#   + '       g   i     K  ; i  + '       g   i     Y3# ; i)r`   repeatspaceroundr   )adN)r   r   maxr   r:   	rectangleclipend	transformrangedrawr   )r"   r#   r;   r>   slice_xslice_yslice_widthslice_heightrepeat_xrepeat_yscale_xscale_yextra_dxn_repeats_xextra_dyn_repeats_yrendered_widthrendered_heightoffset_xoffset_yrr   jtranslate_xtranslate_yr!   imageintrinsic_heightintrinsic_widthr    s   &&&&&&&&&&&&            r,   draw_border_image_region3draw_border_image.<locals>.draw_border_image_region   s    %55GH5;60RS8#"5#6#@AW$#E$7'$AB _{'@@[ST_U W$!!U5+>+H%IJ#<=-!688GH38[5.a8#"6#87#BCW$#F$9G$CD %(BB{UVW W$!!U6+@7+J%KL ,$>? /""##(72*W4!G+o="W,/??^^Q51KKMJJLq8|h6!h,:QRw2;'{+A))&';+A&B&'<+B&C((;+(F(($w.70B'7 



6?<LciiX *) , ( &  *)) & s&   B(M++BM<M+M("	M++M=	)r   )r   )r   r   r   r   )stretchr   NN)get_intrinsic_sizer   r
   default_image_sizingborder_widthborder_heightr   rounded_padding_box)6r!   r    r   border_sliceborder_repeatborder_outsetr   r;   r>   ratioimage_sliceshould_fillr   	slice_topslice_rightslice_bottom
slice_leftr   r   r"   r#   r$   r%   r&   r'   r(   r)   r   pypwphptlptrpbrpblborder_left
border_topborder_rightborder_bottomr   
outset_topoutset_rightoutset_bottomoutset_leftr   r   
scale_left	scale_topscale_rightscale_bottomx_middley_middler   r   s6   fff&&&&                                             @@r,   r   r   t   s{    !33		$%syy'=?E5(0(E(EudT&&(9J9J9L)N%O% r"Kq/K? (A8HII)+a./JK*;q>;KLL(QIJ&Hh!$!7!7!9Aq!QBB),)@)@)B&BBCc3q&KaJr6K'LFZ'M# *-*:JGJ+M!,<lKL,]1-=}MM*=+;[IKAOA|	##Am	##A
#" *QY3J+Q{A7L,Qa9M*Qj!5KH  H V 5	1k:q!ZDJ	 	Aaz+%q+B !9	Aa!em3\=+%'7,'F!#K
 	1q5= +}	l*JF +o==x= OQK, >
?Z7+E	*
 	!OQU]2Ol*M(<7j(;6	 +.>>>x> EL !j.!j.=8k)9)I5D	 	!q:~{A
N],Jy*y(<7		
 xH OQ^Q_|-K
N]*J	j(;6y(<7--+y7P7PL	R %-x{r.   Nc           
       a aaa;a<a=a> Vw  rxrT;'       g    Rw  w  rw  rw  ppw  ppT;'       g    ^V3,          w  ppppR pR pRV V3R llo=SR8X  d-   V! WVV4      w  w  pppV! V) VV) V4      w  w  pppTp^p^o;Vo>MSR8X  d8   V! V) VV) V4      w  w  pppV! V) V) V) V) 4      w  w  pppTp^p^o;Wy,           o>MpSR8X  d8   V! VV) VV) 4      w  w  pppV! V) V) V) V) 4      w  w  pppTpRp^o;W,           o>M2SR8X  d,   V! WVV4      w  w  pppV! VV) VV) 4      w  w  pppTpRp^o;Vo>SR9   d   XV^,          ,
          XX,          V^,          ,
          p!p X) V^,          ,
          VX,          V^,          ,
          p#p"V	V,
          V,           p$T	p%S P                  Wy,           S>4       S P                  VS>4       S P                  VV,           S>V,           4       S P                  Wy,           V,           S>V,           4       MSR9   d   X) X,          V^,          ,
          XV^,          ,
          p!p V) X,          V^,          ,
          X) V^,          ,
          p#p"V
V,
          V,           p$T
p%S P                  S>W,           4       S P                  S>V4       S P                  S>V,           VV,           4       S P                  S>V,           W,           V,           4       SR9   Ed   SR8X  d   TM^V,          o<S P                  R
R7       S P                  4        X'       g
   X'       Ed0   V! X X!4      p&V! X"X#4      p'X$V&,           V',           p%\	        V%S<,          4      p(V'       d!   X'       d   V%V(V(^,          ,           ,          o<MV%V(V(^,          ,           R,
          ,          o<\        V&S<^,          ,
          S<,          4      p)\        V'S<^,          ,
          S<,          4      p*\        V$S<,          4      p+V;V<V=V>VV V3R lp,V,! V)V+XWxXXV&4      w  p+p-V,! V*V+V) Wy,           W,           XXV'4      ^ ,          p+V$R8  Ed   \        ^ V+^4       EF  p.V.V-,          p.SR9   dR   VV,           V.S<,          ,           p/VV,           V.^,           S<,          ,           p0S>V^ 8  d   TM^ ,
          p1V1V,           p2MWSR9   dQ   VV,           V.S<,          ,           p1VV,           V.^,           S<,          ,           p2S>V^ 8  d   TM^ ,
          p/V/V,           p0S=! X/X0V/,
          ^,          ,           X1X2V1,
          ^,          ,           V0V/,
          V2V1,
          V^,          4       EK
  	  EM\        X%S<,          ^,          4      p3V3^,           p4SR8X  d&   Vo<V3'       d   V%V4S<,          ,
          V3,          p5M&^ p5M#SR	8X  d   V%V3V4,           ,          ;'       g    ^;p5o<\        V4^,           4       F  p.V.X5S<,           ,          p6SR8X  d,   VV6,           S<^,          ,           W^,          ,           p8p7S<Tp:p9MSR8X  d3   Wy,           V^,          ,
          VV6,           S<^,          ,           p8p7TS<p:p9MjSR8X  d3   VV6,           S<^,          ,           W,           V^,          ,
          p8p7S<Tp:p9M1SR8X  d+   Wr^,          ,           VV6,           S<^,          ,           p8p7TS<p:p9S=! X7X8X9X:S<^,          4       K  	  S P                  R
R7       S P                  4        R# )zClip one segment of box border.

The strategy is to remove the zones not needed because of the style or the
side before painting.

c                z    \        V 4      \        V4      8  d   \        V4      \        V4      8  d   W3R3# W#3R3# )a  Get the point use for border transition.

The extra boolean returned is ``True`` if the point is in the padding
box (ie. the padding box is rounded).

This point is not specified. We must be sure to be inside the rounded
padding box, and in the zone defined in the "transition zone" allowed
by the specification. We chose the corner of the transition zone. It's
easy to get and gives quite good results, but it seems to be different
from what other browsers do.

TF)abs)x1y1x2y2s   &&&&r,   transition_point-clip_border_segment.<locals>.transition_pointM  s@     !$B#b' 1c"gB6GbXt	$(E"	$r.   c           
         W,
          W,           ,          p\         ^,          W,           ,          ^^V^,          ,          ^
\        ^^V^,          ,          ,
          4      ,           ,          ,           ,          # )a  Return the length of the half of one ellipsis corner.

Inspired by [Ramanujan, S., "Modular Equations and Approximations to
pi" Quart. J. Pure. Appl. Math., vol. 45 (1913-1914), pp. 350-372],
wonderfully explained by Dr Rob.

https://mathforum.org/dr.math/faq/formulas/

)r   r   )r   br"   s   && r,   corner_half_length/clip_border_segment.<locals>.corner_half_length^  sU     UquAvAF
b4AQJ#7788: 	:r.   c           	       < SR8X  Ed   V\        \        4      ,          pSP                  W,           V4       SP                  W,           W,           W,           W,           WV,           4       SP                  W,
          W,           W,
          W,           W,
          V4       SP                  W,
          W,
          W,
          W,
          WV,
          4       SP                  W,           W,
          W,           W,
          W,           V4       SP	                  4        R# SR8X  d0   SP                  W^,          ,
          W^,          ,
          W#4       R# R# )z-Draw a single dash or dot centered on cx, cy.dotteddashedN)r   r   move_tocurve_tocloser   )cxcyr;   r>   rr   r    r   s   &&&&& r,   	draw_dash&clip_border_segment.<locals>.draw_dashl  s    HRLENN262&OOBFBJ
BFBQOOOBJ
BFBOOOBFBJ
BFBQOOOBJ
BFBOLLNhR!)^R1*_eL r.   toprightbottomr7   r   r   Teven_odd      ?c           	        < SR 8X  Ed   V ^ 8X  d   V^,           R3# V ^8X  d   V^,           R3# \        ^V ^4       F  p^S,          V,
          W,          S,          V,          ,           ^,          \        ,          p	SR9   d   TMSp
SR9   d   TMSpS! W,           \        V4      S^,          ,
          \        V	4      ,          ,
          W,           \        V4      S^,          ,
          \	        V	4      ,          ,
          S^,          R7       K  	  ^S,          V,
          X^,           V,          S,          V,          ,           ^,          \        ,          pV\        ,          ^,          S,
          pV ^,          '       d
   V^,          pW3# V ^ 8X  d   V^,           R3# \        ^ V ^4       EFg  pVR,          p^S,          V,
          W,          S,          V,          ,           ^,          \        ,          pV^ 8  d   \
        M\        ! ^S,          V,
          V^,           V,          S,          V,          ,           ^,          \        ,          S\        ,          ^,          4      pSR9   d   SP                  W5,           SV,           4       SP                  W5,           W%,          ^,          \        V4      ,          ,
          S4       SP                  W5,           W%,          ^,          \        V4      ,          ,
          S4       MSR9   d   SP                  SV,           WF,           4       SP                  SWF,           W&,          \        V4      ,          ,           4       SP                  SWF,           W&,          \        V4      ,          ,           4       VS\        ,          ^,          8X  g   EK  W,
          ^S,          V,
          V^,           V,          S,          V,          ,           ^,          \        ,          V,
          ,          pV^,          p W3# 	  ^S\        ,          ^,          X,
          VX,
          ,          ,
          pW3# )r   r   )r   g      ࿩r   r   r7   r   gUUUUUUտ)
r   r   r   r   r   r   r   r   line_tor   )dasheslinewayr"   r#   r   r   chlrr   r   r   r   next_aoffsetangle1angle2angledashr   main_offsetro   r    r   s   &&&&&&&&        r,   draw_dashes(clip_border_segment.<locals>.draw_dashes  sa   H${#ax|+1#ax~-"1fa0%i#o4#1EEJRO"&*;";Q"&*;";Q!Gs2w'9SV&CCGs2w'9SV&CC#ax*	 1  !5y31q5C-$2F2LLPQQTVVF#b[1_u4Fzz	<'Q;!8T>)q&!,AHAe)c/QWt^c-AA  &)1Wc#5e)c/a!es]T-AC-GG
Q(F 00qv{R/?@FSX\CK%??NFSX\CK%??N!22{R'7@'#(S[2H)HJ'#(S[2H)HJa/"(/%i#o!a%31E1KK "#&,7- ". 	 |#= -8 a&0Vf_EGF|#r.   gư>N)r`   r`   r  r  r  )r`   r`   r`   r   r   r   )r   r   )r   r  r   r   r   r   r   r   )?r    r   r;   ro   rG   rA   radiibbxbbybbwbbhtlhtlvtrhtrvbrhbrvblhblvbtr(   bbr)   r   r   px1py1rounded1px2py2rounded2r  a1b1a2b2line_lengthlengthchl1chl2dash_lengthdashes1dashes2r  r  r  rr   r   r   r   r   number_of_spacesnumber_of_dashesr   advancer   r   
dash_widthdash_heightr
  r  r   r  s?   ff&f&&&                                                    @@@@r,   r?   r?   A  s    $Cc5:5K5Km2JS
JS#
c"22a5(lNBB$":M M u}/"bA
cH/cB3C
cH	/cB3C
cH/sdRC"E
cHi		/cT2sC
cH/sdRC"E
cHi	/"bA
cH/cT2sC
cH  rAvsSy5194BQc	EAI 5BCi#osy+.sK(sSy+"34sy3c(9:	"	"eai'rAvBeai'#QBCi#o{CI.{C({S(#)4{S(#)c/:$$)uq5yT"

xx%b"-D%b"-D 4'$.F.KH{Q!>? {Q!>!DED4!8Ot34GD4!8Ot34Gt+,D6$ 6$p 'wc3S#tTLD&tSY	3TKKLND T!q$*AKA00 3YT1 3Y!a%47(S1WE!D%Z!22 3YT1 3Y!a%47(S1WE!D%Zb2g]*B"r'Q,>Rb%!)5 +"  %Vd]Q%67/!3 ##&6&==AQQEE("%)9<L)LMRRQRR+a/0ut|,5= 7]TAX5sQYB.2EJW_ Y2C'MD1H4LB.3TJX% 7]TAX5sy5197LB.2EJV^ 19_cGmdQh.FB.3TJ"b*k4!8D 1 KKK
JJLr.   c                    VR9   d   V P                  V^ ,          4       \        WP                  4       4       \        WP                  R4      4       V P	                  RR7       V P                  V^,          4       \        WP                  R4      4       \        WP                  4       4       V P	                  RR7       R# V P                  V4       \        WP                  4       4       VR8X  d5   \        WP                  R4      4       \        WP                  R4      4       \        WP                  4       4       V P	                  RR7       R# )	ridgeTr   NrZ   r6  groover   gUUUUUU?gUUUUUU?)	set_colorrounded_boxr   rounded_box_ratiofillr   )r    r!   r   rH   s   &&&&r,   rk   rk   (  s   ##q"F3356F11%89T"q"F11%89F2245T"
U//12F11%89F11%89..01
KKKr.   c                 :   Vw  rVrxVw  rrVR9   EdM   V P                  V^ ,          4       V P                  ! V!   V P                  W\^,          ,           Wi^,          ,           W|V
,           ^,          ,
          WV,           ^,          ,
          4       V P                  RR7       V P                  W\^,          ,           Wi^,          ,           W|V
,           ^,          ,
          WV,           ^,          ,
          4       V P                  W\,           Wi,           W|,
          V
,
          W,
          V,
          4       V P                  V^,          4       V P                  RR7       R# V P                  V4       V P                  ! V!   VR8X  d   V P                  W\^,          ,           Wi^,          ,           W|V
,           ^,          ,
          WV,           ^,          ,
          4       V P                  W\^,          ^,          ,           Wi^,          ^,          ,           W|V
,           ^,          ^,          ,
          WV,           ^,          ^,          ,
          4       V P                  W\,           Wi,           W|,
          V
,
          W,
          V,
          4       V P                  RR7       R# )r6  Tr   NrZ   r7  )r9  r   r<  )r    r!   rp   r   rH   r  r  r  r  r  r(   r  r)   s   &&&&&        r,   r@   r@   <  s   CcNBB##q"#q&L#Q,7a-R1}!4	6 	T"q&L#Q,7a-R1}!4	6 	38SX]CHrMJq"T"
U
cq&L#Q,7a-R1}!4	6 	q&1*cFQJ.7a-!##SGq=1+<%<	> SXsxB2F
KKKr.   c	                 \	   W8X  g	   W$8X  g   Q hV P                  4       ;_uu_ 4        VR	9  d   V P                  VRR7       VR8X  d   V P                  ^V,          .V4       M3VR8X  d-   V P                  ^4       V P                  ^ ^V,          .V4       VR8X  Ed!   V P	                  V^,          4       W8X  d   V P                  W^,          ,
          V4       V P                  W5^,          ,
          V4       V P                  W^,          ,           V4       V P                  W5^,          ,           V4       EMEW$8X  d}   V P                  WV^,          ,
          4       V P                  W4V^,          ,
          4       V P                  WV^,          ,           4       V P                  W4V^,          ,           4       EMVR	9   Edr   V P	                  V^,          4       V P                  V^ ,          RR7       W8X  d@   V P                  W^,          ,           V4       V P                  W5^,          ,           V4       MDW$8X  d?   V P                  WV^,          ,           4       V P                  W4V^,          ,           4       V P                  4        V P                  V^,          RR7       W8X  dA   V P                  W^,          ,
          V4       V P                  W5^,          ,
          V4       EMW$8X  d?   V P                  WV^,          ,
          4       V P                  W4V^,          ,
          4       EMHVR8X  Ed   W$8X  g   Q h^p	RV,          p
V P                  W^V
,          ,
          W1,
          ^V
,          4       V P                  4        V P                  4        W,
          pV P                  W4       W8  d   V P	                  V4       V P                  W^,          ,           W)V
,          ,           V^V
,          ^,          ,           W)V
,          ,           V^V
,          ,           V4       V^V
,          ,          pV	R
,          p	K  M3V P	                  V4       V P                  W4       V P                  W44       V P                  4        RRR4       R#   + '       g   i     R# ; i)r6  T)stroker   r   rZ   wavyg      ?Nr7  r   )r:   r9  set_dashset_line_capset_line_widthr   r  r?  r   r   r   r   )r    r   r   r   r   	thicknessr   rH   r  upradiusr"   s   &&&&&&&&&   r,   	draw_linerG  Z  sx   8rx			++U40HOOQ]OV4h"OOQI.7H!!)a-0xrM126rM126rM126rM126r	A#56r	A#56r	A#56r	A#56))!!)a-0U1Xd3xrM126rM126r	A#56r	A#56MMOU1Xd3xrM126rM126r	A#56r	A#56f_8O8BI%FRa&j"'1v:FKKMJJLANN1!&%%i0
NBf$4F
Q&&[(8F
NB( QZb  !!),NN2"NN2"} 
			s   Q)RR+	c                    VP                   R ,          pVP                   R,          p\        VP                   R4      pVP                   R,          pVP                   R,          R8X  Ed+   V'       Ed"   VP                  '       Ed   VP                  4       V,
          V,
          VP	                  4       V,
          V,
          VP                  4       ^V,          ,           ^V,          ,           VP                  4       ^V,          ,           ^V,          ,           3p\         Fr  pV P                  4       ;_uu_ 4        V P                  4       ;_uu_ 4        \        WW'V4       \        W^V3,          V\        WTV4      4       RRR4       RRR4       Kt  	  VP                   F0  p\        V\        P                   4      '       g   K%  \#        W4       K2  	  R#   + '       g   i     L^; i  + '       g   i     K  ; i)outline_widthoutline_offsetoutline_coloroutline_stylerK   rL   N)r   r   ri   border_box_xborder_box_yr   r   re   rc   r:   r?   r@   r   r9   ra   r	   Boxdraw_outline)	r    r!   r;   r  rH   r   outline_boxro   rC   s	   &&       r,   rP  rP    s`   IIo&EYY'(Fcii1EIIo&E
yy)+%+++&/&/U*QZ7!e)+a&j8	:
 D""FNN$4$4#F5L eXu t46 %5""  eUYY'''  %5$4"""s$   8G(.G?G(G% G((G9c           
        Vw  r#rErgr\         ;QJ d    R WgW3 4       F  '       d   K   RM	  RM! R WgW3 4       4      '       d   V P                  W#WE4       R# Rp
V P                  W&^ ,          ,           V4       V P                  W$,           V^ ,          ,
          V4       V P	                  W$,           V^ ,          V
,          ,
          W2V,           W7^,          V
,          ,           W$,           W7^,          ,           4       V P                  W$,           W5,           V^,          ,
          4       V P	                  W$,           W5,           V^,          V
,          ,
          W$,           V^ ,          V
,          ,
          W5,           W$,           V^ ,          ,
          W5,           4       V P                  W)^ ,          ,           W5,           4       V P	                  W)^ ,          V
,          ,           W5,           W#V,           V	^,          V
,          ,
          W#V,           V	^,          ,
          4       V P                  W#V^,          ,           4       V P	                  W#V^,          V
,          ,           W&^ ,          V
,          ,           W2V^ ,          ,           V4       R# )zDraw the path of the border radius box.

``widths`` is a tuple of the inner widths (top, right, bottom, left) from
the border box. Radii are adjusted from these values. Default is (0, 0, 0,
0).

c              3   ,   "   T F
  p^ V9   x  K  	  R# 5i)r`   N ).0corners   & r,   	<genexpr>rounded_box.<locals>.<genexpr>  s     
6%561;%5s   FTNg?)r2   r   r   r  r   )r    r  r"   r#   r$   r%   r&   r'   r(   r)   r   s   &&         r,   r:  r:    s    "'A!
s
6bb%5
6sss
6bb%5
666q$A
NN1!u9a 
NN152a5=!$
OO	1	1!eQA]AE1!u9F
NN15!%"Q%-(
OO	qur!uqy !%"Q%!)"3QUAEBqEM	 NN1!u9ae$
OO	qEAIquaQA!2A1ur!u}F
NN1"Q%i 
OO	r!uqy=!eai-1Iq:r.   )r   r   r   r7   )NN)r`   )__doc__mathr   r   r   r   r   r   r   formatting_structurer	   layoutr
   layout.percentr   r*   r   rH   r   r   re   r-   rI   ry   r   r?   rk   r@   rG  rP  r:  rT  r.   r,   <module>r^     sa     5 5 5 (  '  **(S89VxJRZdN(<AH(.:r.   