[Pas2js] UI approach
Michael Van Canneyt
michael at freepascal.org
Wed Jan 24 15:29:40 CET 2018
On Wed, 24 Jan 2018, warleyalex via Pas2js wrote:
> It's on the oven a tool named PJ-Suite that claims to use the Delphi/Lazarus
> and its form designer to create web applications.
Not "claims", it's actually so :)
> Just drop components onto
> a form and set up at the objector inspector, the events and the properties.
> All of the above is great and it will no doubt give us the same benefits as
> Delphi/Lazarus developers currently enjoy. The compiler will auto generate
> the components for you, such as:
>
> var
> btn1: TButton;
>
> btn1 := TButton.Create(Self);
> btn1.Width := 121;
> btn1.Top := 16;
> btn1.Left := 536;
> btn1.Height := 25;
> btn1.Name := 'btn1';
> btn1.OnClick := Self.btn1Click;
>
> I've spent a few minutes reflecting on this RAD approach. I sincerely don't
> like of the RAD methodology to build big apps. Otherside, for fast
> prototyping desktop web app I really enjoy this appoach.
>
> For big web app, I always will prefer hand-written code, consider to be more
> readable, maintainable and believe to offer more customization.
Well, I think you are *totally* wrong. It's rather the opposite.
The whole point is that building your GUI using RAD is faster.
I see absolutely no benefit in building your GUI in code.
It's a waste of time.
For business code, I will not argue, but spending time on constructing a GUI
using code, not for me, thank you.
>
> Since I didn't test the PJ-Suite yes, it's indeed a nice tool, anyway.
In Delphi it works absolutely splendid.
>
> --------------------------------------
> For fast prototyping Pas2JS applications, in my experiments, it was possible
> to convert "some components" from Lazarus/Delphi form designer to static
> HTML using qooxdoo components! I'll try to modify this tool to use it with
> Pas2JS.
>
> Since Delphi/Lazarus comes with a bunch of ready to use UI elements and
> widgets like modals, popups, popover, searchbar, side panels, headerBar,
> etc. we need to extend the IDE.
>
> I have never created a visual component with Lazarus. I've been thinking to
> build a lightweight kind of "fake" SearchBar widget to be used into the
> Lazarus form designer. The idea is use a tool to render a form into HTML.
What's then the difference with using PJ-Suite mentioned above ?
Why not go RAD all the way ? All you need to do is create a web-widgetset
for the LCL.
Michael.
More information about the Pas2js
mailing list