Missing Entry highlight in interactive mode on Win10-x86-64-MSVC
When using dua i on windows 10 I noticed that I did not see any highlight on the currently selected item.
I was using dua with Microsoft Terminal + Powershell Core 7. One specific thing I noticed when attempting to run this directly on the Powershell 7 shell is that the currently selected item has a slightly whiter text, but still no selection (inverted color on the current item).
below is a screenshot using the powershell 7 shell

The currently selected item is the audioplayback folder. But as you can see its almost completely impossible to distinguish.
other things of note are:
- having a
?in the beginning of current path on the top. - the "capacity" meters next to directory having unrecognized characters (this seems to be a problem with my default terminal font
consolas, switching to the newcascadia codefont in my terminal fixed this)
Other than these problems, it's a very nice program to use :)
Thanks for the screenshot and the research thus far, it will surely prove to be helpful. As I don't easily have access to a windows machine, I hope someone can dig in and try different color combinations especially for windows powershell.
It might be worth trying what that does in Alacritty for instance, or cmd.exe. Maybe in the end there is no one-size-fits-all solution, and dua has to detect the terminal it runs in and adapt accordingly.
I'm willing to take a stab at this, I'll need a bit of help with pointing me to the correct place to change this behavior. I have done some programming in Rust, so this should be a good exercise 😄.
Great, let me help you getting started then.
By the looks of it, the foreground color of entries is handled here, whereas the background color when selected is controlled in this place.
I reckon one could play around with the values and try them iteratively using cargo run -- i.
Good luck!
So I seem to have come across a problem which I am not sure where it came from. I build the project from source (with nightly-x86_64-pc-windows-msvc) and the highlight issue was not there.
I have downloaded the binary for dua from your github releases. so to eliminate random corruption i have downloaded the binary again and compared the filehash of my local build, the first downloaded binary and the fresh download
the result were:
- the first and the second download had the same filehash
- the second download and the self-compiled (release-nightly) one had a different hash
I am tempted to point to the toolchain that you've used to compile for windows as the possible cause for this problem, do you maybe have some information on how you compiled it?
we can probably resolve this by updating the nightly toolchain & creating a different release. Although i would not be sure what the cause was.
This sounds like a dependency update (in the mean time) has fixed the issue coincidentally, as I don't think a different toolchain would be able to have that effect. What are the odds?
I will put it to the test and create a new patch release right away.
The binary-build is on the way, and v2.10.3 has been released. Please let me know if it now works for you.
This build seems to fix the issue for Windows Terminal, but not for the Powershell Shell.
This practically fixes it for me, since my primary terminal is the Windows Terminal. I'm unsure as to what could create the difference between powershell and windows terminal though...
I am waiting for an update to tui to see if a more recent version of crossterm fixes the issue. I will update this issue once there is something new to test.
FYI, I have tested dua in interactive mode on Windows 11 in cmd, PowerShell and Git Bash and highlighting currently selected item worked in all of them.
Thanks! Let’s reopen this issue or create a new one of this still doesn’t work for some.