Difference between revisions of "Projectional editor"

From apm
Jump to: navigation, search
(Experimental toy/research projects: added tylr & added note on curor algebra in fructure)
m (Experimental toy/research projects)
(23 intermediate revisions by the same user not shown)
Line 1: Line 1:
{{Stub}}
+
Closely related but not identical: [[Structural editor]]
 +
----
 +
Projectional code editors are special code editors that <br>
 +
do not show the source-code of a program to the user/programmer directly but rather ...
 +
* have all source-code in a hidden internal representation (not necessarily optimized for human readability, stored in the AST … abstract syntax tree)
 +
* "project" this internal representation of the language onto one (or several) user/programmer facing representation(s)
  
== Serious projects aiming to become at a practically usable programming language ==
+
Projectional editors allow to show the same piece of code in various ways. This can mean ...
 +
* different kinds of programming language syntax
 +
* one or more visual programming projections
 +
* very problem specific projections that just work on a subset of the language, On a DSL (domain specific language)
  
* unison – https://www.unisonweb.org/ – fist implemented code-projection is '''projection into plain text-files'''
+
Specific DSL projections may include ...
* Enso (former luna) – https://enso.org/
+
* projection for [[3D modeling]], processing of data of various types with natural representations, ...
 +
* all the projections (and more) that are listed on the page: [[Higher level computer interfaces for deveusers]]
 +
 
 +
== Relation to structural editing ==
 +
 
 +
Code projections can, but not necessarily need to (!), put restrictions on code editability.
 +
 
 +
'''Projectional editing but not [[structural editing]]:''' <br>
 +
If code is dumped from AST to plaintext and slurped up from plaintext to AST <br>
 +
then there are obviously no restrictions to what can be typed. <br>
 +
'''Projectional editing and [[structural editing]]:''' <br>
 +
If the code editor is not a typical text editor but a special editor that already <br>
 +
only allows code edits to states that will be representable within the internal representation. <br>
 +
Note that this can be impractical to use if improperly designed. See: [[Structural editor]]
 +
 
 +
== Advantages ==
 +
 
 +
Projectional editors can simplify working on problems as <br>
 +
projectional editors allow to use the right tool for the right job <br>
 +
 
 +
Also while allowing so they still retain only one single unified language in the hidden background. <br>
 +
Having a single language in the background can prevent proliferation of software tools/frameworks <br>
 +
with ad-hoc hacked together informal bug-ridden language-plumbing-interfaces to the point of <br>
 +
Ruben Goldberg machines and fragile Frankestein systems riddled with hidden out of sync state. <br>
 +
See related pages: [[Content addressed]] & [[Purely functional programming]] <br>
 +
 
 +
== Projects aiming to become at a practically usable programming language soon  ==
 +
 
 +
* unison – https://www.unisonweb.org/ – fist implemented code-projection is '''projection into plain text-files''' (no structural editor yet as of 2022-12)
 +
* enso (former luna) – https://enso.org/
  
 
== Experimental toy/research projects ==
 
== Experimental toy/research projects ==
Line 10: Line 47:
 
* fructure – Andrew Bilnn – [https://fructure-editor.tumblr.com/ fructure editor (website)] – [https://youtu.be/CnbVCNIh1NA (ninth RacketCon): Andrew Blinn – Fructure: A Structured Editing Engine in Racket] – upload 2019-07-19 <br>– there is a focus on [[typing normally]] – interesting aspect: algebra for the curser
 
* fructure – Andrew Bilnn – [https://fructure-editor.tumblr.com/ fructure editor (website)] – [https://youtu.be/CnbVCNIh1NA (ninth RacketCon): Andrew Blinn – Fructure: A Structured Editing Engine in Racket] – upload 2019-07-19 <br>– there is a focus on [[typing normally]] – interesting aspect: algebra for the curser
 
* hazel – https://hazel.org/
 
* hazel – https://hazel.org/
 +
* ( isomorf – https://isomorf.io/#!/ – login wall )
 
* lambdu – http://www.lamdu.org/
 
* lambdu – http://www.lamdu.org/
* ( isomorf – https://isomorf.io/#!/ )
+
* List of structural editors. Most are projectional too. <br>https://github.com/yairchu/awesome-structure-editors/blob/main/README.md
 +
 
 
----
 
----
 +
By the author so called "'''tile-based editing'''":
 
* https://tylr.fun/ – [https://twitter.com/dm_0ney/status/1414742742530498566?s=09 (some info in twitter)] – single line structural editing interactive demo – focus on [[typing normally]]
 
* https://tylr.fun/ – [https://twitter.com/dm_0ney/status/1414742742530498566?s=09 (some info in twitter)] – single line structural editing interactive demo – focus on [[typing normally]]
  
 
== Related ==
 
== Related ==
  
* [[programming languages]]
+
* '''[[Structural editor]]'''
 +
----
 +
* '''[[Programming languages]]'''
 
* [[Software]]
 
* [[Software]]
 
* [[Annotated lambda diagrams]] and [[Annotated lambda diagram mockups]] – also a code projection
 
* [[Annotated lambda diagrams]] and [[Annotated lambda diagram mockups]] – also a code projection
 
* [[Higher level computer interfaces for deveusers]]
 
* [[Higher level computer interfaces for deveusers]]
 +
 +
* [[Diffing]]
  
 
== External links ==
 
== External links ==
  
* [https://en.wikipedia.org/wiki/Structure_editor Structure editor]
+
* Wikipedia: [https://en.wikipedia.org/wiki/Structure_editor Structure editor]
* [https://www.reddit.com/r/nosyntax/wiki/projects collection of structured editor projects]
+
* Reddit: [https://www.reddit.com/r/nosyntax/wiki/projects collection of structured editor projects]
 +
 
 +
[[Category:Programming]]

Revision as of 22:11, 3 January 2023

Closely related but not identical: Structural editor


Projectional code editors are special code editors that
do not show the source-code of a program to the user/programmer directly but rather ...

  • have all source-code in a hidden internal representation (not necessarily optimized for human readability, stored in the AST … abstract syntax tree)
  • "project" this internal representation of the language onto one (or several) user/programmer facing representation(s)

Projectional editors allow to show the same piece of code in various ways. This can mean ...

  • different kinds of programming language syntax
  • one or more visual programming projections
  • very problem specific projections that just work on a subset of the language, On a DSL (domain specific language)

Specific DSL projections may include ...

Relation to structural editing

Code projections can, but not necessarily need to (!), put restrictions on code editability.

Projectional editing but not structural editing:
If code is dumped from AST to plaintext and slurped up from plaintext to AST
then there are obviously no restrictions to what can be typed.
Projectional editing and structural editing:
If the code editor is not a typical text editor but a special editor that already
only allows code edits to states that will be representable within the internal representation.
Note that this can be impractical to use if improperly designed. See: Structural editor

Advantages

Projectional editors can simplify working on problems as
projectional editors allow to use the right tool for the right job

Also while allowing so they still retain only one single unified language in the hidden background.
Having a single language in the background can prevent proliferation of software tools/frameworks
with ad-hoc hacked together informal bug-ridden language-plumbing-interfaces to the point of
Ruben Goldberg machines and fragile Frankestein systems riddled with hidden out of sync state.
See related pages: Content addressed & Purely functional programming

Projects aiming to become at a practically usable programming language soon

Experimental toy/research projects


By the author so called "tile-based editing":

Related


External links