Reduce SynEdit dependencies from units. Reorder uses sections to see dependencies better.

git-svn-id: trunk@53727 -
This commit is contained in:
juha 2016-12-20 00:09:10 +00:00
parent 8f632960a6
commit 9c405911fd
26 changed files with 489 additions and 361 deletions

1
.gitattributes vendored
View File

@ -1878,6 +1878,7 @@ components/ideintf/docs/lazideintf.xml svneol=native#text/plain
components/ideintf/docs/objectinspector.xml svneol=native#text/plain
components/ideintf/docs/packageintf.xml svneol=native#text/plain
components/ideintf/docs/projectintf.xml svneol=native#text/plain
components/ideintf/editorsyntaxhighlighterdef.pas svneol=native#text/pascal
components/ideintf/fieldseditor.lfm svneol=native#text/plain
components/ideintf/fieldseditor.pas svneol=native#text/pascal
components/ideintf/fieldslist.lfm svneol=native#text/plain

View File

@ -0,0 +1,64 @@
unit EditorSyntaxHighlighterDef;
{$mode objfpc}{$H+}
interface
uses
Classes, SysUtils;
type
TLazSyntaxHighlighter =
( lshNone, lshText, lshFreePascal, lshDelphi, lshLFM, lshXML, lshHTML,
lshCPP, lshPerl, lshJava, lshBash, lshPython, lshPHP, lshSQL, lshJScript,
lshDiff, lshBat, lshIni, lshPo, lshPike
);
const
LazSyntaxHighlighterNames: array[TLazSyntaxHighlighter] of String =
( 'None',
'Text',
'FreePascal',
'Delphi',
'LFM',
'XML',
'HTML',
'C++',
'Perl',
'Java',
'Bash',
'Python',
'PHP',
'SQL',
'JScript',
'Diff',
'Bat',
'Ini',
'PO',
'Pike'
);
function GetSyntaxHighlighterCaption(h: TLazSyntaxHighlighter): string;
function StrToLazSyntaxHighlighter(const s: String): TLazSyntaxHighlighter;
implementation
function GetSyntaxHighlighterCaption(h: TLazSyntaxHighlighter): string;
begin
if h=lshFreePascal then
Result:='Free Pascal'
else
Result:=LazSyntaxHighlighterNames[h];
end;
function StrToLazSyntaxHighlighter(const s: String): TLazSyntaxHighlighter;
begin
for Result := Low(TLazSyntaxHighlighter) to High(TLazSyntaxHighlighter) do
if (CompareText(s, LazSyntaxHighlighterNames[Result]) = 0) then
exit;
Result := lshFreePascal;
end;
end.

View File

