Merge pull request #39 from dtimson/master

bugfix for reading style names
This commit is contained in:
Jan W. Krieger 2020-02-25 07:44:17 +01:00 committed by GitHub
commit 2b942e1e2d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -103,7 +103,7 @@ void JKQTBasePlotterStyle::loadSettings(const QSettings &settings, const QString
QString kk=k;
kk.remove(0, start.size());
QString num="";
while (kk.at(0).isDigit()) {
while (!kk.isEmpty() && kk.at(0).isDigit()) {
num+=kk.at(0);
kk.remove(0, 1);
}

View File

@ -84,7 +84,7 @@ void JKQTPlotterStyle::loadSettings(const QSettings &settings, const QString &gr
QString kk=k;
kk.remove(0, start.size());
QString num="";
while (kk.at(0).isDigit()) {
while (!kk.isEmpty() && kk.at(0).isDigit()) {
num+=kk.at(0);
kk.remove(0, 1);
}