:right-sidebar: True Tile =================================================================== .. currentmodule:: gi.repository.Shumate .. class:: Tile(**properties: ~typing.Any) :no-contents-entry: Superclasses: :class:`~gi.repository.GObject.Object` An object that represents map tiles. Tiles are loaded by a :obj:`~gi.repository.Shumate.MapSource`\. Constructors ------------ .. rst-class:: interim-class .. class:: Tile :no-index: .. classmethod:: new() -> ~gi.repository.Shumate.Tile Creates an instance of :obj:`~gi.repository.Shumate.Tile`\. .. classmethod:: new_full(x: int, y: int, size: int, zoom_level: int) -> ~gi.repository.Shumate.Tile Creates an instance of :obj:`~gi.repository.Shumate.Tile`\. :param x: the x position :param y: the y position :param size: the size in pixels :param zoom_level: the zoom level Methods ------- .. rst-class:: interim-class .. class:: Tile :no-index: .. method:: get_fade_in() -> bool Checks whether the tile should fade in. .. method:: get_paintable() -> ~gi.repository.Gdk.Paintable | None Get the :obj:`~gi.repository.Gdk.Paintable` representing this tile. .. method:: get_scale_factor() -> float Gets the scale factor of the tile. .. versionadded:: 1.1 .. method:: get_size() -> int Gets the tile's size. .. method:: get_state() -> ~gi.repository.Shumate.State Gets the current state of tile loading. .. method:: get_x() -> int Gets the tile's x position. .. method:: get_y() -> int Gets the tile's y position. .. method:: get_zoom_level() -> int Gets the tile's zoom level. .. method:: set_fade_in(fade_in: bool) -> None Sets the flag determining whether the tile should fade in when loading :param fade_in: determines whether the tile should fade in when loading .. method:: set_paintable(paintable: ~gi.repository.Gdk.Paintable) -> None Sets the :obj:`~gi.repository.Gdk.Paintable` representing this tile. :param paintable: a :obj:`~gi.repository.Gdk.Paintable` .. method:: set_scale_factor(scale_factor: float) -> None Sets the scale factor of the tile. .. versionadded:: 1.1 :param scale_factor: the scale factor .. method:: set_size(size: int) -> None Sets the tile's size :param size: the size in pixels .. method:: set_state(state: ~gi.repository.Shumate.State) -> None Sets the tile's :obj:`~gi.repository.Shumate.State` :param state: a :obj:`~gi.repository.Shumate.State` .. method:: set_x(x: int) -> None Sets the tile's x position :param x: the position .. method:: set_y(y: int) -> None Sets the tile's y position :param y: the position .. method:: set_zoom_level(zoom_level: int) -> None Sets the tile's zoom level :param zoom_level: the zoom level Properties ---------- .. rst-class:: interim-class .. class:: Tile :no-index: .. attribute:: props.fade_in :type: bool The type of the None singleton. .. attribute:: props.paintable :type: ~gi.repository.Gdk.Paintable The type of the None singleton. .. attribute:: props.scale_factor :type: float The type of the None singleton. .. versionadded:: 1.1 .. attribute:: props.size :type: int The type of the None singleton. .. attribute:: props.state :type: ~gi.repository.Shumate.State The type of the None singleton. .. attribute:: props.x :type: int The type of the None singleton. .. attribute:: props.y :type: int The type of the None singleton. .. attribute:: props.zoom_level :type: int The type of the None singleton.