ViewModes do not change automatically as saved tabs....

The behaviour described in the bug report is either by design, or would be far too complex/time-consuming to be changed

Moderators: Hacker, petermad, Stefan2, white

Dennis_Stevens
Senior Member
Senior Member
Posts: 217
Joined: 2013-06-08, 16:16 UTC
Location: NRW, Germany

ViewModes do not change automatically as saved tabs....

Post by *Dennis_Stevens »

.... are reloaded.

Example: In a tab-file I have saved 3 tabs. For two of them a switching-rule is matching.
Do I enter these directories manually all rules are applied.
On reload from Tab-File the rules are not applied.
#230412 Single User Licence
Commanding Win10 64bit totally with version 11
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50550
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

This is intentional. Why? View modes are only changed when going to a different directory. Applying view modes to all opened tab would require to read the directories of all these tabs, e.g. because the user has used a rule "at least 50% jpg files". This would be very slow.
Author of Total Commander
https://www.ghisler.com
Dennis_Stevens
Senior Member
Senior Member
Posts: 217
Joined: 2013-06-08, 16:16 UTC
Location: NRW, Germany

Post by *Dennis_Stevens »

ghisler(Author) wrote:This is intentional. Why? View modes are only changed when going to a different directory. Applying view modes to all opened tab would require to read the directories of all these tabs, e.g. because the user has used a rule "at least 50% jpg files". This would be very slow.
I have to correct myself. It works fine for those tabs where the caption is not changed. The rules are applied correctly.
In all tabs where I have set a new caption the rules are applied after the first directory change within the tab. This cannot be intentional.
#230412 Single User Licence
Commanding Win10 64bit totally with version 11
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50550
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Do you mean tab titles for locked tabs? I will check it.
Author of Total Commander
https://www.ghisler.com
Dennis_Stevens
Senior Member
Senior Member
Posts: 217
Joined: 2013-06-08, 16:16 UTC
Location: NRW, Germany

Try this...

Post by *Dennis_Stevens »

ghisler(Author) wrote:Do you mean tab titles for locked tabs? I will check it.
Do the following (this is the configuration I had):

*1 Open 4 Tabs in a panel in different folders.
*2 Lock Tab No. 1 (make sure the directory or its content do not match to any rule)
*3 Configure a rule Tab No. 2 and 3 match to
*4 Give both (of *3) a new caption
*5 Configure a rule for tab No. 4 all the other rules do not match to and DO NOT change the caption
*6 Save all four tabs to a tab file
*7 Clear all tabs except the locked one.
*8 Load the tab file

The following should happen:
The rule for Step *5 is applied (the tab which is not locked and which has no manually set caption)
The rule for Step *3 is not applied (those 2 Tabs that are not locked but that have a new caption).
#230412 Single User Licence
Commanding Win10 64bit totally with version 11
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50550
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Could you provide a saved tab file and a minimal wincmd.ini which cause this problem? I have tried with the options below, and do NOT have the problem. I created 4 test folders for this:
c:\test\test1
c:\test\test2
c:\test\test3
c:\test\test4

and used them in this order for the 4 tabs. Then I closed all tabs except for the locked, right clicked on it, and chose "Load tabs, replace tabs). The colors and sort orders were correctly restored. What am I doing differently?

My test tab file:

Code: Select all

[activetabs]
0_path=C:\Test\Test1\
0_options=1|0|0|0|0|1|0|
1_path=C:\Test\test2\
1_caption=test2title
1_options=1|2|1|0|0|0|0||255,16316671,15790335|1
2_path=C:\Test\test3\
2_caption=test3title
2_options=1|2|1|0|0|0|0||255,16316671,15790335|1
3_path=C:\Test\test4\
3_options=1|3|0|0|0|0|0||32768,16318456,15794160|2
activetab=0
My test wincmd.ini:

Code: Select all

[Configuration]
UseNewDefFont=1
firstmnu=58

[left]
path=C:\Test\Test1\
ViewMode=-1
activepanelcolor=-1
activepanelcolor2=-1
ShowAllDetails=1
SpecialView=0
show=1
sortorder=0
negative Sortorder=0

[right]
path=e:\test2\_various tests\zip_multivolume\
ViewMode=-1
activepanelcolor=-1
activepanelcolor2=-1
ShowAllDetails=1
SpecialView=0
show=1
sortorder=0
negative Sortorder=0

[ViewModeSwitch]
Enabled=1
0_rules=+c:\test\test2\*\||+c:\test\test3\*\
0_mode=1
1_rules=+c:\test\test4\*\
1_mode=2

