![]() |
#1 |
want to learn what I want
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,611
Karma: 7891011
Join Date: Sep 2020
Device: none
|
Template editor code colors
Are the code colors in the template editors customisable?
I wanted to change them to higher contrast tones. |
![]() |
![]() |
![]() |
#2 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 12,436
Karma: 8012886
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
|
No, they aren't without changing source. If you want to do that then see line 160 in calibre.gui2.dialogs.template_dialog.py.
FWIW: keywords, builtin functions, and constants all use the "link" color. The colors for strings, comments, numbers are all hard coded. |
![]() |
![]() |
Advert | |
|
![]() |
#3 |
want to learn what I want
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,611
Karma: 7891011
Join Date: Sep 2020
Device: none
|
I've used the Color Variations View in this nifty program SE-ColorMaker, and found that three shades brighter than the current are way more visible in Dark Theme, here's what's in the "changed tones" screenshot:
("comment", "#00C700", False, True), ("string", "#B6B600", False, False), ("number", "#D96D00", False, False), Before changes, not so visible: |
![]() |
![]() |
![]() |
#4 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,331
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
|
![]() |
![]() |
![]() |
#5 |
want to learn what I want
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,611
Karma: 7891011
Join Date: Sep 2020
Device: none
|
![]() |
![]() |
![]() |
Advert | |
|
![]() |
#6 |
Guru
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 888
Karma: 409970
Join Date: Sep 2017
Location: Buenos Aires, Argentina
Device: moon+ reader, kindle paperwhite
|
![]() |
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Referring to column colors in template | estherflails | Library Management | 7 | 07-18-2021 11:36 AM |
Template : IF code is correct? | un_pogaz | Calibre | 4 | 12-22-2020 10:32 AM |
Template editor | Jellby | Calibre | 4 | 08-23-2014 03:10 AM |
Multiple conditions in TEMPLATE code | HFC3 | Library Management | 4 | 07-07-2013 01:39 PM |
template editor error | lrui | Calibre | 2 | 11-06-2012 10:07 AM |