Back to LanguageTool Homepage - Privacy - Imprint

Using LanguageTool with HTML formatting (TinyMCE)


(Michael) #1

Hello everyone!

I am trying to use LanguageTool whilst retaining HTML formatting in a TinyMCE instance.

I initiate a local server with the command
java -jar languagetool-server.jar --config server.properties --port 8081 --public --allow-origin '*'

LT will ignore the tags and return plain text, losing the original markup.

Has anyone implemented a solution using the AnnotatedTextBuilder class?
https://languagetool.org/development/api/org/languagetool/markup/AnnotatedTextBuilder.html

This functionality doesn't seem to be available using the json API.
https://languagetool.org/http-api/swagger-ui/#!/default/post_check

Many thanks,
Michael


(Daniel Naber) #2

I can confirm that. Pull requests for adding that to the API are welcome. Until then, you'd need to remember text/markup positions on the client side and try to use that information to apply the error messages to the correct positions.