Commit Graph

43916 Commits

Author SHA1 Message Date
Kovid Goyal f4bf609c25 Merge branch 'patch-1' of https://github.com/deckvig/calibre 2021-10-28 12:33:13 +05:30
Deckvig 87e24e7a98 Update amazon.py
fix get ratings fail in amazon.cn
2021-10-28 13:57:05 +08:00
Kovid Goyal 1eea54d6b5 Merge branch 'master' of https://github.com/cbhaley/calibre 2021-10-27 20:32:56 +05:30
Charles Haley 79536a7f7f Small performance improvement for sorting categories by name and first letter 2021-10-27 15:58:43 +01:00
Kovid Goyal 571841268f Kindle driver: Add support for the new Kindle PaperWhite
Lets hope nothing else is different on this device apart from the
changed BCD number. Fixes #1948883 [Add support for the 2021 Kindle Paperwhite (11th Version)](https://bugs.launchpad.net/calibre/+bug/1948883)
2021-10-27 07:28:52 +05:30
Kovid Goyal 978af25658 Bump versions of lxml and libxml2 2021-10-26 08:35:48 +05:30
Kovid Goyal c70e064c23 Content server: Fix some OPDS feeds failing with non-ASCII content. Fixes #1947879 [IOS client access, the library does not display content.](https://bugs.launchpad.net/calibre/+bug/1947879)
This was caused by an underlying libxml2 bug.
https://bugs.launchpad.net/lxml/+bug/1873306
https://gitlab.gnome.org/GNOME/libxml2/-/commit/a697ed1e24234a9e6a4a4639555dcca230f752c1

The workaround is to specify the encoding rather than using None.
2021-10-26 08:28:00 +05:30
Kovid Goyal 1a334d7577 Merge branch 'master' of https://github.com/cbhaley/calibre 2021-10-25 21:47:30 +05:30
Charles Haley 689a280a2c Move the numeric_collation tweak to global preferences with the UI in Preferences / Behaviour. I didn't put it in db.prefs because I didn't want to create a linkage between icu.py and the database. 2021-10-25 16:53:30 +01:00
Kovid Goyal 1518344dd8 ... 2021-10-24 22:20:25 +05:30
Kovid Goyal 36573fe5c8 Merge branch 'master' of https://github.com/cbhaley/calibre
Fixes #1948560 [Authors column: Odd behaviour with digits in alphabetical partitioning](https://bugs.launchpad.net/calibre/+bug/1948560)
2021-10-24 22:18:59 +05:30
Charles Haley 21a4207ad7 Bug #1948560: Odd behaviour with digits in alphabetical partitioning
This is fixed for the tag browser in the gui and the content server. I couldn't find anywhere else that used first letter partitioning.

When using first letter partitioning get_categories() constructs the sort key as follows:
- If the first character of the string is a digit (I hope isdigit() is localized) then use that digit otherwise use a string that is larger than any digit
- The ICU collation order key
- The sort key.

