mirror of
https://github.com/HeidiSQL/HeidiSQL.git
synced 2025-08-26 11:17:57 +08:00
Find a better fix for the black focus rectangle plus fix another graphical glitch for MEMO and BLOB cells, which didn't get covered completely by the (NULL). This fix just leaves the (MEMO) and only uses the grey color for it.
This commit is contained in:
@ -79,7 +79,7 @@ const
|
||||
// Used by ListViews and Grids
|
||||
COLOR_SORTCOLUMN_ASC = $00F7F7F7; // light grey
|
||||
COLOR_SORTCOLUMN_DESC = $00EEEEEE; // medium grey
|
||||
COLOR_NULLVALUE = $00A0A0A0; // darker gray
|
||||
COLOR_NULLVALUE = $00707070; // darker gray
|
||||
ORDER_ASC = 0; // Used for tag-value of "Direction"-button
|
||||
ORDER_DESC = 1; // dito
|
||||
TXT_ASC = 'ASC'; // Used for caption of "Direction"-button
|
||||
|
@ -4920,9 +4920,12 @@ begin
|
||||
if (Grid.Fields[DataCol] <> nil) and Grid.Fields[DataCol].IsNull then
|
||||
begin
|
||||
Grid.Canvas.Font.Color := COLOR_NULLVALUE;
|
||||
Grid.Canvas.TextOut(Rect.Left+2, Rect.Top+2, '(NULL)');
|
||||
// Reset font color, so the focus rectangle in this cell displays as dotted rectangle
|
||||
Grid.Canvas.Font.Color := clWindowText;
|
||||
// Just use the changed font color for (MEMO) and (BLOB) cells
|
||||
if Grid.Fields[DataCol].DataType in [ftMemo, ftBlob] then
|
||||
Grid.DefaultDrawColumnCell(Rect, DataCol, Grid.Columns[DataCol], State)
|
||||
// ... while the natively displayed datatypes get a grey (NULL)
|
||||
else
|
||||
Grid.Canvas.TextOut(Rect.Left+2, Rect.Top+2, '(NULL)');
|
||||
end;
|
||||
end;
|
||||
|
||||
|
Reference in New Issue
Block a user