uiview

UIView animated crossfade causes alpha to drop below 1.0?

I'm crossfading between two views using UIView animation. I've noticed the following surprising fact: If I have (say) two identical views in an identical place, and I animate a cross fade between them (e.g. animate the alpha from 0.0 to 1.0 on one while going from 1.0 to 0.0 on the other, in the same animation), during the animation, th...

iPad UI organization advices

Hi there, I'm doing an iPad application with a map. I want to have a top bar (toolbar), under a 156px height and all width block where i will display information and under an MKMapView. On my second block, I will have a UIPageControl with a couple a view. A button will also allow the user to hide this block, and the map will be resized...

Loading a UIImage from the Web when the apps view loads.

Hi, I'm trying to load a random UIImage from the web using this method NSOperationQueue *queue = [NSOperationQueue new]; NSInvocationOperation *operation = [[NSInvocationOperation alloc] initWithTarget:self selector:@selector(loadImage) ...

crash in internal UIView(CALayerDelegate) actionForLayer

I have an inconsistent crash inside this internal selector. The exception is EXC_BAD_ACCESS, so something has been corrupted. The crash is hard to reproduce, and once it occurs, is not debuggable as the UIView that acts as the receiver can not be inspected. Does anyone have any suggestions for how to debug this crash? I can't even te...

UIScrollView redrawing content while scrolling?

I know there is a property or method that makes the scrollview/uiview call drawRect: method while is scrolling. By default is disabled because of performance reasons but I need to enable it. I cannot remember the name of the method hence I cannot look for it, anyone who knows what I am looking for? Thanks in advance ...

Stockapp kind of interaction - UIView x CALayer

I'm implementing some charts with some user interactions, like long-pressing to view the full data under the finger, two fingers to draw a line, and other stuff. For a start, how would I implement the kind of interaction the iphone stocks app does in the landscape mode of the price chart? Manipulate a CALayer for the yellow vertical li...

UINavigationController: Rotating the view of a covered controller

I have UINavigationController with two view controllers in it (C1 covered by C2). At some point the device is rotated. C2 needs to know the size of one of C1's views (C2 is a map for C1's grid and I need to draw the frame in C2's view). The bounds of C1 are updated when C1 is popped, but I need to get the updated bounds at the time of ...

UIView parent window's frame and bound dimensions while rotating iPad

I a have a following line of code invoked after a touch gesture has completed: CGRect parentBounds = self.view.bounds; CGRect parentFrame = self.view.frame; when iPad is placed in a vertical way both parentFrame and parentBounds have similar dimensions of w:768 h:1004 (or something close to that), but when I rotate parentBounds is 102...

iPhone: Handle multiple action sheets

One of my views uses 3 action sheets that come from when various buttons are clicked. Since I only have one - (void)actionSheet:(UIActionSheet *)actionSheet didDismissWithButtonIndex:(NSInteger)buttonIndex method, what is the best way to know which action sheet I am dealing with? Choosing the first button on any of my actionSheets would...

Movable UIViews, like Tangram

In my iPad application, there is one main view. It contains various views which have different sizes and different images (tetragons, but not rectangles). The grey lines represent the frames, the red lines represent the outline of the image. It is a bit like Tangram, but more complicated since the tetragons are not rectangles. The vi...

best approach for managing UIViews - iPhone Game

Hello. I'm relatively new in this things... In my project, I've got 3 Views(derived from UIView): 1) SplashView (game logo and "Play" button) 2) SelectLevelView (1 to 20 different levels button) 3) GameView (load the selected level in SelectLevelView) All views are programmed using code (drawRect). SplashScreenView is loaded with ...

Multiple UIViews in a viewcontoller?

hi all, i have a uiviewcontroller. there are 2 buttons at the top of UIview. i want to load 2 different UIViews (small view; width=320, height=200) bottom if the user taps buttons. i have uitableview in each smallview and some controls. thats why i want to handle each uiview with own uiviewcontrollers. i think i should create Uiview wi...

UITextView inside UIAlertView subclass

Hi, I'm trying to put a UITextView inside a custom subclass of UIAlertView that I create using a background image of mine. The UITextView is only for displaying large quantities of text (so the scrolling). Here is the code of my subclass - (id)initNarrationViewWithImage:(UIImage *)image text:(NSString *)text{ if (self = [super init]...

Is there a way to use - (UIView *)viewWithTag:(NSInteger)tag with a custom UIView

I have a class that inherits from UIView However when trying to use the follow (UIView *)viewWithTag:(NSInteger)tag I get the warning: *incompatible Objective-C types initializing 'struct UIView *', expected 'struct CustomView ' Right now I have made a custom method that returns my custom view, the method uses a for loop with view.subv...

Relate view & viewmodel.

<DataTemplate DataType="{x:Type vm:SalesViewModel}"> <vm:Sales> </DataTemplate> Whats the meaing of the above code in wpf resource file? ...

Drawing a line in a UIView subview

I have a UIView subclass. This subclass has multiple subviews. Is it possible to draw a line using core graphics inside a subview that is part of the uiview subclass? For example, I have a SampleView class, which is a subclass of UIView. Inside this class's header file is the property for UIView *sampleSubView, which is a subview of Sam...

iPhone: Add "loading" subView

I am wanting to show a simple loading dialog when certain things are happening in my app. I figured I would just create a new view, add a label to that, and then set that view to a subView of my current view. When doing this, I don't see anything! Here is how I am writing my method: - (void)showLoading { UIView *loading = [[UIV...

For iOS, issue "talking" to frame and bounds elements of UIView and decendents

Greetings all - I am having an issue assigning a value to an existing UIScrollView. In response to an Orientation change, I am re-orienting and sizing the ScrollView and the UIImageViews I have contained within. I can set the UIScrollView's frame: CGRect wideThumbFrame = CGRectMake(0.0, 530.0, 1024, 190.0); thumbScrollView.fra...

How to make a UIDatePicker appear at bottom of screen?

Hello, I currently use MonoTouch with MonoTouch.Dialog. When tapping on a date field it pushes the navigationcontroller so you go right a screen to see your UIDatePicker where you choose the date then go "back" to the main screen again. I'd really like to have this UI like other apps I've used that when you select a date field the UID...

sliding UIView back after numeric keypad entry

Hi, I am working on an iPhone app is iOS 4 where I have managed to add the done button to the numeric keypad from an online blog I read. The done button is shown when the key pad pops up and works fine. I had to hook up to the KeyboardViewDidShow event handler and add the button image with the method for it. After I press the done butto...