Skip to content
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

Add CustomJSTicker #13988

Merged
merged 2 commits into from
Jul 31, 2024
Merged
Show file tree
Hide file tree
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
Prev Previous commit
Apply suggestions from code review
Co-authored-by: Moritz Schreiber <[email protected]>
  • Loading branch information
bryevdv and mosc9575 authored Jul 21, 2024
commit 62629cab6f9ea40688e5bd8f37a8daf97a7c86e5
2 changes: 1 addition & 1 deletion examples/styling/plots/custom_js_ticker.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
yticker = CustomJSTicker(major_code="return ['a', 'c', 'e', 'g']")

p = figure(y_range=list("abcdefg"))
p.scatter([1,2,3,4,5], ["a","d","b","f","c"], size=30)
p.scatter([1, 2, 3, 4, 5], ["a", "d", "b", "f", "c"], size=30)

p.xaxis.ticker = xticker

Expand Down
4 changes: 2 additions & 2 deletions src/bokeh/models/tickers.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ def __init__(self, *args, **kwargs) -> None:

args = Dict(String, AnyRef, help="""
A mapping of names to Python objects. In particular those can be bokeh's models.
These objects are made available to the formatter's code snippet as the values of
These objects are made available to the ticker's code snippet as the values of
named parameters to the callback.
""")

Expand Down Expand Up @@ -136,7 +136,7 @@ def __init__(self, *args, **kwargs) -> None:
ignored when the range is a ``FactorRange``.

The ``cb_data`` parameter that is available to the callback code will contain
four specific fields:
five specific fields:

``major_ticks``
the list of the current computed major tick locations
Expand Down
Loading