Remember state of structure widget after changing components in the side panel
When I switch to "Symbols"/"Files" and back to "Structure" all my folding is gone and everything is expanded again, for example. Also when the structure is updated, it is expanding again. Changing the latter could be a complicated task I imagine. That's why I propose first to preserve the folding when the structure hasn't changed. Next I would save the structure state even when the app is closed (the way open files are preserved?).
Preserve the folding even while the structure is changing: I will think about this problem and post here when I find a (part-)solution.