On Wednesday 14 October 2009, Thomas Olsen wrote: > Hi > > I've been googling all day to find a way to use a custom icon for your > Plasmoid. > > I found the following snippet in http://code.google.com/p/gmail- > plasmoid/source/diff?spec=svn22&r=22&format=side&path=/trunk/contents/code/ > main.py
icon to be shown in the widgets explorer, icon of te popupapplet, or..? > > # Install icon if required > kdehome = str(KGlobal.dirs().localkdedir()) > if not os.path.exists(kdehome+"share/icons/gmail-plasmoid.svg"): > try: > shutil.copy(self.package().path() + > "contents/icons/gmail-plasmoid.svg", > kdehome+"share/icons/gmail-plasmoid.svg") > except: > print "Problem copying icon" > print "Unexpected error:", sys.exc_info()[0] > > Is this really the best way to do it? > I think that ideally you should just place your icon somewhere under > contents/icons, put it in the metadata.desktop file under "Icon" and it > should be recognized by Plasma. > > BTW: The file hierarchy of a Plasmoid isn't really well documented anywhere > that I can find. If anyone can explain it to me I will be happy to document > it on TechBase. > -- Marco Martin _______________________________________________ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel