Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Please do test out FreePascal and the Lazarus IDE.

Why?

1. Cross platform - Mac OS, Linux and Window and Raspberry Pi https://www.lazarus-ide.org/

2. VERY fast development and compile-run cycles. You are talking about WYSIWYG designer and compilation in seconds.

3. Fully native binaries which are very small and very fast.

4. It is a full fledged RAD environment with full support for GUI development using a very powerful designer.

5. There are GUI as well as non-GUI components - example: Database components, Database-aware grids, database aware-listboxes, search filters etc.

6. Very diverse set of components. And very easy to develop new components from scratch or customise and existing component.

7. The object structure is very powerful - with support for read & write properties, composite components, property setting pages, internationalisation etc.

8. It is possible to interface with C/C++ libraries as well and that isn't complicated



Just adding another note to my comment above:

9. Lazarus has a built-in debugger which is quite powerful and the development environment has full integration with it.

To see a demo of the Lazarus IDE including the debugger functionality, please see the video in the page below: https://www.getlazarus.org/new/

10. Lazarus is 100% open source and is under active development with the last release in July 22, 2020.

Lazarus is not a new fad language. It has been in existence for decades and there are existing apps which are developed in it - example, the Transmission GUI client.

Other projects done in Lazarus: https://www.getlazarus.org/community/showcase/

Projects by category. This is not a full list: https://wiki.freepascal.org/Projects_using_Lazarus


Double Commander, which is done in Free Pascal/Lazarus, doesn't look or work too integrated on OSX—though I don't know if that's possible by spending more effort. It's using Qt for the looks, as the Cocoa variant works even worse—and that's for some reason inconsistent, compared to other and perhaps simpler Qt apps that aren't made with Pascal.

A file manager has to plug into multiple native features, e.g. the list of app associations—and DC does that sorta half-assedly.


Could you please explain the relationship between FreePascal and Delphi? Is there one besides common ancestry? The page here makes it sound like it's just a class library and not a separate environment: https://wiki.freepascal.org/Delphi

I ask because I'm a big fan of PowerArchiver as my go-to archive manager on Windows over the usual 7-Zip/WinZip/WinRAR/etc, it's a Delphi app, and it has a nice GUI: https://www.powerarchiver.com/


Free Pascal is the language and Lazarus is the IDE. In the case of Delphi, Object Pascal is the language and Delphi is the IDE.

So it is best to see Free Pascal & Lazarus as the free and open source alternative to Object Pascal & Delphi respectively.

Of course, now the term Object Pascal is not used at all. Delphi is used to refer to both the language and the IDE now.

About Free Pascal, it is largely compatible with Delphi/Object Pascal but there are minor differences. https://wiki.freepascal.org/Lazarus_For_Delphi_Users

Here is a write up on the advantages of Free Pascal: https://www.freepascal.org/advantage.var


Thank you! That makes much more sense.


You are welcome! Please do give it a shot.

I am not associated with the Lazarus project at all but I did develop in Delphi over 22 years ago and I still do some development using Lazarus. I hope to do some tutorial videos on this to help those new to the environment.


Were you a 68k-era Mac dev, by chance? That's my biggest mental association with "Object Pascal". I was only old enough to be a beginner-level user in those days and never got to ('had to'?) program anything on them, but it always seemed like it would be fun to revisit and see that Other Side of my childhood System 7 :)


No, I started with Turbo Pascal in the late 80s and early 90s and then moved onto Delphi, Turbo C etc later. I programmed in Delphi till about version 7/8 when Borland decided to implode by going after "Application Lifecycle Management" etc.


Nothing on the wiki page you linked to is about Free Pascal at all. It's about the history of Delphi.


Aside from being on the FreePascal wiki? :p


Aside from that, yes.

Worth mentioning that at least one excellent piece of commercial software, Beyond Compare, targets Windows with Delhi but Linux and MacOS with Lazarus.

https://www.scootersoftware.com/

I haven't tried the Linux version but it'd be useful to look at, for the sake of comparison.


Thanks for mentioning Lazarus IDE. I like it a lot.

A few months ago I developed a Kanban tool to organize my personal tasks. I use the tool under Windows and Linux, it works fine.

For me the big advantage of Lazarus/FreePascal is that you have to write the business logic only once and you compile the code for different environments to get native binary files (no interpreter used). In case of operating system specific code you can use conditional compilation (e.g. {$ifdef MSWINDOWS}) but in my case that wasn't really necessary.


Cool! Do you have it available for download?


How does one usually go about finding documentation related to Pascal? Does one need to download a package from https://packages.lazarus-ide.org/ and view its documentation from there?


The Lazarus IDE has built-in help. Apart from that you can get component-specific documentation as well.

Freepascal Runtime Library documentation: https://lazarus-ccr.sourceforge.io/docs/rtl/

Lazarus Component Library: https://lazarus-ccr.sourceforge.io/docs/lcl/

Freepascal Component Library: https://lazarus-ccr.sourceforge.io/docs/fcl/

Freepascal Wiki: https://wiki.freepascal.org/Lazarus_Documentation

Something else I should have added in my original comment: Lazarus has a very capable built-in debugger.

That is invaluable if you want to step through and understand how things work.

EDIT: Other sites:

Some demo projects here: https://www.getlazarus.org/

Lazarus project showcase: https://www.getlazarus.org/community/showcase/

The Transmission Bittorrent GUI client was done in Lazarus: https://sourceforge.net/projects/transgui/

Other apps done in Lazarus from the Lazarus website shown by category: https://wiki.freepascal.org/Projects_using_Lazarus


Is it declarative or imperative? I wouldn't really want to go back to doing GUIs imperatively.


It is via a drag and drop designer.


I tried, and build my own widget (not sure how it was called), and the IDE kept crashing constantly.


The IDE shouldn't crash by itself (it is extremely rare for the IDE to crash, it used to be less stable at the past but that was around 2006-2007 or so).

However packages (which includes your own widgets) are nothing more than native libraries that become part of the IDE, so any bugs in a package will cause the entire IDE to crash. This is a double edged sword since on one hand you can get a less stable IDE from your own bugs, but on the other hand when you work with a component or widget in the visual editors, you are really working with a "live" instance of that widget that is then serialized as part of the form or data module instead of a mock stand-in object that some other GUI-only designers will give you. Also this allows you to use any TComponent-derived object through a visual editor, not only visual/GUI objects.


Thanks. I understand now. I somehow thought the IDE would use at least some sandboxing


I'm not sure if this is possible, AFAIK this is common in any development environment that allows you to work with live instances of your objects - i think even IDEs like Netbeans have the same issue with custom controls.


Was this with a newer versions of Lazarus? It has become far more stable now.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: