    def centre(self, text, y, colour=7, attr=0, colour_map=None):
        """
        Centre the text on the specified line (y) using the optional colour and attributes.

        :param text: The (single line) text to be printed.
        :param y: The line (y coord) for the start of the text.
        :param colour: The colour of the text to be displayed.
        :param attr: The cell attribute of the text to be displayed.
        :param colour_map: Colour/attribute list for multi-colour text.

        The colours and attributes are the COLOUR_xxx and A_yyy constants
        defined in the Screen class.
        """
        if self._unicode_aware:
            x = (self.width - wcswidth(text)) // 2
        else:
            x = (self.width - len(text)) // 2
        self.paint(text, x, y, colour, attr, colour_map=colour_map)
Centre the text on the specified line (y) using the optional colour and attributes.

:param text: The (single line) text to be printed.
:param y: The line (y coord) for the start of the text.
:param colour: The colour of the text to be displayed.
:param attr: The cell attribute of the text to be displayed.
:param colour_map: Colour/attribute list for multi-colour text.

The colours and attributes are the COLOUR_xxx and A_yyy constants
defined in the Screen class.
asciimatics/screen.py