[ViewModes]
0_name=<Default>
0_icon=
0_options=1|0|0||-1|-1|-1
1_name=red
1_icon=
1_options=1|2|0||255|16316671|15790335
2_name=green
2_icon=
2_options=1|3|0||32768|16318456|15794160

[lefttabs]
0_path=C:\Test\test2\
0_caption=test2title
0_options=1|2|1|0|0|0|0||255,16316671,15790335|1
1_path=C:\Test\test3\
1_caption=test3title
1_options=1|2|1|0|0|0|0||255,16316671,15790335|1
2_path=C:\Test\test4\
2_options=1|3|0|0|0|0|0||32768,16318456,15794160|2
activetab=0
activelocked=1
Author of Total Commander
https://www.ghisler.com
Dennis_Stevens
Senior Member
Senior Member
Posts: 217
Joined: 2013-06-08, 16:16 UTC
Location: NRW, Germany

Post by *Dennis_Stevens »

ghisler(Author) wrote:Could you provide a saved tab file and a minimal wincmd.ini which cause this problem?
Yes I can.
https://www.dropbox.com/s/w2mnj3d9siftizv/viewtopic_44507.ZIP?dl=0

Problem persists in Beta 3 with this INI.

How can I refresh the INI without loosing all configuration?
#230412 Single User Licence
Commanding Win10 64bit totally with version 11
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50550
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Thanks for the file, I will test with it. Please wait with resetting your settings! We may still need them if I fail to reproduce the problem again...
Author of Total Commander
https://www.ghisler.com
Dennis_Stevens
Senior Member
Senior Member
Posts: 217
Joined: 2013-06-08, 16:16 UTC
Location: NRW, Germany

Post by *Dennis_Stevens »

ghisler(Author) wrote:Thanks for the file, I will test with it. Please wait with resetting your settings! We may still need them if I fail to reproduce the problem again...
OK.
#230412 Single User Licence
Commanding Win10 64bit totally with version 11
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50550
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Could you try this with beta 5, please?
Author of Total Commander
https://www.ghisler.com
Dennis_Stevens
Senior Member
Senior Member
Posts: 217
Joined: 2013-06-08, 16:16 UTC
Location: NRW, Germany

Post by *Dennis_Stevens »

ghisler(Author) wrote:Could you try this with beta 5, please?
I did. And unfortunately the problem persists.
All Tabs that have a different caption configured in the tab-file are not automatically affected by the view modes once the tab-file is loaded. Still I have to activate the tab to see the icon on the tab and have to make a directory-change to get the correct view-mode.
#230412 Single User Licence
Commanding Win10 64bit totally with version 11
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50550
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Did you save the tab files with an older beta? Some older betas did not save the view mode, they saved "reload when opened".

When you save the tabs with beta 5 or newer, TC will save the view modes. When you then load the tab file, the following will happen:
1. On the active tabs, the view modes will be determined immediately with the current view mode rules
2. For inactive tabs, the view modes will be restored from the tab file. Once you switch to the tab, the view mode will be determined again with the current view mode rules

This is done because some people have 100s of tabs - it would take a lot of time to load all these tabs and determine their view modes on program start, or when loading a tab file.
Author of Total Commander
https://www.ghisler.com
Dennis_Stevens
Senior Member
Senior Member
Posts: 217
Joined: 2013-06-08, 16:16 UTC
Location: NRW, Germany

Post by *Dennis_Stevens »

ghisler(Author) wrote:Did you save the tab files with an older beta?
No I did not. I am always starting from the last known condition :)
I will try this as soon as possible and give you a feedback!
#230412 Single User Licence
Commanding Win10 64bit totally with version 11
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50550
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Please check whether it behaves as I described: The view modes of the inactive tabs are restored - but when automatic view mode switching is on, switching to the inactive tabs will re-determine the view mode.
Author of Total Commander
https://www.ghisler.com
Dennis_Stevens
Senior Member
Senior Member
Posts: 217
Joined: 2013-06-08, 16:16 UTC
Location: NRW, Germany

Post by *Dennis_Stevens »

ghisler(Author) wrote:Please check whether it behaves as I described: The view modes of the inactive tabs are restored - but when automatic view mode switching is on, switching to the inactive tabs will re-determine the view mode.
That does not work with this ini-File.
All Tabs that have a user-determined caption are not loaded with the view modes.
Nothing has changed.

So .... how do I refresh the ini without loosing all settings?
#230412 Single User Licence
Commanding Win10 64bit totally with version 11
Post Reply