@Mr. Ghisler Slider in Lister
Moderators: Hacker, petermad, Stefan2, white
@Mr. Ghisler Slider in Lister
Dear Mr. Ghisler
Is it possible to make the slider on the right side of the window in LISTER (F3)
proportional to the lenght of the text.
greetings janv
Is it possible to make the slider on the right side of the window in LISTER (F3)
proportional to the lenght of the text.
greetings janv
(#11407) Enjoy my English
- SanskritFritz
- Power Member
- Posts: 3693
- Joined: 2003-07-24, 09:25 UTC
- Location: Budapest, Hungary
I'm not Mr Ghisler, but I'd like to add my comment 
I dont think is will be possible, and I actually hope it will not be implemented, because to determine the length of the slider you have to read the whole file. One of Listers greatest stregths is speed, that is achieved by reading only a small part of the file.

I dont think is will be possible, and I actually hope it will not be implemented, because to determine the length of the slider you have to read the whole file. One of Listers greatest stregths is speed, that is achieved by reading only a small part of the file.
I switched to Linux, bye and thanks for all the fish!
I would think some sort of approximate proportional thumbsize could be calculated based on the filesize (available from the operating system), the size of the lister window, and whether wrap is on or not ...at least for text-based files... without having to read the full file.
Licensed, Mouse-Centric, moving (slowly) toward Touch-centric
- SanskritFritz
- Power Member
- Posts: 3693
- Joined: 2003-07-24, 09:25 UTC
- Location: Budapest, Hungary
That is true, that is the percentage counter in the upper right corner for. But for calculating the slider proportionally, you have to count the lines in the file, thus reading the file. An approximate proportion could be misleading i guess, although i have to admit in most cases it would be correct, as most text files have approximately the same line length.JohnFredC wrote:I would think some sort of approximate proportional thumbsize could be calculated based on the filesize (available from the operating system), the size of the lister window, and whether wrap is on or not ...at least for text-based files... without having to read the full file.
I switched to Linux, bye and thanks for all the fish!
"rustic work" scale---
2JohnFredC
Hello John!
¤ What do you think about a numbered scale on a side of the window? Like that exists in some text-editors, but simplified?
• I mean: having a step of 5...10 rows?
A big benefit'ld be that such a scale could work when displaying *.RTF files (?) since the % counter doesn't work at this for a lot of versions?
I don't know what it demandes at programming, but it seems nice...
Kind regards,
Clo

¤ What do you think about a numbered scale on a side of the window? Like that exists in some text-editors, but simplified?
• I mean: having a step of 5...10 rows?



Clo
#31505 Traducteur Français de T•C French translator Aide en Français Tutoriels Français English Tutorials
- SanskritFritz
- Power Member
- Posts: 3693
- Joined: 2003-07-24, 09:25 UTC
- Location: Budapest, Hungary
I think in average they doSource files (Java, C/C++) usually don't

What yould really fake a scrollbar proportion is a file with really short lines at the beginning, and then lines with 1000 or so characters at the end.
I switched to Linux, bye and thanks for all the fish!
The real issue is about how much accuracy is really required for the thumb size.
I think probably not much.
Perhaps a scrollbar thumbsize could be designated depending on filesize. Small files would have larger thumbs, large files smaller ones, based on a simple lookup table.
Inaccurate, yes, but perhaps not significantly so?
I think probably not much.
Perhaps a scrollbar thumbsize could be designated depending on filesize. Small files would have larger thumbs, large files smaller ones, based on a simple lookup table.
Inaccurate, yes, but perhaps not significantly so?
Licensed, Mouse-Centric, moving (slowly) toward Touch-centric
- SanskritFritz
- Power Member
- Posts: 3693
- Joined: 2003-07-24, 09:25 UTC
- Location: Budapest, Hungary
I agree, that could be in most cases informative. Now lets wait to Mr GhislerPerhaps a scrollbar thumbsize could be designated depending on filesize. Small files would have larger thumbs, large files smaller ones, based on a simple lookup table.

I switched to Linux, bye and thanks for all the fish!
Misunderstanding...
2SanskritFritz
Hi!
¤ I meant the line number, not the average of the file.
kind regards,
Clo
Hi!
¤ I meant the line number, not the average of the file.

Clo
#31505 Traducteur Français de T•C French translator Aide en Français Tutoriels Français English Tutorials
- SanskritFritz
- Power Member
- Posts: 3693
- Joined: 2003-07-24, 09:25 UTC
- Location: Budapest, Hungary
2Clo
Lets make this straight: to know how many bytes were read and how many bytes are left to read is possible without reading the whole file. But knowing how many lines are left to read in the file, is only possible if one actually reads the file.I meant the line number, not the average of the file.
I switched to Linux, bye and thanks for all the fish!
- ghisler(Author)
- Site Admin
- Posts: 50479
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Indeed the slider isn't proportional because the number of lines could only be determined by reading the entire file. Currently the slider goes from 0..1000, which is sort of a percentage (permil) value for the location to which it scrolls.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com