RegionsStyle#
- class movement.napari.layer_styles.RegionsStyle(name='Regions', visible=True, blending='translucent', color='red', edge_width=5.0, opacity=1.0, text=<factory>)[source]#
Bases:
LayerStyleStyle properties for a napari Shapes layer containing regions.
The same
coloris applied to faces, edges, and text. The face color alpha is hardcoded to 0.25, while edges and text are fully opaque. Overall layer opacity is set to 1.0.Methods
Return the style properties as a dictionary of kwargs.
set_color_all_shapes(layer)Set colors on all existing shapes in a napari Shapes layer.
set_style_for_new_shapes(layer)Set the style that napari will apply to newly drawn shapes.
- set_color_all_shapes(layer)[source]#
Set colors on all existing shapes in a napari Shapes layer.
- Return type:
- set_style_for_new_shapes(layer)[source]#
Set the style that napari will apply to newly drawn shapes.
napari uses current_* properties to style shapes as they are drawn.
- Return type:
- property edge_and_text_color: ColorValue#
Return the opaque color for edges and text.
- property face_color: ColorValue#
Return the face color with transparency applied.