def ask_about_inserting_epubs(self): ''' Build question dialog with details about kobo books that couldn't be added to calibre as new books. ''' ''' Terisa: Improve the message ''' caption = PLUGIN_NAME + ' v' + PLUGIN_VERSION plural = format_plural(len(self.ids_of_new_books)) det_msg = '' if self.count > 1: msg = _('<p><b>{0}</b> EPUB{2} successfully added to library.<br /><br /><b>{1}</b> ').format(len(self.ids_of_new_books), len(self.duplicate_book_list), plural) msg += _('not added because books with the same title/author were detected.<br /><br />Would you like to try and add the EPUB format{0}').format(plural) msg += _(' to those existing entries?<br /><br />NOTE: no pre-existing EPUBs will be overwritten.') for entry in self.duplicate_book_list: det_msg += _('{0} -- not added because of {1} in your library.\n\n').format(entry[0].title, entry[2]) else: msg = _('<p><b>{0}</b> -- not added because of {1} in your library.<br /><br />').format(self.duplicate_book_list[0][0].title, self.duplicate_book_list[0][2]) msg += _('Would you like to try and add the EPUB format to an available calibre duplicate?<br /><br />') msg += _('NOTE: no pre-existing EPUB will be overwritten.') return question_dialog(self.gui, caption, msg, det_msg)