Difference between revisions of "Term.clearLine"

From ComputerCraft Wiki
Jump to: navigation, search
(Undo revision 1934 by 91.121.27.33 (talk))
m (Expanded)
 
(2 intermediate revisions by 2 users not shown)
Line 2: Line 2:
 
{{Function
 
{{Function
 
|name=term.clearLine
 
|name=term.clearLine
|args=none
+
|returns=None
|returns=none
+
 
|api=term
 
|api=term
 
|addon=ComputerCraft
 
|addon=ComputerCraft
|desc=Clears the line that the cursor is currently on.
+
|desc=Clears the line that the cursor is currently on. That line is then filled with the color set by [[term.setBackgroundColor]] (''only if'' computer supports that color)
 
|examples=
 
|examples=
 
{{Example
 
{{Example
|desc=Clears the line that the cursor is currently on.
+
|desc=Clears the first line on the computer screen.
|code=term.clearLine()
+
|code= [[term.setCursorPos]](1, 1)
 +
'''term.clearLine()'''
 
}}
 
}}
 
}}
 
}}
 +
 +
[[Category:API_Functions]]

Latest revision as of 17:18, 10 April 2014


Grid Redstone.png  Function term.clearLine
Clears the line that the cursor is currently on. That line is then filled with the color set by term.setBackgroundColor (only if computer supports that color)
Syntax term.clearLine()
Returns None
Part of ComputerCraft
API term

Examples

Grid paper.png  Example
Clears the first line on the computer screen.
Code
term.setCursorPos(1, 1)
term.clearLine()