Commit Graph

9144 Commits (6fdb83017be2c4e6f5e994c2f0bb278f5e514e7b)
 

Author SHA1 Message Date
zwim 6fdb83017b
[plugin] AutoDim: reschedule on every tap (#9243)
This is a maintenance PR.
With scheduling the next autodim_check on every tap, we can keep the device longer in standby mode. So we have more power savings.

The long story: The current version works like that:
Let's say I set the idle-time to 3 min and I need 2.5 min to read a page.
Start at 0 min (next scheduled check is at/in 3 min)
Read and tap to turn page after 2.5 min (next scheduled check is at 3 min - in 0.5 min)
At 3 min there is a scheduled_check (wakeup) -> reschedule check in 3 min.
Read and tap to turn page after 2.5 min (no wakeup)
Then after 1 min there is a wakeup -> reschedule.
---> So I get an additional wakeup on every second page.

This PR solves the problem: During normal reading I don't get any wakeup during reading. (The only drawback is, that one function is unscheduled/scheduled on every tap, but that is no big deal).
2 years ago
NiLuJe 4f4b1e523a
Kobo: Handle the new Libra 2 hardware revision properly (#9234)
Includes a base bump for KoboUSBMS (https://github.com/koreader/koreader-base/pull/1493)

Fix #9218
2 years ago
Frans de Jonge bd89ab30bd
Update translations for 2022.06 (#9232) 2 years ago
Frans de Jonge 9b90f59f05
Bump base for SDL multitouch workaround (#9230)
There was a regression in SDL, see <https://github.com/koreader/koreader/issues/9091> for details.
2 years ago
zwim 83453dfd8f
AutodDim: don't dim if frontlight is off (#9217) 2 years ago
Utsob Roy 74ca6fb317
Better meta parsing for exporter (#9220)
* Get title, author and number of pages from document's metadata
* Add exportable_title parsed from document's title, used in export file generation.
* JSON: export number of pages
2 years ago
dependabot[bot] 2fb45b2c6d
[CI] Bump actions/upload-artifact from 2 to 3 (#9214)
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v2...v3)
2 years ago
dependabot[bot] bdbc130cfe
[CI] Bump actions/checkout from 2 to 3 (#9215)
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v2...v3)
2 years ago
Naveen f85d3b0beb
chore: Included githubactions in the dependabot config (#9213)
This should help with keeping the GitHub actions updated on new releases. This will also help with keeping it secure.

Dependabot helps in keeping the supply chain secure https://docs.github.com/en/code-security/dependabot

GitHub actions up to date https://docs.github.com/en/code-security/dependabot/working-with-dependabot/keeping-your-actions-up-to-date-with-dependabot

https://github.com/ossf/scorecard/blob/main/docs/checks.md#dependency-update-tool
2 years ago
Naveen ee080d63b7
chore: Set permissions for GitHub actions (#9207)
Restrict the GitHub token permissions only to the required ones; this way, even if the attackers will succeed in compromising your workflow, they won’t be able to do much.

- Included permissions for the action. https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions

https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#permissions

https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs

[Keeping your GitHub Actions and workflows secure Part 1: Preventing pwn requests](https://securitylab.github.com/research/github-actions-preventing-pwn-requests/)
2 years ago
Frans de Jonge e5ddd47df5
[CI] Also use Ubuntu 20.04 Docker image for docs (#9209)
Overlooked in <https://github.com/koreader/koreader/pull/9007>.
2 years ago
NiLuJe d3964bb4a0 "Fix" the ImageWidget test 2 years ago
NiLuJe 6ea292ef13 ImageWidget: Always return a bb, even on decoding failure.
(In which case we return a checkerboard pattern).

ScreenSaver: Make sure the choose image/folder/document settings
report what the code actually does on empty settings...
2 years ago
NiLuJe a4f6693919 OPDSBrowser: Handle renderImageData failure in streamPages 2 years ago
NiLuJe 35c33d5308 RenderImage: Always pcall C/FFI stuff, and return nil on error 2 years ago
weijiuqiao cafbf36bb2
Vocabulary builder: store word context, other tweaks and fixes (#9195)
Add a copy button and save word context (off by default), shown
via the three-dot menu of word entries.
Also some db refactoring and minor UI improvements:
- a dedicated book title table in order to shrink db size by storing
  references to title names instead of repeated actual strings,
- alignment of different forms of the "more" button and possible
 clipped words in translations.
- fix plugin name so it can be disabled
2 years ago
zwim def02846ec
AutoDim: Don't update footer if not necessary (#9192) 2 years ago
Frans de Jonge 50b8b60400
[CI] Don't hide docs generation log (#9204)
With reference to https://github.com/koreader/koreader/pull/9193#issuecomment-1153128485
2 years ago
Martín Fernández 2213e6410f
[plugin] Exporter: fix crash on joplin when token is invalid (#9203)
https://github.com/koreader/koreader/issues/9197#issuecomment-1153129147
2 years ago
Wulf C. Krueger 0f238c3179
Auto frontlight plugin: Newer Oasis models are also supported (#9202)
On a Kindle Oasis 2 and 3 the plugin would be disabled due to not
checking for "KindleOasis2" and "KindleOasis3" respectively.
2 years ago
NiLuJe 2e681353d7 UIManager: Simplify setPMInputTimeout (from #9173)
This was originally designed for finer-grainbed control (specifically,
to correct by the amount of time spent in standby), but the final fix
only ever sets this to 0.

Simplify and rename (consumeInputEarlyAfterPM) to avoid useless computations.
2 years ago
NiLuJe 299c34a49c ScreenSaver: Ignore macOS resource forks when choosing a random image
Might help w/ https://www.mobileread.com/forums/showthread.php?t=343622
2 years ago
zwim e8597c2e0c
Footer: update on network disconnect (#9185) 2 years ago
poire-z cc185bae4e Embedded fonts toggle: disabled if no embedded font
Have the enabled/disabled state of the toggle show the
presence or not of embedded fonts in the current book.
Also show the names of the embedded fonts in the
help_text InfoMessage.
2 years ago
poire-z b9724f1e93 Text highlighting: extend to include punctuations
When selected text seems to be a "sentence segment"
(that is, when there are punctuations around start
AND end), extend the selection to include the relevant
punctuation.
Do this only when saving highlights and for translation
(but not when dict or wikipedia lookups, or search).
2 years ago
poire-z 141fa98a32 bump crengine: text selection tweaks and helpers
Includes:
- lvtext: fix m_kerning_mode type
- XML: let 'gb2312' (Chinese) encoding be known
- Add ldomXPointer::getChar()
- LVDocView::getNodeByPoint(): tweak for text selection
- Fonts: allow fetching the list of embedded fonts
cre.cpp:
- getTextFromPositions(): use getNodeByPoint(forTextSelection=true)
  to allow panning in margins and get the nearest text instead
  of nothing.
- add extendXPointersToSentenceSegment() to allow extending some
  xpointer range to include punctuations at start or end (with
  for now a quite rudimentory implementation).
- add getEmbeddedFontList() to allow fetching the list of
  embedded fonts in the current EPUB book.
2 years ago
NiLuJe dcb11c2542
Make luacheck >= 0.26 happy (#9174)
Re: https://github.com/koreader/koreader-base/pull/1487
2 years ago
Martín Fdez d644b1a851 android: update doShareText signature 2 years ago
Martín Fdez 8ac8db69ad bump android-luajit-launcher 2 years ago
zwim 02abbfedf1
Clear screen before zsync OTA update starts (#9114) 2 years ago
zwim 5bcd3d0962
[plugin, Terminal] fix crash on clear screen (#9119)
This fixes https://github.com/koreader/koreader/issues/9108#issuecomment-1132243061

Tapping on clear screen during a running program like top, let's KOReader crash.
2 years ago
NiLuJe 73b2b38954
AutoSuspend: Make sure we send a LeaveStandby event ASAP (#9173)
Even in corner cases where we're woken up without user input (e.g., rtc alarm).

(Followup to #9124)
2 years ago
poire-z c825d50c8f CRE: add "CJK width scaling" option
The setting is handled like all other bottom menu options
but, as it's really not useful and its target audience is
very limited, make it not shown in the bottom menu, but
available via another button in the (also quite not useful)
Word Expansion fine tuning widget.
2 years ago
poire-z f29ee8475e Style tweaks: add "Tailor widths and text-indent for CJK"
Also add a timeout to the "Changed language for
typography rules" InfoMessages.
2 years ago
poire-z ccd527ee48 bump crengine: improved typography for Chinese and Japanese
Includes:
- initTableRendMethods(): fix possible crash
- ldomXPointer::getRect(): skip inline pads
- Ruby: keep any last text wrapped in internal table elements
- Font: fix HarfBuzz localized glyphs with CJK punctuation
- lvtext: store kerning mode as a Formatter property
- CJK: improved typography by tweaking punctuations
- CJK: allow scaling CJK glyphs' widths
- CSS/lvrend: adds "-cr-hint: cjk-tailored"
- CJK: expand last line as previous justified line
- CJK: add 1/4 em of spacing between CJK and western words
2 years ago
zwim d868da6977
[plugin, autosuspend] Clean up after #9055 (#9146) 2 years ago
Utsob Roy 6918d62bad
Pretty JSON export (#9165) 2 years ago
Utsob Roy aa4cc6da56
Exporter: fix remote error (#9167) 2 years ago
weijiuqiao 18db85ea0d
[plugin] Vocabulary builder bugfix and quick word deletion (#9168)
This PR fixes the bug #9162 caused by unsafe db operation and adds an edit mode for quick deletion of words requested at #9132 (comment)
2 years ago
Utsob Roy c71167fc6b
[plugin] Exporter: add info messages with status (#9166) 2 years ago
zwim 05d51997f1
SpinWidget, DoubleSpinWidget: add units to bottom menu (#9126)
* Units to bottom menu

* add ¹’¹ to 96dpi
2 years ago
Utsob Roy 71c7a8a042
[Android] Highlights share (#9153) 2 years ago
weijiuqiao ee6197efff
[fix, plugin] Vocabulary builder: prevent resetting changes when reviewing backwards (#9161) 2 years ago
yparitcher 5b29f1b927
Page turn animations: add to dispatcher (#9160)
For real this time :)

See #9123

https://www.mobileread.com/forums/showthread.php?p=4226937#post4226937
2 years ago
zwim f3df8923fa
Move autodim menu position (#9158) 2 years ago
zwim 84c7e33606
AutoDim: Allow to dim the frontlight on idle (#9028) 2 years ago
zwim b26d3e9815
Autoturn: change to minutes and seconds (#9055)
fix #9051
and add some internal improvements (default values) to the datetimewidget.
2 years ago
Frans de Jonge d30a9b52dc
[CI] Use Ubuntu 20.04 Docker image for CI tests (#9007)
They don't seem to crash.

Supersedes #7775.
2 years ago
weijiuqiao e1b137339c
[feat, plugin] Vocabulary builder (#9132)
Made the old dictionary lookup history into a flashcard-ish vocabulary builder.
2 years ago
zwim 5a033f1221
DateTimeWidget: don't make ":" and "/" translatable (#9145)
* And the ellipsis
2 years ago