Skip to content

Conversation

@jinwoo-park-68
Copy link

I solved the issue #4502.

The problem was that subsurface.fill, the function defined in surface.c, worked differently from the function pygame.draw.rect.

As the author of issue #4502 showed with the example of 100 * 100 square, even with the same coordinates, surface.fill filled all the 100 * 100 area and pygame.draw.rect filled only the 50 * 50 area.

However, subsurface.fill should work in the same way of pygame.draw.rect, and it means that the function needs to fill the area from the start coordinates (x, y) to the coordinates (x + dx, y + dy) and cut off the area with negative coordinates.

I implemented this, so please check it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant