From 17fc7b06f04adc8b1bfe47777b6f2e6350041c97 Mon Sep 17 00:00:00 2001
From: Kovid Goyal ' +
- _('If checked, this column will be displayed as HTML in '
- 'Book details and the Content server. This can be used to '
- 'construct links with the template language. For example, '
- 'the template '
- '<big><b>{title}</b></big>'
- '{series:| [|}{series_index:| [|]]}
'
- 'will create a field displaying the title in bold large '
- 'characters, along with the series, for example
"'
- 'An Oblique Approach [Belisarius [1]]". The template '
- '<a href="https://www.beam-ebooks.de/ebook/{identifiers'
- ':select(beam)}">Beam book</a>
'
- 'will generate a link to the book on the Beam e-books site.') + '
' + _( + 'If checked, this column will be displayed as HTML in ' + 'Book details and the Content server. This can be used to ' + 'construct links with the template language. For example, ' + 'the template ' + '
<big><b>{title}</b></big>' + '{series:| [|}{series_index:| [|]]}' + 'will create a field displaying the title in bold large ' + 'characters, along with the series, for example
<a href="https://www.beam-ebooks.de/ebook/{identifiers' + ':select(beam)}">Beam book</a>' + 'will generate a link to the book on the Beam e-books site.') + '') l.addWidget(cch) add_row(None, l) @@ -414,13 +414,13 @@ class CreateCustomColumn(QDialog): '
' + _('Default: Not formatted. For format language details see' ' the Python documentation')) if col_type == 'int': - self.format_box.setToolTip('
' +
- _('Examples: The format {0:0>4d}
'
+ self.format_box.setToolTip('
' + _(
+ 'Examples: The format {0:0>4d}
'
'gives a 4-digit number with leading zeros. The format '
'{0:d} days
prints the number then the word "days"')+ '
' +
- _('Examples: The format {0:.1f}
gives a floating '
+ self.format_box.setToolTip('
' + _(
+ 'Examples: The format {0:.1f}
gives a floating '
'point number with 1 digit after the decimal point. The format '
'Price: $ {0:,.2f}
prints '
'"Price $ " then displays the number with 2 digits '
@@ -447,7 +447,7 @@ class CreateCustomColumn(QDialog):
return self.simple_error('', _('No lookup name was provided'))
if col.startswith('#'):
col = col[1:]
- if re.match('^\w*$', col) is None or not col[0].isalpha() or col.lower() != col:
+ if re.match(r'^\w*$', col) is None or not col[0].isalpha() or col.lower() != col:
return self.simple_error('', _('The lookup name must contain only '
'lower case letters, digits and underscores, and start with a letter'))
if col.endswith('_index'):