File tree 5 files changed +61
-1
lines changed
5 files changed +61
-1
lines changed Original file line number Diff line number Diff line change @@ -43,3 +43,11 @@ function term.popColor()
43
43
term .setTextColor (color )
44
44
end
45
45
end
46
+
47
+ function term .clearToEndOfLine ()
48
+ io.write (" \027 [K" )
49
+ end
50
+
51
+ function term .moveLeft (n )
52
+ io.write (string.format (" \027 [%sD" , n ))
53
+ end
Original file line number Diff line number Diff line change 128
128
* [ term.setTextColor] ( term.setTextColor.md )
129
129
* [ term.pushColor] ( term.pushColor.md )
130
130
* [ term.popColor] ( term.popColor.md )
131
+ * [ term.clearToEndOfLine] ( term.clearToEndOfLine.md )
132
+ * [ term.moveLeft] ( term.moveLeft.md )
131
133
132
134
### Zip
133
135
Original file line number Diff line number Diff line change
1
+ Clears the console from the cursor location to the end of the line.
2
+
3
+ ``` lua
4
+ term .clearToEndOfLine ()
5
+ ```
6
+
7
+ ### Parameters ###
8
+ None
9
+
10
+ ### Return Value ###
11
+ None
12
+
13
+ ### Example ###
14
+ ``` lua
15
+ term .clearToEndOfLine ()
16
+ ```
17
+
18
+ ### See Also ###
19
+ * [ term.moveLeft] ( term.moveLeft.md )
20
+
21
+ ### Availability ###
22
+
23
+ Premake 5.0.0 beta 3 or later.
24
+
Original file line number Diff line number Diff line change
1
+ Moves the console cursor left by a number of columns.
2
+
3
+ ``` lua
4
+ term .moveLeft (columns )
5
+ ```
6
+
7
+ ### Parameters ###
8
+ ` columns ` is the number of columns to move left.
9
+
10
+ ### Return Value ###
11
+ None
12
+
13
+ ### Example ###
14
+ ``` lua
15
+ term .moveLeft (2 )
16
+ ```
17
+
18
+ ### See Also ###
19
+ * [ term.clearToEndOfLine] ( term.clearToEndOfLine.md )
20
+
21
+ ### Availability ###
22
+
23
+ Premake 5.0.0 beta 3 or later.
24
+
Original file line number Diff line number Diff line change @@ -491,9 +491,11 @@ module.exports = {
491
491
label : 'term' ,
492
492
items : [
493
493
'term.getTextColor' ,
494
+ 'term.setTextColor' ,
494
495
'term.popColor' ,
495
496
'term.pushColor' ,
496
- 'term.setTextColor'
497
+ 'term.clearToEndOfLine' ,
498
+ 'term.moveLeft'
497
499
]
498
500
} ,
499
501
{
You can’t perform that action at this time.
0 commit comments