Mattias Gaertner wrote:
On Sat, 05 Nov 2005 18:32:57 +0000
Colin Western <[EMAIL PROTECTED]> wrote:
[...]
Is the attached anything like right for forcing the ancestor form to
load? It works on the one form I tried...
Well, it will work sometimes because of sheer luck:
- CodeToolBoss.FindCodeToolForSource will only work, if there was a parsing
before. This is not always the case.
- CodeToolBoss.FindDeclaration will fail on syntax errors in code
- CodeTool.CurPos.StartPos is only accidently the ancestor class name
- DoOpenEditorFile will only open the designer, if the option is set in the
environment options.
I added a function, that will handle some of these and few more problems.
But it is still far away from being usable.
Thanks for looking at this - I will give it a try. I had spotted some of
these - I was relying on the preceeding CodeToolBoss.FindFormAncestor
working, and positioning the cursor. Presumably there will always be
some syntax errors that will stop loading, but more robustis certainly
better.
Colin
_________________________________________________________________
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
archives at http://www.lazarus.freepascal.org/mailarchives