SlideShare a Scribd company logo
Beginning Ios Programming With Swift And Swiftui
Ios 15 Simon Ng download
https://ebookbell.com/product/beginning-ios-programming-with-
swift-and-swiftui-ios-15-simon-ng-36056204
Explore and download more ebooks at ebookbell.com
Here are some recommended products that we believe you will be
interested in. You can click the link to download.
Beginning Ios Programming With Swift And Swiftui Ios 18 And Xcode 16
Simon Ng
https://ebookbell.com/product/beginning-ios-programming-with-swift-
and-swiftui-ios-18-and-xcode-16-simon-ng-230820558
Beginning Ios Programming With Swift And Uikit Ios 15 Simon Ng
https://ebookbell.com/product/beginning-ios-programming-with-swift-
and-uikit-ios-15-simon-ng-36478672
Beginning Reactive Programming With Swift Using Rxswift Amazon Web
Services And Json With Ios And Macos 1st Ed Jesse Feiler
https://ebookbell.com/product/beginning-reactive-programming-with-
swift-using-rxswift-amazon-web-services-and-json-with-ios-and-
macos-1st-ed-jesse-feiler-7319500
Beginning Ios Programming With Swift Simon Ng
https://ebookbell.com/product/beginning-ios-programming-with-swift-
simon-ng-35006792
Beginning Ios 8 Programming With Swift Simon Ng
https://ebookbell.com/product/beginning-ios-8-programming-with-swift-
simon-ng-5048088
Beginning Ios 10 Programming With Swift Simon Ng
https://ebookbell.com/product/beginning-ios-10-programming-with-swift-
simon-ng-5705294
Swiftui Apprentice Beginning Ios Programming With Swiftui 1st Edition
Audrey Tam Caroline Begbie
https://ebookbell.com/product/swiftui-apprentice-beginning-ios-
programming-with-swiftui-1st-edition-audrey-tam-caroline-
begbie-33600866
Beginning Ios Programming Building And Deploying Ios Applications 1st
Edition Nick Harris
https://ebookbell.com/product/beginning-ios-programming-building-and-
deploying-ios-applications-1st-edition-nick-harris-4657148
Beginning Ios Programming For Dummies Rajiv Ramnath
https://ebookbell.com/product/beginning-ios-programming-for-dummies-
rajiv-ramnath-4668300
Beginning Ios Programming With Swift And Swiftui Ios 15 Simon Ng
Beginning Ios Programming With Swift And Swiftui Ios 15 Simon Ng
Table of Contents
Preface
Chapter 1 - The Development Tools, the Learning Approach, and the App
Idea
The Tools
The Learning Approach
UIKit vs SwiftUI
Chapter 2 - Your First Taste of Swift with Playgrounds
Trying out Swift in Playgrounds
Constants and Variables
Understanding Type Inference
Control Flow Basics
Understanding Optionals
Playing around with UI
Chapter 3 - Build Your First App in Swift and SwiftUI
An Introduction to SwiftUI
Declarative vs Imperative Programming
Building Your First App Using SwiftUI
Run Your App for the First Time
Chapter 4 - Designing UI Using Stack Views
Understanding VStack, HStack and ZStack
Adding Images to the Xcode Project
Using Spacer and Padding
Using Images
Arranging the Images Using Horizontal Stack Views
Extracting Views for Better Code Organization
Adapting Stack Views Using Size Classes
Chapter 5 - Introduction to Prototyping
Sketching Your App Ideas on Paper
Wireframing Your App
Make Your Sketch/Wireframe Interactive
Prototyping Your App with App Prototyping Tools
Chapter 6 - Understanding List and ForEach
Creating a Simple List
Presenting a List with Array of Items
Adding Thumbnails to the List View
Changing the List View's Style
Alternative Ways to Present the List
Chapter 7 - Customizing List Views
Creating the Basic List View
Displaying Different Restaurant Images
Redesigning the Row Layout
Hiding the List Separators
Chapter 8 - Displaying Alerts and Handling List View Selection
Building a more Elegant Row Layout
Managing Row Selections Using State
Detecting Touches and Displaying an Action Sheet
Understanding Binding
Displaying an Alert Message
Previewing the Row Layout
Chapter 9 - Understanding Struct, Project Organization and Code
Documentation
Classes, Objects and Structures
Creating a Restaurant Struct
Using the Array of Restaurant Objects
Organizing Your Xcode Project Files
Documenting and Organizing Swift Code with MARK
Chapter 10 - List Deletion, Swipe Actions, Context Menus and Activity
Controller
Performing Row Deletion
Using Swipe Actions
Creating Context Menu
Understanding SF Symbols
Working with Activity Controller
Chapter 11 - Working with Navigation View
Creating Navigation Views
Adding the Restaurant Detail View
Navigating from One View to Another
Using Accent Color
Customizing the Back Button
Removing Disclosure Indicators
Chapter 12 - Detail View Enhancement, Custom Fonts and Navigation Bar
Customization
4
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Using Custom Fonts
Improving the Detail View
Ignoring the Safe Area
Previewing the Detail View inside a Navigation View
Customizing the Navigation Bar
Chapter 13 - Understanding Colors, Swift Extensions and Dynamic Type
Working with Custom Colors
Swift Extensions
Adapting Colors for Dark Mode
Dynamic Type
Chapter 14 - Working with Maps
Understanding Map View in SwiftUI
Creating Our Own Map View
Converting an Address into Coordinates Using Geocoder
Adding Annotations to the Map
Embedding MapView
Displaying a Full Screen Map
Chapter 15 - View Animations and Blur Effect
Using Enumeration to Represent Ratings
Implementing the Review View
Applying a Visual Blur Effect
Dismissing the Review View with Animations
Animating the Rate Buttons with Slide-in Animation
Chapter 16 - Working with Observable Objects and Combine
The Problem with our Existing Design
5
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Using Observable Object
Displaying the Rating in Detail View
Chapter 17 - Working with Forms and Camera
Understanding Text Field in SwiftUI
Building Generic Form Fields for User Input
Implementing the Restaurant Form
Working with Photo Library and Camera
Adding Toolbar Buttons
Chapter 18 - Working with Core Data
What is Core Data?
Using Core Data in SwiftUI Projects
Creating the Managed Object Model
Using @FetchRequest to Fetch Records
Deleting a Record from Database
Handling Empty List Views
Updating a Managed Object
Chapter 19 - Adding a Search Bar Using Searchable
Using Searchable
Adding a Search Bar to the Restaurant List View
Search Bar Placement
Performing Search and Displaying Search Results
Chapter 20 - Building Walkthrough Screens Using TabView
A Quick Look at the Walkthrough Screens
Creating the Tutorial View
Adding Next and Skip Buttons
6
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Presenting the Tutorial View
Working with UserDefaults
Chapter 21 - Working with Tab View and Tab Bar Customizations
Creating Tab Interface Using TabView
Adjusting the Color of Tab Bar Items
Adjusting the Color of Tab Bar Items
Chapter 22 - Displaying Web Content with WKWebView and
SFSafariViewController
Designing the About View
Opening Safari Using Link
Using WKWebView
Using SFSafariViewController
Chapter 23 - Working with CloudKit
Understanding CloudKit Framework
Managing Records in CloudKit Dashboard
Fetching Data from a Public Database Using Convenience API
Fetching Data from Public Database Using Operational API
Optimizing the Performance with Activity Indicator
Pull to Refresh
Saving Data Using CloudKit
Chapter 24 - Localizing Your App to Support Multiple Languages
Internationalizing Your App
Export for Localization
Import Localizations
Testing the Localized App
7
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Chapter 25 - Deploying and Testing Your App on a Real iOS Device
Understanding Code Signing and Provisioning Profiles
Automatic Signing in Xcode
Deploying the App on Your Device via USB
Deploying the App over Wi-Fi
Chapter 26 - Beta Testing with TestFlight and CloudKit Production
Deployment
Creating an App Record on App Store Connect
Archiving and Validating Your App
Upload Your App to App Store Connect
Manage Internal Testing
Manage Beta Testing with External Users
CloudKit Production Deployment
Chapter 27 - Submit Your App to App Store
Get Prepared and Well-Tested
Submit Your App to App Store
Chapter 28 - Adopting Haptic Touch
Home Screen Quick Actions
Handling Quick Actions Using Custom URL Scheme
Chapter 29 - Working with User Notifications
Using User Notifications to Increase Customer Engagement
Using the User Notifications Framework
Creating and Scheduling Notifications
Interacting with User Notifications
Appendix - Swift Basics
8
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
9
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Copyright ©2021 by AppCoda Limited
All right reserved. No part of this book may be used or reproduced, stored or
transmitted in any manner whatsoever without written permission from the
publisher.
Published by AppCoda Limited
Published: 20/10/2021 | Last updated: 20/10/2021 | AppCoda © 2021
10
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
What People Say About This Book
"This book got me an internship and a job. After one week of following this book’s
tutorial, I was immediately able to begin developing my own app! 4 months
later, I got an offer at Ancestry to intern as an iOS developer. Best money I ever
spent!!"
- Adriana, iOS developer at Ancestry
"The Basic and Intermediate books are everything you need to understand all the
concepts of design, coding, testing, and publishing an app. All you need is the
idea."
- Rich Gabrielli
"I have published 8Cafe and 8Books, apps based on, and inspired by, the
AppCoda Swift iOS book; it was a pleasure to learn and develop with your team.
In fact, a lot of my apps/games utilise ideas and techniques from your excellent
Beginner and Intermediate Swift books. To me, and a lot of developers, your
talent, knowledge, expertise and willingness to share have been simply a
godsend."
- Mazen Kilani, creator of 8Cafe
"I've been developing iOS apps for about a year now and am greatly indebted to
the team at AppCoda. The Swift books I've purchased from them have
dramatically increased my productivity and understanding of the entire Xcode
and iOS development process. I've learned much more than I ever would have by
scouring StackOverflow and github for hours and hours, which is what I had
been doing prior to deciding to use AppCoda. All of the information is updated
11
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
and accurate, simple to read and follow, and the sample projects are fantastic. I
really can't recommend these books highly enough. If you're trying to jump-start
your Swift education, go for it."
- David Gagne, creator of Bartender.live
"AppCoda's books are fantastic. They are clearly written, assuming no
knowledge, but still push you to think for yourself and internalize the concepts.
No other resource is so comprehensive."
- JP Sheehan, Ingot LLC
"The book is well written, concise, with excellent example code and real-world
examples. It's really helped me get my first App on the App store, and given me
many ideas for further enhancements and updates. I also use it as a reference
guide ongoing as well with the language, and the updates produced as Swift and
iOS change are much gratefully received."
- David Greenfield, creator of ThreadABead
"Thanks for making such an awesome book! This book helped me develop my first
real app and have made $200 on the app store in less than 2 months since
launch. I was also able to get a software developer job where now I am running
the Mobile department. Thanks again for the great book, I always try to promote
it when people ask me about learning how to code."
- Rody Davis, Developer of Pitch Pipe with Pitch Assistant
"The book is really good. I was taking other courses of Swift from Udemy and the
instructor did not have much background as a developer. In your case, I know
you have a good background as a developer. By the way, you explain the things."
- Carlos Aguilar, creator of Roomhints Interior Design Ideas
12
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
"For years, I'd been looking in vain for good quality resources to help sharpen my
app development skills. Your books saved my life. They're the best explained
programming books I've ever read in my 10 years of programming. They're so
easy to understand and they hit everything. I will never thank you enough for
writing the books and I owe you a lot."
- Eric Mwangi
"This book is clearly written with lots of examples. It is also great for experienced
programmers new to Swift."
- Howard Smith, Flickitt
"Without this book, I couldn't become an iOS developer."
- Changho Lee, SY Energy
"I wanted to learn about iOS programming with Swift. For this, I turned to this
book. It's an absolutely great way to learn Swift and iOS app development. If you
have some programming background, you'll be able to do real stuff within a
couple of days. But even if you do not, you'll still be able to learn to develop apps."
- Leon Pillich
"This book is the best book I have found on the Internet. It is very
straightforward. I started my programming journey three years ago and
currently, all my app achievement was due to this book."
- Aziz, Engineer at Kuwait Concepts
"Insightful, helpful, and motivational. The books are full of knowledge and depth
of the subject, providing hints and tips on many aspects of iOS development, and
encourages the student/reader to push forward and to not be afraid of seeking a
deeper understanding of the concepts. Just awesome."
- Moin Ahmad, Creator of Guess Animals
13
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
"This book taught me how to build the structure for the type of app I wanted to
create. The lessons are well laid out, each one is just the right length to avoid
overload. I would highly recommend this book as an excellent introduction to
creating your first app and beyond."
- Stephen Donnelly, Director at Rascalbiscuit
"I tried multiple learning sources including the Stanford training. Although I
already did learn some topics like auto layout, delegates, segues, etc through
other sources, your book was the first one that really made me understand
them!"
- Nico van der Linden, SAP developer at Expertum
"Over the past three years, I have purchased more than a dozen books on
Objective C and Swift. As a high school AP computer science teacher I work
mainly with Java but I also teach several other programming languages so I
tend to keep a large library of books on-hand. While many of the other books and
online video tutorials I purchased these past years were very good, I found
AppCoda's to be far above all others. Simon has a way of presenting a topic in
such a manner where I felt he was teaching me in a classroom environment
rather than just me reading words on a screen. The best way to describe his
writing style is to say it feels like he is speaking to you, not just giving you
instructions."
- Ricky Martin, Gulf Coast High School
"This was one of the easiest books I have found to learn Swift. As a beginner, it
was extremely easy to follow and understand. The real-life examples you include
as your work through the book and build the app being taught is genius and
makes it all worth it in the end. I was able to take many things away and apply to
my own apps. I find myself referring back to it many times. Great Work."
- Bill Harned, creator of Percent Off
14
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
"Best books on iOS development, well designed and easy to follow, and a great
development journey companion."
- Ali Akkawi, freelancer in mobile apps development for iOS and Android
"I like the book. The contents are well structured. We have almost all of the latest
concepts covered."
- Barath V, Lead iOS developer at Robert Bosch LLC
"I have purchased both the Beginning and Intermediate iOS 11 Programming
with Swift books. I am a Java developer turned iOS mobile developer and these
books really helped me learn the concepts of building a mobile application. The
FoodPin application that you build in the Beginner book is an excellent way to
learn all of the most common components of a mobile app. Even though I have
now been working on iOS apps for over three years, I still regularly go back to
the AppCoda swift books as a reference."
- Stacy Chang
"I probably could have done it without the book but it would've taken WAY longer
and I probably wouldn't have understood what I was doing so well. If it weren't
for this book my app probably won't be in the App Store right now. True story.
Keep it up!"
- Marc Estwick
15
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Preface
A couple years ago, people still asked, "Is Swift ready for app development?"
Now everyone knows Swift is the programming language to learn for developing
iOS apps.
I really love this programming language, not because I teach Swift programming
for a living and want you to buy my courses/books. I have been programming for
over 15 years in various programming languages. Swift is my favorite language
right now. This new programming language is well designed with a simplified and
clean syntax. Swift is easier to learn and makes me more productive in iOS app
development, as compared to the good old Objective-C.
Swift was first introduced by Apple in June 2014 and has gone through several
updates. Fast forward to today, the company already released version 5.5 of the
programming language along with Xcode 13 with more features. With over 7 years
of development since its first release, Swift is no longer a brand new programming
language. The language is now solidified, mature and ready for any application
development on iOS, macOS, watchOS, as well as, tvOS. Companies like Lyft,
LinkedIn, and Mozilla have been developing their apps in Swift. Whether you are
planning to develop your next iOS app or you want to build a career in iOS app
development, Swift is for sure the programming language to learn and use.
This book covers everything you need to learn for iOS app development.
Remember, Swift is just a programming language. To develop an iOS app, you
need to learn far more than that. On top of the introduction to Swift, this book will
teach you how to lay out the user interface using SwiftUI and master the essential
APIs of the iOS SDK. Most importantly, you will acquire the Swift programming
skill by developing a real-world app from the ground up.
16
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
As an absolute beginner with no prior programming background, you may
question if you could learn Swift programming and build a real iOS app.
I have been programming in Swift since it was first announced. Swift is more
approachable and it is a lot easier for newbies to learn than Objective-C. Not
everyone can become a great developer, but I believe everyone can learn
programming and develop an app in Swift. All you need is hard work,
determination, and the willingness to take actions.
I launched AppCoda about 9 years ago and started to publish iOS programming
tutorials on a weekly basis. Since then, I have published several books on iOS app
development. At first, I thought people, who want to learn app development, are
those with programming experience and technical background. What's interesting
is that people from different backgrounds are passionate to build their own apps. I
have a reader from France, who is a surgeon by profession, started from zero
programming experience to launching his first app, which allows anyone to share
and advertise event information for free. Another reader is a pilot by profession.
He began to learn iOS programming a couple years ago and is now building iPhone
apps for his own use and other pilots. Boozy is an app for finding Happy Hours,
Daily Deals and Brunches. It was built by a law school dropout. The creator of the
app could not find a good place for a drink in DC area. So she decided to make an
app to meet a real need. Similarly, she did not know coding when she came up with
the idea. She just got started and learned along the way.
From time to time, I got emails from people who want to create an app. The emails
usually mention something like this: "I have an app idea. Where do I begin? But I
have no programming skills. Can I learn from scratch to make one?"
What I learned from these truly inspiring stories is that you don't need to have a
degree in Computer Science or Engineering in order to build an app. These readers
have one thing in common. They are committed to taking actions. They all put
their hard work in to make things happen. This is what you need.
17
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
So you've got an idea to build an app? I believe you can make one on your own.
Remember there is nothing to deter you from learning and get things done if
you're really passionate about it. Let me borrow one of my favorite quotes from
Last Lecture to conclude:
Brick walls are there for a reason: they let us prove how badly we want
things.
- Randy Pausch
Lastly, thanks for picking up the book. I hope you will enjoy reading it and launch
your first iOS app on App Store. If you'd like to share the story of your first app,
drop me an email at simonng@appcoda.com. I would love to hear from you.
Simon Ng
Founder of AppCoda
18
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
What You Will Learn in This Book
I know many readers have an app idea but don't know where to begin. Hence, this
new book is written with this in mind. It covers the whole aspect of Swift
programming and you will learn how to build a real-world app from scratch. You'll
first learn the basics of Swift and SwiftUI. Then you'll start to prototype a real
world app and build it from scratch. Each chapter you'll learn how to use the iOS
APIs to build some features. After going through the whole book, you'll have a real
app. During the process, you will learn how to exhibit data in list views, design UI
using Stack Views, create animations, work on maps, build an adaptive UI, save
data in local database, upload data to iCloud, use TestFlight to arrange beta test,
etc.
This new book features a lot of hands-on exercises and projects. You will get the
opportunities to write code, fix bugs and test your app. Although it involves a lot of
work, it will be a rewarding experience. I believe it will allow you to master Swift
5.5, Xcode 15, and iOS 15 programming. Most importantly, you will be able to
develop an app and release it on App Store.
Audience
This book is written for beginners without any prior programming experience and
those who want to learn Swift programming. Whether you are a programmer who
wants to learn a new programming language or a designer who wants to turn your
design into an iOS app or an entrepreneur who wants to learn to code, this book is
written for you.
I just assume you are comfortable using macOS and iOS as a user.
SwiftUI vs UIKit
19
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
The debut of SwiftUI was huge, really huge for existing iOS developers or people
who are going to learn iOS app building. It was unarguably the biggest change in
iOS app development in recent years. That said, beginners may be confused with
these two UI frameworks. Which one should you learn or start with?
You should ask yourself why you want to learn iOS programming. What's your
goal? Do you want to become a professional iOS developer and get hired? Or you
just want to learn something new as a hobby?
If you want to become a professional iOS developer and look for a job, you should
learn both frameworks. Most of the apps on the App Store are developed using
UIKit. It is very likely you will work on an app built with UIKit if you are employed.
So, you can start with UIKit, followed by SwiftUI.
On the other hand, if you take up programming as a hobby or just create an app as
a side project, I suggest you to jump right into SwiftUI.
This book comes with two editions: UIKit and SwiftUI. Both editions will teach you
how to build the same real world app but with different UI frameworks. If your
plan is to start with SwiftUI, you can continue to read chapter 1. Otherwise, pick up
the UIKit edition of the book.
20
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Chapter 1
The Development Tools, the
Learning Approach, and the App
Idea
Since you pick up this book, I guess you want to create an iOS app. Creating an app
is a fun and rewarding experience. I still remembered the joy when I first created
an app years ago, even though the app is just so simple and elementary.
iOS, the mobile operating system behind iPhone and iPad, has been released for
more than 10 years. The tools, the programming language and its frameworks have
greatly evolved over these years. Therefore, before we dive into iOS programming,
let's go through the tools you need to build an app and get prepared the mindset
for learning iOS app development.
21
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
The Tools
Apple has favored a closed ecosystem over the open system. iOS can be only run on
Apple's own devices including iPhone and iPad. It is very much unlike its
competitor, Google, that Android is allowed to run on mobile devices from
different manufacturers. As an aspiring iOS developer, what this means to you is
that you will need a Mac for app development.
1. Get a Mac
Having a Mac is the basic requirement for iOS development. To develop an iPhone
(or iPad) app, you need to get a Mac with an Intel-based processor running on
macOS version 11 (or later). If you now own a PC, the cheapest option is to
purchase the Mac Mini. As of this writing, the retail price of the entry model is
US$899. You can hook it up to the monitor of your PC. I would recommend you to
pick the basic model of Mac mini with Apple M1 chip. It should be good enough to
run the iOS development tools smoothly. Of course, if you have a bigger budget,
get the higher model or an iMac with better processing power.
2. Register Your Apple ID
You will need an Apple ID to download Xcode, access iOS SDK documentation,
and other technical resources. Most importantly, it will allow you to deploy your
app to a real iPhone/iPad for testing.
If you have downloaded an app from the App Store, it is quite sure that you already
own an Apple ID. In case you haven't created your Apple ID before, you have to get
one. Simply go to Apple's website (https://appleid.apple.com/account) and follow
the procedures for registration.
3. Install Xcode
22
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
To start developing iOS apps, Xcode is the only tool you need to download. Xcode
is an integrated development environment (IDE) provided by Apple. Xcode
provides everything you need to kick start your app development. It already
bundles the latest version of the iOS SDK (short for Software Development Kit), a
built-in source code editor, graphic user interface (UI) editor, debugging tools and
much more. Most importantly, Xcode comes with an iPhone (and iPad) simulator
so you can test your app without the real devices.
To install Xcode, go up to the Mac App Store and download it. If you're using the
latest version of Mac OS, you should be able to open the Mac App Store by clicking
the icon in the dock. In case you can't find it, you may need to upgrade your Mac
OS.
Figure 1-1. App Store icon in the dock
In the Mac App Store, simply search "Xcode" and click the "Get" button to
download it.
23
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Figure 1-2. Download Xcode on App Store
Once you complete the installation process, you will find Xcode in the Launchpad.
24
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Figure 1-3. Xcode icon in the Launchpad
At the time of this writing, the latest version of Xcode is 13. Throughout this book,
we will use this version of Xcode to create the demo apps. Even if you have
installed Xcode before, I suggest you upgrade to the latest version. This should
make it easier for you to follow the tutorials.
4. Enroll in the Apple Developer Program
(Optional)
A common question about developing an iOS app is whether you need to enroll in
the Apple Developer Program (https://developer.apple.com/programs/). The
short answer is optional. First, Xcode already includes a built-in iPhone and iPad
simulator. You can develop and test out your app on Mac, without enrolling in the
program.
25
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Starting from Xcode 7, Apple has changed its policy regarding permissions
required to build and run apps on devices. Before that, the company required you
to pay US$99 per year in order to deploy and run your apps on a physical iPhone
or iPad. Now, program membership is no longer required. Everyone can test their
apps on a real device without enrolling in the Apple Developer Program. Having
said that, if you want to try out some advanced features such as in-app purchase,
push notifications or CloudKit, you still need to apply for the program
membership. Most importantly, you're not able to submit your app to App Store
without paying the annual membership fee.
So, should you enroll in the program now? The Apple Developer Program costs
US$99 per year. It's not big money but it's not cheap either. Since you're reading
this book, you're probably a newcomer and just start exploring iOS development.
The book is written for beginners. We will first start with something simple. You
are not going to tap into the advanced features until you grasp the basic skills.
Therefore, even if you do not enroll into the program, you will still be able to follow
most of the content to build an app and test it on your device. For now, save your
money. I will let you know when you need to enroll in the program. At that time,
you're encouraged to join the program as you're ready to publish the app to the
App Store!
26
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
The Learning Approach
I have been teaching iOS programming from 2012 through blogging, online
courses, and in-person workshops. What I found is that it is the learning approach
and the mindset that make the difference between failing and achieving. Before we
talk about Swift and iOS programming, I want to get you equip with the right
mindset and understand the most effective way to learn programming.
Get Your Hands Dirty
One of the most popular questions about learning how to code is:
What's the best way to learn iOS programming?
First, thanks for reading this book. Unfortunately, I have to tell you that you
cannot learn programming just by reading books. This book has everything you
need to learn Xcode, Swift, and iOS app development.
But the most important part is taking action.
If I have to provide an answer to the question, I will say "Learn by Doing". It is at
the heart of my teaching approach.
Let me change the question a little bit:
What's the best way to learn English (or other foreign languages)?
What's the best way to learn cycling (or any other sports)?
You probably know the answer. I especially like this answer on Quora about
learning a new language:
27
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Follow this routine: listen 1 hour a day, speak 1 hour a day, publish 1 journal
entry.
- Dario Mars Patible
You learn through practice, not by just studying grammar. Learning programming
is somewhat very similar to learning a language. You need to take actions. You
have to work on a project or some exercises. You have to sit in front of your Mac,
immerse yourself in Xcode, and write the Swift code. It doesn't matter how many
mistakes you make during the process. Just remember to open Xcode and code
while reading this book.
Motivations
Why do you want to learn app development? What motivates you to sacrifice the
weekends and holidays to learn how to code?
Some people begin learning app development just because of money. There is
nothing wrong with that. You may want to build your app business to earn some
side income and eventually turn it into a full-time business. That's completely
understandable. Who doesn't want to live a rich life?
As of February 2019, however, there were over 2.2 million apps on the App Store.
It is really hard to put up an app on the App Store and expect to make a load of
money overnight. You'll be easily discouraged or even give up if money is your
primary reason for building apps, especially when you come across articles like
this:
How Much Money I Made on the App Store (https://sitesforprofit.com/how-
much-money-app-store)
28
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Then reality set in.
199 units old = US$209 in sales = US$135 proceeds (net to me). In order to
get the app on the app store I needed to pay the $99 developer fee.
So after 2 months and 1 week my (before tax) profit was $36.
- James
Programming is hard and challenging. I find people who successfully master the
language are those who have a strong desire to build apps and are enthusiastic to
learn programming. They usually have an idea in their mind and want to turn it
into a real app. Making money is not their number one concern. They know the
app can solve their own problems and will be beneficial to others. With such a
powerful purpose in mind, they can overcome any obstacles come up.
So, think again why you want to learn programming.
Find a Buddy
"The best way to learn is to teach" is an old saying. It still works in the modern
world, however. You don't need to be an expert to teach. I'm not talking about
giving a lecture at a university or teaching a bunch of students in a formal class.
Teaching does not always happen that way. It can be as simple as sharing your
knowledge with a colleague or a classmate sitting next to you.
Try to find someone who is also interested in learning iOS programming. When
you learn something new, try to explain the materials to your buddy. For example,
after building your first app, teach your close friend how it works and how he/she
can create an app too.
What if you can't find a buddy to share what you've learned? No worries. Start a
blog on medium.com (or whatever platforms you like), write a blog post every day,
and document everything you learn.
29
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
This is one of the most effective ways of learning as I learn so much while
publishing tutorials on appcoda.com, as well as, developing my first book.
Sometimes you think you know the materials well. But once you need to explain
the concept to someone else and answer questions, chances are that you didn't
understand the material thoroughly. This will motivate you to study the materials
even harder. Give this method a shot while you learn iOS programming.
Be Patient
Grit is passion and perseverance for very long-term goals. Grit is having
stamina. Grit is sticking with your future, day-in, day-out. Not just for the
week, not just for the month, but for years. And working really hard to make
that future a reality. Grit is living life like it’s a marathon, not a sprint.
- Dr. Angela Lee Duckworth
Some of my students asked, "How long would it take to become a good developer?"
It takes time to master programming and become a great developer. It usually
takes years. Not weeks, not months but years.
This book will help you kick start the journey. You will learn all the basics of Swift
and iOS programming and eventually, build an app. That said, it takes time and
lots of practices to become a professional programmer.
Be patient. Don't set your expectations too high for your first app. Just enjoy the
process, create something simple and fun. Keep reading and coding daily. You will
eventually master the skill.
Find Your App Idea
30
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
I always encourage my students to come up with their own app idea when start
learning app development. The idea doesn't have to be big. You do not need to
build the next Uber app or come up with a new idea to change the world. You just
need to start with a very small idea that solves a problem.
Let me give you a couple of the examples.
One classic example that I used to mention is Cockpit Dictionary. It is an app built
by Manolo Suarez, who is a pilot by profession. He had an app idea while learning
app programming. The idea was not fancy but solved his own problem. There are
tens of thousands of Aviation terms in abbreviated form. Even for an experienced
pilot with over 20 years of aviation experience, it is impossible to remember all the
acronyms and technical terms. Instead of using a print dictionary, he thought of
building a handy app for pilots to look up all kinds of Aviation terms. A simple, yet
a great idea to solve his own problem.
31
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Figure 1-4. Cockpit Dictionary
Another example is the NOAA Buoy Data app. While this app is no longer available
on the App Store, I still want to quote it as an example. The app was designed to
retrieve the latest weather, wind, and wave data from the National Oceanic and
Atmospheric Administration’s (NOAA) National Data Buoy Center (NDBC).
Developed by Leo Kin, he came up with the app idea during his recovery from
surgery.
32
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
"After the surgery, I had to wear a neck brace for three months. During those
three months, I couldn’t move a lot and even had a hard time walking or even
raising my arms. My physical therapist advised that I go walking as much as I
can to get exercise and to build back my atrophied leg muscles.
There is an island close to where I was living that I really enjoyed walking to.
The only problem was that it can only be reached during low tide. And if the
tide came in, there’s no way to get back home except by swimming. Since I
was very physically weakened, I was very scared of getting stuck on the island
with no way back. While walking, I was always going to NOAA’s website to
check how high or low the tide was and if I had enough time to walk to the
island and back.
During one of my walks, the idea came to me that I should build an app. Even
if no one else uses the app, it wouldn’t matter because it would help me keep
track of the tides and get back in time."
- Leo Kin
His app may not interest you, but it was solving a problem he faced at the time.
Probably people on that island would benefit from his app too.
33
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Figure 1-5. NOAA Buoy Data app
Having your own app idea will give you a clear goal and motivate you to keep
learning. Now spare some time and write down three app ideas below:
1.
2.
3.
34
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
UIKit vs SwiftUI
Which UI framework should you learn? As a beginner, you may have heard of
these two terms: UIKit and SwiftUI. Some people said you should learn UIKit to
build apps but some said you could ignore UIKit and dive right into SwiftUI
because it's Apple's brand new UI framework.
I guess you may be confused with these technical terms. Let me give you a quick
overview to both, so you know which one you should focus on.
Figure 1-6. Building apps using UIKit and Interface Builder
First, both frameworks allow you to build great apps. The UIKit framework is the
original UI framework available since the first release of iOS. With UIKit, you can
write code to build the mobile app UI or create app layouts using Xcode's Interface
35
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Builder. One of the downsides, however, is that the framework is more
complicated to learn as compared to SwiftUI.
Figure 1-7. Building apps using SwiftUI
With SwiftUI, you can develop the app's UI with a declarative Swift syntax. What
that means to you is that the UI code is easier and more natural to write.
Compared with the existing UI frameworks like UIKit, you can create the same UI
with way less code.
The preview function has always been a weak point of Xcode. While you can
preview simple layouts in Interface Builder (or Storyboard), you usually can't
preview the complete UI until the app is loaded onto the simulators. With SwiftUI,
Xcode gives you immediate feedback of the UI you are coding. For example, you
add a new record to a table, Xcode renders the UI change on the fly in a preview
36
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
canvas. If you want to preview how your UI looks in dark mode, you just need to
change an option. This instant preview feature simply makes UI development a
breeze and iteration much faster.
Not only does it allow you to preview the UI, the new canvas also lets you design
the user interface visually using drag and drop. What's great is that Xcode
automatically generates the SwiftUI code as you add the UI component visually.
The code and the UI are always in sync. This is a feature Apple developers
anticipated for a long time.
Now it comes to the core question. As a beginner, which framework should you
learn?
You should ask yourself why you want to learn iOS programming. What's your
goal? Do you want to become a professional iOS developer and get hired? Or you
just want to learn something new as a hobby?
If you want to develop a career in iOS development, my short answer is to learn
both frameworks. But it's better to begin with UIKit because many companies are
still developing apps using UIKit. It's an essential skill to help you get hired. This is
why I recommend you to get familiar with UIKit, followed by SwiftUI.
On the other hand, if you take up programming as a hobby or create an app as a
side project, I suggest you to jump right into SwiftUI. It is easier to learn and lets
you build apps using less code. From time to time, you may still need to use some
UI components from UIKit. When that time comes, you can learn how to use that
specific UIKit components. So, focus on SwiftUI first and then UIKit.
Summary
That's all for the introduction. Take some time to install Xcode on your Mac, come
up with your own app idea, and pick the framework you want to focus on. We have
both UIKit and SwiftUI books to help you learn the required skills for building
37
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
your own apps.
If SwiftUI is your focus, proceed to the next chapter and we will start programming
in Swift.
So get ready!
38
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Chapter 2
Your First Taste of Swift with
Playgrounds
Now that you have configured everything you need to start iOS app development,
let me answer another common question from beginners before moving on. A lot
of people have asked me about what skills you need in order to develop an iOS app.
In brief, it comes down to three areas:
Learn Swift - Swift is now the recommended programming language for
writing iOS apps.
Learn Xcode - Xcode is the development tool for you to design the app UI,
write Swift code, and build your apps.
Understand the iOS software development kit - Apple provides the
39
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
software development kit for developers to make our lives simpler. This kit
comes with a set of software tools and APIs that empowers you to develop iOS
apps. For example, the SwiftUI framework which will discuss in the next
chapter is one of the essential frameworks you need to learn for building user
interface and animations. If you want to display a web page in your app, the
SDK also provides a built-in browser that lets you embed right in your
application.
You will have to equip yourself with knowledge on the above three areas. That's a
lot of stuff. But no worries. You'll learn the skills as you read through the book.
The Swift History
Let me start off by telling you a bit about the history of Swift.
In the Worldwide Developer Conference 2014, Apple surprised all iOS developers
by launching a new programming language called Swift. Swift is advertised as a
"fast, modern, safe, interactive" programming language. The language is easier to
learn and comes with features to make programming more productive.
Prior to the announcement of Swift, iOS apps were primarily written in Objective-
C. The language has been around for more than 20 years and was chosen by Apple
as the primary programming language for Mac and iOS development. I've talked to
many aspiring iOS developers. A majority of them said Objective-C was hard to
learn and its syntax looked weird. Simply put, the code scares some beginners off
from learning iOS programming.
The release of Swift programming language is probably Apple's answer to some of
these comments. The syntax is much cleaner and easier to read. I have been
programming in Swift since its beta release. It's more than 4 years for now. I can
40
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
say you're almost guaranteed to be more productive using Swift. It definitely
speeds up the development process. Once you get used to Swift programming, it
would be really hard for you to switch back to Objective-C.
It seems to me that Swift will lure more web developers or even novice to build
apps. If you're a web developer with some programming experience on any
scripting languages, you can leverage your existing expertise to gain knowledge on
developing iOS apps. It would be fairly easy for you to pick up Swift. Being that
said, even if you're a total beginner with no prior programming experience, you'll
also find the language friendlier and feel more comfortable to develop apps in
Swift.
In June 2015, Apple announced Swift 2, and that the programming language goes
open source. This is a huge deal. Since then, developers created some interesting
and amazing open source projects using the language. Not only can you use Swift
to develop iOS apps, companies like IBM developed web frameworks for you to
create web apps in Swift. Now you can run Swift on Linux too.
Following the release of Swift 2, Apple introduced Swift 3 in June 2016. This
version of the programming language, integrated into Xcode 8, was released in
Sep, 2016. This was considered as one of the biggest releases since the birth of the
language. There were tons of changes in Swift 3. APIs are renamed and more
features were introduced. All these changes helped to make the language even
better and enabled developers to write more beautiful code. That said, it took all
developers extra efforts to migrate their projects for these breaking changes.
In June 2017, Apple brought you Swift 4, along with the release of Xcode 9, with
even more enhancements and improvements. This version of Swift had a focus on
backward compatibility. That meant ideally projects developed in Swift 3 could be
run on Xcode 9 without any changes. Even if you had to make changes, the
migration from Swift 3 to 4 would be much less cumbersome than that from 2.2 to
3.
41
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
In the following year, Apple only released a minor update for Swift, pushing Swift's
version number to 4.2. Even though it's not a major release, the new version also
came with a lot of language features to improve productivity and efficiency.
In late March 2019, Apple officially released Swift 5, which is a major milestone of
the programming language. While it includes many new features, the most
important change is that the Swift runtime is now included in Apple’s platform
operating systems including iOS, macOS, watchOS, and tvOS. Actually, it's a good
news for aspiring developers. This means the Swift language is more stable and
mature. Everything you learn in this book will apply to the future release of Swift.
This year, the Swift language is further updated to Swift 5.5 with even more
features. The async/await functions introduced in this release makes asynchronous
programming much simpler.
If you're a total beginner, you may have a couple of questions in mind. Why does
Swift keep changing? If it keeps updating, is Swift ready for use?
Nearly all programming languages change over time. The same is for Swift. New
language features are added to Swift every year to make it more powerful and
developer friendly. It is somewhat similar to our spoken languages. Let's say, for
English, it still changes over time. New vocabulary and phrases such as freemium
are added to the dictionary every year.
All languages change over time, and there can be many different reasons for
this. The English language is no different.
Source: https://www.english.com/blog/english-language-has-changed
While Swift keeps evolving, it doesn't mean it is not ready for production use.
Instead, if you are going to build an iOS app, you should build it in Swift. It has
become a de facto standard for iOS app development. Companies such as
42
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
LinkedIn, Duolingo and Mozilla had already written apps entirely in Swift since its
early versions. Since the release of Swift 4, the programming language is more
stable and definitely ready for enterprises and production uses.
Let's Get Started
Enough for the background and history. Let's begin to look into Swift.
To get a taste of Swift programming language, let's take a look at the following
code snippets.
Objective-C
const int count = 10;
double price = 23.55;
NSString *firstMessage = @"Swift is awesome. ";
NSString *secondMessage = @"What do you think?";
NSString *message = [NSString stringWithFormat:@"%@%@", firstMessage, seco
ndMessage];
NSLog(@"%@", message);
Swift
let count = 10
var price = 23.55
let firstMessage = "Swift is awesome. "
let secondMessage = "What do you think?"
var message = firstMessage + secondMessage
print(message)
43
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
The first block of code was written in Objective-C, while the second one was
written in Swift. Which language do you prefer? I guess you would prefer to
program in Swift, especially if you're frustrated with the Objective-C syntax. It's
clearer and readable. There is no @ sign and semi-colon at the end of each
statement. Both statements below concatenate the first and second messages
together. I believe you can probably guess the meaning of the following Swift code:
var message = firstMessage + secondMessage
but find it a bit confusing for the Objective-C code below:
NSString *message = [NSString stringWithFormat:@"%@%@", firstMessage, seco
ndMessage];
Trying out Swift in Playgrounds
I don't want to bore you by just showing you the code. There is no better way to
explore coding than actually writing code. Xcode has a built-in feature called
Playgrounds. It's an interactive development environment for developers to
experiment Swift programming and allows you to see the result of your code in
real-time. You will understand what I mean and how Swift Playgrounds works in a
while.
Assuming you've installed Xcode 13 (or up), launch the application (by clicking the
Xcode icon in Launchpad). You should see a startup dialog.
44
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Figure 2-1. The startup dialog
A Playground is a special type of Xcode file. In the top menu, click File > New >
Playground... to create a new Playground file. You'll then be prompted to select a
template for your playground. Since we focus on exploring Swift in iOS
environment, choose Blank under the iOS section to create a blank file. Click Next
to continue.
45
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Figure 2-2. Creating a Playground file
Once you confirm to save the file, Xcode opens the Playground interface. Your
screen should like this:
46
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
​ On the left pane of the screen, it is the editor area where you type the code. When
you want to test your code and see how it works, hit the Play button. Playground
immediately interprets the code (up to the line of the Play button) and displays the
result on the right pane. By default, Swift Playgrounds includes two lines of code.
As you can see, the result of the str variable appears immediately on the right
pane after you hit the Play button at line 4.
We'll write some code in Playgrounds together. Remember the purpose of this
exercise is to let you experience Swift programming and learn its basics. I will not
cover every feature of Swift. We will only focus on these topics:
1. Constants, variables and type inference
2. Control flow
3. Collection types like arrays and dictionaries
4. Optionals
These are the basic topics that you need to know about Swift. You will learn by
example. However, I'm quite sure you will be confused by some of the
programming concepts, especially you are completely new to programming. No
47
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
worries. You will find my study advice in some sections. Just follow my advice and
keep studying. And, don't forget to take a break when you're stuck.
Cool! Let's get started.
Constants and Variables
Constants and variables are two basic elements in programming. The concept of
variables (and constants) is similar to what you learned in Mathematics. Take a
look at the equation below:
x = y + 10
Here, both x and y are variables. 10 is a constant, meaning that its value is
unchanged.
In Swift, you declare variables with the var keyword and constants using the let
keyword. If you write the above equation in code, here is what it looks like:
let constant = 10
var y = 10
var x = y + constant
Type the code above in Playgrounds and then hit Play at line 5. You will see the
result below.
48
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Figure 2-4. The result of the equation
You can choose whatever name for variables and constants. Just make sure they
are meaningful. For example, you can rewrite the same piece of code like this:
let constant = 10
var number = 10
var result = number + constant
To make sure that you clearly understand the difference between constants and
variables in Swift, type the following code to change the values of constant and
number :
constant = 20
number = 50
After that, press shift+command+enter to execute the code. Other than using the
Play button, you can use the shortcut keys to run the code.
You simply set a new value for the constant and variable. But as soon as you
change the value of the constant, Xcode gives you an error in the console.
Conversely, there is no issue for number .
49
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Figure 2-5. Errors in Playgrounds
This is the core difference between constants and variables in Swift. Once a
constant is initialized with a value, you can't change it. If you have to change the
value after initialization, use variables.
Understanding Type Inference
Swift provides developers with a lot of features to write clean-looking code. One
feature is known as Type Inference. The same code snippet we just discussed
above can be explicitly written as follows:
let constant: Int = 10
var number: Int = 10
var result: Int = number + constant
Each variable in Swift has a type. The keyword Int after colon ( : ) indicates the
type of the variable/constant is an integer. If the value stored is a decimal number,
we use the type Double .
var number: Double = 10.5
50
Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
Another Random Scribd Document
with Unrelated Content
Confederate general; C. A. Battle (Democrat), Confederate general;
A. Tyson (Whig). See Brewer and Garrett, and N. Y. Times, Aug. 3
and 9, 1866.
[1066] McPherson, pp. 240, 241.
[1067] N. Y. Times, Aug. 27, 1866. By “Union” party, Parsons
evidently meant those who opposed secession.
[1068] The northern business men were on the side of the whites.
[1069] McPherson, p. 124.
[1070] McPherson, p. 242.
[1071] N. Y. Times, Sept. 8, 1866.
[1072] Davis was of good middle-class Virginia stock. A Whig in
politics, Mrs. Chesnut called him “a social curiosity.” In convention of
1861 he voted against immediate secession, threatened resistance
among the hills of north Alabama, and ended by signing the
ordinance of secession; was chosen to succeed Dr. Fearn in the
Confederate Provisional Congress; was appointed lieutenant-colonel
of the 19th Alabama Infantry, but declined; commanded a battalion
for a while; his “loyalty” consisted in his leaving the Confederate
service and returning to Huntsville within the Federal lines. Brewer,
p. 365, Garrett, pp. 341, 342; Smith’s Debates, passim. He soon fell
out with the carpet-baggers and “formed a party of one.”
[1073] The disposition of some of the north Alabama leaders (even
among the Conservatives) to play the childish act was one of the
disgusting features of Reconstruction.
[1074] N. Y. Times, Jan. 23, 1867. Among those present were: D. C.
Humphreys (Douglas Democrat), Confederate officer, who deserted
to Federals (he was in the first carpet-bag legislature, and later
judge of the Supreme Court of the District of Columbia; see Garrett,
p. 364); John B. Callis, agent of the Freedmen’s Bureau, Veteran
Reserve Corps, member of Congress, 1868; C. C. Sheets, in
convention of 1861, refused to sign ordinance of secession and
deserted to Federals, a member of Congress, 1868; Thomas M.
Peters, Whig, deserted to Federals, later judge of Supreme Court of
Alabama (see Brewer, p. 309; Garrett, p. 440); F. W. Sykes, member
of legislature during war, soon returned to Conservative party
(Brewer, p. 309); J. J. Hinds, afterward a notorious scalawag.
[1075] One new man was S. C. Posey of Lauderdale, who had been
in the convention of 1861 and refused to sign the ordinance of
secession and was in the legislature during the war. Returned soon
to Conservative party. Brewer, p. 299, Garrett, p. 389.
[1076] The Radical party might have done much worse than to send
him to the Senate. Warren and Spencer, the senators elected, were
far inferior in character and abilities to Swayne. He was too decent a
man to suit the Radicals and was soon dropped.
[1077] N. Y. Herald, March 6, 1867.
[1078] The proclamation announcing that the rebellion had ended
was issued April 2, 1866. McPherson, p. 15.
[1079] Van Horne, Life of Thomas, pp. 153, 399, 400, 408;
Huntsville Advocate, June 9, 1866 (for copy of order relating to
Department of the South that I have not found elsewhere); G. O.
No. 1, Mil. Div. Tenn., June 20, 1865; G. O. No. 118, W. Dept., June
27, 1865; G. O. No. 1, Dept. Ala., July 18, 1865; G. O. No. 1, Dist.
Ala., June 4, 1866; G. O. No. 1, Dept. Tenn., Aug. 13, 1866; G. O.
No. 42, Dept. Tenn., Nov. 1, 1866. The general and special orders
cited in this chapter are on file in the War Department at
Washington.
[1080] O. R., Ser. I, Vol. XLIX, Pt. II, pp. 505, 560, 727, 826, 854,
971; Report of the Joint Committee on Reconstruction, Pt. III.
[1081] Miller, “Alabama,” p. 236; Acts of Ala. (1865-1866), pp. 598,
601.
[1082] That is, the officers had the privileges and authority of
officers of a division. G. O. Nos. 1, 9, 17, 29, 54, Dept. Ala., 1865; G.
O. No. 1, Mil. Div. Tenn., 1865.
[1083] The “Amnesty Oath.” The oath of allegiance had already been
administered to all who would take it. See McPherson,
“Reconstruction,” pp. 9, 10.
[1084] G. O. Nos. 13 and 14, Dept. Ala., 1865.
[1085] G. O. No. 3, Dept. Ala., July 21, 1865. There was complaint
about the stealing of cotton by troops.
[1086] G. O. No. 6, Post of Montgomery, May 15, 1865. This order is
printed on thin, blue Confederate writing paper, which seems to have
been shaped with scissors to the proper size. Supplies had not
followed the army.
[1087] G. O. No. 24, Dept. of Ala., Aug. 25, 1865.
[1088] G. O. No. 6, Post of Mobile, in N. Y. Daily News, June 27,
1865.
[1089] G. O. No. 48, Dept. Ala., Oct. 18, 1865.
[1090] Statement of General Woods, Sept. 4, 1865, Document No.
11, accompanying the Report of Schurz.
[1091] See statement of Woods, Sept. 4, 1865, Schurz’s Report.
[1092] G. O. No. 4, Dept. Ala., Jan. 26, 1866.
[1093] N. Y. Daily News, Sept. 7, 1865.
[1094] Statement of Gen. T. K. Smith, Sept. 14, 1865, in Schurz’s
Report.
[1095] Statement of General Woods, Sept. 4, 1865.
[1096] G. O. No. 5, Sub-dist. Ala., Oct. 13, 1866.
[1097] See Ch. VI, sec. 1.
[1098] G. O. No. 30, Dept. of Ala., Sept. 4, 1865; Statement of
General Woods, Sept. 4, 1865, in Schurz’s Report.
[1099] See Ch. VI, sec. 1.
[1100] N. Y. Herald, Nov. 26 and Dec. 15, 1865.
[1101] Document No. 19, accompanying Schurz’s Report.
[1102] G. O. No. 55, Dept. Ala., Oct. 30, 1865.
[1103] G. O. No. 8, Dept. Ala., Feb. 17, 1866.
[1104] G. O. No. 1, Dept. Ala., Jan. 5, 1866.
[1105] G. O. No. 13, Dept. Ala., 1866.
[1106] G. O. No. 17, Dept. Ala., 1866.
[1107] G. O. No. 20, Dept. Ala., 1866.
[1108] G. O. No. 23, Dept. Ala., 1866.
There were other trials, but the records are missing and the names
of the parties are unknown. A large number of cases were
prosecuted before military commissions convened at the instance of
the Freedmen’s Bureau.
[1109] For two years after the war the Confederate sympathizers in
north Alabama suffered from persecution of this kind. During the
war the Confederates in north Alabama had been classed as guerillas
by the Federal commanders.
[1110] G. O. No. 29, Mil. Div. Tenn., Sept. 21, 1865; G. O. No. 42,
Dept. Ala., Sept. 26, 1865.
[1111] G. O. No. 3, H. Q. A., Jan. 12, 1866; G. O. No. 7, Dept. Ala.,
Feb. 12, 1866.
[1112] G. O. No. 48, Dept. Ala., Oct. 18, 1865.
[1113] G. O. No. 6, Mil. Div. Tenn., Feb. 21, 1866.
[1114] G. O. No. 25, Mil. Div. Tenn., Sept. 13, 1865.
[1115] G. O. No. 44, H. Q. A., July 6, 1866; G. O. No. 13, Dept. of
the South, July 21, 1866.
[1116] Sen. Ex. Doc., No. 26, 39th Cong., 1st Sess.
[1117] P. M. Dox to Governor Parsons, Sen. Ex. Doc., No. 26, 39th
Cong., 1st Sess.
[1118] See p. 327.
[1119] Selma Times, Feb. 3, 1866.
[1120] There were really three governments in Alabama based on
the war powers of the President: (1) the army ruling through its
commanders; (2) the Freedmen’s Bureau, with its agents; (3) the
provisional civil government.
[1121] Circular No. 1, Aug. —, 1865; G. O. No. 21, Dept. Ala., April
9, 1866.
[1122] De Bow’s Review, 1866. De Bow made a trip through the
South. Nation, Oct. 5 and 26, 1865; Truman, Report to President,
April 9, 1866. See also Grant, Letter to President, Dec. 18, 1865.
[1123] Colonel Herbert says that the relations between the soldiers
and the ex-Confederates were very kindly, but the latter hoped the
army would soon be removed, when civil government was
established. “Solid South,” p. 30.
[1124] Miller, “Alabama,” p. 242; Resolutions of the Legislature, Jan.
16, 1866.
[1125] Testimony of Swayne, Report Joint Committee, 1866, Pt. III,
p. 139; various reports of Swayne as assistant commissioner of
Freedmen’s Bureau. It was noticeable that when Swayne was placed
in command of the army in the state there was less interference and
better order than before, though he never obtained the cavalry.
[1126] For instance: In the city of Mobile a petition of some kind
might be made out in proper form and given to the commander of
the Post of Mobile. The latter would indorse it with his approval or
disapproval, and send it to the commander of the District of Mobile,
who likewise forwarded it with his indorsement to the commander of
the Department of Alabama at Mobile or Montgomery. In important
cases the paper had to go on until it reached headquarters in
Macon, Nashville, Louisville, Atlanta, or Washington, and it had to
return the same way.
The following orders relate to the changes made so often:—
G. O. Nos. 1, 9, 10, 12, 17, 19, 20, 27, Dept. Ala., from July 18 to
Sept. 1, 1865; G. O. No. 18, Dept. Ala., March 30, 1866; G. O. No. 1,
Dist. Ala., June 1, 1866; G. O. No. 1, Sub-dist. Ala., Oct. —, 1866; G.
O. No. 1, Mil. Div. Tenn., June 20, 1865; G. O. Nos. 1 and 42, Dept.
of the Tenn., Aug. 13 and Nov. 1, 1866; G. O. No. 1, Dept. of the
South, June 1, 1866; G. O. No. 1, Dept. of the Gulf, ——, 1865; G.
O. No. 1, Dist. of the Chattahoochee, Aug. —, 1866.
There were numerous general orders from local headquarters of the
same nature. See also Van Horne, “Life of Thomas,” pp. 153, 399,
400, 418; and Sen. Ex. Doc., No. 13, 38th Cong., 2d Sess.
[1127] G. O. No. 1, Sub-dist. Ala., March 28, 1867.
[1128] Freedmen’s Bureau Report, Oct. 20, 1869; Ho. Ex. Doc., No.
143, 41st Cong., 2d Sess.
[1129] Sen. Ex. Doc., No. 28, 38th Cong., 2d Sess.
[1130] Regulations, July 9, 1864.
[1131] Stats.-at-Large, Vol. XIII, pp. 507-509. See also O. O.
Howard, “The Freedmen during the War,” in the New Princeton
Review, May and Sept., 1886.
[1132] Ho. Ex. Doc., No. 7, 39th Cong., 2d Sess.
[1133] McPherson, “Reconstruction,” pp. 69-74, 147-151, 349, 350,
378; Burgess, “Reconstruction,” pp. 87-90.
[1134] N. Y. Times, Oct. 31, 1865.
[1135] Circular No. 16, Sept. 19, 1865 (Howard); Circular No. 6,
June 13, 1865 (Howard); Ho. Ex. Doc., No. 70, 39th Cong., 1st
Sess.; Circular No. 1, July 14, 1865 (Conway); Circular No. 2, July
14, 1865 (Conway).
[1136] One of them—Chaplain C. W. Buckley—was guardian of the
blacks at Montgomery. He afterwards played a prominent part in
carpet-bag politics.
[1137] Ku Klux Rept., p. 441; N. Y. World, July 20, 1865; oral
accounts and letters. It was on this theory that the Bureau was
established, and at the head of the institution was placed General O.
O. Howard, who was a soft-hearted, unpractical gentleman, with
boundless confidence in the negro and none whatever in the old
slave owner. A man of hard common sense like Sherman would have
done less harm and probably much good with the Bureau.
[1138] Ho. Ex. Doc., No. 70, 39th Cong., 1st Sess.
[1139] Circular No. 5, June 2, 1865 (Howard); Circular No. 2, July
14, 1865 (Conway); Ho. Ex. Doc., No. 70, 39th Cong., 1st Sess.
[1140] Freedmen’s Bureau Report, Dec., 1865.
[1141] In November, 1866, the following army officers, most of
whom were members of the Veteran Reserve Corps, were made
superintendents of these depots: Montgomery, Capt. J. L. Whiting,
V.R.C.; Mobile, Brevet Major G. H. Tracy, 15th Infantry; Huntsville,
Brevet Col. J. B. Callis, V.R.C.; Selma, Lieut. George Sharkley;
Greenville, James F. McGogy, Late First Lieut. U.S.A.; Tuscaloosa,
Capt. W. H. H. Peck, V.R.C.; Talladega, J. W. Burkholder, A.A.G.,
U.S.A.; Demopolis, Brevet Major C. W. Pierce, V.R.C. Other Bureau
officials who afterward became well-known carpet-baggers were:
Major C. A. Miller, 2d Maine Cavalry, A.A.G.; Major B. W. Norris,
Additional Paymaster; Lieut.-Col. Edwin Beecher, Additional
Paymaster; Rev. C. W. Buckley, Chaplain 47th U.S.C. Infantry. Other
officers of the V.R.C. who arrived later were Capt. Roderick Theune,
Lieuts. George F. Browing, G. W. Pierce, John Jones, P. E. O’Conner,
and Joseph Logan. See Swayne’s Report, Oct. 31, 1866; Sen. Ex.
Doc., No. 21, 40th. Cong., 2d Sess. With one exception these later
assisted in Reconstruction.
[1142] Freedmen’s Bureau Report, Oct. 24, 1869.
[1143] Freedmen’s Bureau Report, Oct. 24, 1868.
[1144] McPherson’s scrap-book, “Freedmen’s Bureau Bill, 1866,” p.
128.
[1145] For examples, see Schurz’s Report and accompanying
documents, Nos. 20, 21, 22, 28; Taylor, “Destruction and
Reconstruction”; article by Schurz in McClure’s Magazine, Jan., 1904.
[1146] The Nation, Feb. 15, 1866.
[1147] Report of the Joint Committee on Reconstruction, Pt. III, p.
138.
[1148] G. O. No. 7, Montgomery, Aug. 4, 1865.
[1149] No one ever knew exactly how far the military commander
was bound to obey the assistant commissioner and vice versa. The
problem was at last solved by making Swayne military commander
also.
[1150] Report of the Joint Committee on Reconstruction, Pt. III, p.
138 (testimony of General Wager Swayne).
[1151] Report of the Joint Committee on Reconstruction, Pt. III, p.
138.
[1152] Swayne did not hesitate to intimidate such men as Parsons.
He would treat old men—former senators, governors, and
congressmen—as if they were bad boys; he himself was under thirty.
[1153] The reason for this was that the day before several Federal
drunken officers had been careering around the bay in a boat, and
Forsyth, who was on this boat, did not want his party of ladies to
meet them.
[1154] Statement of Swayne, 1901; N. Y. News, Aug. 21, 1865.
[1155] Circular No. 20 (Freedmen’s Bureau), War Dept., Nov. 30,
1865.
[1156] Circular No. 15, Sept. 12, 1865.
[1157] McPherson, “Reconstruction,” p. 13.
[1158] Richardson, Messages and Papers of the Presidents, Vol. VI,
p. 352; G. O. No. 64, Dept. Ala., Dec. 10, 1865; Swayne’s Report,
Jan. 31, 1865; Freedmen’s Bureau Reports, Dec., 1865, and Nov.,
1866.
[1159] Freedmen’s Bureau Report, Dec., 1895; Swayne’s Reports,
Jan. 31 and Oct. 31, 1866, in Ho. Ex. Doc., No. 70, and Sen. Ex.
Doc., No. 6, 39th Cong., 1st Sess.
[1160] Freedmen’s Bureau Report, Nov. 1, 1866.
[1161] Ho. Rept., No. 121, 41st Cong., 2d Sess.; Sen. Ex. Doc., No.
6, 39th Cong., 1st Sess.
[1162] Freedmen’s Bureau Reports, Dec., 1865, and Nov., 1866; Ho.
Ex. Doc., No. 142 41st Cong., 2d Sess.; Miller, “History of Alabama,”
p. 240. Congress appropriated $20,000,000, and there was an
immense amount of Confederate property confiscated and sold for
the benefit of the Bureau. Of this no account was kept. One detailed
estimate of Bureau expenses is as follows:—
Appropriations by Congress $20,000,000
General Bounty Fund 8,000,000
Freedmen and Refugee Fund 7,000,000
Retained Bounty Fund (Butler) 2,000,000
School Fund (Confiscated Property) 2,500,000
Total $39,500,000
Edwin De Leon, “Ruin and Reconstruction of the Southern States,” in
Southern Magazine, 1874. See also Ho. Ex. Doc., No. 142, 41st
Cong., 2d Sess.
[1163] G. O. No. 4, July 28, 1865.
[1164] N. Y. News, Sept. 7, 1865 (Montgomery correspondent); Ku
Klux Rept., p. 441; oral accounts.
[1165] Montgomery Mail, May 12, 1865.
[1166] Howard’s Circular, May 30, 1865; War Department Circular
No. 11, July 12, 1865.
[1167] Huntsville Advocate, July 26, 1865. This was when the army
officials were conducting the Bureau. Later the civilian agents
charged $2 for making every contract, and the negroes soon wanted
the Bureau abolished so far as it related to contracts. N. Y. Times,
March 12, 1866 (letter from Florence, Ala.). In Madison County some
of the negroes tarred and feathered a Bureau agent who had been
collecting $1.50 each for drawing contracts. N. Y. Herald, Dec. 22,
1867.
[1168] Swayne’s Report, Jan. 31, 1866.
[1169] These regulations bear the approval of the other two rulers
of Alabama—General Woods and Governor Parsons. See G. O. No.
12, Aug. 30, 1865.
[1170] G. O. No. 13, Sept., 1865. This order was in force until 1868.
See N. Y. World, Nov. 20, 1867.
[1171] These propositions were approved by A. Humphreys,
assistant superintendent at Talladega, and by General Chetlain,
commanding the District of Talladega. Selma Times, Dec. 4, 1865.
[1172] Selma Messenger, Nov. 15, 1865; N. Y. World, Nov. 20, 1867.
[1173] Ku Klux Rept., p. 441; N. Y. News, Sept. 7, 1865; oral
accounts.
[1174] Swayne’s Report, Jan., 1866. Rev. C. W. Buckley, in a report
to Swayne (dated Jan. 5, 1866), of a tour in Lowndes County, stated
that while the Bureau and the army and the “government of the
Christian nation,” each had done much good, all was as nothing to
what God was doing. The hand of God was seen in the stubborn and
persistent reluctance of the negro to make contracts and go to work;
God had taught the 8,000,000 arrogant and haughty whites that
they were dependent upon the freedmen; God had ordained that
“the self-interest of the former master should be the protection of
the late slaves.”
[1175] Swayne’s Report, Oct. 31, 1865.
[1176] Freedmen’s Bureau Report, Oct. 24, 1868.
[1177] De Bow’s Review, 1866.
[1178] Freedmen’s Bureau Report, Dec., 1865.
[1179] Howard’s Circular Letter, Oct. 4, 1865.
[1180] Report, Oct. 31, 1866.
[1181] Herbert, “Solid South,” p. 31; N. Y. News, Sept. 3, 1865
(Selma correspondent).
[1182] In one case the agent in Montgomery sent to Troy, fifty-two
miles distant, and arrested a landlord who refused to rent a house to
a negro. The negro told the Bureau agent that he was being evicted.
[1183] There were several plantations near Montgomery, Selma,
Mobile, and Huntsville where negroes were thus collected.
[1184] In Montgomery, the Rev. C. W. Buckley, a “hard-shell”
preacher, looked after negro contracts. A negro was not allowed to
make his own contract, but it must be drawn up before Buckley.
When a negro broke his contract, Buckley always decided in his
favor, and avowed that he would sooner believe a negro than a
white man. His delight was to keep a white man waiting for a long
time while he talked to the negro, turning his back to and paying no
attention to the white caller. He preached to the negroes several
times a week, not sermons, but political harangues. The audience
was composed chiefly of negro women, who, if they had work,
would leave it to attend the meetings. They would not disclose what
Buckley said to them, and when questioned would reply, “It’s a
secret, and we can’t tell it to white folks.” Buckley advocated
confiscation, but Swayne, who had more common sense, frowned
upon such theological doctrines.
[1185] Barker, a carriage-maker at Livingston, was arrested and
confined in prison for some time, and finally was released without
trial. He was told that a negro servant had preferred charges against
him, and later denied having done so. Such occurrences were
common. Ku Klux Rept. Ala. Test., pp. 357, 371, 390, 475, 487,
1132; Ho. Ex. Doc., No. 27, 39th Cong., 1st Sess.; Swayne’s Reports,
Dec., 1865, and Jan., 1866.
[1186] Selma Times, April 11, 1866. Busteed was a much-disliked
carpet-bag Federal judge. Mr. Burns survived the Busting, and was a
member of the Constitutional Convention of 1901.
[1187] The Bureau courts continued to act even after the state was
readmitted to the Union. In 1868, two constables arrested a negro
charged with house-burning in Tuscumbia. Col. D. C. Rugg, the
Bureau agent at Huntsville, raised a force of forty negroes and came
to the rescue of the negro criminal. “If you attempt to put that negro
on the train,” he said, “blood will be spilled. I am acting under the
orders of the military department.” The officers were trying to take
him to Tuscumbia for trial. Rugg thought the Bureau should try him,
and said, “These men [the negroes] are not going to let you take
the prisoner away, and blood will be shed if you attempt it.” N. Y.
World, Oct. 23, 1868; Tuscaloosa Times.
[1188] Probably more. Freedmen’s Bureau Report, Nov. 1, 1866.
[1189] Bureau Reports, 1865-1869.
[1190] Freedmen’s Bureau Reports, 1865-1870; Hardy, “History of
Selma”; N. Y. World, Nov. 13, 1865.
[1191] The Southern Famine Relief Commission of New York, which
worked in Alabama until 1867, reported that there was much greater
suffering from want among the whites than among the blacks. This
society sent corn alone to the state,—65,958 bushels. See Final
Proceedings and General Report, New York, 1867.
[1192] Freedmen’s Bureau Reports, 1865-1868.
[1193] Ho. Rept., No. 121, 41st Cong., 2d Sess.
[1194] Sen. Ex. Doc., No. 6, 39th Cong., 1st Sess.
[1195] Freedmen’s Bureau Report, Dec., 1865.
[1196] Swayne’s Report, Oct. 31, 1866; N. Y. Daily News, Sept. 7,
1865 (Montgomery correspondent).
[1197] Trowbridge, “The South,” p. 446.
[1198] In the convention of 1867 this teaching bore fruit in the
ordinance authorizing suits by former slaves to recover wages from
Jan. 1, 1863.
[1199] N. Y. World, Nov. 13, 1865 (Selma correspondent); oral
accounts.
[1200] De Bow’s Review, March, 1866 (Dr. Nott); N. Y. Times, Oct. 3,
1865; Montgomery Advertiser, March 21, 1866.
[1201] Du Bois in Atlantic Monthly, March, 1901.
[1202] A Tallapoosa County farmer stated that for three years after
the war the crops were very bad. Yet the whites who had negroes
on their farms felt bound to support them. But if the whites tried to
make the negroes work or spoke sharply to them, they would leave
and go to the Bureau for rations. P. M. Dox, a Democratic member of
Congress in 1870, said that in north Alabama, in 1866-1867, negro
women would not milk a cow when it rained. Servants would not
black boots. There was a general refusal to do menial service. Ala.
Test., pp. 345, 1132. The Alabama cotton crop of 1860 was 842,729
bales; of 1865, 75,305 bales; of 1866, 429,102 bales; of 1867,
239,516 bales; of 1868, 366,193 bales. Of each crop since the war
an increasingly large proportion has been raised by the whites.
[1203] Swayne’s Report, Oct. 31, 1866.
[1204] Within the last five years I have seen several old negroes
who said they had been paying assessments regularly to men who
claimed to be working to get the “forty acres and the mule” for the
negro. They naturally have little to say to white people on the
subject. From what I have been told by former slaves, I am inclined
to think that the negroes have been swindled out of many hard-
earned dollars, even in recent times, by the scoundrels who claim to
be paying the fees of lawyers at work on the negroes’ cases.
[1205] Swayne’s Report, Oct. 31, 1866; Freedmen’s Bureau Report,
Dec., 1865; Grant’s Report; Truman’s Report, April 9, 1866; DeBow’s
Review, March, 1866; Montgomery Advertiser, March 1, 1866; N. Y.
News, Nov. 25, 1865 (Selma correspondent); N. Y. World, Nov. 13,
1865; N. Y. Times, Oct. 31, 1865; N. Y. News, Sept., and Oct. 2, 7,
1865. B. W. Norris, a Bureau agent from Skowhegan, Maine, told the
negroes the tale of “forty acres and a mule,” and they sent him to
Congress in 1868 to get the land for them. He told them that they
had a better right to the land than the masters had. “Your work
made this country what it is, and it is yours.” Ala. Test., pp. 445,
1131.
[1206] Ala. Test., p. 314.
[1207] Ball, “Clarke County,” p. 627.
[1208] Ala. Test., p. 1133.
[1209] Ala. Test., p. 460; see Annual Cyclopædia (1867), article
“Confiscation.”
[1210] Montgomery Advertiser, March, 1866. Buckley was known
among the “malignants” as “the high priest of the nigger Bureau.” N.
Y. World, Dec. 22, 1867.
[1211] N. Y. Herald, July 23, 1865; Herbert, “Solid South,” p. 30.
[1212] DeBow’s Review, 1866; oral accounts.
[1213] N. Y. Times, Feb. 12, 1866 (letter of northern traveller);
Steedman and Fullerton’s Reports; N. Y. Herald, June 24, 1866;
Columbus (Ga.) Sun, Nov. 22, 1865; N. Y. Times, Jan. 25, 1866.
[1214] Account by Col. J. W. DuBose in manuscript.
[1215] Herbert, “Solid South,” pp. 30, 31; N. Y. Times, Jan. 25,
1866.
[1216] Ho. Rept., No. 121, 41st Cong., 2d Sess.; Ku Klux Rept., p.
441. See chapter in regard to Union League.
[1217] See also DuBois, in Atlantic Monthly, March, 1901; Ho. Ex.
Doc., No. 241, 41st Cong., 2d Sess.
[1218] Ho. Rept., No. 121, p. 47, 41st Cong., 2d Sess.
[1219] Some of the prominent incorporators were Peter Cooper,
William C. Bryant, A. A. Low, Gerritt Smith, John Jay, A. S. Barnes, J.
W. Alvord, S. G. Howe, George L. Stearns, Edward Atkinson, and A.
A. Lawrence. The act of incorporation was approved by the President
on March 3, 1865, at the same time the Freedmen’s Bureau Bill was
approved. Numbers of the incorporators and bank officials were
connected with the Bureau. See Ho. Mis. Doc., No. 16, 43d Cong., 2d
Sess.
[1220] A Bureau paymaster.
[1221] Ho. Mis. Doc., No. 16, 43d Cong., 2d Sess.
[1222] Ho. Ex. Doc., No. 70, 39th Cong., 1st Sess.
[1223] See Williams, “History of the Negro Race in America,” Vol. II,
p. 410. August was a month in which there was little money-making
among the negroes. It was vacation time, between the “laying by”
and the gathering of the crop.
[1224] Hoffman, “Race Traits and Tendencies,” p. 290, says
$3,013,699.
[1225] Hoffman, p. 290; also Sen. Rept., No. 440, 46th Cong., 2d
Sess. Williams, Vol. II, p. 411, states that the total deposits
amounted to $57,000,000, an average of $284 for each depositor.
[1226] Dividends were declared as follows: Nov. 1, 1875, 20%;
March 20, 1875-1878, 10%; Sept. 1, 1880, 10%; June 1, 1882,
15%; May 12, 1883, 7%; making 62% in all. To 1886, $1,722,549
had been paid to depositors, and there was a balance in the hands
of the government receivers of $30,476.
[1227] Williams, “History of the Negro Race,” Vol. II, pp. 403-410;
Fred Douglass, “Life and Times,” Ch. XIV; Ho. Mis. Doc., No. 16, 43d
Cong., 2d Sess.; Du Bois, “The Souls of Black Folk”; the various
reports of the Freedmen’s Bureau and of the commissioners
appointed to settle the affairs of the Freedmen’s Savings and Trust
Company, to 1902; Hoffman, “Race Traits and Tendencies,” pp. 289,
290; Fleming, “Documents relating to Reconstruction,” Nos. 6 and 7.
[1228] Regulations of the Treasury Dept., July 29, 1864.
[1229] McPherson, “Rebellion,” pp. 594, 595; McPherson,
“Reconstruction,” pp. 147-151.
[1230] See Ch. IV, sec. 7.
[1231] DuBois (Atlantic Monthly, March, 1901) declares that the
opposition to the education of the negro was bitter, for the South
believed that the educated negro was a dangerous negro. This
statement is perhaps partially correct for fifteen or twenty years
after 1870, but it is not correct for 1865-1869.
[1232] The Gulf States Hist. Mag., Sept., 1902; Report of General
Swayne to Howard, Dec. 26, 1865. The evidence on this point that is
worthy of consideration is conclusive. It is all one way. See also Chs.
XIX and XX, below.
[1233] Report of Swayne, Oct. 31, 1866.
[1234] “Up from Slavery,” pp. 29, 30.
[1235] Daily News, Sept. 7, 1865 (Montgomery correspondence).
Oral accounts.
[1236] G. O. No. 11, July 12, 1865 (Montgomery); Freedmen’s
Bureau Reports, 1865-1869.
[1237] Swayne’s Report, Oct. 31, 1866; Freedmen’s Bureau Report,
1866.
[1238] Swayne’s Report., Oct. 31, 1866.
[1239] Freedmen’s Bureau Report, Dec., 1865; Ho. Ex. Doc., No. 70,
39th Cong., 1st Sess.
[1240] Daily News, Oct. 21, 1865 (Mobile correspondent); De Bow’s
Review, 1866 (Dr. Nott).
[1241] Swayne’s Report, Oct. 31, 1866.
[1242] The account of this particular school was given me by Dr. O.
D. Smith of Auburn, Ala., who was one of the men who chose the
white teacher.
[1243] Swayne’s Report, Oct. 31, 1866.
[1244] Report, Oct. 31, 1866.
[1245] Rent was usually paid at the rate of $20 a month for thirty
pupils. Ho. Rept., No. 121, pp. 47, 369, 374, 377, 41st Cong., 2d
Sess. The books of the American Missionary Association showed that
it had received, in 1868 and 1869, from the Freedmen’s Bureau for
Alabama, the following amounts in cash, though how much it
received before these dates is not known.
December, 1867 $4000.00
October, 1868 583.86
February, 1868 25.41 (?)
January, 1869 218.25
April, 1869 683.53
May, 1869 1397.49
June, 1869 95.87
July, 1869 527.00
September, 1869 3049.59
November, 1869 3469.50
December, 1869 2083.78
For building (?) 20,000.00
An item in the account of the Association was “Chicago to Mobile,
$20,000.” No one was able to explain what it meant unless it was
the $20,000 building in Mobile used as a training school for negro
teachers and on which the Bureau paid rent. In the southern states
the Bureau paid to the American Missionary Association, as shown
by the books of the latter, $213,753.22. Judging from the variable
items not noted above, rent was evidently not included nor even all
the cash. Ho. Rept., No. 121, p. 369 et seq., 41st Cong., 2d Sess.
(Howard Investigation).
[1246] Buckley’s Report for March 15, 1867; Semiannual Report on
Schools for Freedmen, July 4, 1867; General Clanton in Ku Klux
Rept. Ala. Test.
[1247] Francis Wayland.
[1248] S. G. Greene, president of the association.
[1249] President Hill of Harvard College.
[1250] Reports, Proceedings, and Lectures of the National Teachers’
Association, 1865 to 1880; Reports of the Freedmen’s Aid Societies
of the Methodist Episcopal Church. For results of the mistaken
teachings of the radical instructors, see Page’s article on “Lynching”
in the North American Review, Jan., 1904.
[1251] Miss Alice M. Bacon, in the Slater Fund Trustees, Occasional
Papers, No. 7, p. 6. Armstrong, at Hampton, Va., was a shining
exception to the kind of teachers described above.
[1252] The Reconstruction government was now in power. There
were, at this time, thirty-one Bureau schools at thirty-one points in
the state.
[1253] Freedmen’s Bureau Reports, 1867-1870.
[1254] Atlantic Monthly, March, 1901.
[1255] Sir George Campbell, “White and Black,” pp. 131, 383;
Thomas, “The American Negro,” p. 240; Washington, “The Future of
the American Negro,” pp. 25-27, 55; DeBow’s Review, 1866; Slater
Fund Trustees, Occasional Papers, No. 7. Washington tells of the
craze for the education in Greek, Latin, and theology. This education
would make them the equal of the whites, they thought, and would
free them from manual labor, and above all fit them for office-
holding. Nearly all became teachers, preachers, and politicians. “Up
from Slavery,” pp. 30, 80, 81; “Future of the American Negro,” p. 49.
[1256] From the surrender of the Confederate armies, to his death
in 1903, Dr. Curry was a stanch believer in the work for negro
education. No other man knew the whole question so thoroughly as
he. And he had the advantage of a close acquaintance with the
negro from his early childhood. His observations as to the effects of
alien efforts to educate the black will be found in the Slater Fund
Occasional Papers, and in an address delivered before the
Montgomery Conference in 1900. See also Ch. XIV.
[1257] I have talked with many who uniformly assert that they were
unable to conform to the Bureau regulations. It was better to let
land remain uncultivated. Wherever possible no attention was paid
to the rules. The negro laborers themselves have no recollections of
any real assistance in labor matters received from the Bureau. They
remember it rather as an obstruction to laboring freely.
[1258] The President and the Supreme Court now being powerless.
[1259] That is, blacks and such whites as were not “disfranchised for
participation in the rebellion or for felony.”
[1260] July 11, 1868, the oath was modified for those whose
disabilities had been removed by Congress; Feb. 15, 1871, those not
disfranchised by the Fourteenth Amendment were allowed to take
the modified oath of July 11, 1868, instead of the iron-clad oath. See
MacDonald, “Select Statutes.” The Alabama representatives all took
the “iron-clad” oath.
[1261] Text of the Act, McPherson, “Reconstruction,” pp. 191, 192;
G. O. No. 2, 3d M. D., April 3, 1867. For criticism, Burgess,
“Reconstruction,” pp. 112-122; Dunning, “Civil War and
Reconstruction,” pp. 123, 126-135, 143.
[1262] G. O. Nos. 10 and 18, H. Q. A., March 11 and 15, 1867;
McPherson, p. 200.
[1263] Report of Secretary of War, 1867, Vol. I, p. 321.
[1264] The oath was: “I, —— ——, do solemnly swear (or affirm), in
the presence of Almighty God, that I am a citizen of the State of
Alabama; that I have resided in said State for —— months, next
preceding this day, and now reside in the county of —— in said
State; that I am twenty-one years old; that I have not been
disfranchised for participation in any rebellion or civil war against the
United States, nor for felony committed against the laws of any
State or of the United States; that I have never been a member of
any State legislature, nor held any executive or judicial office in any
State and afterward engaged in insurrection or rebellion against the
United States or given aid and comfort to the enemies thereof; that I
have never taken an oath as a member of Congress of the United
States, as an officer of the United States, or as a member of any
State legislature, or as an executive or judicial officer of any State,
to support the Constitution of the United States and afterwards
engaged in insurrection or rebellion against the United States or
given aid and comfort to the enemies thereof; that I will faithfully
support the Constitution and obey the laws of the United States, and
will, to the best of my ability, encourage others to do so, so help me
God!” McPherson, “Reconstruction,” pp. 192, 205; G. O. No. 5, 3d M.
D., April 8, 1867.
[1265] McPherson, “Reconstruction,” pp. 192-194; Burgess,
“Reconstruction,” pp. 129-135; Dunning, “Civil War and
Reconstruction,” pp. 124, 125.
[1266] G. O. Nos. 1 and 2, 3d M. D., April 1 and 3, 1866; N. Y.
Herald, April 6, 1867; Annual Cyclopædia (1867), p. 19; McPherson,
pp. 201, 205; Report of Secretary of War, 1867, Vol. I, p. 322;
Herbert, “Solid South,” p. 38.
[1267] G. O. No. 1, Dist. Ala., April 2, 1867; McPherson, p. 206.
[1268] Report of Secretary of War, 1867, Vol. I, p. 466; N. Y. Herald,
April 6, 1867.
[1269] Ho. Ex. Doc., No. 20, 40th Cong., 1st Sess.
[1270] G. O. No. 52, H. Q. A., April 11, 1867.
[1271] Report of Secretary of War, 1867, Vol. I, p. 353.
[1272] G. O. No. 4, 3d M. D., April 4, 1867.
[1273] G. O. No. 10, 3d M. D., April 23, 1867.
[1274] G. O. No. 48, 3d M. D., Aug. 6, 1867.
[1275] Annual Cyclopædia (1867), p. 17.
[1276] G. O. No. 25, 3d M. D., May 29, 1867. (This was to favor
Radical meetings. There were many stump speakers sent down from
the North to tell the negro how to vote, and it was feared they might
excite the whites to acts of violence.) N. Y. Herald, June 4, 1867
(explanatory order).
[1277] McPherson, “Reconstruction,” pp. 335, 336; Dunning, pp.
153, 154.
[1278] As long as Pope was in command at Montgomery and
Atlanta, he and Grant kept up a rapid and voluminous (on the part of
Pope) correspondence. They were usually agreed on all that
pertained to Reconstruction, both now being extreme in their views.
[1279] Ho. Ex. Doc., No. 30, 40th Cong., 2d Sess.; No. 20, 40th
Cong., 1st Sess.; McPherson, p. 312.
[1280] G. O. No. 45, 3d M. D., Aug. 2, 1867; McPherson, p. 319.
[1281] G. O. Nos. 53 and 55, 3d M. D., Aug. 19 and 23, 1867;
Report of the Secretary of War, 1867, Vol. I, p. 331; McPherson, p.
319.
[1282] See Selma Messenger, Jan. 17, 1868.
[1283] See McPherson, p. 312.
[1284] Eutaw Whig and Observer, Dec. 12 and 24, 1867.
[1285] S. O. No. 2, 3d M. D., April 15, 1867; Annual Cyclopædia
(1867), p. 20; Montgomery Mail, April 30, 1867.
[1286] See p. 509.
[1287] G. O. Nos. 35, 38, 40, Post of Mobile, 1867; Annual
Cyclopædia (1867), pp. 20-23; N. Y. Times, May 21, 1867.
[1288] N. Y. World, May 28, 1867; S. O. No. 34, 3d M. D., May 31,
1867; Herbert, “Solid South,” p. 40; N. Y. Times, May 21, 1867.
[1289] S. O. No. 38, 3d M. D., June 6, 1867; S. O. No. 27, 3d M. D.,
May 22, 1867; N. Y. Tribune, June 12, 1867; Selma Messenger, June
18, 1867; Evening Post, May, 1867; Annual Cyclopædia (1867), pp.
20-25; Mobile Register, Oct. —, 1867.
[1290] Mobile Register, Oct. —, 1867.
[1291] Herbert, “Solid South,” pp. 40, 41; N. Y. Times, Dec. 27,
1867. See above, p. 393.
[1292] S. O. Nos. 9, 10, 16, 18, 19, 20, 22, 24, 25, 26, 27, 31, 32,
35, 36, 37, 38, 39, 3d M. D., 1867; Report of the Secretary of War,
1867, Vol. I, p. 327. (Some of the persons appointed were B. T. Pope
and David P. Lewis, judges; George P. Goldthwaite, solicitor; and B.
F. Saffold, mayor of Selma.)
[1293] Report of the Secretary of War, 1867, Vol. I, p. 364.
[1294] G. O. No. 77, 3d M. D., Oct. 19, 1897; McPherson, p. 319.
[1295] G. O. No. 103, 3d M. D., Dec. 21, 1867.
[1296] Report of the Secretary of War, 1877, Vol. I, p. 333;
McPherson, p. 316.
[1297] S. O. 254, 3d M. D., Nov. 26, 1867; Pope to Swayne, Nov. 20,
1867; N. Y. World, Dec. 14, 1867.
[1298] G. O. No. 3, Sub-dist. Alabama, April 12, 1867; McPherson, p.
319.
[1299] McPherson, p. 319.
[1300] N. Y. Herald, April 6, 1867.
[1301] N. Y. Tribune, June 1, 1867; N. Y. Herald, June 4, 1867; G. O.
No. 28, 3d M. D., June 3, 1867; Report of the Secretary of War,
1867, Vol. I, p. 326.
[1302] Aug. 12, 1867.
[1303] G. O. Nos. 1 and 10.
[1304] G. O. No. 49, 3d M. D., Aug. 12, 1867.
[1305] Report of the Secretary of War, 1867, Vol. I, p. 235.
[1306] Selma Messenger, Dec. 25, 1867.
[1307] G. O. No. 25, 3d M. D., 1867.
[1308] S. O. No. 53, 3d M. D., June 27, 1867; G. O. No. 44, 3d M. D.,
Aug. 1, 1867; Ho. Ex. Doc., No. 30, 40th Cong., 2d Sess.
[1309] G. O. No. 94, 3d M. D., 1867.
[1310] S. O. No. 96, 3d M. D., Aug 5. 1867; Ho. Ex. Doc., No. 30,
40th Cong., 2d Sess. There were other cases not referred to in
general and special orders, but this was the only case in which Pope
himself directly interfered.
[1311] G. O. No. 5, 3d M. D., April 8, 1867.
[1312] In this way, white majorities in ten counties were overcome
by black majorities in the adjoining counties of the district.
[1313] Of the registrars who later became somewhat prominent in
politics, the whites were Horton, Dimon, Dereen, Sillsby, William M.
Buckley, Stanwood, Ely, Pennington, Haughey—all being northern
men. Of the negro members of the boards, Royal, Finley, Williams,
Alston, Turner, Rapier, and King (or Godwin) rose to some
prominence, and their records were much better that those of their
white colleagues.
[1314] G. O. No. 20, 3d M. D., May 21, 1867.
[1315] G. O. No. 12, 3d M. D., 1867.
[1316] Smith was later the first Reconstruction governor of Alabama.
[1317] G. O. No. 41, 3d M. D., 1867.
[1318] G. O. No. 50, 3d M. D., Aug. 15, 1867.
[1319] Governor, secretary of state, treasurer, comptroller, sheriff,
judicial officers of every kind, and all court clerks and other officials,
commissioners, tax assessors and collectors, county surveyors,
treasurers, mayor, councilmen, justices of the peace, solicitors.
[1320] Special Instructions to Registrars in Alabama, Report of the
Secretary of War, 1867, Vol. I, p. 339.
[1321] Registration Orders, June 17, 1867.
[1322] Record of Cabinet Meeting, June 18, 1867, in Ho. Ex. Doc.,
No, 34, 40th Cong., 1st Sess.; Burgess, p. 136; Ho. Ex. Doc., No. 20,
40th Cong., 1st Sess.
[1323] Ho. Ex. Doc., No. 20, 40th Cong., 1st Sess.; McPherson, p.
311. See above, p. 479.
[1324] McPherson, pp. 335, 336; Burgess, pp. 138-142.
[1325] McPherson, pp. 335, 336.
[1326] G. O. No. 59, 3d M. D., Aug. 31, 1867; Journal of Convention
of 1867, pp. 3-5; Report of the Secretary of War, 1867, Vol. I, pp.
356, 357; Tribune Almanac, 1868.
Welcome to our website – the perfect destination for book lovers and
knowledge seekers. We believe that every book holds a new world,
offering opportunities for learning, discovery, and personal growth.
That’s why we are dedicated to bringing you a diverse collection of
books, ranging from classic literature and specialized publications to
self-development guides and children's books.
More than just a book-buying platform, we strive to be a bridge
connecting you with timeless cultural and intellectual values. With an
elegant, user-friendly interface and a smart search system, you can
quickly find the books that best suit your interests. Additionally,
our special promotions and home delivery services help you save time
and fully enjoy the joy of reading.
Join us on a journey of knowledge exploration, passion nurturing, and
personal growth every day!
ebookbell.com

