https://bugs.kde.org/show_bug.cgi?id=477042

            Bug ID: 477042
           Summary: GitHub Dark colour scheme makes two adjacent csv
                    columns same colour
    Classification: Applications
           Product: kate
           Version: 23.08.2
          Platform: openSUSE
                OS: Linux
            Status: REPORTED
          Severity: minor
          Priority: NOR
         Component: sessions
          Assignee: kwrite-bugs-n...@kde.org
          Reporter: matterhorn...@proton.me
  Target Milestone: ---

STEPS TO REPRODUCE
1. Use GitHub Dark theme in Kate
2. Open csv file with 10+ columns

OBSERVED RESULT
CSV files have the following syntax highlighting:
white               #e1e4e8    columns 0, 8
orange            #ffab70     column 1
light blue        #9ecbff      columns 2, 5
red                   #f97583     columns 3, 4, 9
purple             #b392f0     column 6
medium blue #79b8ff      column 7

This means three colours are repeated, two of the red columns are next to each
other, and the white columns are only separated by one other column. The two
blues are also extremely similar, so in practice there are three barely
distinguishable blue columns. And the pattern repeats every 10 columns, so in a
20-column csv, six are blue and look essentially the same, and another six are
all the same red!

Legibility of csv files with GitHub Dark is thus much worse in comparison to
e.g. Breeze. The palette of GH Dark is very restricted in comparison to Breeze,
so it will never be ideal for distinguishing colours, but a more sensible
implementation is surely possible.

EXPECTED RESULT
I'm not sure to what extent the set of colours and method of syntax
highlighting of the GitHub themes are determined by how GitHub does it, but
there must be a better way of doing specifically CSV syntax.

I would suggest either settling on five colours and repeating them every 5
columns rather than 10, but spaced evenly:
PROPOSAL 1
white               #e1e4e8    columns 0, 5
orange            #ffab70     column 1, 6
light blue        #9ecbff      columns 2, 7
red                   #f97583     columns 3, 8
purple             #b392f0     column 4, 9
In this version, there are twice as many columns of each colour vs Breeze, but
at least every column has high contrast with its neighbours and all colours are
distinguishable.

My second suggestion would be to add in the dark blue, grey, and dark red from
the Python syntax highlighting, for a total of 9 colours, then simply adding a
tenth colour that fits nicely with the palette. To keep it in-keeping with the
GH palette, which really doesn't have any other colours, how about a grey
halfway between the grey and white? Then space the reds, blues and greys out to
get:
PROPOSAL 2
white       #e1e4e8     column 0
orange      #ffab70     column 1
light blue  #9ecbff     column 2
red         #f97583     column 3
light grey  #a6acb3     column 4
medium blue #79b8ff     column 5
purple      #b392f0     column 6
grey        #6a737d     column 7
dark blue   #41a0ff     column 8
dark red    #ff5555     column 9

This way no colour is next to another of the same, there are no clusters, and
each greyscale/red/blue is flanked by different pairs of colours to the others,
helping legibility.


SOFTWARE/OS VERSIONS
Linux/KDE Plasma: OpenSUSE Tumbleweed 20231108
KDE Plasma Version: 5.27.9
KDE Frameworks Version: 5.111.0
Qt Version: 5.15.11

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to