Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2012-11

Multiple .lrs files for one .pas

2 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Krzysztof

Hi,

Is it possible to have more than one .lrs file for one .pas file? For example, I have one MyDialogs.pas unit. Inside this unit I have more than one forms like TMyForm1, TMyForm2 etc. And I would like to design each of them using form designer. This is probably not possible (because I don't know how F12 should work in this case), but it could be interesting feature. Similar like in android programming, where xml layouts are not strongly linked with .java files and those layouts can be designed in external tools (like DroidDraw)

Regards
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus.freepascal.org/pipermail/lazarus/attachments/20121124/da449859/attachment.html>

Reply by email

Mattias Gaertner
to Krzysztof
Hi, Is it possible to have more than one .lrs file for one .pas file?

Yes.
You can manually create more files and add them to the code. The IDE maintains only the first in the initialization section.

For example, I have one MyDialogs.pas unit. Inside this unit I have more than one forms like TMyForm1, TMyForm2 etc. And I would like to design each of them using form designer. This is probably not possible

It is not possible in Lazarus.

(because I don't know how F12 should work in this case),

Yes, and many other features and error handlers would become more complicated.

but it could be interesting feature. Similar like in android programming, where xml layouts are not strongly linked with .java files and those layouts can be designed in external tools (like DroidDraw)

Mattias

Reply by email