Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • Orange/OrangeCanvas/registry/base.py

    r11368 r11418  
    11""" 
    2 WidgetRegistry Base 
     2=============== 
     3Widget Registry 
     4=============== 
    35 
    46""" 
     
    2022    """ 
    2123    A container for widget and category descriptions. 
    22  
    23     This class is most often used with WidgetDiscovery class but can 
    24     be used separately. 
    2524 
    2625    >>> reg = WidgetRegistry() 
     
    3837        If supplied the registry is initialized with the contents of `other`. 
    3938 
     39    See also 
     40    -------- 
     41    WidgetDiscovery 
     42 
    4043    """ 
    4144 
     
    4346        # A list of (category, widgets_list) tuples ordered by priority. 
    4447        self.registry = [] 
     48 
    4549        # tuples from 'registry' indexed by name 
    4650        self._categories_dict = {} 
    47         # WidgetDscriptions by qualified name 
     51 
     52        # WidgetDecriptions by qualified name 
    4853        self._widgets_dict = {} 
    4954 
     
    6065        """ 
    6166        Return a list all top level :class:`CategoryDescription` instances 
    62         ordered by priority. 
     67        ordered by `priority`. 
    6368 
    6469        """ 
     
    6772    def category(self, name): 
    6873        """ 
    69         Find a :class:`CategoryDescription` by its `name`. 
     74        Find and return a :class:`CategoryDescription` by its `name`. 
    7075 
    7176        .. note:: Categories are identified by `name` attribute in contrast 
     
    8287    def has_category(self, name): 
    8388        """ 
    84         Does a category with `name` exist in this registry. 
     89        Return ``True`` if a category with `name` exist in this registry. 
    8590 
    8691        Parameters 
     
    130135            Widget description qualified name 
    131136 
    132         See also 
    133         -------- 
    134         WidgetDescription 
    135  
    136137        """ 
    137138        return self._widgets_dict[qualified_name] 
     
    139140    def has_widget(self, qualified_name): 
    140141        """ 
    141         Does the widget with `qualified_name` exist in this registry. 
     142        Return ``True`` if the widget with `qualified_name` exists in 
     143        this registry. 
     144 
    142145        """ 
    143146        return qualified_name in self._widgets_dict 
Note: See TracChangeset for help on using the changeset viewer.