-
Notifications
You must be signed in to change notification settings - Fork 3
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
Make "Show all Details" in the diagram settings persistent #103
Comments
I'm unsure whether this is a VS Code only problem or whether this also is the case in Epoch, but let me tag @a-sr and @soerendomroes because they would know... |
@a-sr or @soerendomroes? |
It is a VS Code problem that we are aware of. |
I just tried looking into this issue: I can reproduce it with the current released extension in the VS Code marketplace, I cannot reproduce it by launching the language server from LF's and KLighD's current main branches. There everything behaves as expected. |
When are you planning to do the next release, @NiklasRentzCAU? |
The next release will be in conjunction with the first Maven release, so I'll aim for no later than next week as I only wait for us officially claiming the |
Great! Please notify us when the release is there, then we can update our gradle configuration to pull from maven central. |
Just stumbled across this again, just for the documentation here as well: The Maven release was published. To further look into this issue, please re-check this with the new release. |
The issue persists. |
As far as I understand, this should be reproducible with the following LF program:
I try the following to reproduce this: I open the program, expand the reactor, and duplicate the reaction inside the reactor. Update: It seems to be some race condition and the problem will occur if adding removing a reaction multiple times. |
Your language server is missing a dependency to |
This should stabilize the diagram generation in VS Code. See lf-lang/vscode-lingua-franca#103 (comment) Fixes lf-lang/vscode-lingua-franca#103
This should stabilize the diagram generation in VS Code. See lf-lang/vscode-lingua-franca#103 and this comment: lf-lang/vscode-lingua-franca#103 (comment)
Thanks for the pointer! I added the dependency in lf-lang/lingua-franca#2018. Indeed, this seems to stabilize the diagram generation. However, there is still some "weirdness" with respect to the "Show all Details" option. Consider this program:
I take the following steps:
I tried this several times, and each time the Foo reactor was expanded when adding it back for the first time and then contracted for the second time. |
For me this is consistent in that the foo-reactor is always collapsed when re-adding the content. Which is what I would expect anyways - the previously expanded graph element is fully removed from the KLighD-structure and thus any expansion state is disregarded. The new "Foo" reactor will be in its default expansion state, which seems to be collapsed in LF. The "Show all Details" is not an option, but rather an action expanding all current elements. Newly added elements will be collapsed by default. If you want a "show all details" option keeping everything open that would be possible in the synthesis as well, forcing new elements with a new "expanded" default. |
Ok, that makes sense. I am Ok with accepting the "weirdness" as a feature and not a bug ;) Also, thanks for your explanation on options vs. actions. I do think it would make sense for us to introduce an option that controls the default expansion state. Do you have any pointers on how this could be achieved? |
The default expanded state is set here. |
I implemented an "initially expand all" option in an old fork: lf-lang/lingua-franca@80bf6c9 |
Thanks! I integrated this change with lf-lang/lingua-franca#2018. |
Thanks for tracking this down, Niklas!! |
I find it quite annoying that the rendered diagrams switch back to "Hide all Details" whenever I edit an LF file. It would be great if the settings are remembered and all details remain expanded once I clicked on "Show all Details" even after I edit the LF program.
The text was updated successfully, but these errors were encountered: