What about a Scala Text Editor?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|

What about a Scala Text Editor?

Rich Oliver
I see the Scala IDE team are considering replacing Eclipse as their target platform. What about creating a Text editor written in Scala from the ground up? That could be used as a foundation for an IDE but would also be an embeddable resource in Scala applications, potentially available across JVM, web and native. Obviously that would require significant work, however without it Scala will always be a second class citizen in its eco system.

--
You received this message because you are subscribed to the Google Groups "scala-debate" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: What about a Scala Text Editor?

Zack Powers
There's been one for some time now, haven't personally tried it: https://github.com/scaled/scaled

On Monday, November 21, 2016 at 8:03:08 AM UTC-5, Rich Oliver wrote:
I see the Scala IDE team are considering replacing Eclipse as their target platform. What about creating a Text editor written in Scala from the ground up? That could be used as a foundation for an IDE but would also be an embeddable resource in Scala applications, potentially available across JVM, web and native. Obviously that would require significant work, however without it Scala will always be a second class citizen in its eco system.

--
You received this message because you are subscribed to the Google Groups "scala-debate" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: What about a Scala Text Editor?

Simon Schäfer
In reply to this post by Rich Oliver

---- On Mon, 21 Nov 2016 14:03:08 +0100Rich Oliver <[hidden email]> wrote ----

I see the Scala IDE team are considering replacing Eclipse as their target platform. What about creating a Text editor written in Scala from the ground up?

Such projects already exists but I can't name any of them right now. But these are all personal projects of a single person afaik, no funding behind it.

That could be used as a foundation for an IDE but would also be an embeddable resource in Scala applications, potentially available across JVM, web and native. Obviously that would require significant work,

Yes it is significant work, too much for the Scala community to handle alone (or for any community to handle alone). Visual Studio Code for example is the result of many companies investing in different parts of the editor and in its dependencies. There may be only a handful of people involved for putting the components together to a usable editor but there are countless of "invisible" people involved to make the end result possible.

however without it Scala will always be a second class citizen in its eco system.

Scala is mostly used for server side applications, hardly anyone cares about GUI applications that are written in Scala (and that is what a text editor is). The future of the GUI is in the web. Therefore if you want to build an editor you have to embrace web technologies - this is what Visual Studio Code did, it was the right decision and because of it they are successful with it.

Beside from that I agree with the second class status of Scala within its eco system. I can see how this problem can be resolved in the long term for the backend of GUI applications but the frontend will never be first class in Scala (i.e. completely written in Scala) - it is simply not the direction in which the ecosystem is moving.

--
You received this message because you are subscribed to the Google Groups "scala-debate" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: What about a Scala Text Editor?

Justin du coeur
On Mon, Nov 21, 2016 at 10:08 AM, Simon Schäfer <[hidden email]> wrote:
Beside from that I agree with the second class status of Scala within its eco system. I can see how this problem can be resolved in the long term for the backend of GUI applications but the frontend will never be first class in Scala (i.e. completely written in Scala) - it is simply not the direction in which the ecosystem is moving.

Strong statement, and I'm not sure I agree -- Web development does seem to be slowly but surely moving in that direction.  We're a good ways from being there yet, but I'm seeing gradual motion towards making the Scala layer larger and the JavaScript one smaller; I'd actually be surprised if we *don't* have reasonably functional all-Scala Web-UI frameworks cropping up in the next two years.

Of course, there will still be JavaScript underneath, but as far as I'm concerned that's the same as having JVM bytecode underneath.  If the *libraries* are written in Scala, then JavaScript is just a fancy compilation target.

--
You received this message because you are subscribed to the Google Groups "scala-debate" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: What about a Scala Text Editor?

Tomas Mikula
In reply to this post by Simon Schäfer
On Monday, November 21, 2016 at 10:08:26 AM UTC-5, Simon Schäfer wrote:
hardly anyone cares about GUI applications that are written in Scala

That might be just a consequence of there not being a Scala UI toolkit. I would much prefer to write GUIs in Scala (given there is a reasonable, FP based, GUI toolkit) than in either JavaScript or JavaFX.

I was even considering rewriting my RichTextFX editor [1] from Java(FX) to Scala, but I concluded that it is probably not worth the effort if there remain too many leaks of the JavaFX programming model.

On Monday, November 21, 2016 at 12:16:33 PM UTC-5, Justin du Coeur wrote:
Of course, there will still be JavaScript underneath, but as far as I'm concerned that's the same as having JVM bytecode underneath.  If the *libraries* are written in Scala, then JavaScript is just a fancy compilation target.

Exactly my thoughts. And there could also be other compilation targets, e.g. JavaFX.

Regards,
Tomas

[1] https://github.com/TomasMikula/RichTextFX/

--
You received this message because you are subscribed to the Google Groups "scala-debate" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: What about a Scala Text Editor?

Haoyi Li
> Yes it is significant work, too much for the Scala community to handle alone (or for any community to handle alone)

Not doubting that it would be a lot of work to build an editor from scratch, but Sublime Text was basically written by one person for many few years (I heard he ended up hiring one more to help manage the package ecosystem), and it seems TextMate was written by 2 people (according to Wikipedia). Sure they had third parties interested/involved enough to write e.g. language plugins, but those came for "free" given the strength of the core editor.

So it's a lot of work, but if you think you can charge 20$ per seat and get a few thousand people to use it, it could well be a successful/profitable solo venture.

On Tue, Nov 22, 2016 at 2:52 AM, Tomas Mikula <[hidden email]> wrote:
On Monday, November 21, 2016 at 10:08:26 AM UTC-5, Simon Schäfer wrote:
hardly anyone cares about GUI applications that are written in Scala

That might be just a consequence of there not being a Scala UI toolkit. I would much prefer to write GUIs in Scala (given there is a reasonable, FP based, GUI toolkit) than in either JavaScript or JavaFX.

I was even considering rewriting my RichTextFX editor [1] from Java(FX) to Scala, but I concluded that it is probably not worth the effort if there remain too many leaks of the JavaFX programming model.

On Monday, November 21, 2016 at 12:16:33 PM UTC-5, Justin du Coeur wrote:
Of course, there will still be JavaScript underneath, but as far as I'm concerned that's the same as having JVM bytecode underneath.  If the *libraries* are written in Scala, then JavaScript is just a fancy compilation target.

Exactly my thoughts. And there could also be other compilation targets, e.g. JavaFX.

Regards,
Tomas

--
You received this message because you are subscribed to the Google Groups "scala-debate" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "scala-debate" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: What about a Scala Text Editor?

Simon Schäfer
In reply to this post by Rich Oliver



---- On Tue, 22 Nov 2016 00:41:07 +0100Haoyi Li <[hidden email]> wrote ----

> Yes it is significant work, too much for the Scala community to handle alone (or for any community to handle alone)


Not doubting that it would be a lot of work to build an editor from scratch, but Sublime Text was basically written by one person for many few years (I heard he ended up hiring one more to help manage the package ecosystem), and it seems TextMate was written by 2 people (according to Wikipedia). Sure they had third parties interested/involved enough to write e.g. language plugins, but those came for "free" given the strength of the core editor.

Creating a text editor is indeed not too hard but I (and I think even the OP) was implicitly talking about IDEs, which are more difficult to create. The problem is that none of the new text editors (except Visual Studio Code and Atom) are powerful enough to handle even the most powerful IDE features. New lightweight editors - while welcome - are not needed. But what people need are new IDEs.

So it's a lot of work, but if you think you can charge 20$ per seat and get a few thousand people to use it, it could well be a successful/profitable solo venture.

On Tue, Nov 22, 2016 at 2:52 AM, Tomas Mikula <[hidden email]> wrote:



--
You received this message because you are subscribed to the Google Groups "scala-debate" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
On Monday, November 21, 2016 at 10:08:26 AM UTC-5, Simon Schäfer wrote:
hardly anyone cares about GUI applications that are written in Scala


That might be just a consequence of there not being a Scala UI toolkit. I would much prefer to write GUIs in Scala (given there is a reasonable, FP based, GUI toolkit) than in either JavaScript or JavaFX.

I was even considering rewriting my RichTextFX editor [1] from Java(FX) to Scala, but I concluded that it is probably not worth the effort if there remain too many leaks of the JavaFX programming model.

On Monday, November 21, 2016 at 12:16:33 PM UTC-5, Justin du Coeur wrote:
Of course, there will still be JavaScript underneath, but as far as I'm concerned that's the same as having JVM bytecode underneath.  If the *libraries* are written in Scala, then JavaScript is just a fancy compilation target.

Exactly my thoughts. And there could also be other compilation targets, e.g. JavaFX.

Regards,
Tomas


--
You received this message because you are subscribed to the Google Groups "scala-debate" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "scala-debate" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: What about a Scala Text Editor?

Simon Schäfer
In reply to this post by Justin du coeur



---- On Mon, 21 Nov 2016 18:16:30 +0100Justin du coeur <[hidden email]> wrote ----

On Mon, Nov 21, 2016 at 10:08 AM, Simon Schäfer <[hidden email]> wrote:

Beside from that I agree with the second class status of Scala within its eco system. I can see how this problem can be resolved in the long term for the backend of GUI applications but the frontend will never be first class in Scala (i.e. completely written in Scala) - it is simply not the direction in which the ecosystem is moving.

Strong statement, and I'm not sure I agree -- Web development does seem to be slowly but surely moving in that direction.  We're a good ways from being there yet, but I'm seeing gradual motion towards making the Scala layer larger and the JavaScript one smaller; I'd actually be surprised if we *don't* have reasonably functional all-Scala Web-UI frameworks cropping up in the next two years.

That is what I meant. first class means the entire stack is written in one language/technology, second class only means the last layer.

Of course, there will still be JavaScript underneath, but as far as I'm concerned that's the same as having JVM bytecode underneath.  If the *libraries* are written in Scala, then JavaScript is just a fancy compilation target.

No, that is different. The JVM is a thinner runtime than the browser. The JVM has less control over the last layer. For the JS ecosystem it is more problematic because the browser ships with the DOM and Electron (a thin browser bundled as a desktop application) ships with Node.js and with the DOM. Therefore in the JS ecosystem one is more limited by JS than how one is limited by Java on the JVM. I do not like to be controlled (or limited) by Java dependencies as it is the case right now for the Scala ecosystem. However, I believe that this limitation can be lifted and first class status can be achieved (that is why I actively work on making it a reality). Getting rid of the DOM is at least for now not possible (nor desirable in my eyes) that is why I consider Scala compiled to JS of second class status.

--
You received this message because you are subscribed to the Google Groups "scala-debate" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: What about a Scala Text Editor?

Tomas Mikula


On Mon, Nov 21, 2016 at 8:13 PM, Simon Schäfer <[hidden email]> wrote:

Getting rid of the DOM is at least for now not possible (nor desirable in my eyes) that is why I consider Scala compiled to JS of second class status.

I think it is possible: the Scala UI framework could be built on top of some primitives like canvas and/or SVG, plus assuming native support for text, images, video... An implementation can then use DOM, JavaFX, or something else. Of course there are a lot of important details to work out (e.g. event handling, complex layouts that require measurements of previously displayed nodes, ...), but I don't see why this would not be possible in principle.

--
You received this message because you are subscribed to the Google Groups "scala-debate" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.