View previous topic :: View next topic |
Author |
Message |
keithml
Joined: 25 Jul 2006 Posts: 12 Location: Florida
|
Posted: Tue Jul 25, 2006 1:19 am Post subject: HTML with Scripts Parser |
|
|
It has been a while since I've used the control and must have forgotten something. Oddly the HTML with Scripts Parser doesn't seem to work when I use it, but the syntax highlighting works for others like Pascal and C.
Here is the code I used.
CtrlText: TSyntaxMemo;
CtrlManager: TSyntaxManager;
CtrlManager.LoadFromFile(gGetProgramDir+'LexLib.LXL');
CtrlText.LoadFromFile(FileName);
CtrlText.SyntaxAnalyzer := CtrlManager.AnalyzerForFile(FileName);
CtrlManager.CurrentLexer := CtrlText.SyntaxAnalyzer;
What am I doing incorrectly?
Thanks,
Keith |
|
Back to top |
|
|
econtrol Site Admin
Joined: 09 Jun 2006 Posts: 202
|
Posted: Tue Jul 25, 2006 7:05 am Post subject: |
|
|
Hi Keith,
Is any highlighting in the editor after executing your sample code?
Michael. |
|
Back to top |
|
|
keithml
Joined: 25 Jul 2006 Posts: 12 Location: Florida
|
Posted: Tue Jul 25, 2006 12:52 pm Post subject: |
|
|
It has no highlighting at all for the HTML parser, but works for the Pascal and C++ I tried.
Keith |
|
Back to top |
|
|
econtrol Site Admin
Joined: 09 Jun 2006 Posts: 202
|
Posted: Wed Jul 26, 2006 9:03 am Post subject: |
|
|
Possible reason is a bug:
See first topic: http://www.econtrol.ru/forum/viewtopic.php?t=14
fixing (ecSyntAnal.pas):
Code: | procedure TSyntAnalyzer.Loaded;
begin
inherited;
...
CompileGramma;
DetectBlockSeparate;// <== fixing
end; |
Michael. |
|
Back to top |
|
|
keithml
Joined: 25 Jul 2006 Posts: 12 Location: Florida
|
Posted: Wed Jul 26, 2006 1:48 pm Post subject: |
|
|
I used both bug fixes in the thread specified. Neither solved the problem. I have uploaded a quick example project, just in case that helps. I have left the compiled executable intact so you can see what happens before you recompile the project as well.
Example Project URL:
www.onecatweb.com/downloads/EControl.zip
Thanks,
Keith |
|
Back to top |
|
|
econtrol Site Admin
Joined: 09 Jun 2006 Posts: 202
|
Posted: Wed Jul 26, 2006 8:16 pm Post subject: |
|
|
Hello Keith,
This bug is fixed.
Please, wait for new update (v 2.25). There are many changes in code.
Michael. |
|
Back to top |
|
|
keithml
Joined: 25 Jul 2006 Posts: 12 Location: Florida
|
Posted: Thu Jul 27, 2006 12:32 am Post subject: |
|
|
THANKS!
Keith |
|
Back to top |
|
|
keithml
Joined: 25 Jul 2006 Posts: 12 Location: Florida
|
Posted: Mon Jul 31, 2006 4:50 pm Post subject: |
|
|
HTML still doesn't load correctly in 2.25. It remains plain text. Any other suggestions?
Keith |
|
Back to top |
|
|
econtrol Site Admin
Joined: 09 Jun 2006 Posts: 202
|
Posted: Mon Jul 31, 2006 6:57 pm Post subject: |
|
|
Take LexLib.lxl from new update. The problem in previous version was in incorrect
saving lexer references. They was with the owner name (for example "SyntEditMain.SyntAnalyzer9").
In new update references are saved without owner name (i.e. "SyntAnalyzer9").
So you should take LexLib.lxl from latest update or open old LexLib.lxl and save it.
Michael. |
|
Back to top |
|
|
keithml
Joined: 25 Jul 2006 Posts: 12 Location: Florida
|
Posted: Tue Aug 01, 2006 1:36 pm Post subject: |
|
|
That was it.
Thanks!
Keith |
|
Back to top |
|
|
|