iOS故事板本地化:UITextView文本未本地化?

iOS故事板本地化:UITextView文本未本地化?,ios,localization,uitextview,uistoryboard,Ios,Localization,Uitextview,Uistoryboard,我有一个基于故事板的应用程序,从德语本地化为英语 UI中的大多数字符串都正确地从Main.strings文件中提取,但UITextView中的所有文本除外,尽管它们确实出现在Main.strings文件中: /* Class = "IBUITextView"; text = "Die Futtermenge kann bei Hunden ab 12 Monaten anhand des Schiebreglers von 2% auf 5% des Körpergewichts verstel

我有一个基于故事板的应用程序,从德语本地化为英语

UI中的大多数字符串都正确地从Main.strings文件中提取,但UITextView中的所有文本除外,尽管它们确实出现在Main.strings文件中:

/* Class = "IBUITextView"; text = "Die Futtermenge kann bei Hunden ab 12 Monaten anhand des Schiebreglers von 2% auf 5% des Körpergewichts verstellt werden. Als Standart empfehlen wir 2% Futter vom Körpergewicht Ihres Hundes. Je nach Aktivität kann das abweichen. Wenn Sie bereits eine hohe Menge an Futter geben und Sie der Meinung sind, es ist nicht ausreichend, erhöhen Sie die Fettmenge im Futter. Mehr unter den Fragen & Antworten.\n \nFür Welpen und Junghunde gilt:\nWelpen 8 - 20 Woche: 7%\nJunghunde 21 - 35 Woche: 6%\nJunghunde 36 - 52 Woche: 5%"; ObjectID = "TAc-yh-nWQ"; */
"TAc-yh-nWQ.text" = "As of 12 months of age, you can use the slide ruler to adjust the food amount for dogs from 2% to 5% of body weight. As a baseline, we recommend 2% of your dog's weight to determine the amount of food. It will vary depending on activity. If you are already giving your dog a lot of food and you feel it is not sufficient, increase the fat content of the food. More information can be found in the FAQ section.\n \nFor puppies and young dogs:\nPuppies 8 - 20 weeks: 7%\nYoung dogs 21 - 35 weeks: 6%\nYoung dogs 36 - 52 weeks: 5%";
/* Class = "IBUILabel"; text = "Getreide:"; ObjectID = "VMF-xs-WfF"; */
"VMF-xs-WfF.text" = "Grains:";
/* Class = "IBUIButton"; normalTitle = "Gewicht aktualisieren..."; ObjectID = "WpP-c7-ipY"; */
"WpP-c7-ipY.normalTitle" = "Update weight...";
我的主弦有什么问题吗?上面是一段摘录。

看起来像是这样


您可以尝试这里推荐的“将可本地化字符串”更改为“Interface Builder Cocoa Touch XIB”方法,这似乎是一种奇怪的巫毒魔法,但如果它起作用,它就会起作用。否则,在运行时设置它似乎是必要的。

我的解决方案是使用Localizable.strings文件通过代码对TextView进行本地化。

如果使用.xliff方法,效果会更好吗?没有尝试过,我不知道如何做。你能告诉我怎么做吗?苹果的臭虫?我也有这个问题。你找到解决方案了吗?将其设置为XIB并返回字符串的方法对iOS 9不起作用。只是想说,这个“错误”仍然存在。。。很奇怪。经过这么长时间,它本应该被修好的。我想开发者们有更好的事情要做,比如喝咖啡或者吃苹果。令人惊讶的是,苹果从来没有修复过任何bug。今天是2020年2月,该漏洞仍然存在于iOS和macOS中。