Page 1 of 1

Lister: Define view method by file type... (except ExplorerPreview method) dosen't work for HTML files

Posted: 2020-09-06, 13:44 UTC
by DrShark
To reproduce:
1. Start Total Commander with clean ini.
2. Open some HTML file in Lister, it will show the file in view 5/HTML (strip tags).
3. Define in Lister any new default view method for *.htm *.html (except ExplplorerPreview):
go to Lister's Options, Configure..., Multimedia, check Define view method by filt type..., press that button and then
Add..., type *.htm *.html, with [+] button add desired view method and then confirm all the changes.
4. Close Lister and reopen the same HTML file with F3:
Lister will still use the 5th view method, HTML (strip tags) as default view.

Only if to define the 8 (ExplorerPreview) as a view method in step 3, it then will be used by default for *.htm, *.html.

Reproduced on Windows 7 32-bit with TC 9.51 final.

Re: Lister: Define view method by filt type... (except ExplorerPreview method) dosen't work for HTML files

Posted: 2020-09-06, 15:24 UTC
by petermad
2DrShark
It seems that the option "Show HTML as test with links" takes precedence over the option "Define view method by file type".

If "Show HTML as test with links" is disabled you can "Define view method by file type" for *.htm* files.

Hardly a bug, rather maybe just unexpected.

Re: Lister: Define view method by file type... (except ExplorerPreview method) dosen't work for HTML files

Posted: 2020-09-06, 15:46 UTC
by DrShark
2petermad
HTML (strip view) is a separate view method, such as other 7 view methods, so I think "Define view method by file type" should get a priority no matter what state the "Show HTML as test with links" option has (this option doesn't disable the feature completely, it just defines Lister's behavior at startup). So looks more like a bug to me.

Re: Lister: Define view method by filt type... (except ExplorerPreview method) dosen't work for HTML files

Posted: 2020-09-06, 17:43 UTC
by petermad
(this option doesn't disable the feature completely, it just defines Lister's behavior at startup
So does all of the options in that dialog.

But, since "Define view method by file type" overrides the 3 options "Use plugins or load bitmap as graphics at startup", "Multimedia (AVI,WAV,...)" and "RTF", then it is only fair that the option "Show HTML as test with links" should also be overridden to be consistent, so I agree that it should be changed - bug or not.

Re: Lister: Define view method by file type... (except ExplorerPreview method) dosen't work for HTML files

Posted: 2021-03-24, 16:06 UTC
by DrShark
As of TC 10.00 public beta 2, I see following behavior:
  • Case 1: plugin that handles *.htm *.html is not installed:
"Define view method by type..." allows to set any view method for *.htm, *.html or both.
  • Case 2: plugin that handles *.htm *.html by content is installed (I tested with IEWebLister, which BTW I could install only by directly writing a path to its .wlx into [ListerPlugins] section of wincmd.ini, on try to install it by pointing to .wlx from TC's Options->Plugins TC showed an error that plugin dll can't be loaded):
view method set in "Define view method by type..." for *.htm, *.html or both is ignored by Lister on F3, IEWebLister always loaded for both by default.
  • Case 3: plugin that handles *.htm *.html by content, but also the extensions set for it in explicit way in wincmd.ini's [ListerPlugins]:

    Code: Select all

    [ListerPlugins]
    0=c:\totalcmd\plugins\wlx\wlx_ieweblister_1.01\IEWebLister.wlx
    0_detect="EXT="HTML" | EXT="HTM""
    In this case, if NOT to set any kind of view method in "Define view method by type..." for *.htm and *.html (so these extensions arn't even listed under ("Define view method by type..."), Lister by F3 open both *.htm and *.html in Text view (aka view merthod 1), and will only switch to IEWeblister after pressing "4" key.
  • Subcase 3.1. If now to set in the "Define view method by type..." association only for *.htm and to use view method 3 (HEX) for it, there are following results:
    • for *.htm after pressing F3 Lister will use HEX mode (3), after following keypress of "4" key view will switch to method 1 (Text), and next keypress of "4" will switch to IEWebLister.
    • for *.html after pressing F3 Lister will use method 5 HTML (strip tags), following keypress of "4" key will switch to IEWebLister.