使用Base Internationalization,基于Object ID生成自动本地化变得非常容易。这是法语版的东西。
/* Class = "IBUILabel"; text = "Clear Memory"; ObjectID = "fHm-5n-KrF"; */
"fHm-5n-KrF.text" = "Effacer la mémoire";
但这仅限于Xcode可以在故事板中找到的内容。
应该可以在AlertView中包含文本字符串。当然。
UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Wheel Cicumference" message:@"Ground Trace (mm):" delegate:self cancelButtonTitle:@"Cancel" otherButtonTitles:nil];
alert.alertViewStyle = UIAlertViewStylePlainTextInput;
alert.tag = 10;
[alert addButtonWithTitle:@"Accept"];
[alert show];
Apple文档很广泛,到目前为止我还没有找到任何有意义的东西。我不一定完全没有为我提出答案,只是把我放在一般方向
答案 0 :(得分:0)
我知道本地化UIAlert
的唯一方法如下:
UIAlertView *alert = [[UIAlertView alloc] initWithTitle:NSLocalizedString(@"Error", @"Error")
message:NSLocalizedString(message, message) delegate:nil
cancelButtonTitle:NSLocalizedString(@"OK", @"OK") otherButtonTitles:nil];