pyvista.themes.DefaultTheme#

class DefaultTheme[source]#

PyVista default theme.

Examples

Change the global default background color to white.

>>> import pyvista
>>> pyvista.global_theme.color = 'white'

Show edges by default.

>>> pyvista.global_theme.show_edges = True

Create a new theme from the default theme and apply it globally.

>>> my_theme = pyvista.themes.DefaultTheme()
>>> my_theme.color = 'red'
>>> my_theme.background = 'white'
>>> pyvista.global_theme.load_theme(my_theme)

Methods

DefaultTheme.from_dict(dict_)

Create from a dictionary.

DefaultTheme.load_theme(theme)

Overwrite the current theme with a theme.

DefaultTheme.restore_defaults()

Restore the theme defaults.

DefaultTheme.save(filename)

Serialize this theme to a json file.

DefaultTheme.to_dict()

Return theme config parameters as a dictionary.

Attributes

DefaultTheme.above_range_color

Return or set the default above range color.

DefaultTheme.anti_aliasing

Enable or disable anti-aliasing.

DefaultTheme.antialiasing

Enable or disable anti-aliasing.

DefaultTheme.auto_close

Automatically close the figures when finished plotting.

DefaultTheme.axes

Return or set the default axes configuration.

DefaultTheme.background

Return or set the default background color of pyvista plots.

DefaultTheme.before_close_callback

Return the default before_close_callback function for Plotter.

DefaultTheme.below_range_color

Return or set the default below range color.

DefaultTheme.camera

Return or set the default camera position.

DefaultTheme.cmap

Return or set the default colormap of pyvista.

DefaultTheme.color

Return or set the default color of meshes in pyvista.

DefaultTheme.colorbar_horizontal

Return or set the default parameters of a horizontal colorbar.

DefaultTheme.colorbar_orientation

Return or set the default colorbar orientation.

DefaultTheme.colorbar_vertical

Return or set the default parameters of a vertical colorbar.

DefaultTheme.depth_peeling

Return or set the default depth peeling parameters.

DefaultTheme.edge_color

Return or set the default edge color.

DefaultTheme.enable_camera_orientation_widget

Enable the camera orientation widget in all plotters.

DefaultTheme.floor_color

Return or set the default floor color.

DefaultTheme.font

Return or set the default font size, family, and/or color.

DefaultTheme.full_screen

Return if figures are shown in full screen.

DefaultTheme.hidden_line_removal

Return or set hidden line removal.

DefaultTheme.interactive

Return or set the default interactive parameter.

DefaultTheme.jupyter_backend

Return or set the jupyter notebook plotting backend.

DefaultTheme.lighting

Return or set the default lighting.

DefaultTheme.multi_rendering_splitting_position

Return or set the default multi_rendering_splitting_position parameter.

DefaultTheme.multi_samples

Return or set the default multi_samples parameter.

DefaultTheme.name

Return or set the name of the theme.

DefaultTheme.nan_color

Return or set the default NaN color.

DefaultTheme.notebook

Return or set the state of notebook plotting.

DefaultTheme.outline_color

Return or set the default outline color.

DefaultTheme.render_points_as_spheres

Return or set the default render_points_as_spheres parameter.

DefaultTheme.return_cpos

Return or set the default behavior of returning the camera position.

DefaultTheme.sharp_edges_feature_angle

Set or return the angle of the sharp edges feature angle.

DefaultTheme.show_edges

Return or set the default edge visibility.

DefaultTheme.show_scalar_bar

Return or set the default color bar visibility.

DefaultTheme.silhouette

Return or set the default silhouette configuration.

DefaultTheme.slider_styles

Return the default slider style configurations.

DefaultTheme.smooth_shading

Return or set the default smooth_shading parameter.

DefaultTheme.split_sharp_edges

Set or return splitting sharp edges.

DefaultTheme.title

Return or set the default title parameter.

DefaultTheme.transparent_background

Return or set the default transparent_background parameter.

DefaultTheme.use_ipyvtk

Set or return the usage of "ipyvtk" as a jupyter backend.

DefaultTheme.volume_mapper

Return or set the default volume_mapper parameter.

DefaultTheme.window_size

Return or set the default render window size.