-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Nested artboard types: node, leaf, layout
~~Adding as a draft to start testing.~~ - [x] Add node, leaf, and layout types. - [x] Leaf supports fit and alignment. - [x] Leaf alignment is floating point instead of enum allowing for animation later. - [x] Layout allows external hosting artboards to take the nested layout node and host it in another hierarchy. - [x] Measure and control size for NestedArtboard from native. - [x] FFI changes for external layout node - [x] WASM changes for external layout node. - [x] Move layouts to RiveNative. <img width="663" alt="CleanShot 2024-07-21 at 14 48 41@2x" src="https://github.com/user-attachments/assets/b2c70d55-5f09-421a-bde3-f49939c6effc"> ~~For a follow up PR: I think it's time to move some of rive_common into rive_native. I think the layout stuff would be a good start. @philter take a look at how the rive_binding.cpp is shared in rive_native for both FFI and WASM. I think it would simplify our layout bindings to use this model too.~~ Nevermind, we need it for this PR or ```LayoutNode.fromExternal``` doesn't work. Diffs= 1a5f273bb Nested artboard types: node, leaf, layout (#7639) Co-authored-by: Luigi Rosso <[email protected]>
- Loading branch information
1 parent
560a993
commit 9f0db02
Showing
24 changed files
with
743 additions
and
269 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
50bc398c464061bb2ab5ac51e42901053ae63f1f | ||
1a5f273bb6534a395d1c3cdcc11a1ba3cd80a96c |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
{ | ||
"name": "NestedArtboardLayout", | ||
"key": { | ||
"int": 452, | ||
"string": "nestedartboardlayout" | ||
}, | ||
"extends": "nested_artboard.json" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
{ | ||
"name": "NestedArtboardLeaf", | ||
"key": { | ||
"int": 451, | ||
"string": "nested_artboard_leaf" | ||
}, | ||
"extends": "nested_artboard.json", | ||
"properties": { | ||
"fit": { | ||
"type": "uint", | ||
"key": { | ||
"int": 538, | ||
"string": "fit" | ||
}, | ||
"description": "Fit type for the nested artboard's runtime artboard." | ||
}, | ||
"alignmentX": { | ||
"type": "double", | ||
"key": { | ||
"int": 644, | ||
"string": "alignmentx" | ||
}, | ||
"description": "Alignment value on X." | ||
}, | ||
"alignmentY": { | ||
"type": "double", | ||
"key": { | ||
"int": 645, | ||
"string": "alignmenty" | ||
}, | ||
"description": "Alignment value on Y." | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.