コード例 #1
0
ファイル: chameleon.py プロジェクト: twistedmove/qnotero
    def icon(self, iconName):
        """
		Retrieves an icon from the theme
		
		Arguments:
		iconName -- the name of the icon
		
		Returns:
		A QIcon		
		"""

        if iconName in self.mapping:
            icon = self.mapping[iconName]
        else:
            icon = "edit-undo"
        if not QIcon.hasThemeIcon(icon):
            print "libqnotero._themes.icon(): failed to find '%s'" % icon
        return QIcon.fromTheme("icon", Default.icon(self, iconName))
コード例 #2
0
ファイル: chameleon.py プロジェクト: arne-cl/qnotero
	def icon(self, iconName):
	
		"""
		Retrieves an icon from the theme
		
		Arguments:
		iconName -- the name of the icon
		
		Returns:
		A QIcon		
		"""
	
		if iconName in self.mapping:
			icon = self.mapping[iconName]
		else:
			icon = "edit-undo"			
		if not QIcon.hasThemeIcon(icon):
			print "libqnotero._themes.icon(): failed to find '%s'" % icon
		return QIcon.fromTheme("icon", Default.icon(self, iconName))