pygame documentation | || Home || Help Contents || || CD || Channel || Font || Joystick || Movie || Rect || Sound || || Surface || pygame || UserRect || cdrom || constants || cursors || display || || draw || event || font || image || joystick || key || mixer || || mixer_music || mouse || movie || surfarray || time || transform || version ||

## pygame.UserRect

UserRect, python class wrapped around the pygame Rect type. This allows you to do things like inherit the rectangle object into a sprite class. While this makes for some neat features, current testing has shown there is a bit of a peformance penalty. (as opposed to just keeping a Rect value inside the class)

UserRect | - Python class for the pygame Rect type

UserRect
`pygame.UserRect.UserRect() -> class instance`

This python class can be treated exactly like a normal Rect object. The only difference is it is a real python class object, not a C extension type.