TextField Width

  1. 10 months ago

    TheMexican

    15 Sep 2017 User since 2016

    I cannot increase the width of a TextField. It stays at 30.
    Is this by design or is this a bug?

  2. andrea

    15 Sep 2017 Administrator User since 2016

    Hi @TheMexican,
    the fixed value of 30 for the height of the TextField is a 'suggestion' by Apple (Human Interface Guidelines, and also the Interface Builder in XCode doesn't allow to change the height), not a real constraint of the control. For this reason, the TextField inspector prevents you to change the height, but if you really need to do so you can change it programmatically. For example, you can add the following code to the DidShow event of the window which contains your text fields:
    TextField1.frame.size.height = 50;

  3. TheMexican

    15 Sep 2017 User since 2016

    Thank You, it worked!

or Sign Up to reply!