-
Notifications
You must be signed in to change notification settings - Fork 20
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 svg and png export to trackscheme panels #306
base: dev
Are you sure you want to change the base?
Add svg and png export to trackscheme panels #306
Conversation
* Convenience method to retrieve the first spot of a branch spot
* getTagSetNames, which return the names of the tag sets in the model * getTagValue(), which returns the value of a branchSpot within a specified tag set * unit tests for the 2 new methods are contained
…getFirstSpot() methods Previously the methods created refs that the caller could not release
This is great! And it looks much simpler that the batik export in TrackMate's TrackScheme. If possible I would like to keep the right-click button for interactions with the data on the panel, as in the other views. Could you put the command in the JMenu? |
Please do not overestimate the capabilities of this. This function only paints the contents of the current view to the SVG/PNG file, i.e. it will not be complete, if the trackscheme as seen on the screen is not completely inside the window. Thus, it would be more honest, if the entry would say "Export current TrackScheme view to SVG/PNG". Would you still like to have it? It may nevertheless be useful for some use cases.
I was also thinking about this. I decided for the right click, since this would offer the highest re-usability with the lineage classification dialog, where I also have it on the right click. However, putting it in the menu should not be too much effort. Would you see it in the |
Yes.
I would say |
…omponents as PNG or SVG files
…led and used to export a panel content to svg/png
b45d180
to
7cb9feb
Compare
Agreed.
It's now in the |
Maybe there is a way to add it to all views automatically. Can I have a go at it? |
Yes, sure. I was not sure, if it makes sense to have it in all views (e.g. table view?) and if it works well in all views (e.g. grapher -> svg might be problematic). Otherwise, I would have tried as well. |
I recently added the functionality to export the content of the lineage classification dendrogram to SVG/PNG files, cf.: https://github.com/mastodon-sc/mastodon-deep-lineage/releases/tag/mastodon-deep-lineage-0.2.0
After this was released, I was asked by a user, if this could be added as a functionality to the track scheme windows as well.
This PR adds exactly this functionality to all TrackScheme Panels and the BDV Panel. It also adds a generic ExportUtils class that can be re-used in all plugin projects to achieve similar behavior in different components.