Lister showing line numbers
Moderators: Hacker, petermad, Stefan2, white
Lister showing line numbers
It would be a great help if the Lister (activated by F3) could show line numbers to the left !
- SanskritFritz
- Power Member
- Posts: 3693
- Joined: 2003-07-24, 09:25 UTC
- Location: Budapest, Hungary
- ghisler(Author)
- Site Admin
- Posts: 50386
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
That's not the problem! The problem is that in order to have line numbers, lister would have to read the entire file from the beginning to the current position. Currently it reads only a few kbytes around the current position, which makes browsing files of ANY size really fast. If you need line numbers, use hpg_ed or synus/synplus, they are very good foir this, and even support syntax highlighting.So, ghisler could implement it if he wanted to but as he doesn't want to
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
I know that, thank you:That's not the problem! The problem is that in order to have line numbers, lister would have to read the entire file from the beginning to the current position. Currently it reads only a few kbytes around the current position, which makes browsing files of ANY size really fast.
http://www.ghisler.ch/board/viewtopic.php?p=34776#34776
SankritFritz' link points to a thread with a statement from you as well, there is no need to repeat the obvious.
They are good for small files, not huge files.If you need line numbers, use hpg_ed or synus/synplus, they are very good foir this, and even support syntax highlighting.
I mean, why do you think I propose FILE VIEWERS instead of editors? I could as well tell anyone who likes to view a file to use Notepad instead of the lister.
Icfu
Last edited by icfu on 2006-02-09, 19:57 UTC, edited 1 time in total.
This account is for sale
- ghisler(Author)
- Site Admin
- Posts: 50386
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
That's exactly the problem which you would also see when lister supported line numbers directly!They are good for small files, not huge files.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
I don't have that problem with ListXP, sorry, but I do have a problem with giving redundant information half a dozen times.That's exactly the problem which you would also see when lister supported line numbers directly!
Everything is LINKED, please follow the links if you are interested. Try out ListXP so you know what I am talking about, thanks.
http://www.ghisler.ch/board/viewtopic.php?p=34887#34887
IcfuSo, all we need is two checkboxes:
-show line numbers in binary mode
-show line numbers in text mode (Attention! File has to be read and will slow down viewing!)
Furthermore TC lister has to read the whole file anyway when using the search, so why not count the CR/LFs at the same time?
ListXP shows that it works even in 500MB files. The file can be viewed and searched already WHILE building the index and summing up the CR/LFs so there is NOT ONE negative aspect for the user.
This account is for sale
- ghisler(Author)
- Site Admin
- Posts: 50386
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
I don't know ListXP myself, but try this: Open a huge log file (a few 10-100 MB) with it and press End or Ctrl+End -> you will have to wait until the entire file has been loaded.I don't have that problem with ListXP, sorry, but I do have a problem with giving redundant information half a dozen times.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
Ok, one last try, I repeat it another time:Open a huge log file (a few 10-100 MB) with it and press End or Ctrl+End -> you will have to wait until the entire file has been loaded.
1. ListXP is a viewer, just like the lister. It only displays a small part of a given file at a given time. It does NOT load the entire file but only the part needed.
2. ListXP INDEXES the file and this index is written to disk (if you activate that), so the next time the file is opened it displays the line numbers without *any* waiting time.
3. I proposed to make it OPTIONAL with checkboxes or whatever you can imagine. It can also be a button named "INDEX FILE NOW" so nothing would change in normal lister behaviour but ONLY when user NEEDS line numbering.
Icfu
This account is for sale
- majkinetor !
- Power Member
- Posts: 1580
- Joined: 2006-01-18, 07:56 UTC
- Contact:
Get used to it....I don't have that problem with ListXP, sorry, but I do have a problem with giving redundant information half a dozen times.
What do you think, how many times Sans repeated "U can use AutoHotKey for that" sentence ?
2MPS
Please skip this kind of requests... Just waste of time:
99% of addons like this will surely be optional.MPS wrote:how about having that line-number feature as an option? switched off by default,
Well... why do we need Ghisler for this ? I mean, request was to update lister with something fundamental (line numbers) not to write separate pluginWhat about a creating a Lister plugin based on ListXP?
Habemus majkam!
@majki:
@Lefteous:
I am in favour of workarounds when applicable but not in this case I think. Line numbering is, after having the cursor in TC 7, the next logical step the internal lister should support, for me at least.
Icfu
Nope, I will NEVER get used to that. I expect that people who comment in a thread take some time to READ before answering because I am investing some time for posting AS WELL.Get used to it....
@Lefteous:
Is that possible? How can external applications be integrated in the lister?2icfu
What about a creating a Lister plugin based on ListXP?
I am in favour of workarounds when applicable but not in this case I think. Line numbering is, after having the cursor in TC 7, the next logical step the internal lister should support, for me at least.
Icfu
This account is for sale