Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Highlight and validation of json syntax #11

Open
dzied-baradzied opened this issue Feb 14, 2019 · 2 comments
Open

Highlight and validation of json syntax #11

dzied-baradzied opened this issue Feb 14, 2019 · 2 comments

Comments

@dzied-baradzied
Copy link

It would be nice to have some colored highlighting of json messages on JSON Output tabs and colored highting with syntax validation on Produce message tab.

@alshpak
Copy link
Owner

alshpak commented Feb 15, 2019

Could you suggest any existing library?

@dzied-baradzied
Copy link
Author

dzied-baradzied commented Feb 15, 2019

According to my research, there are 2 possible ways:

  1. JavaFX native: https://github.com/FXMisc/RichTextFX
    Unfortunately, it doesn't provide ready JSON viewer/editor component. This is only base for your custom implementation. So it probably can take some big effort to implement rich component.
  2. Embed JS component using WebView.
    There are few rich code editors implemented on JS. Ace seems is one of the most popular (https://github.com/ajaxorg/ace). It has built-in support for validation and highlighting JSON syntax.
    Here is their demo app: https://ace.c9.io/build/kitchen-sink.html
    And this is JavaFX based project which embeds this editor: https://github.com/chaschev/bear
    Maybe it will give some tips.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants