+
    	i	                     "    R t ^RIHt R tR tR# )zLeaders management.)boxesc                    \        V P                  4       FY  w  rVP                  '       d	   VR3V3u # \        V\        P
                  4      '       g   KA  \        V4      w  r4Vf   KT  W3V3u # 	  R# )z1Get the index of the first leader box in ``box``.N)NN)	enumeratechildren	is_leader
isinstancer   	ParentBoxleader_index)boxichildchild_leader_indexchild_leaders   &    ^/Users/agent/.openclaw/workspace/venv/lib/python3.14/site-packages/weasyprint/layout/leader.pyr	   r	      sj    cll+???t9e##eU__--/;E/B,!-.<< ,     c                h   \        V4      w  r4^ pVEe   VP                  '       Ed   VP                  w  pVP                  ^ 8:  d   R# VP                  \        R VP                   4       4      ,
          pV P                   FC  pVP
                  VP                  ,           VP
                  8  g   K1  WWP                  ,          pKE  	  WVP                  ,           pVP                  Vn        \        VP                  VP                  ,          4      p	VP                  VP                  ,           p
. p\        V	4       Fx  pWP                  ,          p
WP                  8  d   K'  WP                  ,           VP                  V,           8  d   KQ  VP                  4       pWn        VP                  V4       Kz  	  \        V4      Vn        VP                  R,          R8X  d   VP                  V) R7       TpVe   VP                  V^ ,          ^,           R  FZ  pVP                  4       '       g   K  VP                  R,          R8X  d   VP                  VR7       KG  VP                  V) R7       K\  	  VP                  V^ ,          ,          pV;P                  V,          un        V^,          pK  R# )zCFind a leader box in ``line`` and handle its text and its position.Nc              3   r   "   T F-  pVP                  4       '       g   K  VP                  4       x  K/  	  R # 5i)N)is_in_normal_flowmargin_width).0r   s   & r   	<genexpr> handle_leader.<locals>.<genexpr>   s0      3*.;U&&( !E  ms   77	directionrtl)dxltr)r	   r   widthsumexcluded_shapes
position_yheightint
position_xrangecopyappendtuplestyle	translater   )contextlinecontaining_blockindex
leader_boxextra_widthtext_boxshapeavailable_widthnumber_of_leadersr"   r   r   r
   r   s   &&&            r   handle_leaderr3      s&   $T*EKZ000''	 >>Q ',,s 3*.2mm3* 0* *
 ,,E%,,.@{{* -
 &6%++
  

hnn <=__tzz1
()A..(J111~~-))O;< }}H",OOH% * $Ho
::k"e+  [L 1 C

\\%(Q,-0E&&((::k*e3OO{O3OO|O4 1 ll58$		[ 	a r   N)__doc__formatting_structurer   r	   r3    r   r   <module>r7      s     (	9r   