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

Absolute positioning layout widget for node graphs #506

Open
giannissc opened this issue Jul 9, 2024 · 4 comments
Open

Absolute positioning layout widget for node graphs #506

giannissc opened this issue Jul 9, 2024 · 4 comments

Comments

@giannissc
Copy link

giannissc commented Jul 9, 2024

Hi there! I was wondering if someone can give me some pointers on how to implement a absolute layout widget to be used with something like a node graph? I have used the PanZoom widget that was posted on discord and modified it to implement snapping and show a grid, but it currently doesn't support adding other widgets to it. Following the virtualList and VirtualStack it is unclear to me what exactly is needed.

20240706-1818-38.2816432.mp4
@dzhou121
Copy link
Contributor

dzhou121 commented Jul 9, 2024

It feels like the best approach would probably be a custom widget, e.g., you'd paint the grid yourself.

@giannissc
Copy link
Author

That's what I am trying to do but I am not sure which aspects of the other layout widgets to copy? The two virtual widget currently in floem have some differences. For example the stack uses a diff and stores the children in it's strict definition as well as in the ECS so I am not sure which of the two more closely follows the way thing should be done in floem

@dzhou121
Copy link
Contributor

Does this need to contain other widgets? If so, the logic would be similar to the virtual list.

@giannissc
Copy link
Author

Are there any plans to add a virtual_canvas widget to floem at some point?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants