【问题标题】:How can I adjust the position of the textalignment in placeholder and the main text separately in swift?如何在 swift 中分别调整占位符和正文中文本对齐的位置?
【发布时间】:2017-07-01 22:46:18
【问题描述】:

如何在Swift中的UITextField中设置右侧占位符的textAlignment和左侧主要文本的textAlignment

【问题讨论】:

    标签: swift alignment placeholder


    【解决方案1】:

    在 Swift 中将 UITextField 设置为 natural textAlignment。在 Interface Builder 中,右侧与破折号对齐:

    【讨论】:

      猜你喜欢
      • 2014-01-28
      • 2018-10-05
      • 2017-03-24
      • 2014-10-29
      • 2015-12-31
      • 2013-12-21
      • 2020-10-25
      • 2015-04-08
      • 2016-09-24
      相关资源
      最近更新 更多