o
    gi                     @   st   d Z ddl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lmZ dd	lmZ G d
d deZdS )z
A screenshot (also known as screen capture or screen grab) is a digital image that shows the contents of a computer display.
A screenshot is created by the operating system or software running on the device powering the display.
    N)Decimal)	ImageGrab)Color)HexColor)	Rectangle)Image)	Alignmentc                6       s  e Zd ZdZddeddededededddedddejdddddededededejddfde	de	d	e
d
e	dedededede	de	dedeje deje dede	deje deje deje deje dedededededeje d eje f4 fd!d"Z  ZS )#
ScreenShotz
    A screenshot (also known as screen capture or screen grab) is a digital image that shows the contents of a computer display.
    A screenshot is created by the operating system or software running on the device powering the display.
    F000000r      Nall_screensborder_bottomborder_colorborder_leftborder_radius_bottom_leftborder_radius_bottom_rightborder_radius_top_leftborder_radius_top_rightborder_right
border_topborder_widthbounding_boxheighthorizontal_alignmentinclude_layered_windowsmargin_bottommargin_leftmargin_right
margin_toppadding_bottompadding_leftpadding_rightpadding_topvertical_alignmentwidth	x_displayc                    s   t  jdi dtj|d u rd nt| t| t| t| f|||dd|d|d|d|d|d|d	|d
|	d|
d|d|d|d|d|d|d|d|d|d|d|d|d| d S )Nimage)bboxr   r   xdisplayr   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r    r!   r"   r#   r$    )	super__init__r   grabintget_xget_y	get_width
get_height)selfr   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r    r!   r"   r#   r$   r%   	__class__r)   [/home/ubuntu/.local/lib/python3.10/site-packages/borb/pdf/canvas/layout/image/screenshot.pyr+      st   



 !"#zScreenShot.__init__)__name__
__module____qualname____doc__r   r   r   LEFTTOPboolr   typingOptionalr   strr+   __classcell__r)   r)   r3   r5   r	      s    	
r	   )r9   r=   decimalr   PILr   borb.pdf.canvas.color.colorr   r   "borb.pdf.canvas.geometry.rectangler   "borb.pdf.canvas.layout.image.imager   %borb.pdf.canvas.layout.layout_elementr   r	   r)   r)   r)   r5   <module>   s   