@ -20,7 +20,7 @@
<Description Value="IDEIntf - the interface units for the Lazarus IDE"/>
<License Value="Modified LPGL2"/>
<Version Major="1"/>
<Files Count="80">
<Files Count="81">
<Item1>
<Filename Value="actionseditor.pas"/>
<UnitName Value="ActionsEditor"/>
@ -90,258 +90,262 @@
<UnitName Value="DBPropEdits"/>
</Item17>
<Item18>
<Filename Value="fieldseditor.pas"/>
<UnitName Value="fieldseditor"/>
<Filename Value="editorsyntaxhighlighterdef.pas"/>
<UnitName Value="EditorSyntaxHighlighterDef"/>
</Item18>
<Item19>
<Filename Value="fieldseditor.lfm"/>
<Type Value="LFM"/>
<Filename Value="fieldseditor.pas"/>
<UnitName Value="fieldseditor"/>
</Item19>
<Item20>
<Filename Value="fieldslist.pas"/>
<UnitName Value="fieldslist"/>
<Filename Value="fieldseditor.lfm"/>
<Type Value="LFM"/>
</Item20>
<Item21>
<Filename Value="fieldslist.lfm"/>
<Type Value="LFM"/>
<Filename Value="fieldslist.pas"/>
<UnitName Value="fieldslist"/>
</Item21>
<Item22>
<Filename Value="filefilterpropeditor.pas"/>
<UnitName Value="FileFilterPropEditor"/>
<Filename Value="fieldslist.lfm"/>
<Type Value="LFM"/>
</Item22>
<Item23>
<Filename Value="filefilterpropeditor.lfm"/>
<Type Value="LFM"/>
<Filename Value="filefilterpropeditor.pas"/>
<UnitName Value="FileFilterPropEditor"/>
</Item23>
<Item24>
<Filename Value="formeditingintf.pas"/>
<UnitName Value="FormEditingIntf"/>
<Filename Value="filefilterpropeditor.lfm"/>
<Type Value="LFM"/>
</Item24>
<Item25>
<Filename Value="frmselectprops.pas"/>
<UnitName Value="frmSelectProps"/>
<Filename Value="formeditingintf.pas"/>
<UnitName Value="FormEditingIntf"/>
</Item25>
<Item26>
<Filename Value="frmselectprops.lfm"/>
<Type Value="LFM"/>
<Filename Value="frmselectprops.pas"/>
<UnitName Value="frmSelectProps"/>
</Item26>
<Item27>
<Filename Value="graphicpropedit.pas"/>
<UnitName Value="GraphicPropEdit"/>
<Filename Value="frmselectprops.lfm"/>
<Type Value="LFM"/>
</Item27>
<Item28>
<Filename Value="graphicpropedit.lfm"/>
<Type Value="LFM"/>
<Filename Value="graphicpropedit.pas"/>
<UnitName Value="GraphicPropEdit"/>
</Item28>
<Item29>
<Filename Value="graphpropedits.pas"/>
<UnitName Value="GraphPropEdits"/>
<Filename Value="graphicpropedit.lfm"/>
<Type Value="LFM"/>
</Item29>
<Item30>
<Filename Value="headercontrolpropedit.pp"/>
<UnitName Value="HeaderControlPropEdit"/>
<Filename Value="graphpropedits.pas"/>
<UnitName Value="GraphPropEdits"/>
</Item30>
<Item31>
<Filename Value="helpfpdoc.pas"/>
<UnitName Value="HelpFPDoc"/>
<Filename Value="headercontrolpropedit.pp"/>
<UnitName Value="HeaderControlPropEdit"/>
</Item31>
<Item32>
<Filename Value="idecommands.pas"/>
<UnitName Value="IDECommands"/>
<Filename Value="helpfpdoc.pas"/>
<UnitName Value="HelpFPDoc"/>
</Item32>
<Item33>
<Filename Value="idedialogs.pas"/>
<UnitName Value="IDEDialogs"/>
<Filename Value="idecommands.pas"/>
<UnitName Value="IDECommands"/>
</Item33>
<Item34>
<Filename Value="ideexterntoolintf.pas"/>
<UnitName Value="IDEExternToolIntf"/>
<Filename Value="idedialogs.pas"/>
<UnitName Value="IDEDialogs"/>
</Item34>
<Item35>
<Filename Value="idehelpintf.pas"/>
<UnitName Value="IDEHelpIntf"/>
<Filename Value="ideexterntoolintf.pas"/>
<UnitName Value="IDEExternToolIntf"/>
</Item35>
<Item36>
<Filename Value="ideimagesintf.pas"/>
<UnitName Value="IDEImagesIntf"/>
<Filename Value="idehelpintf.pas"/>
<UnitName Value="IDEHelpIntf"/>
</Item36>
<Item37>
<Filename Value="idemsgintf.pas"/>
<UnitName Value="IDEMsgIntf"/>
<Filename Value="ideimagesintf.pas"/>
<UnitName Value="IDEImagesIntf"/>
</Item37>
<Item38>
<Filename Value="ideoptionsintf.pas"/>
<UnitName Value="IDEOptionsIntf"/>
<Filename Value="idemsgintf.pas"/>
<UnitName Value="IDEMsgIntf"/>
</Item38>
<Item39>
<Filename Value="idetextconverter.pas"/>
<UnitName Value="IDETextConverter"/>
<Filename Value="ideoptionsintf.pas"/>
<UnitName Value="IDEOptionsIntf"/>
</Item39>
<Item40>
<Filename Value="ideutils.pas"/>
<UnitName Value="IDEUtils"/>
<Filename Value="idetextconverter.pas"/>
<UnitName Value="IDETextConverter"/>
</Item40>
<Item41>
<Filename Value="ideutils.pas"/>
<UnitName Value="IDEUtils"/>
</Item41>
<Item42>
<Filename Value="idewindowintf.pas"/>
<HasRegisterProc Value="True"/>
<UnitName Value="IDEWindowIntf"/>
</Item41>
<Item42>
<Filename Value="imagelisteditor.pp"/>
<UnitName Value="ImageListEditor"/>
</Item42>
<Item43>
<Filename Value="imagelisteditor.lfm"/>
<Type Value="LFM"/>
<Filename Value="imagelisteditor.pp"/>
<UnitName Value="ImageListEditor"/>
</Item43>
<Item44>
<Filename Value="keyvalpropeditdlg.pas"/>
<UnitName Value="KeyValPropEditDlg"/>
<Filename Value="imagelisteditor.lfm"/>
<Type Value="LFM"/>
</Item44>
<Item45>
<Filename Value="keyvalpropeditdlg.lfm"/>
<Type Value="LFM"/>
<Filename Value="keyvalpropeditdlg.pas"/>
<UnitName Value="KeyValPropEditDlg"/>
</Item45>
<Item46>
<Filename Value="lazideintf.pas"/>
<UnitName Value="LazIDEIntf"/>
<Filename Value="keyvalpropeditdlg.lfm"/>
<Type Value="LFM"/>
</Item46>
<Item47>
<Filename Value="lazstringgridedit.pas"/>
<UnitName Value="LazStringGridEdit"/>
<Filename Value="lazideintf.pas"/>
<UnitName Value="LazIDEIntf"/>
</Item47>
<Item48>
<Filename Value="lazstringgridedit.lfm"/>
<Type Value="LFM"/>
<Filename Value="lazstringgridedit.pas"/>
<UnitName Value="LazStringGridEdit"/>
</Item48>
<Item49>
<Filename Value="listviewpropedit.pp"/>
<UnitName Value="ListViewPropEdit"/>
<Filename Value="lazstringgridedit.lfm"/>
<Type Value="LFM"/>
</Item49>
<Item50>
<Filename Value="listviewpropedit.lfm"/>
<Type Value="LFM"/>
<Filename Value="listviewpropedit.pp"/>
<UnitName Value="ListViewPropEdit"/>
</Item50>
<Item51>
<Filename Value="macrodefintf.pas"/>
<UnitName Value="MacroDefIntf"/>
<Filename Value="listviewpropedit.lfm"/>
<Type Value="LFM"/>
</Item51>
<Item52>
<Filename Value="macrointf.pas"/>
<UnitName Value="MacroIntf"/>
<Filename Value="macrodefintf.pas"/>
<UnitName Value="MacroDefIntf"/>
</Item52>
<Item53>
<Filename Value="maskpropedit.pas"/>
<UnitName Value="MaskPropEdit"/>
<Filename Value="macrointf.pas"/>
<UnitName Value="MacroIntf"/>
</Item53>
<Item54>
<Filename Value="maskpropedit.lfm"/>
<Type Value="LFM"/>
<Filename Value="maskpropedit.pas"/>
<UnitName Value="MaskPropEdit"/>
</Item54>
<Item55>
<Filename Value="menuintf.pas"/>
<UnitName Value="MenuIntf"/>
<Filename Value="maskpropedit.lfm"/>
<Type Value="LFM"/>
</Item55>
<Item56>
<Filename Value="newfield.pas"/>
<UnitName Value="NewField"/>
<Filename Value="menuintf.pas"/>
<UnitName Value="MenuIntf"/>
</Item56>
<Item57>
<Filename Value="newfield.lfm"/>
<Type Value="LFM"/>
<Filename Value="newfield.pas"/>
<UnitName Value="NewField"/>
</Item57>
<Item58>
<Filename Value="newitemintf.pas"/>
<UnitName Value="NewItemIntf"/>
<Filename Value="newfield.lfm"/>
<Type Value="LFM"/>
</Item58>
<Item59>
<Filename Value="objectinspector.pp"/>
<UnitName Value="ObjectInspector"/>
<Filename Value="newitemintf.pas"/>
<UnitName Value="NewItemIntf"/>
</Item59>
<Item60>
<Filename Value="objectinspector.lfm"/>
<Type Value="LFM"/>
<Filename Value="objectinspector.pp"/>
<UnitName Value="ObjectInspector"/>
</Item60>
<Item61>
<Filename Value="objinspstrconsts.pas"/>
<UnitName Value="ObjInspStrConsts"/>
<Filename Value="objectinspector.lfm"/>
<Type Value="LFM"/>
</Item61>
<Item62>
<Filename Value="oifavoriteproperties.pas"/>
<UnitName Value="OIFavoriteProperties"/>
<Filename Value="objinspstrconsts.pas"/>
<UnitName Value="ObjInspStrConsts"/>
</Item62>
<Item63>
<Filename Value="packageintf.pas"/>
<UnitName Value="PackageIntf"/>
<Filename Value="oifavoriteproperties.pas"/>
<UnitName Value="OIFavoriteProperties"/>
</Item63>
<Item64>
<Filename Value="projectintf.pas"/>
<UnitName Value="ProjectIntf"/>
<Filename Value="packageintf.pas"/>
<UnitName Value="PackageIntf"/>
</Item64>
<Item65>
<Filename Value="projectresourcesintf.pas"/>
<UnitName Value="ProjectResourcesIntf"/>
<Filename Value="projectintf.pas"/>
<UnitName Value="ProjectIntf"/>
</Item65>
<Item66>
<Filename Value="propedits.pp"/>
<UnitName Value="PropEdits"/>
<Filename Value="projectresourcesintf.pas"/>
<UnitName Value="ProjectResourcesIntf"/>
</Item66>
<Item67>
<Filename Value="propeditutils.pp"/>
<UnitName Value="PropEditUtils"/>
<Filename Value="propedits.pp"/>
<UnitName Value="PropEdits"/>
</Item67>
<Item68>
<Filename Value="srceditorintf.pas"/>
<UnitName Value="SrcEditorIntf"/>
<Filename Value="propeditutils.pp"/>
<UnitName Value="PropEditUtils"/>
</Item68>
<Item69>
<Filename Value="statusbarpropedit.pp"/>
<UnitName Value="StatusBarPropEdit"/>
<Filename Value="srceditorintf.pas"/>
<UnitName Value="SrcEditorIntf"/>
</Item69>
<Item70>
<Filename Value="stringspropeditdlg.pas"/>
<UnitName Value="StringsPropEditDlg"/>
<Filename Value="statusbarpropedit.pp"/>
<UnitName Value="StatusBarPropEdit"/>
</Item70>
<Item71>
<Filename Value="stringspropeditdlg.lfm"/>
<Type Value="LFM"/>
<Filename Value="stringspropeditdlg.pas"/>
<UnitName Value="StringsPropEditDlg"/>
</Item71>
<Item72>
<Filename Value="texttools.pas"/>
<UnitName Value="TextTools"/>
<Filename Value="stringspropeditdlg.lfm"/>
<Type Value="LFM"/>
</Item72>
<Item73>
<Filename Value="treeviewpropedit.pas"/>
<UnitName Value="TreeViewPropEdit"/>
<Filename Value="texttools.pas"/>
<UnitName Value="TextTools"/>
</Item73>
<Item74>
<Filename Value="treeviewpropedit.lfm"/>
<Type Value="LFM"/>
<Filename Value="treeviewpropedit.pas"/>
<UnitName Value="TreeViewPropEdit"/>
</Item74>
<Item75>
<Filename Value="unitresources.pas"/>
<UnitName Value="UnitResources"/>
<Filename Value="treeviewpropedit.lfm"/>
<Type Value="LFM"/>
</Item75>
<Item76>
<Filename Value="projpackintf.pas"/>
<UnitName Value="ProjPackIntf"/>
<Filename Value="unitresources.pas"/>
<UnitName Value="UnitResources"/>
</Item76>
<Item77>
<Filename Value="dbgridcolumnspropeditform.pas"/>
<UnitName Value="DBGridColumnsPropEditForm"/>
<Filename Value="projpackintf.pas"/>
<UnitName Value="ProjPackIntf"/>
</Item77>
<Item78>
<Filename Value="toolbarintf.pas"/>
<UnitName Value="ToolBarIntf"/>
<Filename Value="dbgridcolumnspropeditform.pas"/>
<UnitName Value="DBGridColumnsPropEditForm"/>
</Item78>
<Item79>
<Filename Value="changeparentdlg.pas"/>
<UnitName Value="ChangeParentDlg"/>
<Filename Value="toolbarintf.pas"/>
<UnitName Value="ToolBarIntf"/>
</Item79>
<Item80>
<Filename Value="changeparentdlg.pas"/>
<UnitName Value="ChangeParentDlg"/>
</Item80>
<Item81>
<Filename Value="changeparentdlg.lfm"/>
<Type Value="LFM"/>
</Item80>
</Item81>
</Files>
<LazDoc Paths="docs"/>
<i18n>

