iOS Learning Summary day01 common errors on UIView and ibaction

Source: Internet
Author: User

UIKit-user interface for creating and managing applications

Quartzcore-Provides animation effects and the ability to render through hardware

Coregraphics-Provides a C-based API for 2D drawing

Corelocation-Get location information using GPS and WiFi

Mapkit-an interface for the application to provide an inline map

avfoundation– Audio Processing

Common problems with iOS development

Day 01

UIview is something that can be seen on the screen, like buttons on the screen, text, images. General translation is called view \ Controls \ Components

Relationship between a parent control and a child control

A lot of child controls are contained in the parent control

Uiviewcontroller

I'm in control UIView.

In fact, whenever a new interface is displayed, a new Uiviewcontroller object is created first, and then a corresponding full-screen Uiview,uiviewcontroller is created to manage this UIView

Uiviewcontroller is UIView's big housekeeper, responsible for creating, displaying, destroying uiview, monitoring events within UIView, and handling UIView interactions with users.

Uiviewcontroller has a UIView attribute inside it, which is the UIView object that it manages:

@property (Nonatomic,retain) UIView *view;

Comprehensive analysis, you can draw a simple procedure to run the process:

Read Main.storyboard file

Create the Mjviewcontroller object that the arrow refers to

Create Mjviewcontroller UIView objects as described in the storyboard file

Display the UIView object in front of the user

1.IBAction:

1> can guarantee that the method can be wired

2> equivalent to void

2.IBOutlet:

1> can ensure that attributes can be wired

3. Common errors

Setvalue:forundefinedkey:]: This class was not key value coding

The reason for the error is: the connection problem

Some suggestions for 4.XCODE5 start

Declare some methods and properties for wiring in the class extension of the. m file

5.frame\center\bounds

1> frame: Can modify position and size

2> Center: Can modify position

3> bounds: Can modify the size (X\y is generally 0)

iOS Learning Summary day01 common errors on UIView and ibaction

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.