Skip to content

Commit 16fc5ec

Browse files
committed
Make LA transform fill opaque, consistent with RGBA
test_fill[LA] asserted (76, 0): a transparent fill for an opaque "red" fillcolor. That was a side effect of getcolor("red", "La") returning a bare graylevel int, so the transform's internal La fill defaulted alpha to 0. With getcolor now returning (76, 255), the LA fill matches both the RGBA case and Image.new("LA", ..., "red").
1 parent 072f1e9 commit 16fc5ec

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Tests/test_image_transform.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ def test_quad(self) -> None:
9494
(
9595
("RGB", (255, 0, 0)),
9696
("RGBA", (255, 0, 0, 255)),
97-
("LA", (76, 0)),
97+
("LA", (76, 255)),
9898
),
9999
)
100100
def test_fill(self, mode: str, expected_pixel: tuple[int, ...]) -> None:

0 commit comments

Comments
 (0)