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

Add yoga layout support #67

Closed
2 of 3 tasks
kusti8 opened this issue Mar 22, 2018 · 7 comments
Closed
2 of 3 tasks

Add yoga layout support #67

kusti8 opened this issue Mar 22, 2018 · 7 comments

Comments

@kusti8
Copy link
Owner

kusti8 commented Mar 22, 2018

I'd like to add yoga layout, because Grid is pretty buggy and it would make it more similar to React Native. There are a few things that need to be done to make this work.

@kusti8
Copy link
Owner Author

kusti8 commented Mar 25, 2018

I'm almost done with a version that works on Linux, I just need a few more days to work out the bugs. Once the proton-native side is ready, then there shouldn't be any more changes needed since everything else should be implemented in libui.

For libui, the notable changes that I've made (on my fork) is add a fixed component using GtkFixed and add a way to get and set the size of any component.

I need to find a way to implement that in Windows and Mac, but I assume they have easy support for fixed positioning and setting/getting the size.

As for libui-node, I've added all of those bindings. Yoga isn't being built together with libui-node, but added with proton-native. I've had to change the compile options for libui-node because it and yoga were conflicting.

The component is implemented as View and supports all of the options that View has on React Native. I need to see if I can implement setting the background color so that it's easier to see nested views.

@parro-it
Copy link
Contributor

. I've had to change the compile options for libui-node because it and yoga were conflicting.

Can you details where they conflict? And which options you need to. Change?

@kusti8
Copy link
Owner Author

kusti8 commented Mar 26, 2018

I couldn't find exactly what conflicted, but I found this in nbind's issues and it worked. kusti8/libui-node@57a957c

@kusti8
Copy link
Owner Author

kusti8 commented Apr 1, 2018

I've added a PR to track my changes. All I need to do is add fixed positioning for Windows and Mac for libui and merge that.

@roman01la
Copy link
Contributor

@kusti8 Is it still in development? I also have a question about running Yoga on JS side, it's interesting to see how it can impact perf 🤔

@mischnic
Copy link
Contributor

@roman01la This PR needs to be merged first: andlabs/libui#332.

@kusti8
Copy link
Owner Author

kusti8 commented Jan 19, 2020

Proton Native V2 is now released! If the issue still occurs in the new update, please open a new issue.

@kusti8 kusti8 closed this as completed Jan 19, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants