summaryrefslogtreecommitdiff
path: root/uidesigner/newformdesigner.pas
diff options
context:
space:
mode:
authorGraeme Geldenhuys <graeme@mastermaths.co.za>2010-09-28 11:52:45 +0200
committerGraeme Geldenhuys <graeme@mastermaths.co.za>2010-09-28 11:52:45 +0200
commitb178c4deff9bb8447408c5b469e658bc813075ae (patch)
tree3161659047977c9f72f59ece1196ce1a01353abc /uidesigner/newformdesigner.pas
parent92d78b37533d96257d1298d81c26feb8bb9834c1 (diff)
downloadfpGUI-b178c4deff9bb8447408c5b469e658bc813075ae.tar.xz
uidesigner: Fixed Object Inspector editor bounds to fit cell
* When you selected a property, the property editor did not take into account the owner component's border widths, so they overlapped by 2 pixels.
Diffstat (limited to 'uidesigner/newformdesigner.pas')
-rw-r--r--uidesigner/newformdesigner.pas6
1 files changed, 3 insertions, 3 deletions
diff --git a/uidesigner/newformdesigner.pas b/uidesigner/newformdesigner.pas
index b974d262..c20548e5 100644
--- a/uidesigner/newformdesigner.pas
+++ b/uidesigner/newformdesigner.pas
@@ -798,7 +798,7 @@ end;
function TwgPropertyList.RowHeight: integer;
begin
- Result := 22;
+ Result := 23;
end;
procedure TwgPropertyList.OnUpdateProperty(Sender: TObject);
@@ -969,8 +969,8 @@ begin
editor := prop.CreateEditor(Self);
x := 3 + NameWidth;
- y := FMargin + (FFocusItem - FFirstItem) * RowHeight;
- editor.SetPosition(x, y - 1, Width - ScrollBarWidth - x, RowHeight);
+ y := FMargin + ((FFocusItem - FFirstItem) * RowHeight);
+ editor.SetPosition(x, y, Width - FMargin - ScrollBarWidth - x, RowHeight-1); // last -1 is so cell border lines are still visible
editor.CreateLayout;
editor.OnUpdate := @OnUpdateProperty;
editor.LoadValue(Props.Widget);