0
我有一個代碼爲UItabviewcontroller使用編程方式,但如何創建其框架,因爲我在我的應用程序中使用我需要x,y寬度和高度座標的子視圖。我們可以使用UITabBarController * tabBarController = [[UITabBarController alloc] init];如何創建與框架UITabviewcontroller
UIViewController *vc1 = [[UIViewController alloc] init];
UIViewController *vc2 = [[UIViewController alloc] init];
UIView *v1 = [[UIView alloc] init];
UIView *v2 = [[UIView alloc] init];
vc1.title = @"vc1";
vc2.title = @"vc2";
tabBarController.viewControllers = [[NSArray alloc] initWithObjects:vc1, vc2, nil];
self.view = tabBarController.view;