Issue #1482: make height of tree nodes slightly higher for better readability, activate OnStart/OnEndOperation

This commit is contained in:
Ansgar Becker
2025-03-21 08:22:53 +01:00
parent d4bc6feec8
commit 875bb7e7ed

View File

@ -1378,7 +1378,7 @@ begin
end; end;
VT.EndUpdate; VT.EndUpdate;
// Disable hottracking in non-Vista mode, looks ugly in XP, but nice in Vista // Disable hottracking in non-Vista mode, looks ugly in XP, but nice in Vista
if toUseExplorerTheme in VT.TreeOptions.PaintOptions then if (toUseExplorerTheme in VT.TreeOptions.PaintOptions) {$IfDef WINDOWS} and true {$EndIf} then
VT.TreeOptions.PaintOptions := VT.TreeOptions.PaintOptions + [toHotTrack] VT.TreeOptions.PaintOptions := VT.TreeOptions.PaintOptions + [toHotTrack]
else else
VT.TreeOptions.PaintOptions := VT.TreeOptions.PaintOptions - [toHotTrack]; VT.TreeOptions.PaintOptions := VT.TreeOptions.PaintOptions - [toHotTrack];
@ -1394,14 +1394,14 @@ begin
// Apply case insensitive incremental search event // Apply case insensitive incremental search event
if VT.IncrementalSearch <> laz.VirtualTrees.isNone then if VT.IncrementalSearch <> laz.VirtualTrees.isNone then
VT.OnIncrementalSearch := Mainform.AnyGridIncrementalSearch; VT.OnIncrementalSearch := Mainform.AnyGridIncrementalSearch;
//VT.OnStartOperation := Mainform.AnyGridStartOperation; VT.OnStartOperation := Mainform.AnyGridStartOperation;
//VT.OnEndOperation := Mainform.AnyGridEndOperation; VT.OnEndOperation := Mainform.AnyGridEndOperation;
end; end;
function GetTextHeight(Font: TFont): Integer; function GetTextHeight(Font: TFont): Integer;
begin begin
Result := Font.GetTextHeight('<27>y'); Result := MainForm.Canvas.TextHeight('<27>y');
end; end;