String changes

This commit is contained in:
Kovid Goyal 2017-04-25 10:38:42 +05:30
parent 910886157d
commit c4d2fcc3c1
15 changed files with 33 additions and 39 deletions

View File

@ -569,12 +569,13 @@ used by default.
You can also change settings in the conversion dialog for each book conversion. You can also change settings in the conversion dialog for each book conversion.
When you convert a book, calibre remembers the settings you used for that book, When you convert a book, calibre remembers the settings you used for that book,
so that if you convert it again, the saved settings for the individual book so that if you convert it again, the saved settings for the individual book
will take precedence over the defaults set in Preferences. You can restore the will take precedence over the defaults set in :guilabel:`Preferences`. You can
individual settings to defaults by using the :guilabel:`Restore to defaults` restore the individual settings to defaults by using the :guilabel:`Restore defaults`
button in the individual book conversion dialog. You can remove the saved button in the individual book conversion dialog. You can remove the
settings for a group of books by selecting all the books and then clicking the saved settings for a group of books by selecting all the books and then
edit metadata button to bring up the bulk metadata edit dialog, near the bottom clicking the :guilabel:`Edit metadata` button to bring up the bulk metadata
of the dialog is an option to remove stored conversion settings. edit dialog, near the bottom of the dialog is an option to remove stored
conversion settings.
When you Bulk Convert a set of books, settings are taken in the following order (last one wins): When you Bulk Convert a set of books, settings are taken in the following order (last one wins):

View File

@ -358,7 +358,7 @@ class RARMetadataReader(MetadataReaderPlugin):
name = 'Read RAR metadata' name = 'Read RAR metadata'
file_types = set(['rar']) file_types = set(['rar'])
description = _('Read metadata from ebooks in RAR archives') description = _('Read metadata from e-books in RAR archives')
def get_metadata(self, stream, ftype): def get_metadata(self, stream, ftype):
from calibre.ebooks.metadata.rar import get_metadata from calibre.ebooks.metadata.rar import get_metadata
@ -439,7 +439,7 @@ class ZipMetadataReader(MetadataReaderPlugin):
name = 'Read ZIP metadata' name = 'Read ZIP metadata'
file_types = set(['zip', 'oebzip']) file_types = set(['zip', 'oebzip'])
description = _('Read metadata from ebooks in ZIP archives') description = _('Read metadata from e-books in ZIP archives')
def get_metadata(self, stream, ftype): def get_metadata(self, stream, ftype):
from calibre.ebooks.metadata.zip import get_metadata from calibre.ebooks.metadata.zip import get_metadata
@ -1005,13 +1005,13 @@ class ActionCopyToLibrary(InterfaceActionBase):
class ActionTweakEpub(InterfaceActionBase): class ActionTweakEpub(InterfaceActionBase):
name = 'Tweak ePub' name = 'Tweak ePub'
actual_plugin = 'calibre.gui2.actions.tweak_epub:TweakEpubAction' actual_plugin = 'calibre.gui2.actions.tweak_epub:TweakEpubAction'
description = _('Edit e-books in the epub or azw3 formats') description = _('Edit e-books in the EPUB or AZW3 formats')
class ActionUnpackBook(InterfaceActionBase): class ActionUnpackBook(InterfaceActionBase):
name = 'Unpack Book' name = 'Unpack Book'
actual_plugin = 'calibre.gui2.actions.unpack_book:UnpackBookAction' actual_plugin = 'calibre.gui2.actions.unpack_book:UnpackBookAction'
description = _('Make small changes to epub or htmlz files in your calibre library') description = _('Make small changes to EPUB or HTMLZ files in your calibre library')
class ActionNextMatch(InterfaceActionBase): class ActionNextMatch(InterfaceActionBase):

View File