View File

@ -10,18 +10,19 @@ interface
uses
ActionsEditor, ActionsEditorStd, BaseIDEIntf, CheckGroupEditorDlg,
CheckListboxEditorDlg, CollectionPropEditForm, ColumnDlg, ComponentEditors,
ComponentReg, ComponentTreeView, CompOptsIntf, DBPropEdits, fieldseditor,
fieldslist, FileFilterPropEditor, FormEditingIntf, frmSelectProps,
GraphicPropEdit, GraphPropEdits, HeaderControlPropEdit, HelpFPDoc,
IDECommands, IDEDialogs, IDEExternToolIntf, IDEHelpIntf, IDEImagesIntf,
IDEMsgIntf, IDEOptionsIntf, IDETextConverter, IDEUtils, IDEWindowIntf,
ImageListEditor, KeyValPropEditDlg, LazIDEIntf, LazStringGridEdit,
ListViewPropEdit, MacroDefIntf, MacroIntf, MaskPropEdit, MenuIntf, NewField,
NewItemIntf, ObjectInspector, ObjInspStrConsts, OIFavoriteProperties,
PackageIntf, ProjectIntf, ProjectResourcesIntf, PropEdits, PropEditUtils,
SrcEditorIntf, StatusBarPropEdit, StringsPropEditDlg, TextTools,
TreeViewPropEdit, UnitResources, ProjPackIntf, DBGridColumnsPropEditForm,
ToolBarIntf, ChangeParentDlg, LazarusPackageIntf;
ComponentReg, ComponentTreeView, CompOptsIntf, DBPropEdits,
EditorSyntaxHighlighterDef, fieldseditor, fieldslist, FileFilterPropEditor,
FormEditingIntf, frmSelectProps, GraphicPropEdit, GraphPropEdits,
HeaderControlPropEdit, HelpFPDoc, IDECommands, IDEDialogs,
IDEExternToolIntf, IDEHelpIntf, IDEImagesIntf, IDEMsgIntf, IDEOptionsIntf,
IDETextConverter, IDEUtils, IDEWindowIntf, ImageListEditor,
KeyValPropEditDlg, LazIDEIntf, LazStringGridEdit, ListViewPropEdit,
MacroDefIntf, MacroIntf, MaskPropEdit, MenuIntf, NewField, NewItemIntf,
ObjectInspector, ObjInspStrConsts, OIFavoriteProperties, PackageIntf,
ProjectIntf, ProjectResourcesIntf, PropEdits, PropEditUtils, SrcEditorIntf,
StatusBarPropEdit, StringsPropEditDlg, TextTools, TreeViewPropEdit,
UnitResources, ProjPackIntf, DBGridColumnsPropEditForm, ToolBarIntf,
ChangeParentDlg, LazarusPackageIntf;
implementation

View File

@ -25,8 +25,13 @@ unit IDEOptionsIntf;
interface
uses
Classes, SysUtils, LCLProc, Controls, Buttons, Forms, StdCtrls, Graphics,
ComCtrls, Grids, Laz2_XMLCfg;
Classes, SysUtils,
// LCL
LCLProc, Controls, Buttons, Forms, StdCtrls, Graphics, ComCtrls, Grids,
// LazUtils
Laz2_XMLCfg,
// IdeIntf
EditorSyntaxHighlighterDef;
const
NoParent = -1;
@ -157,6 +162,7 @@ type
public
// read-only access to options needed by external packages.
// feel free to extend when needed
function ExtensionToLazSyntaxHighlighter(Ext: String): TLazSyntaxHighlighter; virtual; abstract;
property TabPosition: TTabPosition read GetTabPosition;
end;

View File

@ -39,9 +39,10 @@ uses
// LazUtils
LConvEncoding, FileUtil, LazFileUtils, LazUTF8, LazUTF8Classes,
// IDEIntf
ComponentReg, LazIDEIntf, PackageIntf, ProjectIntf, IDEDialogs, IDEExternToolIntf,
ComponentReg, IDEDialogs,
LazIDEIntf, PackageIntf, ProjectIntf, IDEExternToolIntf, IDEOptionsIntf,
// IDE
IDEProcs, DialogProcs, EditorOptions, CompilerOptions,
IDEProcs, DialogProcs, CompilerOptions,
ProjPackBase, Project, ProjectDefs, PackageDefs, PackageSystem, PackageEditor,
BasePkgManager, LazarusIDEStrConsts,
// Converter
@ -1514,8 +1515,9 @@ begin
if LazProject.MainUnitInfo=nil then begin
// add .lpr file to project as main unit
MainUnitInfo:=TUnitInfo.Create(fMainUnitConverter.fPascalBuffer);
Assert(Assigned(IDEEditorOptions), 'TConvertDelphiProject.CreateMainSourceFile: IDEEditorOptions is Nil.');
MainUnitInfo.DefaultSyntaxHighlighter:=
ExtensionToLazSyntaxHighlighter(fMainUnitConverter.LazFileExt);
IDEEditorOptions.ExtensionToLazSyntaxHighlighter(fMainUnitConverter.LazFileExt);
MainUnitInfo.IsPartOfProject:=true;
LazProject.AddFile(MainUnitInfo,false);
LazProject.MainFileID:=0;

