Skip to content

ReaderBookmark: color in bookmark list#14714

Merged
hius07 merged 7 commits into
koreader:masterfrom
hius07:bookmark-list-color
Jan 30, 2026
Merged

ReaderBookmark: color in bookmark list#14714
hius07 merged 7 commits into
koreader:masterfrom
hius07:bookmark-list-color

Conversation

@hius07

@hius07 hius07 commented Dec 12, 2025

Copy link
Copy Markdown
Member

Introducing colored text in the Menu widget.
An option in settings to show color in the Bookmark list.
Filter bookmarks by highlight color.


1 2 3 4 5 6

This change is Reviewable

@Frenzie Frenzie added this to the 2025.12 milestone Dec 12, 2025
end,
},
{
text = _("Include 'gray'"),

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This means whether or not you get a choice of colors on a b&w device?

Comment on lines +702 to +704
if bookmarks_items_show_color then
if item.color == nil or item.color == "gray" then
if bookmarks_items_show_gray then

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is "gray" our default everywhere ? On my emulator, I get my highlights in yellow since a few months ago. I don't remember having done anything special to get them yellow (?).

@hius07

hius07 commented Dec 12, 2025

Copy link
Copy Markdown
Member Author

"Include 'gray'" will be changed to "Include default color".
The default "default color" is 'gray' on bw devices or 'yellow' on color devices.
A user can change the default color, and this option allows to show the background color only for non-default colored highlights.

@hius07

hius07 commented Dec 12, 2025

Copy link
Copy Markdown
Member Author

The thing I'm not happy with is unaligned right edge of the colored rectangles, depending on the mandatory length.
But aligning it by the max page number would eat too much room from the items on lower pages.

@Frenzie

Frenzie commented Dec 12, 2025

Copy link
Copy Markdown
Member

A user can change the default color, and this option allows to show the background color only for non-default colored highlights.

Might it make more sense to just stick the regular star indicator in there? Or do you mean change to something completely custom.

@hius07

hius07 commented Dec 12, 2025

Copy link
Copy Markdown
Member Author

The default highlight color is set in the Typeset - Highlights menu, and the star is already there.

The new option use case: most highlights are in the default color, and only a few are in red.
With "Include default color" unchecked, only red bookmarks are shown colored in the bookmark list.

@hius07

hius07 commented Dec 12, 2025

Copy link
Copy Markdown
Member Author
1

@Frenzie Frenzie left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Alright.

Comment on lines +226 to +235
text = _("Show highlight colors"),
checked_func = function()
return G_reader_settings:isTrue("bookmarks_items_show_color")
end,
callback = function()
G_reader_settings:flipNilOrFalse("bookmarks_items_show_color")
end,
},
{
text = _("Include default highlight color"),

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To my non-native English ears & eyes, the use of "Include" here feels odd.
No obvious alternative suggestion :/

In the past, I've used "Also..." (which feels odd re-reading these :)) when I had no better idea (at least one of these must be mine):

frontend/apps/filemanager/filemanagerfilesearcher.lua:            text = _("Also search in book metadata"),
frontend/apps/filemanager/filemanagercollection.lua:        text = _("Also search in book content (slow)"),
frontend/ui/elements/common_settings_menu_table.lua:            text = _("Also show values in pixels"),
plugins/statistics.koplugin/main.lua:                        text = _("Also use in calendar view"),

so I would have used "[ ] Also show default highlight color".

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think "also show" would be clearer regardless if it's odd or not. But perhaps that's what you meant. :-)

@hius07 hius07 merged commit ae09757 into koreader:master Jan 30, 2026
4 checks passed
@hius07 hius07 deleted the bookmark-list-color branch January 30, 2026 05:54
0xstillb pushed a commit to 0xstillb/koreader-thai that referenced this pull request May 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

FR: Show highlight colours in Bookmarks menu

3 participants