Fixed
Status Update
Comments
co...@google.com <co...@google.com> #2
Unless I am missing something, it looks like the modifiers collected by the tools API are the materialized versions. The un-materialized versions are available as data in the slot tree but Group
reports the materialized modifiers in the modifierInfo
list.
co...@google.com <co...@google.com>
ap...@google.com <ap...@google.com> #3
According to this inspection in the debugger, it looks like the modifier parameter is the un-materialized version.
This is a parameter from a Text node where I specified:
modifier = Modifier.border(width = 10.0.dp, color = Color.Blue)
This is a parameter from a Text node where I specified:
modifier = Modifier.border(width = 10.0.dp, color = Color.Blue)
co...@google.com <co...@google.com> #4
That is certainly true. The modifiers passed in as parameters are unmaterialized but you should be able to find the materialized version in the corresponding node group.
ap...@google.com <ap...@google.com> #6
Hi Chuck,
Now the question is: how do I determine which NodeGroup to get the modifierInfo from.
Here is a dump of part of the SlotTable. The top node is a Text node that in the source code has a border modifier (BorderModifier).
However the NodeGroup with the modifierInfo does not appear before much later in the tree (underneath "Text", "CoreText", "Layout", "Layout" - and a bunch of other call nodes).
How do I determine that the modifier parameter of the Text node is actually the modifiers found much later ?
CallGroup("Text") - with a "modifier" parameter
- CallGroup(null)
- CallGroup("remember")
- CallGroup("Text")
- CallGroup(null)
- CallGroup(null)
- CallGroup("remember")
- CallGroup("CoreText")
- CallGroup("Layout")
- CallGroup("remember")
- CallGroup(null)
- CallGroup("Layout")
- CallGroup("Layout")
- CallGroup(null)
- CallGroup(null)
- CallGroup("remember")
- CallGroup(null)
- CallGroup("remember")
- CallGroup(null)
- CallGroup("remember")
- CallGroup("emit")
- NodeGroup (this NodeGroup has the BorderModifier). <----------------------------- Here is the BorderModifier that was a parameter for the first Text group node
- CallGroup(null)
- CallGroup("onCommit")
- CallGroup("remember")
Now the question is: how do I determine which NodeGroup to get the modifierInfo from.
Here is a dump of part of the SlotTable. The top node is a Text node that in the source code has a border modifier (BorderModifier).
However the NodeGroup with the modifierInfo does not appear before much later in the tree (underneath "Text", "CoreText", "Layout", "Layout" - and a bunch of other call nodes).
How do I determine that the modifier parameter of the Text node is actually the modifiers found much later ?
CallGroup("Text") - with a "modifier" parameter
- CallGroup(null)
- CallGroup("remember")
- CallGroup("Text")
- CallGroup(null)
- CallGroup(null)
- CallGroup("remember")
- CallGroup("CoreText")
- CallGroup("Layout")
- CallGroup("remember")
- CallGroup(null)
- CallGroup("Layout")
- CallGroup("Layout")
- CallGroup(null)
- CallGroup(null)
- CallGroup("remember")
- CallGroup(null)
- CallGroup("remember")
- CallGroup(null)
- CallGroup("remember")
- CallGroup("emit")
- NodeGroup (this NodeGroup has the BorderModifier). <----------------------------- Here is the BorderModifier that was a parameter for the first Text group node
- CallGroup(null)
- CallGroup("onCommit")
- CallGroup("remember")
pr...@google.com <pr...@google.com> #7
That I am not clear about since it depends on the implementation. There is no requirement that it even be used by it is highly likely to be.
However, it should always be the first NodeGroup
in the call group as anything else means the implementation is probably wrong.
Description
The following Experimental APIs have existed for several releases.
Please consider stabilising or removing these APIs: