优化编辑器,快捷键提示
This commit is contained in:
parent
5732a251bf
commit
2442aa265e
|
|
@ -46,20 +46,20 @@ object functionfinder:t_function_finder
|
|||
object btfind:tbtn
|
||||
autosize=true
|
||||
caption="ɸѡ"
|
||||
height=21
|
||||
height=22
|
||||
left=281
|
||||
onclick=btfind_clk
|
||||
top=7
|
||||
width=38
|
||||
width=54
|
||||
end
|
||||
object ck_prev:tcheckbtn
|
||||
autosize=true
|
||||
caption="´ÓÍ·Æ¥Åä"
|
||||
height=21
|
||||
height=22
|
||||
left=370
|
||||
top=7
|
||||
visible=true
|
||||
width=95
|
||||
width=111
|
||||
end
|
||||
end
|
||||
object sbfind:tstatusbar
|
||||
|
|
|
|||
|
|
@ -0,0 +1,65 @@
|
|||
object shortcut_keys_view:t_shortcut_keys_view
|
||||
caption="우쌥숩啞응"
|
||||
font=<
|
||||
height=19
|
||||
width=9
|
||||
escapement=0
|
||||
orientation=0
|
||||
weight=400
|
||||
italic=0
|
||||
underline=0
|
||||
strikeout=0
|
||||
charset=134
|
||||
outprecision=3
|
||||
clipprecision=2
|
||||
quality=1
|
||||
pitchandfamily=49
|
||||
facename="劤芥竟"
|
||||
color=0
|
||||
>
|
||||
|
||||
height=684
|
||||
left=711
|
||||
minmaxbox=false
|
||||
onclose=shortcut_keys_view_close
|
||||
parentfont=false
|
||||
top=459
|
||||
visible=false
|
||||
width=590
|
||||
object panel1:tpanel
|
||||
align=albottom
|
||||
autosize=true
|
||||
caption="panel1"
|
||||
height=34
|
||||
left=0
|
||||
top=611
|
||||
width=574
|
||||
object fokbtn:tbtn
|
||||
autosize=true
|
||||
caption="횅땍"
|
||||
height=22
|
||||
left=242
|
||||
onclick=fokbtn_clk
|
||||
top=6
|
||||
width=54
|
||||
end
|
||||
end
|
||||
object shortcutview:tlistview
|
||||
align=alclient
|
||||
caption="listview1"
|
||||
columns= [<
|
||||
width=200
|
||||
text="우쌥숩"
|
||||
>
|
||||
<
|
||||
width=500
|
||||
text="綱츠"
|
||||
>
|
||||
]
|
||||
height=611
|
||||
left=0
|
||||
parentfont=true
|
||||
top=0
|
||||
width=574
|
||||
end
|
||||
end
|
||||
|
|
@ -0,0 +1,68 @@
|
|||
type t_shortcut_keys_view=class(tdcreateform)
|
||||
uses tslvcl;
|
||||
panel1:tpanel;
|
||||
fokbtn:tbtn;
|
||||
shortcutview:tlistview;
|
||||
function Create(AOwner);override; //构造
|
||||
begin
|
||||
inherited;
|
||||
shortcutview.AppendItems(init_shortcut_keys());
|
||||
end
|
||||
|
||||
function shortcut_keys_view_close(o;e);
|
||||
begin
|
||||
e.skip := true;
|
||||
Visible := false;
|
||||
end
|
||||
|
||||
function fokbtn_clk(o;e);
|
||||
begin
|
||||
Visible := false;
|
||||
end
|
||||
function Recycling();override; //回收变量
|
||||
begin
|
||||
inherited;
|
||||
ci := self.classinfo(); //将成员变量赋值为nil避免循环引用
|
||||
for i,v in ci["members"] do
|
||||
begin
|
||||
if v["const"] then continue;
|
||||
if v["static"] then continue;
|
||||
invoke(self,v["name"],nil);
|
||||
end
|
||||
end
|
||||
function init_shortcut_keys();
|
||||
begin
|
||||
return array(("ctrl+o","打开"),
|
||||
("ctrl+N","新建"),
|
||||
("ctrl+s","保存"),
|
||||
("ctrl+F","查找窗口"),
|
||||
("ctrl+R","替换窗口"),
|
||||
("ctrl+a","全选"),
|
||||
("ctrl+c","拷贝选择"),
|
||||
("ctrl+D","复制被插入当前行"),
|
||||
("ctrl+v","粘贴"),
|
||||
("ctrl+x","剪切选择"),
|
||||
("ctrl+G","定位到行"),
|
||||
("ctrl+L|Y", "删除当前行"),
|
||||
("tab | shift+tab","多行选中时缩进"),
|
||||
("ctrl+/","注释当前选择"),
|
||||
("ctrl+\\","取消当前注释"),
|
||||
("ctrl+U","反撤销"),
|
||||
("ctrl+z","撤销"),
|
||||
("ctrl+tab","切换标签"),
|
||||
("ctrl+J","打开tsl函数查找面板"),
|
||||
("F2","跳转到下一个断点行"),
|
||||
("F5","添加删除断点"),
|
||||
("Alt+F5","将选中字符串转换为大写"),
|
||||
("ctl+F5","将选中字符串转换为小写"),
|
||||
("F3","正向搜索先前搜索的字符"),
|
||||
("ctrl+F3","反向搜索先前搜索的字符"),
|
||||
("ctrl+tab","切换标签页"),
|
||||
("F9","执行当前页的代码"),
|
||||
("ctrl+F9","打开执行代码编辑器"),
|
||||
("F7","显示隐藏日志窗口"),
|
||||
("F1","对于tsl语言查找当前光标所在位置的帮助"),
|
||||
("alt+m","弹出tsl代码地图"));;
|
||||
end
|
||||
|
||||
end
|
||||
|
|
@ -43,9 +43,14 @@ array(
|
|||
"name":"t_function_finder",
|
||||
"type":"form",
|
||||
"dir":""
|
||||
),
|
||||
"t_shortcut_keys_view":(
|
||||
"name":"t_shortcut_keys_view",
|
||||
"type":"form",
|
||||
"dir":""
|
||||
)
|
||||
),
|
||||
"mainform":"textcompclassmgr",
|
||||
"mainform":"t_shortcut_keys_view",
|
||||
"entryscript":"vcldesginer",
|
||||
"commandline":"\"$(TSL_EXE)\" \"$(FULL_CURRENT_PATH)\" -libpath \"$(SEARCH_PATH)\""
|
||||
)
|
||||
|
|
@ -1996,6 +1996,7 @@ type TEditer=class(TCustomcontrol) //
|
|||
CreateAFile();
|
||||
end
|
||||
ffuncfind := new t_function_finder(self);
|
||||
FShortCutshower := new t_shortcut_keys_view(self);
|
||||
end
|
||||
function PopUpAuxiliary();
|
||||
begin
|
||||
|
|
@ -3188,7 +3189,10 @@ type TEditer=class(TCustomcontrol) //
|
|||
end
|
||||
"快捷键说明":
|
||||
begin
|
||||
s := "";
|
||||
if not FShortCutshower.Parent then FShortCutshower.Parent := self;
|
||||
InitShowWndPos(FShortCutshower,"surcut",500,150,true);
|
||||
FShortCutshower.Show();
|
||||
{s := "";
|
||||
s += "ctrl+o 打开\r\n";
|
||||
s += "ctrl+N 新建\r\n";
|
||||
s += "ctrl+s 保存\r\n";
|
||||
|
|
@ -3219,7 +3223,7 @@ type TEditer=class(TCustomcontrol) //
|
|||
s += "F7 显示隐藏日志窗口\r\n";
|
||||
s += "F1 对于tsl语言查找当前光标所在位置的帮助\r\n";
|
||||
s += "alt+m 弹出tsl代码地图\r\n";
|
||||
messageboxa(s,"우쌥숩綱츠",0,self);
|
||||
messageboxa(s,"우쌥숩綱츠",0,self);}
|
||||
end
|
||||
"撤销":
|
||||
begin
|
||||
|
|
@ -3721,9 +3725,9 @@ type TEditer=class(TCustomcontrol) //
|
|||
begin
|
||||
FTslChmHelp.ShowTslLangChm();
|
||||
end
|
||||
function InitShowWndPos(wnd,n,ix,iy); //셕炬놓迦貫零
|
||||
function InitShowWndPos(wnd,n,ix,iy,flg); //셕炬놓迦貫零
|
||||
begin
|
||||
if not FFistShows[n]then
|
||||
if flg or (not FFistShows[n])then
|
||||
begin
|
||||
FFistShows[n]:= true;
|
||||
xy := Clienttoscreen(ix,iy);
|
||||
|
|
@ -4262,6 +4266,7 @@ type TEditer=class(TCustomcontrol) //
|
|||
FListPages;
|
||||
FFindWnd;
|
||||
ffuncfind;
|
||||
FShortCutshower;
|
||||
FFindListWnd;
|
||||
FEchoWnd;
|
||||
FGotoLineWnd;
|
||||
|
|
|
|||
|
|
@ -1004,11 +1004,10 @@ type TDVirutalWindow = class(TCustomControl) //
|
|||
function Create(AOwner);override;
|
||||
begin
|
||||
fminusfileds := array();
|
||||
FWindowFileds := array("left","top","height","width");
|
||||
inherited;
|
||||
width := 30;
|
||||
height := 30;
|
||||
FWindowFileds := array("left","top","height","width");
|
||||
//ParentFont := true;
|
||||
end
|
||||
function paint();override;
|
||||
begin
|
||||
|
|
@ -1569,10 +1568,17 @@ type TGraphicbevelWindow = class(TDVirutalWindow)
|
|||
**}
|
||||
function paint();override;
|
||||
begin
|
||||
cv := canvas;
|
||||
bd := BindComp;
|
||||
if not bd.Parentcolor then
|
||||
begin
|
||||
c := ClientRect;
|
||||
cv.brush.color := bd.color;
|
||||
cv.fillrect(c);
|
||||
end
|
||||
bd.width := width;
|
||||
bd.height := height;
|
||||
bd.canvas.Handle := canvas.Handle;
|
||||
bd.canvas.Handle := cv.Handle;
|
||||
bd.paint();
|
||||
end
|
||||
function FontChanged(o);override;
|
||||
|
|
@ -1596,7 +1602,7 @@ type TGraphicbevelWindow = class(TDVirutalWindow)
|
|||
width := bd.width;
|
||||
height := bd.Height;
|
||||
BindComp := bd;
|
||||
WindowFileds := array("left","top","width","height","color","parentcolor","font","parentfont","visible","align");
|
||||
WindowFileds := array("left","top","width","height","font","parentfont","visible","align");//,"parentcolor"
|
||||
minusfileds := array("caption","popupMenu","action","border","anchors");
|
||||
end
|
||||
function DesigningSizer();override;
|
||||
|
|
|
|||
Binary file not shown.
|
|
@ -1503,8 +1503,8 @@ type tcontrol = class(tcomponent)
|
|||
if ft then
|
||||
begin
|
||||
c := caption;
|
||||
w := ft.Width*(max(2,length(c)))+2;
|
||||
h := ft.Height+2;
|
||||
w := ft.Width*(length(c)+2);
|
||||
h := ft.Height+3;
|
||||
end
|
||||
end
|
||||
protected
|
||||
|
|
|
|||
|
|
@ -574,7 +574,7 @@ type TPanel=class(TScrollingWinControl) //
|
|||
return frclient;
|
||||
end
|
||||
published
|
||||
property borderwidth read fborderwidth write setborderwidth;
|
||||
property borderwidth:natural read fborderwidth write setborderwidth;
|
||||
property bevelinner:tbevelcut read fbevelinner write setbevelinner;
|
||||
property bevelouter:tbevelcut read fbevelouter write setbevelouter;
|
||||
property bevelwidth:integer read fbevelwidth write setbevelwidth;
|
||||
|
|
|
|||
|
|
@ -2426,6 +2426,8 @@ type tcustombevel = class(TGraphicControl)
|
|||
function create(AOwner);
|
||||
begin
|
||||
inherited;
|
||||
Color := clMenu;
|
||||
transparent := false;
|
||||
caption := "";
|
||||
fshape := bsbox;
|
||||
fstyle := bsLowered;
|
||||
|
|
|
|||
BIN
tsleditor.exe
BIN
tsleditor.exe
Binary file not shown.
BIN
tslvcltool.exe
BIN
tslvcltool.exe
Binary file not shown.
Loading…
Reference in New Issue