get_block_visibility()
Returns the visibility state of a block.
The visibility state is tracked internally and persists across render cycles. Defaults to True for blocks not yet tracked.
Parameters
block_name(str) — The name of the block to check.
Returns
bool—Trueif the block is visible,Falseotherwise.
Example
from pyemsi import Plotter, examples
file_path = examples.transient_path()
plt = Plotter(file_path)
# The transient example has blocks '1', '3', and '4'
print(plt.get_block_visibility("4")) # True
plt.set_block_visibility("4", False)
print(plt.get_block_visibility("4")) # False
See Also
set_block_visibility()— Set visibility for a single block.set_blocks_visibility()— Set visibility for multiple blocks in batch.get_block_names()— Get list of block names.