iOS Development Tutorial (1) Development Environment Construction

 1. System installation

        1. If you have an Apple computer, you can skip this stage directly

        2. If you don’t have an Apple computer, you can use a VMWare virtual machine to install macos. For the installation tutorial, see this article

        https://blog.csdn.net/dm569263708/article/details/130523282

2. Install xcode

        1. Download xcode, because the system version of my virtual machine can only install xcode version 13, so click this link to search  https://developer.apple.com/download/all/

         2. After the download is complete, copy the Xcode_13.3.xip file to the virtual machine, and double-click to run it.

3. New project

         1. Create the simplest ios APP project

        2. There are two options for the UI framework. The current ios development tutorial is generally Storyboard , and the programming language generally chooses swift

        3. Select the path to save the project, click "create", and a simple project will be created

4. Simple UI elements

        1. Add the most common UI controls, text display, button, text input box, the entry is the "+" button in the upper right corner

        2. The interface after adding is like this

        3. We implement a little logic, change the top text from "Hello World" to "1111" when the button is clicked

                3.1 Hold down ctrl and drag the Label into the code, which defines the variable of the text label as "label"

                3.2 Select Button and right-click, select Touch up inside in the event and drag it into the code, which defines a button click event

         3.3 Add code self.label.test="1111" in onClick

                

 5. Run APP

         1. Select the model of the simulated mobile phone

         2. Click the Run button

         3. The running effect, when we click the button, the above text will become "1111"

Guess you like

Origin blog.csdn.net/dm569263708/article/details/130522734