*L iD`ddlmZGddZGddZGddZGdd Zy ) )_list_repr_elidedc|eZdZ d dZdZedZedZedZedZ edZ ed Z y) InputDeviceStateNc X||_||_||_||_||_||_yN)_ctrl_alt_meta_shift_button_buttons)selfctrlaltshiftmetabuttonbuttons_s V/mnt/ssd/data/python-lab/Trading/venv/lib/python3.12/site-packages/plotly/callbacks.py__init__zInputDeviceState.__init__s.      c djt|jt|jt|jt|j t|j t|jS)NzInputDeviceState( ctrl={ctrl}, alt={alt}, shift={shift}, meta={meta}, button={button}, buttons={buttons}))rrrrrr)formatreprrrrrrrrs r__repr__zInputDeviceState.__repr__sb!&diiTXXdiitzz" $& !  rc|jS)zW Whether alt key pressed Returns ------- bool )r rs rrzInputDeviceState.alt syyrc|jS)zX Whether ctrl key pressed Returns ------- bool )rrs rrzInputDeviceState.ctrl+zzrc|jS)zY Whether shift key pressed Returns ------- bool )r rs rrzInputDeviceState.shift6s{{rc|jS)zX Whether meta key pressed Returns ------- bool )r rs rrzInputDeviceState.metaAr rc|jS)a& Integer code for the button that was pressed on the mouse to trigger the event - 0: Main button pressed, usually the left button or the un-initialized state - 1: Auxiliary button pressed, usually the wheel button or the middle button (if present) - 2: Secondary button pressed, usually the right button - 3: Fourth button, typically the Browser Back button - 4: Fifth button, typically the Browser Forward button Returns ------- int )r rs rrzInputDeviceState.buttonLs$||rc|jS)a Integer code for which combination of buttons are pressed on the mouse when the event is triggered. - 0: No button or un-initialized - 1: Primary button (usually left) - 2: Secondary button (usually right) - 4: Auxilary button (usually middle or mouse wheel button) - 8: 4th button (typically the "Browser Back" button) - 16: 5th button (typically the "Browser Forward" button) Combinations of buttons are represented as the decimal form of the bitmask of the values above. For example, pressing both the primary (1) and auxilary (4) buttons will result in a code of 5 Returns ------- int )r rs rrzInputDeviceState.buttons`s.}}r)NNNNNN) __name__ __module__ __qualname__rrpropertyrrrrrrrrrrsOS  "&rrcteZdZgggddfdZdZedZedZedZedZ edZ y) PointsNcJ||_||_||_||_||_yr) _point_inds_xs_ys _trace_name _trace_index)r point_indsxsys trace_name trace_indexs rrzPoints.__init__{s(%%'rc .djt|jtdt|jtdt|j tdt |jt |jS)NzPoints(point_inds={point_inds}, xs={xs}, ys={ys}, trace_name={trace_name}, trace_index={trace_index})zPoints(point_inds=indentz xs=z ys=)r2r3r4r5r6) rrr2lenr3r4rr5r6rs rrzPoints.__repr__sv% &,V(,@(A!\1BC \1BCDOO,T--.&,& rc|jS)zu List of selected indexes into the trace's points Returns ------- list[int] )r-rs rr2zPoints.point_indsrc|jS)zo List of x-coordinates of selected points Returns ------- list[float] r.rs rr3z Points.xs xxrc|jS)zo List of y-coordinates of selected points Returns ------- list[float] r/rs rr4z Points.ysr?rc|jS)zP Name of the trace Returns ------- str )r0rs rr5zPoints.trace_namer<rc|jS)z_ Index of the trace in the figure Returns ------- int )r1rs rr6zPoints.trace_indexs   r) r%r&r'rrr(r2r3r4r5r6r)rrr+r+zs|"$tQU(     !!rr+cJeZdZddZdZedZedZedZy) BoxSelectorNc .d|_||_||_y)Nbox)_type_xrange_yrange)rxrangeyrangers rrzBoxSelector.__init__s   rcPdj|j|jS)Nz9BoxSelector(xrange={xrange}, yrange={yrange}))rKrL)rrKrLrs rrzBoxSelector.__repr__s# &dkk$++ N Orc|jSzR The selector's type Returns ------- str rHrs rtypezBoxSelector.typer rc|jS)zs x-axis range extents of the box selection Returns ------- (float, float) )rIrs rrKzBoxSelector.xrange||rc|jS)zs y-axis range extents of the box selection Returns ------- (float, float) )rJrs rrLzBoxSelector.yrangerSrNN) r%r&r'rrr(rQrKrLr)rrrErEsI O rrEcJeZdZddZdZedZedZedZy) LassoSelectorNc .d|_||_||_y)Nlasso)rHr.r/)rr3r4rs rrzLassoSelector.__init__s rc djt|jtdt|jtdS)Nz-LassoSelector(xs={xs}, ys={ys})zLassoSelector(xs=r8z ys=)r3r4)rrr3r:r4rs rrzLassoSelector.__repr__sC & 5H1IJ 5H1IJ!  rc|jSrOrPrs rrQzLassoSelector.typer rc|jS)z list of x-axis coordinates of each point in the lasso selection boundary Returns ------- list[float] r>rs rr3zLassoSelector.xs xxrc|jS)z list of y-axis coordinates of each point in the lasso selection boundary Returns ------- list[float] rArs rr4zLassoSelector.ysr]rrU) r%r&r'rrr(rQr3r4r)rrrWrWsH      rrWN) plotly.utilsrrr+rErWr)rrr`s7*sslM!M!`**Z//r