2
0
mirror of https://github.com/koreader/koreader synced 2024-10-31 21:20:20 +00:00
Commit Graph

3668 Commits

Author SHA1 Message Date
tobiasarndt
a2f605ba38 [fix] added PocketBook InkPad 3 Pro to device.lua (#5398) 2019-09-18 15:21:04 +02:00
Robert
d08516bd89 Fix: footer offset when orientation changes (#5396)
Fix: #5395
2019-09-18 11:13:51 +02:00
Robert
a7c358b080 [UX] Sort footer elements (#5389)
Close: #5329 

- new option for footer - `Sort items`
- new widget `SortWidget`
2019-09-17 14:50:03 +02:00
Robert
e315d8690d [chore] Remove unnecessary indent on new line (#5391) 2019-09-17 14:27:51 +02:00
Robert
b7d464ae4b Set screenshot output folder (#5382)
Close: #4230
2019-09-17 13:01:40 +02:00
Frans de Jonge
5bc9700c24
[feat] Allow setting any document cover as screensaver (#5369)
Cf. suggestion by @KenMaltby in <https://github.com/koreader/koreader/issues/3033#issuecomment-526657352>.
2019-09-16 15:27:49 +02:00
poire-z
788e6d90df
Fix: don't create sidecar file when indexing pdf documents (#5384) 2019-09-16 08:22:26 +02:00
Robert
54568d4dcd [UX] Add fine tune in line spacing (#5375)
See https://github.com/koreader/koreader/issues/5312#issuecomment-528506421

Progress widget has a new extra button ⋮ that triggers SpinWidget.
2019-09-14 16:30:25 +02:00
Frans de Jonge
672d29fbcc [fix] WakeupMgr: pass through task epoch for proximity check 2019-09-14 16:27:54 +02:00
Frans de Jonge
0c290be055 WakeupMgr: add log when scheduling wakeup 2019-09-14 16:27:54 +02:00
Frans de Jonge
3836184f9d [Kobo] Always write scheduled wakeup info to log 2019-09-14 16:27:54 +02:00
NiLuJe
4363576066 Support the Kobo Libra
(Hopefully?).
2019-09-12 14:27:05 +02:00
Frans de Jonge
e257c4e45e
[feat, Kobo] Autoshutdown (#5335)
The methods used here will likely work on most embedded devices, which is why I put them in their own WakeupMgr interface/scheduler module, separate from Kobo.

See https://www.mobileread.com/forums/showthread.php?p=3886403#post3886403 for more context.

Fixes #3806.
2019-09-12 14:15:08 +02:00
Robert
9163a85b3c Messages in numberpicker widget (#5353)
See: #5342
2019-09-11 21:39:58 +02:00
Frans de Jonge
0dad707e2e
[fix, Kobo] Don't crash trying to sync frontlight with Nickel. (#5361)
When reasonably possible, the program should only crash in debug mode.

Adds a couple of extra unit tests to prevent regressions and adds docs.

Fixes <https://github.com/koreader/koreader/issues/5356>.
2019-09-11 18:11:24 +02:00
Robert
deaa5d98e6 Disable show chapter markers when progress bar is hidden in footer (#5345) 2019-09-11 17:56:26 +02:00
Frans de Jonge
6c93415f67
[fix] Filesearcher crash on empty file attributes (#5351)
Fixes <https://github.com/koreader/koreader/issues/5343>.
2019-09-09 18:39:36 +02:00
Frans de Jonge
ed4396821f
[fix] ReadSettings Inverse reading order (#5350)
`self.inverse_reading_order == nil and G_reader_settings:has("inverse_reading_order")` could easily be false, which would then incorrectly turn the setting off.

Fixes <https://github.com/koreader/koreader/issues/5346>.
2019-09-09 17:34:27 +02:00
Frans de Jonge
07116b9898
[fix] Add keyboard layout to filemanager menu (#5338)
Overlooked in <https://github.com/koreader/koreader/pull/5318>.
2019-09-07 20:49:44 +02:00
Frans de Jonge
59355200dc
[fix] PdfDocument: Hash collision (#5337)
A typo introduced in <https://github.com/koreader/koreader/pull/5282>.

This might resolve <https://github.com/koreader/koreader/issues/5323>, <https://github.com/koreader/koreader/issues/5327>.
2019-09-07 17:15:12 +02:00
NiLuJe
a3acc667d6
[Kobo] Restart KOReader after a crash (#5328)
* Restart KOReader after a crash, after showing a fancy crash recap screen (our very own Gray Screen of Death!).

Kobo only, because it's possibly the platform where getting booted out
of KOReader is the most annoying.

Keeps track of crashes, to be able to give up after a while, in order to
avoid boot loops in the unlikely event of a crash loop on startup.

Adds a dev option to *always* exit KOReader after the crash screen.
2019-09-07 03:19:18 +02:00
Frans de Jonge
872c145f3a
[fix] ReaderGesture: Use getCurrentNetwork().ssid (#5334)
Otherwise ffi/util.template crashes on a table.
2019-09-06 22:51:45 +02:00
Frans de Jonge
17e437dbd0
[UX] Allow keyboard layout selection (#5318)
Fixes <https://github.com/koreader/koreader/issues/3998>.

This isn't quite what I want but I've been letting this slip for
too long due to fancier keyboard interaction concepts.
2019-09-06 17:01:37 +02:00
Martín Fernández
20ebb55703 [Cervantes] Disable wifi before returning to QT, improved sysfs read (#5326) 2019-09-06 15:56:16 +02:00
NiLuJe
5f189beba9 You have failed this city! (#5321)
Switch two finger swipe icons to double arrows
2019-09-06 15:49:41 +02:00
Frans de Jonge
7019ff15bd
[chore] Drop SDL 1.2 (#5324)
Depends on https://github.com/koreader/koreader-base/pull/963.

Also includes Initial import of <linux/rtc.h> related stuff https://github.com/koreader/koreader-base/pull/965
2019-09-05 23:30:13 +02:00
Robert
2d95a09e93 [UX] Option to show horizontal line separator in footer (#5309)
The separator is hidden by default.
2019-09-05 13:58:34 +02:00
Martín Fernández
cb2a3d9e72 Cervantes: Add back to stock reader (#5316) 2019-09-04 20:54:43 +02:00
Robert
ae50569055 Frontlight - Add checkbox use system settings (#5307)
See: https://github.com/koreader/koreader/issues/5205#issuecomment-526935357

Devices with `hasLightLevelFallback = true` (for now Android) has extra checkbutton `Use system settings`. Default unchecked.
2019-09-04 20:52:24 +02:00
Frans de Jonge
2cd9b50137
[Android] Don't ship Noto (#5310)
Follow-up to <https://github.com/koreader/koreader/pull/5252>. This greatly reduces the Android package size.

See discussion in <https://github.com/koreader/koreader/pull/5264#issuecomment-525517001>.
2019-09-04 20:50:25 +02:00
NiLuJe
d66cf7ab61 [fix] Allow setting a fine-tuned font size as default (#5306)
And a couple bugfix this unearthed:

* Always set the default as the *current* value, no matter what (by chance, this was not an issue for margins).
* Don't crash on the hold gesture in the -/+ buttons for the horizontal margins (regression since #5303).
2019-09-03 13:41:15 +02:00
Frans de Jonge
b2554ba5da
[fix] Prevent crash when no page boxes (#5289)
Can occur with invalid page numbers, for example by changing the font size in a reflowable MuPDF document.

Discussion in <https://github.com/koreader/koreader/pull/5282#issuecomment-526842921>.
2019-09-01 22:17:15 +02:00
Frans de Jonge
49589901b1
[fix] Let UIManager handle suspend logic (#5304)
See <https://github.com/koreader/koreader/issues/2431#issuecomment-526925910>.

Supersedes <https://github.com/koreader/koreader/pull/5302>.
2019-09-01 21:37:08 +02:00
Frans de Jonge
4cdc3ab99b
[feat, plugin] Add AutoTurn (#5295)
Fixes <https://github.com/koreader/koreader/issues/3019>.
2019-09-01 21:30:19 +02:00
Robert
b038fa3046 [UX] Add fine tune buttons to horizontal margins (#5303)
Similar to top and bottom margins I add fine tune buttons to L/R margins.
2019-09-01 21:26:11 +02:00
Frans de Jonge
1b17ce8ba0
[fix, Kobo] Save frontlight state on shutdown after suspend (#5305)
Fixes <https://github.com/koreader/koreader/issues/5292>.
2019-09-01 21:25:32 +02:00
Frans de Jonge
621f36b4a9
[fix] GetText: guard against empty strings in translation (#5301)
Fixes <https://github.com/koreader/koreader/issues/5293>.
2019-09-01 16:31:37 +02:00
Robert
d7d99d8b8b New memory icon for footer (#5300)
See: https://github.com/koreader/koreader/pull/5203#issuecomment-525849264
Old memory icon: ⌨
New: ≡
2019-09-01 15:55:41 +02:00
Frans de Jonge
0b62fc56ee
[doc] Add NumberPickerWidget developer docs (#5298) 2019-09-01 15:35:29 +02:00
Robert
3f3443b2e2 [UX] Reorganize tap corner menu in Gesture Manager (#5294)
Reorganize submenu tap corner like other submenus
Settings -> Tap and gestures -> Gesture manager -> Tap corner
2019-09-01 14:56:41 +02:00
Frans de Jonge
bc2412a67a
[doc] Convert koptinterface comments to LDoc format (#5290) 2019-08-31 21:15:22 +02:00
Frans de Jonge
37bab4fe89
[fix] Pass plain link to link:onGotoLink (#5286)
Internal links carry more baggage than external ones.

See <https://github.com/koreader/koreader/pull/5282#issuecomment-526813719>.
2019-08-31 12:43:19 +02:00
Frans de Jonge
258b13d344 [fix] Fallback in case of missing HOME variable 2019-08-30 19:53:36 +02:00
Frans de Jonge
860759cd48 Support loading GUI fonts from any known folder 2019-08-30 19:53:36 +02:00
Frans de Jonge
418aa1e5d6 Cache fontlist 2019-08-30 19:53:36 +02:00
Frans de Jonge
a47b3b1a5b
[doc] Add internal documentation references (#5285)
Also some minor grammatical fixes.
2019-08-30 15:06:30 +02:00
Frans de Jonge
f1f6eebce0
[feat] Add MuPDF EPUB/FB2 dynamic font size (#5282)
Closes #4368.
2019-08-30 13:47:51 +02:00
Frans de Jonge
f6270278aa
[feat] Implement fulltext search direction (#5283)
Closes <https://github.com/koreader/koreader/issues/5054>.
2019-08-30 13:27:03 +02:00
Frans de Jonge
ac16c8d547
[UX] Treat inverse_reading_order as a proper setting (#5284)
This is supported by ReaderPaging and ReaderRolling, but the menu entry was only shown in ReaderPaging.

Hold now sets the global default.

Fixes <https://github.com/koreader/koreader/issues/4983>.
Fixes <https://github.com/koreader/koreader/issues/4089>.
2019-08-30 13:25:51 +02:00
Frans de Jonge
cfa73be940
[feat, Kobo] Implement shutdown from suspend (#5280)
This allows to shutdown straight from suspend just like Nickel.

Fixes <https://github.com/koreader/koreader/issues/2431>.
2019-08-29 22:02:08 +02:00
Frans de Jonge
dd4bfb0a45
[UX] Ignore page flipping toggle while bookmark flipping (#5276)
See https://github.com/koreader/koreader/issues/5265#issuecomment-525626930
2019-08-28 12:59:54 +02:00
Frans de Jonge
2104bb6f98
[fix] Distinguish bookmark/page flipping in menu (#5266)
Fixes <https://github.com/koreader/koreader/issues/5265>.
2019-08-27 14:07:14 +02:00
Frans de Jonge
cddca1a5b5
[fix] Remove gettext util dependency (#5270)
A simple `string.gmatch()` should do the trick here, which avoids the need for refactoring.

Fixes <https://github.com/koreader/koreader/issues/5269>.
2019-08-26 16:51:45 +02:00
Frans de Jonge
be87fb27a0
[chore] Convert a couple more todos (#5267)
Cf. <https://github.com/koreader/koreader/pull/5244>.

Also update check.
2019-08-26 15:49:50 +02:00
Frans de Jonge
f3c3989b7f [chore] readertypeset: normalize string indentation
Same as <ece884a368/frontend/ui/widget/configdialog.lua (L1015-L1019)>.
2019-08-25 15:48:43 +02:00
Frans de Jonge
3ab51b1f85
[spec] Test all gettext codepaths & support language with no plurals (#5260) 2019-08-25 12:39:42 +02:00
Frans de Jonge
06d26ed13e [doc] gettext developer docs 2019-08-25 11:44:43 +02:00
Frans de Jonge
9cd8e4a53a [chore] Work around weird LDoc bug
Using two `@fixme` tags directly following each other can result in a crash.

See <https://github.com/stevedonovan/LDoc/issues/314> for the upstream issue.
2019-08-25 11:44:43 +02:00
Frans de Jonge
59bb3ac8ea
[chore] Remove executable bit on device/input.lua (#5258)
I've got no idea why that might be there.
2019-08-25 11:43:56 +02:00
Frans de Jonge
2c555830f9
[feat, i18n] Implement ngettext (#5257)
Fixes <https://github.com/koreader/koreader/issues/5249>.

See https://www.gnu.org/software/gettext/manual/html_node/Plural-forms.html and https://www.gnu.org/software/gettext/manual/html_node/Translating-plural-forms.html for more information.

Usage:
```lua
local T = ffiUtil.template
local _ = require("gettext")
local N_ = _.ngettext

local items_string = T(N_("1 item", "%1 items", num_items), num_items)
```
2019-08-24 23:06:06 +02:00
Frans de Jonge
45a0f285f1
[fix, i18n] Make two strings translatable (#5256)
Fixes <https://github.com/koreader/koreader/issues/5255>.
2019-08-24 13:45:07 +02:00
Frans de Jonge
6ed58346a1
[i18n] Add translator notes (#5250)
Thanks to <https://github.com/koreader/koreader/pull/5237> we can now  extract the knowledge currently embedded in Transifex and put it directly in our source. This positively affects <https://github.com/koreader/koreader/issues/3754>.

Translation instructions and knowledge that comes out of localization-related questions should be preserved in the source, because Transifex is too ephemeral. For example, the links from <https://github.com/koreader/koreader/pull/2290> are no longer accessible. Even when they are, it's quite useful to have this information around while dealing with the code as well, and I also hope it'll be informative to contributors who seldom visit Transifex.

This commit also makes a few minor changes to obviate the need for comments where possible.
2019-08-24 09:25:38 +02:00
Frans de Jonge
a2dcfe9aec
[doc] Tag @todo, @fixme and @warning (#5244)
This commit standardizes the various todos around the code a bit in a manner recognized by LDoc.

Besides drawing more attention by being displayed in the developer docs, they're also extractable with LDoc on the command line:

```sh
ldoc --tags todo,fixme *.lua
```

However, whether that particular usage offers any advantage over other search tools is questionable at best.

* and some random beautification
2019-08-23 19:53:53 +02:00
Robert
dc6d4085ea Fix: Unable to hold top right corner in FileManager (#5248)
Close: #5247
2019-08-23 19:48:55 +02:00
Frans de Jonge
182e981f4d
[fix, i18n] Translate "not set" (#5246)
Somehow this one slipped through the cracks for years.
2019-08-23 15:06:02 +02:00
Frans de Jonge
da988c15de
[CI] Switch to custom xgettext build to extract multiline strings (#5242)
Because let's face it, it just looks much better this way.

Docker image update in https://github.com/koreader/virdevenv/pull/43

Discussion in https://github.com/koreader/koreader/pull/5238#issuecomment-523675211 and https://github.com/koreader/koreader/pull/4524
2019-08-22 17:11:47 +02:00
Edoardo Putti
0906b69c06 [fix] Handle OPDS catalog responses accordingly (#5241)
- handle moved permanently HTTP 301
- handle authentication required HTTP 401
- handle authentication errors HTTP 403
- handle catalog not found HTTP 404
2019-08-22 15:37:17 +02:00
Frans de Jonge
e2ceace302
[fix, CI] Push to Transifex from master, fix multiline strings for xgettext (#5238)
Related to https://github.com/koreader/koreader/pull/5237
2019-08-22 00:12:53 +02:00
Frans de Jonge
fbd331dd07
[i18n] Switch make pot to xgettext (#5237)
This introduces context to our strings to differentiate them when necessary.

The syntax chosen is `C_()`, following [glib](https://developer.gnome.org/glib/2.28/glib-I18N.html#C-:CAPS).

```lua
local _ = require("gettext")
local C_ = _.pgettext

C_("Menu|StyleTweaks|", "Pages")
```

Closes #5232.
2019-08-21 22:18:14 +02:00
Frans de Jonge
0067c8f29e
[i18n, feat] Add basic context (msgctxt) support (#5234)
References https://github.com/koreader/koreader/issues/5232

Given an entry in the PO file like the following:

```
msgctxt "systemstat"
msgid "    Total"
msgstr "Totaal"
```

It can be addressed using:

```lua
local _ = require("gettext")
local C_ = _.pgettext
C_("systemstat", "    Total")
```

This allows to distinguish between separate instances of the same string, for example "Pages" meaning "Number of pages" and "Pages" meaning "Display of pages".

Extraction of this code pattern is not yet implemented by nightswatcher. xgettext didn't yet support Lua back in 2013 when all this was first added to the program, but now it does. Therefore it might make the most sense to replace the current Python extraction script with xgettext itself.

By default it only understands gettext.pgettext(), but that can be addressed by passing some extra command line arguments, for example:

```
xgettext -l lua -c --keyword=C_:1c,2 *.lua
```
2019-08-21 19:40:15 +02:00
Robert
395503d6ba [fix] Prevent double run genFooterText (#5233) 2019-08-21 15:00:09 +02:00
Martín Fernández
3a957d71e3 [Desktop] Open writable font dir, toggle system+user/user fonts, fix openLink on mac (#5220)
Fixes #5093
2019-08-20 18:38:02 +02:00
Martín Fernández
3161673d70 fix #5228 2019-08-20 16:26:39 +02:00
Robert
d9018faa5a [UX] Option to never full refresh (#5227)
Closes #5190.
2019-08-20 15:36:06 +02:00
Robert
33e4c36a42 [UX] Move tap x y corner to tap corner submenu (#5225)
Ref: https://github.com/koreader/koreader/issues/5021#issuecomment-522308285
Close: #5021
2019-08-18 19:36:11 +02:00
Robert
c57beada27 [chore] Remove Polish keyboard (#5223) 2019-08-18 12:42:38 +02:00
Robert
f56e9bcf98 Fix after #5203 (#5218)
https://github.com/koreader/koreader/pull/5203#issuecomment-522156268
https://github.com/koreader/koreader/pull/5203#pullrequestreview-276228925
2019-08-17 19:45:18 +02:00
poire-z
d25d449a26
bump crengine and others, adds HTML extended debug view (#5219)
Bump crengine: background image and other fixes:
- View HTML: option to show text unicode codepoints
- Fix attribute parsing: decode &-encoded chars
- Text: allow wrap after more unicode spaces and hyphen
- Fix: no left hanging when hanging punctuation disabled
- lvtextfm.cpp: more comments, some formatting cleanup
- Optimize background image drawing
- CSS: fix background-image file path resolution

Bump luasec to 0.8.1
Bump harfbuzz to 2.6.0

cre.cpp:
Adds setBackgroundImage() proxy function to crengine
facility to set background textures (this is unrelated
to the background-image CSS fixes).
No frontend code (yet) to select such an image.

View HTML: adds a 3rd view (extended debug view), showing the
unicode codepoint of each char and crengine rendereing methods.
2019-08-17 19:10:54 +02:00
Robert
5da3312869 More footer options, default to use icons as prefixes (#5203)
- show icons or letters as prefix of items
- various footer separators
- progress percentage format with decimal digits
- time in 12/24 format
- two duration formats (1:30, 1h30')
- move some options into Settings submenu
2019-08-16 23:22:58 +02:00
vvasseur
c104724a58 PocketBook 626 new codename (#5215) 2019-08-16 22:59:36 +02:00
Martín Fernández
50ce8d47cd do not request write settings permission at launch 2019-08-15 15:28:28 +02:00
Robert
939538cc25 [UX] Add gesture - poweroff and restart device (#5202)
Also abstract canRestart, canReboot and CanPowerOff.
2019-08-15 14:49:15 +02:00
NiLuJe
10511220e5 Simplify isWifiOn on Kobo (#5211)
Don't fork for lsmod + grep, we can perfectly well parse /proc/modules
ourselves ;).

c.f., https://github.com/koreader/koreader/pull/5203#issuecomment-521277628
2019-08-14 20:50:03 +02:00
NiLuJe
9e4a7797c9
Honor the alpha channel in our icon for the About popup (#5208)
It ends up with a black background otherwise.
(Old regression that dates back to my alpha shenanigans a few months
ago)
2019-08-14 17:01:26 +02:00
Frans de Jonge
a87c33f1f2
[lang] Change 2019-08-14 16:54:53 +02:00
jetomit
20493eebc3 [fix, Kobo] Add missing parentheses (#5198)
Prevents a crash when the WIFI_MODULE environment variable is not
defined.
2019-08-12 16:06:55 +02:00
Robert
0a2a1fffe8 [UI] Status bar alignment (#5195)
Close #5044
Option to align status bar without progress bar.
2019-08-11 19:58:39 +02:00
noEmbryo
570180196b [UX] Update for the greek popups (#5193)
Just used the north (upper) part of the popup wherever I could, because is more accessible.
2019-08-08 18:38:46 +02:00
Robert
f450936e9a Fix: conflict horizontal edge gesture with link swipe (#5189)
See: #5186
2019-08-08 15:19:09 +02:00
Robert
9baf055154 [UX] Add spread/pinch & font increase/decrease to gesture manager (#5188)
* Add spread/pinch gesture to gesture manager
ability to disable: 
https://www.mobileread.com/forums/showthread.php?t=321818
https://github.com/koreader/koreader/pull/4815#issuecomment-478462416

* Add increase/decrease font size action gesture
https://github.com/koreader/koreader/issues/4727#issuecomment-475950484
2019-08-07 20:18:36 +02:00
Robert
aec112fa6b [UX] Add double finger up and down swipe gesture (#5183)
* Add double finger up and down swipe gesture
* Cleaning ReaderFrontLight
2019-08-06 19:54:09 +02:00
Robert
dac2458427 [UX] Extend edge zones (#5181)
See: https://github.com/koreader/koreader/pull/5179#discussion_r310676845
2019-08-05 21:24:58 +02:00
Frans de Jonge
ec6e34cb1e
Change default zoom mode & add warning message for fit page + scroll (#5170)
* [UX] Change default zoom mode to page width

Fixes #5166.

* Warning popup for weird scroll mode combinations
2019-08-05 18:38:10 +02:00
Robert
5245bc88ff [UX] Add horizontal edge gestures (#5179) 2019-08-04 19:59:20 +02:00
poire-z
a82d7832b9 Dict lookups: have them always interruptible
They should be now interruptible when fuzzy search is disabled
and on Android.
2019-08-03 20:38:57 +02:00
poire-z
8749a3c5b6 Wikipedia download: increase timeout 2019-08-03 20:38:57 +02:00
Robert
a10fc83a4a Fix: hold bottom left corner doesn't work properly (#5177) 2019-08-03 20:35:48 +02:00
Robert
1743c0ca23 [UX] Extend the touch zone for up button in touch menu (#5175)
See: #5155
Close: #5155
2019-08-03 18:02:45 +02:00
Robert
d3e02d05c6 Fix: set custom screen DPI (#5165)
Settings -> Screen -> Screen DPI
When custom DPI is not set we see ugly information with %1:
2019-08-03 16:45:17 +02:00
Robert
825a3c4b52 Add gesture - show current book statistics (#5167) 2019-08-03 10:40:20 +02:00
jp8
47da9600d1 fix "empty folder" when accessing nextcloud webdav (#5171)
fix for cloud storage webdav nextcloud "empty folder" problem

See https://github.com/koreader/koreader/issues/4879
2019-08-03 08:30:05 +02:00
Martín Fernández
10456169e5
Android: ignore touchscreen by user request (using a hardware key) (#5164)
* android: ignore touchscreen by user request (using a hardware key)
2019-08-03 01:02:50 +02:00
Frans de Jonge
ac15143c14
[lang] Rename 'Scroll Mode' to 'Continuous' (#5169)
The current name causes people to think of scrolling, which is slightly awkward on E Ink. For example, see <https://github.com/koreader/koreader/issues/5166#issuecomment-517771475>.

> But this on LCD, not E-ink where the lag is unbearable, especially if you want to correct any scrolling over/undershoot.

Scroll mode is a misnomer. It should be renamed continuous. I use "scroll mode" as the default, but I seldom or never scroll. Conversely, you can still scroll in paged mode if a page is longer than the screen. As far as I'm concerned if you're scrolling (panning) you may be doing it wrong, but to anyone reading: you do you. ;-)
2019-08-02 22:43:26 +02:00
NiLuJe
affc0f48de
Go Big or Go Home! (#5163)
* Tweak goHome to assume sane-ish defaults if no custom home dir is set (re #5154)
* If we're already in Home, make goHome send us to the first page.
2019-08-02 18:07:31 +02:00
NiLuJe
e2961097e7
Don't use WAL on devices where it's not supported (#5162)
(i.e., truly ancient kernels and weird FS).

In which case, we use TRUNCATE, which might be a tad less terrible than
DELETE on said weird crap FS.
2019-08-01 19:10:46 +02:00
Robert
c6c8c5a037 Add vertical edge gesture (#5156)
* Add vertical edge gesture
* Add left/right edge swipe gesture
* Move kobolight plugin to ReaderFrontlight
* Remove kobolight plugin
2019-08-01 19:08:09 +02:00
Martín Fernández
91b2faae6a android: add an option to ignore volume keys or use them to turn pages 2019-08-01 19:05:23 +02:00
NiLuJe
53adb9d0e1
On (really old) Kindles, don't crash if there's no sysfs entry to read for battery capacity (#5161)
Parse gasgaucge-info's output instead.

Fix #5159
2019-08-01 18:45:30 +02:00
NiLuJe
e9eca55d90
Minor auto_restore_wifi tweaks (#5143)
* Try to make sure restoreWifiAsync eventually sends a NetworkConnected
event...

re: #5109

* Take a page from @shermp's book, and make sure wpa_supplicant managed to
connect to the AP before acquiring an IP.
Tear down WiFi modules in case of failure.
c.f., https://github.com/shermp/Kobo-UNCaGED/pull/21

* Don't let restore-wifi-async.sh enable WiFi behind our back when we're
killing it to start Nickel...

* Don't even call ping if there's no default gw
2019-07-31 01:00:51 +02:00
Robert
a38ba01b6e [chore] SpinWidget default_text instead of defaults_text (#5153) 2019-07-29 11:48:07 +02:00
Robert
3a4ac1964c [UX] Offer to restart KOReader after update (#5150)
Adding the option to restart KOReader after update.
Close: #5144
2019-07-29 09:54:28 +02:00
Robert
803a143764 [sdl] Add support arrow key for next/prev page (#5149)
Close: #4997 
This PR add support arrow key and mouse scroll wheel for next/previous page.

- Document in page mode:

PageDown, Arrow down, Arrow right - go to next page
PageUp, Arrow up, arrow left - go to prev page
Mouse scroll wheel down - go to next page
Mouse scroll wheel up - go to prev page

- Document in scroll mode:

PageDown, Arrow right - go to next page
PageUp, Arrow, arrow left - go to prev page
Arrow down - scroll document down
Arrow up - scroll document up
Mouse scroll wheel down - scroll document down
Mouse scroll wheel up - scroll document up
2019-07-28 13:57:03 +02:00
Robert
b71d0a19b8 [UX] Set font size for menu items (#5146)
Ref: #4757
This PR add option to changing the font size of items in menu widget (filemanger in classic mode, TOC) in single line mode.
Close: #4757
2019-07-28 08:37:43 +02:00
Martín Fernández
cd0f1acd7f android: add support for different screen timeout setups 2019-07-26 23:16:23 +02:00
Frans de Jonge
f763839577
[fix] Typo miliseconds → milliseconds (#5145)
Follow-up to https://github.com/koreader/koreader/pull/5138
2019-07-26 08:11:43 +02:00
Robert
1f6af80817 [feat] Make gesture intervals configurable (#5138)
Discussion: #4842
Close: #4842
2019-07-24 14:31:20 +02:00
Robert
69ee8c48cc Fix: Status bar hides text with minimal bottom margin (#5135)
With very narrow bottom margin text is sometimes hidden by status bar.
2019-07-22 20:42:36 +02:00
Robert
cbba7566b7 Cloudstorage - Add option to view unsupported files (#5131)
Option to show all files in cloudstorage also not supported by KOReader. We can also download any file.
To show all files in CS we need to enable option Show unsupported files in file manager (introducing in #5129)
Close: #5006
2019-07-21 21:45:02 +02:00
Frans de Jonge
55973771f9
[lang] Minor CSS tweaks stylistic improvements (#5128)
Pluralizing paddings like this is a bit unidiomatic, and that "all" seems a bit redundant.

Cf. <https://github.com/koreader/koreader/pull/5127>.
2019-07-20 17:37:06 +02:00
Robert
39bf5a4677 [feat] File manager - add option to view unsupported files (#5129)
New option to show all files (also not supported by KOReader) in file manager. Default this option is disabled.
2019-07-20 17:36:41 +02:00
NiLuJe
74518c79d1
Fix Kindle model detection in some corner-cases (#5125)
* Fix Kindle model detection in some corner-cases

We were (currently) unaffected because we don't support the K1.
Still, this should be slightly more robust.
2019-07-19 23:16:25 +02:00
poire-z
fd5e4df142 Style tweaks: adds Ignore all vertical/horizontal margins/paddings
Provides a bit more granularity than the generic "Ignore all
publisher margins" - and allow the same for paddings for books
that wrongly use paddings for that effect.
2019-07-19 22:31:28 +02:00
poire-z
0f3f2b660b TOC: baseline align chapter name and page number 2019-07-19 22:31:28 +02:00
sladflob
4717d6f70a Update screensaver.lua (#5123)
Change to use Math.round()
2019-07-19 05:52:12 +02:00
NiLuJe
564ee15679
Auto-detect the touchscreen input device on the PW4 (#5113)
Once again, LTE devices have an extra proximity sensors that shifts the
evdev path by one...

Fix #5110
2019-07-18 22:36:41 +02:00
sladflob
912e617377 [feat] Add percentage read (and other book information) to sleep message (#5121)
Add checking for escape sequences for current/total page, percentage read, and document title.
2019-07-18 14:11:21 +02:00
poire-z
642aed240c Update Wikipedia EPUB stylesheet to allow floating thumbnails
Main thumbnails and galleries items will float in "book" and
"web" modes.
Also use a honest User-Agent when requesting Wikipedia to
comply with their policy and avoid rate limitation (and
broken images).
2019-07-15 20:14:33 +02:00
poire-z
aedc5a4806 Style tweaks: update for latest epub.css, added a few more
- Updated "Avoid page break" tweaks to work on our latest epub.css.
- Added "New page on headings>" menu, as we no more break page on
H1, H2, H3 in EPUBs.
- Added "Center headings" as we no more have them centered.
- Added "Pure black and white" which can make some documents
  more readable.
2019-07-15 20:14:33 +02:00
poire-z
8b612142b7 Prettier CSS when viewing HTML
Avoid wraps on comma in properties values (eg. in font list,
in rgb() values).
Also prettify CSS included in the HTML in debug view.
2019-07-15 20:14:33 +02:00
poire-z
9f3c85ed83 cre: toggable enhanced rendering (floats, collapsed margins...)
Adds "Render mode" toggle with 4 modes, to enable some or all
of crengine's new enhanced block rendering features.
Use "legacy" rendering for previously opened books to not mess
with bookmarks, and "web" (all of the new features) for new books.

Also make available the added "HTML5" stylesheet to the Style menu.
2019-07-15 20:14:33 +02:00
Андрей Тюрин
bea7ca7008 Pocketbook 622 preliminary support (#5118) 2019-07-15 14:39:37 +02:00
Martín Fernández
b385e443e6 [Android] Add support for 3rd party dictionary apps (#5108)
Co-Authored-By: poire-z <poire-z@users.noreply.github.com>
2019-07-08 14:19:36 +02:00
Martín Fernández
338bc8cced fullscreen toggle for Jelly Bean devices 2019-07-06 17:09:18 +02:00
Robert
7d093fc0b9 [feat] Delete book after reading (#5107) 2019-07-05 10:35:23 +02:00
NiLuJe
38e7975728
More robust Gyro toggle (#5104)
* Make toggling Gyro events more robust

Actually ask to turn it on/off depending on the setting, instead of a
blind toggle

A quick succession of suspend/resume events could otherwise leave it
in an unexpected state (i.e., off when it should have been on).
2019-07-01 17:12:24 +02:00
NiLuJe
a13f9835be Tweak SleepCover handling a bit on Kobo
Specifically, how we ignore it.
No longer do anything specific and potentially racy, and let the
unexpected wakeup handler take care of putting us back to sleep.

Also add an option to only ignore wakeup events from the SleepCover.

Re #5098
Re #5087
2019-06-29 19:53:14 +02:00
NiLuJe
2ab3e48286 Make sure we only pass a single IP to ping
For some mysterious reason, I have a duplicate default gateway on my
Forma, one with no metrics, and a proper one.
This ensures we pick the proper one.

I'm fairly sure this is temporary insanity on the part of my device,
but, still, it can't hurt.

route -n:
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
0.0.0.0         192.168.0.1     0.0.0.0         UG    0      0        0 eth0
0.0.0.0         192.168.0.1     0.0.0.0         UG    208    0        0 eth0
192.168.0.0     0.0.0.0         255.255.255.0   U     208    0        0 eth0

ip r:
default via 192.168.0.1 dev eth0
default via 192.168.0.1 dev eth0  metric 208
192.168.0.0/24 dev eth0  src 192.168.0.49  metric 208
2019-06-29 19:53:14 +02:00
NiLuJe
2e7a910178
Some BookStatus QoL tweaks (#5100)
* Make the cover thumbnail respect the cover's AR in the widget
* Add a "Mark as read/unread" button in the FM's longpress menu.
* Make sure the cover_info cache is wiped if necessary (sidecar purge/BookInfo cache clear).
2019-06-28 04:46:16 +02:00
poire-z
03bbba249a
MovableContainer: avoid refresh glitches on close (#5094)
The contained widget may not have integer position/dimen
(which should probably be fixed in those that don't ensure
that), and our maths could eventually make them even more
shifted by fractional parts.
In the end, when closing the widget, the refresh code may
miss painting/cleaning 1px and leave a border of the widget
on the screen.
2019-06-26 13:48:02 +02:00
NiLuJe
4ccb1f3dd5
Allow disabling automagic image inversion in Nightmode in CRe (#5095)
* Allow disabling automagic image inversion in NightMode

Fix #4986
2019-06-26 00:23:41 +02:00
Frans de Jonge
fca51757af
[fix] OPDS crash with fewer than 4 servers (#5092)
Regression introduced in <https://github.com/koreader/koreader/pull/4249>.

Fixes <https://github.com/koreader/koreader/issues/5091>.
2019-06-25 19:50:01 +02:00
Martín Fernández
75ff5dcaae Add Device:Info for android and use it in report a bug infomessage.
Move local function getCodename to top, use android.app.activity.sdkVersion directly,
instead of relying on Device.firmware_rev
2019-06-21 19:55:19 +02:00
Martín Fernández
c60d672b04 bump base & luajit-launcher: workaround for buggy firmwares and more 2019-06-13 22:16:58 +02:00
Frans de Jonge
6f153255d6
[fix] Kindle Basic 3: use Kobo snow protocol (#5071)
Otherwise touch will be stuck in perpetual hold.

Fixes https://github.com/koreader/koreader/issues/5070
2019-06-11 09:12:57 +02:00
Frans de Jonge
9300a59a89
[fix] util.getSafeFilename() maximum extension length (#5067)
Strip HTML and do some semi-intelligent detection of faux extensions (i.e., more than 10 characters probably isn't one).

Fixes #5049.
2019-06-10 17:06:13 +02:00
Frans de Jonge
5df31f2dbf
[doc, fix] Some documentation issues (#5066)
Fixes #5065.
2019-06-09 15:50:22 +02:00
Frans de Jonge
efe2db4406 [feat, UX] Paste in folder shortcuts
Fixes #5046.
2019-06-09 15:26:05 +02:00
Frans de Jonge
986b44f9f8 [fix] FileManager: Empty clipboard after paste 2019-06-09 15:26:05 +02:00
Frans de Jonge
7cbd56fcdd
[fix] End of document - go to file browser: swap openFileBrowser() close/open order (#5062)
Fixes #5060.

Cf. 89e002f236/frontend/apps/reader/modules/readermenu.lua (L42-L50) and 89e002f236/frontend/apps/reader/readerui.lua (L711-L718)
2019-06-09 15:19:38 +02:00
NiLuJe
89e002f236
Minor networking fixes on legacy Kindles (#5059)
* Allow toggling WiFi & Suspend on legacy Kindles
* Fix ping invocations on Legacy Kindles
* Don't crash when disabling WiFi on legacy Kindles
2019-06-05 21:36:38 +02:00
NiLuJe
3798e1b72c Kindle Basic 3 support (#5057)
* Detect a few new PW4 variants

* Detect the new Kindle Basic 3

* Bump base for KT4 mxcfb support
2019-06-04 21:36:21 +02:00
NiLuJe
efe34b6fee Fix shutdown action on Kobo (#5055)
Bypass init, like Nickel does.
Otherwise, some devices either deadlock or panic.
2019-06-03 18:54:45 +02:00
limerainne
53b6e3d018 [i18n] Add Korean keyboard (2-beolsik) (#5053) 2019-06-03 11:03:28 +02:00
limerainne
98b681bb4f [fix] InputText: fix ignoring first char when carat not in front of hint (#5052) 2019-06-01 16:48:35 +02:00
Frans de Jonge
439f876ad8
[fix] util.getSafeFilename() default to worst-case scenario (#5036)
Also pass path from Wallabag plugin.

Fixes #5025.
2019-05-22 11:34:46 +02:00
NiLuJe
de1146c0b5 [Kobo] Tweak the Aura viewport (#5034)
Officially, the bezel should only cover the bottom 10 pixels ;).
(The Aura was officially advertised as having a 758x1014 screen).
2019-05-21 20:31:23 +02:00
poire-z
34e6f41e05
cre: fix 2 footnotes issues, bump crengine (#5031)
- Popup footnotes: workaround strange behaviour of MuPDF
  which is adding some unwanted margin above elements
  with an "id=" attribute.
- In-page footnotes: also remove any left and right margin,
  to keep footnotes aligned with the main text.
  Also add 2 classnames (witnessed in quite a few recent
  french books) to the list of classic classnames.
- Also bump crengine: CSS: fix parsing of multi classnames
  and attributes selectors
2019-05-18 01:29:51 +02:00
Frans de Jonge
8815cbe07a
[fix, chore] Abstract filename logic in util.getSafeFilename() (#5026)
Fixes https://github.com/koreader/koreader/issues/5025

The OPDS browser was doing some fancier stuff in a way that should be abstracted away in util (because it applies anywhere files will be saved):

eace8d25c1/frontend/ui/widget/opdsbrowser.lua (L482-L491)
2019-05-14 19:10:41 +02:00
Frans de Jonge
de75f6bfa3
[fix] Don't try to save highlight into non-PDF document (#5027)
* [fix] Don't try to save highlight into non-PDF document

Fixes <https://github.com/koreader/koreader/issues/5024>.

Highlighting will still work with the .sdr metadata.

* temp fix
2019-05-14 17:57:59 +02:00
Frans de Jonge
5d7dbb4466
[UX] Update Greek keyboard with swipes & popup (#5028)
Closes #5023. Thanks to @noembryo.
2019-05-14 16:30:21 +02:00
poire-z
eace8d25c1 cre: fix possible crash when switching books too fast
Noticable with "End of document action > Open next file",
and holding PgDn in a directory full of single page html
files.
2019-05-09 22:14:13 +02:00
Frans de Jonge
2968f558eb
[fix, UX] Ignore first hold release when keyboard opened with hold (#5011)
Fixes #4902.
2019-05-08 10:13:44 +02:00
NiLuJe
4ba7f984bf Sync powerd.fl brightness with powerd when toggling the FL (#4999)
Possibly helps with some more edge cases related to interaction with
autowarmth & the KA1...

re: #4925
2019-05-05 22:08:53 +02:00
poire-z
7c53fcd922 CRe margins: hide bottom menu on change (#5000)
So we can immediately see how's the bottom margin.
2019-05-05 10:15:13 +02:00
NiLuJe
f3decdc26c [fix] Restore PAGE_MARGIN string (#4993)
It's used by KOptConfig

Fix #4992
Regression since #4945
2019-05-02 19:06:57 +02:00
NiLuJe
aec7594af5
Blacklist the C BB on devices where it cannot be used (#4989)
Either at all, or because it would impose reduced functionality.

Meaning:
* On 4bpp fb, because those are completely unsupported by the C BB
* On 24bpp fb, because it has limited support for that target format (no alpha blending).
* On 8bpp Linux eInk fb with an inverted palette (that's basically only the K4 ;)).
* On Linux eInk devices w/ no HW inversion support, as that would render NightMode inoperable.

That last point means that it's currently *always* blacklisted on PocketBook, because I don't have a PB device, so I don't know how safe HW inversion would be, meaning none of them are marked as being HW invert capable.

(I was a tiny bit hasty with https://github.com/koreader/koreader-base/pull/912 ;).)
2019-05-02 04:27:48 +02:00
poire-z
bf07c44009
CRe margins: add toggle to sync top and bottom margins (#4990)
Also fix DogEar size update on margin change.
Also re-order cre bottom tabs to be like with kopt.
2019-05-01 22:18:50 +02:00
NiLuJe
888d3591b2
Give more control over CRe margins (#4945)
Without having to resort to weird custom defaults.

* Split the current margins setting in three:
  * Horizontal margins (because you generally want those two to be balanced).
  * Top margin & Bottom margin (because you may want to tweak those separately to deal with quirky status bar/final line shenanigans).

* Also, add a "Reclaim bar height from bottom margin" toggle to the status bar menu, to optionally make sure the status bar won't eat into the bottom margin.

* Includes a free fix to diacritics popup refresh handling in the keyboard ;).
2019-05-01 02:09:01 +02:00
Frans de Jonge
96179670f8
[fix] Close calibre search when opening document (#4978)
Fixes https://github.com/koreader/koreader/issues/4225.
2019-04-28 20:10:41 +02:00
Frans de Jonge
3f670baaa2
[UX] Keyboard popup: add X (#4977) 2019-04-27 09:04:48 +02:00
Qingping Hou
080c079d01 chore: add test for screen color toggle 2019-04-24 21:09:23 +02:00
NiLuJe
d9ab5d2f43 Make sure the AutoWarmth feature will never try to turn the light back (#4953)
on if it's off.
Because, on the KA1, since wetting the warmth *has* to set the
brightness, it could ;).

Patch only actually needed on Kobo, as all Cervantes devices with warmth
support have a mixer, which mean they *can* set the warmth without
affecting the brightness ;).
2019-04-21 20:46:29 +02:00
Frans de Jonge
ff843e0eb7 [i18n] Change user-facing floating punctuation text to hanging punctuation
See https://www.mobileread.com/forums/showthread.php?t=316787
2019-04-20 19:47:31 -07:00
Frans de Jonge
4782f5ffc1
[UX] Keyboard popup: add = (#4950)
As suggested by @Biep in https://github.com/koreader/koreader/pull/4889#issuecomment-485158316
2019-04-20 23:36:52 +02:00
Frans de Jonge
8ec42d1e60
[fix] Actually commit V popup data (#4940)
Overlooked in https://github.com/koreader/koreader/pull/4938
2019-04-19 14:17:18 +02:00
NiLuJe
9134594119
Allow toggling CRe's new dithering & scaling (#4922)
Smooth scaling toggle is per document, in the gear tab.
Dithering is in the Dev top menu ;).
2019-04-18 23:26:53 +02:00
Frans de Jonge
6203fbb633
[UX] Keyboard popup: add V diacritics (#4938) 2019-04-18 21:03:17 +02:00
Galunid
9759ffa381 [feat] GestureManager: Implement action to change highlight style using gesture manager (#4936) 2019-04-18 12:12:38 +02:00
Frans de Jonge
c053e48526
[UX] Keyboard popup: add Y diacritics (#4935) 2019-04-17 21:21:28 +02:00
Frans de Jonge
04c39a8591
[UX] Keyboard popup: add R diacritics (IPA edition) (#4934) 2019-04-17 20:47:30 +02:00
Martín Fernández
a69c09a275 [Android] do not log verbose blitbuffer messages on release builds, unless specified in settings.lua. Keep debug builds as they are (#4933) 2019-04-17 20:04:07 +02:00
Frans de Jonge
1299ae93a8
[UX] Keyboard popup: add P (#4932)
Only Greek pi seems to make sense here.
2019-04-17 14:37:31 +02:00
Frans de Jonge
8882cdf0c5 [chore] Show FileManager in case of showReaderCoroutine failure
Same as https://github.com/koreader/koreader/pull/2956.

Fixes https://github.com/koreader/koreader/issues/4928.
2019-04-16 22:40:31 -07:00
Frans de Jonge
39b48d56c0
[UX] Keyboard popup: add N and M diacritics (#4930) 2019-04-16 20:44:22 +02:00
NiLuJe
717db55566
Some more FL fixes when we start with the FL off (#4924)
* Don't override hw_intensity when we start with the FL off
* And add an insane workaround to make the first toggle behave sanely in this case.
* And also handle the sneakier case where the first toggle happening would not be manual, but triggered by a suspend/resume cycle.
2019-04-16 00:04:29 +02:00
NiLuJe
33946aa732
Some FL regression fixes after #4901 (#4921)
* Make hasNaturalLight* caps safe to call without a device check. (fix #4919)
Make it clear that it's expecting the NTX implementation, though.
* Don't turn the FL on on resume if it was off on suspend
* Make sure turnOn/turnOff actually updates hw_intensity in the process where it matters, instead of just in a short lived fork ;). (fix #4923)
2019-04-15 20:06:24 +02:00
Frans de Jonge
7e06db9c2a
[UX] Keyboard popup: add H and J (#4920) 2019-04-14 18:39:09 +02:00
Frans de Jonge
a507f753fb
[UX] Keyboard popup: minor changes to S (#4918)
Split sigma into upper and lowercase to make room for esh.
2019-04-14 09:50:39 +02:00
Frans de Jonge
06a73ba550
[UX] Keyboard popup: add F and G (#4914) 2019-04-13 20:00:36 +02:00
Frans de Jonge
742453a047
[UX] Keyboard popup: add Q and W (#4913)
Mainly for easy swipe access to `[]{}`.
2019-04-13 15:18:05 +02:00
Frans de Jonge
762b4bef26
[UX] Keyboard popup: add C diacritics (#4912) 2019-04-13 11:40:31 +02:00
Frans de Jonge
d27393d723
[UX] Keyboard O popup: add Ø (#4911)
Danish/Norse and IPA close-mid front rounded vowel.

Requested by @gerhaher over in https://github.com/koreader/koreader/pull/4907#issuecomment-482784459
2019-04-13 09:51:52 +02:00
Frans de Jonge
ad62cc23e2
[UX] Keyboard popup: add Z diacritics (#4910) 2019-04-12 23:02:48 +02:00
NiLuJe
f63ca005c6 [fix] Update AutoWarmth state on resume (#4901)
Regression since #4871
Fix #4895

* Hide the "Configure" button in the FL/NL widget on devices where it
won't do anything

(i.e., those w/ a NL mixer).
2019-04-12 22:46:10 +02:00
Frans de Jonge
74e14a927c
[UX] Keyboard popup: k and l diacritics (#4908)
There doesn't seem to be much going on in k-land, and I like using proper hyphens and dashes.
2019-04-12 22:20:14 +02:00
poire-z
d3aaff135c
Update FR and ES keyboards (#4906)
Extend the FR and ES keyboards from the EN one, and
just tweak what has to be changed.
This will allow them to stay in sync with the EN keyboard's
recent and futur developments of key popups.
Also make the FR keyboard a bit more AZERTY.
2019-04-12 21:12:33 +02:00
Frans de Jonge
6f8a077f32
[UX] Keyboard popups: stubs for the rest of the vowels (I, O, U) (#4907)
With the basic pattern of diacritics and special characters established by now, the basic diacritics + IPA don't need too much thought for an initial draft.

Cf. https://github.com/koreader/koreader/pull/4906#discussion_r274966796
2019-04-12 18:28:05 +02:00
NiLuJe
2a91b2b038 Go back to "UI" refreshes in the FM (#4903)
Going with partial ends up being problematic on REAGL devices in a
number of different ways.

On Kindle (at least pre EPDCv2), it's slightly flickery because of the
whitespace and the boldface.
On Kobo, it's slow when anything else tries to queue an update (i.e.,
flashing the chevrons).
Which is a non-issue on the Forma because then it's fast when using
pageturns to navigate, but, still :D.

The obvious downside is we lose the automatic flash after n refresh,
which is potentially annoying on older, non-reagl devices.
It's not really on issue on REAGL devices, especially on EPDCv2.
2019-04-12 17:57:22 +02:00
Frans de Jonge
9b26178118
[UX] Keyboard popup: add T diacritics (#4905)
The Ťť is used in Czech and Slovak. The t-comma Țț is Romanian. The rest is a combination of IPA, Greek, and why not.
2019-04-12 17:53:19 +02:00
Frans de Jonge
58d88b12ab
[UX] Keyboard: add d diacritics (#4898)
Eth (ð) is an important letter for people who like Old English (me), and for IPA.

Ď/ď is Czech/Slovak.

Đ/đ is sometimes an alternative rendering of ð, maybe because you could type it on a traditional typewriter. It's also Slavic and something Vietnamese.

Delta is an often-used Greek letter.
2019-04-11 18:22:32 +02:00
Frans de Jonge
021f1d9107
[fix] VirtualKeyboard: always fall back to en (like it used to) (#4900)
Fixes #4899.
2019-04-11 14:01:58 +02:00
Frans de Jonge
4ba826ca3c
[fix] VirtualKeyPopup close refresh (#4897)
See https://github.com/koreader/koreader/pull/4891#issuecomment-481866246
2019-04-11 14:00:59 +02:00
Frans de Jonge
c35f96c819
[UX] VirtualKeyPopup: add B, comma, and period popups (#4893)
Adds B because it's on the same row as a comma.
2019-04-11 10:32:13 +02:00
Frans de Jonge
3f59dee721
[UX] VirtualKeyPopup: variable size (#4892)
This makes the code a lot more complex, but it looks much better.
2019-04-11 10:12:29 +02:00
Frans de Jonge
fd50dc34a6
[UX] VirtualKeyPopup: close on hold release (#4891)
As suggested by @poire-z.
2019-04-10 17:05:02 +02:00
Frans de Jonge
2d5cbafd27
[UX] Keyboard: add S diacritics (#4890) 2019-04-10 15:47:15 +02:00
Frans de Jonge
80953b5c4c
[UX] Keyboard: add @ and A diacritics (#4889)
Also rename std to en_keyboard.
2019-04-10 12:54:28 +02:00
Frans de Jonge
69e3830bc1
[UX] VirtualKeyPopup: respond to hold & pan release (#4887)
As suggested by @poire-z in https://github.com/koreader/koreader/pull/4886#discussion_r273569802

This is actually much better than before.

It subtly changes the behavior of every key this way, but I don't think that's a bad thing.
2019-04-09 22:19:56 +02:00
Frans de Jonge
23f903274a
[UX] Keyboard character selection popup (#4886) 2019-04-09 21:29:36 +02:00
Frans de Jonge
2760b98582
[UX] Add keyboard swipes (#4884)
Only the `e` and `E` are added in this initial commit.
2019-04-09 10:40:39 +02:00
NiLuJe
4005bf69aa
Slightly less crappy Nightmode (#4871)
Companion PR to https://github.com/koreader/koreader-base/pull/884
* Basically flags devices known to be stable when using PxP inversion.
* Plus, random fix for #4870 ;).
* A few FrontLight tweaks & cleanups on Kobo:
  * Moved the Kobo-specific startup status insanity to Kobo-specific init
  * Made turnOff/turnOn frontlight do a smooth ramp down/up
  * On Kobo, use turnOff/turnOn for suspend/resume, to get that smooth toggle
  * On Kobo, for NaturalLight w/ a mixer, only set warmth for setWarmth, and only set Brightness for setBrightness, otherwise, it tried to set both with not in-sync values, which made the FL widget jittery.
2019-04-08 23:05:08 +02:00
Frans de Jonge
8466af2c5b
[UX] Gesture manager: corner gestures (#4878)
Adds configuration to the top corners as well as the additional gestures hold and two-finger tap.

Deprecates `DTAP_ZONE_FLIPPING` and `DTAP_ZONE_BOOKMARK`.

Fixes #4877.
2019-04-07 19:00:15 +02:00
Frans de Jonge
22db71c075
[fix] OPDS last-modified check (#4874)
Fixes #4873. Unfortunately this will introduce a slight delay but I don't see any other quick & reasonable solution.
2019-04-05 08:50:33 +02:00
poire-z
5c38bcb8b7 [UX] Links menu and handling tweaks (#4867)
- Removed "Swipe to follow first link on page" menu item and
  handling code, as it feels not really as practical as
  "Swipe to follow nearest link".
- Removed recently added "External link action", as we can
  just always present a popup with the url and the available
  actions.
- Generic handling of these actions in onGoToExternalLink(),
  so they are proposed on the Wikipedia lookup popup too.
- Allow external link on PDF documents (previously, only
  internal links were handled).
- Have "Ignore external links on tap" available on all
  document types.
- Added "Ignore external links on swipe" (default to true,
  the current behaviour).
- Added multiswipe gesture "Follow nearest internal link"
  (the existing "Follow nearest link" now follows the
  nearest external or internal link)
- ButtonDialogTitle: added an option to look a bit more
  alike ConfirmBoxes.
- Footnote popups: fix link unhighlight when tap on external link.
2019-04-02 18:27:35 +02:00
Martín Fernández
dde301e765 [Android] use the same tag for all logs (#4862) 2019-04-01 15:48:10 +02:00
Frans de Jonge
0a314e3ab8
[fix] widget/scrollhtmlwidget: default_font_size same as infofont and Screen:scaleBySize() (#4864)
Otherwise it's:

1. Too small on virtually all devices due to a lack of scaling.
2. Unusably small by default.

It's currently scaled by the callers (dictquicklookup & footnotewidget) based on other properties, but you shouldn't have to change it from the default just to get something usable. ;-)
2019-03-31 22:00:07 +02:00
Frans de Jonge
709207a621
[feat, UX] Add external link to Wallabag (#4863)
Offers a choice when Wallabag is available.
2019-03-31 19:19:07 +02:00
poire-z
7396abebf2 [chore] reformat all gestures "overrides" to be diff friendly 2019-03-30 23:47:07 +01:00
poire-z
44529dbbc9 Fix tap for top menu occasionally not working
It was missing some ordering hints to have it always
precede taps to change page.
(Somehow noticed only when we reached > 32 gestures
registered, which may have introduced some shuffling,
while previously the addition order was somehow
preserved...)
2019-03-30 23:47:07 +01:00
Frans de Jonge
433b89638a
[UX] Gesture manager: show selected two-finger swipe action (#4855)
As requested by @poire-z here: https://github.com/koreader/koreader/pull/4820#issuecomment-478220239
2019-03-30 13:06:15 +01:00
poire-z
8f019b8183 Night mode: keep some images non-inverted
Have the code pre-invert some images when in night mode,
so they get inverted back to normal by night mode.
This will allow images to be displayed normally in
the following contexts:
- images in credocument pages
- long-press on images in credocument viewed in ImageViewer
- cover thumbnails in File browser and History
- full size covers when viewed in ImageViewer
- images in Wikipedia lookup results
2019-03-30 01:30:46 +01:00
poire-z
e2b4099228 Footnote popups: fix link unhighlight when closing with keys 2019-03-30 01:30:46 +01:00
NiLuJe
b72a2000b1
A few minor fixes after #4847 (#4850)
* Add a toggle to disable the C blitter in the Dev menu (depends on https://github.com/koreader/koreader-base/pull/882) (never shown if the JIT is disabled, grayed out if the C blitter is not installed)
* Fix a few sizeUtf8Text call sites that were doing a nil check in order to account for the new return type.
* Tweak statusbar handling to avoid spurious sizeUtf8Text warnings when it's hidden, and unify its behavior between being hidden via toggle, and hidden on book open (at least when all-at-once is not enabled).
* c.f., https://github.com/koreader/koreader-base/pull/882 (Android, PB, RGB32 & Legacy Kindle regression fixes).
2019-03-29 20:12:09 +01:00
Frans de Jonge
db5bd8884d
[UX] Gesture manager: add diagonal two-finger swipes (#4820)
Follow-up to #4815. Pointed out as an easy target [here](https://github.com/koreader/koreader/pull/4815#issuecomment-473990141) by @poire-z.
2019-03-29 11:28:24 +01:00
NiLuJe
7210fb478d
Faster blitting @ BB8/BBRGB32 when no processing is needed (#4847)
* Pickup the eponymous blitting performance tweaks from koreader/koreader-base#878
* Cleanup BitOpts usage (require & cache)
* Unify oddness checks (MOD -> AND)
* Enforce the native Portrait orientation on Kobo (except @ 16bpp, i.e., KSM w/ 8bpp swap disabled), to allow for faster blitting when unrotted.
* Switch CRe BB to 32BPP on color screens
* Minor cleanups
2019-03-27 22:50:44 +01:00
NiLuJe
fe3fc78171 Move AutoSuspend menu to the Plugin itself 2019-03-27 17:34:41 +01:00
NiLuJe
04f5bc7823 Remove the Aura SE viewport
This feels somewhat arbitrary and potentially unneeded,
and it'll prevent full blits, so, off it goes.
2019-03-27 17:34:41 +01:00
NiLuJe
9ecc2dd119 There's no viewport on the H2O²
Fix #4834
2019-03-27 17:34:41 +01:00
NiLuJe
9be3455ccc Don't crash when sizeUtf8Text is called on a nil
By returning a table with the right fields instead of nil.

Re #4845
2019-03-27 17:34:41 +01:00
NiLuJe
abbb3ea747 Increase granularity of the font size fine tuning button
Should allow us to get at the full 12 to 30 range when scaled on a 300dpi
device (29 -> 72 or 26 -> 64 w/ a dpi override).
2019-03-27 17:34:41 +01:00
NiLuJe
783c3fd7dc Allow toggling sleepcover handling from the UI 2019-03-27 17:34:41 +01:00
NiLuJe
860b4b24a0 Allow setting the autosuspend timeout from the UI
Fix #4179
2019-03-27 17:34:41 +01:00
NiLuJe
32c9ea74a6 Ignore the accelerometer while we're sleeping on Kobo
It might cause unwanted wakeups, and even it it doesn't, it just feels
and looks stupid ;).
2019-03-27 17:34:41 +01:00
Frans de Jonge
83cdb9cb9a
[fix] MenuSorter: don't add empty menu item (#4848)
Fixes #4845.
2019-03-27 09:50:25 +01:00
poire-z
b98ee4583b Footnote popups: fix crash when used on some links
Fix crash when dismissing the popup when the link was
detected as "not coherent".
2019-03-26 21:44:57 +01:00
poire-z
a47f3a2765 ReaderRolling: proper refresh when toggling scroll/page mode
When toggling between scroll and page modes multiple
times, _gotoXPointer() could find the xpointer to be
already positionned and avoid calling setDirty() (so
not enqueuing a whole screen refresh). But the page
will be slightly moved to account for the top margin
disappearing. We need that whole screen refresh in
such cases, so ensure one is enqueued.
2019-03-26 21:44:57 +01:00
poire-z
b7b4cdd2a7 ConfigDialog: fix possible crash (#4838)
When one has set a default for toggles thad don't have 'values' in
their definitions (possibly only Orientation).
2019-03-25 19:15:29 +01:00
poire-z
cfd562697f
Fix Color rendering toggle not toggable (#4836)
Also refresh screen when toggling.
2019-03-24 21:54:58 +01:00
Galunid
5f44ef5dad [feat] Kindle suspend using lipc (#4825)
Fixes problems with making Kindle go to sleep using menu or gesture manager action.
2019-03-21 11:52:58 +01:00
Frans de Jonge
2f65fb94ec
[Android, UX] Add Device:openLink() implementation (#4824)
Fixes https://github.com/koreader/koreader/issues/4821

Same as https://github.com/koreader/koreader/pull/4822

Thanks to @pazos who implemented the Android backend, see https://github.com/koreader/android-luajit-launcher/pull/133
2019-03-20 17:28:19 +01:00
Frans de Jonge
b1ed2838c8
[UX] Add Device:openLink() stub for Linux SDL (#4822)
References #4821.
2019-03-20 16:58:32 +01:00
Frans de Jonge
728bb187fa
[UX] Gesture manager: add two-finger swipe left and right (#4815)
Also add Device:hasMultitouch() to control whether the configuration menu is shown.

Cf. #4727.
2019-03-19 20:18:38 +01:00
NiLuJe
003de939b0 [fix] Properly account for MuPDF feeding us premultiplied alpha (#4807)
* Properly account for MuPDF feeding us premultiplied alpha

* Bump base to pickup necessary backend changes

Also includes a bunch of CMake refactoring
(https://github.com/koreader/koreader-base/pull/865
https://github.com/koreader/koreader-base/pull/867
https://github.com/koreader/koreader-base/pull/868)
2019-03-18 09:35:27 +01:00
Frans de Jonge
59d8a1852f
[fix, lang] ReaderGesture: toggle highlight action to cycle (#4809)
I overlooked this until I noticed it on Transifex today.

See https://github.com/koreader/koreader/pull/4791#discussion_r265546245

Also changing the internal name because for something that's only been in one or two nightlies there's no point in prematurely introducing legacy settings.
2019-03-16 11:24:11 +01:00
poire-z
b16aa79636
ConfigDialog ButtonProgress: black border on default item (#4805)
Make the default (user set, or KOReader's default) item
among the button progress squares shown with a black border.
2019-03-15 23:15:05 +01:00
Frans de Jonge
e357165f17
[fix] GestureDetector: fix typo in ges_coordinate_translation_90 (#4804)
Fixes #4803.
2019-03-15 19:53:15 +01:00
poire-z
454f14384b
Gesture manager: fix actions: Book cover, Book description (#4800)
Code removed from ReaderGesture and put into BookInfo where
it belongs, so we can just use Events.
Also convert description to plain text to not show HTML tags.
2019-03-15 15:29:25 +01:00
poire-z
6239d89022
Screensaver: fix crash when "Choose screensaver image" (#4799)
Just switched to use the friendly PathChooser instead of
FileChooser (which is more like a superclass and shouldn't
be used directly).
2019-03-15 14:14:53 +01:00
NiLuJe
645d41eda9
Add more granularity in line-height settings with CRe (#4785)
70 -> 130, in steps of 5 ;).
2019-03-15 00:34:46 +01:00
poire-z
2aa77a4879 Gesture manager: add actions: Book cover, Book description 2019-03-14 22:34:18 +01:00