Skip to content
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

TreeView: Filtering, Sorting, Grouping #681

Merged
merged 30 commits into from
Dec 14, 2023

Conversation

falko17
Copy link
Collaborator

@falko17 falko17 commented Dec 9, 2023

Apart from a lot of smaller improvements to the TreeWindow, this pull request adds the following functionality (accessible via buttons next to the search bar):

  • Filtering: Both the normal tree view and the graph search can apply a combination of filters, handled by the GraphFilter class. Currently, this only includes toggle attributes and a toggle for edges. Filtered elements will not be shown in the TreeWindow (orphan nodes and dangling edges are "lifted" upwards).
  • Sorting: Both the normal tree view and the graph search can sort the results by a number of attributes via the GraphSorter class. Currently, this includes the source name, the source line, the filename, and the type. Sorters are applied in order, and can be made descending or ascending on a case-by-case basis.
  • Grouping: In the tree view, elements can be grouped together (i.e., put below a root node together) via the TreeWindowGrouper class. Currently, this is possible with the reflexion state and the element type. Only one group can be applied at a time. The hierarchy is preserved here – for details on what this means, see Allow "direct" grouping in Tree Window #680. Elements that do not actually belong to the group are rendered in italics.

All three modifiers can be combined in any desired way (e.g., filters can still be applied while grouping elements). Additionally, it should be very easy to include additional filters/sorters/groupers with this structure in place.

Additional Changes

  • A static Icons class has been added, so that icon glyphs can be easily reused across different contexts. See https://github.com/uni-bremen-agst/SEE/wiki/Icons for details.
  • Headings for PopupMenus have been implemented.
  • A bug in the MoveAction has been fixed that led to nodes not being unparented correctly in a reflexion analysis context.
  • An option has been added to keep PopupMenus open even after clicking on them.
  • A DefaultDictionary has been added that adds and returns a default value if an accessed dictionary key does not actually exist.
  • A bug in the CI has been fixed which led to bad patterns not being detected correctly.
  • Unity has been updated to version 2022.3.15f1.
  • Additional smaller bug fixes.

@falko17 falko17 added enhancement New feature or request Improvement Improvement of existing features labels Dec 9, 2023
@falko17 falko17 requested a review from koschke December 9, 2023 22:25
@falko17 falko17 self-assigned this Dec 9, 2023
@falko17 falko17 linked an issue Dec 9, 2023 that may be closed by this pull request
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are a few bad patterns I found which you should check.

Assets/SEE/UI/Window/TreeWindow/DesktopTreeWindow.cs Outdated Show resolved Hide resolved
Assets/SEE/UI/Window/TreeWindow/TreeWindowContextMenu.cs Outdated Show resolved Hide resolved
Assets/SEE/UI/Window/TreeWindow/TreeWindowContextMenu.cs Outdated Show resolved Hide resolved
Copy link
Collaborator

@koschke koschke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have only very trivial remarks.

Assets/SEE/DataModel/GraphSearch/GraphFilter.cs Outdated Show resolved Hide resolved
Assets/SEE/DataModel/DG/Graph.cs Outdated Show resolved Hide resolved
Assets/SEE/DataModel/DG/Graph.cs Outdated Show resolved Hide resolved
Assets/SEE/DataModel/DG/Graph.cs Outdated Show resolved Hide resolved
Assets/SEE/UI/Window/TreeWindow/DesktopTreeWindow.cs Outdated Show resolved Hide resolved
Assets/SEE/UI/Window/TreeWindow/TreeWindowContextMenu.cs Outdated Show resolved Hide resolved
Assets/SEE/UI/Window/TreeWindow/TreeWindowContextMenu.cs Outdated Show resolved Hide resolved
Assets/SEE/Utils/CollectionExtensions.cs Show resolved Hide resolved
Copy link
Collaborator

@koschke koschke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All fine. I resolved all remaining issues myself.

@koschke koschke enabled auto-merge December 14, 2023 12:00
@koschke koschke merged commit a01ac50 into master Dec 14, 2023
10 checks passed
@koschke koschke deleted the 444-display-reflexion-results-in-tree-view-window branch December 14, 2023 12:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request Improvement Improvement of existing features
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Display reflexion results in tree-view window
2 participants