-
-
Notifications
You must be signed in to change notification settings - Fork 590
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
Dynamically toggle navigator? #907
Comments
@bdrichards I don't think you can do that. |
Another option is to change the visibility of the navigator: var viewer = OpenSeadragon({
// debugMode: true,
id: "contentDiv",
prefixUrl: "../../build/openseadragon/images/",
tileSources: "../data/testpattern.dzi",
showNavigator: true
});
var navigatorShown = true;
function toggleNavigator() {
navigatorShown = !navigatorShown;
viewer.navigator.element.style.display = navigatorShown ? 'block' : 'none';
} There is a small issue with that, the red rectangle indicating the current position of the viewport will sometimes be misplaced after a toggle. |
Thanks for the ideas to investigate. |
This might be helpful (see the last comments for working code): |
I know this must be very basic, but what would be the syntax in a button onclick event to dynamically toggle the navigator?
The text was updated successfully, but these errors were encountered: