Xcode 9 - Localization Issue Warning Storyboard

前端 未结 4 1237
无人共我
无人共我 2020-12-05 13:45

I am currently testing out Xcode 9 beta 3 at the time of this writing.

When viewing the storyboard I am receiving a list of warnings indicating that in other languag

4条回答
  •  我在风中等你
    2020-12-05 14:03

    You can also remove the Localization Issue warning by simply embedding the label or button in a transparent view. Then remove the fix width constraint from the label or button and set it to that container view instead.

    By using a container view you can silence the warning and still be able to localize the storyboard. Sometimes you need to have a label or button with a fix width even if the language is going to change, and if you are sure the fix width is big enough it shouldn't be a problem but Xcode doesn't know that, that's why you get the warning ;-)

提交回复
热议问题