uiview

Displaying a UIViewController/UIView over another view

I'm trying to create a picker controller with a 'Done' button positioned just above it, to display over a form that is in another view. I have created a sub-class of UIViewController and using IB I've added a toolbar and a picker view. This seems fine and by copying the examples in UICatalog I can get it to display the required values a...

Iphone UIButton not working in nested UIViews

This is so damn simple im sure! Im missing something and im exhausted from trying to fix it. hopefully someone can help. The Button in CharacterView.m works but the button nested down in CharacterMale.m does not. I'm not using IB everything is done progmatically. What would cause one button to work and other not? //////////////////////...

UIView clipsToBounds property: Does it improve performance?

The documentation says that the clipsToBounds property of UIView will clip the drawing to the bounds, or more precisely that the subview can't draw outside of the bounds of the superview. Sounds nice, but what does that mean in practise? If I set that to YES, then my subview will automatically only draw those parts which are not outside...

Is there a way of setting some kind of z-index for z-position of UIImageView objects?

I'm building up a grid of images, and I start at the top, creating UIImageView objects all over the place. Now I want that they overlap a little bit, but the last ones I draw are the ones most on top. I'd like to set the z-position programmatically, so that the first ones I draw will be the ones most on top. ...

custom UIView problem

i have a custom UIView class,and i have linked my view in IB with this class. in my own custom class, i have a function -(void)replaceSubview:(UIView*)view1 withSubView:(UIView*)view2; so in my viewcontroller, i have called this function like this way: [self.view replaceSubview:view1 withSubview:view2]; however,the function wo...

why is UIWindow a child and also a parent of UView?

The UIKit reference says UIView is a superclass of UIWindow, but despite of this parentage, a UIWindow actually manages UIViews. This sounds so unusual to me. Does anyone know what the significants of this are in terms of software design? Many thanks. EDIT: I read the related paragraph in the iPhone programming guide. Yet I couldn't s...

How would you implement a dataSource object for an UIScrollView?

Tell me if I am wrong with that: I made an new class ScrollViewDataSource. That class conforms to an protocol I created within my delegate for the scroll view. Well, it's a very special delegate that does some very complex stuff upon scrolling. So this delegate receives that data source object upon initialization. The datasource object ...

UIView animations interacting badly

Hi-- I'm seeing what appears to be interaction between separate animations, and I'd really appreciate any suggestions to eliminate this effect. Basically: I've got an iPhone app which includes a button 'a' on the root view. Tapping 'a' pushes a view on a navigation view controller stack, with a flip animation. The pushed view has a but...

Why doesn't UIView.exclusiveTouch work?

Hi! In one of my iPhone projects, I have three views that you can move around by touching and dragging. However, I want to stop the user from moving two views at the same time, by using two fingers. I have therefore tried to experiment with UIView.exclusiveTouch, without any success. To understand how the property works, I created a br...

Make Background of UIView a Gradient Without Sub Classing

Is there a way to make the background of a UIView a gradient without subclassing it? I'd rather not use an image file to accomplish this either. It just seems obtuse to have to subclass UIView just to draw a gradient for the background. ...

Display image as popup

I need to display a table formatted data on top of a UIWebView as a modal. Basically a UIAlertView. However, I need to display tabular data in this modal, which UIAlertView can't do (that I know of). I'm thinking to create an image with the textual data in it and display the image in a UIImageView or that within a UIView that can have...

EXEC_BAD_ACCESS upon re-loading a UIViewController containing a UITableView

I get an EXEC_BAD_ACCESS when executing the following steps: STEP 1: Click on "Scores" button from a Main Menu: This Removes the Menu (UIView), and loads the Scores (UIView) which subsequently initiates the process of populating a UITableView with values. No problems here. self.viewController4 = [[ScoresViewController alloc] in...

UIView: how to do non-destructive drawing?

My original question: I'm creating a simple drawing application and need to be able to draw over existing, previously drawn content in my drawRect. What is the proper way to draw on top of existing content without entirely replacing it? Based on answers received here and elsewhere, here is the deal. You should be prep...

Overlaying UIViews

Hi Stackoverflow, what is the appropriate way to overlay two layers of an UIView for the iPhone? The underlaying view should be active until a button is pressed, then another UIView should cover everything in a transparent way. I found the Modal View Controllers, but they simply exchange UI-Views but don't overlay. Thanks in advance. ...

How to get transition like Star Trek app?

I've modified the ViewTransitions app to use kCAScrollHorizontally. I've set transition in the app delegate to use kCATransitionPush rather than kCATransitionFade. However, I still get fading in and out. How can I get the views to slide in landscape just like the Star Trek app (http://itunes.apple.com/WebObjects/MZStore.woa/wa/viewSoft...

iPhone - Problem with sending view to back

When I try to send a view to the back, it hides some of the buttons and labels in my view controller. The view I am sending to the back is a UIImageView. Does anyone have an opinion of what might be the problem? ...

iPhone - creating a loading view

When the app is in one view controller, I want to add a view to simulate that data is being loaded when I click my tab bar controller to open another view controller. Example: When I the app is in the recorder-view, I want it to show a loading view (a view with a activity indicator) when I change to the list of recorded files (which can ...

Giving swip event to other control

I have a UITextView on top of a UIView. They are in a PageScrollView. The user can swipe anyhere outside of the UITextView and flick over the next page (view). I'd like the user to swipe on the UITextView and flick over the next view as well. The UITextView scrolls vertically when there is to much text, which the user can swipe and...

Adding a subview into view hierarchy

I'd like to have a view appear when the user clicks a button. The hierarchy I have looks like this: MainWindow -UIView --ScrollView ---ScrollView.pages = UIViews ----UIView (from above assignment) ----TextView ----InfoButton pages is an NSMutableArry of pageController objects. These hook to a nib. These nibs are the pages that use...

Creating iPhone Pop-up Menu Similar to Mail App Menu

I'd like to create a pop-up menu similar to the one found in the mail app when you want to reply to a message. I've seen this in more than one application so I wasn't sure if there was something built into the framework for it or some example code out there. ...