More Related Content

PDF
Ios 12 App Development Essentials Learn To Develop Ios 12 Apps With Xcode 10 ...
PDF
Learning Swift 3 Early release 3rd Edition Jonathan Manning
PDF
Learning Swift Building Apps for OSX, iOS, and Beyond Jon Manning
PDF
Learning Swift Building Apps for OSX, iOS, and Beyond Jon Manning 2024 scribd...
PDF
Ios 5 Programming Cookbook Solutions Examples For Iphone Ipad And Ipod Touch ...
PDF
Learning Swift Building Apps for macOS iOS and Beyond 3rd Edition Jonathon Ma...
PDF
iOS 8 Swift Programming Cookbook Solutions Examples for iOS Apps 1st Edition ...
PDF
Swift Online Training.pdf
Ios 12 App Development Essentials Learn To Develop Ios 12 Apps With Xcode 10 ...
Learning Swift 3 Early release 3rd Edition Jonathan Manning
Learning Swift Building Apps for OSX, iOS, and Beyond Jon Manning
Learning Swift Building Apps for OSX, iOS, and Beyond Jon Manning 2024 scribd...
Ios 5 Programming Cookbook Solutions Examples For Iphone Ipad And Ipod Touch ...
Learning Swift Building Apps for macOS iOS and Beyond 3rd Edition Jonathon Ma...
iOS 8 Swift Programming Cookbook Solutions Examples for iOS Apps 1st Edition ...
Swift Online Training.pdf

