9

Self-Sizing Table View Cells [SUBSCRIBER]

 4 years ago
source link: https://www.raywenderlich.com/9147384-self-sizing-table-view-cells
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client
This course is available as part of the raywenderlich.com Professional subscription. To learn more clickhere

Self-Sizing Table View Cells

Pro

Mar 24 2020 · Video Course (32 mins) · Intermediate

Learn how to create self-sizing table view cells, allow them to resize on demand, support Dynamic Type, and even create them with SwiftUI.

Start Watching for Free

Version

  • Swift 5.1, macOS 10.15, Xcode 11.3

iOS & Swift Tutorials

e62425df-d133-4b73-b531-e5fcf8e073b9.png50c8d72c-0780-47d8-8570-17f399858d17.png

Set Up the UITableView

Set up the custom Auteur table view cell to grow as its content changes by applying constraints and setting properties on the UILabel.

Update the UITableView to be aware that its cells may be of varying sizes by declaring an estimatedRowHeight value.

Add in more content to the AuteurTableViewCell, adding constraints to ensure it will continue to grow as needed.

Make Elements Dynamic

Layout the UI elements for the detail view, configuring the UITextView to grow when its content is changed.

Demonstrate how easy it is to grow a cell once AutoLayout constraint are in place by simply changing the text in a UITextView.

Add Dynamic Type support to the cells - which is just another type of content change to which the cell can adjust.

Explore SwiftUI Differences

Implement the Auteur table in SwiftUI, taking advantage of its built-in formatting rules to make laying out the cells easier.

Implement the detail view in SwiftUI, add Dynamic Type support, and demonstrate how easy it is to grow the cells.

Who is this for?

Intermediate iOS developers who want to do more with their UITableViews. It expects you to have familiarity with creating user interfaces with Storyboards in Interface Builder, the concept of Dynamic Type, and some basics of SwiftUI.

Covered concepts

  • Self-sizing UITableView cells
  • Dynamic Type
  • SwiftUI

Contributors

Josh Steele

In my day job, I write apps (Java, iOS) for space and health at APL. I also teach at the JHU Whiting School Engineer for...

Instructor

Adriana Kutenko

Graphic Illustrator with a Bachelor’s Degree in Fine Arts. I am a perpetual perfection seeker with a big passion for History...

Illustrator


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK