3
W5	                 @   s\   d Z ddlmZmZ ddlmZ ddlmZ ddlm	Z	 ddl
mZ dd	lmZ d
d ZdS )z
    weasyprint.layout.markers
    -------------------------

    Layout for list markers (for ``display: list-item``).

    :copyright: Copyright 2011-2014 Simon Sapin and contributors, see AUTHORS.
    :license: BSD, see LICENSE for details.

    )divisionunicode_literals   )resolve_percentages)image_marker_layout)find_in_flow_baseline   )split_first_line)boxesc             C   s   t |dd}|rt||d t|tjr^t|j|j| jddd\|_	}}|_
|_|_t|}nt| t|tjr|r||j |_n
|j |_|j |_d|jj }|jj}|dkr||_| j|j 8  _n||_| j|j 7  _dS )z$Lay out the list markers of ``box``.Zoutside_list_markerN)Zcontaining_block)	max_width
line_widthg      ?Zltr)getattrr   
isinstancer
   ZTextBoxr	   textstyleZenable_hintingZpango_layoutwidthheightbaseliner   r   Z
position_yZcontent_box_yZborder_box_xZ
position_xZ	font_size	directionZmargin_rightZmargin_widthZmargin_leftZborder_width)contextZboxmarker_r   Zhalf_emr    r   Y/var/www/html/enquirykeeper_venv/lib/python3.6/site-packages/weasyprint/layout/markers.pylist_marker_layout   s(    


r   N)__doc__
__future__r   r   Zpercentagesr   Zreplacedr   Ztablesr   r   r	   Zformatting_structurer
   r   r   r   r   r   <module>   s   