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

[15SP] UI: Add support for using and editing sub-graphs #199

Open
ivan-cukic opened this issue Sep 16, 2024 · 1 comment
Open

[15SP] UI: Add support for using and editing sub-graphs #199

ivan-cukic opened this issue Sep 16, 2024 · 1 comment

Comments

@ivan-cukic
Copy link
Contributor

ivan-cukic commented Sep 16, 2024

Sub-graphs are shown as regular blocks in the flowgraph, with a visual hint that they are editable groups of blocks.

Editing sub-graphs:

  1. User double-clicks a sub-graph-block (or right-clicks on a block -> 'edit sub-graph')
  2. The UI opens a nested window that shows the same flowgraph-editing component used for the main flowgraph, just showing the blocks nested in the sub-graph

Creating new sub-graphs, 1st approach:

  1. User right-clicks on the flowgraph backgound and selects 'create a new sub-graph'
  2. The UI opens a nested window that shows the same flowgraph-editing component used for the main flowgraph, without any precreated blocks where the user can add new blocks and make connections

Creating new sub-graphs, 2nd approach:

  1. User selects one or more blocks from the graph
  2. User right-clicks on one of the selected blocks and selects 'create a new subgraph from the selected blocks'
  3. The UI opens a nested window that shows the same flowgraph-editing component used for the main flowgraph, with the previously selected blocks already added to the sub-graph (and removed from the parent graph)

Moving blocks from the sub-graph into the main flowgraph

  1. User right-clicks a sub-graph, and selects 'ungroup sub-graph'
  2. The sub-graph block gets replaced with its contents.

Choosing which ports are visible from the outside

Sub-graphs should behave like normal blocks in the graph that contains them. This means that they need to have input and output ports. The ports from the nested blocks that should be presented as inputs and outputs of the sub-graph are called 'exported ports' in GR4 code.

When creating a sub-graph from a selection of blocks, all connections that cross the boundary between the blocks inside the newly created sub-graph and the blocks from outside should be converted to exported ports and connections from outside blocks to the exported port and not directly to the port inside the block.

To otherwise define the exported ports, the UI needs to allow connecting ports of nested blocks to special areas 'exported input ports' and 'exported output ports'. The visual part for this needs to be discussed.

@ivan-cukic ivan-cukic converted this from a draft issue Sep 16, 2024
@wirew0rm wirew0rm added this to the CALL#6Security Hardening and RBAC Integration milestone Sep 16, 2024
@RalphSteinhagen RalphSteinhagen modified the milestones: CALL#5 - Security Hardening and RBAC Integration, CALL#5 - Security Hardening Sep 25, 2024
@ivan-cukic
Copy link
Contributor Author

Needs #246 to be done first.

@RalphSteinhagen RalphSteinhagen changed the title [5SP] UI: Add support for using and editing sub-graphs [15SP] UI: Add support for using and editing sub-graphs Dec 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 🔖 Selected (6)
Development

No branches or pull requests

3 participants