带标签的iOS 7故事板本地化 [英] iOS 7 storyboard localization with attributed Labels

查看:51
本文介绍了带标签的iOS 7故事板本地化的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用我的基本情节提要板针对所有语言从ibtool生成我的字符串文件...出于某种原因,ibtool并未提取样式为归因"的UILabel ...

I am generating my String- Files with ibtool from my Base Storyboard for all my languages...For some reason ibtool is not extracting UILabels with style "attributed"...

我没有这些标签的键/值对...有人知道为什么吗?!

I have no Key/Value Pair for those labels...Does somebody has a clue why?!

推荐答案

我最终得出结论,无法使用ibtool在 当前版本.

I ended up concluding that it couldn't be done using ibtool in the present version.

相反,我将Textview设为纯文本视图,并使用 子类,解析其text属性,以便我可以 NSMutableAttributedString并设置所需的属性.

Instead I let the Textview be a plain text view and, using my subclass, parsed its text property so I could make a NSMutableAttributedString and set the needed properties.

这使我能够使用ibtool提取字符串,并且仍然有一个 归因于textview.

That enabled me to use ibtool to extract the strings and still have an attributed textview.

从情节提要中本地化UITextView

这篇关于带标签的iOS 7故事板本地化的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