Page 1 of 2

Implement text zooming in the lister

Posted: 2020-01-09, 10:44 UTC
by nibbler
Hi,

It would be great if you were able to zoom the text in and out in the lister. For instance in Notepad++ has this feature (... and in my opinion very good keyboard shortcuts and mouse functionality for it). :wink:

Re: Implement text zooming in the lister

Posted: 2020-01-09, 11:18 UTC
by ghisler(Author)
The problem is that the default fonts used (system fixed font) are bitmap fonts, and there aren't any good looking truetype or opentype fixed fonts I could set as a default instead.

Re: Implement text zooming in the lister

Posted: 2020-01-09, 22:14 UTC
by DrShark
ghisler(Author) wrote: 2020-01-09, 11:18 UTCThe problem is that the default fonts used (system fixed font) are bitmap fonts, and there aren't any good looking truetype or opentype fixed fonts I could set as a default instead.
Since RichEdit control used by Lister e.g. for RTF files supports text zooming, maybe it's worth letting user to use it also for other files, for example by introducing RichEditAdditionalTypes= similar to existing IviewAdditionalTypes=, or by adding RichEdit as additional view mode similar to new ExplorerPreview.

Re: Implement text zooming in the lister

Posted: 2024-10-09, 14:36 UTC
by Fla$her
13.08.24 Added: wincmd.ini [Lister] ZoomFont=1 controls font zoom with mouse wheel: 0=off, 1=Ctrl+Wheel, -1=Ctrl+Alt+Wheel. The unused one is used for fast scrolling (32/64)
12.08.24 Added: Lister: Ctrl+Mouse wheel now also zooms in all text modes. Fast scrolling has been changed to Ctrl+Alt+Mouse wheel (32/64)
12.08.24 Added: Lister: Ctrl+'+'/'-' now also zooms in all text modes (32/64)

Re: Implement text zooming in the lister

Posted: 2024-10-09, 14:39 UTC
by ghisler(Author)
Please note that this only works when using a Truetype or Opentype font, not when using a bitmap font like FIXEDSYS which is the default.

Re: Implement text zooming in the lister

Posted: 2024-10-09, 16:31 UTC
by Fla$her
It's bad that this happens in spurts, and not as smoothly as in text editors like AkelPad.

Re: Implement text zooming in the lister

Posted: 2024-10-09, 18:20 UTC
by wanderer
It's a welcome addition but when lister is closed and reopened, the "zoom" is remembered. OK with that, but there is no way to "reset" the font to its original size, you have to close and reopen the whole TC instance.

- Perhaps a new keystroke could be used for "reset to default zoom" ( CTRL + numpad '/' maybe? ).
- Another way could be to add a new "Reset zoom" menu item in the lister window (like the one at the right that shows in what percentage of the file the scrollbar is). It could be added at the left of the percentage and appear only when the zoom is something different than the default.
- Perhaps both of the above could be implemented?

Re: Implement text zooming in the lister

Posted: 2024-10-09, 19:21 UTC
by browny
wanderer wrote: 2024-10-09, 18:20 UTC - Perhaps a new keystroke could be used for "reset to default zoom" ( CTRL + numpad '/' maybe? ).
Ctrl+0 in Firefox and some other programs.

Re: Implement text zooming in the lister

Posted: 2024-10-10, 07:48 UTC
by ghisler(Author)
That's a good idea, I will check whether I can add Ctrl+0.

Re: Implement text zooming in the lister

Posted: 2024-10-10, 09:01 UTC
by browny
ghisler(Author) wrote: 2024-10-09, 14:39 UTC Please note that this only works when using a Truetype or Opentype font, not when using a bitmap font like FIXEDSYS which is the default.
The above mentioned akelpad editor can zoom even with Fixedsys font, though not very smoothly (it uses rich edit control).

Re: Implement text zooming in the lister

Posted: 2024-10-10, 11:53 UTC
by AntonyD
- Perhaps both of the above could be implemented?
+++Support++++

+ in a help we see:
ZoomFont=1 Controls font zoom with mouse wheel: 0=off, 1=Ctrl+Wheel, -1=Ctrl+Alt+Wheel. The other combination is used for fast scrolling
But WHAT exactly "other combination" means? Another digits? 2/3/7? -5/-8?
And about "fast scrolling" - Didn't it work before? Or has it started working differently now?
Why is this mode highlighted as a separate state?

Re: Implement text zooming in the lister

Posted: 2024-10-10, 14:03 UTC
by ghisler(Author)
The two combinations are Ctrl+Wheel and Ctrl+Alt+Wheel.
In older Total Commander versions, Ctrl+Wheel was scrolling page by page. This is now changed to Ctrl+Alt+Wheel.
With ZoomFont=-1, the two are reversed: Ctrl+Wheel again scrolls page by page, and Ctrl+Alt+Wheel zooms the font.
I changed the default for consistency reasons, because Ctrl+Wheel already zooms images.

Re: Implement text zooming in the lister

Posted: 2024-10-10, 14:32 UTC
by petermad
I would like if Lister would show the zoom fator - either in the title bar or in a tooltip like in the thumbnail view.

Re: Implement text zooming in the lister

Posted: 2024-10-10, 15:52 UTC
by wanderer
petermad wrote: 2024-10-10, 14:32 UTC I would like if Lister would show the zoom fator - either in the title bar or in a tooltip like in the thumbnail view.
wanderer wrote: 2024-10-09, 18:20 UTC- Another way could be to add a new "Reset zoom" menu item in the lister window (like the one at the right that shows in what percentage of the file the scrollbar is). It could be added at the left of the percentage and appear only when the zoom is something different than the default.
That's one of the reasons i proposed this. Some programs (i.e. browsers) show the zoom factor and when you click on it, you are returned to 100%. If implemented like this in TC too (as a menu item), it would certainly feel familiar.

Re: Implement text zooming in the lister

Posted: 2024-10-17, 13:42 UTC
by browny
ghisler(Author) wrote: 2024-10-10, 07:48 UTC That's a good idea, I will check whether I can add Ctrl+0.
This used to work for numeric pad 0 too, but TC beta 2 ignores the key.

Additionally, it might be nice to see the image size in the caption (similar to IrfanView, though it shows zoomed size in the caption and original in status bar).