texstudio/texstudio-4.3.1-fs72345.patch

26 lines
1.6 KiB
Diff

--- 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()));