View File

@ -40,10 +40,11 @@ interface
uses
// RTL, FCL
Classes, SysUtils, resource,
Classes, SysUtils, typinfo, resource,
// LCL
Controls, ExtCtrls, Graphics, LCLProc, FileUtil, Laz2_XMLCfg, lazutf8classes,
LazClasses, LazFileUtils, LResources, Forms, Dialogs, ComCtrls, LCLType, LazUTF8,
Graphics, LCLProc, LResources, Forms, Dialogs, ComCtrls, LCLType,
// LazUtils
FileUtil, LazFileUtils, LazUTF8, LazClasses, LazUTF8Classes, Laz2_XMLCfg,
// Synedit
SynEdit, SynEditAutoComplete, SynEditKeyCmds, SynEditTypes,
SynEditMiscClasses, SynBeautifier, SynEditTextTrimmer, SynEditMouseCmds,
@ -63,9 +64,9 @@ uses
// codetools
LinkScanner, CodeToolManager,
// IDEIntf
IDECommands, SrcEditorIntf, IDEOptionsIntf, IDEDialogs,
IDECommands, SrcEditorIntf, IDEOptionsIntf, IDEDialogs, EditorSyntaxHighlighterDef,
// IDE
SourceMarks, LazarusIDEStrConsts, IDEProcs, KeyMapping, LazConf, typinfo;
SourceMarks, LazarusIDEStrConsts, IDEProcs, KeyMapping, LazConf;
const
DefaultCompletionLongLineHintType = sclpExtendRightOnly;
@ -83,11 +84,6 @@ type
TLazSynPluginSyncroEditForm = class(TForm) end;
TLazSynPluginSyncroEditFormOff = class(TForm) end;
TLazSyntaxHighlighter =
(lshNone, lshText, lshFreePascal, lshDelphi, lshLFM, lshXML, lshHTML,
lshCPP, lshPerl, lshJava, lshBash, lshPython, lshPHP, lshSQL, lshJScript,
lshDiff, lshBat, lshIni, lshPo, lshPike);
TColorSchemeAttributeFeature =
( hafBackColor, hafForeColor, hafFrameColor, hafAlpha, hafPrior,
hafStyle, hafStyleMask,
@ -700,8 +696,7 @@ type
DefaultFileExtensions: string;
ColorScheme: String;
SampleSource: String;
AddAttrSampleLines: array[TAdditionalHilightAttribute] of
Integer; // first line = 1
AddAttrSampleLines: array[TAdditionalHilightAttribute] of Integer; // first line = 1
MappedAttributes: TStringList; // map attributes to pascal
DefaultCommentType: TCommentType;
CaretXY: TPoint;
@ -727,8 +722,7 @@ type
function FindByType(AType: TLazSyntaxHighlighter): Integer;
function GetDefaultFilextension(AType: TLazSyntaxHighlighter): String;
function GetInfoByType(AType: TLazSyntaxHighlighter): TEditOptLanguageInfo;
property Items[Index: Integer]: TEditOptLanguageInfo read GetInfos;
default;
property Items[Index: Integer]: TEditOptLanguageInfo read GetInfos; default;
end;
TEditorOptions = class;
@ -1459,6 +1453,7 @@ type
procedure GetSynEditPreviewSettings(APreviewEditor: TObject);
procedure ApplyFontSettingsTo(ASynEdit: TSynEdit);
function ExtensionToLazSyntaxHighlighter(Ext: String): TLazSyntaxHighlighter; override;
function CreateSyn(LazSynHilighter: TLazSyntaxHighlighter): TSrcIDEHighlighter;
function ReadColorScheme(const LanguageName: String): String;
function ReadPascalColorScheme: String;
@ -1693,40 +1688,11 @@ type
property StringBreakPrefix: String read FStringBreakPrefix write FStringBreakPrefix;
end;
const
LazSyntaxHighlighterNames: array[TLazSyntaxHighlighter] of String = (
'None',
'Text',
'FreePascal',
'Delphi',
'LFM',
'XML',
'HTML',
'C++',
'Perl',
'Java',
'Bash',
'Python',
'PHP',
'SQL',
'JScript',
'Diff',
'Bat',
'Ini',
'PO',
'Pike'
);
var
EditorOpts: TEditorOptions;
function StrToLazSyntaxHighlighter(const s: String): TLazSyntaxHighlighter;
function ExtensionToLazSyntaxHighlighter(Ext: String): TLazSyntaxHighlighter;
function FilenameToLazSyntaxHighlighter(Filename: String): TLazSyntaxHighlighter;
procedure RepairEditorFontSize(var FontSize: integer);
function GetSyntaxHighlighterCaption(h: TLazSyntaxHighlighter): string;
function BuildBorlandDCIFile(ACustomSynAutoComplete: TCustomSynAutoComplete): Boolean;
function ColorSchemeFactory: TColorSchemeFactory;
function UserSchemeDirectory(CreateIfNotExists: Boolean = False): String;
@ -2239,74 +2205,9 @@ begin
FontSize := SynDefaultFontSize;
end;
function StrToLazSyntaxHighlighter(const s: String): TLazSyntaxHighlighter;
begin
for Result := Low(TLazSyntaxHighlighter) to High(TLazSyntaxHighlighter) do
if (CompareText(s, LazSyntaxHighlighterNames[Result]) = 0) then
exit;
Result := lshFreePascal;
end;
function ExtensionToLazSyntaxHighlighter(Ext: String): TLazSyntaxHighlighter;
var
s, CurExt: String;
LangID, StartPos, EndPos: Integer;
begin
Result := lshNone;
if (Ext = '') or (Ext = '.') or (EditorOpts.HighlighterList = Nil) then
exit;
Ext := lowercase(Ext);
if (Ext[1] = '.') then
Ext := copy(Ext, 2, length(Ext) - 1);
LangID := 0;
while LangID < EditorOpts.HighlighterList.Count do
begin
s := EditorOpts.HighlighterList[LangID].FileExtensions;
StartPos := 1;
while StartPos <= length(s) do
begin
Endpos := StartPos;
while (EndPos <= length(s)) and (s[EndPos] <> ';') do
inc(EndPos);
CurExt := copy(s, Startpos, EndPos - StartPos);
if (CurExt <> '') and (CurExt[1] = '.') then
CurExt := copy(CurExt, 2, length(CurExt) - 1);
if lowercase(CurExt) = Ext then
begin
Result := EditorOpts.HighlighterList[LangID].TheType;
exit;
end;
Startpos := EndPos + 1;
end;
inc(LangID);
end;
end;
function FilenameToLazSyntaxHighlighter(Filename: String): TLazSyntaxHighlighter;
var
CompilerMode: TCompilerMode;
begin
Result:=ExtensionToLazSyntaxHighlighter(ExtractFileExt(Filename));
if Result in [lshFreePascal,lshDelphi] then begin
CompilerMode:=CodeToolBoss.GetCompilerModeForDirectory(ExtractFilePath(Filename));
if CompilerMode in [cmDELPHI,cmTP] then
Result:=lshDelphi
else
Result:=lshFreePascal;
end;
end;
const
EditOptsConfFileName = 'editoroptions.xml';
function GetSyntaxHighlighterCaption(h: TLazSyntaxHighlighter): string;
begin
if h=lshFreePascal then
Result:='Free Pascal'
else
Result:=LazSyntaxHighlighterNames[h];
end;
function BuildBorlandDCIFile(
ACustomSynAutoComplete: TCustomSynAutoComplete): Boolean;
// returns if something has changed
@ -2578,7 +2479,6 @@ end;
constructor TEditOptLanguageInfo.Create;
begin
inherited Create;
end;
destructor TEditOptLanguageInfo.Destroy;
@ -5601,6 +5501,41 @@ begin
ASynEdit.Font.Quality := fqDefault;
end;
function TEditorOptions.ExtensionToLazSyntaxHighlighter(Ext: String): TLazSyntaxHighlighter;
var
s, CurExt: String;
LangID, StartPos, EndPos: Integer;
begin
Result := lshNone;
if (Ext = '') or (Ext = '.') or (HighlighterList = Nil) then
exit;
Ext := lowercase(Ext);
if (Ext[1] = '.') then
Ext := copy(Ext, 2, length(Ext) - 1);
LangID := 0;
while LangID < HighlighterList.Count do
begin
s := HighlighterList[LangID].FileExtensions;
StartPos := 1;
while StartPos <= length(s) do
begin
Endpos := StartPos;
while (EndPos <= length(s)) and (s[EndPos] <> ';') do
inc(EndPos);
CurExt := copy(s, Startpos, EndPos - StartPos);
if (CurExt <> '') and (CurExt[1] = '.') then
CurExt := copy(CurExt, 2, length(CurExt) - 1);
if lowercase(CurExt) = Ext then
begin
Result := HighlighterList[LangID].TheType;
exit;
end;
Startpos := EndPos + 1;
end;
inc(LangID);
end;
end;
procedure TEditorOptions.GetSynEditSettings(ASynEdit: TSynEdit;
SimilarEdit: TSynEdit);
// read synedit settings from config file

View File

@ -41,11 +41,17 @@ uses
{$IFDEF IDE_MEM_CHECK}
MemCheck,
{$ENDIF}
Classes, SysUtils, contnrs, FileUtil, LazUTF8, LCLType, Controls, Forms, Buttons,
StdCtrls, Dialogs, ExtCtrls, LCLProc, ButtonPanel, EditBtn,
IDEExternToolIntf, IDEHelpIntf, PropEdits, IDEDialogs, IDECommands,
FileProcs, LazFileUtils, TransferMacros, LazarusIDEStrConsts, EnvironmentOpts,
KeyMapping, IDEProcs, LazConfigStorage, IDEUtils;
Classes, SysUtils, contnrs,
// LCL
LCLType, Controls, Forms, StdCtrls, Dialogs, LCLProc, ButtonPanel, EditBtn,
// LazUtils
FileUtil, LazFileUtils, LazUTF8, LazConfigStorage,
// Codetools
FileProcs,
// IdeIntf
IDEExternToolIntf, IDEHelpIntf, PropEdits, IDEDialogs, IDECommands, IDEUtils,
// IDE
TransferMacros, LazarusIDEStrConsts, EnvironmentOpts, KeyMapping;
const
ExternalToolOptionsVersion = 3;
@ -130,11 +136,9 @@ type
function Run(Index: integer; {%H-}ShowAbort: boolean): TModalResult;
// load/save
function Load(Config: TConfigStorage): TModalResult;
function Load(Config: TConfigStorage; const Path: string): TModalResult;
override;
function Load(Config: TConfigStorage; const Path: string): TModalResult; override;
function Save(Config: TConfigStorage): TModalResult;
function Save(Config: TConfigStorage; const Path: string): TModalResult;
override;
function Save(Config: TConfigStorage; const Path: string): TModalResult; override;
procedure LoadShortCuts(KeyCommandRelationList: TKeyCommandRelationList);
procedure SaveShortCuts(KeyCommandRelationList: TKeyCommandRelationList);
end;

View File

@ -25,9 +25,17 @@ unit editor_codefolding_options;
interface
uses
Classes, SysUtils, FileUtil, Forms, StdCtrls, ExtCtrls, Graphics,
LCLType, EditorOptions, LazarusIDEStrConsts, IDEOptionsIntf, Controls,
SynEditHighlighter, SynEditHighlighterFoldBase, CheckLst, Buttons;
Classes, SysUtils,
// LCL
LCLType, Forms, StdCtrls, ExtCtrls, Graphics, Controls, CheckLst, Buttons,
// LazUtils
FileUtil,
// IdeIntf
EditorSyntaxHighlighterDef, IDEOptionsIntf,
// SynEdit
SynEditHighlighter, SynEditHighlighterFoldBase,
// IDE
EditorOptions, LazarusIDEStrConsts;
type

View File

@ -25,9 +25,15 @@ unit editor_dividerdraw_options;
interface
uses
Classes, SysUtils, StdCtrls, ExtCtrls, Graphics,
LCLType, EditorOptions, LazarusIDEStrConsts, IDEOptionsIntf,
SynEditHighlighter, Spin, ColorBox, CheckLst;
Classes, SysUtils,
// LCL
StdCtrls, ExtCtrls, Graphics, Spin, ColorBox, CheckLst, LCLType,
// IdeIntf
EditorSyntaxHighlighterDef, IDEOptionsIntf,
// SynEdit
SynEditHighlighter,
// IDE
EditorOptions, LazarusIDEStrConsts;
type
@ -60,7 +66,6 @@ type
procedure TopLvlColorBoxChange(Sender: TObject);
procedure TopLvlColorCheckBoxChange(Sender: TObject);
private
{ private declarations }
FHighlighters: array[TLazSyntaxHighlighter] of TSrcIDEHighlighter;
FCurHighlighter: TSrcIDEHighlighter;
FCurDividerConf: TSynDividerDrawConfig;

View File

@ -25,11 +25,19 @@ unit editor_markup_options;
interface
uses
Classes, StdCtrls, ComCtrls, Graphics, sysutils, EditorOptions, LazarusIDEStrConsts,
SourceMarks, IDEOptionsIntf, Spin, ExtCtrls, SynEditMarkupBracket, editor_color_options,
editor_general_options, editor_keymapping_options, editor_codefolding_options, SynEdit,
SynCompletion, SynHighlighterPas, SynEditKeyCmds, SynEditHighlighterFoldBase, DividerBevel,
LCLType, CheckLst, Controls;
Classes, sysutils,
// LCL
LCLType, CheckLst, Controls, StdCtrls, ComCtrls, Graphics, Spin, ExtCtrls,
// LazControls
DividerBevel,
// IDEIntf
EditorSyntaxHighlighterDef, IDEOptionsIntf,
// SynEdit
SynEdit, SynCompletion, SynHighlighterPas, SynEditKeyCmds, SynEditHighlighterFoldBase,
// IDE
EditorOptions, LazarusIDEStrConsts, SourceMarks, SynEditMarkupBracket,
editor_color_options, editor_general_options, editor_keymapping_options,
editor_codefolding_options;
type
{ TEditorMarkupOptionsFrame }

View File

@ -38,8 +38,13 @@ unit IDECmdLine;
interface
uses
Classes, SysUtils, FileUtil, LazFileUtils, LazUTF8, LazUTF8Classes,
LazLogger, LazConf, LCLProc;
Classes, SysUtils,
// LazUtils
FileUtil, LazFileUtils, LazUTF8, LazUTF8Classes, LazLogger,
// LCL
LCLProc,
// IDE
LazConf;
const
ShowSetupDialogOptLong='--setup';

View File

@ -36,9 +36,20 @@ unit InputHistory;
interface
uses
Classes, SysUtils, FileProcs, LazFileCache, DiffPatch, IDEProcs,
AvgLvlTree, Laz2_XMLCfg, SynEditTypes, LazConf, Dialogs, LazUTF8, IDEDialogs,
ProjectIntf, LazFileUtils;
// RTL + LCL
Classes, SysUtils,
// LCL
Dialogs,
// LazUtils
LazFileCache, LazFileUtils, LazUTF8, AvgLvlTree, Laz2_XMLCfg,
// Codetools
FileProcs,
// IdeIntf
ProjectIntf, IDEDialogs,
// SynEdit
SynEditTypes,
// IDE
DiffPatch, LazConf, IDEProcs;
{$ifdef Windows}
{$define CaseInsensitiveFilenames}

View File

@ -32,9 +32,17 @@ unit KeyMapping;
interface
uses
Classes, SysUtils, contnrs, Forms, LCLType, LCLProc, AvgLvlTree, Laz2_XMLCfg,
Classes, SysUtils, contnrs,
// LCL
Forms, LCLType, LCLProc,
// LazUtils
AvgLvlTree, Laz2_XMLCfg,
// SynEdit
SynEditKeyCmds, SynPluginTemplateEdit, SynPluginSyncroEdit, SynPluginMultiCaret,
IDECommands, LazarusIDEStrConsts, Debugger;
// IdeIntf
IDECommands,
// IDE
LazarusIDEStrConsts, Debugger;
type
TKeyMapScheme = (

View File

@ -75,7 +75,7 @@ uses
// SynEdit
SynEdit, AllSynEdit, SynEditKeyCmds, SynEditMarks, SynEditHighlighter,
// IDE interface
IDEIntf, ObjectInspector, PropEdits, PropEditUtils,
IDEIntf, ObjectInspector, PropEdits, PropEditUtils, EditorSyntaxHighlighterDef,
MacroIntf, IDECommands, IDEWindowIntf, ComponentReg,
SrcEditorIntf, NewItemIntf, IDEExternToolIntf, IDEMsgIntf,
PackageIntf, ProjectIntf, CompOptsIntf, MenuIntf, LazIDEIntf, IDEDialogs,

View File

@ -52,23 +52,26 @@ interface
{$I ide.inc}
uses
{$IFDEF IDE_MEM_CHECK}
{$IFDEF IDE_MEM_CHECK}
MemCheck,
{$ENDIF}
Math, Classes, LCLType, LCLProc, LCLIntf, Buttons, Menus, ComCtrls,
SysUtils, types, Controls, Graphics, ExtCtrls, Dialogs, LazFileUtils, Forms,
CodeToolManager, AVL_Tree, SynEditKeyCmds, PackageIntf,
{$ENDIF}
Classes, SysUtils, Types, Math,
// LCL
LCLProc, Buttons, Menus, ComCtrls, Controls, Graphics, Dialogs, Forms, ImgList,
// LazUtils
LazFileUtils,
// Codetools
CodeToolManager,
// SynEdit
SynEditKeyCmds,
// IDEIntf
IDEImagesIntf, SrcEditorIntf, LazIDEIntf, MenuIntf, NewItemIntf,
IDECommands, IDEWindowIntf, ProjectIntf, ToolBarIntf,
IDEImagesIntf, SrcEditorIntf, LazIDEIntf, MenuIntf, NewItemIntf, PackageIntf,
IDECommands, IDEWindowIntf, ProjectIntf, ToolBarIntf, ObjectInspector,
PropEdits, IDEDialogs, EditorSyntaxHighlighterDef,
// IDE
LazConf, LazarusIDEStrConsts, ProjectDefs, Project, IDEDialogs,
TransferMacros, ObjectInspector, PropEdits, BuildManager,
EnvironmentOpts, EditorOptions, CompilerOptions, KeyMapping, IDEProcs,
Debugger, IDEOptionDefs, Splash, Designer,
SourceEditor, FindInFilesDlg,
MainBar, MainIntf, SourceSynEditor, PseudoTerminalDlg,
DesktopManager, ImgList;
LazConf, LazarusIDEStrConsts, Project, BuildManager, IDEProcs,
EnvironmentOpts, EditorOptions, CompilerOptions, SourceEditor, SourceSynEditor,
FindInFilesDlg, DesktopManager, Splash, MainBar, MainIntf, Designer, Debugger;
type
TResetToolFlag = (

View File

@ -43,24 +43,27 @@ interface
{$I ide.inc}
uses
{$IFDEF IDE_MEM_CHECK}
{$IFDEF IDE_MEM_CHECK}
MemCheck,
{$ENDIF}
// RTL + FCL + LCL
Classes, SysUtils, TypInfo, LCLProc, Forms, Controls, Dialogs, maps,
{$ENDIF}
// RTL + FCL
Classes, SysUtils, TypInfo,
// LCL
LCLProc, Forms, Controls, Dialogs, maps,
// CodeTools
CodeToolsConfig, ExprEval, DefineTemplates,
BasicCodeTools, CodeToolsCfgScript, CodeToolManager, CodeCache, FileProcs,
CodeToolsConfig, ExprEval, DefineTemplates, BasicCodeTools, CodeToolsCfgScript,
LinkScanner, CodeToolManager, CodeCache, FileProcs,
// LazUtils
FPCAdds, FileUtil, LazFileUtils, LazFileCache, LazUTF8, Laz2_XMLCfg,
// IDEIntf
PropEdits, CompOptsIntf, ProjectIntf, MacroIntf, MacroDefIntf, UnitResources,
PackageIntf, SrcEditorIntf, IDEOptionsIntf, IDEDialogs, LazIDEIntf, ProjPackIntf,
PropEdits, UnitResources, EditorSyntaxHighlighterDef,
CompOptsIntf, ProjectIntf, MacroIntf, MacroDefIntf, SrcEditorIntf,
IDEOptionsIntf, IDEDialogs, LazIDEIntf, ProjPackIntf, PackageIntf,
// IDE
CompOptsModes, ProjectResources, LazConf, W32Manifest, ProjectIcon,
IDECmdLine, LazarusIDEStrConsts, CompilerOptions,
TransferMacros, EditorOptions, IDEProcs, RunParamsOpts, ProjectDefs, ProjPackBase,
FileReferenceList, EditDefineTree, ModeMatrixOpts, PackageDefs, PackageSystem;
IDECmdLine, IDEProcs, CompilerOptions, RunParamsOpts, ModeMatrixOpts,
TransferMacros, ProjectDefs, FileReferenceList, EditDefineTree,
LazarusIDEStrConsts, ProjPackBase, PackageDefs, PackageSystem;
type
TUnitInfo = class;
@ -1121,6 +1124,7 @@ const
var
Project1: TProject = nil;// the main project
function FilenameToLazSyntaxHighlighter(Filename: String): TLazSyntaxHighlighter;
function AddCompileReasonsDiff(const PropertyName: string;
const Old, New: TCompileReasons; Tool: TCompilerDiffTool = nil): boolean;
function dbgs(aType: TUnitCompDependencyType): string; overload;
@ -1135,6 +1139,20 @@ const
ProjOptionsPath = 'ProjectOptions/';
function FilenameToLazSyntaxHighlighter(Filename: String): TLazSyntaxHighlighter;
var
CompilerMode: TCompilerMode;
begin
Result:=IDEEditorOptions.ExtensionToLazSyntaxHighlighter(ExtractFileExt(Filename));
if Result in [lshFreePascal,lshDelphi] then begin
CompilerMode:=CodeToolBoss.GetCompilerModeForDirectory(ExtractFilePath(Filename));
if CompilerMode in [cmDELPHI,cmTP] then
Result:=lshDelphi
else
Result:=lshFreePascal;
end;
end;
function AddCompileReasonsDiff(const PropertyName: string;
const Old, New: TCompileReasons; Tool: TCompilerDiffTool): boolean;
begin
@ -1854,8 +1872,7 @@ begin
else
LoadedDesigner:=false;
fUserReadOnly:=XMLConfig.GetValue(Path+'ReadOnly/Value',false);
FBuildFileIfActive:=XMLConfig.GetValue(Path+'BuildFileIfActive/Value',
false);
FBuildFileIfActive:=XMLConfig.GetValue(Path+'BuildFileIfActive/Value',false);
FRunFileIfActive:=XMLConfig.GetValue(Path+'RunFileIfActive/Value',false);
fUsageCount:=XMLConfig.GetValue(Path+'UsageCount/Value',-1);
if fUsageCount<1 then begin
@ -1923,7 +1940,7 @@ begin
end;
fFileName:=NewFilename;
if EditorOpts<>nil then
if IDEEditorOptions<>nil then
UpdateDefaultHighlighter(FilenameToLazSyntaxHighlighter(FFilename));
UpdateSourceDirectoryReference;
end;
@ -3591,7 +3608,7 @@ var
begin
NewBuf:=CodeToolBoss.CreateFile(Filename);
AnUnitInfo:=TUnitInfo.Create(NewBuf);
if EditorOpts<>nil then
if IDEEditorOptions<>nil then
AnUnitInfo.DefaultSyntaxHighlighter := FilenameToLazSyntaxHighlighter(NewBuf.Filename);
Result:=AnUnitInfo;
end;
@ -5054,7 +5071,7 @@ procedure TProject.UpdateAllCustomHighlighter;
var
i: Integer;
begin
if EditorOpts=nil then exit;
if IDEEditorOptions=nil then exit;
for i:=0 to UnitCount-1 do
Units[i].UpdateHasCustomHighlighter(FilenameToLazSyntaxHighlighter(Units[i].Filename));
end;
@ -5063,7 +5080,7 @@ procedure TProject.UpdateAllSyntaxHighlighter;
var
i: Integer;
begin
if EditorOpts=nil then exit;
if IDEEditorOptions=nil then exit;
for i:=0 to UnitCount-1 do
Units[i].UpdateDefaultHighlighter(FilenameToLazSyntaxHighlighter(Units[i].Filename));
end;

View File

@ -37,9 +37,16 @@ unit ProjectDefs;
interface
uses
Classes, SysUtils, Controls, Forms,
FileProcs, LazFileUtils, Laz2_XMLCfg, LazUTF8,
Classes, SysUtils,
// LCL
Controls, Forms,
// Codetools
FileProcs,
// LazUtils
LazFileUtils, LazUTF8, Laz2_XMLCfg,
// IdeIntf
CompOptsIntf, ProjectIntf, LazIDEIntf,
// IDE
frmCustomApplicationOptions, PublishModule, IDEProcs, LazarusIDEStrConsts;
type

View File

@ -34,9 +34,16 @@ unit ProjectIcon;
interface
uses
Classes, SysUtils, FileUtil, Laz2_XMLCfg, lazutf8classes, LCLProc,
Graphics, FileProcs, LazFileUtils, LazFileCache,
resource, groupiconresource, ProjectResourcesIntf;
// RTL + LCL
Classes, SysUtils, resource, groupiconresource,
// LCL
LCLProc, Graphics,
// LazUtils
FileUtil, LazFileUtils, LazFileCache, Laz2_XMLCfg, lazutf8classes,
// Codetools
FileProcs,
// IdeIntf
ProjectResourcesIntf;
type
TIconData = array of byte;

View File

@ -39,7 +39,8 @@ interface
uses
// RTL + LCL
Classes, SysUtils, resource, reswriter, fgl,
Controls, LCLProc, LResources, Dialogs,
// LCL
Controls, Dialogs, LCLProc, LResources,
// LazUtils
LazFileUtils, AvgLvlTree, Laz2_XMLCfg,
// Codetools

View File

@ -35,11 +35,18 @@ unit ProjectUserResources;
interface
uses
Classes, SysUtils, Laz2_XMLCfg, LCLProc, FileProcs, LazFileUtils, LazUTF8,
// RTL + LCL
Classes, SysUtils,
resource, bitmapresource, groupresource, groupiconresource, groupcursorresource,
// LCL
LCLProc,
// LazUtils
FileProcs, LazFileUtils, LazUTF8, Laz2_XMLCfg,
// IdeIntf
ProjectResourcesIntf, IDEMsgIntf, MacroIntf, IDEExternToolIntf,
LazarusIDEStrConsts, resource, bitmapresource, groupresource,
groupiconresource, groupcursorresource;
// IDE
LazarusIDEStrConsts;
type
TUserResourceType = (
rtIcon, // maps to RT_GROUP_ICON

View File

@ -36,7 +36,14 @@ interface
uses
Classes, SysUtils,
IDEProcs, SynRegExpr, LazFileUtils, Laz2_XMLCfg, LCLProc;
// LCL
LCLProc,
// LazUtils
LazFileUtils, Laz2_XMLCfg,
// SynEdit
SynRegExpr,
// IDE
IDEProcs;
type
{ TPublishModuleOptions }

View File

@ -47,10 +47,15 @@ uses
{$IFDEF IDE_MEM_CHECK}
MemCheck,
{$ENDIF}
Classes, SysUtils, LCLProc, Controls, Forms, Buttons, StdCtrls, ComCtrls,
Dialogs, ExtCtrls, BaseIDEIntf, IDEHelpIntf, ProjectIntf, IDEDialogs,
IDEProcs, SysVarUserOverrideDlg, InputHistory, LazarusIDEStrConsts, LazFileUtils,
Laz2_XMLCfg, LazFileCache, LazUTF8, ButtonPanel;
Classes, SysUtils,
// LCL
Controls, Forms, Buttons, StdCtrls, ComCtrls, Dialogs, ButtonPanel,
// IdeIntf
BaseIDEIntf, IDEHelpIntf, ProjectIntf, IDEDialogs,
// LazUtils
LazFileUtils, LazFileCache, LazUTF8, Laz2_XMLCfg,
// IDE
IDEProcs, SysVarUserOverrideDlg, InputHistory, LazarusIDEStrConsts;
{ The xml format version:
When the format changes (new values, changed formats) we can distinguish old

View File

@ -42,11 +42,17 @@ uses
{$IFDEF IDE_MEM_CHECK}
MemCheck,
{$ENDIF}
SynEditMouseCmds, Classes, SysUtils, StrUtils, types, Math,
SynEditMouseCmds,
// RTL + FCL
Classes, SysUtils, StrUtils, types, Math,
// LCL
Controls, Forms, ComCtrls, StdCtrls, Graphics, Dialogs, Extctrls, Menus,
ExtendedNotebook, LCLProc, LCLType, LResources, LCLIntf, FileUtil, LazFileUtils,
Translations, ClipBrd, HelpIntfs,
LConvEncoding, Messages, LazLoggerBase, lazutf8classes, LazLogger, AvgLvlTree,
LCLProc, LCLType, LResources, LCLIntf, FileUtil, LazFileUtils,
Translations, ClipBrd, HelpIntfs, Messages,
// LazControls
ExtendedNotebook,
// LazUtils
LConvEncoding, LazLoggerBase, LazUTF8Classes, LazLogger, AvgLvlTree,
LazFileCache, LazUTF8,
// codetools
BasicCodeTools, CodeBeautifier, CodeToolManager, CodeCache, SourceLog,
@ -58,21 +64,21 @@ uses
SynBeautifier, SynPluginMultiCaret,
SynPluginSyncronizedEditBase, SourceSynEditor,
SynExportHTML, SynHighlighterPas, SynEditMarkup, SynEditMarkupIfDef,
// Intf
// IdeIntf
SrcEditorIntf, MenuIntf, LazIDEIntf, PackageIntf, IDEHelpIntf, IDEImagesIntf,
IDEWindowIntf, ProjectIntf, MacroDefIntf, ToolBarIntf,
IDEWindowIntf, ProjectIntf, MacroDefIntf, ToolBarIntf, IDEDialogs,
EditorSyntaxHighlighterDef,
// DebuggerIntf
DbgIntfBaseTypes, DbgIntfDebuggerBase,
// IDE units
IDECmdLine, IDEDialogs, LazarusIDEStrConsts, IDECommands,
EditorOptions, EnvironmentOpts, WordCompletion, FindReplaceDialog, IDEProcs,
IDEOptionDefs, IDEHelpManager, MacroPromptDlg, TransferMacros,
CodeContextForm, SrcEditHintFrm, etMessagesWnd, etSrcEditMarks, InputHistory,
CodeMacroPrompt, CodeTemplatesDlg, CodeToolsOptions,
editor_general_options,
SortSelectionDlg, EncloseSelectionDlg, EncloseIfDef, InvertAssignTool,
SourceEditProcs, SourceMarks, CharacterMapDlg, SearchFrm, MultiPasteDlg,
FPDocHints, EditorMacroListViewer, EditorToolbarStatic, editortoolbar_options,
DbgIntfBaseTypes, DbgIntfDebuggerBase, BaseDebugManager, Debugger, MainIntf,
GotoFrm;
IDECmdLine, LazarusIDEStrConsts, IDECommands, EditorOptions, EnvironmentOpts,
WordCompletion, FindReplaceDialog, IDEProcs, IDEOptionDefs, IDEHelpManager,
MacroPromptDlg, TransferMacros, CodeContextForm, SrcEditHintFrm, etMessagesWnd,
etSrcEditMarks, InputHistory, CodeMacroPrompt, CodeTemplatesDlg, CodeToolsOptions,
editor_general_options, SortSelectionDlg, EncloseSelectionDlg, EncloseIfDef,
InvertAssignTool, SourceEditProcs, SourceMarks, CharacterMapDlg, SearchFrm,
MultiPasteDlg, EditorMacroListViewer, EditorToolbarStatic, editortoolbar_options,
FPDocHints, MainIntf, GotoFrm, BaseDebugManager, Debugger;
type
TSourceNotebook = class;

View File

@ -32,22 +32,28 @@ unit SourceFileManager;
interface
uses
AVL_Tree, typinfo, math, Classes, SysUtils, Controls, Forms, Dialogs, LCLIntf,
LCLType, LCLProc, FileProcs, IDEProcs, DialogProcs, IDEDialogs,
LConvEncoding, LazFileCache, FileUtil, LazFileUtils, LazUTF8, LResources, PropEdits,
DefineTemplates, IDEMsgIntf, IDEProtocol, LazarusIDEStrConsts, LclStrConsts, NewDialog,
NewProjectDlg, LazIDEIntf, MainBase, MainBar, MainIntf, MenuIntf, NewItemIntf,
CompOptsIntf, SrcEditorIntf, IDEWindowIntf, ProjectIntf, Project, ProjectDefs,
ProjectInspector, PackageIntf, PackageDefs, PackageSystem, CompilerOptions,
BasePkgManager, ComponentReg, SourceEditor, EditorOptions, CustomFormEditor,
FormEditor, EmptyMethodsDlg, BaseDebugManager, ControlSelection,
TransferMacros, EnvironmentOpts, BuildManager, EditorMacroListViewer,
KeywordFuncLists, FindRenameIdentifier, GenericCheckList, ViewUnit_Dlg,
DiskDiffsDialog, InputHistory, CheckLFMDlg, LCLMemManager, CodeToolManager,
CodeToolsStructs, ConvCodeTool, CodeCache, CodeTree, FindDeclarationTool,
BasicCodeTools, SynEdit, UnitResources, IDEExternToolIntf, ObjectInspector,
PublishModule, etMessagesWnd, SourceSynEditor,
FormEditingIntf, fpjson;
Classes, SysUtils, typinfo, math, AVL_Tree, fpjson,
// LCL
Controls, Forms, Dialogs, LCLIntf, LCLType, LCLProc, LclStrConsts,
LResources, LCLMemManager,
// LazUtils
LConvEncoding, LazFileCache, FileUtil, LazFileUtils, LazUTF8,
// Codetools
BasicCodeTools, CodeToolsStructs, CodeToolManager, FileProcs, DefineTemplates,
CodeCache, CodeTree, FindDeclarationTool, KeywordFuncLists,
// IdeIntf
IDEDialogs, PropEdits, IDEMsgIntf, LazIDEIntf, MenuIntf, NewItemIntf,
CompOptsIntf, SrcEditorIntf, IDEWindowIntf, ProjectIntf, PackageIntf,
FormEditingIntf, IDEExternToolIntf, ObjectInspector, UnitResources, ComponentReg,
EditorSyntaxHighlighterDef,
// IDE
IDEProcs, DialogProcs, IDEProtocol, LazarusIDEStrConsts, NewDialog, NewProjectDlg,
MainBase, MainBar, MainIntf, Project, ProjectDefs, ProjectInspector, CompilerOptions,
SourceSynEditor, SourceEditor, EditorOptions, EnvironmentOpts, CustomFormEditor,
ControlSelection, FormEditor, EmptyMethodsDlg, BaseDebugManager, TransferMacros,
BuildManager, EditorMacroListViewer, FindRenameIdentifier, GenericCheckList,
ViewUnit_Dlg, DiskDiffsDialog, InputHistory, CheckLFMDlg, PublishModule, etMessagesWnd,
ConvCodeTool, BasePkgManager, PackageDefs, PackageSystem;
type

View File

@ -55,7 +55,7 @@ const
LCLPlatformDisplayNames: array[TLCLPlatform] of string = (
'gtk (deprecated)',
'gtk 2',
'gtk2',
'gtk3 (alpha)',
'win32/win64',
'wince',