pyvista.Plotter.theme

目次

pyvista.Plotter.theme#

property Plotter.theme: Theme[ソース]#

このプロッタで使用するテーマを返すか設定します.

バージョン 0.47 で非推奨: Assigning the theme attribute to a plotter object does not affect global appearance settings such as background, which are set at instantiation. To this respect, you need to set the theme such that:

import pyvista as pv

pl = pv.Plotter()
pl.theme = theme
# change above lines to
pl = pv.Plotter(theme=theme)

However, actor appearance settings such as edge_color for example are correctly taken into account.

戻り値:
pyvista.Theme

このプロッターのテーマ.

プロッタにはダークテーマを使用します.

>>> import pyvista as pv
>>> from pyvista import themes
>>> pl = pv.Plotter()
>>> pl.theme = themes.DarkTheme()
>>> actor = pl.add_mesh(pv.Sphere())
>>> pl.show()
../../../_images/pyvista-Plotter-theme-44c64830ad61d125_00_00.png