java.lang.Object
it.polimi.ingsw.view.cli.console.graphics.components.Rectangle
it.polimi.ingsw.view.cli.console.graphics.components.WindowItem
it.polimi.ingsw.view.cli.console.graphics.LoggerPane
public class LoggerPane extends WindowItem
-
Field Summary
Fields inherited from class it.polimi.ingsw.view.cli.console.graphics.components.WindowItem
activeItems, id, parent, passiveItems -
Constructor Summary
Constructors Constructor Description LoggerPane(WindowItem parent, CursorPosition initCoord, int width, int height, java.lang.String id)Custom constructor -
Method Summary
Modifier and Type Method Description voidaddLogLine(java.lang.String line, boolean urgent)Adds a new line to the logger, eventually scrolling and deleting the previous onesprotected voiddrawBorders()Does nothing, because the alternative color scheme is used to show urgent messagesMethods inherited from class it.polimi.ingsw.view.cli.console.graphics.components.WindowItem
addActiveItem, addPassiveItem, currentActiveItem, drawShadows, getCli, getID, getParent, hideShadows, maxStringLength, nextActiveItem, previousActiveItem, remove, showMethods inherited from class it.polimi.ingsw.view.cli.console.graphics.components.Rectangle
drawBackground, findCenter, getBackgroundColor, getColor, getHeight, getInitCoord, getTextColor, getWidth, hideBorders, loadPropertiesFile
-
Constructor Details
-
LoggerPane
public LoggerPane(WindowItem parent, CursorPosition initCoord, int width, int height, java.lang.String id)Custom constructorCreates an item using custom settings
The initial coordinates are relative to the object's parent- Parameters:
parent- the Dialog containing thisinitCoord- the item coordinateswidth- the object widthheight- the object heightid- the object id
-
-
Method Details
-
addLogLine
public void addLogLine(java.lang.String line, boolean urgent)Adds a new line to the logger, eventually scrolling and deleting the previous ones- Parameters:
line- the line to add (can be split)urgent- alters the log text if true
-
drawBorders
protected void drawBorders()Does nothing, because the alternative color scheme is used to show urgent messages- Overrides:
drawBordersin classRectangle
-