MCPcopy Create free account
hub / github.com/CobaltFusion/DebugViewPP / AddEllipsis

Function AddEllipsis

DebugView++/LogView.cpp:72–81  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

70}
71
72void AddEllipsis(HDC hdc, std::wstring& text, int width)
73{
74 static const std::wstring ellipsis(L"...");
75 int pos = GetTextOffset(hdc, text, width);
76 if (pos >= 0 && pos < static_cast<int>(text.size()))
77 {
78 pos = GetTextOffset(hdc, text, width - GetTextSize(hdc, ellipsis, ellipsis.size()).cx);
79 text = text.substr(0, pos) + ellipsis;
80 }
81}
82
83SelectionInfo::SelectionInfo() :
84 beginLine(0), endLine(0), count(0)

Callers 1

DrawHighlightedTextFunction · 0.85

Calls 3

GetTextOffsetFunction · 0.85
GetTextSizeFunction · 0.85
sizeMethod · 0.45

Tested by

no test coverage detected