Similar to Beginning Ios Programming With Swift And Swiftui Ios 15 Simon Ng (20)

PDF
Swift Online Training.pdf
PDF
iOS 5 Programming Cookbook Solutions Examples for iPhone iPad and iPod touch ...
PDF
iOS 5 Programming Cookbook Solutions Examples for iPhone iPad and iPod touch ...
PDF
Learning Swift 3 Early release 3rd Edition Jonathan Manning
PDF
Learning the iOS 4 SDK for JavaScript Programmers Create Native Apps with Obj...
PDF
iOS 5 Programming Cookbook Solutions Examples for iPhone iPad and iPod touch ...
PDF
iOS 7 in Action 1st Edition Brendan G. Lim
PDF
Learn ios9-programming
PDF
iOS 7 in Action 1st Edition Brendan G. Lim
PDF
Ios 7 Programming Cookbook 2nd Edition Vandad Nahavandipoor
PDF
iOS 7 Programming Cookbook 2nd Edition Vandad Nahavandipoor
PDF
App Development with Swift, by Apple
PDF
iOS 7 Programming Cookbook 2nd Edition Vandad Nahavandipoor
PDF
iOS 7 Programming Cookbook 2nd Edition Vandad Nahavandipoor
PDF
iOSMumbai Meetup Keynote
PPTX
Basic iOS Training with SWIFT - Part 1
PDF
Learning the iPhone SDK for JavaScript Programmers Create Native Apps with Ob...
PDF
Ios 4 Programming Cookbook Solutions Examples For Iphone Ipad And Ipod Touch ...
PDF
iPhone in action introduction to Web and SDK development 1st Edition Christop...
PDF
Никита Корчагин - Introduction to iOS development
Swift Online Training.pdf
iOS 5 Programming Cookbook Solutions Examples for iPhone iPad and iPod touch ...
iOS 5 Programming Cookbook Solutions Examples for iPhone iPad and iPod touch ...
Learning Swift 3 Early release 3rd Edition Jonathan Manning
Learning the iOS 4 SDK for JavaScript Programmers Create Native Apps with Obj...
iOS 5 Programming Cookbook Solutions Examples for iPhone iPad and iPod touch ...
iOS 7 in Action 1st Edition Brendan G. Lim
Learn ios9-programming
iOS 7 in Action 1st Edition Brendan G. Lim
Ios 7 Programming Cookbook 2nd Edition Vandad Nahavandipoor
iOS 7 Programming Cookbook 2nd Edition Vandad Nahavandipoor
App Development with Swift, by Apple
iOS 7 Programming Cookbook 2nd Edition Vandad Nahavandipoor
iOS 7 Programming Cookbook 2nd Edition Vandad Nahavandipoor
iOSMumbai Meetup Keynote
Basic iOS Training with SWIFT - Part 1
Learning the iPhone SDK for JavaScript Programmers Create Native Apps with Ob...
Ios 4 Programming Cookbook Solutions Examples For Iphone Ipad And Ipod Touch ...
iPhone in action introduction to Web and SDK development 1st Edition Christop...
Никита Корчагин - Introduction to iOS development
Ad

