This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
SuicidalSTDz's profile picture

Doubled last character in Interactive Lua Prompt

Started by SuicidalSTDz, 04 May 2013 - 02:11 PM
SuicidalSTDz #1
Posted 04 May 2013 - 04:11 PM
Enter text until it scrolls the line one space to the right. Now, scroll to the beginning and then scroll to the end. The last character doubles.

After doing this, if you press the down arrow key the doubled character will stay.
Shnupbups #2
Posted 04 May 2013 - 05:52 PM
Yeah, I've had this before. Was too lazy to report it. Also, the letter is a ghost, doesn't affect the code.
SuicidalSTDz #3
Posted 04 May 2013 - 06:05 PM
Yeah, I know. But, it is still a bug :P/>
Shnupbups #4
Posted 04 May 2013 - 07:15 PM
Yeah, I know. But, it is still a bug :P/>
I know that as well. I was just giving more information on the subject, stating it is just a visual bug.
remiX #5
Posted 04 May 2013 - 07:57 PM
Yeah, I've had this before. Was too lazy to report it.

Exactly the same here xD
Engineer #6
Posted 04 May 2013 - 09:25 PM
That 'bug' has been there for ages :P/>
SuicidalSTDz #7
Posted 04 May 2013 - 09:34 PM
If it has been there for ages, why has it not been fixed yet? :P/>
Smiley43210 #8
Posted 05 May 2013 - 01:41 AM
This? http://www.computercraft.info/forums2/index.php?/topic/12490-at-least-cc-14smpsspscrolling-bug-with-function-read/
LBPHacker #9
Posted 06 May 2013 - 11:03 AM
That. Temporary solution:
SpoilerGo to bios.lua, find read(), and insert a whitespace into every term.write (two of them maybe?).
Sorry, no line numbers, but what is Ctrl+F for?
Sammich Lord #10
Posted 06 May 2013 - 11:10 AM
That. Temporary solution:
SpoilerGo to bios.lua, find read(), and insert a whitespace into every term.write (two of them maybe?).
Sorry, no line numbers, but what is Ctrl+F for?
CTRL+F is the shortcut for find. It works in most web browsers and text editors.
LBPHacker #11
Posted 06 May 2013 - 11:45 AM
CTRL+F is the shortcut for find. It works in most web browsers and text editors.
Umm… Yeah, I know that. Said it because I gave no line numbers (since they're changing with every new version), but you can find "function read" with Ctrl+F…
Sammich Lord #12
Posted 06 May 2013 - 12:01 PM
CTRL+F is the shortcut for find. It works in most web browsers and text editors.
Umm… Yeah, I know that. Said it because I gave no line numbers (since they're changing with every new version), but you can find "function read" with Ctrl+F…
You added a question mark to it and it was worded like a question so I assumed you were wondering what CTRL+F was.
PixelToast #13
Posted 06 May 2013 - 12:41 PM
That. Temporary solution:
SpoilerGo to bios.lua, find read(), and insert a whitespace into every term.write (two of them maybe?).
Sorry, no line numbers, but what is Ctrl+F for?
http://www.computerc...post__p__114606
:P/>
anyway, here is the new redraw function:

local function redraw( _sCustomReplaceChar )
  local nScroll = 0
  if sx + nPos >= w then
   nScroll = (sx + nPos) - w
  end
  
  term.setCursorPos( sx, sy )
  local sReplace = _sCustomReplaceChar or _sReplaceChar
  if sReplace then
   term.write( string.rep(sReplace, string.len(sLine) - nScroll).." ")
  else
   term.write( string.sub( sLine, nScroll + 1 ).." ")
  end
  term.setCursorPos( sx + nPos - nScroll, sy )
end
around line 228
Smiley43210 #14
Posted 07 May 2013 - 06:53 PM
CTRL+F is the shortcut for find. It works in most web browsers and text editors.
Umm… Yeah, I know that. Said it because I gave no line numbers (since they're changing with every new version), but you can find "function read" with Ctrl+F…
You added a question mark to it and it was worded like a question so I assumed you were wondering what CTRL+F was.
He was saying it in an implicative way.
superaxander #15
Posted 08 May 2013 - 01:43 AM
When I see this bug I always think I made typo. Luckily it's a ghost character in the way that it will not be passed to the function