Fixes#13278.
* Add correct external keyboard punctuation key names
* Compose physical-keyboard text via a layout and TextInput
* Expand to multiple possible layers
* Add XKB conversion script
* Give ourselves some dead key support
* Add license identifier
* Improve AltGr
* Group the layouts together
* And add the common layouts
* Expand with regular US international (with regular non-AltGr dead keys)
* Add some other scripts (that should do it)
* [fix] Avoid rotating up/down in external keyboards along with the device orientation
* Log keyboard layout in case of issues
* Also listen to PrintScr 'cause that's what the thing is for, isn't it
---------
Co-authored-by: Frans de Jonge <fransdejonge@gmail.com>
A mosaic cell already carries a full-thickness underline, painted white until it
takes the focus, so the strip only ever changes colour: there is nothing to
reserve or to clear. The cell hands its focus indicator out like the other views.
Unintuitively, FileManager:deleteFile updates history and collections,
but FileManager:moveFile doesn't, so we need to do it manually (like
movetoarchive.koplugin does).
Otherwise, articles added to Favourites (or any other collection) will
either
a) crash koreader if someone tries to open it from the collection immediately
b) disappear from the collection after koreader restart
Moving (or deleting) the file while it's still being open in the reader
causes problems: its metadata will be written to the old location when
it's eventually closed, and I think I've seen crashes as well (don't
quite remember but something like switching to File Browser and then
using the Open Last Book function or something).
The simplest solution is to just not archive it while it's still open.
It will be archived on the next sync anyway.
Alternatively, we could do what movetoarchive.koplugin does, and ask the
user whether they want to open it from the new location (if archiving)
or switch back to File Browser:
https://github.com/koreader/koreader/blob/8c4d6c0a3ab8449ac65b413187d27d54f50fd946/plugins/movetoarchive.koplugin/main.lua#L153-L161
I don't think it's worth the complexity though — Move to Archive doing
nothing is bad UX, obviously, but a Wallabag sync skipping one article
until the next sync is fine, IMO.
I suspect this might also be related to this TODO note:
https://github.com/koreader/koreader/blob/8c4d6c0a3ab8449ac65b413187d27d54f50fd946/plugins/wallabag.koplugin/main.lua#L1428
The arxiv .pdf-suffix workaround ran unconditionally after the rel
handling, so an acquisition link with type="application/pdf" and no
.pdf suffix was added twice. Only apply it when the link produced no
acquisition above.
Fixes#15849
InputDialog binds the Back key group, but its handler only presses a button
carrying id "close" and does nothing when the dialog has none, so on a
non-touch device those dialogs cannot be dismissed with the key at all: the
only way out is to aim the cursor at Cancel.
Dialogs that can lose work should get that button (_addSaveCloseButtons adds
it alongside save_callback, and its callback is what asks about unsaved
changes), so the rest can simply close, as ButtonDialog does with the same key.
Including the archive dir in the result of Wallabag:getLocalArticles
causes all archived articles' statuses to be synced with Wallabag every
time. That leads to an increase in sync times from seconds to minutes
(or even more if one's archive is larger than hundreds…).
The fix is simple: skip the archive dir when scanning.
(As a side effect, this allows one to organise their archive dir using
subdirs, which is similar to the motivation of the PR that broke this…)
Fixes: 896646bf8b ("Reworked the Wallabag plugin to recursively scan the download directory (#15558)")
Fixes: https://github.com/koreader/koreader/pull/15558#issuecomment-5136923551