mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-06 00:58:04 +02:00
IDE: SourceEditor change Highlighter, don't show internal dummy HL.
(cherry picked from commit 046947520c
)
This commit is contained in:
parent
17dd1f61a0
commit
fb6edd5b06
@ -7231,7 +7231,7 @@ begin
|
||||
if SrcEdit=nil then exit;
|
||||
if Sender is TIDEMenuItem then begin
|
||||
IDEMenuItem:=TIDEMenuItem(Sender);
|
||||
i:=IDEMenuItem.SectionIndex;
|
||||
i:=IDEMenuItem.Tag;
|
||||
if (i>=0) and (i<EditorOpts.HighlighterList.Count) then begin
|
||||
SrcEdit.SyntaxHighlighterId:=i;
|
||||
SrcEdit.UpdateProjectFile([sepuChangedHighlighter]);
|
||||
@ -7690,6 +7690,8 @@ var
|
||||
begin
|
||||
SrcEditSubMenuHighlighter.ChildrenAsSubMenu:=true;
|
||||
for i := 0 to EditorOpts.HighlighterList.Count - 1 do begin
|
||||
if EditorOpts.HighlighterList.SharedSynInstances[i] is TNonSrcIDEHighlighter then
|
||||
continue;
|
||||
CurName:='Highlighter'+IntToStr(i);
|
||||
CurCaption:= EditorOpts.HighlighterList.Captions[i];
|
||||
if SrcEditSubMenuHighlighter.Count=i then begin
|
||||
@ -7699,6 +7701,7 @@ begin
|
||||
end else begin
|
||||
IDEMenuItem:=SrcEditSubMenuHighlighter[i];
|
||||
IDEMenuItem.Caption:=CurCaption;
|
||||
IDEMenuItem.Tag:=i;
|
||||
IDEMenuItem.OnClick:=@HighlighterClicked;
|
||||
end;
|
||||
if IDEMenuItem is TIDEMenuCommand then
|
||||
|
Loading…
Reference in New Issue
Block a user