Recently uploaded (20)

PDF
3rd Neelam Sanjeevareddy Memorial Lecture.pdf
PDF
102 student loan defaulters named and shamed – Is someone you know on the list?
PPTX
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
PPTX
BOWEL ELIMINATION FACTORS AFFECTING AND TYPES
PDF
grade 11-chemistry_fetena_net_5883.pdf teacher guide for all student
PDF
Abdominal Access Techniques with Prof. Dr. R K Mishra
PDF
ANTIBIOTICS.pptx.pdf………………… xxxxxxxxxxxxx
PPTX
Cell Structure & Organelles in detailed.
PDF
Microbial disease of the cardiovascular and lymphatic systems
PPTX
Institutional Correction lecture only . . .
PDF
VCE English Exam - Section C Student Revision Booklet
PDF
BÀI TẬP BỔ TRỢ 4 KỸ NĂNG TIẾNG ANH 9 GLOBAL SUCCESS - CẢ NĂM - BÁM SÁT FORM Đ...
PDF
01-Introduction-to-Information-Management.pdf
PPTX
Final Presentation General Medicine 03-08-2024.pptx
PPTX
IMMUNITY IMMUNITY refers to protection against infection, and the immune syst...
PPTX
Pharma ospi slides which help in ospi learning
PPTX
Introduction to Child Health Nursing – Unit I | Child Health Nursing I | B.Sc...
PDF
Physiotherapy_for_Respiratory_and_Cardiac_Problems WEBBER.pdf
PDF
FourierSeries-QuestionsWithAnswers(Part-A).pdf
PDF
Classroom Observation Tools for Teachers
3rd Neelam Sanjeevareddy Memorial Lecture.pdf
102 student loan defaulters named and shamed – Is someone you know on the list?
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
BOWEL ELIMINATION FACTORS AFFECTING AND TYPES
grade 11-chemistry_fetena_net_5883.pdf teacher guide for all student
Abdominal Access Techniques with Prof. Dr. R K Mishra
ANTIBIOTICS.pptx.pdf………………… xxxxxxxxxxxxx
Cell Structure & Organelles in detailed.
Microbial disease of the cardiovascular and lymphatic systems
Institutional Correction lecture only . . .
VCE English Exam - Section C Student Revision Booklet
BÀI TẬP BỔ TRỢ 4 KỸ NĂNG TIẾNG ANH 9 GLOBAL SUCCESS - CẢ NĂM - BÁM SÁT FORM Đ...
01-Introduction-to-Information-Management.pdf
Final Presentation General Medicine 03-08-2024.pptx
IMMUNITY IMMUNITY refers to protection against infection, and the immune syst...
Pharma ospi slides which help in ospi learning
Introduction to Child Health Nursing – Unit I | Child Health Nursing I | B.Sc...
Physiotherapy_for_Respiratory_and_Cardiac_Problems WEBBER.pdf
FourierSeries-QuestionsWithAnswers(Part-A).pdf
Classroom Observation Tools for Teachers
Ad

Beginning Ios Programming With Swift And Swiftui Ios 15 Simon Ng

  • 1. Beginning Ios Programming With Swift And Swiftui Ios 15 Simon Ng download https://ebookbell.com/product/beginning-ios-programming-with- swift-and-swiftui-ios-15-simon-ng-36056204 Explore and download more ebooks at ebookbell.com
  • 2. Here are some recommended products that we believe you will be interested in. You can click the link to download. Beginning Ios Programming With Swift And Swiftui Ios 18 And Xcode 16 Simon Ng https://ebookbell.com/product/beginning-ios-programming-with-swift- and-swiftui-ios-18-and-xcode-16-simon-ng-230820558 Beginning Ios Programming With Swift And Uikit Ios 15 Simon Ng https://ebookbell.com/product/beginning-ios-programming-with-swift- and-uikit-ios-15-simon-ng-36478672 Beginning Reactive Programming With Swift Using Rxswift Amazon Web Services And Json With Ios And Macos 1st Ed Jesse Feiler https://ebookbell.com/product/beginning-reactive-programming-with- swift-using-rxswift-amazon-web-services-and-json-with-ios-and- macos-1st-ed-jesse-feiler-7319500 Beginning Ios Programming With Swift Simon Ng https://ebookbell.com/product/beginning-ios-programming-with-swift- simon-ng-35006792
  • 3. Beginning Ios 8 Programming With Swift Simon Ng https://ebookbell.com/product/beginning-ios-8-programming-with-swift- simon-ng-5048088 Beginning Ios 10 Programming With Swift Simon Ng https://ebookbell.com/product/beginning-ios-10-programming-with-swift- simon-ng-5705294 Swiftui Apprentice Beginning Ios Programming With Swiftui 1st Edition Audrey Tam Caroline Begbie https://ebookbell.com/product/swiftui-apprentice-beginning-ios- programming-with-swiftui-1st-edition-audrey-tam-caroline- begbie-33600866 Beginning Ios Programming Building And Deploying Ios Applications 1st Edition Nick Harris https://ebookbell.com/product/beginning-ios-programming-building-and- deploying-ios-applications-1st-edition-nick-harris-4657148 Beginning Ios Programming For Dummies Rajiv Ramnath https://ebookbell.com/product/beginning-ios-programming-for-dummies- rajiv-ramnath-4668300
  • 6. Table of Contents Preface Chapter 1 - The Development Tools, the Learning Approach, and the App Idea The Tools The Learning Approach UIKit vs SwiftUI Chapter 2 - Your First Taste of Swift with Playgrounds Trying out Swift in Playgrounds Constants and Variables Understanding Type Inference Control Flow Basics Understanding Optionals Playing around with UI Chapter 3 - Build Your First App in Swift and SwiftUI An Introduction to SwiftUI Declarative vs Imperative Programming Building Your First App Using SwiftUI Run Your App for the First Time Chapter 4 - Designing UI Using Stack Views Understanding VStack, HStack and ZStack Adding Images to the Xcode Project Using Spacer and Padding
  • 7. Using Images Arranging the Images Using Horizontal Stack Views Extracting Views for Better Code Organization Adapting Stack Views Using Size Classes Chapter 5 - Introduction to Prototyping Sketching Your App Ideas on Paper Wireframing Your App Make Your Sketch/Wireframe Interactive Prototyping Your App with App Prototyping Tools Chapter 6 - Understanding List and ForEach Creating a Simple List Presenting a List with Array of Items Adding Thumbnails to the List View Changing the List View's Style Alternative Ways to Present the List Chapter 7 - Customizing List Views Creating the Basic List View Displaying Different Restaurant Images Redesigning the Row Layout Hiding the List Separators Chapter 8 - Displaying Alerts and Handling List View Selection Building a more Elegant Row Layout Managing Row Selections Using State Detecting Touches and Displaying an Action Sheet Understanding Binding
  • 8. Displaying an Alert Message Previewing the Row Layout Chapter 9 - Understanding Struct, Project Organization and Code Documentation Classes, Objects and Structures Creating a Restaurant Struct Using the Array of Restaurant Objects Organizing Your Xcode Project Files Documenting and Organizing Swift Code with MARK Chapter 10 - List Deletion, Swipe Actions, Context Menus and Activity Controller Performing Row Deletion Using Swipe Actions Creating Context Menu Understanding SF Symbols Working with Activity Controller Chapter 11 - Working with Navigation View Creating Navigation Views Adding the Restaurant Detail View Navigating from One View to Another Using Accent Color Customizing the Back Button Removing Disclosure Indicators Chapter 12 - Detail View Enhancement, Custom Fonts and Navigation Bar Customization 4 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 9. Using Custom Fonts Improving the Detail View Ignoring the Safe Area Previewing the Detail View inside a Navigation View Customizing the Navigation Bar Chapter 13 - Understanding Colors, Swift Extensions and Dynamic Type Working with Custom Colors Swift Extensions Adapting Colors for Dark Mode Dynamic Type Chapter 14 - Working with Maps Understanding Map View in SwiftUI Creating Our Own Map View Converting an Address into Coordinates Using Geocoder Adding Annotations to the Map Embedding MapView Displaying a Full Screen Map Chapter 15 - View Animations and Blur Effect Using Enumeration to Represent Ratings Implementing the Review View Applying a Visual Blur Effect Dismissing the Review View with Animations Animating the Rate Buttons with Slide-in Animation Chapter 16 - Working with Observable Objects and Combine The Problem with our Existing Design 5 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 10. Using Observable Object Displaying the Rating in Detail View Chapter 17 - Working with Forms and Camera Understanding Text Field in SwiftUI Building Generic Form Fields for User Input Implementing the Restaurant Form Working with Photo Library and Camera Adding Toolbar Buttons Chapter 18 - Working with Core Data What is Core Data? Using Core Data in SwiftUI Projects Creating the Managed Object Model Using @FetchRequest to Fetch Records Deleting a Record from Database Handling Empty List Views Updating a Managed Object Chapter 19 - Adding a Search Bar Using Searchable Using Searchable Adding a Search Bar to the Restaurant List View Search Bar Placement Performing Search and Displaying Search Results Chapter 20 - Building Walkthrough Screens Using TabView A Quick Look at the Walkthrough Screens Creating the Tutorial View Adding Next and Skip Buttons 6 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 11. Presenting the Tutorial View Working with UserDefaults Chapter 21 - Working with Tab View and Tab Bar Customizations Creating Tab Interface Using TabView Adjusting the Color of Tab Bar Items Adjusting the Color of Tab Bar Items Chapter 22 - Displaying Web Content with WKWebView and SFSafariViewController Designing the About View Opening Safari Using Link Using WKWebView Using SFSafariViewController Chapter 23 - Working with CloudKit Understanding CloudKit Framework Managing Records in CloudKit Dashboard Fetching Data from a Public Database Using Convenience API Fetching Data from Public Database Using Operational API Optimizing the Performance with Activity Indicator Pull to Refresh Saving Data Using CloudKit Chapter 24 - Localizing Your App to Support Multiple Languages Internationalizing Your App Export for Localization Import Localizations Testing the Localized App 7 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 12. Chapter 25 - Deploying and Testing Your App on a Real iOS Device Understanding Code Signing and Provisioning Profiles Automatic Signing in Xcode Deploying the App on Your Device via USB Deploying the App over Wi-Fi Chapter 26 - Beta Testing with TestFlight and CloudKit Production Deployment Creating an App Record on App Store Connect Archiving and Validating Your App Upload Your App to App Store Connect Manage Internal Testing Manage Beta Testing with External Users CloudKit Production Deployment Chapter 27 - Submit Your App to App Store Get Prepared and Well-Tested Submit Your App to App Store Chapter 28 - Adopting Haptic Touch Home Screen Quick Actions Handling Quick Actions Using Custom URL Scheme Chapter 29 - Working with User Notifications Using User Notifications to Increase Customer Engagement Using the User Notifications Framework Creating and Scheduling Notifications Interacting with User Notifications Appendix - Swift Basics 8 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 13. 9 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 14. Copyright ©2021 by AppCoda Limited All right reserved. No part of this book may be used or reproduced, stored or transmitted in any manner whatsoever without written permission from the publisher. Published by AppCoda Limited Published: 20/10/2021 | Last updated: 20/10/2021 | AppCoda © 2021 10 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 15. What People Say About This Book "This book got me an internship and a job. After one week of following this book’s tutorial, I was immediately able to begin developing my own app! 4 months later, I got an offer at Ancestry to intern as an iOS developer. Best money I ever spent!!" - Adriana, iOS developer at Ancestry "The Basic and Intermediate books are everything you need to understand all the concepts of design, coding, testing, and publishing an app. All you need is the idea." - Rich Gabrielli "I have published 8Cafe and 8Books, apps based on, and inspired by, the AppCoda Swift iOS book; it was a pleasure to learn and develop with your team. In fact, a lot of my apps/games utilise ideas and techniques from your excellent Beginner and Intermediate Swift books. To me, and a lot of developers, your talent, knowledge, expertise and willingness to share have been simply a godsend." - Mazen Kilani, creator of 8Cafe "I've been developing iOS apps for about a year now and am greatly indebted to the team at AppCoda. The Swift books I've purchased from them have dramatically increased my productivity and understanding of the entire Xcode and iOS development process. I've learned much more than I ever would have by scouring StackOverflow and github for hours and hours, which is what I had been doing prior to deciding to use AppCoda. All of the information is updated 11 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 16. and accurate, simple to read and follow, and the sample projects are fantastic. I really can't recommend these books highly enough. If you're trying to jump-start your Swift education, go for it." - David Gagne, creator of Bartender.live "AppCoda's books are fantastic. They are clearly written, assuming no knowledge, but still push you to think for yourself and internalize the concepts. No other resource is so comprehensive." - JP Sheehan, Ingot LLC "The book is well written, concise, with excellent example code and real-world examples. It's really helped me get my first App on the App store, and given me many ideas for further enhancements and updates. I also use it as a reference guide ongoing as well with the language, and the updates produced as Swift and iOS change are much gratefully received." - David Greenfield, creator of ThreadABead "Thanks for making such an awesome book! This book helped me develop my first real app and have made $200 on the app store in less than 2 months since launch. I was also able to get a software developer job where now I am running the Mobile department. Thanks again for the great book, I always try to promote it when people ask me about learning how to code." - Rody Davis, Developer of Pitch Pipe with Pitch Assistant "The book is really good. I was taking other courses of Swift from Udemy and the instructor did not have much background as a developer. In your case, I know you have a good background as a developer. By the way, you explain the things." - Carlos Aguilar, creator of Roomhints Interior Design Ideas 12 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 17. "For years, I'd been looking in vain for good quality resources to help sharpen my app development skills. Your books saved my life. They're the best explained programming books I've ever read in my 10 years of programming. They're so easy to understand and they hit everything. I will never thank you enough for writing the books and I owe you a lot." - Eric Mwangi "This book is clearly written with lots of examples. It is also great for experienced programmers new to Swift." - Howard Smith, Flickitt "Without this book, I couldn't become an iOS developer." - Changho Lee, SY Energy "I wanted to learn about iOS programming with Swift. For this, I turned to this book. It's an absolutely great way to learn Swift and iOS app development. If you have some programming background, you'll be able to do real stuff within a couple of days. But even if you do not, you'll still be able to learn to develop apps." - Leon Pillich "This book is the best book I have found on the Internet. It is very straightforward. I started my programming journey three years ago and currently, all my app achievement was due to this book." - Aziz, Engineer at Kuwait Concepts "Insightful, helpful, and motivational. The books are full of knowledge and depth of the subject, providing hints and tips on many aspects of iOS development, and encourages the student/reader to push forward and to not be afraid of seeking a deeper understanding of the concepts. Just awesome." - Moin Ahmad, Creator of Guess Animals 13 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 18. "This book taught me how to build the structure for the type of app I wanted to create. The lessons are well laid out, each one is just the right length to avoid overload. I would highly recommend this book as an excellent introduction to creating your first app and beyond." - Stephen Donnelly, Director at Rascalbiscuit "I tried multiple learning sources including the Stanford training. Although I already did learn some topics like auto layout, delegates, segues, etc through other sources, your book was the first one that really made me understand them!" - Nico van der Linden, SAP developer at Expertum "Over the past three years, I have purchased more than a dozen books on Objective C and Swift. As a high school AP computer science teacher I work mainly with Java but I also teach several other programming languages so I tend to keep a large library of books on-hand. While many of the other books and online video tutorials I purchased these past years were very good, I found AppCoda's to be far above all others. Simon has a way of presenting a topic in such a manner where I felt he was teaching me in a classroom environment rather than just me reading words on a screen. The best way to describe his writing style is to say it feels like he is speaking to you, not just giving you instructions." - Ricky Martin, Gulf Coast High School "This was one of the easiest books I have found to learn Swift. As a beginner, it was extremely easy to follow and understand. The real-life examples you include as your work through the book and build the app being taught is genius and makes it all worth it in the end. I was able to take many things away and apply to my own apps. I find myself referring back to it many times. Great Work." - Bill Harned, creator of Percent Off 14 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 19. "Best books on iOS development, well designed and easy to follow, and a great development journey companion." - Ali Akkawi, freelancer in mobile apps development for iOS and Android "I like the book. The contents are well structured. We have almost all of the latest concepts covered." - Barath V, Lead iOS developer at Robert Bosch LLC "I have purchased both the Beginning and Intermediate iOS 11 Programming with Swift books. I am a Java developer turned iOS mobile developer and these books really helped me learn the concepts of building a mobile application. The FoodPin application that you build in the Beginner book is an excellent way to learn all of the most common components of a mobile app. Even though I have now been working on iOS apps for over three years, I still regularly go back to the AppCoda swift books as a reference." - Stacy Chang "I probably could have done it without the book but it would've taken WAY longer and I probably wouldn't have understood what I was doing so well. If it weren't for this book my app probably won't be in the App Store right now. True story. Keep it up!" - Marc Estwick 15 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 20. Preface A couple years ago, people still asked, "Is Swift ready for app development?" Now everyone knows Swift is the programming language to learn for developing iOS apps. I really love this programming language, not because I teach Swift programming for a living and want you to buy my courses/books. I have been programming for over 15 years in various programming languages. Swift is my favorite language right now. This new programming language is well designed with a simplified and clean syntax. Swift is easier to learn and makes me more productive in iOS app development, as compared to the good old Objective-C. Swift was first introduced by Apple in June 2014 and has gone through several updates. Fast forward to today, the company already released version 5.5 of the programming language along with Xcode 13 with more features. With over 7 years of development since its first release, Swift is no longer a brand new programming language. The language is now solidified, mature and ready for any application development on iOS, macOS, watchOS, as well as, tvOS. Companies like Lyft, LinkedIn, and Mozilla have been developing their apps in Swift. Whether you are planning to develop your next iOS app or you want to build a career in iOS app development, Swift is for sure the programming language to learn and use. This book covers everything you need to learn for iOS app development. Remember, Swift is just a programming language. To develop an iOS app, you need to learn far more than that. On top of the introduction to Swift, this book will teach you how to lay out the user interface using SwiftUI and master the essential APIs of the iOS SDK. Most importantly, you will acquire the Swift programming skill by developing a real-world app from the ground up. 16 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 21. As an absolute beginner with no prior programming background, you may question if you could learn Swift programming and build a real iOS app. I have been programming in Swift since it was first announced. Swift is more approachable and it is a lot easier for newbies to learn than Objective-C. Not everyone can become a great developer, but I believe everyone can learn programming and develop an app in Swift. All you need is hard work, determination, and the willingness to take actions. I launched AppCoda about 9 years ago and started to publish iOS programming tutorials on a weekly basis. Since then, I have published several books on iOS app development. At first, I thought people, who want to learn app development, are those with programming experience and technical background. What's interesting is that people from different backgrounds are passionate to build their own apps. I have a reader from France, who is a surgeon by profession, started from zero programming experience to launching his first app, which allows anyone to share and advertise event information for free. Another reader is a pilot by profession. He began to learn iOS programming a couple years ago and is now building iPhone apps for his own use and other pilots. Boozy is an app for finding Happy Hours, Daily Deals and Brunches. It was built by a law school dropout. The creator of the app could not find a good place for a drink in DC area. So she decided to make an app to meet a real need. Similarly, she did not know coding when she came up with the idea. She just got started and learned along the way. From time to time, I got emails from people who want to create an app. The emails usually mention something like this: "I have an app idea. Where do I begin? But I have no programming skills. Can I learn from scratch to make one?" What I learned from these truly inspiring stories is that you don't need to have a degree in Computer Science or Engineering in order to build an app. These readers have one thing in common. They are committed to taking actions. They all put their hard work in to make things happen. This is what you need. 17 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 22. So you've got an idea to build an app? I believe you can make one on your own. Remember there is nothing to deter you from learning and get things done if you're really passionate about it. Let me borrow one of my favorite quotes from Last Lecture to conclude: Brick walls are there for a reason: they let us prove how badly we want things. - Randy Pausch Lastly, thanks for picking up the book. I hope you will enjoy reading it and launch your first iOS app on App Store. If you'd like to share the story of your first app, drop me an email at simonng@appcoda.com. I would love to hear from you. Simon Ng Founder of AppCoda 18 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 23. What You Will Learn in This Book I know many readers have an app idea but don't know where to begin. Hence, this new book is written with this in mind. It covers the whole aspect of Swift programming and you will learn how to build a real-world app from scratch. You'll first learn the basics of Swift and SwiftUI. Then you'll start to prototype a real world app and build it from scratch. Each chapter you'll learn how to use the iOS APIs to build some features. After going through the whole book, you'll have a real app. During the process, you will learn how to exhibit data in list views, design UI using Stack Views, create animations, work on maps, build an adaptive UI, save data in local database, upload data to iCloud, use TestFlight to arrange beta test, etc. This new book features a lot of hands-on exercises and projects. You will get the opportunities to write code, fix bugs and test your app. Although it involves a lot of work, it will be a rewarding experience. I believe it will allow you to master Swift 5.5, Xcode 15, and iOS 15 programming. Most importantly, you will be able to develop an app and release it on App Store. Audience This book is written for beginners without any prior programming experience and those who want to learn Swift programming. Whether you are a programmer who wants to learn a new programming language or a designer who wants to turn your design into an iOS app or an entrepreneur who wants to learn to code, this book is written for you. I just assume you are comfortable using macOS and iOS as a user. SwiftUI vs UIKit 19 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 24. The debut of SwiftUI was huge, really huge for existing iOS developers or people who are going to learn iOS app building. It was unarguably the biggest change in iOS app development in recent years. That said, beginners may be confused with these two UI frameworks. Which one should you learn or start with? You should ask yourself why you want to learn iOS programming. What's your goal? Do you want to become a professional iOS developer and get hired? Or you just want to learn something new as a hobby? If you want to become a professional iOS developer and look for a job, you should learn both frameworks. Most of the apps on the App Store are developed using UIKit. It is very likely you will work on an app built with UIKit if you are employed. So, you can start with UIKit, followed by SwiftUI. On the other hand, if you take up programming as a hobby or just create an app as a side project, I suggest you to jump right into SwiftUI. This book comes with two editions: UIKit and SwiftUI. Both editions will teach you how to build the same real world app but with different UI frameworks. If your plan is to start with SwiftUI, you can continue to read chapter 1. Otherwise, pick up the UIKit edition of the book. 20 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 25. Chapter 1 The Development Tools, the Learning Approach, and the App Idea Since you pick up this book, I guess you want to create an iOS app. Creating an app is a fun and rewarding experience. I still remembered the joy when I first created an app years ago, even though the app is just so simple and elementary. iOS, the mobile operating system behind iPhone and iPad, has been released for more than 10 years. The tools, the programming language and its frameworks have greatly evolved over these years. Therefore, before we dive into iOS programming, let's go through the tools you need to build an app and get prepared the mindset for learning iOS app development. 21 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 26. The Tools Apple has favored a closed ecosystem over the open system. iOS can be only run on Apple's own devices including iPhone and iPad. It is very much unlike its competitor, Google, that Android is allowed to run on mobile devices from different manufacturers. As an aspiring iOS developer, what this means to you is that you will need a Mac for app development. 1. Get a Mac Having a Mac is the basic requirement for iOS development. To develop an iPhone (or iPad) app, you need to get a Mac with an Intel-based processor running on macOS version 11 (or later). If you now own a PC, the cheapest option is to purchase the Mac Mini. As of this writing, the retail price of the entry model is US$899. You can hook it up to the monitor of your PC. I would recommend you to pick the basic model of Mac mini with Apple M1 chip. It should be good enough to run the iOS development tools smoothly. Of course, if you have a bigger budget, get the higher model or an iMac with better processing power. 2. Register Your Apple ID You will need an Apple ID to download Xcode, access iOS SDK documentation, and other technical resources. Most importantly, it will allow you to deploy your app to a real iPhone/iPad for testing. If you have downloaded an app from the App Store, it is quite sure that you already own an Apple ID. In case you haven't created your Apple ID before, you have to get one. Simply go to Apple's website (https://appleid.apple.com/account) and follow the procedures for registration. 3. Install Xcode 22 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 27. To start developing iOS apps, Xcode is the only tool you need to download. Xcode is an integrated development environment (IDE) provided by Apple. Xcode provides everything you need to kick start your app development. It already bundles the latest version of the iOS SDK (short for Software Development Kit), a built-in source code editor, graphic user interface (UI) editor, debugging tools and much more. Most importantly, Xcode comes with an iPhone (and iPad) simulator so you can test your app without the real devices. To install Xcode, go up to the Mac App Store and download it. If you're using the latest version of Mac OS, you should be able to open the Mac App Store by clicking the icon in the dock. In case you can't find it, you may need to upgrade your Mac OS. Figure 1-1. App Store icon in the dock In the Mac App Store, simply search "Xcode" and click the "Get" button to download it. 23 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 28. Figure 1-2. Download Xcode on App Store Once you complete the installation process, you will find Xcode in the Launchpad. 24 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 29. Figure 1-3. Xcode icon in the Launchpad At the time of this writing, the latest version of Xcode is 13. Throughout this book, we will use this version of Xcode to create the demo apps. Even if you have installed Xcode before, I suggest you upgrade to the latest version. This should make it easier for you to follow the tutorials. 4. Enroll in the Apple Developer Program (Optional) A common question about developing an iOS app is whether you need to enroll in the Apple Developer Program (https://developer.apple.com/programs/). The short answer is optional. First, Xcode already includes a built-in iPhone and iPad simulator. You can develop and test out your app on Mac, without enrolling in the program. 25 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 30. Starting from Xcode 7, Apple has changed its policy regarding permissions required to build and run apps on devices. Before that, the company required you to pay US$99 per year in order to deploy and run your apps on a physical iPhone or iPad. Now, program membership is no longer required. Everyone can test their apps on a real device without enrolling in the Apple Developer Program. Having said that, if you want to try out some advanced features such as in-app purchase, push notifications or CloudKit, you still need to apply for the program membership. Most importantly, you're not able to submit your app to App Store without paying the annual membership fee. So, should you enroll in the program now? The Apple Developer Program costs US$99 per year. It's not big money but it's not cheap either. Since you're reading this book, you're probably a newcomer and just start exploring iOS development. The book is written for beginners. We will first start with something simple. You are not going to tap into the advanced features until you grasp the basic skills. Therefore, even if you do not enroll into the program, you will still be able to follow most of the content to build an app and test it on your device. For now, save your money. I will let you know when you need to enroll in the program. At that time, you're encouraged to join the program as you're ready to publish the app to the App Store! 26 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 31. The Learning Approach I have been teaching iOS programming from 2012 through blogging, online courses, and in-person workshops. What I found is that it is the learning approach and the mindset that make the difference between failing and achieving. Before we talk about Swift and iOS programming, I want to get you equip with the right mindset and understand the most effective way to learn programming. Get Your Hands Dirty One of the most popular questions about learning how to code is: What's the best way to learn iOS programming? First, thanks for reading this book. Unfortunately, I have to tell you that you cannot learn programming just by reading books. This book has everything you need to learn Xcode, Swift, and iOS app development. But the most important part is taking action. If I have to provide an answer to the question, I will say "Learn by Doing". It is at the heart of my teaching approach. Let me change the question a little bit: What's the best way to learn English (or other foreign languages)? What's the best way to learn cycling (or any other sports)? You probably know the answer. I especially like this answer on Quora about learning a new language: 27 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 32. Follow this routine: listen 1 hour a day, speak 1 hour a day, publish 1 journal entry. - Dario Mars Patible You learn through practice, not by just studying grammar. Learning programming is somewhat very similar to learning a language. You need to take actions. You have to work on a project or some exercises. You have to sit in front of your Mac, immerse yourself in Xcode, and write the Swift code. It doesn't matter how many mistakes you make during the process. Just remember to open Xcode and code while reading this book. Motivations Why do you want to learn app development? What motivates you to sacrifice the weekends and holidays to learn how to code? Some people begin learning app development just because of money. There is nothing wrong with that. You may want to build your app business to earn some side income and eventually turn it into a full-time business. That's completely understandable. Who doesn't want to live a rich life? As of February 2019, however, there were over 2.2 million apps on the App Store. It is really hard to put up an app on the App Store and expect to make a load of money overnight. You'll be easily discouraged or even give up if money is your primary reason for building apps, especially when you come across articles like this: How Much Money I Made on the App Store (https://sitesforprofit.com/how- much-money-app-store) 28 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 33. Then reality set in. 199 units old = US$209 in sales = US$135 proceeds (net to me). In order to get the app on the app store I needed to pay the $99 developer fee. So after 2 months and 1 week my (before tax) profit was $36. - James Programming is hard and challenging. I find people who successfully master the language are those who have a strong desire to build apps and are enthusiastic to learn programming. They usually have an idea in their mind and want to turn it into a real app. Making money is not their number one concern. They know the app can solve their own problems and will be beneficial to others. With such a powerful purpose in mind, they can overcome any obstacles come up. So, think again why you want to learn programming. Find a Buddy "The best way to learn is to teach" is an old saying. It still works in the modern world, however. You don't need to be an expert to teach. I'm not talking about giving a lecture at a university or teaching a bunch of students in a formal class. Teaching does not always happen that way. It can be as simple as sharing your knowledge with a colleague or a classmate sitting next to you. Try to find someone who is also interested in learning iOS programming. When you learn something new, try to explain the materials to your buddy. For example, after building your first app, teach your close friend how it works and how he/she can create an app too. What if you can't find a buddy to share what you've learned? No worries. Start a blog on medium.com (or whatever platforms you like), write a blog post every day, and document everything you learn. 29 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 34. This is one of the most effective ways of learning as I learn so much while publishing tutorials on appcoda.com, as well as, developing my first book. Sometimes you think you know the materials well. But once you need to explain the concept to someone else and answer questions, chances are that you didn't understand the material thoroughly. This will motivate you to study the materials even harder. Give this method a shot while you learn iOS programming. Be Patient Grit is passion and perseverance for very long-term goals. Grit is having stamina. Grit is sticking with your future, day-in, day-out. Not just for the week, not just for the month, but for years. And working really hard to make that future a reality. Grit is living life like it’s a marathon, not a sprint. - Dr. Angela Lee Duckworth Some of my students asked, "How long would it take to become a good developer?" It takes time to master programming and become a great developer. It usually takes years. Not weeks, not months but years. This book will help you kick start the journey. You will learn all the basics of Swift and iOS programming and eventually, build an app. That said, it takes time and lots of practices to become a professional programmer. Be patient. Don't set your expectations too high for your first app. Just enjoy the process, create something simple and fun. Keep reading and coding daily. You will eventually master the skill. Find Your App Idea 30 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 35. I always encourage my students to come up with their own app idea when start learning app development. The idea doesn't have to be big. You do not need to build the next Uber app or come up with a new idea to change the world. You just need to start with a very small idea that solves a problem. Let me give you a couple of the examples. One classic example that I used to mention is Cockpit Dictionary. It is an app built by Manolo Suarez, who is a pilot by profession. He had an app idea while learning app programming. The idea was not fancy but solved his own problem. There are tens of thousands of Aviation terms in abbreviated form. Even for an experienced pilot with over 20 years of aviation experience, it is impossible to remember all the acronyms and technical terms. Instead of using a print dictionary, he thought of building a handy app for pilots to look up all kinds of Aviation terms. A simple, yet a great idea to solve his own problem. 31 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 36. Figure 1-4. Cockpit Dictionary Another example is the NOAA Buoy Data app. While this app is no longer available on the App Store, I still want to quote it as an example. The app was designed to retrieve the latest weather, wind, and wave data from the National Oceanic and Atmospheric Administration’s (NOAA) National Data Buoy Center (NDBC). Developed by Leo Kin, he came up with the app idea during his recovery from surgery. 32 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 37. "After the surgery, I had to wear a neck brace for three months. During those three months, I couldn’t move a lot and even had a hard time walking or even raising my arms. My physical therapist advised that I go walking as much as I can to get exercise and to build back my atrophied leg muscles. There is an island close to where I was living that I really enjoyed walking to. The only problem was that it can only be reached during low tide. And if the tide came in, there’s no way to get back home except by swimming. Since I was very physically weakened, I was very scared of getting stuck on the island with no way back. While walking, I was always going to NOAA’s website to check how high or low the tide was and if I had enough time to walk to the island and back. During one of my walks, the idea came to me that I should build an app. Even if no one else uses the app, it wouldn’t matter because it would help me keep track of the tides and get back in time." - Leo Kin His app may not interest you, but it was solving a problem he faced at the time. Probably people on that island would benefit from his app too. 33 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 38. Figure 1-5. NOAA Buoy Data app Having your own app idea will give you a clear goal and motivate you to keep learning. Now spare some time and write down three app ideas below: 1. 2. 3. 34 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 39. UIKit vs SwiftUI Which UI framework should you learn? As a beginner, you may have heard of these two terms: UIKit and SwiftUI. Some people said you should learn UIKit to build apps but some said you could ignore UIKit and dive right into SwiftUI because it's Apple's brand new UI framework. I guess you may be confused with these technical terms. Let me give you a quick overview to both, so you know which one you should focus on. Figure 1-6. Building apps using UIKit and Interface Builder First, both frameworks allow you to build great apps. The UIKit framework is the original UI framework available since the first release of iOS. With UIKit, you can write code to build the mobile app UI or create app layouts using Xcode's Interface 35 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 40. Builder. One of the downsides, however, is that the framework is more complicated to learn as compared to SwiftUI. Figure 1-7. Building apps using SwiftUI With SwiftUI, you can develop the app's UI with a declarative Swift syntax. What that means to you is that the UI code is easier and more natural to write. Compared with the existing UI frameworks like UIKit, you can create the same UI with way less code. The preview function has always been a weak point of Xcode. While you can preview simple layouts in Interface Builder (or Storyboard), you usually can't preview the complete UI until the app is loaded onto the simulators. With SwiftUI, Xcode gives you immediate feedback of the UI you are coding. For example, you add a new record to a table, Xcode renders the UI change on the fly in a preview 36 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 41. canvas. If you want to preview how your UI looks in dark mode, you just need to change an option. This instant preview feature simply makes UI development a breeze and iteration much faster. Not only does it allow you to preview the UI, the new canvas also lets you design the user interface visually using drag and drop. What's great is that Xcode automatically generates the SwiftUI code as you add the UI component visually. The code and the UI are always in sync. This is a feature Apple developers anticipated for a long time. Now it comes to the core question. As a beginner, which framework should you learn? You should ask yourself why you want to learn iOS programming. What's your goal? Do you want to become a professional iOS developer and get hired? Or you just want to learn something new as a hobby? If you want to develop a career in iOS development, my short answer is to learn both frameworks. But it's better to begin with UIKit because many companies are still developing apps using UIKit. It's an essential skill to help you get hired. This is why I recommend you to get familiar with UIKit, followed by SwiftUI. On the other hand, if you take up programming as a hobby or create an app as a side project, I suggest you to jump right into SwiftUI. It is easier to learn and lets you build apps using less code. From time to time, you may still need to use some UI components from UIKit. When that time comes, you can learn how to use that specific UIKit components. So, focus on SwiftUI first and then UIKit. Summary That's all for the introduction. Take some time to install Xcode on your Mac, come up with your own app idea, and pick the framework you want to focus on. We have both UIKit and SwiftUI books to help you learn the required skills for building 37 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 42. your own apps. If SwiftUI is your focus, proceed to the next chapter and we will start programming in Swift. So get ready! 38 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 43. Chapter 2 Your First Taste of Swift with Playgrounds Now that you have configured everything you need to start iOS app development, let me answer another common question from beginners before moving on. A lot of people have asked me about what skills you need in order to develop an iOS app. In brief, it comes down to three areas: Learn Swift - Swift is now the recommended programming language for writing iOS apps. Learn Xcode - Xcode is the development tool for you to design the app UI, write Swift code, and build your apps. Understand the iOS software development kit - Apple provides the 39 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 44. software development kit for developers to make our lives simpler. This kit comes with a set of software tools and APIs that empowers you to develop iOS apps. For example, the SwiftUI framework which will discuss in the next chapter is one of the essential frameworks you need to learn for building user interface and animations. If you want to display a web page in your app, the SDK also provides a built-in browser that lets you embed right in your application. You will have to equip yourself with knowledge on the above three areas. That's a lot of stuff. But no worries. You'll learn the skills as you read through the book. The Swift History Let me start off by telling you a bit about the history of Swift. In the Worldwide Developer Conference 2014, Apple surprised all iOS developers by launching a new programming language called Swift. Swift is advertised as a "fast, modern, safe, interactive" programming language. The language is easier to learn and comes with features to make programming more productive. Prior to the announcement of Swift, iOS apps were primarily written in Objective- C. The language has been around for more than 20 years and was chosen by Apple as the primary programming language for Mac and iOS development. I've talked to many aspiring iOS developers. A majority of them said Objective-C was hard to learn and its syntax looked weird. Simply put, the code scares some beginners off from learning iOS programming. The release of Swift programming language is probably Apple's answer to some of these comments. The syntax is much cleaner and easier to read. I have been programming in Swift since its beta release. It's more than 4 years for now. I can 40 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 45. say you're almost guaranteed to be more productive using Swift. It definitely speeds up the development process. Once you get used to Swift programming, it would be really hard for you to switch back to Objective-C. It seems to me that Swift will lure more web developers or even novice to build apps. If you're a web developer with some programming experience on any scripting languages, you can leverage your existing expertise to gain knowledge on developing iOS apps. It would be fairly easy for you to pick up Swift. Being that said, even if you're a total beginner with no prior programming experience, you'll also find the language friendlier and feel more comfortable to develop apps in Swift. In June 2015, Apple announced Swift 2, and that the programming language goes open source. This is a huge deal. Since then, developers created some interesting and amazing open source projects using the language. Not only can you use Swift to develop iOS apps, companies like IBM developed web frameworks for you to create web apps in Swift. Now you can run Swift on Linux too. Following the release of Swift 2, Apple introduced Swift 3 in June 2016. This version of the programming language, integrated into Xcode 8, was released in Sep, 2016. This was considered as one of the biggest releases since the birth of the language. There were tons of changes in Swift 3. APIs are renamed and more features were introduced. All these changes helped to make the language even better and enabled developers to write more beautiful code. That said, it took all developers extra efforts to migrate their projects for these breaking changes. In June 2017, Apple brought you Swift 4, along with the release of Xcode 9, with even more enhancements and improvements. This version of Swift had a focus on backward compatibility. That meant ideally projects developed in Swift 3 could be run on Xcode 9 without any changes. Even if you had to make changes, the migration from Swift 3 to 4 would be much less cumbersome than that from 2.2 to 3. 41 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 46. In the following year, Apple only released a minor update for Swift, pushing Swift's version number to 4.2. Even though it's not a major release, the new version also came with a lot of language features to improve productivity and efficiency. In late March 2019, Apple officially released Swift 5, which is a major milestone of the programming language. While it includes many new features, the most important change is that the Swift runtime is now included in Apple’s platform operating systems including iOS, macOS, watchOS, and tvOS. Actually, it's a good news for aspiring developers. This means the Swift language is more stable and mature. Everything you learn in this book will apply to the future release of Swift. This year, the Swift language is further updated to Swift 5.5 with even more features. The async/await functions introduced in this release makes asynchronous programming much simpler. If you're a total beginner, you may have a couple of questions in mind. Why does Swift keep changing? If it keeps updating, is Swift ready for use? Nearly all programming languages change over time. The same is for Swift. New language features are added to Swift every year to make it more powerful and developer friendly. It is somewhat similar to our spoken languages. Let's say, for English, it still changes over time. New vocabulary and phrases such as freemium are added to the dictionary every year. All languages change over time, and there can be many different reasons for this. The English language is no different. Source: https://www.english.com/blog/english-language-has-changed While Swift keeps evolving, it doesn't mean it is not ready for production use. Instead, if you are going to build an iOS app, you should build it in Swift. It has become a de facto standard for iOS app development. Companies such as 42 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 47. LinkedIn, Duolingo and Mozilla had already written apps entirely in Swift since its early versions. Since the release of Swift 4, the programming language is more stable and definitely ready for enterprises and production uses. Let's Get Started Enough for the background and history. Let's begin to look into Swift. To get a taste of Swift programming language, let's take a look at the following code snippets. Objective-C const int count = 10; double price = 23.55; NSString *firstMessage = @"Swift is awesome. "; NSString *secondMessage = @"What do you think?"; NSString *message = [NSString stringWithFormat:@"%@%@", firstMessage, seco ndMessage]; NSLog(@"%@", message); Swift let count = 10 var price = 23.55 let firstMessage = "Swift is awesome. " let secondMessage = "What do you think?" var message = firstMessage + secondMessage print(message) 43 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 48. The first block of code was written in Objective-C, while the second one was written in Swift. Which language do you prefer? I guess you would prefer to program in Swift, especially if you're frustrated with the Objective-C syntax. It's clearer and readable. There is no @ sign and semi-colon at the end of each statement. Both statements below concatenate the first and second messages together. I believe you can probably guess the meaning of the following Swift code: var message = firstMessage + secondMessage but find it a bit confusing for the Objective-C code below: NSString *message = [NSString stringWithFormat:@"%@%@", firstMessage, seco ndMessage]; Trying out Swift in Playgrounds I don't want to bore you by just showing you the code. There is no better way to explore coding than actually writing code. Xcode has a built-in feature called Playgrounds. It's an interactive development environment for developers to experiment Swift programming and allows you to see the result of your code in real-time. You will understand what I mean and how Swift Playgrounds works in a while. Assuming you've installed Xcode 13 (or up), launch the application (by clicking the Xcode icon in Launchpad). You should see a startup dialog. 44 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 49. Figure 2-1. The startup dialog A Playground is a special type of Xcode file. In the top menu, click File > New > Playground... to create a new Playground file. You'll then be prompted to select a template for your playground. Since we focus on exploring Swift in iOS environment, choose Blank under the iOS section to create a blank file. Click Next to continue. 45 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 50. Figure 2-2. Creating a Playground file Once you confirm to save the file, Xcode opens the Playground interface. Your screen should like this: 46 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 51. ​ On the left pane of the screen, it is the editor area where you type the code. When you want to test your code and see how it works, hit the Play button. Playground immediately interprets the code (up to the line of the Play button) and displays the result on the right pane. By default, Swift Playgrounds includes two lines of code. As you can see, the result of the str variable appears immediately on the right pane after you hit the Play button at line 4. We'll write some code in Playgrounds together. Remember the purpose of this exercise is to let you experience Swift programming and learn its basics. I will not cover every feature of Swift. We will only focus on these topics: 1. Constants, variables and type inference 2. Control flow 3. Collection types like arrays and dictionaries 4. Optionals These are the basic topics that you need to know about Swift. You will learn by example. However, I'm quite sure you will be confused by some of the programming concepts, especially you are completely new to programming. No 47 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 52. worries. You will find my study advice in some sections. Just follow my advice and keep studying. And, don't forget to take a break when you're stuck. Cool! Let's get started. Constants and Variables Constants and variables are two basic elements in programming. The concept of variables (and constants) is similar to what you learned in Mathematics. Take a look at the equation below: x = y + 10 Here, both x and y are variables. 10 is a constant, meaning that its value is unchanged. In Swift, you declare variables with the var keyword and constants using the let keyword. If you write the above equation in code, here is what it looks like: let constant = 10 var y = 10 var x = y + constant Type the code above in Playgrounds and then hit Play at line 5. You will see the result below. 48 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 53. Figure 2-4. The result of the equation You can choose whatever name for variables and constants. Just make sure they are meaningful. For example, you can rewrite the same piece of code like this: let constant = 10 var number = 10 var result = number + constant To make sure that you clearly understand the difference between constants and variables in Swift, type the following code to change the values of constant and number : constant = 20 number = 50 After that, press shift+command+enter to execute the code. Other than using the Play button, you can use the shortcut keys to run the code. You simply set a new value for the constant and variable. But as soon as you change the value of the constant, Xcode gives you an error in the console. Conversely, there is no issue for number . 49 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 54. Figure 2-5. Errors in Playgrounds This is the core difference between constants and variables in Swift. Once a constant is initialized with a value, you can't change it. If you have to change the value after initialization, use variables. Understanding Type Inference Swift provides developers with a lot of features to write clean-looking code. One feature is known as Type Inference. The same code snippet we just discussed above can be explicitly written as follows: let constant: Int = 10 var number: Int = 10 var result: Int = number + constant Each variable in Swift has a type. The keyword Int after colon ( : ) indicates the type of the variable/constant is an integer. If the value stored is a decimal number, we use the type Double . var number: Double = 10.5 50 Beginning iOS Programming with Swift and SwiftUI (iOS 15) | APPCODA
  • 55. Another Random Scribd Document with Unrelated Content
  • 56. Confederate general; C. A. Battle (Democrat), Confederate general; A. Tyson (Whig). See Brewer and Garrett, and N. Y. Times, Aug. 3 and 9, 1866. [1066] McPherson, pp. 240, 241. [1067] N. Y. Times, Aug. 27, 1866. By “Union” party, Parsons evidently meant those who opposed secession. [1068] The northern business men were on the side of the whites. [1069] McPherson, p. 124. [1070] McPherson, p. 242. [1071] N. Y. Times, Sept. 8, 1866. [1072] Davis was of good middle-class Virginia stock. A Whig in politics, Mrs. Chesnut called him “a social curiosity.” In convention of 1861 he voted against immediate secession, threatened resistance among the hills of north Alabama, and ended by signing the ordinance of secession; was chosen to succeed Dr. Fearn in the Confederate Provisional Congress; was appointed lieutenant-colonel of the 19th Alabama Infantry, but declined; commanded a battalion for a while; his “loyalty” consisted in his leaving the Confederate service and returning to Huntsville within the Federal lines. Brewer, p. 365, Garrett, pp. 341, 342; Smith’s Debates, passim. He soon fell out with the carpet-baggers and “formed a party of one.” [1073] The disposition of some of the north Alabama leaders (even among the Conservatives) to play the childish act was one of the disgusting features of Reconstruction. [1074] N. Y. Times, Jan. 23, 1867. Among those present were: D. C. Humphreys (Douglas Democrat), Confederate officer, who deserted to Federals (he was in the first carpet-bag legislature, and later judge of the Supreme Court of the District of Columbia; see Garrett, p. 364); John B. Callis, agent of the Freedmen’s Bureau, Veteran Reserve Corps, member of Congress, 1868; C. C. Sheets, in
  • 57. convention of 1861, refused to sign ordinance of secession and deserted to Federals, a member of Congress, 1868; Thomas M. Peters, Whig, deserted to Federals, later judge of Supreme Court of Alabama (see Brewer, p. 309; Garrett, p. 440); F. W. Sykes, member of legislature during war, soon returned to Conservative party (Brewer, p. 309); J. J. Hinds, afterward a notorious scalawag. [1075] One new man was S. C. Posey of Lauderdale, who had been in the convention of 1861 and refused to sign the ordinance of secession and was in the legislature during the war. Returned soon to Conservative party. Brewer, p. 299, Garrett, p. 389. [1076] The Radical party might have done much worse than to send him to the Senate. Warren and Spencer, the senators elected, were far inferior in character and abilities to Swayne. He was too decent a man to suit the Radicals and was soon dropped. [1077] N. Y. Herald, March 6, 1867. [1078] The proclamation announcing that the rebellion had ended was issued April 2, 1866. McPherson, p. 15. [1079] Van Horne, Life of Thomas, pp. 153, 399, 400, 408; Huntsville Advocate, June 9, 1866 (for copy of order relating to Department of the South that I have not found elsewhere); G. O. No. 1, Mil. Div. Tenn., June 20, 1865; G. O. No. 118, W. Dept., June 27, 1865; G. O. No. 1, Dept. Ala., July 18, 1865; G. O. No. 1, Dist. Ala., June 4, 1866; G. O. No. 1, Dept. Tenn., Aug. 13, 1866; G. O. No. 42, Dept. Tenn., Nov. 1, 1866. The general and special orders cited in this chapter are on file in the War Department at Washington. [1080] O. R., Ser. I, Vol. XLIX, Pt. II, pp. 505, 560, 727, 826, 854, 971; Report of the Joint Committee on Reconstruction, Pt. III. [1081] Miller, “Alabama,” p. 236; Acts of Ala. (1865-1866), pp. 598, 601.
  • 58. [1082] That is, the officers had the privileges and authority of officers of a division. G. O. Nos. 1, 9, 17, 29, 54, Dept. Ala., 1865; G. O. No. 1, Mil. Div. Tenn., 1865. [1083] The “Amnesty Oath.” The oath of allegiance had already been administered to all who would take it. See McPherson, “Reconstruction,” pp. 9, 10. [1084] G. O. Nos. 13 and 14, Dept. Ala., 1865. [1085] G. O. No. 3, Dept. Ala., July 21, 1865. There was complaint about the stealing of cotton by troops. [1086] G. O. No. 6, Post of Montgomery, May 15, 1865. This order is printed on thin, blue Confederate writing paper, which seems to have been shaped with scissors to the proper size. Supplies had not followed the army. [1087] G. O. No. 24, Dept. of Ala., Aug. 25, 1865. [1088] G. O. No. 6, Post of Mobile, in N. Y. Daily News, June 27, 1865. [1089] G. O. No. 48, Dept. Ala., Oct. 18, 1865. [1090] Statement of General Woods, Sept. 4, 1865, Document No. 11, accompanying the Report of Schurz. [1091] See statement of Woods, Sept. 4, 1865, Schurz’s Report. [1092] G. O. No. 4, Dept. Ala., Jan. 26, 1866. [1093] N. Y. Daily News, Sept. 7, 1865. [1094] Statement of Gen. T. K. Smith, Sept. 14, 1865, in Schurz’s Report. [1095] Statement of General Woods, Sept. 4, 1865. [1096] G. O. No. 5, Sub-dist. Ala., Oct. 13, 1866.
  • 59. [1097] See Ch. VI, sec. 1. [1098] G. O. No. 30, Dept. of Ala., Sept. 4, 1865; Statement of General Woods, Sept. 4, 1865, in Schurz’s Report. [1099] See Ch. VI, sec. 1. [1100] N. Y. Herald, Nov. 26 and Dec. 15, 1865. [1101] Document No. 19, accompanying Schurz’s Report. [1102] G. O. No. 55, Dept. Ala., Oct. 30, 1865. [1103] G. O. No. 8, Dept. Ala., Feb. 17, 1866. [1104] G. O. No. 1, Dept. Ala., Jan. 5, 1866. [1105] G. O. No. 13, Dept. Ala., 1866. [1106] G. O. No. 17, Dept. Ala., 1866. [1107] G. O. No. 20, Dept. Ala., 1866. [1108] G. O. No. 23, Dept. Ala., 1866. There were other trials, but the records are missing and the names of the parties are unknown. A large number of cases were prosecuted before military commissions convened at the instance of the Freedmen’s Bureau. [1109] For two years after the war the Confederate sympathizers in north Alabama suffered from persecution of this kind. During the war the Confederates in north Alabama had been classed as guerillas by the Federal commanders. [1110] G. O. No. 29, Mil. Div. Tenn., Sept. 21, 1865; G. O. No. 42, Dept. Ala., Sept. 26, 1865. [1111] G. O. No. 3, H. Q. A., Jan. 12, 1866; G. O. No. 7, Dept. Ala., Feb. 12, 1866. [1112] G. O. No. 48, Dept. Ala., Oct. 18, 1865.
  • 60. [1113] G. O. No. 6, Mil. Div. Tenn., Feb. 21, 1866. [1114] G. O. No. 25, Mil. Div. Tenn., Sept. 13, 1865. [1115] G. O. No. 44, H. Q. A., July 6, 1866; G. O. No. 13, Dept. of the South, July 21, 1866. [1116] Sen. Ex. Doc., No. 26, 39th Cong., 1st Sess. [1117] P. M. Dox to Governor Parsons, Sen. Ex. Doc., No. 26, 39th Cong., 1st Sess. [1118] See p. 327. [1119] Selma Times, Feb. 3, 1866. [1120] There were really three governments in Alabama based on the war powers of the President: (1) the army ruling through its commanders; (2) the Freedmen’s Bureau, with its agents; (3) the provisional civil government. [1121] Circular No. 1, Aug. —, 1865; G. O. No. 21, Dept. Ala., April 9, 1866. [1122] De Bow’s Review, 1866. De Bow made a trip through the South. Nation, Oct. 5 and 26, 1865; Truman, Report to President, April 9, 1866. See also Grant, Letter to President, Dec. 18, 1865. [1123] Colonel Herbert says that the relations between the soldiers and the ex-Confederates were very kindly, but the latter hoped the army would soon be removed, when civil government was established. “Solid South,” p. 30. [1124] Miller, “Alabama,” p. 242; Resolutions of the Legislature, Jan. 16, 1866. [1125] Testimony of Swayne, Report Joint Committee, 1866, Pt. III, p. 139; various reports of Swayne as assistant commissioner of Freedmen’s Bureau. It was noticeable that when Swayne was placed
  • 61. in command of the army in the state there was less interference and better order than before, though he never obtained the cavalry. [1126] For instance: In the city of Mobile a petition of some kind might be made out in proper form and given to the commander of the Post of Mobile. The latter would indorse it with his approval or disapproval, and send it to the commander of the District of Mobile, who likewise forwarded it with his indorsement to the commander of the Department of Alabama at Mobile or Montgomery. In important cases the paper had to go on until it reached headquarters in Macon, Nashville, Louisville, Atlanta, or Washington, and it had to return the same way. The following orders relate to the changes made so often:— G. O. Nos. 1, 9, 10, 12, 17, 19, 20, 27, Dept. Ala., from July 18 to Sept. 1, 1865; G. O. No. 18, Dept. Ala., March 30, 1866; G. O. No. 1, Dist. Ala., June 1, 1866; G. O. No. 1, Sub-dist. Ala., Oct. —, 1866; G. O. No. 1, Mil. Div. Tenn., June 20, 1865; G. O. Nos. 1 and 42, Dept. of the Tenn., Aug. 13 and Nov. 1, 1866; G. O. No. 1, Dept. of the South, June 1, 1866; G. O. No. 1, Dept. of the Gulf, ——, 1865; G. O. No. 1, Dist. of the Chattahoochee, Aug. —, 1866. There were numerous general orders from local headquarters of the same nature. See also Van Horne, “Life of Thomas,” pp. 153, 399, 400, 418; and Sen. Ex. Doc., No. 13, 38th Cong., 2d Sess. [1127] G. O. No. 1, Sub-dist. Ala., March 28, 1867. [1128] Freedmen’s Bureau Report, Oct. 20, 1869; Ho. Ex. Doc., No. 143, 41st Cong., 2d Sess. [1129] Sen. Ex. Doc., No. 28, 38th Cong., 2d Sess. [1130] Regulations, July 9, 1864. [1131] Stats.-at-Large, Vol. XIII, pp. 507-509. See also O. O. Howard, “The Freedmen during the War,” in the New Princeton Review, May and Sept., 1886.
  • 62. [1132] Ho. Ex. Doc., No. 7, 39th Cong., 2d Sess. [1133] McPherson, “Reconstruction,” pp. 69-74, 147-151, 349, 350, 378; Burgess, “Reconstruction,” pp. 87-90. [1134] N. Y. Times, Oct. 31, 1865. [1135] Circular No. 16, Sept. 19, 1865 (Howard); Circular No. 6, June 13, 1865 (Howard); Ho. Ex. Doc., No. 70, 39th Cong., 1st Sess.; Circular No. 1, July 14, 1865 (Conway); Circular No. 2, July 14, 1865 (Conway). [1136] One of them—Chaplain C. W. Buckley—was guardian of the blacks at Montgomery. He afterwards played a prominent part in carpet-bag politics. [1137] Ku Klux Rept., p. 441; N. Y. World, July 20, 1865; oral accounts and letters. It was on this theory that the Bureau was established, and at the head of the institution was placed General O. O. Howard, who was a soft-hearted, unpractical gentleman, with boundless confidence in the negro and none whatever in the old slave owner. A man of hard common sense like Sherman would have done less harm and probably much good with the Bureau. [1138] Ho. Ex. Doc., No. 70, 39th Cong., 1st Sess. [1139] Circular No. 5, June 2, 1865 (Howard); Circular No. 2, July 14, 1865 (Conway); Ho. Ex. Doc., No. 70, 39th Cong., 1st Sess. [1140] Freedmen’s Bureau Report, Dec., 1865. [1141] In November, 1866, the following army officers, most of whom were members of the Veteran Reserve Corps, were made superintendents of these depots: Montgomery, Capt. J. L. Whiting, V.R.C.; Mobile, Brevet Major G. H. Tracy, 15th Infantry; Huntsville, Brevet Col. J. B. Callis, V.R.C.; Selma, Lieut. George Sharkley; Greenville, James F. McGogy, Late First Lieut. U.S.A.; Tuscaloosa, Capt. W. H. H. Peck, V.R.C.; Talladega, J. W. Burkholder, A.A.G., U.S.A.; Demopolis, Brevet Major C. W. Pierce, V.R.C. Other Bureau
  • 63. officials who afterward became well-known carpet-baggers were: Major C. A. Miller, 2d Maine Cavalry, A.A.G.; Major B. W. Norris, Additional Paymaster; Lieut.-Col. Edwin Beecher, Additional Paymaster; Rev. C. W. Buckley, Chaplain 47th U.S.C. Infantry. Other officers of the V.R.C. who arrived later were Capt. Roderick Theune, Lieuts. George F. Browing, G. W. Pierce, John Jones, P. E. O’Conner, and Joseph Logan. See Swayne’s Report, Oct. 31, 1866; Sen. Ex. Doc., No. 21, 40th. Cong., 2d Sess. With one exception these later assisted in Reconstruction. [1142] Freedmen’s Bureau Report, Oct. 24, 1869. [1143] Freedmen’s Bureau Report, Oct. 24, 1868. [1144] McPherson’s scrap-book, “Freedmen’s Bureau Bill, 1866,” p. 128. [1145] For examples, see Schurz’s Report and accompanying documents, Nos. 20, 21, 22, 28; Taylor, “Destruction and Reconstruction”; article by Schurz in McClure’s Magazine, Jan., 1904. [1146] The Nation, Feb. 15, 1866. [1147] Report of the Joint Committee on Reconstruction, Pt. III, p. 138. [1148] G. O. No. 7, Montgomery, Aug. 4, 1865. [1149] No one ever knew exactly how far the military commander was bound to obey the assistant commissioner and vice versa. The problem was at last solved by making Swayne military commander also. [1150] Report of the Joint Committee on Reconstruction, Pt. III, p. 138 (testimony of General Wager Swayne). [1151] Report of the Joint Committee on Reconstruction, Pt. III, p. 138.
  • 64. [1152] Swayne did not hesitate to intimidate such men as Parsons. He would treat old men—former senators, governors, and congressmen—as if they were bad boys; he himself was under thirty. [1153] The reason for this was that the day before several Federal drunken officers had been careering around the bay in a boat, and Forsyth, who was on this boat, did not want his party of ladies to meet them. [1154] Statement of Swayne, 1901; N. Y. News, Aug. 21, 1865. [1155] Circular No. 20 (Freedmen’s Bureau), War Dept., Nov. 30, 1865. [1156] Circular No. 15, Sept. 12, 1865. [1157] McPherson, “Reconstruction,” p. 13. [1158] Richardson, Messages and Papers of the Presidents, Vol. VI, p. 352; G. O. No. 64, Dept. Ala., Dec. 10, 1865; Swayne’s Report, Jan. 31, 1865; Freedmen’s Bureau Reports, Dec., 1865, and Nov., 1866. [1159] Freedmen’s Bureau Report, Dec., 1895; Swayne’s Reports, Jan. 31 and Oct. 31, 1866, in Ho. Ex. Doc., No. 70, and Sen. Ex. Doc., No. 6, 39th Cong., 1st Sess. [1160] Freedmen’s Bureau Report, Nov. 1, 1866. [1161] Ho. Rept., No. 121, 41st Cong., 2d Sess.; Sen. Ex. Doc., No. 6, 39th Cong., 1st Sess. [1162] Freedmen’s Bureau Reports, Dec., 1865, and Nov., 1866; Ho. Ex. Doc., No. 142 41st Cong., 2d Sess.; Miller, “History of Alabama,” p. 240. Congress appropriated $20,000,000, and there was an immense amount of Confederate property confiscated and sold for the benefit of the Bureau. Of this no account was kept. One detailed estimate of Bureau expenses is as follows:—
  • 65. Appropriations by Congress $20,000,000 General Bounty Fund 8,000,000 Freedmen and Refugee Fund 7,000,000 Retained Bounty Fund (Butler) 2,000,000 School Fund (Confiscated Property) 2,500,000 Total $39,500,000 Edwin De Leon, “Ruin and Reconstruction of the Southern States,” in Southern Magazine, 1874. See also Ho. Ex. Doc., No. 142, 41st Cong., 2d Sess. [1163] G. O. No. 4, July 28, 1865. [1164] N. Y. News, Sept. 7, 1865 (Montgomery correspondent); Ku Klux Rept., p. 441; oral accounts. [1165] Montgomery Mail, May 12, 1865. [1166] Howard’s Circular, May 30, 1865; War Department Circular No. 11, July 12, 1865. [1167] Huntsville Advocate, July 26, 1865. This was when the army officials were conducting the Bureau. Later the civilian agents charged $2 for making every contract, and the negroes soon wanted the Bureau abolished so far as it related to contracts. N. Y. Times, March 12, 1866 (letter from Florence, Ala.). In Madison County some of the negroes tarred and feathered a Bureau agent who had been collecting $1.50 each for drawing contracts. N. Y. Herald, Dec. 22, 1867. [1168] Swayne’s Report, Jan. 31, 1866. [1169] These regulations bear the approval of the other two rulers of Alabama—General Woods and Governor Parsons. See G. O. No. 12, Aug. 30, 1865.
  • 66. [1170] G. O. No. 13, Sept., 1865. This order was in force until 1868. See N. Y. World, Nov. 20, 1867. [1171] These propositions were approved by A. Humphreys, assistant superintendent at Talladega, and by General Chetlain, commanding the District of Talladega. Selma Times, Dec. 4, 1865. [1172] Selma Messenger, Nov. 15, 1865; N. Y. World, Nov. 20, 1867. [1173] Ku Klux Rept., p. 441; N. Y. News, Sept. 7, 1865; oral accounts. [1174] Swayne’s Report, Jan., 1866. Rev. C. W. Buckley, in a report to Swayne (dated Jan. 5, 1866), of a tour in Lowndes County, stated that while the Bureau and the army and the “government of the Christian nation,” each had done much good, all was as nothing to what God was doing. The hand of God was seen in the stubborn and persistent reluctance of the negro to make contracts and go to work; God had taught the 8,000,000 arrogant and haughty whites that they were dependent upon the freedmen; God had ordained that “the self-interest of the former master should be the protection of the late slaves.” [1175] Swayne’s Report, Oct. 31, 1865. [1176] Freedmen’s Bureau Report, Oct. 24, 1868. [1177] De Bow’s Review, 1866. [1178] Freedmen’s Bureau Report, Dec., 1865. [1179] Howard’s Circular Letter, Oct. 4, 1865. [1180] Report, Oct. 31, 1866. [1181] Herbert, “Solid South,” p. 31; N. Y. News, Sept. 3, 1865 (Selma correspondent). [1182] In one case the agent in Montgomery sent to Troy, fifty-two miles distant, and arrested a landlord who refused to rent a house to
  • 67. a negro. The negro told the Bureau agent that he was being evicted. [1183] There were several plantations near Montgomery, Selma, Mobile, and Huntsville where negroes were thus collected. [1184] In Montgomery, the Rev. C. W. Buckley, a “hard-shell” preacher, looked after negro contracts. A negro was not allowed to make his own contract, but it must be drawn up before Buckley. When a negro broke his contract, Buckley always decided in his favor, and avowed that he would sooner believe a negro than a white man. His delight was to keep a white man waiting for a long time while he talked to the negro, turning his back to and paying no attention to the white caller. He preached to the negroes several times a week, not sermons, but political harangues. The audience was composed chiefly of negro women, who, if they had work, would leave it to attend the meetings. They would not disclose what Buckley said to them, and when questioned would reply, “It’s a secret, and we can’t tell it to white folks.” Buckley advocated confiscation, but Swayne, who had more common sense, frowned upon such theological doctrines. [1185] Barker, a carriage-maker at Livingston, was arrested and confined in prison for some time, and finally was released without trial. He was told that a negro servant had preferred charges against him, and later denied having done so. Such occurrences were common. Ku Klux Rept. Ala. Test., pp. 357, 371, 390, 475, 487, 1132; Ho. Ex. Doc., No. 27, 39th Cong., 1st Sess.; Swayne’s Reports, Dec., 1865, and Jan., 1866. [1186] Selma Times, April 11, 1866. Busteed was a much-disliked carpet-bag Federal judge. Mr. Burns survived the Busting, and was a member of the Constitutional Convention of 1901. [1187] The Bureau courts continued to act even after the state was readmitted to the Union. In 1868, two constables arrested a negro charged with house-burning in Tuscumbia. Col. D. C. Rugg, the Bureau agent at Huntsville, raised a force of forty negroes and came
  • 68. to the rescue of the negro criminal. “If you attempt to put that negro on the train,” he said, “blood will be spilled. I am acting under the orders of the military department.” The officers were trying to take him to Tuscumbia for trial. Rugg thought the Bureau should try him, and said, “These men [the negroes] are not going to let you take the prisoner away, and blood will be shed if you attempt it.” N. Y. World, Oct. 23, 1868; Tuscaloosa Times. [1188] Probably more. Freedmen’s Bureau Report, Nov. 1, 1866. [1189] Bureau Reports, 1865-1869. [1190] Freedmen’s Bureau Reports, 1865-1870; Hardy, “History of Selma”; N. Y. World, Nov. 13, 1865. [1191] The Southern Famine Relief Commission of New York, which worked in Alabama until 1867, reported that there was much greater suffering from want among the whites than among the blacks. This society sent corn alone to the state,—65,958 bushels. See Final Proceedings and General Report, New York, 1867. [1192] Freedmen’s Bureau Reports, 1865-1868. [1193] Ho. Rept., No. 121, 41st Cong., 2d Sess. [1194] Sen. Ex. Doc., No. 6, 39th Cong., 1st Sess. [1195] Freedmen’s Bureau Report, Dec., 1865. [1196] Swayne’s Report, Oct. 31, 1866; N. Y. Daily News, Sept. 7, 1865 (Montgomery correspondent). [1197] Trowbridge, “The South,” p. 446. [1198] In the convention of 1867 this teaching bore fruit in the ordinance authorizing suits by former slaves to recover wages from Jan. 1, 1863. [1199] N. Y. World, Nov. 13, 1865 (Selma correspondent); oral accounts.
  • 69. [1200] De Bow’s Review, March, 1866 (Dr. Nott); N. Y. Times, Oct. 3, 1865; Montgomery Advertiser, March 21, 1866. [1201] Du Bois in Atlantic Monthly, March, 1901. [1202] A Tallapoosa County farmer stated that for three years after the war the crops were very bad. Yet the whites who had negroes on their farms felt bound to support them. But if the whites tried to make the negroes work or spoke sharply to them, they would leave and go to the Bureau for rations. P. M. Dox, a Democratic member of Congress in 1870, said that in north Alabama, in 1866-1867, negro women would not milk a cow when it rained. Servants would not black boots. There was a general refusal to do menial service. Ala. Test., pp. 345, 1132. The Alabama cotton crop of 1860 was 842,729 bales; of 1865, 75,305 bales; of 1866, 429,102 bales; of 1867, 239,516 bales; of 1868, 366,193 bales. Of each crop since the war an increasingly large proportion has been raised by the whites. [1203] Swayne’s Report, Oct. 31, 1866. [1204] Within the last five years I have seen several old negroes who said they had been paying assessments regularly to men who claimed to be working to get the “forty acres and the mule” for the negro. They naturally have little to say to white people on the subject. From what I have been told by former slaves, I am inclined to think that the negroes have been swindled out of many hard- earned dollars, even in recent times, by the scoundrels who claim to be paying the fees of lawyers at work on the negroes’ cases. [1205] Swayne’s Report, Oct. 31, 1866; Freedmen’s Bureau Report, Dec., 1865; Grant’s Report; Truman’s Report, April 9, 1866; DeBow’s Review, March, 1866; Montgomery Advertiser, March 1, 1866; N. Y. News, Nov. 25, 1865 (Selma correspondent); N. Y. World, Nov. 13, 1865; N. Y. Times, Oct. 31, 1865; N. Y. News, Sept., and Oct. 2, 7, 1865. B. W. Norris, a Bureau agent from Skowhegan, Maine, told the negroes the tale of “forty acres and a mule,” and they sent him to Congress in 1868 to get the land for them. He told them that they
  • 70. had a better right to the land than the masters had. “Your work made this country what it is, and it is yours.” Ala. Test., pp. 445, 1131. [1206] Ala. Test., p. 314. [1207] Ball, “Clarke County,” p. 627. [1208] Ala. Test., p. 1133. [1209] Ala. Test., p. 460; see Annual Cyclopædia (1867), article “Confiscation.” [1210] Montgomery Advertiser, March, 1866. Buckley was known among the “malignants” as “the high priest of the nigger Bureau.” N. Y. World, Dec. 22, 1867. [1211] N. Y. Herald, July 23, 1865; Herbert, “Solid South,” p. 30. [1212] DeBow’s Review, 1866; oral accounts. [1213] N. Y. Times, Feb. 12, 1866 (letter of northern traveller); Steedman and Fullerton’s Reports; N. Y. Herald, June 24, 1866; Columbus (Ga.) Sun, Nov. 22, 1865; N. Y. Times, Jan. 25, 1866. [1214] Account by Col. J. W. DuBose in manuscript. [1215] Herbert, “Solid South,” pp. 30, 31; N. Y. Times, Jan. 25, 1866. [1216] Ho. Rept., No. 121, 41st Cong., 2d Sess.; Ku Klux Rept., p. 441. See chapter in regard to Union League. [1217] See also DuBois, in Atlantic Monthly, March, 1901; Ho. Ex. Doc., No. 241, 41st Cong., 2d Sess. [1218] Ho. Rept., No. 121, p. 47, 41st Cong., 2d Sess. [1219] Some of the prominent incorporators were Peter Cooper, William C. Bryant, A. A. Low, Gerritt Smith, John Jay, A. S. Barnes, J. W. Alvord, S. G. Howe, George L. Stearns, Edward Atkinson, and A.
  • 71. A. Lawrence. The act of incorporation was approved by the President on March 3, 1865, at the same time the Freedmen’s Bureau Bill was approved. Numbers of the incorporators and bank officials were connected with the Bureau. See Ho. Mis. Doc., No. 16, 43d Cong., 2d Sess. [1220] A Bureau paymaster. [1221] Ho. Mis. Doc., No. 16, 43d Cong., 2d Sess. [1222] Ho. Ex. Doc., No. 70, 39th Cong., 1st Sess. [1223] See Williams, “History of the Negro Race in America,” Vol. II, p. 410. August was a month in which there was little money-making among the negroes. It was vacation time, between the “laying by” and the gathering of the crop. [1224] Hoffman, “Race Traits and Tendencies,” p. 290, says $3,013,699. [1225] Hoffman, p. 290; also Sen. Rept., No. 440, 46th Cong., 2d Sess. Williams, Vol. II, p. 411, states that the total deposits amounted to $57,000,000, an average of $284 for each depositor. [1226] Dividends were declared as follows: Nov. 1, 1875, 20%; March 20, 1875-1878, 10%; Sept. 1, 1880, 10%; June 1, 1882, 15%; May 12, 1883, 7%; making 62% in all. To 1886, $1,722,549 had been paid to depositors, and there was a balance in the hands of the government receivers of $30,476. [1227] Williams, “History of the Negro Race,” Vol. II, pp. 403-410; Fred Douglass, “Life and Times,” Ch. XIV; Ho. Mis. Doc., No. 16, 43d Cong., 2d Sess.; Du Bois, “The Souls of Black Folk”; the various reports of the Freedmen’s Bureau and of the commissioners appointed to settle the affairs of the Freedmen’s Savings and Trust Company, to 1902; Hoffman, “Race Traits and Tendencies,” pp. 289, 290; Fleming, “Documents relating to Reconstruction,” Nos. 6 and 7. [1228] Regulations of the Treasury Dept., July 29, 1864.
  • 72. [1229] McPherson, “Rebellion,” pp. 594, 595; McPherson, “Reconstruction,” pp. 147-151. [1230] See Ch. IV, sec. 7. [1231] DuBois (Atlantic Monthly, March, 1901) declares that the opposition to the education of the negro was bitter, for the South believed that the educated negro was a dangerous negro. This statement is perhaps partially correct for fifteen or twenty years after 1870, but it is not correct for 1865-1869. [1232] The Gulf States Hist. Mag., Sept., 1902; Report of General Swayne to Howard, Dec. 26, 1865. The evidence on this point that is worthy of consideration is conclusive. It is all one way. See also Chs. XIX and XX, below. [1233] Report of Swayne, Oct. 31, 1866. [1234] “Up from Slavery,” pp. 29, 30. [1235] Daily News, Sept. 7, 1865 (Montgomery correspondence). Oral accounts. [1236] G. O. No. 11, July 12, 1865 (Montgomery); Freedmen’s Bureau Reports, 1865-1869. [1237] Swayne’s Report, Oct. 31, 1866; Freedmen’s Bureau Report, 1866. [1238] Swayne’s Report., Oct. 31, 1866. [1239] Freedmen’s Bureau Report, Dec., 1865; Ho. Ex. Doc., No. 70, 39th Cong., 1st Sess. [1240] Daily News, Oct. 21, 1865 (Mobile correspondent); De Bow’s Review, 1866 (Dr. Nott). [1241] Swayne’s Report, Oct. 31, 1866.
  • 73. [1242] The account of this particular school was given me by Dr. O. D. Smith of Auburn, Ala., who was one of the men who chose the white teacher. [1243] Swayne’s Report, Oct. 31, 1866. [1244] Report, Oct. 31, 1866. [1245] Rent was usually paid at the rate of $20 a month for thirty pupils. Ho. Rept., No. 121, pp. 47, 369, 374, 377, 41st Cong., 2d Sess. The books of the American Missionary Association showed that it had received, in 1868 and 1869, from the Freedmen’s Bureau for Alabama, the following amounts in cash, though how much it received before these dates is not known. December, 1867 $4000.00 October, 1868 583.86 February, 1868 25.41 (?) January, 1869 218.25 April, 1869 683.53 May, 1869 1397.49 June, 1869 95.87 July, 1869 527.00 September, 1869 3049.59 November, 1869 3469.50 December, 1869 2083.78 For building (?) 20,000.00 An item in the account of the Association was “Chicago to Mobile, $20,000.” No one was able to explain what it meant unless it was the $20,000 building in Mobile used as a training school for negro teachers and on which the Bureau paid rent. In the southern states the Bureau paid to the American Missionary Association, as shown by the books of the latter, $213,753.22. Judging from the variable
  • 74. items not noted above, rent was evidently not included nor even all the cash. Ho. Rept., No. 121, p. 369 et seq., 41st Cong., 2d Sess. (Howard Investigation). [1246] Buckley’s Report for March 15, 1867; Semiannual Report on Schools for Freedmen, July 4, 1867; General Clanton in Ku Klux Rept. Ala. Test. [1247] Francis Wayland. [1248] S. G. Greene, president of the association. [1249] President Hill of Harvard College. [1250] Reports, Proceedings, and Lectures of the National Teachers’ Association, 1865 to 1880; Reports of the Freedmen’s Aid Societies of the Methodist Episcopal Church. For results of the mistaken teachings of the radical instructors, see Page’s article on “Lynching” in the North American Review, Jan., 1904. [1251] Miss Alice M. Bacon, in the Slater Fund Trustees, Occasional Papers, No. 7, p. 6. Armstrong, at Hampton, Va., was a shining exception to the kind of teachers described above. [1252] The Reconstruction government was now in power. There were, at this time, thirty-one Bureau schools at thirty-one points in the state. [1253] Freedmen’s Bureau Reports, 1867-1870. [1254] Atlantic Monthly, March, 1901. [1255] Sir George Campbell, “White and Black,” pp. 131, 383; Thomas, “The American Negro,” p. 240; Washington, “The Future of the American Negro,” pp. 25-27, 55; DeBow’s Review, 1866; Slater Fund Trustees, Occasional Papers, No. 7. Washington tells of the craze for the education in Greek, Latin, and theology. This education would make them the equal of the whites, they thought, and would free them from manual labor, and above all fit them for office-
  • 75. holding. Nearly all became teachers, preachers, and politicians. “Up from Slavery,” pp. 30, 80, 81; “Future of the American Negro,” p. 49. [1256] From the surrender of the Confederate armies, to his death in 1903, Dr. Curry was a stanch believer in the work for negro education. No other man knew the whole question so thoroughly as he. And he had the advantage of a close acquaintance with the negro from his early childhood. His observations as to the effects of alien efforts to educate the black will be found in the Slater Fund Occasional Papers, and in an address delivered before the Montgomery Conference in 1900. See also Ch. XIV. [1257] I have talked with many who uniformly assert that they were unable to conform to the Bureau regulations. It was better to let land remain uncultivated. Wherever possible no attention was paid to the rules. The negro laborers themselves have no recollections of any real assistance in labor matters received from the Bureau. They remember it rather as an obstruction to laboring freely. [1258] The President and the Supreme Court now being powerless. [1259] That is, blacks and such whites as were not “disfranchised for participation in the rebellion or for felony.” [1260] July 11, 1868, the oath was modified for those whose disabilities had been removed by Congress; Feb. 15, 1871, those not disfranchised by the Fourteenth Amendment were allowed to take the modified oath of July 11, 1868, instead of the iron-clad oath. See MacDonald, “Select Statutes.” The Alabama representatives all took the “iron-clad” oath. [1261] Text of the Act, McPherson, “Reconstruction,” pp. 191, 192; G. O. No. 2, 3d M. D., April 3, 1867. For criticism, Burgess, “Reconstruction,” pp. 112-122; Dunning, “Civil War and Reconstruction,” pp. 123, 126-135, 143. [1262] G. O. Nos. 10 and 18, H. Q. A., March 11 and 15, 1867; McPherson, p. 200.
  • 76. [1263] Report of Secretary of War, 1867, Vol. I, p. 321. [1264] The oath was: “I, —— ——, do solemnly swear (or affirm), in the presence of Almighty God, that I am a citizen of the State of Alabama; that I have resided in said State for —— months, next preceding this day, and now reside in the county of —— in said State; that I am twenty-one years old; that I have not been disfranchised for participation in any rebellion or civil war against the United States, nor for felony committed against the laws of any State or of the United States; that I have never been a member of any State legislature, nor held any executive or judicial office in any State and afterward engaged in insurrection or rebellion against the United States or given aid and comfort to the enemies thereof; that I have never taken an oath as a member of Congress of the United States, as an officer of the United States, or as a member of any State legislature, or as an executive or judicial officer of any State, to support the Constitution of the United States and afterwards engaged in insurrection or rebellion against the United States or given aid and comfort to the enemies thereof; that I will faithfully support the Constitution and obey the laws of the United States, and will, to the best of my ability, encourage others to do so, so help me God!” McPherson, “Reconstruction,” pp. 192, 205; G. O. No. 5, 3d M. D., April 8, 1867. [1265] McPherson, “Reconstruction,” pp. 192-194; Burgess, “Reconstruction,” pp. 129-135; Dunning, “Civil War and Reconstruction,” pp. 124, 125. [1266] G. O. Nos. 1 and 2, 3d M. D., April 1 and 3, 1866; N. Y. Herald, April 6, 1867; Annual Cyclopædia (1867), p. 19; McPherson, pp. 201, 205; Report of Secretary of War, 1867, Vol. I, p. 322; Herbert, “Solid South,” p. 38. [1267] G. O. No. 1, Dist. Ala., April 2, 1867; McPherson, p. 206. [1268] Report of Secretary of War, 1867, Vol. I, p. 466; N. Y. Herald, April 6, 1867.
  • 77. [1269] Ho. Ex. Doc., No. 20, 40th Cong., 1st Sess. [1270] G. O. No. 52, H. Q. A., April 11, 1867. [1271] Report of Secretary of War, 1867, Vol. I, p. 353. [1272] G. O. No. 4, 3d M. D., April 4, 1867. [1273] G. O. No. 10, 3d M. D., April 23, 1867. [1274] G. O. No. 48, 3d M. D., Aug. 6, 1867. [1275] Annual Cyclopædia (1867), p. 17. [1276] G. O. No. 25, 3d M. D., May 29, 1867. (This was to favor Radical meetings. There were many stump speakers sent down from the North to tell the negro how to vote, and it was feared they might excite the whites to acts of violence.) N. Y. Herald, June 4, 1867 (explanatory order). [1277] McPherson, “Reconstruction,” pp. 335, 336; Dunning, pp. 153, 154. [1278] As long as Pope was in command at Montgomery and Atlanta, he and Grant kept up a rapid and voluminous (on the part of Pope) correspondence. They were usually agreed on all that pertained to Reconstruction, both now being extreme in their views. [1279] Ho. Ex. Doc., No. 30, 40th Cong., 2d Sess.; No. 20, 40th Cong., 1st Sess.; McPherson, p. 312. [1280] G. O. No. 45, 3d M. D., Aug. 2, 1867; McPherson, p. 319. [1281] G. O. Nos. 53 and 55, 3d M. D., Aug. 19 and 23, 1867; Report of the Secretary of War, 1867, Vol. I, p. 331; McPherson, p. 319. [1282] See Selma Messenger, Jan. 17, 1868. [1283] See McPherson, p. 312.
  • 78. [1284] Eutaw Whig and Observer, Dec. 12 and 24, 1867. [1285] S. O. No. 2, 3d M. D., April 15, 1867; Annual Cyclopædia (1867), p. 20; Montgomery Mail, April 30, 1867. [1286] See p. 509. [1287] G. O. Nos. 35, 38, 40, Post of Mobile, 1867; Annual Cyclopædia (1867), pp. 20-23; N. Y. Times, May 21, 1867. [1288] N. Y. World, May 28, 1867; S. O. No. 34, 3d M. D., May 31, 1867; Herbert, “Solid South,” p. 40; N. Y. Times, May 21, 1867. [1289] S. O. No. 38, 3d M. D., June 6, 1867; S. O. No. 27, 3d M. D., May 22, 1867; N. Y. Tribune, June 12, 1867; Selma Messenger, June 18, 1867; Evening Post, May, 1867; Annual Cyclopædia (1867), pp. 20-25; Mobile Register, Oct. —, 1867. [1290] Mobile Register, Oct. —, 1867. [1291] Herbert, “Solid South,” pp. 40, 41; N. Y. Times, Dec. 27, 1867. See above, p. 393. [1292] S. O. Nos. 9, 10, 16, 18, 19, 20, 22, 24, 25, 26, 27, 31, 32, 35, 36, 37, 38, 39, 3d M. D., 1867; Report of the Secretary of War, 1867, Vol. I, p. 327. (Some of the persons appointed were B. T. Pope and David P. Lewis, judges; George P. Goldthwaite, solicitor; and B. F. Saffold, mayor of Selma.) [1293] Report of the Secretary of War, 1867, Vol. I, p. 364. [1294] G. O. No. 77, 3d M. D., Oct. 19, 1897; McPherson, p. 319. [1295] G. O. No. 103, 3d M. D., Dec. 21, 1867. [1296] Report of the Secretary of War, 1877, Vol. I, p. 333; McPherson, p. 316. [1297] S. O. 254, 3d M. D., Nov. 26, 1867; Pope to Swayne, Nov. 20, 1867; N. Y. World, Dec. 14, 1867.
  • 79. [1298] G. O. No. 3, Sub-dist. Alabama, April 12, 1867; McPherson, p. 319. [1299] McPherson, p. 319. [1300] N. Y. Herald, April 6, 1867. [1301] N. Y. Tribune, June 1, 1867; N. Y. Herald, June 4, 1867; G. O. No. 28, 3d M. D., June 3, 1867; Report of the Secretary of War, 1867, Vol. I, p. 326. [1302] Aug. 12, 1867. [1303] G. O. Nos. 1 and 10. [1304] G. O. No. 49, 3d M. D., Aug. 12, 1867. [1305] Report of the Secretary of War, 1867, Vol. I, p. 235. [1306] Selma Messenger, Dec. 25, 1867. [1307] G. O. No. 25, 3d M. D., 1867. [1308] S. O. No. 53, 3d M. D., June 27, 1867; G. O. No. 44, 3d M. D., Aug. 1, 1867; Ho. Ex. Doc., No. 30, 40th Cong., 2d Sess. [1309] G. O. No. 94, 3d M. D., 1867. [1310] S. O. No. 96, 3d M. D., Aug 5. 1867; Ho. Ex. Doc., No. 30, 40th Cong., 2d Sess. There were other cases not referred to in general and special orders, but this was the only case in which Pope himself directly interfered. [1311] G. O. No. 5, 3d M. D., April 8, 1867. [1312] In this way, white majorities in ten counties were overcome by black majorities in the adjoining counties of the district. [1313] Of the registrars who later became somewhat prominent in politics, the whites were Horton, Dimon, Dereen, Sillsby, William M. Buckley, Stanwood, Ely, Pennington, Haughey—all being northern
  • 80. men. Of the negro members of the boards, Royal, Finley, Williams, Alston, Turner, Rapier, and King (or Godwin) rose to some prominence, and their records were much better that those of their white colleagues. [1314] G. O. No. 20, 3d M. D., May 21, 1867. [1315] G. O. No. 12, 3d M. D., 1867. [1316] Smith was later the first Reconstruction governor of Alabama. [1317] G. O. No. 41, 3d M. D., 1867. [1318] G. O. No. 50, 3d M. D., Aug. 15, 1867. [1319] Governor, secretary of state, treasurer, comptroller, sheriff, judicial officers of every kind, and all court clerks and other officials, commissioners, tax assessors and collectors, county surveyors, treasurers, mayor, councilmen, justices of the peace, solicitors. [1320] Special Instructions to Registrars in Alabama, Report of the Secretary of War, 1867, Vol. I, p. 339. [1321] Registration Orders, June 17, 1867. [1322] Record of Cabinet Meeting, June 18, 1867, in Ho. Ex. Doc., No, 34, 40th Cong., 1st Sess.; Burgess, p. 136; Ho. Ex. Doc., No. 20, 40th Cong., 1st Sess. [1323] Ho. Ex. Doc., No. 20, 40th Cong., 1st Sess.; McPherson, p. 311. See above, p. 479. [1324] McPherson, pp. 335, 336; Burgess, pp. 138-142. [1325] McPherson, pp. 335, 336. [1326] G. O. No. 59, 3d M. D., Aug. 31, 1867; Journal of Convention of 1867, pp. 3-5; Report of the Secretary of War, 1867, Vol. I, pp. 356, 357; Tribune Almanac, 1868.
  • 81. Welcome to our website – the perfect destination for book lovers and knowledge seekers. We believe that every book holds a new world, offering opportunities for learning, discovery, and personal growth. That’s why we are dedicated to bringing you a diverse collection of books, ranging from classic literature and specialized publications to self-development guides and children's books. More than just a book-buying platform, we strive to be a bridge connecting you with timeless cultural and intellectual values. With an elegant, user-friendly interface and a smart search system, you can quickly find the books that best suit your interests. Additionally, our special promotions and home delivery services help you save time and fully enjoy the joy of reading. Join us on a journey of knowledge exploration, passion nurturing, and personal growth every day! ebookbell.com