Make Notification have toast=true, and UIManager deal
specifically with such widget:
a "toast" widget gets closed by any event, and let
the event be handled by a lower widget.
This should allow us to not wait or tap to get rid
of a notification, and just go on with what we're
doing.
Also make them have a default timeout of 2s,
used with all existing ones.
* Fix HW dithered partial refreshes sometimes behaving as if the refreshed
content had moved a few pixels to the side...
Probably a kernel issue with the alignment fixup in the EPDC?
* Get rid of the legacy coordinates fixup
It shouldn't be necessary anymore.
And I'd rather fix the root cause, anyway.
* Bump base
(https://github.com/koreader/koreader-base/pull/1116)
* Missed a few DIVs in #6224
Allows editing a CSS snippet to be applied to this
book only, without the need to create and edit
a User style tweak.
Allows copying any other tweak CSS by just taping
on it (and pasting into this with Hold).
Limit User style tweaks nb of items per menu page
to 6 (like we try to do for other tweaks menus).
Set these 2 tweaks as default global tweaks for new users
(and existing users that have not set any global defaults).
One can disable them by long-press on each of them.
Only per-specs EPUB and FB2 footnotes (other in-page footnotes
tweaks may trigger on non-footnote content on some books, so
let enabling them be a user decision).
bidi.lua:
- Revert "Alias everything to Bidi.nowrap() when in LTR UI,
as using LTR isolates seems uneeded when already LTR" (part
of a628714f) which was a wrong assumption: we need proper
wrappers for all things paths. Enhance some of these wrappers.
- Fix GetText RTL wrapping which was losing empty lines and
trailing \n.
- Wrap all paths, directories, filenames in the code with
these wrappers.
- Wrap all book metadata (title, authors...) with BD.auto(),
as it helps fixing some edge cases (like open/close quotation
marks which are not considered as bracket types by FriBiDi).
(Needed some minor logic changes in CoverBrowser.)
- Tweak hyphenation menu text
- Update forgotten SortWidget for UI mirroring
- KoptConfig: update "justification" index for RTL re-ordering,
following the recent addition of the page_gap_height option.
Allow TextBoxWidget new text direction/lang parameters to be
set on upper widgets, and propagate them all the way to it
(ScrollTextWidget, InputText, InputDialog, TextViewer).
Use specific non-default ones in some specific cases:
- Force LTR text direction when showing HTML and CSS, and
configuration files (in some plugins).
- Use Wikipedia server language and text direction when
showing an article.
- Use auto with Dictionary results, as we don't know the
dictionary language, and they may contain mixed content.
- Force LTR when showing some paths (still needs more of them)
TextEditor plugin: add 2 new options "Auto paragraph direction"
and "Force paragraph direction LTR".
Footnotes popup: grab HTML direction, and forward it
to MuPDF for proper display.
Revert 9971eb85 and make multi-lines strings more readable.
(Multiline translatable strings extraction has been fixed
in koreader-misc tralua_xgettext.py.)
When no height= provided, and the InfoMessage would overflow
screen height when some long message is provided, decrease the
font size until the widget fit.
Adds 2 tweaks to allow displaying footnotes at the bottom of pages,
like it's done in some printed books. This will work only with
books with correctly specified footnotes with the adequate EPUB
attributes, and with Wikipedia EPUBs. But users may be able to
activate them for other books with some user style tweaks.
Adds a few tweaks to control the build of the alternative TOC.
With some user style tweaks, one may be able to build a usable
TOC for some badly formatted or converted books.
Also fixes 2 paragraphs tweaks.
TouchMenu: added options to menu items with the following defaults:
keep_menu_open = false
hold_keep_menu_open = true
So, default for Tap callback is to close menu, and for Hold callback
to keep menu open.
In both cases, provide the TouchMenu instance as the 1st argument to
the callback functions (instead of a refresh_menu_func I added in #3941)
so the callback can do more things, like closing, refreshing,
changing menu items text and re-ordering...
ReaderZooming: show symbol for default (like it was done for
ReaderFont, ReaderHyphenation...)
TextEditor plugin: update the previously opened files list in real
time, so the menu can be kept open and used as the TextEditor main
interface.
SSH plugin: keep menu open and update the Start/Stop state in real time
ReadTimer plugin: tried to do what feels right (but I don't use it)
Also remove forgotten cp in the move/paste file code
Some problem somewhere with [[...]] strings starting with a
leading newline. Should probably be allowed, but for now
fix the few such cases to allow them being translated.
Books previously opened (that have a metadata.lua, whether with
highlights or not, but because they all have a last_xpointer that
points to the current page, that can be broken too by the changes)
will continue to have the old wrong behaviour, so they won't be
impacted by the breaking changes.
Update cre_dom_version code to use the new functions from cre.cpp.
Remove these Workarounds from Style tweaks.
Alternate rendering of list items as block elements (instead of
inline/final).
Check the built DOM is still coherent with styles on stylesheet
change, and propose to reload the document if not. Also
invalidate cache on close in that case so a new DOM is built
at next opening.
ReaderStyleTweak: fix tweak css duplication; when globally
enabled, when disabling and re-enabling locally, the css would
be added twice to the final CSS.
Also adds !important to "sub_sup_smaller" tweak, and increase
its priority so it can override "font_size_all_inherit".
Adds CreDocument:getCacheFilePath() for futur features.