Skip to content

Instantly share code, notes, and snippets.

Andres Kievsky anknetau

Block or report user

Report or block anknetau

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View keybase proof
### Keybase proof
I hereby claim:
* I am anknetau on github.
* I am ank ( on keybase.
* I have a public key whose fingerprint is 9534 E157 8B32 46F0 9C8F 8B2F 4EBE 7B2D 30EA E859
To claim this, I am signing this object:
anknetau / gist.m
Created Feb 3, 2016
Add a child view controller
View gist.m
UIViewController* controller = [self.storyboard instantiateViewControllerWithIdentifier:@"identifier"]; // or whatever
[self addChildViewController:controller];
controller.view.frame = CGRectMake(0, 0, 100, 100); // or whatever
[self.view addSubview:controller.view];
[controller didMoveToParentViewController:self];
anknetau / gist.m
Created Feb 3, 2016
Remove a child view controller
View gist.m
UIViewController *vc = self.childViewControllers[3]; // or whatever
[vc willMoveToParentViewController:nil];
[vc.view removeFromSuperview];
[vc removeFromParentViewController];
anknetau / Remove leading and trailing spaces
Last active Aug 29, 2015
Removing start and end spaces of an NSString is very simple
View Remove leading and trailing spaces
NSString* result = [string stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceAndNewlineCharacterSet]];
You can’t perform that action at this time.