rayoptics.mpl.interactivediagram module
- class InteractiveDiagram(opt_model, dgm_type, refresh_gui=None, do_barrel_constraint=False, barrel_constraint=1.0, enable_slide=False, bend_or_gap='bend', parax_model=None, parax_model_key='ifcs', **kwargs)[source]
Bases:
InteractiveFigure
Editable version of \(y-\overline{y}\) and \(\omega-\overline{\omega}\) diagrams
- opt_model
parent optical model
- refresh_gui
function to be called on refresh_gui event
- dgm_type
diagram type, ‘ht’ or ‘slp’
- do_barrel_constraint, bool
display the barrel diamond if True
- barrel_constraint, float
the radius for the barrel constraint
- enable_slide
Display the “bend” or “gap” constaint lines
- bend_or_gap
“bend” | “gap”
- parax_model
if None, ‘ifcs’ else parax_mode for layer parax_model_key
- parax_model_key
“ifcs” | “eles” | “asm” | “sys”
- set(*, agg_filter=<UNSET>, alpha=<UNSET>, animated=<UNSET>, canvas=<UNSET>, clip_box=<UNSET>, clip_on=<UNSET>, clip_path=<UNSET>, constrained_layout=<UNSET>, constrained_layout_pads=<UNSET>, dpi=<UNSET>, edgecolor=<UNSET>, facecolor=<UNSET>, figheight=<UNSET>, figwidth=<UNSET>, frameon=<UNSET>, gid=<UNSET>, in_layout=<UNSET>, label=<UNSET>, layout_engine=<UNSET>, linewidth=<UNSET>, mouseover=<UNSET>, path_effects=<UNSET>, picker=<UNSET>, rasterized=<UNSET>, size_inches=<UNSET>, sketch_params=<UNSET>, snap=<UNSET>, tight_layout=<UNSET>, transform=<UNSET>, url=<UNSET>, view_bbox=<UNSET>, visible=<UNSET>, zorder=<UNSET>)
Set multiple properties at once.
Supported properties are
- Properties:
agg_filter: a filter function, which takes a (m, n, 3) float array and a dpi value, and returns a (m, n, 3) array and two offsets from the bottom left corner of the image alpha: scalar or None animated: bool canvas: FigureCanvas clip_box: .Bbox clip_on: bool clip_path: Patch or (Path, Transform) or None constrained_layout: unknown constrained_layout_pads: unknown dpi: float edgecolor: color facecolor: color figheight: float figure: .Figure figwidth: float frameon: bool gid: str in_layout: bool label: object layout_engine: unknown linewidth: number mouseover: bool path_effects: .AbstractPathEffect picker: None or bool or float or callable rasterized: bool size_inches: (float, float) or float sketch_params: (scale: float, length: float, randomness: float) snap: bool or None tight_layout: unknown transform: .Transform url: str view_bbox: unknown visible: bool zorder: float