mirror of
https://github.com/moparisthebest/Simba
synced 2024-11-25 02:32:19 -05:00
Started on the function list. So far you can drag objects from it into the script, though it just inserts "will implement later" into the script for now...
git-svn-id: http://www.villavu.com/repositories/merlijn/mufasa@317 3f818213-9676-44b0-a9b4-5e4c4e03d09d
This commit is contained in:
parent
fdf4b9ee35
commit
36d0cc2f9c
@ -22,6 +22,8 @@ object ScriptFrame: TScriptFrame
|
|||||||
ParentFont = False
|
ParentFont = False
|
||||||
PopupMenu = Form1.ScriptPopup
|
PopupMenu = Form1.ScriptPopup
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
|
OnDragDrop = SynEditDragDrop
|
||||||
|
OnDragOver = SynEditDragOver
|
||||||
OnKeyDown = SynEditKeyDown
|
OnKeyDown = SynEditKeyDown
|
||||||
Gutter.Width = 57
|
Gutter.Width = 57
|
||||||
Gutter.MouseActions = <
|
Gutter.MouseActions = <
|
||||||
@ -712,7 +714,7 @@ object ScriptFrame: TScriptFrame
|
|||||||
DirectiveAttri.Foreground = clRed
|
DirectiveAttri.Foreground = clRed
|
||||||
DirectiveAttri.Style = [fsBold]
|
DirectiveAttri.Style = [fsBold]
|
||||||
CompilerMode = pcmObjFPC
|
CompilerMode = pcmObjFPC
|
||||||
NestedComments = False
|
NestedComments = True
|
||||||
left = 320
|
left = 320
|
||||||
top = 16
|
top = 16
|
||||||
end
|
end
|
||||||
|
@ -7,8 +7,9 @@ LazarusResources.Add('TScriptFrame','FORMDATA',[
|
|||||||
+'dit'#4'Left'#2#0#6'Height'#3'H'#1#3'Top'#2#0#5'Width'#3#141#1#5'Align'#7#8
|
+'dit'#4'Left'#2#0#6'Height'#3'H'#1#3'Top'#2#0#5'Width'#3#141#1#5'Align'#7#8
|
||||||
+'alClient'#11'Font.Height'#2#243#9'Font.Name'#6#11'Courier New'#10'Font.Pitc'
|
+'alClient'#11'Font.Height'#2#243#9'Font.Name'#6#11'Courier New'#10'Font.Pitc'
|
||||||
+'h'#7#7'fpFixed'#12'Font.Quality'#7#16'fqNonAntialiased'#11'ParentColor'#8#10
|
+'h'#7#7'fpFixed'#12'Font.Quality'#7#16'fqNonAntialiased'#11'ParentColor'#8#10
|
||||||
+'ParentFont'#8#9'PopupMenu'#7#17'Form1.ScriptPopup'#8'TabOrder'#2#0#9'OnKeyD'
|
+'ParentFont'#8#9'PopupMenu'#7#17'Form1.ScriptPopup'#8'TabOrder'#2#0#10'OnDra'
|
||||||
+'own'#7#14'SynEditKeyDown'#12'Gutter.Width'#2'9'#19'Gutter.MouseActions'#14#1
|
+'gDrop'#7#15'SynEditDragDrop'#10'OnDragOver'#7#15'SynEditDragOver'#9'OnKeyDo'
|
||||||
|
+'wn'#7#14'SynEditKeyDown'#12'Gutter.Width'#2'9'#19'Gutter.MouseActions'#14#1
|
||||||
+#5'Shift'#11#0#9'ShiftMask'#11#0#6'Button'#7#6'mbLeft'#10'ClickCount'#7#5'cc'
|
+#5'Shift'#11#0#9'ShiftMask'#11#0#6'Button'#7#6'mbLeft'#10'ClickCount'#7#5'cc'
|
||||||
+'Any'#8'ClickDir'#7#6'cdDown'#7'Command'#2#13#9'MoveCaret'#8#6'Option'#2#0#8
|
+'Any'#8'ClickDir'#7#6'cdDown'#7'Command'#2#13#9'MoveCaret'#8#6'Option'#2#0#8
|
||||||
+'Priority'#2#0#0#1#5'Shift'#11#0#9'ShiftMask'#11#0#6'Button'#7#7'mbRight'#10
|
+'Priority'#2#0#0#1#5'Shift'#11#0#9'ShiftMask'#11#0#6'Button'#7#7'mbRight'#10
|
||||||
@ -64,8 +65,8 @@ LazarusResources.Add('TScriptFrame','FORMDATA',[
|
|||||||
+'7`'#0#1#7'Command'#7#12'ecSetMarker8'#8'ShortCut'#3'8`'#0#1#7'Command'#7#12
|
+'7`'#0#1#7'Command'#7#12'ecSetMarker8'#8'ShortCut'#3'8`'#0#1#7'Command'#7#12
|
||||||
+'ecSetMarker9'#8'ShortCut'#3'9`'#0#1#7'Command'#7#12'EcFoldLevel1'#8'ShortCu'
|
+'ecSetMarker9'#8'ShortCut'#3'9`'#0#1#7'Command'#7#12'EcFoldLevel1'#8'ShortCu'
|
||||||
+'t'#4'1'#160#0#0#0#1#7'Command'#7#12'EcFoldLevel2'#8'ShortCut'#4'2'#160#0#0#0
|
+'t'#4'1'#160#0#0#0#1#7'Command'#7#12'EcFoldLevel2'#8'ShortCut'#4'2'#160#0#0#0
|
||||||
+#1#7'Command'#7#12'EcFoldLevel1'#8'ShortCut'#4'3'#160#0#0#0#1#7'Command'#7#12
|
,#1#7'Command'#7#12'EcFoldLevel1'#8'ShortCut'#4'3'#160#0#0#0#1#7'Command'#7#12
|
||||||
,'EcFoldLevel1'#8'ShortCut'#4'4'#160#0#0#0#1#7'Command'#7#12'EcFoldLevel1'#8
|
+'EcFoldLevel1'#8'ShortCut'#4'4'#160#0#0#0#1#7'Command'#7#12'EcFoldLevel1'#8
|
||||||
+'ShortCut'#4'5'#160#0#0#0#1#7'Command'#7#12'EcFoldLevel6'#8'ShortCut'#4'6'
|
+'ShortCut'#4'5'#160#0#0#0#1#7'Command'#7#12'EcFoldLevel6'#8'ShortCut'#4'6'
|
||||||
+#160#0#0#0#1#7'Command'#7#12'EcFoldLevel7'#8'ShortCut'#4'7'#160#0#0#0#1#7'Co'
|
+#160#0#0#0#1#7'Command'#7#12'EcFoldLevel7'#8'ShortCut'#4'7'#160#0#0#0#1#7'Co'
|
||||||
+'mmand'#7#12'EcFoldLevel8'#8'ShortCut'#4'8'#160#0#0#0#1#7'Command'#7#12'EcFo'
|
+'mmand'#7#12'EcFoldLevel8'#8'ShortCut'#4'8'#160#0#0#0#1#7'Command'#7#12'EcFo'
|
||||||
@ -128,8 +129,8 @@ LazarusResources.Add('TScriptFrame','FORMDATA',[
|
|||||||
+#8'ccSingle'#8'ClickDir'#7#4'cdUp'#7'Command'#2#16#9'MoveCaret'#8#6'Option'#2
|
+#8'ccSingle'#8'ClickDir'#7#4'cdUp'#7'Command'#2#16#9'MoveCaret'#8#6'Option'#2
|
||||||
+#0#8'Priority'#2#0#0#1#5'Shift'#11#0#9'ShiftMask'#11#7'ssShift'#0#6'Button'#7
|
+#0#8'Priority'#2#0#0#1#5'Shift'#11#0#9'ShiftMask'#11#7'ssShift'#0#6'Button'#7
|
||||||
+#8'mbMiddle'#10'ClickCount'#7#5'ccAny'#8'ClickDir'#7#6'cdDown'#7'Command'#2
|
+#8'mbMiddle'#10'ClickCount'#7#5'ccAny'#8'ClickDir'#7#6'cdDown'#7'Command'#2
|
||||||
+#14#9'MoveCaret'#8#6'Option'#2#0#8'Priority'#2#0#0#1#5'Shift'#11#7'ssShift'#0
|
,#14#9'MoveCaret'#8#6'Option'#2#0#8'Priority'#2#0#0#1#5'Shift'#11#7'ssShift'#0
|
||||||
,#9'ShiftMask'#11#7'ssShift'#0#6'Button'#7#8'mbMiddle'#10'ClickCount'#7#5'ccA'
|
+#9'ShiftMask'#11#7'ssShift'#0#6'Button'#7#8'mbMiddle'#10'ClickCount'#7#5'ccA'
|
||||||
+'ny'#8'ClickDir'#7#6'cdDown'#7'Command'#2#14#9'MoveCaret'#8#6'Option'#2#1#8
|
+'ny'#8'ClickDir'#7#6'cdDown'#7'Command'#2#14#9'MoveCaret'#8#6'Option'#2#1#8
|
||||||
+'Priority'#2#0#0#1#5'Shift'#11#0#9'ShiftMask'#11#0#6'Button'#7#6'mbLeft'#10
|
+'Priority'#2#0#0#1#5'Shift'#11#0#9'ShiftMask'#11#0#6'Button'#7#6'mbLeft'#10
|
||||||
+'ClickCount'#7#5'ccAny'#8'ClickDir'#7#6'cdDown'#7'Command'#2#0#9'MoveCaret'#8
|
+'ClickCount'#7#5'ccAny'#8'ClickDir'#7#6'cdDown'#7'Command'#2#0#9'MoveCaret'#8
|
||||||
@ -148,5 +149,5 @@ LazarusResources.Add('TScriptFrame','FORMDATA',[
|
|||||||
+'.Foreground'#7#6'clNavy'#22'StringAttri.Foreground'#7#6'clBlue'#22'SymbolAt'
|
+'.Foreground'#7#6'clNavy'#22'StringAttri.Foreground'#7#6'clBlue'#22'SymbolAt'
|
||||||
+'tri.Foreground'#7#5'clRed'#25'DirectiveAttri.Foreground'#7#5'clRed'#20'Dire'
|
+'tri.Foreground'#7#5'clRed'#25'DirectiveAttri.Foreground'#7#5'clRed'#20'Dire'
|
||||||
+'ctiveAttri.Style'#11#6'fsBold'#0#12'CompilerMode'#7#9'pcmObjFPC'#14'NestedC'
|
+'ctiveAttri.Style'#11#6'fsBold'#0#12'CompilerMode'#7#9'pcmObjFPC'#14'NestedC'
|
||||||
+'omments'#8#4'left'#3'@'#1#3'top'#2#16#0#0#0
|
+'omments'#9#4'left'#3'@'#1#3'top'#2#16#0#0#0
|
||||||
]);
|
]);
|
||||||
|
@ -44,6 +44,9 @@ type
|
|||||||
SynEdit: TSynEdit;
|
SynEdit: TSynEdit;
|
||||||
SynFreePascalSyn1: TSynFreePascalSyn;
|
SynFreePascalSyn1: TSynFreePascalSyn;
|
||||||
procedure SynEditChange(Sender: TObject);
|
procedure SynEditChange(Sender: TObject);
|
||||||
|
procedure SynEditDragDrop(Sender, Source: TObject; X, Y: Integer);
|
||||||
|
procedure SynEditDragOver(Sender, Source: TObject; X, Y: Integer;
|
||||||
|
State: TDragState; var Accept: Boolean);
|
||||||
procedure SynEditKeyDown(Sender: TObject; var Key: Word; Shift: TShiftState
|
procedure SynEditKeyDown(Sender: TObject; var Key: Word; Shift: TShiftState
|
||||||
);
|
);
|
||||||
procedure SynEditProcessCommand(Sender: TObject;
|
procedure SynEditProcessCommand(Sender: TObject;
|
||||||
@ -89,6 +92,22 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TScriptFrame.SynEditDragDrop(Sender, Source: TObject; X, Y: Integer);
|
||||||
|
begin
|
||||||
|
SynEdit.InsertTextAtCaret('will implement later');
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TScriptFrame.SynEditDragOver(Sender, Source: TObject; X, Y: Integer;
|
||||||
|
State: TDragState; var Accept: Boolean);
|
||||||
|
begin
|
||||||
|
Accept := Source = Form1.TreeView1;
|
||||||
|
if(Accept)then
|
||||||
|
begin
|
||||||
|
SynEdit.CaretXY := SynEdit.PixelsToLogicalPos(point(x, y));
|
||||||
|
Form1.ActiveControl := SynEdit;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
procedure TScriptFrame.SynEditKeyDown(Sender: TObject; var Key: Word;
|
procedure TScriptFrame.SynEditKeyDown(Sender: TObject; var Key: Word;
|
||||||
Shift: TShiftState);
|
Shift: TShiftState);
|
||||||
begin
|
begin
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -1,7 +1,7 @@
|
|||||||
object Form1: TForm1
|
object Form1: TForm1
|
||||||
Left = 474
|
Left = 446
|
||||||
Height = 557
|
Height = 557
|
||||||
Top = 246
|
Top = 224
|
||||||
Width = 731
|
Width = 731
|
||||||
ActiveControl = ScriptPanel
|
ActiveControl = ScriptPanel
|
||||||
Caption = 'THA FUKING MUFASA'
|
Caption = 'THA FUKING MUFASA'
|
||||||
@ -167,7 +167,7 @@ object Form1: TForm1
|
|||||||
object StatusBar: TStatusBar
|
object StatusBar: TStatusBar
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 21
|
Height = 21
|
||||||
Top = 536
|
Top = 511
|
||||||
Width = 731
|
Width = 731
|
||||||
Panels = <
|
Panels = <
|
||||||
item
|
item
|
||||||
@ -185,7 +185,7 @@ object Form1: TForm1
|
|||||||
object PanelMemo: TPanel
|
object PanelMemo: TPanel
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 154
|
Height = 154
|
||||||
Top = 382
|
Top = 357
|
||||||
Width = 731
|
Width = 731
|
||||||
Align = alBottom
|
Align = alBottom
|
||||||
ClientHeight = 154
|
ClientHeight = 154
|
||||||
@ -205,28 +205,29 @@ object Form1: TForm1
|
|||||||
Cursor = crVSplit
|
Cursor = crVSplit
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 5
|
Height = 5
|
||||||
Top = 377
|
Top = 352
|
||||||
Width = 731
|
Width = 731
|
||||||
Align = alBottom
|
Align = alBottom
|
||||||
ResizeAnchor = akBottom
|
ResizeAnchor = akBottom
|
||||||
end
|
end
|
||||||
object ScriptPanel: TPanel
|
object ScriptPanel: TPanel
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 353
|
Height = 328
|
||||||
Top = 24
|
Top = 24
|
||||||
Width = 731
|
Width = 731
|
||||||
Align = alClient
|
Align = alClient
|
||||||
BevelOuter = bvNone
|
BevelOuter = bvNone
|
||||||
Caption = 'ScriptPanel'
|
Caption = 'ScriptPanel'
|
||||||
ClientHeight = 353
|
ClientHeight = 328
|
||||||
ClientWidth = 731
|
ClientWidth = 731
|
||||||
TabOrder = 4
|
TabOrder = 4
|
||||||
object PageControl1: TPageControl
|
object PageControl1: TPageControl
|
||||||
Left = 0
|
Left = 144
|
||||||
Height = 318
|
Height = 293
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 731
|
Width = 587
|
||||||
Align = alClient
|
Align = alRight
|
||||||
|
Anchors = [akTop, akLeft, akRight, akBottom]
|
||||||
Images = Mufasa_Image_List
|
Images = Mufasa_Image_List
|
||||||
PopupMenu = TabPopup
|
PopupMenu = TabPopup
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
@ -242,7 +243,7 @@ object Form1: TForm1
|
|||||||
object SearchPanel: TPanel
|
object SearchPanel: TPanel
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 35
|
Height = 35
|
||||||
Top = 318
|
Top = 293
|
||||||
Width = 731
|
Width = 731
|
||||||
Align = alBottom
|
Align = alBottom
|
||||||
BevelOuter = bvSpace
|
BevelOuter = bvSpace
|
||||||
@ -370,6 +371,25 @@ object Form1: TForm1
|
|||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
object TreeView1: TTreeView
|
||||||
|
Left = 0
|
||||||
|
Height = 293
|
||||||
|
Top = 0
|
||||||
|
Width = 141
|
||||||
|
Align = alLeft
|
||||||
|
DefaultItemHeight = 19
|
||||||
|
ReadOnly = True
|
||||||
|
ScrollBars = ssAutoBoth
|
||||||
|
TabOrder = 2
|
||||||
|
OnMouseDown = TreeView1MouseDown
|
||||||
|
Options = [tvoAutoItemHeight, tvoHideSelection, tvoKeepCollapsedNodes, tvoReadOnly, tvoShowButtons, tvoShowLines, tvoShowRoot, tvoToolTips]
|
||||||
|
Items.Data = {
|
||||||
|
F9FFFFFF020001000000FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF020000000000
|
||||||
|
00000005000000436F6C6F72FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF00000000
|
||||||
|
00000000000900000046696E64436F6C6F72FFFFFFFFFFFFFFFFFFFFFFFFFFFF
|
||||||
|
FFFF00000000000000000008000000476574436F6C6F72
|
||||||
|
}
|
||||||
|
end
|
||||||
end
|
end
|
||||||
object MainMenu1: TMainMenu
|
object MainMenu1: TMainMenu
|
||||||
left = 528
|
left = 528
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -179,6 +179,7 @@ type
|
|||||||
ToolButton8: TToolButton;
|
ToolButton8: TToolButton;
|
||||||
TB_Convert: TToolButton;
|
TB_Convert: TToolButton;
|
||||||
MTrayIcon: TTrayIcon;
|
MTrayIcon: TTrayIcon;
|
||||||
|
TreeView1: TTreeView;
|
||||||
procedure ActionClearDebugExecute(Sender: TObject);
|
procedure ActionClearDebugExecute(Sender: TObject);
|
||||||
procedure ActionCloseTabExecute(Sender: TObject);
|
procedure ActionCloseTabExecute(Sender: TObject);
|
||||||
procedure ActionCopyExecute(Sender: TObject);
|
procedure ActionCopyExecute(Sender: TObject);
|
||||||
@ -246,6 +247,8 @@ type
|
|||||||
procedure ProcessDebugStream(Sender: TObject);
|
procedure ProcessDebugStream(Sender: TObject);
|
||||||
procedure ScriptPopupPopup(Sender: TObject);
|
procedure ScriptPopupPopup(Sender: TObject);
|
||||||
procedure SpeedButtonSearchClick(Sender: TObject);
|
procedure SpeedButtonSearchClick(Sender: TObject);
|
||||||
|
procedure TreeView1MouseDown(Sender: TObject; Button: TMouseButton;
|
||||||
|
Shift: TShiftState; X, Y: Integer);
|
||||||
private
|
private
|
||||||
PopupTab : integer;
|
PopupTab : integer;
|
||||||
SearchStart : TPoint;
|
SearchStart : TPoint;
|
||||||
@ -341,6 +344,13 @@ begin
|
|||||||
CloseFindPanel;
|
CloseFindPanel;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TForm1.TreeView1MouseDown(Sender: TObject; Button: TMouseButton;
|
||||||
|
Shift: TShiftState; X, Y: Integer);
|
||||||
|
begin
|
||||||
|
if(Button = mbLeft)then
|
||||||
|
TreeView1.BeginDrag(False, 10); //BeginDrag(False, 10);
|
||||||
|
end;
|
||||||
|
|
||||||
procedure formWriteln( S : String);
|
procedure formWriteln( S : String);
|
||||||
begin
|
begin
|
||||||
writeln('formWriteln: ' + s);
|
writeln('formWriteln: ' + s);
|
||||||
@ -1172,11 +1182,7 @@ var
|
|||||||
Pos: Integer;
|
Pos: Integer;
|
||||||
begin
|
begin
|
||||||
Pos := PageControl1.TabIndexAtClientPos(Point(x,y));
|
Pos := PageControl1.TabIndexAtClientPos(Point(x,y));
|
||||||
if (Pos <> PageControl1.TabIndex) and (Pos <> -1) then
|
Accept := (Pos <> PageControl1.TabIndex) and (Pos <> -1);
|
||||||
PageControl1.DragCursor := crDrag
|
|
||||||
else
|
|
||||||
PageControl1.DragCursor := crNo;
|
|
||||||
Accept := PageControl1.DragCursor = crDrag;
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TForm1.PageControl1MouseDown(Sender: TObject; Button: TMouseButton;
|
procedure TForm1.PageControl1MouseDown(Sender: TObject; Button: TMouseButton;
|
||||||
@ -1378,7 +1384,6 @@ begin
|
|||||||
ScriptFrame := TScriptFrame.Create(Tabsheet);
|
ScriptFrame := TScriptFrame.Create(Tabsheet);
|
||||||
ScriptFrame.Parent := Tabsheet;
|
ScriptFrame.Parent := Tabsheet;
|
||||||
ScriptFrame.Align:= alClient;
|
ScriptFrame.Align:= alClient;
|
||||||
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
constructor TMufasaTab.Create(Page: TPageControl);
|
constructor TMufasaTab.Create(Page: TPageControl);
|
||||||
@ -1389,7 +1394,7 @@ begin
|
|||||||
Tabsheet.PageControl := Page;
|
Tabsheet.PageControl := Page;
|
||||||
ScriptFrame := TScriptFrame.Create(Tabsheet);
|
ScriptFrame := TScriptFrame.Create(Tabsheet);
|
||||||
ScriptFrame.Parent := Tabsheet;
|
ScriptFrame.Parent := Tabsheet;
|
||||||
ScriptFrame.Align:= alClient;
|
ScriptFrame.Align := alClient;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
destructor TMufasaTab.Destroy;
|
destructor TMufasaTab.Destroy;
|
||||||
|
Loading…
Reference in New Issue
Block a user