eclipse / tm4e

TextMate support in Eclipse IDE
https://projects.eclipse.org/projects/technology.tm4e
Eclipse Public License 2.0
84 stars 56 forks source link

a TextMate grammar editor? #96

Open mickaelistria opened 7 years ago

mickaelistria commented 7 years ago

Currently, editing TextMate grammar is a bit of a nightmare ;) I would be nice if TM4E could provide a rich TextMate grammar editor, with a preview mechanism, using a "split" editor (one side edition, other side preview) or populating the Outline view with a text area showing preview, or adding a new "Preview" view (covered in #97).

mickaelistria commented 7 years ago

cc @akurtakov

angelozerr commented 7 years ago

You read in my mind @mickaelistria :)

Yes I would like to provide this kind of editor like PDE editor with Overview, Rules, Source page.

My idea is to develop this editor based on FormEditor to provide nicely UI like PDE and benefit with master details feature (for rule for instance). @mickaelistria what do you think?

For the moment I'm busy with https://github.com/eclipse/tm4e/issues/94 (I'm developping an Import wizard for that, I will ping you as soon as I have something and tell you what you will think about my idea).

mickaelistria commented 7 years ago

The only concern I have is that if you're opting for a tab-editor, it's really annoying to switch between edition and preview with tabs. I just think the preview should be in a separate view for best results. And at the moment, I believe the preview would be more valuable for TextMate grammar developers than the editor actually. Both could be implemented separately. I'm going to open a bug for the preview (in outline or wherever not in the editor).

angelozerr commented 7 years ago

I agree with you, preview tab was not in my mind. Preview should be hosted in a View (like JavaDoc view)

My idea was to displays TextMate rules in a list and when you select an item it displays rule content on the right side (like Extension Points PDE tab with master detail feature)

I think we should have a TextMate Perspective which opens several views to provide several views like http://tmtheme-editor.herokuapp.com/#!/editor/theme/Monokai:

image

image

image

After when you edit theme or grammar and change it, the TMPresentationReconciler could be refresed with new theme content or new grammar syntax.

What do you think about that?

ainslec commented 7 years ago

@mickaelistria

At the risk of plugging my own stuff, I have been developing a web based textmate grammar editor / debugger with stack introspection. You can also export to Ace editor.

http://eeyo.io/iro