Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Presetting text programatically loses padding #174

Open
pratikgujarati7 opened this issue Aug 16, 2017 · 3 comments
Open

Presetting text programatically loses padding #174

pratikgujarati7 opened this issue Aug 16, 2017 · 3 comments

Comments

@pratikgujarati7
Copy link

I am trying to preset some text in JVFloatLabeledTextField on controller's viewDidLoad. As soon as i try to edit the textfield it becomes normal. Please find attached screenshot. FYI : I am using autoresizing with XIB.
simulator screen shot 16-aug-2017 6 02 25 pm

@RajkumarLoganathan
Copy link

RajkumarLoganathan commented Sep 1, 2017

Set TextField text in viewDidAppear

-(void)viewDidAppear:(BOOL)animated {
    [super viewDidAppear:animated];
    textField.text = @"Testing"];
}

or in ViewDidLoad

dispatch_async(dispatch_get_main_queue(), ^{
      textField.text = @"Testing"];
});

@pratikgujarati7
Copy link
Author

pratikgujarati7 commented Sep 2, 2017 via email

@skguner
Copy link

skguner commented Nov 23, 2017

I tried both suggestions but it didn't work. Any more idea ?
2017-11-23-photo-00000034

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants