开发者

UIAction sheet frame

UIAction sheet frame

I have an action sheet that I am displaying in landscape mode.

sheet2 = [[[UIActionSheet alloc] 

      initWithTitle:@"\n\n\n\n\n\n\n\n\n"
      delegate:self
      cancelButtonTitle: nil destructiveButtonTitle:nil
      otherButtonTitles:NSLocalizedString(@"Merge", @"Merge button text"),NSLocalizedString(@"Refresh", @"Refresh button text"), nil] 
     autorelease];

How do I set the frame of it so that it looks proper in my view? See I don't want开发者_开发百科 this gap between the text and the buttons.


It would be helpful if you posted the actual code snippet along with that image, because that image and that code snippet are clearly not connected. UIActionSheets by default will only take up as much space as it needs, so removing those \n's from the title should fix your problem (assuming they even exist in the code that generated that screenshot).

However, from a design perspective, you're probably just going in the wrong direction here overall. If you have to give that much explanation of the two options then you probably should just go ahead and use a new UIViewController so the user can see and read that info in properly sized text.

Or, if you give them enough information before they get to this UIActionSheet, then I would recommend making the button text more explicit. Something like "Replace Local Contacts" instead of "Refresh" and "Merge with Server Contacts" instead of just "Merge."

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