I did try to change the language but when using the method .language() it shows me that en_US is enabled. I do not why this is the case. Could look over my implementation ? Thanks in advance for your help!
Here ist the print out in the debugger:
Here is the file structure
Last, but not least the implementation:
// Configure the iink runtime environment
let configurationPath = Bundle.main.bundlePath.appending("/recognition-assets/conf")
// Tells the engine where to load the recognition assets from.
Thanh Hoang
I did try to change the language but when using the method .language() it shows me that en_US is enabled. I do not why this is the case. Could look over my implementation ? Thanks in advance for your help!
Here ist the print out in the debugger:
Here is the file structure
Last, but not least the implementation:
// Configure the iink runtime environment
let configurationPath = Bundle.main.bundlePath.appending("/recognition-assets/conf")
// Tells the engine where to load the recognition assets from.
do {
try engine.configuration.set(stringArray: [configurationPath],
forKey: "configuration-manager.search-path") // Tells the engine where to load the recognition assets from.
} catch {
print("Should not happen, please check your resources assets : " + error.localizedDescription)
return nil
}
// Set the temporary directory
do {
try engine.configuration.set(string: NSTemporaryDirectory(),
forKey: "content-package.temp-folder")
} catch {
print("Failed to set temporary folder: " + error.localizedDescription)
return nil
}
// Load german language
do {
try engine.configuration.set(string: "lang", forKey: "de_DE")
} catch {
print("Error while loading the german language pack")
return nil
}
Dear Thanh Hoang,
Thank you for your question.
I think you should reverse the key and value in your language configuration:
try engine.configuration.set(string: "de_DE", forKey: "lang")
Please, let us know if this fixes your issue.
Best regards,
Gwenaëlle
- Oldest First
- Popular
- Newest First
Sorted by PopularGwenaelle @MyScript
Dear Thanh Hoang,
Thank you for your question.
I think you should reverse the key and value in your language configuration:
try engine.configuration.set(string: "de_DE", forKey: "lang")
Please, let us know if this fixes your issue.
Best regards,
Gwenaëlle
1 person likes this
Thanh Hoang
Dear Gwenaëlle,
thanks! It works!
Could you update your site https://developer.myscript.com/docs/interactive-ink/2.1/ios/fundamentals/interactive-ink-runtime ? This line should be wrong, too:
configuration.set(string: "lang", forKey: "it_IT")
Gwenaelle @MyScript
Dear Thanh Hoang,
Glad to see you succeeded in changing your language configuration.
Thank you for your update and pointing out this error in our documentation.
We will fix it accordingly!
Best regards,
Gwenaëlle