mirror of
https://git.sr.ht/~eliasnaur/gio
synced 2026-07-01 07:35:40 +00:00
op/clip: split Rect into pixel-aligned Rect and rounded RRect
The pixel-aligned Rect is more efficient and easier to use in the common case of layout clipping. Signed-off-by: Elias Naur <mail@eliasnaur.com>
This commit is contained in:
+1
-1
@@ -258,7 +258,7 @@ func (l *List) layout() Dimensions {
|
||||
Max: axisPoint(l.Axis, max, inf),
|
||||
}
|
||||
stack := op.Push(ops)
|
||||
clip.Rect{Rect: FRect(r)}.Add(ops)
|
||||
clip.Rect(r).Add(ops)
|
||||
op.Offset(FPt(axisPoint(l.Axis, pos, cross))).Add(ops)
|
||||
child.call.Add(ops)
|
||||
stack.Pop()
|
||||
|
||||
Reference in New Issue
Block a user