mirror of
https://git.sr.ht/~eliasnaur/gio
synced 2026-07-05 17:35:36 +00:00
all: rename layout.Dimens to layout.Dimensions
Dimens is only 4 characters shorter and not worth the abbreviation. Signed-off-by: Elias Naur <mail@eliasnaur.com>
This commit is contained in:
+2
-2
@@ -25,7 +25,7 @@ type Image struct {
|
||||
Scale float32
|
||||
}
|
||||
|
||||
func (im Image) Layout(c ui.Config, ops *ui.Ops, cs layout.Constraints) layout.Dimens {
|
||||
func (im Image) Layout(c ui.Config, ops *ui.Ops, cs layout.Constraints) layout.Dimensions {
|
||||
size := im.Src.Bounds()
|
||||
wf, hf := float32(size.Dx()), float32(size.Dy())
|
||||
var w, h int
|
||||
@@ -49,5 +49,5 @@ func (im Image) Layout(c ui.Config, ops *ui.Ops, cs layout.Constraints) layout.D
|
||||
}
|
||||
paint.ImageOp{Src: im.Src, Rect: im.Rect}.Add(ops)
|
||||
paint.PaintOp{Rect: dr}.Add(ops)
|
||||
return layout.Dimens{Size: d, Baseline: d.Y}
|
||||
return layout.Dimensions{Size: d, Baseline: d.Y}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user