Community Packages

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#72345 - [texstudio] languagetool not usable

Attached to Project: Community Packages
Opened by xsmile (xsmile) - Monday, 04 October 2021, 22:07 GMT
Last edited by Sven-Hendrik Haase (Svenstaro) - Tuesday, 12 October 2021, 13:07 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Sven-Hendrik Haase (Svenstaro)
Architecture All
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:

The currently included fs56433.patch does not enable the LanguageTool integration. The fixed version of the patch is as follows:
--- a/configmanager.cpp
+++ b/configmanager.cpp
@@ -631,7 +631,7 @@ ConfigManager::ConfigManager(QObject *pa
#else
registerOption("Grammar/Language Tool URL", &grammarCheckerConfig->languageToolURL, "http://localhost:8081/", &pseudoDialog->lineEditGrammarLTUrl);
#endif
- registerOption("Grammar/Language Tool Path", &grammarCheckerConfig->languageToolPath, "", &pseudoDialog->lineEditGrammarLTPath);
+ registerOption("Grammar/Language Tool Path", &grammarCheckerConfig->languageToolPath, "/usr/share/languagetool:/usr/share/java/languagetool/*", &pseudoDialog->lineEditGrammarLTPath);
registerOption("Grammar/Language Tool Arguments", &grammarCheckerConfig->languageToolArguments, "org.languagetool.server.HTTPServer -p 8081", &pseudoDialog->lineEditGrammarLTArguments);
registerOption("Grammar/Language Tool Java Path", &grammarCheckerConfig->languageToolJavaPath, "java", &pseudoDialog->lineEditGrammarLTJava);
registerOption("Grammar/Language Tool Autorun", &grammarCheckerConfig->languageToolAutorun, true, &pseudoDialog->checkBoxGrammarLTAutorun);
--- a/grammarcheck.cpp
+++ b/grammarcheck.cpp
@@ -639,11 +639,6 @@ void GrammarCheckLanguageToolJSON::tryTo
startTime = 0;
if (ltPath == "")
return;
- if(!QFileInfo::exists(ltPath)){
- errorText=QString("LT path \" %1 \" not found !").arg(ltPath);
- emit errorMessage(errorText);
- return;
- }
javaProcess = new QProcess();
connect(javaProcess, SIGNAL(finished(int,QProcess::ExitStatus)), javaProcess, SLOT(deleteLater()));
connect(this, SIGNAL(destroyed()), javaProcess, SLOT(deleteLater()));

Thanks.
This task depends upon

Closed by  Sven-Hendrik Haase (Svenstaro)
Tuesday, 12 October 2021, 13:07 GMT
Reason for closing:  Fixed
Comment by Sven-Hendrik Haase (Svenstaro) - Monday, 11 October 2021, 01:19 GMT
Thanks, could you attach the patch as a file?
Comment by xsmile (xsmile) - Monday, 11 October 2021, 10:09 GMT
Of course, here it is.
Comment by Sven-Hendrik Haase (Svenstaro) - Tuesday, 12 October 2021, 02:07 GMT
I pushed 4.0.1 with your patch into [community]. Can you check?
Comment by xsmile (xsmile) - Tuesday, 12 October 2021, 10:07 GMT
4.0.1 works well. Thanks again.

Loading...