优化代码--编辑器

This commit is contained in:
2025-03-14 18:27:47 +08:00
parent d295888137
commit fa201dfc76
11 changed files with 93 additions and 26 deletions
+5 -1
View File
@@ -1042,10 +1042,11 @@ type TDVirutalWindow = class(TCustomControl) //
end
public
function Create(AOwner);override;
begin
begin
fminusfileds := array();
FWindowFileds := array("left","top","height","width");
inherited;
ignore_childsizing := true;
width := 30;
height := 30;
end
@@ -1591,6 +1592,7 @@ type TGraphicLabelWindow = class(TDVirutalWindow)
function Create(AOwner);override;
begin
inherited;
ignore_childsizing := false;
Parentcolor := true;
BindComp := new tlabel(self);
width := BindComp.width;
@@ -1635,6 +1637,7 @@ type TGraphicbevelWindow = class(TDVirutalWindow)
function Create(AOwner);override;
begin
inherited;
ignore_childsizing := false;
Border := false;
Parentcolor := true;
bd := new tbevel(self);
@@ -1691,6 +1694,7 @@ type TGraphicsplitterWindow = class(TDVirutalWindow)
function Create(AOwner);override;
begin
inherited;
ignore_childsizing := false;
BindComp := new tsplitter(self);
width := BindComp.width;
height := BindComp.Height;
+16 -6
View File
@@ -608,15 +608,24 @@ type TTslDebuga=class(TCustomControl)
FDebugport := randomfrom(1 -> 600)+20000;
FDebugaddr := '127.0.0.1';
FRuningItem := item;
FCurrentgotoitem := item;
dirs := owner.getlibpathstr();
FCurrentgotoitem := item;
parsercurrentitem(item);
fio := ioFileseparator();
FDebugUsr := 0;
FDebugPwd := 0;
deletefuncacheini();
////////////////////////////////////////////////////
getdebuger(pms,pdir);
exestr := format('"%s" "%s" -DEBUGSERVER -DEBUGLOGIN 0 -WAITATTACH -DEBUGPORT %d -libpath "%s" ',FDebugExe,FRuningfile,FDebugport,(pdir?pdir:dirs));
if not pdir then pdir := owner.getlibpathstr();
if not pdir then pdir := "abc;";
////////////////////////////////////
if pdir then
begin
exestr := format('"%s" "%s" -DEBUGSERVER -DEBUGLOGIN 0 -WAITATTACH -DEBUGPORT %d -libpath "%s" ',FDebugExe,FRuningfile,FDebugport,pdir);
end else
begin
exestr := format('"%s" "%s" -DEBUGSERVER -DEBUGLOGIN 0 -WAITATTACH -DEBUGPORT %d " ',FDebugExe,FRuningfile,FDebugport);
end
exestr += pms;
fremotedbugstart := true;
fscriptbrks := array();
@@ -677,6 +686,7 @@ type TTslDebuga=class(TCustomControl)
function Create(AOwner);
begin
inherited;
init_item_height := 30;
fscriptbrks := array();
//Frundirect := false;
FCmdHistory := array();
@@ -688,14 +698,14 @@ type TTslDebuga=class(TCustomControl)
dbwnd.Align := alClient;
dbwnd.Parent := self;
FStackList := new TListView(self); // new TListBox(self); //new tmemo(self);//
FStackList.ItemHeight := 23;
FStackList.ItemHeight := init_item_height;
FStackList.Columns := array(("text":"line","width":80),
("text":"function","width":250) //,("text":"type","width":70)
);
FStackList.Border := true;
FVaraiblesList := new TGroupGridA(self);
FVaraiblesList.Border := false;
FVaraiblesList.ItemHeight := 23;
FVaraiblesList.ItemHeight := init_item_height;
FVaraiblesList.Columns := array(("text":"name","width":105),
("text":"value","width":135),
("text":"type","width":80)
@@ -703,7 +713,7 @@ type TTslDebuga=class(TCustomControl)
FCommandtext := new TEdit(self);
FCommandtext.autosize := true;
FCommandtext.placeholder := "命令输入框";
FCommandtext.Height := 23;
FCommandtext.Height := init_item_height;
FCommandtext.onkeyup := thisfunction(cmdkeyup);
FShowText := new tmemo(self);
FShowText.ReadOnly := true;