qownnotes / scripts

QOwnNotes script repository
http://www.qownnotes.org
GNU General Public License v3.0
104 stars 79 forks source link

[BUG] Highlighted text in dark mode is not legible. #204

Closed moshpirit closed 10 months ago

moshpirit commented 1 year ago

Script name

Text highlights

Script authors

@mleo2003, @ryliejamesthomas, Beurt

Expected behavior

Change the body text color from white to black, or the opposite color, so even if we select some dark color, a light color is selected for text. Or maybe letting us select the color of the font.

Actual behavior

Nothing changes, it just adds a yellow background.

Edit: forgot to add the mentions

pbek commented 1 year ago

Best mention the maintainers of the script (with "@"!)

Beurt commented 1 year ago

Hi,

Text Highlights scripts allow you to choose which style you want for the highlight.

Screenshot showing the parameter style of the Text Highlight script

Then, you are free to set the proper colors in the Editor fonts & colors settings of QON

Screenshot showing the parameters for a specific style in QON

Finally, with the script Custom note preview styling you can configure the highlight style for the preview.

Screenshot showing the custom preview styling script parameters

Is it what you needed?

moshpirit commented 1 year ago

Thanks for replying, @Beurt! I appreciate the script, I think it's really cool, I turned it into red, and it looks good in dark themes.

Then, you are free to set the proper colors in the Editor fonts & colors settings of QON

I don't know what you mean exactly by that, in your screenshot, you cannot change the style, it appears as the options are disabled (meaning that we can't change the font, background color, or foreground).

What I meant is that it would be nice to have the script to automatically change the foreground font color, when the background color is very similar, or if not, maybe showing an option to manually change the foreground color of the font.

I don't know anything about the technical stuff; but maybe it could be achieved by:

I have even less idea about hexadecimal colors, but the automation of the foreground color, might be easy to achieve by changing the letters "E" or "F" to "0" and vice versa.

ryliejamesthomas commented 1 year ago

It's a bit confusing, but to change the styles you have to press 'copy' to create a new schema that can be edited.

(I agree that it'd be nice to be able to change the colour with a regular colour picker, but this is a workaround)

Beurt commented 11 months ago

Sorry @moshpirit and @ryliejamesthomas but I don't think it is possible to alter styles with a QON Script. You have to do it by hand like I explained in https://github.com/qownnotes/scripts/issues/204#issuecomment-1780524482.

github-actions[bot] commented 10 months ago

This issue is stale because it has been open for 30 days with no activity.

github-actions[bot] commented 10 months ago

This issue was closed because it has been inactive for 14 days since being marked as stale.