No scrollbar for spaces.

Questions & Answers

Moderators: fgagnon, nikos, Site Mods

Post Reply
User avatar
Medlir
Member
Member
Posts: 9
Joined: 2002 Oct 07, 00:06
Location: Olivet, MI, USA
Contact:

No scrollbar for spaces.

Post by Medlir »

I'm not sure if this is a bug or just odd/interesting behavior. :P

I was doing some programming myself, and having a problem with a textbox filling with spaces in an Open dialog, and I was curious how many it was stuffing in there... so I copied them out, and pasted the line into Editor^2 (v2.0.0.7 UC) to see the character (column) count and that's when I noticed... a line full of spaces, even if it goes off the screen, doesn't cause Editor^2 to show the bottom left-right scrollbar. This is with a monospaced font by the way (Courier, 9, Regular) and at 1024x768 screen res where column 128 is the actual right edge of the screen with the window maximized.

A line of 256 spaces... scrollbar absent.
A line of 256 W's... scrollbar present.

The cursor goes off the visible screen however. If you then type any other character at the end of the spaces, the scrollbar appears and the view jumps out to the cursor location.

Also, if you have Word Wrap on, it doesn't wrap spaces, but it does make the cursor visible on the far-right edge of the screen no matter how far off the screen you should be.

However, if you type out (Copy/Paste, whatever) a whopping 3072 spaces with Word Wrap off then the scrollbar appears and the view jumps way out to the end where the cursor is.

But then, if you type out 65536 space with Word Wrap on, it goes back to saying it's in column 1 of line 1 even though it's really at 65537. If you continue it'll reach 65536 again and go over it the second time. If you continue in this vein you'll eventually cause a silent crash. If you type any letters after that, they get dumped to line 2 no matter what. If you go back to line 1, and hit End, it reports as being at the end of line 2 instead.

It doesn't cause me any problems... and I'm not sure why anyone would have a text file full of spaces under normal circumstances, and if all they're doing is typing spaces, they deserve to have it close on them. :P

I just found it curious that a space character doesn't register on the scrollbar unless there's 3072 on a line and word wrap is off, and with word wrap on, it doesn't split and wrap the lines at reasonable limits like it would with other characters.

Any word on future versions of Editor^2? Back in October you had mentioned a patch for the stack corruption on Ctrl+A issue, but that you hadn't released it in lieu of a new full version.

Keep up the good work. :)
moof!
User avatar
nikos
Site Admin
Site Admin
Posts: 15806
Joined: 2002 Feb 07, 15:57
Location: UK
Contact:

Post by nikos »

this is quirky indeed, but it's all down to M$ richedit v2/3 control

i have been putting off the [Ctrl+A] patch since I want to introduce regular expressions in ed2, but as this may take some while, I've released 2.0.0.8 unicode, which is now available from the website, correcting this bug
User avatar
Medlir
Member
Member
Posts: 9
Joined: 2002 Oct 07, 00:06
Location: Olivet, MI, USA
Contact:

Post by Medlir »

Excellent, thank you. :)

It's also 500K smaller than *.7 which is nice also. :D
moof!
Post Reply