1
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Swift StoryboardでScroll ViewとStack Viewを組み合わせて使う

Posted at

はじめに

StoryboardにてScroll ViewとStack Viewを組み合わせて、
Stack Viewに応じてスクロールする画面を作成する。

環境

  • Xcode 11.5
  • Swift 5

実施手順

1. Scroll Viewを配置する

ScrollAndStack1.png

2. Scroll Viewに制約を追加する

ScrollAndStack2.png

3. Stack Viewを追加する

ScrollAndStack3.png

4. Stack Viewに制約を追加する①

ScrollAndStack4.png

5. Stack Viewに制約を追加する②

ScrollAndStack5.png

6. Stack Viewにアイテムを追加する

ScrollAndStack6.png
1
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?