pygame.Rect(left, top, width, height): return Rect pygame.Rect((left,
top), (width, height)): return Rect pygame.Rect(object): return Rect
pygame object for storing rectangular coordinates
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
a new object with type S, a subtype of T
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
clamp(...)
Rect.clamp(Rect): return Rect moves the rectangle inside another |
source code
|
|
|
clamp_ip(...)
Rect.clamp_ip(Rect): return None moves the rectangle inside another,
in place |
source code
|
|
|
clip(...)
Rect.clip(Rect): return Rect crops a rectangle inside another |
source code
|
|
|
collidedict(...)
Rect.collidedict(dict): return (key, value) test if one rectangle in
a dictionary intersects |
source code
|
|
|
collidedictall(...)
Rect.collidedictall(dict): return [(key, value), ...] test if all
rectangles in a dictionary intersect |
source code
|
|
|
collidelist(...)
Rect.collidelist(list): return index test if one rectangle in a list
intersects |
source code
|
|
|
collidelistall(...)
Rect.collidelistall(list): return indices test if all rectangles in a
list intersect |
source code
|
|
|
collidepoint(...)
Rect.collidepoint(x, y): return bool Rect.collidepoint((x,y)): return
bool test if a point is inside a rectangle |
source code
|
|
|
colliderect(...)
Rect.colliderect(Rect): return bool test if two rectangles overlap |
source code
|
|
|
contains(...)
Rect.contains(Rect): return bool test if one rectangle is inside
another |
source code
|
|
|
copy(...)
Rect.copy(): return Rect copy the rectangle |
source code
|
|
|
fit(...)
Rect.fit(Rect): return Rect resize and move a rectangle with aspect
ratio |
source code
|
|
|
inflate(...)
Rect.inflate(x, y): return Rect grow or shrink the rectangle size |
source code
|
|
|
inflate_ip(...)
Rect.inflate_ip(x, y): return None grow or shrink the rectangle size,
in place |
source code
|
|
|
move(...)
Rect.move(x, y): return Rect moves the rectangle |
source code
|
|
|
move_ip(...)
Rect.move_ip(x, y): return None moves the rectangle, in place |
source code
|
|
|
normalize(...)
Rect.normalize(): return None correct negative sizes |
source code
|
|
|
union(...)
Rect.union(Rect): return Rect joins two rectangles into one |
source code
|
|
|
union_ip(...)
Rect.union_ip(Rect): return None joins two rectangles into one, in
place |
source code
|
|
|
unionall(...)
Rect.unionall(Rect_sequence): return Rect the union of many
rectangles |
source code
|
|
|
unionall_ip(...)
Rect.unionall_ip(Rect_sequence): return None the union of many
rectangles, in place |
source code
|
|
Inherited from object :
__delattr__ ,
__format__ ,
__getattribute__ ,
__hash__ ,
__reduce_ex__ ,
__setattr__ ,
__sizeof__ ,
__subclasshook__
|