Is it possible to present a popover without any sort of arrows pointing somewhere?
A:
Nope, there is no UIPopoverArrowDirectionNone
option, and UIPopoverArrowDirectionUnknown
throws an exception i think if you try to use that to present.
Instead of a popover controller, you can call presentModalViewController:animated:
and set the controller you are presenting to have a modal presentation style of UIModalPresentationFormSheet
or perhaps UIModalPresentationPageSheet
. Those are more traditional popup screens than popovers are.
Kevlar
2010-08-04 18:38:33
Unfortunately, presentModalViewController is limited to certain particular frame sizes, while popovers are not, unless I'm missing something. They also don't provide the same look and feel as a popover.
David Liu
2010-08-09 19:55:15
That's correct. Unfortunately, if your requirements are strict you may have to roll your own popups to get what you want.
Kevlar
2010-08-09 22:53:26
+2
A:
Yes it is possible just do:
[self.popoverController presentPopoverFromBarButtonItem:anItem
permittedArrowDirections:0
animated:YES];
The zero represent no direction.
Matt
2010-09-02 00:54:09
it works for me!!! thanks.. will apple accept this? ... by the way, is it posible to present a keyboard inside a popover, the way it looks on ipad passcode? http://stackoverflow.com/questions/3636560/how-to-present-keyboard-inside-popover-ipad-passcode-lock-style
Omer
2010-09-03 14:10:13
A:
Yes, it's possible. Use UIPopoverArrowDirectionUnknown option.
Ex.:
[popoverController presentPopoverFromRect:self.frame inView:self.view permittedArrowDirections:UIPopoverArrowDirectionUnknown animated:YES];
[popoverController presentPopoverFromBarButtonItem:aItem permittedArrowDirections:UIPopoverArrowDirectionUnknown animated:YES];
Marcos Issler
2010-09-17 21:53:53
Doesn't the UIPopoverController specifically state that this direction should not be used?
David Liu
2010-09-17 22:17:07