Scroll was previously taking the graphics region as its control size as
opposed to the constraints. This was due to this code originally living
in redraw. This fixes scroll areas being able to scroll their contents
fully when sharing window space with other widgts.
This also means that if an animation is animating over discrete values
and the actual value has not changed, the Dynamic will no longer detect
a change because it's now using update instead of set.
measure() now is layout(). LayoutContext can either persist layout
information or be used temporarily for measurement. While this caching
is constantly thrown out currently, this is a step towards being able to
only re-layout widgets if they've been invalidated.
I decided scrolling a label would work better, so I loaded a source file
and noticed it wasn't rendering quite right in the label. It turns out
that the text wrapping was triggering despite the width in redraw being
the same as the measured amount. In short: sometimes the width I measure
can't be the width I set as the cosmic_text::Buffer size, because it
will cause it to wrap.
I've worked around it by caching the measured text for now. But it may
still show up in other situations and may require a more generalized
fix by seeing what else we can gleam from the glyphs being measured.