IDE: code observer options: nicer layout

git-svn-id: trunk@33163 -
This commit is contained in:
mattias 2011-10-30 09:27:27 +00:00
parent 4e22228b6b
commit 1c732c24ef
4 changed files with 100 additions and 73 deletions

View File

@ -2921,7 +2921,7 @@ function TGDBMIDebuggerCommandDisassembe.DoExecute: Boolean;
{$PUSH}{$IFnDEF DBGMI_WITH_DISASS_OVERFLOW}{$Q-}{$R-}{$ENDIF} // Overflow is allowed to occur {$PUSH}{$IFnDEF DBGMI_WITH_DISASS_OVERFLOW}{$Q-}{$R-}{$ENDIF} // Overflow is allowed to occur
Addr := Itm^.Addr; Addr := Itm^.Addr;
Offs := TDBGPtr(Addr - AMemDump.Addr); Offs := TDBGPtr(Addr - AMemDump.Addr);
if (Offs {%H-}< 0) or (Offs >= AMemDump.Count) if (Offs < 0) or (Offs >= AMemDump.Count)
then Continue; then Continue;
if (NextItm <> nil) //and (NextItm^.Addr > Addr) if (NextItm <> nil) //and (NextItm^.Addr > Addr)

View File

@ -1,19 +1,19 @@
inherited CodeObserverOptionsFrame: TCodeObserverOptionsFrame inherited CodeObserverOptionsFrame: TCodeObserverOptionsFrame
Height = 428 Height = 466
Width = 531 Width = 557
ClientHeight = 428 ClientHeight = 466
ClientWidth = 531 ClientWidth = 557
TabOrder = 0 TabOrder = 0
DesignLeft = 220 DesignLeft = 250
DesignTop = 220 DesignTop = 214
object CodeObsIgnoreConstantsLabel: TLabel[0] object CodeObsIgnoreConstantsLabel: TLabel[0]
AnchorSideLeft.Control = Owner AnchorSideLeft.Control = Owner
AnchorSideTop.Control = CodeObsCategoriesCheckGroup AnchorSideTop.Control = CodeObsCategoriesCheckGroup
AnchorSideTop.Side = asrBottom AnchorSideTop.Side = asrBottom
Left = 0 Left = 0
Height = 16 Height = 18
Top = 196 Top = 226
Width = 165 Width = 212
BorderSpacing.Top = 6 BorderSpacing.Top = 6
Caption = 'CodeObsIgnoreConstantsLabel' Caption = 'CodeObsIgnoreConstantsLabel'
ParentColor = False ParentColor = False
@ -22,33 +22,23 @@ inherited CodeObserverOptionsFrame: TCodeObserverOptionsFrame
AnchorSideLeft.Control = CodeObsLeftPanel AnchorSideLeft.Control = CodeObsLeftPanel
AnchorSideTop.Control = CodeObsCategoriesCheckGroup AnchorSideTop.Control = CodeObsCategoriesCheckGroup
AnchorSideTop.Side = asrBottom AnchorSideTop.Side = asrBottom
Left = 269 Left = 291
Height = 16 Height = 18
Top = 196 Top = 226
Width = 152 Width = 191
BorderSpacing.Top = 6 BorderSpacing.Top = 6
Caption = 'COIgnoreConstInFuncsLabel' Caption = 'COIgnoreConstInFuncsLabel'
ParentColor = False ParentColor = False
end end
object Label1: TLabel[2] object CodeObsCategoriesCheckGroup: TCheckGroup[2]
AnchorSideLeft.Control = Owner
AnchorSideLeft.Side = asrCenter
Left = 265
Height = 1
Top = 40
Width = 1
ParentColor = False
end
object CodeObsCategoriesCheckGroup: TCheckGroup[3]
AnchorSideLeft.Control = Owner AnchorSideLeft.Control = Owner
AnchorSideTop.Control = Owner AnchorSideTop.Control = Owner
AnchorSideRight.Control = Label1
AnchorSideBottom.Control = Owner AnchorSideBottom.Control = Owner
AnchorSideBottom.Side = asrBottom AnchorSideBottom.Side = asrBottom
Left = 0 Left = 0
Height = 190 Height = 220
Top = 0 Top = 0
Width = 262 Width = 288
Anchors = [akTop, akLeft, akRight] Anchors = [akTop, akLeft, akRight]
AutoFill = True AutoFill = True
AutoSize = True AutoSize = True
@ -62,11 +52,11 @@ inherited CodeObserverOptionsFrame: TCodeObserverOptionsFrame
ChildSizing.ShrinkVertical = crsScaleChilds ChildSizing.ShrinkVertical = crsScaleChilds
ChildSizing.Layout = cclLeftToRightThenTopToBottom ChildSizing.Layout = cclLeftToRightThenTopToBottom
ChildSizing.ControlsPerLine = 1 ChildSizing.ControlsPerLine = 1
Constraints.MinHeight = 190 Constraints.MinHeight = 220
OnItemClick = CodeObsCategoriesCheckGroupItemClick OnItemClick = CodeObsCategoriesCheckGroupItemClick
TabOrder = 0 TabOrder = 0
end end
object CodeObsIgnoreConstantsMemo: TMemo[4] object CodeObsIgnoreConstantsMemo: TMemo[3]
AnchorSideLeft.Control = CodeObsIgnoreConstantsLabel AnchorSideLeft.Control = CodeObsIgnoreConstantsLabel
AnchorSideTop.Control = CodeObsIgnoreConstantsLabel AnchorSideTop.Control = CodeObsIgnoreConstantsLabel
AnchorSideTop.Side = asrBottom AnchorSideTop.Side = asrBottom
@ -75,9 +65,9 @@ inherited CodeObserverOptionsFrame: TCodeObserverOptionsFrame
AnchorSideBottom.Control = Owner AnchorSideBottom.Control = Owner
AnchorSideBottom.Side = asrBottom AnchorSideBottom.Side = asrBottom
Left = 0 Left = 0
Height = 213 Height = 219
Top = 215 Top = 247
Width = 262 Width = 288
Anchors = [akTop, akLeft, akRight, akBottom] Anchors = [akTop, akLeft, akRight, akBottom]
BorderSpacing.Top = 3 BorderSpacing.Top = 3
Lines.Strings = ( Lines.Strings = (
@ -85,74 +75,93 @@ inherited CodeObserverOptionsFrame: TCodeObserverOptionsFrame
) )
TabOrder = 1 TabOrder = 1
end end
object CodeObsLeftPanel: TPanel[5] object CodeObsLeftPanel: TPanel[4]
AnchorSideLeft.Control = Label1 AnchorSideLeft.Control = CodeObsCategoriesCheckGroup
AnchorSideLeft.Side = asrBottom AnchorSideLeft.Side = asrBottom
AnchorSideTop.Control = Owner AnchorSideTop.Control = Owner
Left = 269 AnchorSideRight.Control = Owner
Height = 169 AnchorSideRight.Side = asrBottom
Left = 291
Height = 211
Top = 0 Top = 0
Width = 177 Width = 266
Anchors = [akTop, akLeft, akRight]
AutoSize = True AutoSize = True
BorderSpacing.Left = 3 BorderSpacing.Left = 3
BevelOuter = bvNone BevelOuter = bvNone
ClientHeight = 169 ClientHeight = 211
ClientWidth = 177 ClientWidth = 266
TabOrder = 2 TabOrder = 2
object NestedProcCountLabel: TLabel object NestedProcCountLabel: TLabel
AnchorSideLeft.Control = CodeObsLeftPanel AnchorSideLeft.Control = CodeObsLeftPanel
AnchorSideTop.Control = LongParamListCountSpinEdit AnchorSideTop.Control = LongParamListCountSpinEdit
AnchorSideTop.Side = asrBottom AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = CodeObsLeftPanel
AnchorSideRight.Side = asrBottom
Left = 0 Left = 0
Height = 16 Height = 18
Top = 102 Top = 114
Width = 123 Width = 266
Anchors = [akTop, akLeft, akRight]
BorderSpacing.Top = 6 BorderSpacing.Top = 6
Caption = 'NestedProcCountLabel' Caption = 'NestedProcCountLabel'
ParentColor = False ParentColor = False
WordWrap = True
end end
object LongParamListCountLabel: TLabel object LongParamListCountLabel: TLabel
AnchorSideLeft.Control = CodeObsLeftPanel AnchorSideLeft.Control = CodeObsLeftPanel
AnchorSideTop.Control = LongProcLineCountSpinEdit AnchorSideTop.Control = LongProcLineCountSpinEdit
AnchorSideTop.Side = asrBottom AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = CodeObsLeftPanel
AnchorSideRight.Side = asrBottom
Left = 0 Left = 0
Height = 16 Height = 18
Top = 54 Top = 60
Width = 141 Width = 266
Anchors = [akTop, akLeft, akRight]
BorderSpacing.Top = 6 BorderSpacing.Top = 6
Caption = 'LongParamListCountLabel' Caption = 'LongParamListCountLabel'
ParentColor = False ParentColor = False
WordWrap = True
end end
object LongProcLineCountLabel: TLabel object LongProcLineCountLabel: TLabel
AnchorSideLeft.Control = CodeObsLeftPanel AnchorSideLeft.Control = CodeObsLeftPanel
AnchorSideTop.Control = CodeObsLeftPanel AnchorSideTop.Control = CodeObsLeftPanel
AnchorSideRight.Control = CodeObsLeftPanel
AnchorSideRight.Side = asrBottom
Left = 0 Left = 0
Height = 16 Height = 18
Top = 6 Top = 6
Width = 135 Width = 266
Anchors = [akTop, akLeft, akRight]
BorderSpacing.Top = 6 BorderSpacing.Top = 6
Caption = 'LongProcLineCountLabel' Caption = 'LongProcLineCountLabel'
ParentColor = False ParentColor = False
WordWrap = True
end end
object CodeObsCharConstCheckBox: TCheckBox object UnnamedCharConstCheckBox: TCheckBox
AnchorSideLeft.Control = CodeObsLeftPanel AnchorSideLeft.Control = CodeObsLeftPanel
AnchorSideTop.Control = NestedProcCountSpinEdit AnchorSideTop.Control = UnnamedCharConstLabel
AnchorSideTop.Side = asrBottom AnchorSideTop.Side = asrBottom
Left = 0 AnchorSideRight.Control = CodeObsLeftPanel
Height = 19 AnchorSideRight.Side = asrBottom
Top = 150 Left = 6
Width = 177 Height = 22
BorderSpacing.Top = 6 Top = 189
Caption = 'CodeObsCharConstCheckBox' Width = 260
Anchors = [akTop, akLeft, akRight]
BorderSpacing.Left = 6
BorderSpacing.Top = 3
Caption = 'UnnamedCharConstCheckBox'
TabOrder = 0 TabOrder = 0
end end
object NestedProcCountSpinEdit: TSpinEdit object NestedProcCountSpinEdit: TSpinEdit
AnchorSideLeft.Control = CodeObsCharConstCheckBox AnchorSideLeft.Control = UnnamedCharConstCheckBox
AnchorSideTop.Control = NestedProcCountLabel AnchorSideTop.Control = NestedProcCountLabel
AnchorSideTop.Side = asrBottom AnchorSideTop.Side = asrBottom
Left = 6 Left = 12
Height = 23 Height = 27
Top = 121 Top = 135
Width = 60 Width = 60
BorderSpacing.Left = 6 BorderSpacing.Left = 6
BorderSpacing.Top = 3 BorderSpacing.Top = 3
@ -163,8 +172,8 @@ inherited CodeObserverOptionsFrame: TCodeObserverOptionsFrame
AnchorSideTop.Control = LongParamListCountLabel AnchorSideTop.Control = LongParamListCountLabel
AnchorSideTop.Side = asrBottom AnchorSideTop.Side = asrBottom
Left = 6 Left = 6
Height = 23 Height = 27
Top = 73 Top = 81
Width = 60 Width = 60
BorderSpacing.Left = 6 BorderSpacing.Left = 6
BorderSpacing.Top = 3 BorderSpacing.Top = 3
@ -175,15 +184,31 @@ inherited CodeObserverOptionsFrame: TCodeObserverOptionsFrame
AnchorSideTop.Control = LongProcLineCountLabel AnchorSideTop.Control = LongProcLineCountLabel
AnchorSideTop.Side = asrBottom AnchorSideTop.Side = asrBottom
Left = 6 Left = 6
Height = 23 Height = 27
Top = 25 Top = 27
Width = 60 Width = 60
BorderSpacing.Left = 6 BorderSpacing.Left = 6
BorderSpacing.Top = 3 BorderSpacing.Top = 3
TabOrder = 3 TabOrder = 3
end end
object UnnamedCharConstLabel: TLabel
AnchorSideLeft.Control = CodeObsLeftPanel
AnchorSideTop.Control = NestedProcCountSpinEdit
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = CodeObsLeftPanel
AnchorSideRight.Side = asrBottom
Left = 0
Height = 18
Top = 168
Width = 266
Anchors = [akTop, akLeft, akRight]
BorderSpacing.Top = 6
Caption = 'UnnamedCharConstLabel'
ParentColor = False
WordWrap = True
end end
object COIgnoreConstInFuncsMemo: TMemo[6] end
object COIgnoreConstInFuncsMemo: TMemo[5]
AnchorSideLeft.Control = CodeObsLeftPanel AnchorSideLeft.Control = CodeObsLeftPanel
AnchorSideTop.Control = COIgnoreConstInFuncsLabel AnchorSideTop.Control = COIgnoreConstInFuncsLabel
AnchorSideTop.Side = asrBottom AnchorSideTop.Side = asrBottom
@ -191,10 +216,10 @@ inherited CodeObserverOptionsFrame: TCodeObserverOptionsFrame
AnchorSideRight.Side = asrBottom AnchorSideRight.Side = asrBottom
AnchorSideBottom.Control = Owner AnchorSideBottom.Control = Owner
AnchorSideBottom.Side = asrBottom AnchorSideBottom.Side = asrBottom
Left = 269 Left = 291
Height = 213 Height = 219
Top = 215 Top = 247
Width = 262 Width = 266
Anchors = [akTop, akLeft, akRight, akBottom] Anchors = [akTop, akLeft, akRight, akBottom]
BorderSpacing.Top = 3 BorderSpacing.Top = 3
Lines.Strings = ( Lines.Strings = (

View File

@ -33,11 +33,10 @@ type
{ TCodeObserverOptionsFrame } { TCodeObserverOptionsFrame }
TCodeObserverOptionsFrame = class(TAbstractIDEOptionsEditor) TCodeObserverOptionsFrame = class(TAbstractIDEOptionsEditor)
CodeObsCharConstCheckBox: TCheckBox; UnnamedCharConstCheckBox: TCheckBox;
CodeObsCategoriesCheckGroup: TCheckGroup; CodeObsCategoriesCheckGroup: TCheckGroup;
CodeObsIgnoreConstantsLabel: TLabel; CodeObsIgnoreConstantsLabel: TLabel;
COIgnoreConstInFuncsLabel: TLabel; COIgnoreConstInFuncsLabel: TLabel;
Label1: TLabel;
LongProcLineCountLabel: TLabel; LongProcLineCountLabel: TLabel;
LongParamListCountLabel: TLabel; LongParamListCountLabel: TLabel;
CodeObsIgnoreConstantsMemo: TMemo; CodeObsIgnoreConstantsMemo: TMemo;
@ -47,6 +46,7 @@ type
LongParamListCountSpinEdit: TSpinEdit; LongParamListCountSpinEdit: TSpinEdit;
NestedProcCountSpinEdit: TSpinEdit; NestedProcCountSpinEdit: TSpinEdit;
CodeObsLeftPanel: TPanel; CodeObsLeftPanel: TPanel;
UnnamedCharConstLabel: TLabel;
procedure CodeObsCategoriesCheckGroupItemClick(Sender: TObject; procedure CodeObsCategoriesCheckGroupItemClick(Sender: TObject;
Index: integer); Index: integer);
private private
@ -154,7 +154,8 @@ begin
LongProcLineCountLabel.Caption := lisCELongProcLineCount; LongProcLineCountLabel.Caption := lisCELongProcLineCount;
LongParamListCountLabel.Caption := lisCELongParamListCount; LongParamListCountLabel.Caption := lisCELongParamListCount;
NestedProcCountLabel.Caption := lisCENestedProcCount; NestedProcCountLabel.Caption := lisCENestedProcCount;
CodeObsCharConstCheckBox.Caption := lisCodeObsCharConst; UnnamedCharConstLabel.Caption := lisCodeObsCharConst;
UnnamedCharConstCheckBox.Caption := lisShow;
CodeObsIgnoreConstantsLabel.Caption := lisCodeObsIgnoreeConstants; CodeObsIgnoreConstantsLabel.Caption := lisCodeObsIgnoreeConstants;
COIgnoreConstInFuncsLabel.Caption := lisCodeObIgnoreConstInFuncs; COIgnoreConstInFuncsLabel.Caption := lisCodeObIgnoreConstInFuncs;
end; end;
@ -174,7 +175,7 @@ begin
LongProcLineCountSpinEdit.Value := LongProcLineCount; LongProcLineCountSpinEdit.Value := LongProcLineCount;
LongParamListCountSpinEdit.Value := LongParamListCount; LongParamListCountSpinEdit.Value := LongParamListCount;
NestedProcCountSpinEdit.Value := NestedProcCount; NestedProcCountSpinEdit.Value := NestedProcCount;
CodeObsCharConstCheckBox.Checked := ObserveCharConst; UnnamedCharConstCheckBox.Checked := ObserveCharConst;
Tmp := CreateListOfCOIgnoreConstants; Tmp := CreateListOfCOIgnoreConstants;
CodeObsIgnoreConstantsMemo.Lines.Assign(Tmp); CodeObsIgnoreConstantsMemo.Lines.Assign(Tmp);
Tmp.Free; Tmp.Free;
@ -200,7 +201,7 @@ begin
LongProcLineCount := LongProcLineCountSpinEdit.Value; LongProcLineCount := LongProcLineCountSpinEdit.Value;
LongParamListCount := LongParamListCountSpinEdit.Value; LongParamListCount := LongParamListCountSpinEdit.Value;
NestedProcCount := NestedProcCountSpinEdit.Value; NestedProcCount := NestedProcCountSpinEdit.Value;
ObserveCharConst := CodeObsCharConstCheckBox.Checked; ObserveCharConst := UnnamedCharConstCheckBox.Checked;
SetListOf_COIgnoreConstants(CodeObsIgnoreConstantsMemo.Lines, False); SetListOf_COIgnoreConstants(CodeObsIgnoreConstantsMemo.Lines, False);
SetListOf_COIgnoreConstInFuncs(COIgnoreConstInFuncsMemo.Lines, False); SetListOf_COIgnoreConstInFuncs(COIgnoreConstInFuncsMemo.Lines, False);
end; end;

View File

@ -4921,6 +4921,7 @@ resourcestring
lisCENestedProcCount = 'Nested procedures count treating as "many"'; lisCENestedProcCount = 'Nested procedures count treating as "many"';
lisCodeObsCharConst = 'Search for unnamed char constants'; lisCodeObsCharConst = 'Search for unnamed char constants';
lisCodeObsIgnoreeConstants = 'Ignore next unnamed constants'; lisCodeObsIgnoreeConstants = 'Ignore next unnamed constants';
lisShow = 'Show';
lisCodeObIgnoreConstInFuncs = 'Ignore constants in next functions'; lisCodeObIgnoreConstInFuncs = 'Ignore constants in next functions';
lisCEEmptyBlocks = 'Empty blocks'; lisCEEmptyBlocks = 'Empty blocks';
lisCEComplexityGroup = 'Complexity'; lisCEComplexityGroup = 'Complexity';