MG: fixed saving OI settings

git-svn-id: trunk@1647 -
This commit is contained in:
lazarus 2002-04-28 06:42:49 +00:00
parent f3cb25dc9c
commit 65c5b68d59
3 changed files with 22 additions and 15 deletions

View File

@ -1550,11 +1550,13 @@ begin
FTop:=XMLConfig.GetValue('ObjectInspectorOptions/Bounds/Top',0);
FWidth:=XMLConfig.GetValue('ObjectInspectorOptions/Bounds/Width',250);
FHeight:=XMLConfig.GetValue('ObjectInspectorOptions/Bounds/Height',400);
FPropertyGridSplitterX:=XMLConfig.GetValue(
'ObjectInspectorOptions/Bounds/PropertyGridSplitterX',110);
FEventGridSplitterX:=XMLConfig.GetValue(
'ObjectInspectorOptions/Bounds/EventGridSplitterX',110);
end;
FPropertyGridSplitterX:=XMLConfig.GetValue(
'ObjectInspectorOptions/Bounds/PropertyGridSplitterX',110);
if FPropertyGridSplitterX<10 then FPropertyGridSplitterX:=10;
FEventGridSplitterX:=XMLConfig.GetValue(
'ObjectInspectorOptions/Bounds/EventGridSplitterX',110);
if FEventGridSplitterX<10 then FEventGridSplitterX:=10;
FGridBackgroundColor:=XMLConfig.GetValue(
'ObjectInspectorOptions/GridBackgroundColor',clBtnFace);
@ -1582,13 +1584,13 @@ begin
XMLConfig.SetValue('ObjectInspectorOptions/Bounds/Top',FTop);
XMLConfig.SetValue('ObjectInspectorOptions/Bounds/Width',FWidth);
XMLConfig.SetValue('ObjectInspectorOptions/Bounds/Height',FHeight);
XMLConfig.SetValue(
'ObjectInspectorOptions/Bounds/PropertyGridSplitterX'
,FPropertyGridSplitterX);
XMLConfig.SetValue(
'ObjectInspectorOptions/Bounds/EventGridSplitterX'
,FEventGridSplitterX);
end;
XMLConfig.SetValue(
'ObjectInspectorOptions/Bounds/PropertyGridSplitterX'
,FPropertyGridSplitterX);
XMLConfig.SetValue(
'ObjectInspectorOptions/Bounds/EventGridSplitterX'
,FEventGridSplitterX);
XMLConfig.SetValue('ObjectInspectorOptions/GridBackgroundColor'
,FGridBackgroundColor);
@ -1619,11 +1621,11 @@ procedure TOIOptions.AssignTo(AnObjInspector: TObjectInspector);
begin
if FSaveBounds then begin
AnObjInspector.SetBounds(FLeft,FTop,FWidth,FHeight);
AnObjInspector.PropertyGrid.SplitterX:=FPropertyGridSplitterX;
AnObjInspector.PropertyGrid.PrefferedSplitterX:=FPropertyGridSplitterX;
AnObjInspector.EventGrid.SplitterX:=FEventGridSplitterX;
AnObjInspector.EventGrid.PrefferedSplitterX:=FPropertyGridSplitterX;
end;
AnObjInspector.PropertyGrid.PrefferedSplitterX:=FPropertyGridSplitterX;
AnObjInspector.PropertyGrid.SplitterX:=FPropertyGridSplitterX;
AnObjInspector.EventGrid.PrefferedSplitterX:=FEventGridSplitterX;
AnObjInspector.EventGrid.SplitterX:=FEventGridSplitterX;
AnObjInspector.PropertyGrid.BackgroundColor:=FGridBackgroundColor;
AnObjInspector.PropertyGrid.ShowHint:=FShowHints;
AnObjInspector.EventGrid.BackgroundColor:=FGridBackgroundColor;

View File

@ -462,7 +462,6 @@ begin
// trim result
if DestPos<=length(AFilename) then
SetLength(Result,DestPos-1);
writeln(' TrimFilename "',AFilename,'" -> "',Result,'"');
end;
procedure FreeThenNil(var Obj: TObject);

View File

@ -911,6 +911,9 @@ begin
ObjectInspector1.PropertyEditorHook:=PropertyEditorHook1;
EnvironmentOptions.IDEWindowLayoutList.Apply(TForm(ObjectInspector1),
DefaultObjectInspectorName);
with EnvironmentOptions do begin
ObjectInspectorOptions.AssignTo(ObjectInspector1);
end;
end;
procedure TMainIDE.SetupCompilerInterface;
@ -6285,6 +6288,9 @@ end.
{ =============================================================================
$Log$
Revision 1.288 2002/04/28 06:42:47 lazarus
MG: fixed saving OI settings
Revision 1.287 2002/04/27 18:56:47 lazarus
MG: started component renaming