def on_uninstall_btn_clicked(self, button): try: UninstallFont(self.font) self.js_installed_check() except AttributeError: head = _("This the uninstall button.") message = _("Select a font on the left and press this button. It will be removed from your system.") Window.info_dialog(self, head, message)
def on_info_btn_clicked(self, button): try: info_url = "http://www.google.com/webfonts/specimen/" + \ self.font.replace(' ', '+', -1) Gtk.show_uri(None, info_url, 0) except AttributeError: head = _("This the info button.") message = _("Select a font on the left and press this button. A browser will open with further information about the chosen font.") Window.info_dialog(self,head, message)
def on_download_btn_clicked(self, button): try: try: DownloadFont(self.font, uri=None) self.js_installed_check() except DownloadError: self.download_failed() except AttributeError: head = _("This the install button.") message = _("Select a font on the left and press this button. The font will be installed for off-line use.") Window.info_dialog(self, head, message)