def get_width(self):
        """
        Returns the Widget target width.

        :return: Widget target width.
        :rtype: int
        """

        return self.__margin + \
               self.__editor.fontMetrics().width(foundations.strings.to_string(max(1, self.__editor.blockCount())))
Returns the Widget target width.

        :return: Widget target width.
        :rtype: int