You've already forked lazarus-ccr
LazStats: Fix positioning and sizing of non-modal forms in Descriptive menu
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@7677 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
@ -29,6 +29,7 @@ object BoxPlotFrm: TBoxPlotFrm
|
||||
BorderSpacing.Bottom = 8
|
||||
Caption = 'Close'
|
||||
ModalResult = 11
|
||||
OnClick = CloseBtnClick
|
||||
TabOrder = 7
|
||||
end
|
||||
object ComputeBtn: TButton
|
||||
|
@ -32,6 +32,7 @@ type
|
||||
Label2: TLabel;
|
||||
Label3: TLabel;
|
||||
VarList: TListBox;
|
||||
procedure CloseBtnClick(Sender: TObject);
|
||||
procedure ComputeBtnClick(Sender: TObject);
|
||||
procedure FormActivate(Sender: TObject);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
@ -347,6 +348,12 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TBoxPlotFrm.CloseBtnClick(Sender: TObject);
|
||||
begin
|
||||
Close;
|
||||
end;
|
||||
|
||||
|
||||
procedure TBoxPlotFrm.FormActivate(Sender: TObject);
|
||||
var
|
||||
w: Integer;
|
||||
@ -363,6 +370,7 @@ begin
|
||||
Constraints.MinWidth := Width;
|
||||
Constraints.MinHeight := Height;
|
||||
|
||||
Position := poDesigned;
|
||||
FAutoSized := true;
|
||||
end;
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
object BubbleForm: TBubbleForm
|
||||
Left = 473
|
||||
Left = 476
|
||||
Height = 454
|
||||
Top = 253
|
||||
Top = 224
|
||||
Width = 500
|
||||
HelpType = htKeyword
|
||||
HelpKeyword = 'html/RepeatedMeasuresBubblePlot.htm'
|
||||
@ -11,7 +11,6 @@ object BubbleForm: TBubbleForm
|
||||
ClientWidth = 500
|
||||
OnActivate = FormActivate
|
||||
OnCreate = FormCreate
|
||||
OnShow = FormShow
|
||||
Position = poMainFormCenter
|
||||
LCLVersion = '2.1.0.0'
|
||||
object Label6: TLabel
|
||||
@ -398,32 +397,33 @@ object BubbleForm: TBubbleForm
|
||||
Text = 'SizeEdit'
|
||||
end
|
||||
end
|
||||
object ReturnBtn: TButton
|
||||
object CloseBtn: TButton
|
||||
AnchorSideTop.Side = asrBottom
|
||||
AnchorSideRight.Control = Owner
|
||||
AnchorSideRight.Side = asrBottom
|
||||
AnchorSideBottom.Control = Owner
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 427
|
||||
Left = 433
|
||||
Height = 25
|
||||
Top = 421
|
||||
Width = 61
|
||||
Width = 55
|
||||
Anchors = [akRight, akBottom]
|
||||
AutoSize = True
|
||||
BorderSpacing.Left = 8
|
||||
BorderSpacing.Top = 8
|
||||
BorderSpacing.Right = 12
|
||||
BorderSpacing.Bottom = 8
|
||||
Caption = 'Return'
|
||||
ModalResult = 1
|
||||
Caption = 'Close'
|
||||
ModalResult = 11
|
||||
OnClick = CloseBtnClick
|
||||
TabOrder = 8
|
||||
end
|
||||
object ComputeBtn: TButton
|
||||
AnchorSideTop.Side = asrBottom
|
||||
AnchorSideRight.Control = ReturnBtn
|
||||
AnchorSideRight.Control = CloseBtn
|
||||
AnchorSideBottom.Control = Owner
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 343
|
||||
Left = 349
|
||||
Height = 25
|
||||
Top = 421
|
||||
Width = 76
|
||||
@ -441,7 +441,7 @@ object BubbleForm: TBubbleForm
|
||||
AnchorSideRight.Control = ComputeBtn
|
||||
AnchorSideBottom.Control = Owner
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 281
|
||||
Left = 287
|
||||
Height = 25
|
||||
Top = 421
|
||||
Width = 54
|
||||
@ -459,7 +459,7 @@ object BubbleForm: TBubbleForm
|
||||
AnchorSideRight.Control = ResetBtn
|
||||
AnchorSideBottom.Control = Owner
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 222
|
||||
Left = 228
|
||||
Height = 25
|
||||
Top = 421
|
||||
Width = 51
|
||||
@ -477,7 +477,7 @@ object BubbleForm: TBubbleForm
|
||||
AnchorSideLeft.Control = Owner
|
||||
AnchorSideRight.Control = Owner
|
||||
AnchorSideRight.Side = asrBottom
|
||||
AnchorSideBottom.Control = ReturnBtn
|
||||
AnchorSideBottom.Control = CloseBtn
|
||||
Left = 0
|
||||
Height = 8
|
||||
Top = 405
|
||||
|
@ -30,7 +30,7 @@ type
|
||||
Label6: TLabel;
|
||||
ResetBtn: TButton;
|
||||
ComputeBtn: TButton;
|
||||
ReturnBtn: TButton;
|
||||
CloseBtn: TButton;
|
||||
IDInBtn: TBitBtn;
|
||||
IDOutBtn: TBitBtn;
|
||||
XInBtn: TBitBtn;
|
||||
@ -56,6 +56,7 @@ type
|
||||
procedure IDInBtnClick(Sender: TObject);
|
||||
procedure IDOutBtnClick(Sender: TObject);
|
||||
procedure ResetBtnClick(Sender: TObject);
|
||||
procedure CloseBtnClick(Sender: TObject);
|
||||
procedure SizeInBtnClick(Sender: TObject);
|
||||
procedure SizeOutBtnClick(Sender: TObject);
|
||||
procedure VarListSelectionChange(Sender: TObject; {%H-}User: boolean);
|
||||
@ -372,11 +373,11 @@ begin
|
||||
if FAutoSized then
|
||||
exit;
|
||||
|
||||
w := MaxValue([HelpBtn.Width, ResetBtn.Width, ComputeBtn.Width, ReturnBtn.Width]);
|
||||
w := MaxValue([HelpBtn.Width, ResetBtn.Width, ComputeBtn.Width, CloseBtn.Width]);
|
||||
HelpBtn.Constraints.MinWidth := w;
|
||||
ResetBtn.Constraints.MinWidth := w;
|
||||
ComputeBtn.Constraints.MinWidth := w;
|
||||
ReturnBtn.Constraints.MinWidth := w;
|
||||
CloseBtn.Constraints.MinWidth := w;
|
||||
|
||||
Panel1.Constraints.MinHeight := SizeOutBtn.Top + SizeOutBtn.Height;
|
||||
Panel1.Constraints.MinWidth := 2*Label2.Width + IDInBtn.Width + 2*VarList.BorderSpacing.Right;
|
||||
@ -384,6 +385,7 @@ begin
|
||||
Constraints.MinWidth := Width;
|
||||
Constraints.MinHeight := Height;
|
||||
|
||||
Position := poDesigned;
|
||||
FAutoSized := True;
|
||||
end;
|
||||
|
||||
@ -634,6 +636,11 @@ begin
|
||||
Reset;
|
||||
end;
|
||||
|
||||
procedure TBubbleForm.CloseBtnClick(Sender: TObject);
|
||||
begin
|
||||
Close;
|
||||
end;
|
||||
|
||||
|
||||
procedure TBubbleForm.SizeInBtnClick(Sender: TObject);
|
||||
var
|
||||
|
@ -153,6 +153,7 @@ object DescriptiveFrm: TDescriptiveFrm
|
||||
BorderSpacing.Top = 8
|
||||
Caption = 'Close'
|
||||
ModalResult = 11
|
||||
OnClick = CloseBtnClick
|
||||
TabOrder = 9
|
||||
end
|
||||
object HelpBtn: TButton
|
||||
@ -166,7 +167,6 @@ object DescriptiveFrm: TDescriptiveFrm
|
||||
Width = 51
|
||||
Anchors = [akRight, akBottom]
|
||||
AutoSize = True
|
||||
BorderSpacing.Left = 8
|
||||
BorderSpacing.Top = 8
|
||||
BorderSpacing.Right = 8
|
||||
Caption = 'Help'
|
||||
|
@ -38,6 +38,7 @@ type
|
||||
VarList: TListBox;
|
||||
SelList: TListBox;
|
||||
procedure AllBtnClick(Sender: TObject);
|
||||
procedure CloseBtnClick(Sender: TObject);
|
||||
procedure ComputeBtnClick(Sender: TObject);
|
||||
procedure FormActivate(Sender: TObject);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
@ -84,6 +85,12 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TDescriptiveFrm.CloseBtnClick(Sender: TObject);
|
||||
begin
|
||||
Close;
|
||||
end;
|
||||
|
||||
|
||||
procedure TDescriptiveFrm.FormActivate(Sender: TObject);
|
||||
var
|
||||
w: Integer;
|
||||
@ -100,12 +107,16 @@ begin
|
||||
ParamsPanel.Constraints.MinHeight := AllBtn.Top + AllBtn.Height + OptionsGroup.Height +
|
||||
CIEdit.Height + Bevel1.Height + CloseBtn.Height + VarList.BorderSpacing.Bottom +
|
||||
OptionsGroup.BorderSpacing.Bottom + CloseBtn.BorderSpacing.Top;
|
||||
ParamsPanel.Constraints.MinWidth := OptionsGroup.Width;
|
||||
ParamsPanel.Constraints.MinWidth := Math.Max(
|
||||
4*w + 3*HelpBtn.BorderSpacing.Right,
|
||||
OptionsGroup.Width
|
||||
);
|
||||
ParamsPanel.AutoSize := false;
|
||||
|
||||
Constraints.MinHeight := ParamsPanel.Constraints.MinHeight + ParamsPanel.BorderSpacing.Around*2;
|
||||
Constraints.MinWidth := ParamsPanel.Constraints.MinWidth + ParamsPanel.BorderSpacing.Around*2;
|
||||
|
||||
Position := poDesigned;
|
||||
FAutoSized := true;
|
||||
end;
|
||||
|
||||
|
@ -12,7 +12,6 @@ object MultXvsYFrm: TMultXvsYFrm
|
||||
ClientWidth = 395
|
||||
OnActivate = FormActivate
|
||||
OnCreate = FormCreate
|
||||
OnShow = FormShow
|
||||
Position = poMainFormCenter
|
||||
LCLVersion = '2.1.0.0'
|
||||
object Bevel1: TBevel
|
||||
@ -358,6 +357,7 @@ object MultXvsYFrm: TMultXvsYFrm
|
||||
BorderSpacing.Bottom = 8
|
||||
Caption = 'Close'
|
||||
ModalResult = 11
|
||||
OnClick = CloseBtnClick
|
||||
TabOrder = 3
|
||||
end
|
||||
object HelpBtn: TButton
|
||||
|
@ -45,6 +45,7 @@ type
|
||||
Label4: TLabel;
|
||||
Label5: TLabel;
|
||||
VarList: TListBox;
|
||||
procedure CloseBtnClick(Sender: TObject);
|
||||
procedure ComputeBtnClick(Sender: TObject);
|
||||
procedure FormActivate(Sender: TObject);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
@ -275,6 +276,12 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TMultXvsYFrm.CloseBtnClick(Sender: TObject);
|
||||
begin
|
||||
Close;
|
||||
end;
|
||||
|
||||
|
||||
procedure TMultXvsYFrm.FormActivate(Sender: TObject);
|
||||
var
|
||||
w: Integer;
|
||||
@ -291,6 +298,7 @@ begin
|
||||
Constraints.MinWidth := Width;
|
||||
Constraints.MinHeight := Height;
|
||||
|
||||
Position := poDesigned;
|
||||
FAutoSized := true;
|
||||
end;
|
||||
|
||||
|
@ -1,13 +1,13 @@
|
||||
object PlotXYFrm: TPlotXYFrm
|
||||
Left = 433
|
||||
Height = 367
|
||||
Height = 374
|
||||
Top = 262
|
||||
Width = 490
|
||||
HelpType = htKeyword
|
||||
HelpKeyword = 'html/XVersusYPlot.htm'
|
||||
AutoSize = True
|
||||
Caption = 'Plot X versus Y'
|
||||
ClientHeight = 367
|
||||
ClientHeight = 374
|
||||
ClientWidth = 490
|
||||
OnActivate = FormActivate
|
||||
OnCreate = FormCreate
|
||||
@ -58,7 +58,7 @@ object PlotXYFrm: TPlotXYFrm
|
||||
AnchorSideBottom.Control = Bevel1
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 8
|
||||
Height = 293
|
||||
Height = 300
|
||||
Top = 25
|
||||
Width = 215
|
||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
||||
@ -175,17 +175,18 @@ object PlotXYFrm: TPlotXYFrm
|
||||
Text = 'YEdit'
|
||||
end
|
||||
object GroupBox1: TGroupBox
|
||||
AnchorSideLeft.Control = YEdit
|
||||
AnchorSideLeft.Control = XinBtn
|
||||
AnchorSideTop.Control = YEdit
|
||||
AnchorSideTop.Side = asrBottom
|
||||
AnchorSideRight.Side = asrBottom
|
||||
Left = 267
|
||||
Left = 231
|
||||
Height = 141
|
||||
Top = 181
|
||||
Width = 191
|
||||
AutoSize = True
|
||||
BorderSpacing.Top = 24
|
||||
BorderSpacing.Right = 8
|
||||
BorderSpacing.Bottom = 8
|
||||
Caption = 'Options'
|
||||
ChildSizing.LeftRightSpacing = 12
|
||||
ClientHeight = 121
|
||||
@ -278,7 +279,7 @@ object PlotXYFrm: TPlotXYFrm
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 416
|
||||
Height = 25
|
||||
Top = 334
|
||||
Top = 341
|
||||
Width = 62
|
||||
Anchors = [akRight, akBottom]
|
||||
BorderSpacing.Left = 8
|
||||
@ -287,6 +288,7 @@ object PlotXYFrm: TPlotXYFrm
|
||||
BorderSpacing.Bottom = 8
|
||||
Caption = 'Close'
|
||||
ModalResult = 11
|
||||
OnClick = CloseBtnClick
|
||||
TabOrder = 8
|
||||
end
|
||||
object ComputeBtn: TButton
|
||||
@ -295,7 +297,7 @@ object PlotXYFrm: TPlotXYFrm
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 332
|
||||
Height = 25
|
||||
Top = 334
|
||||
Top = 341
|
||||
Width = 76
|
||||
Anchors = [akRight, akBottom]
|
||||
BorderSpacing.Left = 8
|
||||
@ -312,7 +314,7 @@ object PlotXYFrm: TPlotXYFrm
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 270
|
||||
Height = 25
|
||||
Top = 334
|
||||
Top = 341
|
||||
Width = 54
|
||||
Anchors = [akRight, akBottom]
|
||||
BorderSpacing.Left = 12
|
||||
@ -330,7 +332,7 @@ object PlotXYFrm: TPlotXYFrm
|
||||
AnchorSideBottom.Control = CloseBtn
|
||||
Left = 0
|
||||
Height = 8
|
||||
Top = 318
|
||||
Top = 325
|
||||
Width = 490
|
||||
Anchors = [akLeft, akRight, akBottom]
|
||||
Shape = bsBottomLine
|
||||
|
@ -38,6 +38,7 @@ type
|
||||
YOutBtn: TBitBtn;
|
||||
Label1: TLabel;
|
||||
VarList: TListBox;
|
||||
procedure CloseBtnClick(Sender: TObject);
|
||||
procedure ComputeBtnClick(Sender: TObject);
|
||||
procedure FormActivate(Sender: TObject);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
@ -318,6 +319,12 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TPlotXYFrm.CloseBtnClick(Sender: TObject);
|
||||
begin
|
||||
Close;
|
||||
end;
|
||||
|
||||
|
||||
procedure TPlotXYFrm.FormActivate(Sender: TObject);
|
||||
var
|
||||
w: Integer;
|
||||
@ -336,6 +343,7 @@ begin
|
||||
Constraints.MinWidth := GroupBox1.Width * 2 + XInBtn.Width + 4 * VarList.BorderSpacing.Left;
|
||||
Constraints.MinHeight := Height;
|
||||
|
||||
Position := poDesigned;
|
||||
FAutoSized := True;
|
||||
end;
|
||||
|
||||
|
@ -306,6 +306,7 @@ object XvsMultYForm: TXvsMultYForm
|
||||
BorderSpacing.Bottom = 8
|
||||
Caption = 'Close'
|
||||
ModalResult = 11
|
||||
OnClick = CloseBtnClick
|
||||
TabOrder = 3
|
||||
end
|
||||
object ComputeBtn: TButton
|
||||
|
@ -39,6 +39,7 @@ type
|
||||
XOutBtn: TBitBtn;
|
||||
YOutBtn: TBitBtn;
|
||||
VarList: TListBox;
|
||||
procedure CloseBtnClick(Sender: TObject);
|
||||
procedure ComputeBtnClick(Sender: TObject);
|
||||
procedure FormActivate(Sender: TObject);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
@ -253,6 +254,12 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TXvsMultYForm.CloseBtnClick(Sender: TObject);
|
||||
begin
|
||||
Close;
|
||||
end;
|
||||
|
||||
|
||||
procedure TXvsMultYForm.FormActivate(Sender: TObject);
|
||||
var
|
||||
w: Integer;
|
||||
@ -268,6 +275,7 @@ begin
|
||||
Constraints.MinWidth := Width;
|
||||
Constraints.MinHeight := Height;
|
||||
|
||||
Position := poDesigned;
|
||||
FAutoSized := true;
|
||||
end;
|
||||
|
||||
|
Reference in New Issue
Block a user