Commit Graph

7164 Commits (830fc790f13990c28daaf99bab01341726f70f22)
 

Author SHA1 Message Date
Robert 830fc790f1 Battery stats plugin: fix and improvements (#5626)
- fix incorrectly shown awake, sleeping, charging and discharging,
- remove unneeded debug mode and logging to external file,
- prevent showing values like inf, -inf, nan in estimated times
  (we now show "n/a"), and values below zero,
- show extra confirm box when we want to reset data,
- show time in format xxhxxm instead of only pure minutes,
- check at initialization that the device was charging when it was
  turned off (battery level larger than at the time of exit).
5 years ago
Robert 2161a76ea8 fix util.secondsToHClock when hmsFormat is true (#5640) 5 years ago
Robert d93206a841 Remove DCREREADER_PROGRESS_BAR (#5641) 5 years ago
NiLuJe 4778d3db3b
[RFC] Switch remaining keyboard icons to glyphs (#5639)
* Switch the last few remaining icons to true glyphs
(Del/Backspace & Enter).
Also, allow a glyph to be rendered in (fake) bold, and use it for Enter.
* Update fonts
Pickup the tweaked nerdfonts for the backspace symbol
5 years ago
Frans de Jonge 0cbceca98a
Bump luajit-launcher (#5637)
For eink: more devices https://github.com/koreader/android-luajit-launcher/pull/197
5 years ago
poire-z 085d162f23 CoverBrowser: Mosaic: fix alignment on non-fully filled rows 5 years ago
poire-z f410315f83 Screensaver: avoid crash when no lastfile 5 years ago
NiLuJe d8e0b1759b
Other minor frontend.util cleanups (#5629)
* Resync fixUtf8 w/ upstream
* Fix lastIndexOf desc
* Drop unichar usage, it's a crappier unicodeCodepointToUtf8 ;).
5 years ago
poire-z 4740ab1fdc
bump crengine: round FT metrics, split text drawing by script (#5628)
Includes:
- Fonts: round FT metrics instead of floor'ing them
- Fonts: switch to no hinting when native hinting fails
- Fonts: fix issue with Harfbuzz fallback font drawing
- Text: split measuring and word drawing by unicode script
- Page splitting: fix small memory leak
- Fix "background-color: black" ignored on inline elements
- Fix decoding of recent MOBI files
- Hardcoded elements list: add <font>
base/xtext.cpp: small cleanup, no logic change
5 years ago
NiLuJe e0f14a336e
Rewrite unicodeCodepointToUtf8 w/ bitopt (#5625)
* Rewrite unicodeCodepointToUtf8 w/ bitopt

Avoids costly divs & modulos
5 years ago
Frans de Jonge da5f3c0d53
Bump base (#5623)
* [chore] thirdparty patch file dependencies https://github.com/koreader/koreader-base/pull/1012
* Revert "[fix] MuPDF Android font dir patch update https://github.com/koreader/koreader-base/pull/1013

Fixes #5617.
5 years ago
yparitcher 6d3e7fcef6 [fix] PDF footer margins (#5620)
closes #5612 

the change in `ReaderView:recalculate()` causes the viewable page size to be calculated by not including the footer, causing the text not to get cut off.

since the page area was not drawing under the footer `ReaderView:drawPageSurround()` had to be fixed to draw the margin under the footer so when tapping the footer off the area should be dran the background color.
5 years ago
Robert 03fda96041 [fix] Empty directory path and crash on TextWidget (#5606) 5 years ago
Frans de Jonge 7775233688
[fix] Prevent xtext crash by not freeing TextWidget prematurely (#5616)
Fixes <https://github.com/koreader/koreader/issues/5614>.
5 years ago
Robert e655616876 Cloud storage UX improvements (#5613)
* Overwrite confirmbox order

* Restore confirmbox option to read the downloaded book
5 years ago
Frans de Jonge 15fe0fef07
[chore] Extract Cyrillic/Russian keyboard (#5610)
Follow-up to #5583.

* Add separate Cyrillic/Russian keyboard

* And remove that from English

* Update French keyboard (is easy)

* Remove yahzhert, that was just a double of QWERTY

* Update Spanish keyboard

* Reduce Japanese to 4 layers and add globe

* Reduce Korean to 4 layers

* Reduce Greek to 8 layers
5 years ago
Frans de Jonge 67b57834da
[lang] Minor touchups (#5611) 5 years ago
Robert 04741d8cfd [feat] Synchronize local folder with dropbox (#5591)
Option to synchronize files in local koreader folder with folder on Dropbox. All files that aren't on the local disk will be downloaded. Files with different sizes will also be downloaded and overwritten.
The download process can be paused or stopped at any time (similar to downloading images in Wikipedia).

Synchronize and settings are available after long press in dropbox account in Cloud storage.
Limitations: Only one folder (without subfolders) can be synchronize with one folder on local storage.
5 years ago
Frans de Jonge 16fd731f73
[doc] Add coreutils to Mac brew dependencies (#5608)
See 75d02a9038 (commitcomment-36008019)
5 years ago
yparitcher 5e8d1227ef [feat, UX] Pick keyboard layout from keyboard (#5583)
* Tap goes to next activated keyboard.
* Hold opens a selection popup.
5 years ago
Frans de Jonge afd277901a
[fix] Prevent double library loads (#5607)
As per @NiLuJe's suggestions from <https://github.com/koreader/koreader/pull/5598#issuecomment-554767891>.

I'm not super happy with this but being able to easily run the emulator is the most important thing.
5 years ago
Frans de Jonge 50878eab9e
[fix] Tailor plurals match (#5603)
Fixes #5601.
5 years ago
poire-z 9d2da98247
bump xtext: link against stdc++ (#5605) 5 years ago
poire-z 89c0bd0886 ConfigDialog: allow larger toggle title text
Avoid a few truncated text, as some fit when allowed
to bite a bit on the (large) left padding.
5 years ago
poire-z 558bd1ebeb cre fonts list: ignore nerdfonts/symbol.ttf
It's rejected anyway by crengine, this just avoids
an error from being logged.
5 years ago
poire-z dc8696bd34 TextBoxWidget: add new properties, use them in Menu
- height_adjust: if true, reduce height to a multiple of
  line_height (for nicer centering)
- height_overflow_show_ellipsis: if height overflow, append
  ellipsis to last shown line
(Implemented in both use_xtext and legacy code path.)

Use them in Menu.lua to clean up/shorten the code used for multiline
menu items by delegating the work to TextBoxWidget, or using
TextWidget when we end up needing only a single line.
5 years ago
poire-z e699a1ee22 TextBoxWidget: use xtext for text shaping
Alternative code to size, split lines and draw text with
the help of the xtext Lua C module.
Enabled by default (can be disabled via an added menu
item in "Developer options").

New properties can be specified by calling widgets, only
used when xtext is used:
- lang: use specified language instead of the UI language
- para_direction_rtl: true/false to override the default
  direction for the UI language
- auto_para_direction: detect direction of each paragraph
  in text
- alignment_strict: prevent the inversion of the specified
  alignment= that is done when a paragraph direction is
  set or detected as RTL.

Also: fix possible memory leak (present even when not using xtext)
by calling :free() in onCloseWidget() like it's done in ImageWidget.
5 years ago
poire-z 22e3e34c45 TextWidget: use xtext for text shaping
Alternative code to size and draw text with the help
of the xtext Lua C module.
Enabled by default (can be disabled via an added menu
item in "Developer options").

New properties can be specified by calling widgets, only
used when xtext is used:
- lang: use specified language instead of the UI language
- para_direction_rtl: true/false to override the default
  direction for the UI language
- auto_para_direction: detect direction of each paragraph
  in text
5 years ago
poire-z c2e2c00db6 Font rendering: add some helpers for use by xtext
bump base for libkoreader-xtext.so:
- ffi/pic.lua: fix memory leak with some unsupported PNG files
- FreeType ffi: add methods for use with Harfbuzz shaping
- thirdparty: adds libunibreak
- Adds libkoreader-xtext.so: enhanced text shaping

Add a getFallbackFont(N) to each Lua font object to instantiate
(if not yet done) and return the Nth fallback font for the font.

Fallback fonts list: add NotoSansArabicUI-Regular.ttf

Add RenderText:getGlyphByIndex() to get a glyph bitmap by glyph
index, which is what we'll get from Harfbuzz shaping.
(RenderText:getGlyph() works with unicode charcode).
5 years ago
poire-z 272d8857a2 TextBoxWidget: fix two minor bugs 5 years ago
poire-z 0fb780ea21 PicDocument: log reason of opening failure 5 years ago
Robert 679b592c80 [UX] Add Mark as read to end of document action (#5596) 5 years ago
NiLuJe b21b4c8776
Update nerdfonts symbol codepoints for the updated version with no PUA (#5595)
* Update nerdfonts symbol codepoints for the updated version with no PUA conflicts

Should no longer stomp on Arabic & CJK PUA stuff.
5 years ago
Robert e166a77eba [UX] Gesture to open Favorites (#5592)
Close: #5576 
+ default multigesture east - west - east -> open `Favorites`,
+ ability to add new gesture to open `Favorites`
5 years ago
Frans de Jonge 2855fdfdac
[feat] Support callback function in VirtualKeyPopup (#5588)
Required for <https://github.com/koreader/koreader/pull/5583>.
5 years ago
Frans de Jonge 35154b8d56
Bump base for [fix] Prevent undefined symbol error on SDL < 2.0.9 (#5587)
Fixes https://github.com/koreader/koreader/issues/5570 for real this time. ;-)
5 years ago
Frans de Jonge 3550672a5e
Bump base (#5586)
Includes:

* [fix] LuaRocks 2 and 3 compat (#1004)
* [fix] Revert Android Noto patch (#1007)
* [fix] Don't crash on SDL < 2.9 (#1008)
5 years ago
Frans de Jonge 425c808c18
[UX] Switch ButtonTable to COLOR_GRAY (#5585)
Same as the menu.

See <https://github.com/koreader/koreader/pull/5584>.
5 years ago
yparitcher 816b197ab9 [UX] Thicker loading bar (#5581)
The current thickness for the loading bar when opening a document is to thin to really see on my KT4,
5 years ago
yparitcher 83b7d8de2b [UX] Default setting option always enabled (#5580)
as per https://github.com/koreader/koreader/pull/5522#issuecomment-548006595 do not grey out the current default
5 years ago
Robert 98555908c8 [fix] Enable rewind button in sort widget (#5579)
See: #5578
Close: #5578
5 years ago
Frans de Jonge 9bc1c6f40d
Add CODEOWNERS file (#5559)
A bit of an experiment with GitHub functionality.

Teams can be added like `@koreader/kobo-dev` but that doesn't seem too much use to us right now.
5 years ago
Robert 2ae91ac6f6 [fix] Prevent crash on local calibre OPDS server (#5572)
Close: #5476 
- Prevent segmentation fault when we enter incorrect address of calibre opds server (eg http://192.168.1.1:8080/ instead of proper http://192.168.1.1:8080/opds
- prevent unnecessary infos in Gutenberg OPDS
5 years ago
poire-z 0885e9947d Keyboard: avoid additional key stroke on hold release (#5573) 5 years ago
Frans de Jonge dc4453eb7f
[fix, plugin] Don't show full widget together with isOnline() (#5575)
Fixes https://github.com/koreader/koreader/issues/5415

Cf. https://github.com/koreader/koreader/pull/5452 https://github.com/koreader/koreader/pull/5573 https://github.com/koreader/koreader/pull/5574
5 years ago
Frans de Jonge f0b2d58342
Revert "Fix frozen confirmbox when keyboard shown (#5452)" (#5574)
This reverts commit 513fd807b0.
5 years ago
Martín Fernández f1f75c5cb0 android: touchscreen toggle option (#5564) 5 years ago
Robert 371e3336a5 [feat] Favorites: organize book into collections (#5527)
View, add, remove, sort, open book to/from collections.
For now, only one collection named Favorites.
5 years ago
poire-z 04ce1836d8 Avoid double flash when switching or reloading document (#5568) 5 years ago
poire-z 4462380048
Wikipedia lookup results: fix page turning when image loading (#5560)
Tapping to turn page while some image is loading was
interrupting the image loading, but not turning the page,
since a82d7832 where using trap_widget=false is to be
used to not resend the event (while =nil does resend it).
5 years ago