I have just added two sort functions to one of my editors, TopGun. I removed two cursors because they had the potential to make the operation unreliable if the editor was left for a long time without entering text into it. The two sort functions are on the "Selection" menu and they are useful for either sorting lists of words or sentences in either ascending or descending order.
I have also tested the ballon tooltip code posted by "anon" which seems to work fine.
If anyone has a little time, I would appreciate some testing to make sure its working correctly. It seems to be here so far.
I have removed the first attachment and the new one is posted below.
I've done a few test with some random text, with numbers, spaces, identical lines, etc.
All in all it works like it should :U
I have tested the sort functions... and I get a crash when doing this sequence:
1)Select All
2)Sort Ascending
3)Sort Descending
It could be because the file is very big :D
Here is the offending file (Solar_OS 6Mb listing)
www.oby.ro/system32.zip
Bogdan,
Thanks, I can duplicate the problem, now I have to go look for why its happening. :P
I think I have it tracked down, the output buffer to be written back to the edit control was being written past its end which made it GPF. Increased the buffer size and it handles the big file of Bogdan's OK sorted with both algos back and forth.
[attachment deleted by admin]
The program looks very nice. Also the sort function worked well (and fast)
on a 2.2 meg word list I have. Nice to hear some people are using some of
the snippets I occasionally post.
Although it took perhaps 20 minutes to do all of this, I was able to load a 100MB file, do a select all, a sort descending, a sort ascending, and a save as without problems, and afterwards FC /B reported no differences between the original and the new. Doing the same with a 20MB file was no problem, with the load, select all, and store as requiring only a few seconds each, and with the sorts requiring perhaps 10 seconds each.
[attachment deleted by admin]
Works just fine, AMD XP 2500+, XP SP2. :toothy