@ -21,7 +21,7 @@ this command starts an embedded python interpreter. You can also run the main
calibre GUI, the calibre viewer and the calibre editor in debug mode. calibre GUI, the calibre viewer and the calibre editor in debug mode.
It also contains interfaces to various bits of calibre that do not have It also contains interfaces to various bits of calibre that do not have
dedicated command line tools, such as font subsetting, the ebook diff tool and so dedicated command line tools, such as font subsetting, the e-book diff tool and so
on. on.
You can also use %prog to run standalone scripts. To do that use it like this: You can also use %prog to run standalone scripts. To do that use it like this:
@ -44,7 +44,7 @@ Everything after the -- is passed to the script.
' specified path. For internal use only, use the -g' ' specified path. For internal use only, use the -g'
' option to run the GUI in debug mode')) ' option to run the GUI in debug mode'))
parser.add_option('-w', '--viewer', default=False, action='store_true', parser.add_option('-w', '--viewer', default=False, action='store_true',
help=_('Run the ebook viewer in debug mode')) help=_('Run the e-book viewer in debug mode'))
parser.add_option('--paths', default=False, action='store_true', parser.add_option('--paths', default=False, action='store_true',
help=_('Output the paths necessary to setup the calibre environment')) help=_('Output the paths necessary to setup the calibre environment'))
parser.add_option('--add-simple-plugin', default=None, parser.add_option('--add-simple-plugin', default=None,

View File

@ -15,7 +15,7 @@ class README(USBMS):
name = 'Binatone Readme Device Interface' name = 'Binatone Readme Device Interface'
gui_name = 'Binatone Readme' gui_name = 'Binatone Readme'
description = _('Communicate with the Binatone Readme eBook reader.') description = _('Communicate with the Binatone Readme e-book reader.')
author = 'John Schember' author = 'John Schember'
supported_platforms = ['windows', 'osx', 'linux'] supported_platforms = ['windows', 'osx', 'linux']
@ -54,4 +54,3 @@ class README(USBMS):
drives['main'] = carda drives['main'] = carda
drives['carda'] = main drives['carda'] = main
return drives return drives

View File

@ -14,7 +14,7 @@ class ESLICK(USBMS):
name = 'ESlick Device Interface' name = 'ESlick Device Interface'
gui_name = 'Foxit ESlick' gui_name = 'Foxit ESlick'
description = _('Communicate with the ESlick eBook reader.') description = _('Communicate with the ESlick e-book reader.')
author = 'Kovid Goyal' author = 'Kovid Goyal'
supported_platforms = ['windows', 'osx', 'linux'] supported_platforms = ['windows', 'osx', 'linux']
@ -46,7 +46,7 @@ class EBK52(ESLICK):
name = 'EBK-52 Device Interface' name = 'EBK-52 Device Interface'
gui_name = 'Sigmatek EBK' gui_name = 'Sigmatek EBK'
description = _('Communicate with the Sigmatek eBook reader.') description = _('Communicate with the Sigmatek e-book reader.')
FORMATS = ['epub', 'fb2', 'pdf', 'txt'] FORMATS = ['epub', 'fb2', 'pdf', 'txt']
@ -59,5 +59,3 @@ class EBK52(ESLICK):
@classmethod @classmethod
def can_handle(cls, dev, debug=False): def can_handle(cls, dev, debug=False):
return (dev[3], dev[4]) == ('philips', 'Philips d') return (dev[3], dev[4]) == ('philips', 'Philips d')

View File

@ -17,7 +17,7 @@ class HANLINV3(USBMS):
name = 'Hanlin V3 driver' name = 'Hanlin V3 driver'
gui_name = 'Hanlin V3' gui_name = 'Hanlin V3'
description = _('Communicate with Hanlin V3 eBook readers.') description = _('Communicate with Hanlin V3 e-book readers.')
author = 'Tijmen Ruizendaal' author = 'Tijmen Ruizendaal'
supported_platforms = ['windows', 'osx', 'linux'] supported_platforms = ['windows', 'osx', 'linux']
@ -97,7 +97,7 @@ class SPECTRA(HANLINV3):
class HANLINV5(HANLINV3): class HANLINV5(HANLINV3):
name = 'Hanlin V5 driver' name = 'Hanlin V5 driver'
gui_name = 'Hanlin V5' gui_name = 'Hanlin V5'
description = _('Communicate with Hanlin V5 eBook readers.') description = _('Communicate with Hanlin V5 e-book readers.')
VENDOR_ID = [0x0492] VENDOR_ID = [0x0492]
PRODUCT_ID = [0x8813] PRODUCT_ID = [0x8813]
@ -116,7 +116,7 @@ class BOOX(HANLINV3):
name = 'BOOX driver' name = 'BOOX driver'
gui_name = 'BOOX' gui_name = 'BOOX'
description = _('Communicate with the BOOX eBook reader.') description = _('Communicate with the BOOX e-book reader.')
author = 'Jesus Manuel Marinho Valcarce' author = 'Jesus Manuel Marinho Valcarce'
supported_platforms = ['windows', 'osx', 'linux'] supported_platforms = ['windows', 'osx', 'linux']
METADATA_CACHE = '.metadata.calibre' METADATA_CACHE = '.metadata.calibre'
@ -159,4 +159,3 @@ class BOOX(HANLINV3):
def linux_swap_drives(self, drives): def linux_swap_drives(self, drives):
return drives return drives

View File

@ -102,7 +102,7 @@ class KOBO(USBMS):
_('Create tags for automatic management'), _('Create tags for automatic management'),
_('Upload covers for books (newer readers)') + _('Upload covers for books (newer readers)') +
':::'+_('Normally, the KOBO readers get the cover image from the' ':::'+_('Normally, the KOBO readers get the cover image from the'
' ebook file itself. With this option, calibre will send a ' ' e-book file itself. With this option, calibre will send a '
'separate cover image to the reader, useful if you ' 'separate cover image to the reader, useful if you '
'have modified the cover.'), 'have modified the cover.'),
_('Upload Black and White Covers'), _('Upload Black and White Covers'),

View File

@ -179,7 +179,7 @@ class BookUploadsGroupBox(DeviceOptionsGroupBox):
self.modify_css_checkbox = create_checkbox( self.modify_css_checkbox = create_checkbox(
_("Modify CSS"), _("Modify CSS"),
_('This allows addition of user CSS rules and removal of some CSS. ' _('This allows addition of user CSS rules and removal of some CSS. '
'When sending a book, the driver adds the contents of {0} to all stylesheets in the ePub. ' 'When sending a book, the driver adds the contents of {0} to all stylesheets in the EPUB. '
'This file is searched for in the root directory of the main memory of the device. ' 'This file is searched for in the root directory of the main memory of the device. '
'As well as this, if the file contains settings for the "orphans" or "widows", ' 'As well as this, if the file contains settings for the "orphans" or "widows", '
'these are removed for all styles in the original stylesheet.').format(device.KOBO_EXTRA_CSSFILE), 'these are removed for all styles in the original stylesheet.').format(device.KOBO_EXTRA_CSSFILE),

View File

@ -20,7 +20,7 @@ class PRS505(USBMS):
name = 'SONY Device Interface' name = 'SONY Device Interface'
gui_name = 'SONY Reader' gui_name = 'SONY Reader'
description = _('Communicate with Sony eBook readers older than the' description = _('Communicate with Sony e-book readers older than the'
' PRST1.') ' PRST1.')
author = 'Kovid Goyal' author = 'Kovid Goyal'
supported_platforms = ['windows', 'osx', 'linux'] supported_platforms = ['windows', 'osx', 'linux']
@ -75,7 +75,7 @@ class PRS505(USBMS):
abt='abt', abtv=ALL_BY_TITLE, aba='aba', abav=ALL_BY_AUTHOR), abt='abt', abtv=ALL_BY_TITLE, aba='aba', abav=ALL_BY_AUTHOR),
_('Upload separate cover thumbnails for books (newer readers)') + ':::'+ _('Upload separate cover thumbnails for books (newer readers)') + ':::'+
_('Normally, the SONY readers get the cover image from the' _('Normally, the SONY readers get the cover image from the'
' ebook file itself. With this option, calibre will send a ' ' e-book file itself. With this option, calibre will send a '
'separate cover image to the reader, useful if you are ' 'separate cover image to the reader, useful if you are '
'sending DRMed books in which you cannot change the cover.' 'sending DRMed books in which you cannot change the cover.'
' WARNING: This option should only be used with newer ' ' WARNING: This option should only be used with newer '
@ -298,4 +298,3 @@ class PRS505(USBMS):
with lopen(cpath, 'wb') as f: with lopen(cpath, 'wb') as f:
f.write(metadata.thumbnail[-1]) f.write(metadata.thumbnail[-1])
debug_print('Cover uploaded to: %r'%cpath) debug_print('Cover uploaded to: %r'%cpath)

View File

@ -38,7 +38,7 @@ class ImageWrapper(object):
class PRST1(USBMS): class PRST1(USBMS):
name = 'SONY PRST1 and newer Device Interface' name = 'SONY PRST1 and newer Device Interface'
gui_name = 'SONY Reader' gui_name = 'SONY Reader'
description = _('Communicate with the PRST1 and newer SONY eBook readers') description = _('Communicate with the PRST1 and newer SONY e-book readers')
author = 'Kovid Goyal' author = 'Kovid Goyal'
supported_platforms = ['windows', 'osx', 'linux'] supported_platforms = ['windows', 'osx', 'linux']
path_sep = '/' path_sep = '/'

View File

@ -338,7 +338,7 @@ class USBMS(CLI, Device):
:param filename: The name of the book file without the extension. :param filename: The name of the book file without the extension.
:param metadata: metadata belonging to the book. Use metadata.thumbnail :param metadata: metadata belonging to the book. Use metadata.thumbnail
for cover for cover
:param filepath: The full path to the ebook file :param filepath: The full path to the e-book file
''' '''
pass pass

View File

@ -21,17 +21,17 @@ from calibre.utils.localization import localize_user_manual_link
USAGE = '%prog ' + _('''\ USAGE = '%prog ' + _('''\
input_file output_file [options] input_file output_file [options]
Convert an ebook from one format to another. Convert an e-book from one format to another.
input_file is the input and output_file is the output. Both must be \ input_file is the input and output_file is the output. Both must be \
specified as the first two arguments to the command. specified as the first two arguments to the command.
The output ebook format is guessed from the file extension of \ The output e-book format is guessed from the file extension of \
output_file. output_file can also be of the special format .EXT where \ output_file. output_file can also be of the special format .EXT where \
EXT is the output file extension. In this case, the name of the output \ EXT is the output file extension. In this case, the name of the output \
file is derived from the name of the input file. Note that the filenames must \ file is derived from the name of the input file. Note that the filenames must \
not start with a hyphen. Finally, if output_file has no extension, then \ not start with a hyphen. Finally, if output_file has no extension, then \
it is treated as a directory and an "open ebook" (OEB) consisting of HTML \ it is treated as a directory and an "open e-book" (OEB) consisting of HTML \
files is written to that directory. These files are the files that would \ files is written to that directory. These files are the files that would \
normally have been passed to the output plugin. normally have been passed to the output plugin.
@ -269,7 +269,7 @@ def add_pipeline_options(parser, plumber):
def option_parser(): def option_parser():
parser = OptionParser(usage=USAGE) parser = OptionParser(usage=USAGE)
parser.add_option('--list-recipes', default=False, action='store_true', parser.add_option('--list-recipes', default=False, action='store_true',
help=_('List builtin recipe names. You can create an ebook from ' help=_('List builtin recipe names. You can create an e-book from '
'a builtin recipe like this: ebook-convert "Recipe Name.recipe" ' 'a builtin recipe like this: ebook-convert "Recipe Name.recipe" '
'output.epub')) 'output.epub'))
return parser return parser

View File

@ -55,7 +55,7 @@ class ComicInput(InputFormatPlugin):
"alphabetically by name. Instead use the order they were " "alphabetically by name. Instead use the order they were "
"added to the comic.")), "added to the comic.")),
OptionRecommendation(name='output_format', choices=['png', 'jpg'], OptionRecommendation(name='output_format', choices=['png', 'jpg'],
recommended_value='png', help=_('The format that images in the created ebook ' recommended_value='png', help=_('The format that images in the created e-book '
'are converted to. You can experiment to see which format gives ' 'are converted to. You can experiment to see which format gives '
'you optimal size and look on your device.')), 'you optimal size and look on your device.')),
OptionRecommendation(name='no_process', recommended_value=False, OptionRecommendation(name='no_process', recommended_value=False,
@ -261,4 +261,3 @@ class ComicInput(InputFormatPlugin):
f.write(wrapper.encode('utf-8')) f.write(wrapper.encode('utf-8'))
wrappers.append(page) wrappers.append(page)
return wrappers return wrappers

View File

@ -18,7 +18,7 @@ class DOCXInput(InputFormatPlugin):
options = { options = {
OptionRecommendation(name='docx_no_cover', recommended_value=False, OptionRecommendation(name='docx_no_cover', recommended_value=False,
help=_('Normally, if a large image is present at the start of the document that looks like a cover, ' help=_('Normally, if a large image is present at the start of the document that looks like a cover, '
'it will be removed from the document and used as the cover for created ebook. This option ' 'it will be removed from the document and used as the cover for created e-book. This option '
'turns off that behavior.')), 'turns off that behavior.')),
OptionRecommendation(name='docx_no_pagebreaks_between_notes', recommended_value=False, OptionRecommendation(name='docx_no_pagebreaks_between_notes', recommended_value=False,
help=_('Do not insert a page break after every endnote.')), help=_('Do not insert a page break after every endnote.')),
@ -32,4 +32,3 @@ class DOCXInput(InputFormatPlugin):
from calibre.ebooks.docx.to_html import Convert from calibre.ebooks.docx.to_html import Convert
return Convert(stream, detect_cover=not options.docx_no_cover, log=log, notes_nopb=options.docx_no_pagebreaks_between_notes, return Convert(stream, detect_cover=not options.docx_no_cover, log=log, notes_nopb=options.docx_no_pagebreaks_between_notes,
nosupsub=options.docx_inline_subsup)() nosupsub=options.docx_inline_subsup)()

View File

@ -49,7 +49,7 @@ class BasicNewsRecipe(Recipe):
to creating recipes, see :doc:`news`. to creating recipes, see :doc:`news`.
''' '''
#: The title to use for the ebook #: The title to use for the e-book
title = _('Unknown News Source') title = _('Unknown News Source')
#: A couple of lines that describe the content this recipe downloads. #: A couple of lines that describe the content this recipe downloads.
@ -106,7 +106,7 @@ class BasicNewsRecipe(Recipe):
#: Convenient flag to disable loading of stylesheets for websites #: Convenient flag to disable loading of stylesheets for websites
#: that have overly complex stylesheets unsuitable for conversion #: that have overly complex stylesheets unsuitable for conversion
#: to ebooks formats. #: to e-book formats.
#: If True stylesheets are not downloaded and processed #: If True stylesheets are not downloaded and processed
no_stylesheets = False no_stylesheets = False