News for hackers. Stuff that matters.
Re:A Book about Qt5 by jyriand on Monday March 04, 2019 @02:51AM (#19299540)
I have been thinking about creating a desktop app for a while now. Problem is I can't decide which framework to use. Ideally I would like to use Common Lisp, but McCLIM looks like it's from the eighties, there's also qtools and CommonQT that make it possible to use Qt in Common Lisp, but somehow I'm afraid to develop myself into corner with these tools. Could also use clojure and "seesaw", but again -- it's like I'm handicapping myself here. I could use Racket and it's GUI library, but Racket is marketed as a language for creating languages, so I'll skip that. I guess I still need to use Java 8 with JavaFX. I wish there was a lisp dialect just for developing desktop applications.
Re:A Book about Qt5 by oblio on Monday March 04, 2019 @04:00AM (#19299807)
Yeah, it's a real shame. From what I see the best Common Lisp compilers and libraries are proprietary and seem to be stuck a in 90's vendor (think Borland) mindset.

They're probably serving their existing customers well, since they're still around, but I doubt they're getting many new customers (or mass adoption) with these prices: http://www.lispworks.com/buy/prices-2c.html, https://franz.com/products/packages/.

Re:A Book about Qt5 by lispm on Monday March 04, 2019 @06:47AM (#19300532)
Probably they wouldn't get 'mass adoption' with lower prices either. Devtools is a niche market and for an independent company it is difficult.

See for example the price for VA Smalltalk...: $6995 for a new developer license.

https://www.instantiations.com/products/purchase.html

Or VisualWorks, which charges based on either end users, number of CPUs, or a royalty basis.

It's a special niche market and in the Lisp space there are unfortunately no companies left of those which once sold actively maintained mid-priced Lisp systems with actual GUI Libs/IDEs (Dead/sold/abandoned/unmaintained: Procyon CL, Expertelligence ExperLisp, Corman CL, Digitool's MCL, Golden Common Lisp from Gold Hill, ...).

The remaining ones are two of the higher-priced vendors: Allegro CL and LispWorks. There were attempts to offer commercial CL systems - but none with emphasis on GUI (example Scieneer CL).

Re:A Book about Qt5 by pflanze on Monday March 04, 2019 @03:50PM (#19305294)
I'll mention an earlier comment of mine: https://news.ycombinator.com/item?id=18045890 (a Scheme interpreter running in C++ land, to communicate with via s-expressions (really Scheme code) from 'real' Scheme or Lisp systems. Extending its parser to support Clojure and CL is on my mind, extending the interpreter to run programs written in those languages (e.g. '(defun square (x) (* x x)) instead of '(define (square x) (* x x))) is of course also a possibility if deemed useful enough.)

My work was interrupted because my employer decided to scrap the project this was planned for. I've got permission to release it as open source, which I'll do ASAP (I'm in the middle of cleaning it up a bit). Incidentally my position was made redundant at the same time, so I'm currently looking for new work, most likely I won't have too much time to work on that in the near future, but I'll try to continue working it on the side and will be happy to help where I can. Send me mail to [email protected] if you'd like to be notified once it's up.

Re:A Book about Qt5 by p4bl0 on Monday March 04, 2019 @06:59AM (#19300580)
> I could use Racket and it's GUI library, but Racket is marketed as a language for creating languages, so I'll skip that.

Why? Racket is very far from only being a language research platform, it's also a very good general purpose programming languages, and its GUI framework is quite easy to use. I would give it a try if I were you :).

Re:A Book about Qt5 by _ph_ on Monday March 04, 2019 @05:33AM (#19300209)
Another option would be GTK. It is quite portable and while I haven't checked out the GTK libraries for Common Lisp, but as GTK is a pure C-based API, binding to it from other languages is very easy, so good bindings should be available. Personally, I have been using GTK3 via Go on Linux/Mac.

And for Common Lisp, there is of course LTk, it is extremely portable, but you have to live with the Tk UI toolkit (which got a pretty native look in the meantime).

Re:A Book about Qt5 by justinclift on Monday March 04, 2019 @07:23AM (#19300686)
Gtk itself is poorly documented for non-trivial examples, and doesn't seem all that stable across the years.

Qt on the other hand is well documented, and reasonably stable over the years.

Re:A Book about Qt5 by misja on Monday March 04, 2019 @04:21AM (#19299891)
Why not use Java 9 instead of 8? This could give your desktop app a smaller footprint (using the new modular jdk feature), so your app could start up faster.
Re:A Book about Qt5 by jyriand on Monday March 04, 2019 @06:18AM (#19300416)
I read somewhere that java 9 is not supporting JavaFX, I guess I could just add javafx as a dependency and it should work fine in java 9 also.
Re:A Book about Qt5 by misja on Monday March 04, 2019 @07:31AM (#19300735)
No it was removed only in JDK 11. Here's an example of a modular JDK 9 + JavaFX 9 app: https://carlfx.wordpress.com/2016/04/26/a-javafx-helloworld-...
Re:A Book about Qt5 by ethelward on Monday March 04, 2019 @09:53AM (#19301696)
Oh, I missed that. What is the officially sanctioned way to build GUI in Java 11 then? Swing?
Re:A Book about Qt5 by flavoie on Monday March 04, 2019 @03:12PM (#19304885)
They have decided to make it in a standalone package so it can evolve independently. Like xamarin is not part of .net

Its not about being supported or not. It's just an external. it's not up-to-date with java 11 https://openjfx.io/

You can also use clojure with it if you want a lisp dialect.

Re:A Book about Qt5 by j-pb on Monday March 04, 2019 @04:10AM (#19299847)
If you're using Java anyways, why not clojure? I've written both clojure an common lisp, and even though the immutable datastructures take some getting used to if you're from CL or Java, they're awesome, fast and make programming so much more fun.
Re:A Book about Qt5 by jyriand on Monday March 04, 2019 @06:17AM (#19300411)
I was thinking about clojure. I think only choice I have is to use 'seesaw'(wrapper for swing). I haven't seen any promising wrappers for javafx yet.
Re:A Book about Qt5 by robto on Monday March 04, 2019 @10:48AM (#19302113)
You should check out cljfx[0]! It's a re-frame-like wrapper for javafx, and it looks very well thought out. It's very well documented and the maintainer is very responsive if you need help.

[0]https://github.com/cljfx/cljfx

Re:A Book about Qt5 by MarvelousWololo on Monday March 04, 2019 @03:45AM (#19299742)
Hm I'm in the exact situation and I'm total beginner on desktop apps. I've been looking into Flutter for desktop but it isn't stable yet. If you ever come to a conclusion would you mind to share it? Thanks.
Re:A Book about Qt5 by SheinH on Monday March 04, 2019 @03:58AM (#19299797)
JavaFX is a great choice for beginners. Whatever app you make, anybody can run so long as the have the JRE installed.
Re:A Book about Qt5 by MarvelousWololo on Monday March 04, 2019 @09:49AM (#19301659)
Isn't it heavy and slow though? At least that's what I hear. I use android studio in a beefy macbook pro from time to time and it's slow as hell.
Re:A Book about Qt5 by SheinH on Wednesday March 06, 2019 @01:34PM (#19321309)
Jetbrains uses Swing not JavaFX from my knowledge. And yes, the performance can get slow for a Java app on the scale of Android studio but that shouldn't be of concern to a beginner.
Re:A Book about Qt5 by hanniabu on Monday March 04, 2019 @05:03AM (#19300076)
> as the have the JRE installed.

Does this come packed with most platforms (Mac, Linux, Windows)?

Re:A Book about Qt5 by izacus on Monday March 04, 2019 @05:48AM (#19300272)
No, but nothing else does either - you'll need to ship runtime environment in any case. And packing JRE is more cross-platform tested than most other solutions.
Re:A Book about Qt5 by kbp on Monday March 04, 2019 @09:52PM (#19307719)
LispWorks CAPI is very good. It's a shame it's proprietary and not cheap.
Re:A Book about Qt5 by rsp1984 on Monday March 04, 2019 @05:26AM (#19300180)
Why the focus on niche languages / frameworks? Why not make your life easy and use Qt (C++) or Electron (JS)?
Re:A Book about Qt5 by jyriand on Monday March 04, 2019 @06:25AM (#19300441)
I don't really know C++ and I'm sick of JS. But I will take a look into Qt.
Re:A Book about Qt5 by wjoe on Monday March 04, 2019 @09:11AM (#19301325)
You can also use Qt from Python using PyQt or PySide, which is officially supported as of recently - https://www.qt.io/qt-for-python

There are also Qt bindings for a bunch of other languages, but Python seems to be the best supported after C++

Re:A Book about Qt5 by iamcreasy on Wednesday March 06, 2019 @03:18PM (#19322352)
How about Xamarin?