MCPcopy Create free account
hub / github.com/OpenLoco/OpenLoco / drawStringLeftClipped

Function drawStringLeftClipped

src/OpenLoco/src/Graphics/TextRenderer.cpp:506–522  ·  view source on GitHub ↗

0x00494BBF al: colour bx: string id cx: x dx: y esi: args edi: rt bp: width

Source from the content-addressed store, hash-verified

504 // edi: rt
505 // bp: width
506 static Ui::Point drawStringLeftClipped(
507 TextDrawingState& drawState,
508 DrawingContext& ctx,
509 const RenderTarget& rt,
510 Ui::Point origin,
511 uint16_t width,
512 AdvancedColour colour,
513 StringId stringId,
514 FormatArgumentsView args)
515 {
516 char buffer[512];
517 StringManager::formatString(buffer, std::size(buffer), stringId, args);
518
519 clipString(drawState.font, width, buffer);
520
521 return drawString(drawState, ctx, rt, origin, colour, buffer);
522 }
523
524 // 0x00494C78
525 // al: colour

Callers 1

drawStringLeftClippedMethod · 0.85

Calls 3

formatStringFunction · 0.85
clipStringFunction · 0.85
drawStringFunction · 0.85

Tested by

no test coverage detected