jarun / nnn

n³ The unorthodox terminal file manager
BSD 2-Clause "Simplified" License
19.38k stars 761 forks source link

dirs in context color fix #1898

Closed a-gruzdev closed 5 months ago

a-gruzdev commented 5 months ago

When you launch nnn -D , directories use some default color instead of context color

I made some investigation and found out that this check if (color_pair && fcolors[color_pair]) is always false for context colors, as it's values in fcolors are always 0.

dbg

I added it's initialization in initcurses to fix this. Now it looks like this

col1 col2
jarun commented 5 months ago

Did you test without -D to confirm there are no side effects?

a-gruzdev commented 5 months ago

yes, tested without -D, dirs use their color from fcolors (blue by default), and everything else works as expected

jarun commented 5 months ago

Thank you!