def _get_ref(self, size=None):
        """ Return the resource manager reference to the image. """

        if self._ref is None:
            self._ref = resource_manager.locate_image(self.name,
                    self.search_path, size)

        return self._ref
Beispiel #2
0
    def _get_ref(self, size=None):
        """ Return the resource manager reference to the image.

        Parameters
        ----------
        size : (int, int) or None
            The desired size as a width, height tuple, or None if wanting
            default image size.

        Returns
        -------
        ref : ImageReference instance
            The reference to the requested image.
        """

        if self._ref is None:
            self._ref = resource_manager.locate_image(self.name,
                    self.search_path, size)

        return self._ref
Beispiel #3
0
    def _get_ref(self, size=None):
        """ Return the resource manager reference to the image.

        Parameters
        ----------
        size : (int, int) or None
            The desired size as a width, height tuple, or None if wanting
            default image size.

        Returns
        -------
        ref : ImageReference instance
            The reference to the requested image.
        """

        if self._ref is None:
            self._ref = resource_manager.locate_image(self.name,
                                                      self.search_path, size)

        return self._ref