MCPcopy Create free account
hub / github.com/AppleWin/AppleWin / DrawConsoleCursor

Function DrawConsoleCursor

source/Debugger/Debugger_Display.cpp:1286–1305  ·  view source on GitHub ↗

===========================================================================

Source from the content-addressed store, hash-verified

1284
1285//===========================================================================
1286void DrawConsoleCursor ()
1287{
1288 DebuggerSetColorFG( DebuggerGetColor( FG_CONSOLE_INPUT ));
1289 DebuggerSetColorBG( DebuggerGetColor( BG_CONSOLE_INPUT ));
1290
1291 int nWidth = g_aFontConfig[ FONT_CONSOLE ]._nFontWidthAvg;
1292
1293 int nLineHeight = GetConsoleLineHeightPixels();
1294 int y = 0;
1295
1296 const int nInputWidth = min( g_nConsoleInputChars, g_nConsoleInputScrollWidth ); // NOTE: Keep in Sync! DrawConsoleInput() and DrawConsoleCursor()
1297
1298 RECT rect;
1299 rect.left = (nInputWidth + g_nConsolePromptLen) * nWidth;
1300 rect.top = GetConsoleTopPixels( y );
1301 rect.bottom = rect.top + nLineHeight; //g_nFontHeight;
1302 rect.right = rect.left + nWidth;
1303
1304 PrintText( g_sConsoleCursor, rect );
1305}
1306
1307//===========================================================================
1308void GetConsoleRect ( const int y, RECT & rect )

Callers 1

DebuggerCursorUpdateFunction · 0.85

Calls 6

DebuggerSetColorFGFunction · 0.85
DebuggerGetColorFunction · 0.85
DebuggerSetColorBGFunction · 0.85
GetConsoleTopPixelsFunction · 0.85
PrintTextFunction · 0.85

Tested by

no test coverage detected