⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 upluginutils.pas

📁 Delphi编写的一个支持语法高亮显示和很多语言的文本编辑器
💻 PAS
字号:
{
+------------------------------------------------------------------------------+
| This is a simple plugin wrapper class.  It only provides one function at the |
| moment but that one function is enough to do a whole lot of things with.     |
+------------------------------------------------------------------------------+
| Function:                                                                    |
+------------------------------------------------------------------------------+
| GetSelDoc - No parameters are required.  Returns the selected document on    |
| the cEdit window if there is one as a TFrmDoc.  With this you can get text,  |
| add text, modify text, etc.  Treat it just like it is in cEdit itself and    |
| your adding code to do something in cEdit.                                   |
+------------------------------------------------------------------------------+

}
unit uPluginUtils;

interface



uses    Windows,
   Messages,
   SysUtils,
   Classes,
   Dialogs,
   Forms,
   uPlugin,
   fDoc,
   fMain,
   dMain,
   synedit;



type
  TGetSelDoc=function:TfrmDoc;
  function GetSelDoc: TfrmDoc;
type
  TSetLang=procedure(strLang: string);
  procedure SetLang(strLang: String);

var AppHost: Tapplication;  

implementation


procedure SetLang(strLang: String);
begin

  TSetLang(TSetLang (GetProcAddress(Application.Handle,'SetLang')))(strLang);
end;


function GetSelDoc: TfrmDoc;
var
  frm: TFrmDoc;
begin

  frm:=TFrmDoc(TGetSelDoc (GetProcAddress(Application.Handle,'GetDoc')));
  if frm <> nil then
    GetSelDoc := frm
  else
    frm := GetSelDoc;
end;
end.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -