mirror of
https://github.com/levinsv/pgadmin3.git
synced 2026-05-15 14:15:49 -06:00
Underlining the query results with a red line if they were truncated due to the set maximum column size.
Результаты запроса которые были усечены из-за превышения максимального размера колонки будут подчёркнуты красной линией.
This commit is contained in:
parent
409bcc95ce
commit
9f6da5c40a
1 changed files with 6 additions and 0 deletions
|
|
@ -224,10 +224,12 @@ public:
|
|||
//////////////////////////////////////////////////////////////////////////////
|
||||
//CursorCellRenderer::Draw(grid, attr, dc, rect, row, col, isSelected); //
|
||||
dc.SetBackgroundMode(wxSOLID);
|
||||
bool istruncateLine=false;
|
||||
wxString text = grid.GetCellValue(row, col);
|
||||
// grey out fields if the grid is disabled
|
||||
if (grid.IsEnabled())
|
||||
{
|
||||
istruncateLine=text.Right(5)=="(...)";
|
||||
if (isSelected)
|
||||
{
|
||||
wxColour clr;
|
||||
|
|
@ -326,6 +328,10 @@ public:
|
|||
}
|
||||
grid.DrawTextRectangle(dc, text,
|
||||
rect, hAlign, vAlign);
|
||||
if (istruncateLine) {
|
||||
dc.SetPen(*wxRED_PEN);
|
||||
dc.DrawLine(wxPoint(rect.x,rect.y+rect.GetHeight()-2),wxPoint(rect.x+rect.width,rect.y+rect.GetHeight()-2));
|
||||
}
|
||||
}
|
||||
#else
|
||||
class CursorCellRenderer : public wxGridCellAutoWrapStringRenderer
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue