style: formatting
This commit is contained in:
@@ -25,7 +25,7 @@ modem.open(HOST_CHANNEL)
|
|||||||
]]
|
]]
|
||||||
function wrapText(text, maxWidth)
|
function wrapText(text, maxWidth)
|
||||||
if not text then return {} end
|
if not text then return {} end
|
||||||
if maxWidth <= 0 then return {text} end
|
if maxWidth <= 0 then return { text } end
|
||||||
|
|
||||||
local lines = {}
|
local lines = {}
|
||||||
local currentLine = ""
|
local currentLine = ""
|
||||||
@@ -68,7 +68,6 @@ function wrapText(text, maxWidth)
|
|||||||
return lines
|
return lines
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
--[[
|
--[[
|
||||||
logging
|
logging
|
||||||
]]
|
]]
|
||||||
@@ -279,7 +278,7 @@ function drawLogs(x0, y0, x1, y1)
|
|||||||
messageFG = prevColourFg
|
messageFG = prevColourFg
|
||||||
end
|
end
|
||||||
|
|
||||||
for lineIdx=#wrappedMessage,1, -1 do
|
for lineIdx = #wrappedMessage, 1, -1 do
|
||||||
if drawnLines > h then break end
|
if drawnLines > h then break end
|
||||||
|
|
||||||
local line = wrappedMessage[lineIdx]
|
local line = wrappedMessage[lineIdx]
|
||||||
|
|||||||
Reference in New Issue
Block a user