From 16e572266a1ea820b0be8fadcde6153c8eced65f Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Thu, 3 Apr 2014 13:22:05 +0530 Subject: [PATCH] ... --- src/calibre/gui2/tweak_book/spell.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/calibre/gui2/tweak_book/spell.py b/src/calibre/gui2/tweak_book/spell.py index 1062d51a83..4ce20ab935 100644 --- a/src/calibre/gui2/tweak_book/spell.py +++ b/src/calibre/gui2/tweak_book/spell.py @@ -11,7 +11,7 @@ from collections import defaultdict from PyQt4.Qt import ( QGridLayout, QApplication, QTreeWidget, QTreeWidgetItem, Qt, QFont, - QStackedLayout, QLabel, QVBoxLayout, QVariant, QWidget, QPushButton) + QStackedLayout, QLabel, QVBoxLayout, QVariant, QWidget, QPushButton, QIcon) from calibre.gui2.tweak_book.widgets import Dialog from calibre.spell.dictionary import ( @@ -76,6 +76,9 @@ class ManageDictionaries(Dialog): self.bb.clear() self.bb.addButton(self.bb.Close) + b = self.bb.addButton(_('&Add dictionary'), self.bb.ActionRole) + b.setIcon(QIcon(I('plus.png'))) + b.clicked.connect(self.add_dictionary) l.addWidget(self.bb, l.rowCount(), 0, 1, l.columnCount()) def build_dictionaries(self): @@ -113,6 +116,9 @@ class ManageDictionaries(Dialog): self.dictionaries.expandAll() + def add_dictionary(self): + pass + def current_item_changed(self): item = self.dictionaries.currentItem() if item is not None: