9.40. IOS storyboard (Storyboards)

发布时间 :2025-10-25 12:23:54 UTC      

9.40.1. Brief introduction

Storyboards is only introduced in iOS5, and when we use Storyboards, the deployment target should be iOS5.0 or higher.

Storyboards helps us understand the visual flow of the picture, in the interface for

Create all application screens under MainStoryboard.storyboard. Example step =

1. 创建一个single view application,创建应用程序时选择 storyboard 复选框。

two。 Select MainStoryboard.storyboard, where you can find a single view controller. Add a view controller and update the view controller, as follows

storyboardInterface

3.连接两个视图控制器。右键单击”show modal(显示模式)”按钮,在左侧视图控制器将其拖动到右视视图控制器中,如下图所示:

storyboardButtonAction

4.现在从如下所示的三个显示选项中选择modal(模态)

storyboardButtonActionModal

5.更新 ViewController.h 如下所示

#import <UIKit/UIKit.h>

@interface ViewController : UIViewController

-(IBAction)done:(UIStoryboardSegue *)seque;

@end

6.更新 ViewController.m 如下所示

#import "ViewController.h"

@interface ViewController ()

@end

@implementation ViewController

- (void)viewDidLoad
{
    [super viewDidLoad];
}

- (void)didReceiveMemoryWarning
{
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}
-(IBAction)done:(UIStoryboardSegue *)seque{
    [self.navigationController popViewControllerAnimated:YES];
}

@end

7.选择”MainStoryboard.storyboard”,并右键点击”Exit “按钮,在右侧视图控制器中选择和连接后退按钮,如下图所示

storyboardButtonExitAction

9.40.2. Output

Run the application in the iPhone device and get the following output

storyboardOutput1

Now, select the display mode and you will get the following output

storyboardOutput2

Principles, Technologies, and Methods of Geographic Information Systems  102

In recent years, Geographic Information Systems (GIS) have undergone rapid development in both theoretical and practical dimensions. GIS has been widely applied for modeling and decision-making support across various fields such as urban management, regional planning, and environmental remediation, establishing geographic information as a vital component of the information era. The introduction of the “Digital Earth” concept has further accelerated the advancement of GIS, which serves as its technical foundation. Concurrently, scholars have been dedicated to theoretical research in areas like spatial cognition, spatial data uncertainty, and the formalization of spatial relationships. This reflects the dual nature of GIS as both an applied technology and an academic discipline, with the two aspects forming a mutually reinforcing cycle of progress.