Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

make hlut widget optional #351

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Nov 3, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 14 additions & 9 deletions 23 fastplotlib/widgets/image.py
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,7 @@ def __init__(
grid_shape: Tuple[int, int] = None,
names: List[str] = None,
grid_plot_kwargs: dict = None,
histogram_widget: bool = False,
clewis7 marked this conversation as resolved.
Show resolved Hide resolved
clewis7 marked this conversation as resolved.
Show resolved Hide resolved
**kwargs,
):
"""
Expand Down Expand Up @@ -288,6 +289,9 @@ def __init__(
names: Optional[str]
gives names to the subplots

histogram_widget: bool, default False
determines whether each subplot is rendered with a Histogram LUT widget
clewis7 marked this conversation as resolved.
Show resolved Hide resolved
clewis7 marked this conversation as resolved.
Show resolved Hide resolved

kwargs: Any
passed to fastplotlib.graphics.Image

Expand Down Expand Up @@ -556,16 +560,17 @@ def __init__(
subplot.name = name
subplot.set_title(name)

hlut = HistogramLUT(
data=d,
image_graphic=ig,
name="histogram_lut"
)
if histogram_widget:
hlut = HistogramLUT(
data=d,
image_graphic=ig,
name="histogram_lut"
)

subplot.docks["right"].add_graphic(hlut)
subplot.docks["right"].size = 80
subplot.docks["right"].auto_scale(maintain_aspect=False)
subplot.docks["right"].controller.enabled = False
subplot.docks["right"].add_graphic(hlut)
subplot.docks["right"].size = 80
subplot.docks["right"].auto_scale(maintain_aspect=False)
subplot.docks["right"].controller.enabled = False

self.block_sliders = False
self._image_widget_toolbar = None
Expand Down
Morty Proxy This is a proxified and sanitized view of the page, visit original site.