Skip to content

Commit f0b50d5

Browse files
committed
Tweaks
1 parent c01f97a commit f0b50d5

File tree

5 files changed

+110
-88
lines changed

5 files changed

+110
-88
lines changed

Source/ide/simba.form_functionlist.pas

Lines changed: 16 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ TSimbaFunctionListPage = class(TSimbaPage)
5757
procedure DoOpenContextMenu(Sender: TObject);
5858
procedure DoUpdateHiddenSections(Sender: TObject);
5959
procedure DoMouseOverTooltipClick(Sender: TObject);
60+
procedure DoCollapseAllClick(Sender: TObject);
6061
procedure DoShowAllClick(Sender: TObject);
6162
procedure DoHideAllClick(Sender: TObject);
6263
procedure DoDragDrop(Sender, Source: TObject; X, Y: Integer);
@@ -173,7 +174,7 @@ procedure TSimbaFunctionListPage.AddDecl(ParentNode: TTreeNode; Decl: TDeclarati
173174
begin
174175
if (Decl.Name = '') then
175176
Exit;
176-
if (ANodeType = ntSimbaDecl) and ((Decl is TDeclaration_Method) and ((Decl.Name[1] = '_') or TDeclaration_Method(Decl).isOverride)) then
177+
if (ANodeType = ntSimbaDecl) and ((Decl is TDeclaration_Method) and ((Decl.Name[1] = '_') or TDeclaration_Method(Decl).isOverride or TDeclaration_Method(Decl).isOperator)) then
177178
Exit;
178179

179180
Node := FTreeView.AddNode(ParentNode, Decl.Name);
@@ -222,7 +223,7 @@ procedure TSimbaFunctionListPage.AddSimbaNode;
222223
AddDecl(ParentNode, Decl, ntSimbaDecl);
223224
end;
224225

225-
FSimbaNode.AlphaSort();
226+
//FSimbaNode.AlphaSort();
226227
FSimbaNode.Expanded := True;
227228

228229
DoHiddenSimbaSectionsChange(SimbaSettings.FunctionList.HiddenSimbaSections);
@@ -359,16 +360,9 @@ procedure TSimbaFunctionListPage.DoCustomOrderChange(Setting: TSimbaSetting);
359360
I: Integer;
360361
begin
361362
Order := String(Setting.Value).Split(',');
362-
363-
// will need to be re done when anything changes, just easier
364-
if (Length(Order) <> FSimbaNode.Count) then
365-
Exit;
366363
for I := 0 to High(Order) do
367-
if (FSimbaNode.FindNode(Order[I]) = nil) then
368-
Exit;
369-
370-
for I := 0 to High(Order) do
371-
FSimbaNode.FindNode(Order[I]).Index := I;
364+
if (FSimbaNode.FindNode(Order[I]) <> nil) and (I < FSimbaNode.Count) then
365+
FSimbaNode.FindNode(Order[I]).Index := I;
372366
end;
373367

374368
procedure TSimbaFunctionListPage.DoEditorModified(Sender: TObject);
@@ -471,6 +465,16 @@ procedure TSimbaFunctionListPage.DoMouseOverTooltipClick(Sender: TObject);
471465
SimbaSettings.FunctionList.ShowMouseoverHint.Value := TMenuItem(Sender).Checked;
472466
end;
473467

468+
procedure TSimbaFunctionListPage.DoCollapseAllClick(Sender: TObject);
469+
begin
470+
FTreeView.FullCollapse();
471+
472+
FScriptNode.Expanded := True;
473+
FIncludesNode.Expanded := True;
474+
FPluginsNode.Expanded := True;
475+
FSimbaNode.Expanded := True;
476+
end;
477+
474478
procedure TSimbaFunctionListPage.DoShowAllClick(Sender: TObject);
475479
begin
476480
SimbaSettings.FunctionList.HiddenSimbaSections.Value := '';
@@ -592,6 +596,7 @@ constructor TSimbaFunctionListPage.Create(AOwner: TComponent);
592596
Add('Open Simba Documentation', @DoOpenSimbaDocClick, False, False, IMG_SIMBA);
593597
Add('Show Mouse-over tooltip', @DoMouseOverTooltipClick, True, SimbaSettings.FunctionList.ShowMouseoverHint.Value);
594598
AddLine();
599+
Add('Collapse all', @DoCollapseAllClick);
595600
Add('Show all', @DoShowAllClick);
596601
Add('Hide all', @DoHideAllClick);
597602

@@ -826,4 +831,3 @@ procedure TSimbaFunctionListForm.DoDoubleClickSplitter(Sender: TObject);
826831
{$R *.lfm}
827832

828833
end.
829-

Source/ide/simba.form_main.pas

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -609,7 +609,7 @@ procedure TSimbaMainForm.Setup;
609609
BeginFormUpdate();
610610
try
611611
DockMaster.BeginUpdate();
612-
DockMaster.SplitterWidth := Scale96ToScreen(8);
612+
DockMaster.SplitterWidth := Scale96ToScreen(6);
613613
DockMaster.HeaderClass := TSimbaAnchorDockHeader;
614614
DockMaster.SplitterClass := TSimbaAnchorDockSplitter;
615615
DockMaster.SiteClass := TSimbaAnchorDockHostSite;

Source/ide/simba.frame_settings_general.lfm

Lines changed: 71 additions & 71 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
object SimbaGeneralFrame: TSimbaGeneralFrame
22
Left = 0
3-
Height = 784
3+
Height = 1045
44
Top = 0
5-
Width = 1121
6-
ClientHeight = 784
7-
ClientWidth = 1121
8-
DesignTimePPI = 144
5+
Width = 1495
6+
ClientHeight = 1045
7+
ClientWidth = 1495
8+
DesignTimePPI = 192
99
ParentFont = False
1010
TabOrder = 0
1111
DesignLeft = 3939
@@ -18,19 +18,19 @@ object SimbaGeneralFrame: TSimbaGeneralFrame
1818
AnchorSideRight.Control = Owner
1919
AnchorSideRight.Side = asrBottom
2020
AnchorSideBottom.Side = asrBottom
21-
Left = 234
21+
Left = 215
2222
Height = 31
23-
Top = 129
24-
Width = 869
23+
Top = 134
24+
Width = 1256
2525
Max = 32
2626
Min = 12
2727
PageSize = 1
2828
Position = 12
2929
OnChange = ToolbarSizeTrackBarChange
3030
Align = alCustom
3131
Anchors = [akTop, akLeft, akRight]
32-
BorderSpacing.Top = 12
33-
BorderSpacing.Right = 18
32+
BorderSpacing.Top = 16
33+
BorderSpacing.Right = 24
3434
Color = 3487029
3535
ParentColor = False
3636
TabOrder = 0
@@ -43,17 +43,17 @@ object SimbaGeneralFrame: TSimbaGeneralFrame
4343
AnchorSideRight.Side = asrBottom
4444
AnchorSideBottom.Control = FontSizeLabel
4545
AnchorSideBottom.Side = asrBottom
46-
Left = 234
46+
Left = 215
4747
Height = 31
4848
Top = 0
49-
Width = 869
49+
Width = 1256
5050
Max = 24
51-
Min = 8
51+
Min = 7
5252
Position = 8
5353
OnChange = FontSizeTrackBarChange
5454
Align = alCustom
5555
Anchors = [akTop, akLeft, akRight]
56-
BorderSpacing.Right = 18
56+
BorderSpacing.Right = 24
5757
Color = 3487029
5858
ParentColor = False
5959
TabOrder = 1
@@ -66,7 +66,7 @@ object SimbaGeneralFrame: TSimbaGeneralFrame
6666
Left = 0
6767
Height = 31
6868
Top = 0
69-
Width = 107
69+
Width = 98
7070
Align = alCustom
7171
Anchors = [akTop, akLeft, akBottom]
7272
Caption = 'Font Size'
@@ -80,8 +80,8 @@ object SimbaGeneralFrame: TSimbaGeneralFrame
8080
AnchorSideBottom.Side = asrBottom
8181
Left = 0
8282
Height = 31
83-
Top = 129
84-
Width = 47
83+
Top = 134
84+
Width = 43
8585
Anchors = [akTop, akLeft, akBottom]
8686
Caption = 'Size'
8787
Layout = tlCenter
@@ -94,17 +94,17 @@ object SimbaGeneralFrame: TSimbaGeneralFrame
9494
AnchorSideTop.Side = asrBottom
9595
AnchorSideRight.Control = Owner
9696
AnchorSideRight.Side = asrBottom
97-
Left = 234
98-
Height = 37
99-
Top = 335
100-
Width = 857
97+
Left = 215
98+
Height = 49
99+
Top = 341
100+
Width = 1240
101101
Max = 38
102102
Min = 8
103103
Position = 10
104104
OnChange = ToolbarSizeTrackBarChange
105105
Anchors = [akTop, akLeft, akRight]
106-
BorderSpacing.Top = 12
107-
BorderSpacing.Right = 30
106+
BorderSpacing.Top = 16
107+
BorderSpacing.Right = 40
108108
Color = 3487029
109109
ParentColor = False
110110
TabOrder = 2
@@ -116,16 +116,16 @@ object SimbaGeneralFrame: TSimbaGeneralFrame
116116
AnchorSideTop.Side = asrBottom
117117
AnchorSideRight.Control = Owner
118118
AnchorSideRight.Side = asrBottom
119-
Left = 234
120-
Height = 37
121-
Top = 384
122-
Width = 857
119+
Left = 215
120+
Height = 49
121+
Top = 406
122+
Width = 1240
123123
Min = 1
124124
Position = 10
125125
OnChange = DoScrollBarArrowTrackBarChange
126126
Anchors = [akTop, akLeft, akRight]
127-
BorderSpacing.Top = 12
128-
BorderSpacing.Right = 30
127+
BorderSpacing.Top = 16
128+
BorderSpacing.Right = 40
129129
Color = 3487029
130130
ParentColor = False
131131
TabOrder = 3
@@ -136,9 +136,9 @@ object SimbaGeneralFrame: TSimbaGeneralFrame
136136
AnchorSideBottom.Control = ScrollBarSizeTrackBar
137137
AnchorSideBottom.Side = asrBottom
138138
Left = 0
139-
Height = 37
140-
Top = 335
141-
Width = 47
139+
Height = 49
140+
Top = 341
141+
Width = 43
142142
Anchors = [akTop, akLeft, akBottom]
143143
Caption = 'Size'
144144
Layout = tlCenter
@@ -150,9 +150,9 @@ object SimbaGeneralFrame: TSimbaGeneralFrame
150150
AnchorSideBottom.Control = ScrollBarArrowSizeTrackBar
151151
AnchorSideBottom.Side = asrBottom
152152
Left = 0
153-
Height = 37
154-
Top = 384
155-
Width = 125
153+
Height = 49
154+
Top = 406
155+
Width = 112
156156
Anchors = [akTop, akLeft, akBottom]
157157
Caption = 'Arrow Size'
158158
Layout = tlCenter
@@ -165,21 +165,21 @@ object SimbaGeneralFrame: TSimbaGeneralFrame
165165
AnchorSideRight.Control = Owner
166166
AnchorSideRight.Side = asrBottom
167167
Left = 0
168-
Height = 37
169-
Top = 286
170-
Width = 1121
168+
Height = 32
169+
Top = 293
170+
Width = 1495
171171
Caption = 'Scroll Bar'
172172
Anchors = [akTop, akLeft, akRight]
173-
BorderSpacing.Top = 12
173+
BorderSpacing.Top = 16
174174
Style = gsHorLines
175175
end
176176
object PlaceholderLabel: TLabel
177177
AnchorSideLeft.Control = Owner
178178
Left = 0
179-
Height = 37
180-
Top = 720
181-
Width = 227
182-
BorderSpacing.Right = 7
179+
Height = 32
180+
Top = 960
181+
Width = 206
182+
BorderSpacing.Right = 9
183183
Caption = 'Image Size: Default'
184184
ParentColor = False
185185
end
@@ -190,24 +190,24 @@ object SimbaGeneralFrame: TSimbaGeneralFrame
190190
AnchorSideRight.Control = Owner
191191
AnchorSideRight.Side = asrBottom
192192
Left = 0
193-
Height = 37
194-
Top = 80
195-
Width = 1121
193+
Height = 32
194+
Top = 86
195+
Width = 1495
196196
Caption = 'Tool Bar'
197197
Anchors = [akTop, akLeft, akRight]
198-
BorderSpacing.Top = 6
198+
BorderSpacing.Top = 8
199199
Style = gsHorLines
200200
end
201201
object ToolbarPositionComboBox: TComboBox
202202
AnchorSideLeft.Control = ToolbarSizeTrackBar
203203
AnchorSideTop.Control = ToolbarSizeTrackBar
204204
AnchorSideTop.Side = asrBottom
205-
Left = 234
206-
Height = 45
207-
Top = 172
208-
Width = 302
209-
BorderSpacing.Top = 12
210-
ItemHeight = 37
205+
Left = 215
206+
Height = 40
207+
Top = 181
208+
Width = 403
209+
BorderSpacing.Top = 16
210+
ItemHeight = 32
211211
ItemIndex = 0
212212
Items.Strings = (
213213
'Top (Default)'
@@ -224,9 +224,9 @@ object SimbaGeneralFrame: TSimbaGeneralFrame
224224
AnchorSideBottom.Control = ToolbarPositionComboBox
225225
AnchorSideBottom.Side = asrBottom
226226
Left = 0
227-
Height = 45
228-
Top = 172
229-
Width = 95
227+
Height = 40
228+
Top = 181
229+
Width = 84
230230
Anchors = [akTop, akLeft, akBottom]
231231
Caption = 'Position'
232232
Layout = tlCenter
@@ -238,12 +238,12 @@ object SimbaGeneralFrame: TSimbaGeneralFrame
238238
AnchorSideTop.Side = asrBottom
239239
AnchorSideRight.Control = ToolbarPositionComboBox
240240
AnchorSideRight.Side = asrBottom
241-
Left = 234
242-
Height = 45
243-
Top = 229
244-
Width = 302
241+
Left = 215
242+
Height = 40
243+
Top = 237
244+
Width = 403
245245
Anchors = [akTop, akLeft, akRight]
246-
BorderSpacing.Top = 12
246+
BorderSpacing.Top = 16
247247
MaxValue = 40
248248
TabOrder = 5
249249
OnChange = ToolbarSpacingSpinEditChange
@@ -254,9 +254,9 @@ object SimbaGeneralFrame: TSimbaGeneralFrame
254254
AnchorSideBottom.Control = ToolbarSpacingSpinEdit
255255
AnchorSideBottom.Side = asrBottom
256256
Left = 0
257-
Height = 45
258-
Top = 229
259-
Width = 94
257+
Height = 40
258+
Top = 237
259+
Width = 84
260260
Anchors = [akTop, akLeft, akBottom]
261261
Caption = 'Spacing'
262262
Layout = tlCenter
@@ -269,8 +269,8 @@ object SimbaGeneralFrame: TSimbaGeneralFrame
269269
AnchorSideBottom.Side = asrBottom
270270
Left = 0
271271
Height = 31
272-
Top = 43
273-
Width = 128
272+
Top = 47
273+
Width = 116
274274
Align = alCustom
275275
Anchors = [akTop, akLeft, akBottom]
276276
Caption = 'Image Size'
@@ -286,18 +286,18 @@ object SimbaGeneralFrame: TSimbaGeneralFrame
286286
AnchorSideRight.Side = asrBottom
287287
AnchorSideBottom.Control = ImageSizeLabel
288288
AnchorSideBottom.Side = asrBottom
289-
Left = 234
289+
Left = 215
290290
Height = 31
291-
Top = 43
292-
Width = 869
291+
Top = 47
292+
Width = 1256
293293
Max = 32
294294
Min = 15
295295
Position = 15
296296
OnChange = ImageSizeTrackBarChange
297297
Align = alCustom
298298
Anchors = [akTop, akLeft, akRight]
299-
BorderSpacing.Top = 12
300-
BorderSpacing.Right = 18
299+
BorderSpacing.Top = 16
300+
BorderSpacing.Right = 24
301301
Color = 3487029
302302
ParentColor = False
303303
TabOrder = 6

0 commit comments

Comments
 (0)