mirror of
https://git.sr.ht/~eliasnaur/gio
synced 2026-07-05 17:35:36 +00:00
cmd,example: fix uses of color.NRGBA
Signed-off-by: Egon Elbre <egonelbre@gmail.com>
This commit is contained in:
@@ -96,11 +96,11 @@ func runEndToEndTest(t *testing.T, driver TestDriver) {
|
||||
t.Log("starting driver and gio app")
|
||||
driver.Start("testdata/red.go")
|
||||
|
||||
beef := color.RGBA{R: 0xde, G: 0xad, B: 0xbe}
|
||||
white := color.RGBA{R: 0xff, G: 0xff, B: 0xff}
|
||||
black := color.RGBA{R: 0x00, G: 0x00, B: 0x00}
|
||||
gray := color.RGBA{R: 0xbb, G: 0xbb, B: 0xbb}
|
||||
red := color.RGBA{R: 0xff, G: 0x00, B: 0x00}
|
||||
beef := color.NRGBA{R: 0xde, G: 0xad, B: 0xbe, A: 0xff}
|
||||
white := color.NRGBA{R: 0xff, G: 0xff, B: 0xff, A: 0xff}
|
||||
black := color.NRGBA{R: 0x00, G: 0x00, B: 0x00, A: 0xff}
|
||||
gray := color.NRGBA{R: 0xbb, G: 0xbb, B: 0xbb, A: 0xff}
|
||||
red := color.NRGBA{R: 0xff, G: 0x00, B: 0x00, A: 0xff}
|
||||
|
||||
// These are the four colors at the beginning.
|
||||
t.Log("taking initial screenshot")
|
||||
@@ -181,7 +181,7 @@ func (m colorMismatch) String() string {
|
||||
)
|
||||
}
|
||||
|
||||
func checkImageCorners(img image.Image, topLeft, topRight, botLeft, botRight color.RGBA) error {
|
||||
func checkImageCorners(img image.Image, topLeft, topRight, botLeft, botRight color.Color) error {
|
||||
// The colors are split in four rectangular sections. Check the corners
|
||||
// of each of the sections. We check the corners left to right, top to
|
||||
// bottom, like when reading left-to-right text.
|
||||
|
||||
Reference in New Issue
Block a user