diff --git a/buildconfig/stubs/pygame/display.pyi b/buildconfig/stubs/pygame/display.pyi index c12630ca09..43e1ec8c05 100644 --- a/buildconfig/stubs/pygame/display.pyi +++ b/buildconfig/stubs/pygame/display.pyi @@ -47,8 +47,10 @@ def set_mode( def get_surface() -> Optional[Surface]: ... def flip() -> None: ... @overload +def update() -> None: ... +@overload def update( - rectangle: Optional[Union[RectLike, Iterable[Optional[RectLike]]]] = None, / + rectangle: Optional[Union[RectLike, Iterable[Optional[RectLike]]]], / ) -> None: ... @overload def update(x: float, y: float, w: float, h: float, /) -> None: ... diff --git a/docs/reST/ref/display.rst b/docs/reST/ref/display.rst index c739bfbf57..223a3744de 100644 --- a/docs/reST/ref/display.rst +++ b/docs/reST/ref/display.rst @@ -273,7 +273,10 @@ required). .. function:: update | :sl:`Update all, or a portion, of the display. For non-OpenGL displays.` - | :sg:`update(rectangle=None, /) -> None` + | :sg:`update() -> None` + | :sg:`update(rectangle, /) -> None` + | :sg:`update(x, y, w, h, /) -> None` + | :sg:`update((x, y), (w, h), /) -> None` | :sg:`update(rectangle_iterable, /) -> None` For non OpenGL display Surfaces, this function is very similar to