File Window Variables

Started by axel.hennig, April 13, 2023, 09:23:01 PM

Previous topic - Next topic


Related to this post: Variable for "Total files in File Window" available?

This is a suggestion to create two new Variables ->  File Window Variables:
  • Index of the selected file in the current File Window (x)
  • Total number of files in the current File Window (n)

With those Variables one could create a Layout Template showing something like:
  • This is file x of n
  • x of n
  • x / n

One could also think of additional File Window Variables, for example:
  • Number of currently selected files
  • Number of stacked files
  • Number of files hidden by a stack
  • Number of protected files


I think, like Mario pointed out somewhere, this ist doable.

My wish for variables for categories (,13137.0.html) would give a lot more work, I guess, hence I support simply your FR.  :)
Best wishes from Switzerland! :-)


I have thought about this and the implementation was quite straightforward.
The File Window already maintains a var context, because this is needed for custom templates in File Window Layouts.
I've augmented that context with a new kind of variables with the prefix {FW.}.

So far I have created {FW.Index}, {FW.FileCount} and {FW.FileSize}.
These variables are based on the filtered and stacked content of the File Window, reflecting the numbers you see in the File Window Caption.

Like zis:


-- Mario
IMatch Developer
Forum Administrator  -  Contact & Support - Follow me on 𝕏 - Like on Facebook