| 70 | } |
| 71 | |
| 72 | void 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 | |
| 83 | SelectionInfo::SelectionInfo() : |
| 84 | beginLine(0), endLine(0), count(0) |
no test coverage detected