xananews icon indicating copy to clipboard operation
xananews copied to clipboard

XanaNews for Lazarus

Open carlca opened this issue 6 years ago • 12 comments

Hi Graeme, did you ever make any headway on XanaNews for Lazarus? You were speaking about it in quite hopeful tones back in 2014. It would really solve a problem for me since there is no decent NNTP app available for the Apple Mac that I have been able to find.

carlca avatar Sep 15 '18 18:09 carlca

XanaNews's code is very Windows centric and from my research it will be a huge task (rewrite) to convert to a cross-platform project for use with FPC and Lazarus. I'm still undecided if that is worth doing - plus the fact that Lazarus's LCL 64-bit widgetset for OSX is still in Alpha stage and lagging behind with very little contributions, and I'm not a big fan of GTK3 for Linux + FreeBSD.

So no matter what, the task is going to be huge. But that got me thinking further....If it is going to be a rewrite, I might go a whole different route and reimplement XanaNews as a truly cross-platform application using Java instead (amazing language, fantastic backwards compatibility, better development tools, a much better future than Object Pascal etc). Java being more popular I might get a community of developers/contributors going (eventually), and all the existing NNTP clients for Java that I have seen all suck. If I go this route, I'll recreate XanaNews in Java as close as possible to the original. Choices, choices... and still no clear direction of what I want to do. ;-)

graemeg avatar Jan 08 '19 10:01 graemeg

a truly cross-platform application using Java instead

Eww. Please don't.

Not only does using Java not automatically make your code cross-platform (e.g. the TVBrowser guys have massive problems trying to support all relevant platforms), Java applications are also slow and potentially prone to security holes.

I'd probably suggest C instead (there are quite a few lovely cross-platform C GUI libraries, like libui). But I like Delphi a lot... :-) it had most of Go's features long before Go was a thing.

Even if Delphi dies one day, Free Pascal (Lazarus) is there to take over. I agree that its macOS support is still mediocre, but they're getting there.

dertuxmalwieder avatar Oct 14 '19 20:10 dertuxmalwieder

Java applications are also slow

That is such an old, yet common, misconception. Your statement might have been true many years ago, but not so relevant these days. Java is actually really fast these days and on par with C/C++ application speeds (there is a reason financial institutes love Java in trading systems, banking etc - it's fast, tooling is brilliant and plenty of knowledgeable developers around). Java can also compiles to native code these days and the same application executable can take advantage of different CPU features - depending on the system it is running on. The millions of dollars that companies like Oracle, IBM, Red Hat etc have invested in Java has paid off. :-)

I've written my own graphics (pure cpu) intensive comparisons in Delphi, FPC, JavaScript and C++ doing 3d like graphics (without OpenGL or a 3D GPU), and mere avg Java code (no optimisations on my part in the code) blew Delphi and FPC out the water by 250+% in performance. Even with all the code and compiler optimizations I could think of, I couldn't get Delphi or FPC to come even close to the Java performance.

Some other similar results (just a quick Google search):

  • http://www.hildstrom.com/projects/langcomp/index.html
  • http://dan.corlan.net/bench.html

Saying all that, I still haven't started any XanaNews port. :-(

graemeg avatar Oct 14 '19 22:10 graemeg

You make a good point about Java, it seems, Graeme! Bitwig Studio, my favourite piece of software of all time, has a front-end written in Java. The authors address the Java issue in this entertaining forum post... https://www.kvraudio.com/forum/viewtopic.php?f=259&t=450443

carlca avatar Oct 14 '19 22:10 carlca

Java is actually really fast these days and on par with C/C++ application speeds

Sure, once the VM has started and you limit its horrendous RAM usage ...

After all, it's your project though. :-)

dertuxmalwieder avatar Oct 14 '19 22:10 dertuxmalwieder

Since I first wrote the original message in this thread, I have gone full circle and gone back to the Apple Mac NNTP client I was using in 1997, namely Mozilla Thunderbird. It still works and the muscle memory for using it is still there!

carlca avatar Oct 14 '19 22:10 carlca

Of course, I was using the Windows version of Thunderbird back then, I should point out 😉

carlca avatar Oct 14 '19 22:10 carlca

Thunderbird did not exist in 1997.

dertuxmalwieder avatar Oct 14 '19 22:10 dertuxmalwieder

Forgive me. I must be thinking of Netscape Messanger which was, I guess, the spiritual ancestor of Mozilla Thunderbird. It was 22 years ago...

carlca avatar Oct 14 '19 22:10 carlca

Technically, Thunderbird started as a standalone version of Mozilla's mail component (which was Netscape before they open-sourced it), indeed.

We leave the track of this ticket though... ;-)

dertuxmalwieder avatar Oct 14 '19 23:10 dertuxmalwieder

Sure, once the VM has started and you limit its horrendous RAM usage ...

I used to complain about RAM usage too, but is it really still an issue? Especially when you consider that a $35 Raspberry Pi can ship with 4GB RAM. ;-)

graemeg avatar Oct 15 '19 16:10 graemeg

We're talking about the Usenet here. Yes, any RAM waste is useless. I don't use the Usenet because I have too much RAM.

dertuxmalwieder avatar Oct 15 '19 16:10 dertuxmalwieder