Open milekpl opened 8 years ago
Here is the code that handles this:
If there are no suggestions, we show the message that language tool server returned in the msg field. For example, for two nouns together. You do not have a suggestion but you can tell the user what is the problem that the rule detected. This is not a "general message" it is the message returned by the rule. With Catalan language, this works fine. If you are seeming many general messages may be the rules return poor messages in the "msg" field. What are the rules that are triggering this problem? What are the message that you are seeing?
Regarding selecting the message changes the text what you are describing is correct. Unfortunately we cannot customize this behaviour since it is embed in Android operating system. We have two options or 1) we show the error and the user is aware of the problem or 2) we do not show the error and the user will be missing many useful errors that LT detected. I choose option 2.
Here's an example with German:
Der Haus
- only suggestions, no message
Ein großer Haus
- message as first suggestion, then rest of suggestions
I see. In some cases the returned msg field from LT is too long to be displayed.
What I suggest doing is:
Let me know if this makes sense to you
Thanks
Sounds good, but there's also a short message for some rules which could be used. It hadn't been part of the API response yet, but I've just added it and it will appear tonight at around 22:00 CET on our public HTTP server. The attribute is shortmsg
. There's no guarantee about its length, though.
For rules that offer no suggestions but a general message, selecting the message in the UI copies that message to the TextView control over the original text. This makes no sense for a lot of rules. Selecting the message should have no effect on the original text whatsover.