kaorahi / lizgoban

Leela Zero & KataGo visualizer
GNU General Public License v3.0
169 stars 28 forks source link

Can the text color of the win rate percentage be dynamically changed? #94

Open qcgm1978 opened 11 months ago

qcgm1978 commented 11 months ago

The current win rate is displayed in white, which is easily misleading as to the win rate of white chess. Additionally, the color has no correlation with the win rate itself. It is possible to consider dynamically setting it to other colors, for example, the following modification:

const get_color = (percent) => {
    if (percent < 40) {
        return 'red';
    } else if (percent < 60) {
        return 'orange';
    } else if (percent < 80) {
        return 'yellow';
    } else {
        return 'green';
    }
}
function draw_winrate_graph_current(g) {
    ...
    g.strokeStyle = g.fillStyle = get_color(percent);
    fill_text(g, unit * 2, `${percent}%`, ...here)
    g.restore()
}

https://github.com/kaorahi/lizgoban/assets/3024299/1020ce32-5747-4bae-8a38-5c60cd1d3cb9

kaorahi commented 11 months ago

Oh, I hadn't noticed that this white lettering can be misleading. Color design is really difficult...

Since this is the first complaint I've received about this issue, I'd like to postpone making a decision until we gather more feedback from other users.

We need to remind ourselves that simple change in text color can cause a readability problem when it is placed over the winrate line. It may be necessary to redesign the colors of all elements together. This is not a small task in my impression.

kaorahi commented 10 months ago

By the way, I was really surprised to see that you disabled "Lizzie style" in your movie. I thought I was the only one who prefers "annoying red lines across the board" over "many small digits that strain the eyes".

qcgm1978 commented 10 months ago

I really don't like seeing too many numbers on the board, and I want to record videos by autoplaying them, so I don't need those numbers either.