question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

restoring toolstate manager

See original GitHub issue

Prerequisites

  • Are you running the latest version?
  • Are you reporting to the correct repository?
  • Did you perform a cursory search?

For more information, see the CONTRIBUTING guide.

Description

[Description of the bug or feature]

Steps to Reproduce

  1. save tool state manager as JSON to database
  2. use a function setElementToolStateManager then restore the toolstate back to the element on click
  3. When we log the toolStateManager, we can see all the states are there along with the image url, with tools for each image used previously

Expected behavior: On click an image, restore the state manager

Actual behavior: But we cannot see the physical changes on the canvas, but they are visible on the tool state manager

Codepen With Reproduction of Issue:

Issue Analytics

  • State:open
  • Created 4 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
dannyrbcommented, Sep 16, 2019

^_^

image

1reaction
jlopes90commented, Sep 16, 2019

@dannyrb don’t forget change new issues.

Anotação 2019-09-16 150915

Read more comments on GitHub >

github_iconTop Results From Across the Web

Restore tool state · Issue #409 · cornerstonejs/cornerstoneTools
I've been working on saving and restoring tools to DICOM structured reports so I have some code here that shows how to create...
Read more >
Dynamically adding toolStates (i.e. for restoring annotations)
Hi, I'm saving and restoring saved toolStates using this code: ... The object is added to the state manager, but not displayed until...
Read more >
Tool Data - cornerstone-tools
addToolState is mostly used internally by tools, or to restore a saved state. ... A Stack specific tool state management strategy. This means...
Read more >
Clear all annotations with cornerstone-tools - Stack Overflow
The clearToolState function will remove all states from the state manager corresponding to the name and element of that tool.
Read more >
How to use the cornerstone-tools.zoom function in ... - Snyk
_disable_all_tools(this.viewer); cs.reset(this.viewer); var toolStateManager ... tool state managers (for now) toolStateManager.clear(this.viewer); cs.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found