mirror of
https://github.com/SquidDev-CC/CC-Tweaked
synced 2025-01-27 17:34:48 +00:00
Render terminal cursor in a less awkward way
The previous way seemed weird enough to seem to have had a purpose, but I can't tell. Revert this if it turns out that there was.
This commit is contained in:
parent
7e71045c7b
commit
4e3def39e0
@ -407,23 +407,22 @@ public class WidgetTerminal extends Widget
|
|||||||
TextBuffer colour = terminal.getTextColourLine( line );
|
TextBuffer colour = terminal.getTextColourLine( line );
|
||||||
TextBuffer backgroundColour = terminal.getBackgroundColourLine( line );
|
TextBuffer backgroundColour = terminal.getBackgroundColourLine( line );
|
||||||
fontRenderer.drawString( text, x, y, colour, backgroundColour, m_leftMargin, m_rightMargin, greyscale );
|
fontRenderer.drawString( text, x, y, colour, backgroundColour, m_leftMargin, m_rightMargin, greyscale );
|
||||||
if( tblink && ty == line )
|
y += FixedWidthFontRenderer.FONT_HEIGHT;
|
||||||
{
|
}
|
||||||
if( tx >= 0 && tx < tw )
|
|
||||||
{
|
if( tblink )
|
||||||
TextBuffer cursor = new TextBuffer( '_', 1 );
|
{
|
||||||
TextBuffer cursorColour = new TextBuffer( "0123456789abcdef".charAt( terminal.getTextColour() ), 1 );
|
TextBuffer cursor = new TextBuffer( '_', 1 );
|
||||||
fontRenderer.drawString(
|
TextBuffer cursorColour = new TextBuffer( "0123456789abcdef".charAt( terminal.getTextColour() ), 1 );
|
||||||
cursor,
|
|
||||||
x + FixedWidthFontRenderer.FONT_WIDTH * tx,
|
fontRenderer.drawString(
|
||||||
y,
|
cursor,
|
||||||
cursorColour, null,
|
x + FixedWidthFontRenderer.FONT_WIDTH * tx,
|
||||||
0, 0,
|
startY + m_topMargin + FixedWidthFontRenderer.FONT_HEIGHT * ty,
|
||||||
greyscale
|
cursorColour, null,
|
||||||
);
|
0, 0,
|
||||||
}
|
greyscale
|
||||||
}
|
);
|
||||||
y = y + FixedWidthFontRenderer.FONT_HEIGHT;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user