As such, items that start with a digit will first sort by that digit, then if needed use the ICU key as the second level then if needed use the sort key as the third level. Items that do not start with a digit will sort by the ICU key then the sort key.
2021-10-24 17:18:02 +01:00
Charles Haley 82e4b04e2f Include some tests for non_numeric_sort_collator 2021-10-24 17:08:15 +01:00
Charles Haley 06b598eb9d Fix non_numeric_sort_collator. 2021-10-24 17:07:50 +01:00
Kovid Goyal ae437852be E-book viewer: Add a button to directly open the viewer help section in the calibre user manual to the viewer controls 2021-10-24 21:21:08 +05:30
Kovid Goyal 6c45f4333d oops 2021-10-24 18:46:05 +05:30
Kovid Goyal 4958e3623d Add a clear button to the target field 2021-10-24 15:50:13 +05:30
Kovid Goyal 79a6ab5d94 Add a function to generation collation order for partitioning 2021-10-24 15:46:31 +05:30
Kovid Goyal ff32d7c4f8 oops 2021-10-24 12:24:34 +05:30
Kovid Goyal 0078c8426f E-book viewer: Prevent the display from sleeping when using auto-scroll or read aloud modes (Implemented only on Windows and macOS) 2021-10-24 12:20:12 +05:30
Kovid Goyal a44cb71cbb Platform independent wrapper for controlling sleep 2021-10-24 12:05:56 +05:30
Kovid Goyal 3fd1383c80 Wrap the Cocoa API for power management 2021-10-24 10:54:07 +05:30
Kovid Goyal f2c5a14fab Wrap the windows API to set thread execution state 2021-10-23 16:49:46 +05:30
Kovid Goyal 8972f56290 Allow setting a keyboard shortcut in Preferences->Shortcuts to open the content server in a local browser
See #1948519 ([Enhancement] Shortcut to open content server in browser)
2021-10-23 16:25:10 +05:30
Kovid Goyal e416b1c30b Edit book: Set semantics tool: Add support for EPUB 3 landmarks 2021-10-23 16:21:24 +05:30
Kovid Goyal 47143b0506 Fix #1948520 [[Enhancement] Change icon for Filter button in the User categories window](https://bugs.launchpad.net/calibre/+bug/1948520) 2021-10-23 14:30:32 +05:30
Kovid Goyal ce6e97260c Make functionality to set landmarks re-useable 2021-10-23 11:37:30 +05:30
Kovid Goyal bd7d859ac2 Make functionality to ensure nav re-useable 2021-10-23 11:29:03 +05:30
Kovid Goyal be73536c26 ... 2021-10-23 10:44:46 +05:30
Kovid Goyal 9a295fad07 Add an entry to the Connect/share menu to open the content server in a local browser when it is running. Fixes #1948493 [Enhancement Request: Open content server in browser](https://bugs.launchpad.net/calibre/+bug/1948493) 2021-10-23 09:40:06 +05:30
Kovid Goyal e22319199b typo 2021-10-22 20:02:03 +05:30
Kovid Goyal baf215b0c8 version 5.30.0 v5.30.0 2021-10-22 04:54:50 +05:30
Kovid Goyal b8c95130c2 Clean up the icon removal dialog box 2021-10-22 04:46:16 +05:30
Kovid Goyal 375eebf783 Merge branch 'master' of https://github.com/cbhaley/calibre
Fixes #1947948 [[Enhancement] Scrollable list for removing custom icons](https://bugs.launchpad.net/calibre/+bug/1947948)
2021-10-22 04:38:47 +05:30
Charles Haley 7320a9a7b3 Enhancement #1947948: Scrollable list for removing custom icons 2021-10-21 20:23:15 +01:00
Kovid Goyal 88cf8ff2bb E-book viewer: Read aloud: Allow right clicking to play/pause reading. Fixes #1946439 [[Enhancement - E-book viewer] Right mouse click to pause/play Read aloud](https://bugs.launchpad.net/calibre/+bug/1946439) 2021-10-21 19:55:20 +05:30
Kovid Goyal dd4da79f8f Merge branch 'master' of https://github.com/davidfor/calibre 2021-10-21 18:03:37 +05:30
David 3bb4031cc7 Bump Kobo firmware for Sage and Libra 2 2021-10-21 22:54:21 +11:00
Kovid Goyal ba2bd3f01b pep8 2021-10-21 11:20:08 +05:30
Kovid Goyal f9694a218c Merge branch 'py2-cleanup' of https://github.com/eli-schwartz/calibre 2021-10-21 10:38:56 +05:30
Eli Schwartz fd467c4527 perform various automated cleanups of python2-compatible code
performed using:

```
pyupgrade --keep-percent-format --py3-only
```

and committing the results.

This changes various things, including:
- remove u from u'' strings, since python3 strings are always unicode
- consolidate on OSError for various exceptions that are deprecated aliases
- dict/set literals and comprehensions
- yield from
- remove extraneous () produced by accident by some modernization code
- modern super()
- remove __future__ imports

etc.
2021-10-20 21:45:51 -04:00
Eli Schwartz 39a22268b9 py3 porting cleanup: drop str proxy
We don't need unicode_type anymore, because the str/unicode split
disappeared.

In addition to converting all unicode_type to str, there are some cases
where string literals were converted to unicode_type, e.g. for r''
strings, since ur'' didn't work. These can now be dropped entirely.
2021-10-20 21:45:24 -04:00
Eli Schwartz e794b388b4 fix incorrect log message referencing python type alias
During porting work, this got changed from "Unicode" to "unicode_type",
which was wrong.
2021-10-20 21:45:24 -04:00
Eli Schwartz 34f3033444 py3 porting cleanup: drop os.getenv/getcwd proxies
The stdlib getenv/getcwd is suitable everywhere now, so that is all that
is used.
2021-10-20 21:45:01 -04:00
Eli Schwartz e592d895ea py3 porting cleanup: drop raw_input compat alias 2021-10-20 21:43:47 -04:00
Eli Schwartz 887f620406 py3 porting cleanup: remove unneeded indirect import of builtins
filter, map, range, and zip were proxied through polyglot.builtins to
ensure that their `future_builtins` forms were used. In python3 this is
no longer needed and they don't need to be imported at all, from
anywhere. So, don't.
2021-10-20 21:43:43 -04:00
Kovid Goyal ae41b9b4aa Merge branch 'master' of https://github.com/cbhaley/calibre
Fixes #1947841 [Rules editor: Title & Author is/is not set](https://bugs.launchpad.net/calibre/+bug/1947841)
2021-10-20 18:13:16 +05:30
Charles Haley 63b61ee0c9 Bug #1947841: Title & Author is/is not set. Implemented option 1. 2021-10-20 12:39:35 +01:00
Kovid Goyal fad59ba7c7 ToC Editor: Ignore in succession clicks on the OK and Cancel buttons to avoid accidentally closing the window when finishing creating a new entry 2021-10-19 22:27:14 +05:30
Kovid Goyal 016a62b95e Comments editor: Fix the formatting buttons not showing the current state correctly 2021-10-19 14:45:23 +05:30