logic: fixed crash when specifying an unknown text encoding in appsettings
* also: updated jar dependencies
This commit is contained in:
@@ -819,7 +819,7 @@
|
||||
<File Id='OrgEclipseCoreFilesystem' Name='org.eclipse.core.filesystem-1.7.0.jar' DiskId='1' Source='./../../../bin/app/data/java/lib/org.eclipse.core.filesystem-1.7.0.jar' KeyPath='yes' />
|
||||
</Component>
|
||||
<Component Id='JavaOrgEclipseCoreJobsJar' Guid='*' Win64="$(var.Win64)">
|
||||
<File Id='OrgEclipseCoreJobs' Name='org.eclipse.core.jobs-3.9.0.jar' DiskId='1' Source='./../../../bin/app/data/java/lib/org.eclipse.core.jobs-3.9.0.jar' KeyPath='yes' />
|
||||
<File Id='OrgEclipseCoreJobs' Name='org.eclipse.core.jobs-3.9.1.jar' DiskId='1' Source='./../../../bin/app/data/java/lib/org.eclipse.core.jobs-3.9.1.jar' KeyPath='yes' />
|
||||
</Component>
|
||||
<Component Id='JavaOrgEclipseCoreResourcesJar' Guid='*' Win64="$(var.Win64)">
|
||||
<File Id='OrgEclipseCoreResources' Name='org.eclipse.core.resources-3.12.0.jar' DiskId='1' Source='./../../../bin/app/data/java/lib/org.eclipse.core.resources-3.12.0.jar' KeyPath='yes' />
|
||||
@@ -843,7 +843,7 @@
|
||||
<File Id='OrgEclipseJdtCore' Name='org.eclipse.jdt.core-3.13.0.jar' DiskId='1' Source='./../../../bin/app/data/java/lib/org.eclipse.jdt.core-3.13.0.jar' KeyPath='yes' />
|
||||
</Component>
|
||||
<Component Id='JavaOrgEclipseOsgiJar' Guid='*' Win64="$(var.Win64)">
|
||||
<File Id='OrgEclipseOsgi' Name='org.eclipse.osgi-3.12.0.jar' DiskId='1' Source='./../../../bin/app/data/java/lib/org.eclipse.osgi-3.12.0.jar' KeyPath='yes' />
|
||||
<File Id='OrgEclipseOsgi' Name='org.eclipse.osgi-3.12.50.jar' DiskId='1' Source='./../../../bin/app/data/java/lib/org.eclipse.osgi-3.12.50.jar' KeyPath='yes' />
|
||||
</Component>
|
||||
<Component Id='JavaOrgEclipseTextJar' Guid='*' Win64="$(var.Win64)">
|
||||
<File Id='OrgEclipseText' Name='org.eclipse.text-3.6.100.jar' DiskId='1' Source='./../../../bin/app/data/java/lib/org.eclipse.text-3.6.100.jar' KeyPath='yes' />
|
||||
|
||||
@@ -49,14 +49,22 @@ QtCodeField::QtCodeField(
|
||||
}
|
||||
|
||||
QTextCodec* codec = QTextCodec::codecForName(ApplicationSettings::getInstance()->getTextEncoding().c_str());
|
||||
QString convertedDisplayCode(codec->toUnicode(displayCode.c_str()));
|
||||
setPlainText(convertedDisplayCode);
|
||||
createLineLengthCache();
|
||||
if (displayCode.size() != convertedDisplayCode.length())
|
||||
if (codec)
|
||||
{
|
||||
LOG_INFO("Converting displayed code to " + codec->name().toStdString() + " resulted in offset of source locations. Correcting this now.");
|
||||
createMultibyteCharacterLocationCache();
|
||||
QString convertedDisplayCode(codec->toUnicode(displayCode.c_str()));
|
||||
setPlainText(convertedDisplayCode);
|
||||
if (displayCode.size() != convertedDisplayCode.length())
|
||||
{
|
||||
LOG_INFO("Converting displayed code to " + codec->name().toStdString() + " resulted in offset of source locations. Correcting this now.");
|
||||
createMultibyteCharacterLocationCache();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
setPlainText(displayCode.c_str());
|
||||
}
|
||||
|
||||
createLineLengthCache();
|
||||
|
||||
this->setMouseTracking(true);
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@ namespace utility
|
||||
"org.eclipse.core.contenttype-3.6.0.jar",
|
||||
"org.eclipse.core.expressions-3.6.0.jar",
|
||||
"org.eclipse.core.filesystem-1.7.0.jar",
|
||||
"org.eclipse.core.jobs-3.9.0.jar",
|
||||
"org.eclipse.core.jobs-3.9.1.jar",
|
||||
"org.eclipse.core.resources-3.12.0.jar",
|
||||
"org.eclipse.core.runtime-3.13.0.jar",
|
||||
"org.eclipse.equinox.app-1.3.400.jar",
|
||||
@@ -24,7 +24,7 @@ namespace utility
|
||||
"org.eclipse.equinox.preferences-3.7.0.jar",
|
||||
"org.eclipse.equinox.registry-3.7.0.jar",
|
||||
"org.eclipse.jdt.core-3.13.0.jar",
|
||||
"org.eclipse.osgi-3.12.0.jar",
|
||||
"org.eclipse.osgi-3.12.50.jar",
|
||||
"org.eclipse.text-3.6.100.jar",
|
||||
"slf4j-api-1.7.10.jar",
|
||||
"slf4j-simple-1.7.10.jar"
|
||||
|
||||
Reference in New Issue
Block a user