-1

我想将 的背页颜色UIPageViewController从白色更改为某个图像。我曾尝试从以前的 stackoverflow 建议中实现它,但我无法获得如何做到这一点。谁能建议我到底需要做什么?

-(void) createPages{ 
  self.pages = [[NSMutableArray alloc]initWithCapacity:6];
  CountViewController *controller; 
  UIStoryboard *storyboard = [UIStoryboard storyboardWithName:@"MainStoryboard" bundle:[NSBundle mainBundle]];
  for (int i = 0; i < 6; i++) { controller = [storyboard instantiateViewControllerWithIdentifier:@"countView"]; 
   controller.pageNumber = [NSNumber numberWithInt:i];
   [controller.view setUserInteractionEnabled:YES]; 
   [self.pages addObject:controller]; 
  }
}
4

1 回答 1

1

您正在看到窗口背景颜色。您应该设置窗口背景颜色:

appDelegate.window.backgroundColor = [UIColor blackColor];
于 2013-05-28T13:18:38.557 回答