Colouring directories as well as files

Here you can propose new features, make suggestions etc.

Moderators: Stefan2, white, sheep, Hacker

Post Reply
sbertolucci
Junior Member
Junior Member
Posts: 17
Joined: 2003-10-18, 23:35 UTC
Location: Milan

Colouring directories as well as files

Post by *sbertolucci » 2019-05-03, 09:50 UTC

Hi,

I don't know if it is already possible, but in case it isn't I would like to have the possibility to assign colors to folders.
I have one case in which there are several subfolders into a folder (on whose name I don't have control and the names are quite cryptic).
Each subfolder's content can have different meaning
Now, if I could assign a different color for each meaning it'd be easier for me to pick the correct ones depending on what I have to do. Now every time I have to proceed by trial and error because there is no connection between the folder name and its content type.

Thanks for the attention

Stefano
WC License # 44689

User avatar
petermad
Power Member
Power Member
Posts: 8471
Joined: 2003-02-05, 20:24 UTC
Location: Valsted, Denmark
Contact:

Re: Colouring directories as well as files

Post by *petermad » 2019-05-03, 11:50 UTC

Is it the background color of the folder panel you want to colorize, or is it the names of the folders? Both is already possible in TC

And could you give som examples - it is not very clear (to me, at least) what you mean?
Last edited by petermad on 2019-05-03, 17:27 UTC, edited 1 time in total.
License #524 (1994)
Danish Total Commander Translator
TC 9.22a 32+64bit on Win XP 32bit, Win 7, 8.1 & 10 (1903) 64bit, 'Everything' 1.4.1.935 (x64)
TC 3.0b6 on Android 6.0
Get: Extended Total Commander Menus | PHSM-Calendar

User avatar
clifford_cooley
Junior Member
Junior Member
Posts: 38
Joined: 2019-03-05, 06:04 UTC
Location: USA

Re: Colouring directories as well as files

Post by *clifford_cooley » 2019-05-03, 12:04 UTC

As long as it is opt-in, it would be fine by me. All the colors in a programming text editor is distracting to me.
License #116347

sbertolucci
Junior Member
Junior Member
Posts: 17
Joined: 2003-10-18, 23:35 UTC
Location: Milan

Re: Colouring directories as well as files

Post by *sbertolucci » 2019-05-03, 19:14 UTC

petermad wrote:
2019-05-03, 11:50 UTC
Is it the background color of the folder panel you want to colorize, or is it the names of the folders? Both is already possible in TC

And could you give som examples - it is not very clear (to me, at least) what you mean?
I'd rather change the font color, background is too heavy

As an example, if I have in a TC Panel
[..]
[Dir1]
[Dir2]
[Dir3]

I would like to be able to see them like
[..]
[Dir1]
[Dir2]
[Dir3]

Based maybe on some local settings made directly by me and just when needed.
Of course the logic used to color files (the extension) here can't be used for directories and automatic coloring based on content would be too complex and maybe slow
WC License # 44689

User avatar
petermad
Power Member
Power Member
Posts: 8471
Joined: 2003-02-05, 20:24 UTC
Location: Valsted, Denmark
Contact:

Re: Colouring directories as well as files

Post by *petermad » 2019-05-04, 07:53 UTC

2sbertolucci
As you can see here: http://madsenworld.dk/tcmd/dircolor.png - it is possible, but you have to make a rule for every dir you want coloured...

It can either be for all dirs with those names or just for dirs in a particular path.
License #524 (1994)
Danish Total Commander Translator
TC 9.22a 32+64bit on Win XP 32bit, Win 7, 8.1 & 10 (1903) 64bit, 'Everything' 1.4.1.935 (x64)
TC 3.0b6 on Android 6.0
Get: Extended Total Commander Menus | PHSM-Calendar

sbertolucci
Junior Member
Junior Member
Posts: 17
Joined: 2003-10-18, 23:35 UTC
Location: Milan

Re: Colouring directories as well as files

Post by *sbertolucci » 2019-05-04, 11:33 UTC

Wow, thanks!!!!
Could you please give me an example of such a rule ?
I'm an old user of TC, but not so good in this kind of things.

Thanks

Stefano
WC License # 44689

User avatar
petermad
Power Member
Power Member
Posts: 8471
Joined: 2003-02-05, 20:24 UTC
Location: Valsted, Denmark
Contact:

Re: Colouring directories as well as files

Post by *petermad » 2019-05-04, 17:18 UTC

You can either make a rule for the specific directory name (for example Dir1) like this:
Put this in the [Searches] section of your windmd.ini file:

Code: Select all

Dir1_SearchFor=
Dir1_SearchIn=
Dir1_SearchText=
Dir1_SearchFlags=0|002002010021||||||||22221|0000|||
Dir1_plugin=tc.name = Dir1
And this in the [Colors] section:

Code: Select all

ColorFilter1=>Dir1
ColorFilter1Color=33023
This will make any directory with the name Dir1 orange in the file list
You will have to change 1 in Filter1 to another number, if you have other color filters of your own.
If it doesn't work with a higher number than 1, then go into "Configuration" -> "Options..." -> "Color" - enable "Define colors by file type" and click the button "Define colors by file type". Then move "Dir1" up in top of the list in the "Define colors by file type" dialog.

----------------

You can also do it so you mark any folder or file to be colored by using the File Comment function:
Put this in the [Searches] section of your windmd.ini file:

Code: Select all

Color orange_SearchFor=
Color orange_SearchIn=
Color orange_SearchText=
Color orange_SearchFlags=0|002002010021|||||||||0000|||
Color orange_plugin=tc.comment contains color=orange
And this in the [Colors] section:

Code: Select all

ColorFilter1=>Color orange
ColorFilter1Color=33023
Then on the directory Dir1 press Ctrl+Z and write: color=orange in the box and press F2.

This will make the directory with the name Dir1 orange in the file list - or any dir/file that you give the comment color=orange.
You will have to change 1 in Filter1 to another number, if you have other color filters of your own.
If it doesn't work with a higher number than 1, then go into "Configuration" -> "Options..." -> "Color" - enable "Define colors by file type" and click the button "Define colors by file type". Then move "Color orange" up in top of the list in the "Define colors by file type" dialog.

If you want to change the shade of the color go to "Configuration" -> "Options..." -> "Color" -> "Define colors by file type" -> "Edit" -> "OK" and pick another color in the color picker.

.
Last edited by petermad on 2019-05-06, 20:38 UTC, edited 1 time in total.
License #524 (1994)
Danish Total Commander Translator
TC 9.22a 32+64bit on Win XP 32bit, Win 7, 8.1 & 10 (1903) 64bit, 'Everything' 1.4.1.935 (x64)
TC 3.0b6 on Android 6.0
Get: Extended Total Commander Menus | PHSM-Calendar

sbertolucci
Junior Member
Junior Member
Posts: 17
Joined: 2003-10-18, 23:35 UTC
Location: Milan

Re: Colouring directories as well as files

Post by *sbertolucci » 2019-05-04, 22:03 UTC

Thank you so much!!!!
Stefano
WC License # 44689

User avatar
petermad
Power Member
Power Member
Posts: 8471
Joined: 2003-02-05, 20:24 UTC
Location: Valsted, Denmark
Contact:

Re: Colouring directories as well as files

Post by *petermad » 2019-05-06, 20:40 UTC

CORRECTION!
In order for the approach using file comments to colorize the directory/file name to also work for files, the line:

Code: Select all

Color orange_SearchFlags=0|002002010021||||||||22221|0000|||
has to be changed to:

Code: Select all

Color orange_SearchFlags=0|002002010021|||||||||0000|||
I have edited the previous post accordingly.
Last edited by petermad on 2019-05-07, 11:58 UTC, edited 1 time in total.
License #524 (1994)
Danish Total Commander Translator
TC 9.22a 32+64bit on Win XP 32bit, Win 7, 8.1 & 10 (1903) 64bit, 'Everything' 1.4.1.935 (x64)
TC 3.0b6 on Android 6.0
Get: Extended Total Commander Menus | PHSM-Calendar

sbertolucci
Junior Member
Junior Member
Posts: 17
Joined: 2003-10-18, 23:35 UTC
Location: Milan

Re: Colouring directories as well as files

Post by *sbertolucci » 2019-05-07, 11:15 UTC

Thanks!!!
WC License # 44689

Post Reply