Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, making threats, or asking for money, are
spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the
password reset link.
Due to spam on this forum, all posts now need moderator approval.
Entire forum
➜ MUSHclient
➜ Bug reports
➜ TextRectangle bug
It is now over 60 days since the last post. This thread is closed.
Refresh page
| Posted by
| Worstje
Netherlands (899 posts) Bio
|
| Date
| Sat 16 Aug 2008 04:31 AM (UTC) |
| Message
| A tiny but annoying bug I just found...
If you specify a negative parameter for bottom (so it will count from the bottom) and have the distance between the actual window and the output area as being less than the height of the font, it will go wonky when using pageup/pagedown with scrolling down: it never wants to fully scroll down (thumb on scrollbar stays one pixel above the fully scrolled down position) and the MORE indicator always stays on.
Atleast, I think it has to do with fontheight, since the bug happens for me around sizes below 23 pixels height... which approximates my fontheight. | | Top |
|
| Posted by
| Worstje
Netherlands (899 posts) Bio
|
| Date
| Reply #1 on Sat 16 Aug 2008 04:33 AM (UTC) Amended on Sat 16 Aug 2008 04:35 AM (UTC) by Worstje
|
| Message
| Figures, and now I can't reproduce it anymore all of a sudden.
Probably the amount of data in the buffer also factors into this somewhere.
/me is off to test a bit more.
Edit: Oops, accidentally posted a second time rather than edited. Anyhow, it's confirmed. Clearing my outputbuffer made the bug show again. It's unlikely to show for sufficiently large outputbuffers - my outputbuffer was +- 300 lines when it stopped happening, but it is annoying none the less. =) | | Top |
|
| Posted by
| Nick Gammon
Australia (23,173 posts) Bio
Forum Administrator |
| Date
| Reply #2 on Mon 18 Aug 2008 08:49 PM (UTC) |
| Message
| It doesn't surprise me, I am surprised not more things went wrong, after all those changes for the TextRectangle.
I'll try to find and fix it for the next version. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | | Top |
|
| Posted by
| Nick Gammon
Australia (23,173 posts) Bio
Forum Administrator |
| Date
| Reply #3 on Mon 18 Aug 2008 09:34 PM (UTC) Amended on Mon 18 Aug 2008 09:36 PM (UTC) by Nick Gammon
|
| Message
| | I can't reproduce it - can you be specific about the exact font you are using and the exact height of the text rectangle? Or, the exact script call? Maybe the width of the border affects it. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | | Top |
|
| Posted by
| Worstje
Netherlands (899 posts) Bio
|
| Date
| Reply #4 on Wed 20 Aug 2008 12:12 PM (UTC) |
| Message
| I am using Monaco, 9pt as font. The code I used was this (or atleast I think so - I don't really recall playing with it much more than that (just done with 48 hours of travel and my mind is a blank atm.)
TextRectangle(150 + 4, 0, 0, -24, 2, ColourNameToRGB ("red"), 1, ColourNameToRGB ("black"), 0)
| | Top |
|
| Posted by
| Nick Gammon
Australia (23,173 posts) Bio
Forum Administrator |
| Date
| Reply #5 on Wed 20 Aug 2008 09:28 PM (UTC) |
| Message
| | Hmm, I don't seem to have Monaco 9 pt, but using Dina 9 pt and the code you gave above, doesn't cause any problems for me. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | | Top |
|
| Posted by
| Worstje
Netherlands (899 posts) Bio
|
| Date
| Reply #6 on Thu 21 Aug 2008 08:26 AM (UTC) |
| Message
| I got the font quite some time ago from this site: http://www.lowing.org/fonts/. I doubt the font changed though.
If you can't get it working after that, I'll see if I can recreate the bug again somehow. | | Top |
|
| Posted by
| Worstje
Netherlands (899 posts) Bio
|
| Date
| Reply #7 on Mon 25 Aug 2008 02:54 PM (UTC) Amended on Mon 25 Aug 2008 03:02 PM (UTC) by Worstje
|
| Message
| I just managed to reproduce it... with TextRectangle() being called to cover the entire window, and while having plenty of scrollback. I'm flabbergasted. Basic way to trigger it for me so far seems to consist of:
- Have a TextRectangle which doesn't reach the bottom of the output window.
- Get some content in.
- Change the TextRectangle so that the bottom edge of the TextRectangle and the bottom edge of the output window becomes smaller. I do this atm by resetting the TextRectangle to the default.
- Notice a gap of space below all the output so far.
- Now click the bottom arrow of the scrollbar - it will jump UP and make the actual last line go at the bottom of the output area, hiding the gap of space. The MORE INDICATOR is on.
- Now grab the thumb of the vertical scrollbar, drag it up a bit and make the output window scroll, and now drag it all the way back down - and the gap is back from it's hidey spot.
- Any new input apparently recalculates the size of the internal buffer, so one more line (no matter how small compared to the gap) fixes it. My guess is that the code to calculate the visible area of the output calculates until the bottom of the output window, rather than the TextRectangle() - ending up with a value that isn't correct and messes up the MORE indicator and the scrollbar.
Screenshot: hxxp://qs.merseine.nu/images/textrectangle_gap.png. Replace the hxxp by http. =)
Also, I found something else that is affected by TextRectangle. The Find function fails to actually draw the selection on the found word when:
- the TextRectangle() does NOT cover the full output window
- AND the found text can be seen WITHOUT scrolling.
It seems a redraw can be focused by clicking on the scrollbar. Clicking in the outputwindow outside of the TextRectangle doesn't help, however.
Last.. which may or may not be a bug. It might have been there already in the past prior to TextRectangle(), but the fact I can make nice borders makes it show up far more than it used to in the past. Suppose I select a few lines of text, then use CTRL+UP to scroll up. Now I make the selection disappear out of view, with the last unselected line now being the bottom visible one. You'll notice a 1 pixel border at the bottom of the textrectangle, just below the last unselected line. You can also notice it by using background colors in notes and scrolling up like that.
What can I say... I'm OCD and notice little things. >_> | | Top |
|
| Posted by
| Nick Gammon
Australia (23,173 posts) Bio
Forum Administrator |
| Date
| Reply #8 on Mon 25 Aug 2008 11:10 PM (UTC) |
| Message
| | You forgot to mention that if you set a bookmark, and then go to that bookmark, and it is on the same screen, it also is not highlighted properly. :) |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | | Top |
|
| Posted by
| Worstje
Netherlands (899 posts) Bio
|
| Date
| Reply #9 on Mon 25 Aug 2008 11:14 PM (UTC) |
| Message
| | I never even use bookmarks. I thought I was already being a good tester, and here I get called out on doing an inadequate job. *sniffle* | | Top |
|
| Posted by
| Nick Gammon
Australia (23,173 posts) Bio
Forum Administrator |
| Date
| Reply #10 on Mon 25 Aug 2008 11:20 PM (UTC) |
| Message
| See the release notes, points 21 to 24. All the things you mentioned are fixed.
The stuff about the 1 pixel border is, I think, because you have 1 pixel text offset set in the output configuration. It was in fact drawing two lines too many, thus you were seeing the start of the next line, including the inverted selection (which is normally in the output colour and thus not visible). |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | | Top |
|
| Posted by
| Nick Gammon
Australia (23,173 posts) Bio
Forum Administrator |
| Date
| Reply #11 on Mon 25 Aug 2008 11:21 PM (UTC) |
| Message
|
Quote:
I get called out on doing an inadequate job ...
Your report alerted me to the possibility that other things that invalidate the selection might be wrong, which it was. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | | Top |
|
| Posted by
| Worstje
Netherlands (899 posts) Bio
|
| Date
| Reply #12 on Tue 26 Aug 2008 12:30 AM (UTC) |
| Message
| | Aww, sometimes a textmedium can't convey humor too well. I'll add a smiley or two next time. :) | | Top |
|
| Posted by
| Nick Gammon
Australia (23,173 posts) Bio
Forum Administrator |
| Date
| Reply #13 on Tue 26 Aug 2008 12:49 AM (UTC) |
| Message
| I got it - and I certainly appreciate the detailed testing. :-)
:O |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | | Top |
|
The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).
To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.
29,715 views.
It is now over 60 days since the last post. This thread is closed.
Refresh page
top