├── k
├── Assets.xcassets
│ ├── Contents.json
│ ├── AppIcon.appiconset
│ │ ├── k(1).png
│ │ └── Contents.json
│ └── AccentColor.colorset
│ │ └── Contents.json
├── Preview Content
│ └── Preview Assets.xcassets
│ │ └── Contents.json
├── kApp.swift
├── k.entitlements
├── ContentView.swift
└── SettingsView.swift
├── shared
├── WordListBarStyle.swift
├── WordListBarItem.swift
├── AccessoryBarItem.swift
├── Position.swift
├── UIImpactFeedbackGenerator.FeedbackStyle+Codable.swift
├── Array+Codable.swift
├── Shape+strokeFill.swift
└── KeyboardButtonStyle.swift
├── k.xcodeproj
├── project.xcworkspace
│ ├── contents.xcworkspacedata
│ └── xcshareddata
│ │ └── IDEWorkspaceChecks.plist
├── xcshareddata
│ └── xcschemes
│ │ ├── k.xcscheme
│ │ └── keyboard.xcscheme
└── project.pbxproj
├── keyboard
├── keyboard.entitlements
├── Audio.swift
├── Info.plist
├── KeyboardViewController.swift
├── WordListView.swift
├── AccessoryBarView.swift
└── KeyboardView.swift
├── .gitignore
└── LICENSE
/k/Assets.xcassets/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "info" : {
3 | "author" : "xcode",
4 | "version" : 1
5 | }
6 | }
7 |
--------------------------------------------------------------------------------
/k/Assets.xcassets/AppIcon.appiconset/k(1).png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/twodayslate/k/main/k/Assets.xcassets/AppIcon.appiconset/k(1).png
--------------------------------------------------------------------------------
/k/Preview Content/Preview Assets.xcassets/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "info" : {
3 | "author" : "xcode",
4 | "version" : 1
5 | }
6 | }
7 |
--------------------------------------------------------------------------------
/shared/WordListBarStyle.swift:
--------------------------------------------------------------------------------
1 | import Foundation
2 |
3 | enum WordListBarStyle: String, Codable {
4 | case regular
5 | case suggestion
6 | }
7 |
--------------------------------------------------------------------------------
/k.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/k/Assets.xcassets/AccentColor.colorset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "colors" : [
3 | {
4 | "idiom" : "universal"
5 | }
6 | ],
7 | "info" : {
8 | "author" : "xcode",
9 | "version" : 1
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/k/kApp.swift:
--------------------------------------------------------------------------------
1 | //
2 | // kApp.swift
3 | // k
4 | //
5 | // Created by Zachary Gorak on 10/12/22.
6 | //
7 |
8 | import SwiftUI
9 |
10 | @main
11 | struct kApp: App {
12 | var body: some Scene {
13 | WindowGroup {
14 | ContentView()
15 | }
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/k/Assets.xcassets/AppIcon.appiconset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "filename" : "k(1).png",
5 | "idiom" : "universal",
6 | "platform" : "ios",
7 | "size" : "1024x1024"
8 | }
9 | ],
10 | "info" : {
11 | "author" : "xcode",
12 | "version" : 1
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/k.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/k/k.entitlements:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | com.apple.security.application-groups
6 |
7 | group.com.twodayslate.k
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/keyboard/keyboard.entitlements:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | com.apple.security.application-groups
6 |
7 | group.com.twodayslate.k
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/keyboard/Audio.swift:
--------------------------------------------------------------------------------
1 | //
2 | // Audio.swift
3 | // keyboard
4 | //
5 | // Created by Zachary Gorak on 10/18/22.
6 | //
7 |
8 | import Foundation
9 | import AudioToolbox
10 |
11 | enum Sound {
12 | case normal
13 | case modifier
14 | case delete
15 | }
16 |
17 | func AudioServicesPlaySystemSound(_ sound: Sound) {
18 | switch sound {
19 | case .delete:
20 | AudioServicesPlaySystemSound(1155)
21 | case .normal:
22 | AudioServicesPlaySystemSound(1104)
23 | case .modifier:
24 | AudioServicesPlaySystemSound(1156)
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/shared/WordListBarItem.swift:
--------------------------------------------------------------------------------
1 | import Foundation
2 |
3 | enum WordListBarItem: String, Codable {
4 | case inputModeSwitchKey
5 | case wordList
6 | case hide
7 |
8 | var name: String {
9 | switch self {
10 | case .inputModeSwitchKey:
11 | return "Input Switcher"
12 | case .wordList: return "Word List"
13 | case .hide: return "Hide Keyboard"
14 | }
15 | }
16 | }
17 |
18 | extension WordListBarItem: CaseIterable {}
19 |
20 | extension WordListBarItem: Identifiable {
21 | var id: String {
22 | return self.rawValue
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/keyboard/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | NSExtension
6 |
7 | NSExtensionAttributes
8 |
9 | IsASCIICapable
10 |
11 | PrefersRightToLeft
12 |
13 | PrimaryLanguage
14 | mul
15 | RequestsOpenAccess
16 |
17 |
18 | NSExtensionPointIdentifier
19 | com.apple.keyboard-service
20 | NSExtensionPrincipalClass
21 | $(PRODUCT_MODULE_NAME).KeyboardViewController
22 |
23 |
24 |
25 |
--------------------------------------------------------------------------------
/shared/AccessoryBarItem.swift:
--------------------------------------------------------------------------------
1 | //
2 | // AccessoryBarItem.swift
3 | // k
4 | //
5 | // Created by Zachary Gorak on 10/17/22.
6 | //
7 |
8 | import Foundation
9 |
10 | enum AccessoryBarItem: String, Codable {
11 | case space
12 | case backspace
13 | case hide
14 | case spacer
15 |
16 | var name: String {
17 | switch self {
18 | case .space: return "Spacebar"
19 | case .backspace: return "Backspace"
20 | case .hide: return "Hide Keyboard"
21 | case .spacer: return "Spacer"
22 | }
23 | }
24 | }
25 |
26 | extension AccessoryBarItem: CaseIterable {
27 |
28 | }
29 |
30 | extension AccessoryBarItem: Identifiable {
31 | var id: String {
32 | return self.rawValue
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/shared/Position.swift:
--------------------------------------------------------------------------------
1 | //
2 | // Edge+wrapped.swift
3 | // keyboard
4 | //
5 | // Created by Zachary Gorak on 10/17/22.
6 | //
7 |
8 | import Foundation
9 | import SwiftUI
10 |
11 | /// Edge can't be put into AppStorage so we have this instead
12 | enum Position: String, Codable {
13 | case leading
14 | case trailing
15 | case top
16 | case bottom
17 |
18 | var name: String {
19 | switch self {
20 | case .bottom: return "Bottom"
21 | case .top: return "Top"
22 | case .trailing: return "Right"
23 | case .leading: return "Left"
24 | }
25 | }
26 | }
27 |
28 | extension Position: CaseIterable { }
29 |
30 | extension Position: Identifiable {
31 | var id: String {
32 | self.rawValue
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/shared/UIImpactFeedbackGenerator.FeedbackStyle+Codable.swift:
--------------------------------------------------------------------------------
1 | import UIKit
2 |
3 | extension UIImpactFeedbackGenerator.FeedbackStyle: Codable, CaseIterable, Identifiable, CustomStringConvertible {
4 | public var id: String {
5 | self.description
6 | }
7 |
8 | public var description: String {
9 | switch self {
10 | case .soft:
11 | return "Soft"
12 | case .medium: return "Medium"
13 | case .heavy: return "Heavy"
14 | case .light: return "Light"
15 | case .rigid: return "Rigid"
16 | @unknown default:
17 | return "Unknown"
18 | }
19 | }
20 |
21 | public static var allCases: [UIImpactFeedbackGenerator.FeedbackStyle] {
22 | return [.light, .medium, .heavy, .soft, .rigid]
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/shared/Array+Codable.swift:
--------------------------------------------------------------------------------
1 | import Foundation
2 |
3 | /// https://stackoverflow.com/a/65598711
4 | extension Array: RawRepresentable where Element: Codable {
5 | public init?(rawValue: String) {
6 | guard let data = rawValue.data(using: .utf8),
7 | let result = try? JSONDecoder().decode([Element].self, from: data)
8 | else {
9 | return nil
10 | }
11 | self = result
12 | }
13 |
14 | public var rawValue: String {
15 | guard let data = try? JSONEncoder().encode(self),
16 | let result = String(data: data, encoding: .utf8)
17 | else {
18 | return "[]"
19 | }
20 | return result
21 | }
22 | }
23 |
24 | public let DEFAULT_KEYBOARD_OPTIONS = [
25 | "k", "k.", "K", "K.", "Okay", "Okay."]
26 |
27 | let DEFAULT_WORDLIST_BAR_ITEMS: [WordListBarItem] = [.inputModeSwitchKey, .wordList]
28 |
--------------------------------------------------------------------------------
/shared/Shape+strokeFill.swift:
--------------------------------------------------------------------------------
1 | //
2 | // Shape+strokeFill.swift
3 | // k
4 | //
5 | // Created by Zachary Gorak on 10/17/22.
6 | //
7 |
8 | import SwiftUI
9 |
10 | /// https://www.hackingwithswift.com/quick-start/swiftui/how-to-fill-and-stroke-shapes-at-the-same-time
11 | public extension Shape {
12 | func fill(_ fillStyle: Fill, strokeBorder strokeStyle: Stroke, lineWidth: Double = 1) -> some View {
13 | self
14 | .stroke(strokeStyle, lineWidth: lineWidth)
15 | .background(self.fill(fillStyle))
16 | }
17 | }
18 |
19 | /// https://www.hackingwithswift.com/quick-start/swiftui/how-to-fill-and-stroke-shapes-at-the-same-time
20 | public extension InsettableShape {
21 | func fill(_ fillStyle: Fill, strokeBorder strokeStyle: Stroke, lineWidth: Double = 1) -> some View {
22 | self
23 | .strokeBorder(strokeStyle, lineWidth: lineWidth)
24 | .background(self.fill(fillStyle))
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/k/ContentView.swift:
--------------------------------------------------------------------------------
1 | //
2 | // ContentView.swift
3 | // k
4 | //
5 | // Created by Zachary Gorak on 10/12/22.
6 | //
7 |
8 | import SwiftUI
9 |
10 | struct ContentView: View {
11 | @State private var text: String = ""
12 |
13 | var body: some View {
14 | NavigationStack {
15 | VStack {
16 | Spacer()
17 | Text("k.")
18 | .font(.largeTitle)
19 | Spacer()
20 | Link("Add or change keyboards", destination: URL(string: "https://support.apple.com/guide/iphone/add-or-change-keyboards-iph73b71eb/ios")!)
21 | .font(.footnote)
22 | HStack {
23 | TextField("Test Your Keyboard", text: $text)
24 | .textFieldStyle(.roundedBorder)
25 | NavigationLink(destination: SettingsView(), label: {
26 | Image(systemName: "gear")
27 | })
28 | }
29 | }
30 | .padding()
31 | }
32 | }
33 | }
34 |
35 | struct ContentView_Previews: PreviewProvider {
36 | static var previews: some View {
37 | ContentView()
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/keyboard/KeyboardViewController.swift:
--------------------------------------------------------------------------------
1 | //
2 | // KeyboardViewController.swift
3 | // keyboard
4 | //
5 | // Created by Zachary Gorak on 10/12/22.
6 | //
7 |
8 | import UIKit
9 | import SwiftUI
10 | import AudioToolbox
11 |
12 | class KeyboardViewController: UIInputViewController {
13 |
14 | @IBOutlet var nextKeyboardButton: UIButton!
15 |
16 | override func updateViewConstraints() {
17 | super.updateViewConstraints()
18 |
19 | // Add custom view sizing constraints here
20 | }
21 |
22 | // Need this so we don't get an error during runtime
23 | var needsInputModeSwitchKeyWrapper = true
24 |
25 | override func viewDidLoad() {
26 | super.viewDidLoad()
27 |
28 | // Perform custom UI setup here
29 | self.nextKeyboardButton = UIButton(type: .system)
30 |
31 | self.nextKeyboardButton.setImage(UIImage(systemName: "globe"), for: [])
32 | self.nextKeyboardButton.tintColor = .label
33 |
34 | self.nextKeyboardButton.addTarget(self, action: #selector(handleInputModeList(from:with:)), for: .allTouchEvents)
35 |
36 | let root = UIHostingController(
37 | rootView:
38 | KeyboardView(
39 | parent: self,
40 | needsInputModeSwitchKey: .init(get: {
41 | self.needsInputModeSwitchKeyWrapper
42 | }, set: { _ in
43 | // no-op
44 | })
45 | )
46 | )
47 | root.view.autoresizingMask = [.flexibleWidth, .flexibleHeight]
48 | self.view.addSubview(root.view)
49 | self.addChild(root)
50 | root.didMove(toParent: self)
51 | self.view.backgroundColor = .clear
52 | root.view.backgroundColor = .clear
53 | }
54 |
55 | override func viewWillLayoutSubviews() {
56 | super.viewWillLayoutSubviews()
57 | needsInputModeSwitchKeyWrapper = needsInputModeSwitchKey
58 | }
59 |
60 | override func textWillChange(_ textInput: UITextInput?) {
61 | needsInputModeSwitchKeyWrapper = needsInputModeSwitchKey
62 | // The app is about to change the document's contents. Perform any preparation here.
63 | }
64 |
65 | override func textDidChange(_ textInput: UITextInput?) {
66 | needsInputModeSwitchKeyWrapper = needsInputModeSwitchKey
67 | // The app has just changed the document's contents, the document context has been updated.
68 | }
69 | }
70 |
--------------------------------------------------------------------------------
/shared/KeyboardButtonStyle.swift:
--------------------------------------------------------------------------------
1 | //
2 | // KeyboardButtonStyle.swift
3 | // k
4 | //
5 | // Created by Zachary Gorak on 10/17/22.
6 | //
7 |
8 | import SwiftUI
9 |
10 | struct KeyboardButton: ButtonStyle {
11 | @Environment(\.colorScheme) var colorScheme
12 |
13 | var accessory: Bool
14 |
15 | enum KeyStyle: String, Codable {
16 | case regular
17 | case accessory
18 | case suggestion
19 | }
20 |
21 | var backgroundColor: Color {
22 | if accessory {
23 | switch colorScheme {
24 | case .dark:
25 | return Color(red: 70.0/255.0, green: 70.0/255.0, blue: 70.0/255.0)
26 | case .light:
27 | return Color(red: 172.0/255.0, green: 177.0/255.0, blue: 187.0/255.0)
28 | @unknown default:
29 | return Color(UIColor.systemGray4)
30 | }
31 | } else {
32 | switch colorScheme {
33 | case .dark:
34 | return Color(red: 107.0/255.0, green: 107.0/255.0, blue: 107.0/255.0)
35 | case .light:
36 | return .white
37 | @unknown default:
38 | return .white
39 | }
40 | }
41 | }
42 |
43 | var shadowColor: Color {
44 | if accessory {
45 | switch colorScheme {
46 | case .dark:
47 | return Color(red: 37.0/255.0, green: 37.0/255.0, blue: 37.0/255.0)
48 | case .light:
49 | return Color(red: 151.0/255.0, green: 154.0/255.0, blue: 161.0/255.0)
50 | @unknown default:
51 | return Color(UIColor.black)
52 | }
53 | } else {
54 | switch colorScheme {
55 | case .dark:
56 | return Color(red: 33.0/255.0, green: 33.0/255.0, blue: 33.0/255.0)
57 | case .light:
58 | return Color(red: 172.0/255.0, green: 173.0/255.0, blue: 176.0/255.0)
59 | @unknown default:
60 | return .black
61 | }
62 | }
63 | }
64 |
65 | func makeBody(configuration: Configuration) -> some View {
66 | configuration.label
67 | .background(backgroundColor)
68 | .foregroundColor(Color(UIColor.label))
69 | .clipShape(RoundedRectangle(cornerRadius: 8))
70 | .background {
71 | RoundedRectangle(cornerRadius: 8)
72 | .fill(configuration.isPressed ? shadowColor.opacity(0.8) : shadowColor)
73 | .offset(y: configuration.isPressed ? (accessory ? 1.5 : 1) : 1.5)
74 | }
75 | }
76 | }
77 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | ## User settings
2 | xcuserdata/
3 |
4 | ## Xcode 8 and earlier
5 | *.xcscmblueprint
6 | *.xccheckout
7 |
8 | # Xcode
9 | #
10 | # gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore
11 |
12 | ## User settings
13 | xcuserdata/
14 |
15 | ## compatibility with Xcode 8 and earlier (ignoring not required starting Xcode 9)
16 | *.xcscmblueprint
17 | *.xccheckout
18 |
19 | ## compatibility with Xcode 3 and earlier (ignoring not required starting Xcode 4)
20 | build/
21 | DerivedData/
22 | *.moved-aside
23 | *.pbxuser
24 | !default.pbxuser
25 | *.mode1v3
26 | !default.mode1v3
27 | *.mode2v3
28 | !default.mode2v3
29 | *.perspectivev3
30 | !default.perspectivev3
31 |
32 | ## Obj-C/Swift specific
33 | *.hmap
34 |
35 | ## App packaging
36 | *.ipa
37 | *.dSYM.zip
38 | *.dSYM
39 |
40 | ## Playgrounds
41 | timeline.xctimeline
42 | playground.xcworkspace
43 |
44 | # Swift Package Manager
45 | #
46 | # Add this line if you want to avoid checking in source code from Swift Package Manager dependencies.
47 | # Packages/
48 | # Package.pins
49 | # Package.resolved
50 | # *.xcodeproj
51 | #
52 | # Xcode automatically generates this directory with a .xcworkspacedata file and xcuserdata
53 | # hence it is not needed unless you have added a package configuration file to your project
54 | # .swiftpm
55 |
56 | .build/
57 |
58 | # CocoaPods
59 | #
60 | # We recommend against adding the Pods directory to your .gitignore. However
61 | # you should judge for yourself, the pros and cons are mentioned at:
62 | # https://guides.cocoapods.org/using/using-cocoapods.html#should-i-check-the-pods-directory-into-source-control
63 | #
64 | # Pods/
65 | #
66 | # Add this line if you want to avoid checking in source code from the Xcode workspace
67 | # *.xcworkspace
68 |
69 | # Carthage
70 | #
71 | # Add this line if you want to avoid checking in source code from Carthage dependencies.
72 | # Carthage/Checkouts
73 |
74 | Carthage/Build/
75 |
76 | # Accio dependency management
77 | Dependencies/
78 | .accio/
79 |
80 | # fastlane
81 | #
82 | # It is recommended to not store the screenshots in the git repo.
83 | # Instead, use fastlane to re-generate the screenshots whenever they are needed.
84 | # For more information about the recommended setup visit:
85 | # https://docs.fastlane.tools/best-practices/source-control/#source-control
86 |
87 | fastlane/report.xml
88 | fastlane/Preview.html
89 | fastlane/screenshots/**/*.png
90 | fastlane/test_output
91 |
92 | # Code Injection
93 | #
94 | # After new code Injection tools there's a generated folder /iOSInjectionProject
95 | # https://github.com/johnno1962/injectionforxcode
96 |
97 | iOSInjectionProject/
98 |
--------------------------------------------------------------------------------
/k.xcodeproj/xcshareddata/xcschemes/k.xcscheme:
--------------------------------------------------------------------------------
1 |
2 |
5 |
8 |
9 |
15 |
21 |
22 |
23 |
24 |
25 |
30 |
31 |
32 |
33 |
43 |
45 |
51 |
52 |
53 |
54 |
60 |
62 |
68 |
69 |
70 |
71 |
73 |
74 |
77 |
78 |
79 |
--------------------------------------------------------------------------------
/k.xcodeproj/xcshareddata/xcschemes/keyboard.xcscheme:
--------------------------------------------------------------------------------
1 |
2 |
6 |
9 |
10 |
16 |
22 |
23 |
24 |
30 |
36 |
37 |
38 |
39 |
40 |
45 |
46 |
47 |
48 |
60 |
64 |
65 |
66 |
72 |
73 |
74 |
75 |
83 |
85 |
91 |
92 |
93 |
94 |
96 |
97 |
100 |
101 |
102 |
--------------------------------------------------------------------------------
/keyboard/WordListView.swift:
--------------------------------------------------------------------------------
1 | import SwiftUI
2 |
3 | struct WordListView: View {
4 | var parent: KeyboardViewController
5 |
6 | @Binding var needsInputModeSwitchKey: Bool
7 | @Binding var text: String
8 |
9 | @AppStorage("enabledWordListBarItems", store: .init(suiteName: "group.com.twodayslate.k")) var enabledWordListBarItems: [WordListBarItem] = DEFAULT_WORDLIST_BAR_ITEMS
10 |
11 | @AppStorage("keyboardOptions", store: .init(suiteName: "group.com.twodayslate.k")) var textOptions = DEFAULT_KEYBOARD_OPTIONS
12 |
13 | @AppStorage("keyboardSoundEnabled", store: .init(suiteName: "group.com.twodayslate.k")) var keyboardSoundEnabled = false
14 | @AppStorage("keyboardHapticsEnabled", store: .init(suiteName: "group.com.twodayslate.k")) var keyboardHapticsEnabled = false
15 | @AppStorage("keyboardHapticsStyle", store: .init(suiteName: "group.com.twodayslate.k")) var keyboardHapticsStyle: UIImpactFeedbackGenerator.FeedbackStyle = .rigid
16 | @AppStorage("keyboardHapticsIntensity", store: .init(suiteName: "group.com.twodayslate.k")) var keyboardHapticsIntensity = 1.0
17 |
18 | var body: some View {
19 | HStack(spacing: 0) {
20 | ForEach(enabledWordListBarItems) { item in
21 | switch item {
22 | case .wordList:
23 | ScrollView(.horizontal, showsIndicators: false) {
24 | HStack {
25 | ForEach(self.textOptions, id: \.self) {
26 | keyboardOptionButton($0)
27 | }
28 | }
29 | .padding(.horizontal, 4)
30 |
31 | }
32 | .mask {
33 | GeometryReader { reader in
34 | let gradientSize = 4 / max(10, reader.size.width)
35 | LinearGradient(
36 | stops: [
37 | .init(color: .black.opacity(0.0), location: 0.0),
38 | .init(color: .black, location: gradientSize),
39 | .init(color: .black, location: 1.0 - gradientSize),
40 | .init(color: .black.opacity(0.0), location: 1.0),
41 | ],
42 | startPoint: .leading,
43 | endPoint: .trailing
44 | )
45 | }
46 | }
47 | case .hide:
48 | Button {
49 | if keyboardSoundEnabled {
50 | AudioServicesPlaySystemSound(.modifier)
51 | }
52 | if keyboardHapticsEnabled {
53 | if keyboardHapticsEnabled {
54 | UIImpactFeedbackGenerator(style: keyboardHapticsStyle)
55 | .impactOccurred(intensity: keyboardHapticsIntensity)
56 | }
57 | }
58 | parent.dismissKeyboard()
59 | } label: {
60 | Image(systemName: "globe")
61 | .opacity(0.0)
62 | .overlay {
63 | Image(systemName: "keyboard.chevron.compact.down")
64 | .foregroundColor(Color(UIColor.label))
65 | }
66 | .padding(8)
67 | }
68 |
69 | case .inputModeSwitchKey:
70 | if needsInputModeSwitchKey {
71 | Image(systemName: "globe")
72 | .opacity(0.0)
73 | .overlay {
74 | ViewWrapper(view: parent.nextKeyboardButton)
75 | }
76 | .padding(8)
77 | }
78 | }
79 | }
80 |
81 | }
82 | }
83 |
84 | @ViewBuilder
85 | func keyboardOptionButton(_ text: String) -> some View {
86 | Button {
87 | if keyboardSoundEnabled {
88 | AudioServicesPlaySystemSound(.modifier)
89 | }
90 | if keyboardHapticsEnabled {
91 | if keyboardHapticsEnabled {
92 | UIImpactFeedbackGenerator(style: keyboardHapticsStyle)
93 | .impactOccurred(intensity: keyboardHapticsIntensity)
94 | }
95 | }
96 | self.text = text
97 | } label: {
98 | Text(text)
99 | .font(.footnote)
100 | .lineLimit(1)
101 | .padding(8)
102 | .frame(minWidth: 30)
103 | }
104 | .buttonStyle(KeyboardButton(accessory: true))
105 | .padding(.vertical, 8)
106 | }
107 | }
108 |
--------------------------------------------------------------------------------
/keyboard/AccessoryBarView.swift:
--------------------------------------------------------------------------------
1 | import SwiftUI
2 | import AudioToolbox
3 |
4 | struct AccessoryBarView: View {
5 | var parent: KeyboardViewController
6 |
7 | @AppStorage("enabledAccessoryBarItems", store: .init(suiteName: "group.com.twodayslate.k")) var enabledAccessoryBarItems = [AccessoryBarItem]()
8 | @AppStorage("accessoryBarPosition", store: .init(suiteName: "group.com.twodayslate.k")) var accessoryBarPosition: Position = .trailing
9 | @AppStorage("spaceBarTextEnabled", store: .init(suiteName: "group.com.twodayslate.k")) var spaceBarTextEnabled = true
10 |
11 | @AppStorage("keyboardSoundEnabled", store: .init(suiteName: "group.com.twodayslate.k")) var keyboardSoundEnabled = false
12 | @AppStorage("keyboardHapticsEnabled", store: .init(suiteName: "group.com.twodayslate.k")) var keyboardHapticsEnabled = false
13 | @AppStorage("keyboardHapticsStyle", store: .init(suiteName: "group.com.twodayslate.k")) var keyboardHapticsStyle: UIImpactFeedbackGenerator.FeedbackStyle = .rigid
14 | @AppStorage("keyboardHapticsIntensity", store: .init(suiteName: "group.com.twodayslate.k")) var keyboardHapticsIntensity = 1.0
15 |
16 | var body: some View {
17 | switch accessoryBarPosition {
18 | case .leading, .trailing:
19 | leftRightSpace
20 | case .top, .bottom:
21 | topBottomSpace
22 | }
23 | }
24 |
25 | var hideKeyboardButton: some View {
26 | Button {
27 | if keyboardSoundEnabled {
28 | AudioServicesPlaySystemSound(.modifier)
29 | }
30 | if keyboardHapticsEnabled {
31 | if keyboardHapticsEnabled {
32 | UIImpactFeedbackGenerator(style: keyboardHapticsStyle)
33 | .impactOccurred(intensity: keyboardHapticsIntensity)
34 | }
35 | }
36 | parent.dismissKeyboard()
37 | } label: {
38 | Image(systemName: "delete.left")
39 | .opacity(0.0)
40 | .overlay {
41 | Image(systemName: "keyboard.chevron.compact.down")
42 | .foregroundColor(Color(UIColor.label))
43 | }
44 | .padding(6)
45 | }
46 | .buttonStyle(KeyboardButton(accessory: true))
47 | }
48 |
49 | var backspaceButton: some View {
50 | Button {
51 | if keyboardSoundEnabled {
52 | AudioServicesPlaySystemSound(.delete)
53 | }
54 | if keyboardHapticsEnabled {
55 | if keyboardHapticsEnabled {
56 | UIImpactFeedbackGenerator(style: keyboardHapticsStyle)
57 | .impactOccurred(intensity: keyboardHapticsIntensity)
58 | }
59 | }
60 | parent.textDocumentProxy.deleteBackward()
61 | } label: {
62 | Image(systemName: "delete.left")
63 | .padding(6)
64 | }
65 | .buttonStyle(KeyboardButton(accessory: true))
66 | }
67 |
68 | @ViewBuilder
69 | var spaceButtonForTopBottom: some View {
70 | Button {
71 | if keyboardSoundEnabled {
72 | AudioServicesPlaySystemSound(.modifier)
73 | }
74 | if keyboardHapticsEnabled {
75 | if keyboardHapticsEnabled {
76 | UIImpactFeedbackGenerator(style: keyboardHapticsStyle)
77 | .impactOccurred(intensity: keyboardHapticsIntensity)
78 | }
79 | }
80 | parent.textDocumentProxy.insertText(" ")
81 | } label: {
82 | ZStack {
83 | Image(systemName: "delete.left")
84 | .padding(6)
85 | .opacity(0.0)
86 |
87 | Text(spaceBarTextEnabled ? "space" : " ")
88 | .font(.callout)
89 | .frame(maxWidth: .infinity, maxHeight: .infinity)
90 | }
91 |
92 | }
93 | .buttonStyle(KeyboardButton(accessory: false))
94 | }
95 |
96 | @ViewBuilder
97 | var topBottomSpace: some View {
98 | HStack {
99 | ForEach(enabledAccessoryBarItems) { item in
100 | switch item {
101 | case .space:
102 | spaceButtonForTopBottom
103 | case .backspace:
104 | backspaceButton
105 | case .hide:
106 | hideKeyboardButton
107 | case .spacer:
108 | Spacer()
109 | }
110 | }
111 | }
112 | .padding([.horizontal, .top], 8)
113 | }
114 |
115 | var spaceButtonForLeftRight: some View {
116 | Button {
117 | if keyboardSoundEnabled {
118 | AudioServicesPlaySystemSound(.modifier)
119 | }
120 | if keyboardHapticsEnabled {
121 | if keyboardHapticsEnabled {
122 | UIImpactFeedbackGenerator(style: keyboardHapticsStyle)
123 | .impactOccurred(intensity: keyboardHapticsIntensity)
124 | }
125 | }
126 | parent.textDocumentProxy.insertText(" ")
127 | } label: {
128 | ZStack {
129 | Image(systemName: "delete.left")
130 | .padding(6)
131 | .opacity(0.0)
132 | Text(" ")
133 | .frame(maxWidth: .infinity, maxHeight: .infinity)
134 | .overlay {
135 | if spaceBarTextEnabled {
136 | Text("space")
137 | .font(.callout)
138 | .fixedSize(horizontal: true, vertical: false)
139 | .rotationEffect(.degrees(accessoryBarPosition == .leading ? -90 : 90))
140 | .frame(maxHeight: .infinity)
141 | }
142 | }
143 | }
144 |
145 | }
146 | .buttonStyle(KeyboardButton(accessory: false))
147 | }
148 |
149 | @ViewBuilder
150 | var leftRightSpace: some View {
151 | VStack {
152 | ForEach(enabledAccessoryBarItems) { item in
153 | switch item {
154 | case .space:
155 | spaceButtonForLeftRight
156 | case .backspace:
157 | backspaceButton
158 | case .hide:
159 | hideKeyboardButton
160 | case .spacer:
161 | Spacer()
162 | }
163 | }
164 | }
165 | .padding(.leading, accessoryBarPosition == .leading ? 8 : 0)
166 | .padding(.top, 8)
167 | .padding(.trailing, accessoryBarPosition == .trailing ? 8 : 0)
168 | }
169 | }
170 |
--------------------------------------------------------------------------------
/keyboard/KeyboardView.swift:
--------------------------------------------------------------------------------
1 | //
2 | // KeyboardView.swift
3 | // keyboard
4 | //
5 | // Created by Zachary Gorak on 10/12/22.
6 | //
7 |
8 | import SwiftUI
9 | import UIKit
10 |
11 | struct ViewWrapper: UIViewRepresentable {
12 | var view: UIView
13 |
14 | func makeUIView(context: Context) -> UIView {
15 | view
16 | }
17 |
18 | func updateUIView(_ uiView: UIView, context: Context) {
19 | // no-op
20 | }
21 | }
22 |
23 | struct KeyboardView: View {
24 | var parent: KeyboardViewController
25 | @Binding var needsInputModeSwitchKey: Bool
26 |
27 | @State var text = "k"
28 |
29 | @AppStorage("keyboardOptions", store: .init(suiteName: "group.com.twodayslate.k")) var textOptions = DEFAULT_KEYBOARD_OPTIONS
30 | @AppStorage("showHideKeyboard", store: .init(suiteName: "group.com.twodayslate.k")) var showHideKeyboard = false
31 | @AppStorage("swipeKeyboardKeyWordList", store: .init(suiteName: "group.com.twodayslate.k")) var swipeKeyWordList = false
32 | @AppStorage("enabledAccessoryBarItems", store: .init(suiteName: "group.com.twodayslate.k")) var enabledAccessoryBarItems = [AccessoryBarItem]()
33 | @AppStorage("accessoryBarPosition", store: .init(suiteName: "group.com.twodayslate.k")) var accessoryBarPosition: Position = .trailing
34 | @AppStorage("wordListBarPosition", store: .init(suiteName: "group.com.twodayslate.k")) var wordListBarPosition: Position = .bottom
35 | @AppStorage("showWordListBarDivider", store: .init(suiteName: "group.com.twodayslate.k")) var showWordListBarDivider = false
36 | @AppStorage("useLastUsedWord", store: .init(suiteName: "group.com.twodayslate.k")) var useLastUsedWord = false
37 | @AppStorage("lastUsedWord", store: .init(suiteName: "group.com.twodayslate.k")) var lastUsedWord = ""
38 |
39 | @AppStorage("keyboardSoundEnabled", store: .init(suiteName: "group.com.twodayslate.k")) var keyboardSoundEnabled = false
40 | @AppStorage("keyboardHapticsEnabled", store: .init(suiteName: "group.com.twodayslate.k")) var keyboardHapticsEnabled = false
41 | @AppStorage("keyboardHapticsStyle", store: .init(suiteName: "group.com.twodayslate.k")) var keyboardHapticsStyle: UIImpactFeedbackGenerator.FeedbackStyle = .rigid
42 | @AppStorage("keyboardHapticsIntensity", store: .init(suiteName: "group.com.twodayslate.k")) var keyboardHapticsIntensity = 1.0
43 |
44 | @Environment(\.colorScheme) var colorScheme
45 |
46 | func action(_ text: String) {
47 | lastUsedWord = text
48 | if keyboardSoundEnabled {
49 | AudioServicesPlaySystemSound(.normal);
50 | }
51 | if keyboardHapticsEnabled {
52 | UIImpactFeedbackGenerator(style: keyboardHapticsStyle)
53 | .impactOccurred(intensity: keyboardHapticsIntensity)
54 | }
55 | parent.textDocumentProxy.insertText(text)
56 | }
57 |
58 | var gesture: SimultaneousGesture, _EndedGesture>, _EndedGesture> {
59 | let tap = TapGesture(count: 1)
60 | .onEnded { value in
61 | action(text)
62 | }
63 | return DragGesture(minimumDistance: 10, coordinateSpace: .local)
64 | .onEnded { value in
65 | print("got value", value)
66 | // ensure gesture is enabled
67 | guard swipeKeyWordList else { return }
68 | // ensure the gesture isn't diagnol
69 | guard value.translation.height < 15 else {
70 | return
71 | }
72 | guard value.translation.height > -15 else {
73 | return
74 | }
75 | let index = textOptions.firstIndex(of: text) ?? 0
76 | if value.translation.width < 0 {
77 | let newIndex = max(0, textOptions.index(before: index))
78 | text = textOptions[newIndex]
79 | }
80 | if value.translation.width > 0 {
81 | let newIndex = max(min(textOptions.index(after: index), textOptions.count - 1), 0)
82 | text = textOptions[newIndex]
83 | }
84 | }
85 | .exclusively(
86 | before: tap
87 | )
88 | .simultaneously(
89 | with: tap
90 | )
91 | }
92 |
93 | var accessoryBarEnabled: Bool {
94 | enabledAccessoryBarItems.count > 0
95 | }
96 |
97 | var accessoryBar: some View {
98 | AccessoryBarView(parent: parent)
99 | }
100 |
101 | var wordListBar: some View {
102 | WordListView(parent: parent, needsInputModeSwitchKey: $needsInputModeSwitchKey, text: $text)
103 | }
104 |
105 | var body: some View {
106 | VStack(spacing: 0) {
107 | if wordListBarPosition == .top {
108 | wordListBar
109 | if showWordListBarDivider {
110 | Divider()
111 | }
112 | }
113 |
114 | VStack(spacing: 0) {
115 | if accessoryBarEnabled, accessoryBarPosition == .top {
116 | accessoryBar
117 | }
118 | HStack {
119 | if accessoryBarPosition == .leading, accessoryBarEnabled {
120 | accessoryBar
121 | }
122 | Button {
123 | lastUsedWord = text
124 | action(text)
125 | } label: {
126 | Text(text)
127 | .padding()
128 | .font(.title)
129 | .minimumScaleFactor(0.1)
130 | .frame(maxWidth: .infinity, maxHeight: .infinity)
131 | }
132 | .buttonStyle(KeyboardButton(accessory: false))
133 | .padding(.leading, (accessoryBarEnabled && accessoryBarPosition == .leading) ? 0 : 8)
134 | .padding(.top, 8)
135 | .padding(.trailing, accessoryBarEnabled && accessoryBarPosition == .trailing ? 0 : 8)
136 | .layoutPriority(1.0)
137 | if accessoryBarEnabled, accessoryBarPosition == .trailing {
138 | accessoryBar
139 | }
140 | }
141 | .layoutPriority(1.0)
142 |
143 | if accessoryBarEnabled, accessoryBarPosition == .bottom {
144 | accessoryBar
145 | }
146 | }
147 | .padding(.bottom, wordListBarPosition == .top ? 8 : 0)
148 |
149 | if wordListBarPosition != .top {
150 | if showWordListBarDivider {
151 | Divider()
152 | .padding(.top, 8)
153 | }
154 | wordListBar
155 | }
156 | }
157 | .onAppear {
158 | if useLastUsedWord {
159 | if !lastUsedWord.isEmpty {
160 | text = lastUsedWord
161 | return
162 | }
163 | }
164 | text = textOptions.first ?? "k"
165 | }
166 | }
167 | }
168 |
--------------------------------------------------------------------------------
/k/SettingsView.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SettingsView.swift
3 | // k
4 | //
5 | // Created by Zachary Gorak on 10/13/22.
6 | //
7 |
8 | import SwiftUI
9 |
10 | struct SettingsView: View {
11 | @AppStorage("keyboardOptions", store: .init(suiteName: "group.com.twodayslate.k")) var keyboardOptions = DEFAULT_KEYBOARD_OPTIONS
12 | @AppStorage("showHideKeyboard", store: .init(suiteName: "group.com.twodayslate.k")) var showHideKeyboard = false
13 | @AppStorage("accessoryBarPosition", store: .init(suiteName: "group.com.twodayslate.k")) var accessoryBarPosition = Position.trailing
14 | @AppStorage("spaceBarTextEnabled", store: .init(suiteName: "group.com.twodayslate.k")) var spaceBarTextEnabled = true
15 | @AppStorage("enabledAccessoryBarItems", store: .init(suiteName: "group.com.twodayslate.k")) var enabledAccessoryBarItems = [AccessoryBarItem]()
16 | @AppStorage("enabledWordListBarItems", store: .init(suiteName: "group.com.twodayslate.k")) var enabledWordListBarItems: [WordListBarItem] = DEFAULT_WORDLIST_BAR_ITEMS
17 | @AppStorage("wordListBarPosition", store: .init(suiteName: "group.com.twodayslate.k")) var wordListBarPosition: Position = .bottom
18 | @AppStorage("showWordListBarDivider", store: .init(suiteName: "group.com.twodayslate.k")) var showWordListBarDivider = false
19 | @AppStorage("useLastUsedWord", store: .init(suiteName: "group.com.twodayslate.k")) var useLastUsedWord = false
20 | @AppStorage("lastUsedWord", store: .init(suiteName: "group.com.twodayslate.k")) var lastUsedWord = ""
21 | @AppStorage("keyboardSoundEnabled", store: .init(suiteName: "group.com.twodayslate.k")) var keyboardSoundEnabled = false
22 | @AppStorage("keyboardHapticsEnabled", store: .init(suiteName: "group.com.twodayslate.k")) var keyboardHapticsEnabled = false
23 | @AppStorage("keyboardHapticsStyle", store: .init(suiteName: "group.com.twodayslate.k")) var keyboardHapticsStyle: UIImpactFeedbackGenerator.FeedbackStyle = .rigid
24 | @AppStorage("keyboardHapticsIntensity", store: .init(suiteName: "group.com.twodayslate.k")) var keyboardHapticsIntensity = 1.0
25 |
26 | @State var newItem = ""
27 | @FocusState private var nameIsFocused: Bool
28 |
29 | var body: some View {
30 | List {
31 | Section("Keyboard Feedback") {
32 | // Sound
33 | Toggle(isOn: $keyboardSoundEnabled, label: {
34 | Text("Sound")
35 | })
36 | .onChange(of: keyboardSoundEnabled, perform: { _ in
37 | withAnimation {
38 | nameIsFocused = false
39 | }
40 | })
41 |
42 | // Haptic
43 | VStack {
44 | Toggle(isOn: $keyboardHapticsEnabled, label: {
45 | Text("Haptics")
46 | })
47 | .onChange(of: keyboardHapticsEnabled, perform: { _ in
48 | withAnimation {
49 | nameIsFocused = false
50 | }
51 | })
52 | Text("Requires full access!")
53 | .font(.footnote)
54 | .foregroundColor(.gray)
55 | }
56 |
57 | if keyboardHapticsEnabled {
58 | Picker("Haptic Style", selection: $keyboardHapticsStyle) {
59 | ForEach(UIImpactFeedbackGenerator.FeedbackStyle.allCases) { style in
60 | Text("\(style.description)")
61 | .tag(style)
62 | }
63 | }
64 | .onChange(of: keyboardHapticsStyle) { _ in
65 | withAnimation {
66 | nameIsFocused = false
67 | }
68 | }
69 |
70 | VStack(alignment: .leading) {
71 | HStack {
72 | Text("Haptic Intensity")
73 | Spacer()
74 | Text("\(keyboardHapticsIntensity)")
75 | .foregroundColor(.gray)
76 | }
77 | Slider(
78 | value: $keyboardHapticsIntensity,
79 | in: 0...1.0,
80 | label: {
81 | Text("Haptic Intensity")
82 | },
83 | minimumValueLabel: {
84 | Text("0.0")
85 | },
86 | maximumValueLabel: {
87 | Text("1.0")
88 | }
89 | )
90 | .onChange(of: keyboardHapticsIntensity) { _ in
91 | withAnimation {
92 | nameIsFocused = false
93 | }
94 | }
95 | }
96 | }
97 | }
98 | Section("Word List") {
99 | ForEach(keyboardOptions, id: \.self) { item in
100 | if item == keyboardOptions.first {
101 | HStack {
102 | Text("\(item)")
103 | Spacer()
104 | Image(systemName: "star.fill")
105 | .foregroundColor(Color.yellow)
106 | }
107 | } else {
108 | Text("\(item)")
109 | }
110 | }
111 | .onDelete { offsets in
112 | withAnimation { [offsets] in
113 | keyboardOptions.remove(atOffsets: offsets)
114 | nameIsFocused = false
115 |
116 | if keyboardOptions.isEmpty {
117 | keyboardOptions.append(DEFAULT_KEYBOARD_OPTIONS.first ?? "k")
118 | }
119 | }
120 | lastUsedWord = ""
121 | }
122 | .onMove { from, to in
123 | withAnimation { [from, to] in
124 | keyboardOptions.move(fromOffsets: from, toOffset: to)
125 | nameIsFocused = false
126 | }
127 | }
128 | HStack {
129 | TextField("New Item", text: $newItem)
130 | .focused($nameIsFocused)
131 | Button {
132 | withAnimation {
133 | guard !newItem.isEmpty else { return }
134 | guard !keyboardOptions.contains(newItem) else { return }
135 | keyboardOptions.append(newItem)
136 | nameIsFocused = false
137 | newItem = ""
138 | }
139 | } label: {
140 | Image(systemName: "plus")
141 | }
142 | .disabled(newItem.isEmpty || keyboardOptions.contains(newItem))
143 | }
144 | }
145 |
146 | Section("Word List Bar") {
147 | ForEach(enabledWordListBarItems) { item in
148 | Text("\(item.name)")
149 | }
150 | .onMove(perform: { from, to in
151 | withAnimation {
152 | enabledWordListBarItems.move(fromOffsets: from, toOffset: to)
153 | nameIsFocused = false
154 | }
155 | })
156 | }
157 |
158 | Section {
159 | Toggle(isOn: $showHideKeyboard, label: {
160 | Text("Show 'Hide Keyboard' Button")
161 | })
162 | .onChange(of: showHideKeyboard, perform: { value in
163 | withAnimation {
164 | if value {
165 | enabledWordListBarItems.append(.hide)
166 | } else {
167 | enabledWordListBarItems.removeAll(where: { $0 == .hide })
168 | }
169 | nameIsFocused = false
170 | }
171 | })
172 | Toggle(isOn: $showWordListBarDivider, label: {
173 | Text("Show Divider")
174 | })
175 | .onChange(of: showWordListBarDivider, perform: { value in
176 | withAnimation {
177 | nameIsFocused = false
178 | }
179 | })
180 | Toggle(isOn: $useLastUsedWord, label: {
181 | Text("Show last used word")
182 | })
183 | .onChange(of: useLastUsedWord, perform: { value in
184 | if !value {
185 | lastUsedWord = ""
186 | }
187 | withAnimation {
188 | nameIsFocused = false
189 | }
190 | })
191 | Picker("Position", selection: $wordListBarPosition) {
192 | ForEach([Position.top, Position.bottom]) { item in
193 | Text("\(item.name)")
194 | .tag(item)
195 |
196 | }
197 | }
198 | .pickerStyle(.automatic)
199 | }
200 |
201 | Section("Accessory Bar") {
202 | ForEach(enabledAccessoryBarItems) { item in
203 | Text("\(item.name)")
204 | }
205 | .onDelete(perform: { offsets in
206 | withAnimation {
207 | enabledAccessoryBarItems.remove(atOffsets: offsets)
208 | nameIsFocused = false
209 | }
210 | })
211 | .onMove(perform: { from, to in
212 | withAnimation {
213 | enabledAccessoryBarItems.move(fromOffsets: from, toOffset: to)
214 | nameIsFocused = false
215 | }
216 | })
217 |
218 | ForEach(AccessoryBarItem.allCases) { item in
219 | if !enabledAccessoryBarItems.contains(item) {
220 | Button {
221 | enabledAccessoryBarItems.append(item)
222 | } label: {
223 | HStack {
224 | Text("\(item.name)")
225 | Spacer()
226 | Image(systemName: "plus")
227 | }
228 | }
229 | }
230 | }
231 | }
232 |
233 | if enabledAccessoryBarItems.contains(.space) {
234 | Toggle(isOn: $spaceBarTextEnabled, label: {
235 | Text("Spacebar text")
236 | })
237 | .onChange(of: spaceBarTextEnabled) { value in
238 | withAnimation {
239 | nameIsFocused = false
240 | }
241 | }
242 | }
243 |
244 | if enabledAccessoryBarItems.count > 0 {
245 | Section("Accessory Bar Location") {
246 | accessoryBarLocation
247 | .padding()
248 | }
249 | }
250 |
251 | Section {
252 | Button {
253 | reset()
254 | nameIsFocused = false
255 | } label: {
256 | HStack {
257 | Spacer()
258 | Text("Reset")
259 | Spacer()
260 | }
261 | }
262 | }
263 | }
264 | .listStyle(.grouped)
265 | .navigationTitle("Settings")
266 | .toolbar {
267 | EditButton()
268 | }
269 | }
270 |
271 | func reset() {
272 | keyboardOptions = DEFAULT_KEYBOARD_OPTIONS
273 | showHideKeyboard = false
274 | accessoryBarPosition = .trailing
275 | enabledAccessoryBarItems.removeAll()
276 | enabledWordListBarItems = DEFAULT_WORDLIST_BAR_ITEMS
277 | showWordListBarDivider = false
278 | keyboardSoundEnabled = false
279 | keyboardHapticsEnabled = false
280 | keyboardHapticsStyle = .rigid
281 | keyboardHapticsIntensity = 1.0
282 | lastUsedWord = ""
283 | useLastUsedWord = false
284 | wordListBarPosition = .bottom
285 | spaceBarTextEnabled = true
286 | }
287 |
288 | @ViewBuilder
289 | var accessoryBarLocation: some View {
290 | VStack(spacing: 4) {
291 | if wordListBarPosition == .top {
292 | Button {
293 | // no-op
294 | } label: {
295 | Text("Word List Bar")
296 | .frame(maxWidth: .infinity)
297 | .padding(.vertical, 4)
298 | .background {
299 | RoundedRectangle(cornerRadius: 8)
300 | .strokeBorder(Color.gray)
301 | }
302 | }
303 | .buttonStyle(.borderless)
304 | .disabled(true)
305 |
306 | if showWordListBarDivider {
307 | Divider()
308 | }
309 | }
310 | Button {
311 | accessoryBarPosition = .top
312 | nameIsFocused = false
313 | } label: {
314 | Text("Top")
315 | .foregroundColor(accessoryBarPosition == .top ? .white : .accentColor)
316 | .frame(maxWidth: .infinity)
317 | .padding(.vertical, 4)
318 | .background {
319 | RoundedRectangle(cornerRadius: 8)
320 | .fill(accessoryBarPosition == .top ? Color.accentColor : .clear, strokeBorder: Color.accentColor)
321 |
322 | }
323 | }
324 | .buttonStyle(.borderless)
325 | HStack(spacing: 4) {
326 | Button {
327 | accessoryBarPosition = .leading
328 | nameIsFocused = false
329 | } label: {
330 | Text("Left")
331 | .foregroundColor(accessoryBarPosition == .leading ? .white : .accentColor)
332 | .frame(minHeight: 80, maxHeight: .infinity)
333 | .padding(.horizontal, 4)
334 | .background {
335 | RoundedRectangle(cornerRadius: 8)
336 | .fill(accessoryBarPosition == .leading ? Color.accentColor : .clear, strokeBorder: Color.accentColor)
337 | }
338 | }
339 | .buttonStyle(.borderless)
340 | Button {
341 | // no-op
342 | } label: {
343 | Text(keyboardOptions.first ?? "k")
344 | .frame(maxWidth: .infinity, minHeight: 80, maxHeight: .infinity)
345 | .background {
346 | RoundedRectangle(cornerRadius: 8)
347 | .strokeBorder(Color(UIColor.gray))
348 | }
349 | }
350 | .buttonStyle(.borderless)
351 | .disabled(true)
352 |
353 | Button {
354 | accessoryBarPosition = .trailing
355 | nameIsFocused = false
356 | } label: {
357 | Text("Right")
358 | .foregroundColor(accessoryBarPosition == .trailing ? .white : .accentColor)
359 | .frame(minHeight: 80, maxHeight: .infinity)
360 | .padding(.horizontal, 4)
361 | .background {
362 | RoundedRectangle(cornerRadius: 8)
363 | .fill(accessoryBarPosition == .trailing ? Color.accentColor : .clear, strokeBorder: Color.accentColor)
364 | }
365 | }
366 | .buttonStyle(.borderless)
367 | }
368 | Button {
369 | accessoryBarPosition = .bottom
370 | nameIsFocused = false
371 | } label: {
372 | Text("Bottom")
373 | .foregroundColor(accessoryBarPosition == .bottom ? .white : .accentColor)
374 | .frame(maxWidth: .infinity)
375 | .padding(.vertical, 4)
376 | .background {
377 | RoundedRectangle(cornerRadius: 8)
378 | .fill(accessoryBarPosition == .bottom ? Color.accentColor : .clear, strokeBorder: Color.accentColor)
379 |
380 | }
381 | }
382 | .buttonStyle(.borderless)
383 |
384 | if wordListBarPosition != .top {
385 | if showWordListBarDivider {
386 | Divider()
387 | }
388 | Button {
389 | // no-op
390 | } label: {
391 | Text("Word List Bar")
392 | .frame(maxWidth: .infinity)
393 | .padding(.vertical, 4)
394 | .background {
395 | RoundedRectangle(cornerRadius: 8)
396 | .strokeBorder(Color.gray)
397 | }
398 | }
399 | .buttonStyle(.borderless)
400 | .disabled(true)
401 | }
402 | }
403 | }
404 | }
405 |
406 | struct SettingsViewPreview: PreviewProvider {
407 | static var previews: some View {
408 | SettingsView()
409 | }
410 | }
411 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | # Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International
2 |
3 | Creative Commons Corporation (“Creative Commons”) is not a law firm and does not provide legal services or legal advice. Distribution of Creative Commons public licenses does not create a lawyer-client or other relationship. Creative Commons makes its licenses and related information available on an “as-is” basis. Creative Commons gives no warranties regarding its licenses, any material licensed under their terms and conditions, or any related information. Creative Commons disclaims all liability for damages resulting from their use to the fullest extent possible.
4 |
5 | ### Using Creative Commons Public Licenses
6 |
7 | Creative Commons public licenses provide a standard set of terms and conditions that creators and other rights holders may use to share original works of authorship and other material subject to copyright and certain other rights specified in the public license below. The following considerations are for informational purposes only, are not exhaustive, and do not form part of our licenses.
8 |
9 | * __Considerations for licensors:__ Our public licenses are intended for use by those authorized to give the public permission to use material in ways otherwise restricted by copyright and certain other rights. Our licenses are irrevocable. Licensors should read and understand the terms and conditions of the license they choose before applying it. Licensors should also secure all rights necessary before applying our licenses so that the public can reuse the material as expected. Licensors should clearly mark any material not subject to the license. This includes other CC-licensed material, or material used under an exception or limitation to copyright. [More considerations for licensors](http://wiki.creativecommons.org/Considerations_for_licensors_and_licensees#Considerations_for_licensors).
10 |
11 | * __Considerations for the public:__ By using one of our public licenses, a licensor grants the public permission to use the licensed material under specified terms and conditions. If the licensor’s permission is not necessary for any reason–for example, because of any applicable exception or limitation to copyright–then that use is not regulated by the license. Our licenses grant only permissions under copyright and certain other rights that a licensor has authority to grant. Use of the licensed material may still be restricted for other reasons, including because others have copyright or other rights in the material. A licensor may make special requests, such as asking that all changes be marked or described. Although not required by our licenses, you are encouraged to respect those requests where reasonable. [More considerations for the public](http://wiki.creativecommons.org/Considerations_for_licensors_and_licensees#Considerations_for_licensees).
12 |
13 | ## Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International Public License
14 |
15 | By exercising the Licensed Rights (defined below), You accept and agree to be bound by the terms and conditions of this Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International Public License ("Public License"). To the extent this Public License may be interpreted as a contract, You are granted the Licensed Rights in consideration of Your acceptance of these terms and conditions, and the Licensor grants You such rights in consideration of benefits the Licensor receives from making the Licensed Material available under these terms and conditions.
16 |
17 | ### Section 1 – Definitions.
18 |
19 | a. __Adapted Material__ means material subject to Copyright and Similar Rights that is derived from or based upon the Licensed Material and in which the Licensed Material is translated, altered, arranged, transformed, or otherwise modified in a manner requiring permission under the Copyright and Similar Rights held by the Licensor. For purposes of this Public License, where the Licensed Material is a musical work, performance, or sound recording, Adapted Material is always produced where the Licensed Material is synched in timed relation with a moving image.
20 |
21 | b. __Adapter's License__ means the license You apply to Your Copyright and Similar Rights in Your contributions to Adapted Material in accordance with the terms and conditions of this Public License.
22 |
23 | c. __BY-NC-SA Compatible License__ means a license listed at [creativecommons.org/compatiblelicenses](http://creativecommons.org/compatiblelicenses), approved by Creative Commons as essentially the equivalent of this Public License.
24 |
25 | d. __Copyright and Similar Rights__ means copyright and/or similar rights closely related to copyright including, without limitation, performance, broadcast, sound recording, and Sui Generis Database Rights, without regard to how the rights are labeled or categorized. For purposes of this Public License, the rights specified in Section 2(b)(1)-(2) are not Copyright and Similar Rights.
26 |
27 | e. __Effective Technological Measures__ means those measures that, in the absence of proper authority, may not be circumvented under laws fulfilling obligations under Article 11 of the WIPO Copyright Treaty adopted on December 20, 1996, and/or similar international agreements.
28 |
29 | f. __Exceptions and Limitations__ means fair use, fair dealing, and/or any other exception or limitation to Copyright and Similar Rights that applies to Your use of the Licensed Material.
30 |
31 | g. __License Elements__ means the license attributes listed in the name of a Creative Commons Public License. The License Elements of this Public License are Attribution, NonCommercial, and ShareAlike.
32 |
33 | h. __Licensed Material__ means the artistic or literary work, database, or other material to which the Licensor applied this Public License.
34 |
35 | i. __Licensed Rights__ means the rights granted to You subject to the terms and conditions of this Public License, which are limited to all Copyright and Similar Rights that apply to Your use of the Licensed Material and that the Licensor has authority to license.
36 |
37 | j. __Licensor__ means the individual(s) or entity(ies) granting rights under this Public License.
38 |
39 | k. __NonCommercial__ means not primarily intended for or directed towards commercial advantage or monetary compensation. For purposes of this Public License, the exchange of the Licensed Material for other material subject to Copyright and Similar Rights by digital file-sharing or similar means is NonCommercial provided there is no payment of monetary compensation in connection with the exchange.
40 |
41 | l. __Share__ means to provide material to the public by any means or process that requires permission under the Licensed Rights, such as reproduction, public display, public performance, distribution, dissemination, communication, or importation, and to make material available to the public including in ways that members of the public may access the material from a place and at a time individually chosen by them.
42 |
43 | m. __Sui Generis Database Rights__ means rights other than copyright resulting from Directive 96/9/EC of the European Parliament and of the Council of 11 March 1996 on the legal protection of databases, as amended and/or succeeded, as well as other essentially equivalent rights anywhere in the world.
44 |
45 | n. __You__ means the individual or entity exercising the Licensed Rights under this Public License. __Your__ has a corresponding meaning.
46 |
47 | ### Section 2 – Scope.
48 |
49 | a. ___License grant.___
50 |
51 | 1. Subject to the terms and conditions of this Public License, the Licensor hereby grants You a worldwide, royalty-free, non-sublicensable, non-exclusive, irrevocable license to exercise the Licensed Rights in the Licensed Material to:
52 |
53 | A. reproduce and Share the Licensed Material, in whole or in part, for NonCommercial purposes only; and
54 |
55 | B. produce, reproduce, and Share Adapted Material for NonCommercial purposes only.
56 |
57 | 2. __Exceptions and Limitations.__ For the avoidance of doubt, where Exceptions and Limitations apply to Your use, this Public License does not apply, and You do not need to comply with its terms and conditions.
58 |
59 | 3. __Term.__ The term of this Public License is specified in Section 6(a).
60 |
61 | 4. __Media and formats; technical modifications allowed.__ The Licensor authorizes You to exercise the Licensed Rights in all media and formats whether now known or hereafter created, and to make technical modifications necessary to do so. The Licensor waives and/or agrees not to assert any right or authority to forbid You from making technical modifications necessary to exercise the Licensed Rights, including technical modifications necessary to circumvent Effective Technological Measures. For purposes of this Public License, simply making modifications authorized by this Section 2(a)(4) never produces Adapted Material.
62 |
63 | 5. __Downstream recipients.__
64 |
65 | A. __Offer from the Licensor – Licensed Material.__ Every recipient of the Licensed Material automatically receives an offer from the Licensor to exercise the Licensed Rights under the terms and conditions of this Public License.
66 |
67 | B. __Additional offer from the Licensor – Adapted Material.__ Every recipient of Adapted Material from You automatically receives an offer from the Licensor to exercise the Licensed Rights in the Adapted Material under the conditions of the Adapter’s License You apply.
68 |
69 | C. __No downstream restrictions.__ You may not offer or impose any additional or different terms or conditions on, or apply any Effective Technological Measures to, the Licensed Material if doing so restricts exercise of the Licensed Rights by any recipient of the Licensed Material.
70 |
71 | 6. __No endorsement.__ Nothing in this Public License constitutes or may be construed as permission to assert or imply that You are, or that Your use of the Licensed Material is, connected with, or sponsored, endorsed, or granted official status by, the Licensor or others designated to receive attribution as provided in Section 3(a)(1)(A)(i).
72 |
73 | b. ___Other rights.___
74 |
75 | 1. Moral rights, such as the right of integrity, are not licensed under this Public License, nor are publicity, privacy, and/or other similar personality rights; however, to the extent possible, the Licensor waives and/or agrees not to assert any such rights held by the Licensor to the limited extent necessary to allow You to exercise the Licensed Rights, but not otherwise.
76 |
77 | 2. Patent and trademark rights are not licensed under this Public License.
78 |
79 | 3. To the extent possible, the Licensor waives any right to collect royalties from You for the exercise of the Licensed Rights, whether directly or through a collecting society under any voluntary or waivable statutory or compulsory licensing scheme. In all other cases the Licensor expressly reserves any right to collect such royalties, including when the Licensed Material is used other than for NonCommercial purposes.
80 |
81 | ### Section 3 – License Conditions.
82 |
83 | Your exercise of the Licensed Rights is expressly made subject to the following conditions.
84 |
85 | a. ___Attribution.___
86 |
87 | 1. If You Share the Licensed Material (including in modified form), You must:
88 |
89 | A. retain the following if it is supplied by the Licensor with the Licensed Material:
90 |
91 | i. identification of the creator(s) of the Licensed Material and any others designated to receive attribution, in any reasonable manner requested by the Licensor (including by pseudonym if designated);
92 |
93 | ii. a copyright notice;
94 |
95 | iii. a notice that refers to this Public License;
96 |
97 | iv. a notice that refers to the disclaimer of warranties;
98 |
99 | v. a URI or hyperlink to the Licensed Material to the extent reasonably practicable;
100 |
101 | B. indicate if You modified the Licensed Material and retain an indication of any previous modifications; and
102 |
103 | C. indicate the Licensed Material is licensed under this Public License, and include the text of, or the URI or hyperlink to, this Public License.
104 |
105 | 2. You may satisfy the conditions in Section 3(a)(1) in any reasonable manner based on the medium, means, and context in which You Share the Licensed Material. For example, it may be reasonable to satisfy the conditions by providing a URI or hyperlink to a resource that includes the required information.
106 |
107 | 3. If requested by the Licensor, You must remove any of the information required by Section 3(a)(1)(A) to the extent reasonably practicable.
108 |
109 | b. ___ShareAlike.___
110 |
111 | In addition to the conditions in Section 3(a), if You Share Adapted Material You produce, the following conditions also apply.
112 |
113 | 1. The Adapter’s License You apply must be a Creative Commons license with the same License Elements, this version or later, or a BY-NC-SA Compatible License.
114 |
115 | 2. You must include the text of, or the URI or hyperlink to, the Adapter's License You apply. You may satisfy this condition in any reasonable manner based on the medium, means, and context in which You Share Adapted Material.
116 |
117 | 3. You may not offer or impose any additional or different terms or conditions on, or apply any Effective Technological Measures to, Adapted Material that restrict exercise of the rights granted under the Adapter's License You apply.
118 |
119 | ### Section 4 – Sui Generis Database Rights.
120 |
121 | Where the Licensed Rights include Sui Generis Database Rights that apply to Your use of the Licensed Material:
122 |
123 | a. for the avoidance of doubt, Section 2(a)(1) grants You the right to extract, reuse, reproduce, and Share all or a substantial portion of the contents of the database for NonCommercial purposes only;
124 |
125 | b. if You include all or a substantial portion of the database contents in a database in which You have Sui Generis Database Rights, then the database in which You have Sui Generis Database Rights (but not its individual contents) is Adapted Material, including for purposes of Section 3(b); and
126 |
127 | c. You must comply with the conditions in Section 3(a) if You Share all or a substantial portion of the contents of the database.
128 |
129 | For the avoidance of doubt, this Section 4 supplements and does not replace Your obligations under this Public License where the Licensed Rights include other Copyright and Similar Rights.
130 |
131 | ### Section 5 – Disclaimer of Warranties and Limitation of Liability.
132 |
133 | a. __Unless otherwise separately undertaken by the Licensor, to the extent possible, the Licensor offers the Licensed Material as-is and as-available, and makes no representations or warranties of any kind concerning the Licensed Material, whether express, implied, statutory, or other. This includes, without limitation, warranties of title, merchantability, fitness for a particular purpose, non-infringement, absence of latent or other defects, accuracy, or the presence or absence of errors, whether or not known or discoverable. Where disclaimers of warranties are not allowed in full or in part, this disclaimer may not apply to You.__
134 |
135 | b. __To the extent possible, in no event will the Licensor be liable to You on any legal theory (including, without limitation, negligence) or otherwise for any direct, special, indirect, incidental, consequential, punitive, exemplary, or other losses, costs, expenses, or damages arising out of this Public License or use of the Licensed Material, even if the Licensor has been advised of the possibility of such losses, costs, expenses, or damages. Where a limitation of liability is not allowed in full or in part, this limitation may not apply to You.__
136 |
137 | c. The disclaimer of warranties and limitation of liability provided above shall be interpreted in a manner that, to the extent possible, most closely approximates an absolute disclaimer and waiver of all liability.
138 |
139 | ### Section 6 – Term and Termination.
140 |
141 | a. This Public License applies for the term of the Copyright and Similar Rights licensed here. However, if You fail to comply with this Public License, then Your rights under this Public License terminate automatically.
142 |
143 | b. Where Your right to use the Licensed Material has terminated under Section 6(a), it reinstates:
144 |
145 | 1. automatically as of the date the violation is cured, provided it is cured within 30 days of Your discovery of the violation; or
146 |
147 | 2. upon express reinstatement by the Licensor.
148 |
149 | For the avoidance of doubt, this Section 6(b) does not affect any right the Licensor may have to seek remedies for Your violations of this Public License.
150 |
151 | c. For the avoidance of doubt, the Licensor may also offer the Licensed Material under separate terms or conditions or stop distributing the Licensed Material at any time; however, doing so will not terminate this Public License.
152 |
153 | d. Sections 1, 5, 6, 7, and 8 survive termination of this Public License.
154 |
155 | ### Section 7 – Other Terms and Conditions.
156 |
157 | a. The Licensor shall not be bound by any additional or different terms or conditions communicated by You unless expressly agreed.
158 |
159 | b. Any arrangements, understandings, or agreements regarding the Licensed Material not stated herein are separate from and independent of the terms and conditions of this Public License.
160 |
161 | ### Section 8 – Interpretation.
162 |
163 | a. For the avoidance of doubt, this Public License does not, and shall not be interpreted to, reduce, limit, restrict, or impose conditions on any use of the Licensed Material that could lawfully be made without permission under this Public License.
164 |
165 | b. To the extent possible, if any provision of this Public License is deemed unenforceable, it shall be automatically reformed to the minimum extent necessary to make it enforceable. If the provision cannot be reformed, it shall be severed from this Public License without affecting the enforceability of the remaining terms and conditions.
166 |
167 | c. No term or condition of this Public License will be waived and no failure to comply consented to unless expressly agreed to by the Licensor.
168 |
169 | d. Nothing in this Public License constitutes or may be interpreted as a limitation upon, or waiver of, any privileges and immunities that apply to the Licensor or You, including from the legal processes of any jurisdiction or authority.
170 |
171 | > Creative Commons is not a party to its public licenses. Notwithstanding, Creative Commons may elect to apply one of its public licenses to material it publishes and in those instances will be considered the “Licensor.” Except for the limited purpose of indicating that material is shared under a Creative Commons public license or as otherwise permitted by the Creative Commons policies published at [creativecommons.org/policies](http://creativecommons.org/policies), Creative Commons does not authorize the use of the trademark “Creative Commons” or any other trademark or logo of Creative Commons without its prior written consent including, without limitation, in connection with any unauthorized modifications to any of its public licenses or any other arrangements, understandings, or agreements concerning use of licensed material. For the avoidance of doubt, this paragraph does not form part of the public licenses.
172 | >
173 | > Creative Commons may be contacted at creativecommons.org
174 |
--------------------------------------------------------------------------------
/k.xcodeproj/project.pbxproj:
--------------------------------------------------------------------------------
1 | // !$*UTF8*$!
2 | {
3 | archiveVersion = 1;
4 | classes = {
5 | };
6 | objectVersion = 56;
7 | objects = {
8 |
9 | /* Begin PBXBuildFile section */
10 | F615B8AC28F7DAA000FC4730 /* Array+Codable.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8AB28F7DAA000FC4730 /* Array+Codable.swift */; };
11 | F615B8AD28F7DAF600FC4730 /* Array+Codable.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8AB28F7DAA000FC4730 /* Array+Codable.swift */; };
12 | F615B8AF28F7DBEE00FC4730 /* SettingsView.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8AE28F7DBEE00FC4730 /* SettingsView.swift */; };
13 | F615B8BC28FDDA9C00FC4730 /* Shape+strokeFill.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8BB28FDDA9C00FC4730 /* Shape+strokeFill.swift */; };
14 | F615B8BD28FDDAAE00FC4730 /* Shape+strokeFill.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8BB28FDDA9C00FC4730 /* Shape+strokeFill.swift */; };
15 | F615B8BF28FDDB8500FC4730 /* KeyboardButtonStyle.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8BE28FDDB8500FC4730 /* KeyboardButtonStyle.swift */; };
16 | F615B8C028FDDB8C00FC4730 /* KeyboardButtonStyle.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8BE28FDDB8500FC4730 /* KeyboardButtonStyle.swift */; };
17 | F615B8C228FDE06800FC4730 /* AccessoryBarItem.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8C128FDE06800FC4730 /* AccessoryBarItem.swift */; };
18 | F615B8C328FDE09A00FC4730 /* AccessoryBarItem.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8C128FDE06800FC4730 /* AccessoryBarItem.swift */; };
19 | F615B8C528FDED8900FC4730 /* AccessoryBarView.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8C428FDED8900FC4730 /* AccessoryBarView.swift */; };
20 | F615B8C728FDEF3100FC4730 /* WordListBarItem.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8C628FDEF3100FC4730 /* WordListBarItem.swift */; };
21 | F615B8C828FDF01100FC4730 /* WordListBarItem.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8C628FDEF3100FC4730 /* WordListBarItem.swift */; };
22 | F615B8CB28FDF46700FC4730 /* Position.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8CA28FDF46700FC4730 /* Position.swift */; };
23 | F615B8CC28FDF54700FC4730 /* Position.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8CA28FDF46700FC4730 /* Position.swift */; };
24 | F615B8CE28FDF67000FC4730 /* WordListView.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8CD28FDF67000FC4730 /* WordListView.swift */; };
25 | F615B8D028FE253D00FC4730 /* WordListBarStyle.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8CF28FE253D00FC4730 /* WordListBarStyle.swift */; };
26 | F615B8D428FE257700FC4730 /* WordListBarStyle.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8CF28FE253D00FC4730 /* WordListBarStyle.swift */; };
27 | F615B8D628FE5D4100FC4730 /* Audio.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8D528FE5D4100FC4730 /* Audio.swift */; };
28 | F615B8D828FE603000FC4730 /* UIImpactFeedbackGenerator.FeedbackStyle+Codable.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8D728FE603000FC4730 /* UIImpactFeedbackGenerator.FeedbackStyle+Codable.swift */; };
29 | F615B8D928FE610E00FC4730 /* UIImpactFeedbackGenerator.FeedbackStyle+Codable.swift in Sources */ = {isa = PBXBuildFile; fileRef = F615B8D728FE603000FC4730 /* UIImpactFeedbackGenerator.FeedbackStyle+Codable.swift */; };
30 | F6DE778528F7B96400E6F79A /* kApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = F6DE778428F7B96400E6F79A /* kApp.swift */; };
31 | F6DE778728F7B96400E6F79A /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = F6DE778628F7B96400E6F79A /* ContentView.swift */; };
32 | F6DE778928F7B96600E6F79A /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = F6DE778828F7B96600E6F79A /* Assets.xcassets */; };
33 | F6DE778C28F7B96600E6F79A /* Preview Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = F6DE778B28F7B96600E6F79A /* Preview Assets.xcassets */; };
34 | F6DE779928F7BA2E00E6F79A /* KeyboardViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = F6DE779828F7BA2E00E6F79A /* KeyboardViewController.swift */; };
35 | F6DE779D28F7BA2E00E6F79A /* keyboard.appex in Embed Foundation Extensions */ = {isa = PBXBuildFile; fileRef = F6DE779628F7BA2E00E6F79A /* keyboard.appex */; settings = {ATTRIBUTES = (RemoveHeadersOnCopy, ); }; };
36 | F6DE77A328F7BB6E00E6F79A /* KeyboardView.swift in Sources */ = {isa = PBXBuildFile; fileRef = F6DE77A228F7BB6E00E6F79A /* KeyboardView.swift */; };
37 | /* End PBXBuildFile section */
38 |
39 | /* Begin PBXContainerItemProxy section */
40 | F6DE779B28F7BA2E00E6F79A /* PBXContainerItemProxy */ = {
41 | isa = PBXContainerItemProxy;
42 | containerPortal = F6DE777928F7B96400E6F79A /* Project object */;
43 | proxyType = 1;
44 | remoteGlobalIDString = F6DE779528F7BA2E00E6F79A;
45 | remoteInfo = keyboard;
46 | };
47 | /* End PBXContainerItemProxy section */
48 |
49 | /* Begin PBXCopyFilesBuildPhase section */
50 | F6DE77A128F7BA2E00E6F79A /* Embed Foundation Extensions */ = {
51 | isa = PBXCopyFilesBuildPhase;
52 | buildActionMask = 2147483647;
53 | dstPath = "";
54 | dstSubfolderSpec = 13;
55 | files = (
56 | F6DE779D28F7BA2E00E6F79A /* keyboard.appex in Embed Foundation Extensions */,
57 | );
58 | name = "Embed Foundation Extensions";
59 | runOnlyForDeploymentPostprocessing = 0;
60 | };
61 | /* End PBXCopyFilesBuildPhase section */
62 |
63 | /* Begin PBXFileReference section */
64 | F615B8A828F7D66F00FC4730 /* keyboard.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = keyboard.entitlements; sourceTree = ""; };
65 | F615B8A928F7D6AD00FC4730 /* k.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = k.entitlements; sourceTree = ""; };
66 | F615B8AB28F7DAA000FC4730 /* Array+Codable.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "Array+Codable.swift"; sourceTree = ""; };
67 | F615B8AE28F7DBEE00FC4730 /* SettingsView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SettingsView.swift; sourceTree = ""; };
68 | F615B8BB28FDDA9C00FC4730 /* Shape+strokeFill.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "Shape+strokeFill.swift"; sourceTree = ""; };
69 | F615B8BE28FDDB8500FC4730 /* KeyboardButtonStyle.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = KeyboardButtonStyle.swift; sourceTree = ""; };
70 | F615B8C128FDE06800FC4730 /* AccessoryBarItem.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AccessoryBarItem.swift; sourceTree = ""; };
71 | F615B8C428FDED8900FC4730 /* AccessoryBarView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AccessoryBarView.swift; sourceTree = ""; };
72 | F615B8C628FDEF3100FC4730 /* WordListBarItem.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = WordListBarItem.swift; sourceTree = ""; };
73 | F615B8CA28FDF46700FC4730 /* Position.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Position.swift; sourceTree = ""; };
74 | F615B8CD28FDF67000FC4730 /* WordListView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = WordListView.swift; sourceTree = ""; };
75 | F615B8CF28FE253D00FC4730 /* WordListBarStyle.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = WordListBarStyle.swift; sourceTree = ""; };
76 | F615B8D528FE5D4100FC4730 /* Audio.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Audio.swift; sourceTree = ""; };
77 | F615B8D728FE603000FC4730 /* UIImpactFeedbackGenerator.FeedbackStyle+Codable.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "UIImpactFeedbackGenerator.FeedbackStyle+Codable.swift"; sourceTree = ""; };
78 | F6DE778128F7B96400E6F79A /* k.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = k.app; sourceTree = BUILT_PRODUCTS_DIR; };
79 | F6DE778428F7B96400E6F79A /* kApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = kApp.swift; sourceTree = ""; };
80 | F6DE778628F7B96400E6F79A /* ContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentView.swift; sourceTree = ""; };
81 | F6DE778828F7B96600E6F79A /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; };
82 | F6DE778B28F7B96600E6F79A /* Preview Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = "Preview Assets.xcassets"; sourceTree = ""; };
83 | F6DE779628F7BA2E00E6F79A /* keyboard.appex */ = {isa = PBXFileReference; explicitFileType = "wrapper.app-extension"; includeInIndex = 0; path = keyboard.appex; sourceTree = BUILT_PRODUCTS_DIR; };
84 | F6DE779828F7BA2E00E6F79A /* KeyboardViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = KeyboardViewController.swift; sourceTree = ""; };
85 | F6DE779A28F7BA2E00E6F79A /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
86 | F6DE77A228F7BB6E00E6F79A /* KeyboardView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = KeyboardView.swift; sourceTree = ""; };
87 | /* End PBXFileReference section */
88 |
89 | /* Begin PBXFrameworksBuildPhase section */
90 | F6DE777E28F7B96400E6F79A /* Frameworks */ = {
91 | isa = PBXFrameworksBuildPhase;
92 | buildActionMask = 2147483647;
93 | files = (
94 | );
95 | runOnlyForDeploymentPostprocessing = 0;
96 | };
97 | F6DE779328F7BA2E00E6F79A /* Frameworks */ = {
98 | isa = PBXFrameworksBuildPhase;
99 | buildActionMask = 2147483647;
100 | files = (
101 | );
102 | runOnlyForDeploymentPostprocessing = 0;
103 | };
104 | /* End PBXFrameworksBuildPhase section */
105 |
106 | /* Begin PBXGroup section */
107 | F615B8AA28F7DA9600FC4730 /* shared */ = {
108 | isa = PBXGroup;
109 | children = (
110 | F615B8AB28F7DAA000FC4730 /* Array+Codable.swift */,
111 | F615B8BB28FDDA9C00FC4730 /* Shape+strokeFill.swift */,
112 | F615B8BE28FDDB8500FC4730 /* KeyboardButtonStyle.swift */,
113 | F615B8C128FDE06800FC4730 /* AccessoryBarItem.swift */,
114 | F615B8C628FDEF3100FC4730 /* WordListBarItem.swift */,
115 | F615B8CA28FDF46700FC4730 /* Position.swift */,
116 | F615B8CF28FE253D00FC4730 /* WordListBarStyle.swift */,
117 | F615B8D728FE603000FC4730 /* UIImpactFeedbackGenerator.FeedbackStyle+Codable.swift */,
118 | );
119 | path = shared;
120 | sourceTree = "";
121 | };
122 | F6DE777828F7B96400E6F79A = {
123 | isa = PBXGroup;
124 | children = (
125 | F615B8AA28F7DA9600FC4730 /* shared */,
126 | F6DE778328F7B96400E6F79A /* k */,
127 | F6DE779728F7BA2E00E6F79A /* keyboard */,
128 | F6DE778228F7B96400E6F79A /* Products */,
129 | );
130 | sourceTree = "";
131 | };
132 | F6DE778228F7B96400E6F79A /* Products */ = {
133 | isa = PBXGroup;
134 | children = (
135 | F6DE778128F7B96400E6F79A /* k.app */,
136 | F6DE779628F7BA2E00E6F79A /* keyboard.appex */,
137 | );
138 | name = Products;
139 | sourceTree = "";
140 | };
141 | F6DE778328F7B96400E6F79A /* k */ = {
142 | isa = PBXGroup;
143 | children = (
144 | F615B8A928F7D6AD00FC4730 /* k.entitlements */,
145 | F6DE778428F7B96400E6F79A /* kApp.swift */,
146 | F6DE778628F7B96400E6F79A /* ContentView.swift */,
147 | F615B8AE28F7DBEE00FC4730 /* SettingsView.swift */,
148 | F6DE778828F7B96600E6F79A /* Assets.xcassets */,
149 | F6DE778A28F7B96600E6F79A /* Preview Content */,
150 | );
151 | path = k;
152 | sourceTree = "";
153 | };
154 | F6DE778A28F7B96600E6F79A /* Preview Content */ = {
155 | isa = PBXGroup;
156 | children = (
157 | F6DE778B28F7B96600E6F79A /* Preview Assets.xcassets */,
158 | );
159 | path = "Preview Content";
160 | sourceTree = "";
161 | };
162 | F6DE779728F7BA2E00E6F79A /* keyboard */ = {
163 | isa = PBXGroup;
164 | children = (
165 | F615B8A828F7D66F00FC4730 /* keyboard.entitlements */,
166 | F6DE779828F7BA2E00E6F79A /* KeyboardViewController.swift */,
167 | F6DE77A228F7BB6E00E6F79A /* KeyboardView.swift */,
168 | F615B8C428FDED8900FC4730 /* AccessoryBarView.swift */,
169 | F615B8CD28FDF67000FC4730 /* WordListView.swift */,
170 | F615B8D528FE5D4100FC4730 /* Audio.swift */,
171 | F6DE779A28F7BA2E00E6F79A /* Info.plist */,
172 | );
173 | path = keyboard;
174 | sourceTree = "";
175 | };
176 | /* End PBXGroup section */
177 |
178 | /* Begin PBXNativeTarget section */
179 | F6DE778028F7B96400E6F79A /* k */ = {
180 | isa = PBXNativeTarget;
181 | buildConfigurationList = F6DE778F28F7B96600E6F79A /* Build configuration list for PBXNativeTarget "k" */;
182 | buildPhases = (
183 | F6DE777D28F7B96400E6F79A /* Sources */,
184 | F6DE777E28F7B96400E6F79A /* Frameworks */,
185 | F6DE777F28F7B96400E6F79A /* Resources */,
186 | F6DE77A128F7BA2E00E6F79A /* Embed Foundation Extensions */,
187 | );
188 | buildRules = (
189 | );
190 | dependencies = (
191 | F6DE779C28F7BA2E00E6F79A /* PBXTargetDependency */,
192 | );
193 | name = k;
194 | productName = k;
195 | productReference = F6DE778128F7B96400E6F79A /* k.app */;
196 | productType = "com.apple.product-type.application";
197 | };
198 | F6DE779528F7BA2E00E6F79A /* keyboard */ = {
199 | isa = PBXNativeTarget;
200 | buildConfigurationList = F6DE779E28F7BA2E00E6F79A /* Build configuration list for PBXNativeTarget "keyboard" */;
201 | buildPhases = (
202 | F6DE779228F7BA2E00E6F79A /* Sources */,
203 | F6DE779328F7BA2E00E6F79A /* Frameworks */,
204 | F6DE779428F7BA2E00E6F79A /* Resources */,
205 | );
206 | buildRules = (
207 | );
208 | dependencies = (
209 | );
210 | name = keyboard;
211 | productName = keyboard;
212 | productReference = F6DE779628F7BA2E00E6F79A /* keyboard.appex */;
213 | productType = "com.apple.product-type.app-extension";
214 | };
215 | /* End PBXNativeTarget section */
216 |
217 | /* Begin PBXProject section */
218 | F6DE777928F7B96400E6F79A /* Project object */ = {
219 | isa = PBXProject;
220 | attributes = {
221 | BuildIndependentTargetsInParallel = 1;
222 | LastSwiftUpdateCheck = 1400;
223 | LastUpgradeCheck = 1400;
224 | TargetAttributes = {
225 | F6DE778028F7B96400E6F79A = {
226 | CreatedOnToolsVersion = 14.0.1;
227 | };
228 | F6DE779528F7BA2E00E6F79A = {
229 | CreatedOnToolsVersion = 14.0.1;
230 | };
231 | };
232 | };
233 | buildConfigurationList = F6DE777C28F7B96400E6F79A /* Build configuration list for PBXProject "k" */;
234 | compatibilityVersion = "Xcode 14.0";
235 | developmentRegion = en;
236 | hasScannedForEncodings = 0;
237 | knownRegions = (
238 | en,
239 | Base,
240 | );
241 | mainGroup = F6DE777828F7B96400E6F79A;
242 | productRefGroup = F6DE778228F7B96400E6F79A /* Products */;
243 | projectDirPath = "";
244 | projectRoot = "";
245 | targets = (
246 | F6DE778028F7B96400E6F79A /* k */,
247 | F6DE779528F7BA2E00E6F79A /* keyboard */,
248 | );
249 | };
250 | /* End PBXProject section */
251 |
252 | /* Begin PBXResourcesBuildPhase section */
253 | F6DE777F28F7B96400E6F79A /* Resources */ = {
254 | isa = PBXResourcesBuildPhase;
255 | buildActionMask = 2147483647;
256 | files = (
257 | F6DE778C28F7B96600E6F79A /* Preview Assets.xcassets in Resources */,
258 | F6DE778928F7B96600E6F79A /* Assets.xcassets in Resources */,
259 | );
260 | runOnlyForDeploymentPostprocessing = 0;
261 | };
262 | F6DE779428F7BA2E00E6F79A /* Resources */ = {
263 | isa = PBXResourcesBuildPhase;
264 | buildActionMask = 2147483647;
265 | files = (
266 | );
267 | runOnlyForDeploymentPostprocessing = 0;
268 | };
269 | /* End PBXResourcesBuildPhase section */
270 |
271 | /* Begin PBXSourcesBuildPhase section */
272 | F6DE777D28F7B96400E6F79A /* Sources */ = {
273 | isa = PBXSourcesBuildPhase;
274 | buildActionMask = 2147483647;
275 | files = (
276 | F615B8D928FE610E00FC4730 /* UIImpactFeedbackGenerator.FeedbackStyle+Codable.swift in Sources */,
277 | F615B8BC28FDDA9C00FC4730 /* Shape+strokeFill.swift in Sources */,
278 | F615B8C228FDE06800FC4730 /* AccessoryBarItem.swift in Sources */,
279 | F6DE778728F7B96400E6F79A /* ContentView.swift in Sources */,
280 | F615B8AF28F7DBEE00FC4730 /* SettingsView.swift in Sources */,
281 | F615B8D428FE257700FC4730 /* WordListBarStyle.swift in Sources */,
282 | F615B8AC28F7DAA000FC4730 /* Array+Codable.swift in Sources */,
283 | F6DE778528F7B96400E6F79A /* kApp.swift in Sources */,
284 | F615B8C828FDF01100FC4730 /* WordListBarItem.swift in Sources */,
285 | F615B8BF28FDDB8500FC4730 /* KeyboardButtonStyle.swift in Sources */,
286 | F615B8CC28FDF54700FC4730 /* Position.swift in Sources */,
287 | );
288 | runOnlyForDeploymentPostprocessing = 0;
289 | };
290 | F6DE779228F7BA2E00E6F79A /* Sources */ = {
291 | isa = PBXSourcesBuildPhase;
292 | buildActionMask = 2147483647;
293 | files = (
294 | F615B8D628FE5D4100FC4730 /* Audio.swift in Sources */,
295 | F615B8C028FDDB8C00FC4730 /* KeyboardButtonStyle.swift in Sources */,
296 | F615B8BD28FDDAAE00FC4730 /* Shape+strokeFill.swift in Sources */,
297 | F615B8D828FE603000FC4730 /* UIImpactFeedbackGenerator.FeedbackStyle+Codable.swift in Sources */,
298 | F6DE779928F7BA2E00E6F79A /* KeyboardViewController.swift in Sources */,
299 | F615B8C328FDE09A00FC4730 /* AccessoryBarItem.swift in Sources */,
300 | F615B8D028FE253D00FC4730 /* WordListBarStyle.swift in Sources */,
301 | F615B8CB28FDF46700FC4730 /* Position.swift in Sources */,
302 | F615B8AD28F7DAF600FC4730 /* Array+Codable.swift in Sources */,
303 | F615B8CE28FDF67000FC4730 /* WordListView.swift in Sources */,
304 | F615B8C528FDED8900FC4730 /* AccessoryBarView.swift in Sources */,
305 | F615B8C728FDEF3100FC4730 /* WordListBarItem.swift in Sources */,
306 | F6DE77A328F7BB6E00E6F79A /* KeyboardView.swift in Sources */,
307 | );
308 | runOnlyForDeploymentPostprocessing = 0;
309 | };
310 | /* End PBXSourcesBuildPhase section */
311 |
312 | /* Begin PBXTargetDependency section */
313 | F6DE779C28F7BA2E00E6F79A /* PBXTargetDependency */ = {
314 | isa = PBXTargetDependency;
315 | target = F6DE779528F7BA2E00E6F79A /* keyboard */;
316 | targetProxy = F6DE779B28F7BA2E00E6F79A /* PBXContainerItemProxy */;
317 | };
318 | /* End PBXTargetDependency section */
319 |
320 | /* Begin XCBuildConfiguration section */
321 | F6DE778D28F7B96600E6F79A /* Debug */ = {
322 | isa = XCBuildConfiguration;
323 | buildSettings = {
324 | ALWAYS_SEARCH_USER_PATHS = NO;
325 | CLANG_ANALYZER_NONNULL = YES;
326 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
327 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++20";
328 | CLANG_ENABLE_MODULES = YES;
329 | CLANG_ENABLE_OBJC_ARC = YES;
330 | CLANG_ENABLE_OBJC_WEAK = YES;
331 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
332 | CLANG_WARN_BOOL_CONVERSION = YES;
333 | CLANG_WARN_COMMA = YES;
334 | CLANG_WARN_CONSTANT_CONVERSION = YES;
335 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
336 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
337 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
338 | CLANG_WARN_EMPTY_BODY = YES;
339 | CLANG_WARN_ENUM_CONVERSION = YES;
340 | CLANG_WARN_INFINITE_RECURSION = YES;
341 | CLANG_WARN_INT_CONVERSION = YES;
342 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
343 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
344 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
345 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
346 | CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
347 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
348 | CLANG_WARN_STRICT_PROTOTYPES = YES;
349 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
350 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
351 | CLANG_WARN_UNREACHABLE_CODE = YES;
352 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
353 | COPY_PHASE_STRIP = NO;
354 | DEBUG_INFORMATION_FORMAT = dwarf;
355 | ENABLE_STRICT_OBJC_MSGSEND = YES;
356 | ENABLE_TESTABILITY = YES;
357 | GCC_C_LANGUAGE_STANDARD = gnu11;
358 | GCC_DYNAMIC_NO_PIC = NO;
359 | GCC_NO_COMMON_BLOCKS = YES;
360 | GCC_OPTIMIZATION_LEVEL = 0;
361 | GCC_PREPROCESSOR_DEFINITIONS = (
362 | "DEBUG=1",
363 | "$(inherited)",
364 | );
365 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
366 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
367 | GCC_WARN_UNDECLARED_SELECTOR = YES;
368 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
369 | GCC_WARN_UNUSED_FUNCTION = YES;
370 | GCC_WARN_UNUSED_VARIABLE = YES;
371 | IPHONEOS_DEPLOYMENT_TARGET = 16.0;
372 | MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
373 | MTL_FAST_MATH = YES;
374 | ONLY_ACTIVE_ARCH = YES;
375 | SDKROOT = iphoneos;
376 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
377 | SWIFT_OPTIMIZATION_LEVEL = "-Onone";
378 | };
379 | name = Debug;
380 | };
381 | F6DE778E28F7B96600E6F79A /* Release */ = {
382 | isa = XCBuildConfiguration;
383 | buildSettings = {
384 | ALWAYS_SEARCH_USER_PATHS = NO;
385 | CLANG_ANALYZER_NONNULL = YES;
386 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
387 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++20";
388 | CLANG_ENABLE_MODULES = YES;
389 | CLANG_ENABLE_OBJC_ARC = YES;
390 | CLANG_ENABLE_OBJC_WEAK = YES;
391 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
392 | CLANG_WARN_BOOL_CONVERSION = YES;
393 | CLANG_WARN_COMMA = YES;
394 | CLANG_WARN_CONSTANT_CONVERSION = YES;
395 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
396 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
397 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
398 | CLANG_WARN_EMPTY_BODY = YES;
399 | CLANG_WARN_ENUM_CONVERSION = YES;
400 | CLANG_WARN_INFINITE_RECURSION = YES;
401 | CLANG_WARN_INT_CONVERSION = YES;
402 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
403 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
404 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
405 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
406 | CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
407 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
408 | CLANG_WARN_STRICT_PROTOTYPES = YES;
409 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
410 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
411 | CLANG_WARN_UNREACHABLE_CODE = YES;
412 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
413 | COPY_PHASE_STRIP = NO;
414 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
415 | ENABLE_NS_ASSERTIONS = NO;
416 | ENABLE_STRICT_OBJC_MSGSEND = YES;
417 | GCC_C_LANGUAGE_STANDARD = gnu11;
418 | GCC_NO_COMMON_BLOCKS = YES;
419 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
420 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
421 | GCC_WARN_UNDECLARED_SELECTOR = YES;
422 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
423 | GCC_WARN_UNUSED_FUNCTION = YES;
424 | GCC_WARN_UNUSED_VARIABLE = YES;
425 | IPHONEOS_DEPLOYMENT_TARGET = 16.0;
426 | MTL_ENABLE_DEBUG_INFO = NO;
427 | MTL_FAST_MATH = YES;
428 | SDKROOT = iphoneos;
429 | SWIFT_COMPILATION_MODE = wholemodule;
430 | SWIFT_OPTIMIZATION_LEVEL = "-O";
431 | VALIDATE_PRODUCT = YES;
432 | };
433 | name = Release;
434 | };
435 | F6DE779028F7B96600E6F79A /* Debug */ = {
436 | isa = XCBuildConfiguration;
437 | buildSettings = {
438 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES;
439 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
440 | ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
441 | CODE_SIGN_ENTITLEMENTS = k/k.entitlements;
442 | CODE_SIGN_STYLE = Automatic;
443 | CURRENT_PROJECT_VERSION = 7;
444 | DEVELOPMENT_ASSET_PATHS = "\"k/Preview Content\"";
445 | DEVELOPMENT_TEAM = C6L3992RFB;
446 | ENABLE_PREVIEWS = YES;
447 | GENERATE_INFOPLIST_FILE = YES;
448 | INFOPLIST_KEY_CFBundleDisplayName = k.;
449 | INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES;
450 | INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
451 | INFOPLIST_KEY_UILaunchScreen_Generation = YES;
452 | INFOPLIST_KEY_UIRequiredDeviceCapabilities = armv7;
453 | INFOPLIST_KEY_UISupportedInterfaceOrientations = "UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown";
454 | LD_RUNPATH_SEARCH_PATHS = (
455 | "$(inherited)",
456 | "@executable_path/Frameworks",
457 | );
458 | MARKETING_VERSION = 1.1.0;
459 | PRODUCT_BUNDLE_IDENTIFIER = com.twodayslate.k;
460 | PRODUCT_NAME = "$(TARGET_NAME)";
461 | SWIFT_EMIT_LOC_STRINGS = YES;
462 | SWIFT_VERSION = 5.0;
463 | TARGETED_DEVICE_FAMILY = "1,2";
464 | };
465 | name = Debug;
466 | };
467 | F6DE779128F7B96600E6F79A /* Release */ = {
468 | isa = XCBuildConfiguration;
469 | buildSettings = {
470 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES;
471 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
472 | ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
473 | CODE_SIGN_ENTITLEMENTS = k/k.entitlements;
474 | CODE_SIGN_STYLE = Automatic;
475 | CURRENT_PROJECT_VERSION = 7;
476 | DEVELOPMENT_ASSET_PATHS = "\"k/Preview Content\"";
477 | DEVELOPMENT_TEAM = C6L3992RFB;
478 | ENABLE_PREVIEWS = YES;
479 | GENERATE_INFOPLIST_FILE = YES;
480 | INFOPLIST_KEY_CFBundleDisplayName = k.;
481 | INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES;
482 | INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
483 | INFOPLIST_KEY_UILaunchScreen_Generation = YES;
484 | INFOPLIST_KEY_UIRequiredDeviceCapabilities = armv7;
485 | INFOPLIST_KEY_UISupportedInterfaceOrientations = "UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown";
486 | LD_RUNPATH_SEARCH_PATHS = (
487 | "$(inherited)",
488 | "@executable_path/Frameworks",
489 | );
490 | MARKETING_VERSION = 1.1.0;
491 | PRODUCT_BUNDLE_IDENTIFIER = com.twodayslate.k;
492 | PRODUCT_NAME = "$(TARGET_NAME)";
493 | SWIFT_EMIT_LOC_STRINGS = YES;
494 | SWIFT_VERSION = 5.0;
495 | TARGETED_DEVICE_FAMILY = "1,2";
496 | };
497 | name = Release;
498 | };
499 | F6DE779F28F7BA2E00E6F79A /* Debug */ = {
500 | isa = XCBuildConfiguration;
501 | buildSettings = {
502 | CODE_SIGN_ENTITLEMENTS = keyboard/keyboard.entitlements;
503 | CODE_SIGN_STYLE = Automatic;
504 | CURRENT_PROJECT_VERSION = 7;
505 | DEVELOPMENT_TEAM = C6L3992RFB;
506 | GENERATE_INFOPLIST_FILE = YES;
507 | INFOPLIST_FILE = keyboard/Info.plist;
508 | INFOPLIST_KEY_CFBundleDisplayName = k.;
509 | INFOPLIST_KEY_NSHumanReadableCopyright = "";
510 | LD_RUNPATH_SEARCH_PATHS = (
511 | "$(inherited)",
512 | "@executable_path/Frameworks",
513 | "@executable_path/../../Frameworks",
514 | );
515 | MARKETING_VERSION = 1.1.0;
516 | PRODUCT_BUNDLE_IDENTIFIER = com.twodayslate.k.keyboard;
517 | PRODUCT_NAME = "$(TARGET_NAME)";
518 | SKIP_INSTALL = YES;
519 | SWIFT_EMIT_LOC_STRINGS = YES;
520 | SWIFT_VERSION = 5.0;
521 | TARGETED_DEVICE_FAMILY = "1,2";
522 | };
523 | name = Debug;
524 | };
525 | F6DE77A028F7BA2E00E6F79A /* Release */ = {
526 | isa = XCBuildConfiguration;
527 | buildSettings = {
528 | CODE_SIGN_ENTITLEMENTS = keyboard/keyboard.entitlements;
529 | CODE_SIGN_STYLE = Automatic;
530 | CURRENT_PROJECT_VERSION = 7;
531 | DEVELOPMENT_TEAM = C6L3992RFB;
532 | GENERATE_INFOPLIST_FILE = YES;
533 | INFOPLIST_FILE = keyboard/Info.plist;
534 | INFOPLIST_KEY_CFBundleDisplayName = k.;
535 | INFOPLIST_KEY_NSHumanReadableCopyright = "";
536 | LD_RUNPATH_SEARCH_PATHS = (
537 | "$(inherited)",
538 | "@executable_path/Frameworks",
539 | "@executable_path/../../Frameworks",
540 | );
541 | MARKETING_VERSION = 1.1.0;
542 | PRODUCT_BUNDLE_IDENTIFIER = com.twodayslate.k.keyboard;
543 | PRODUCT_NAME = "$(TARGET_NAME)";
544 | SKIP_INSTALL = YES;
545 | SWIFT_EMIT_LOC_STRINGS = YES;
546 | SWIFT_VERSION = 5.0;
547 | TARGETED_DEVICE_FAMILY = "1,2";
548 | };
549 | name = Release;
550 | };
551 | /* End XCBuildConfiguration section */
552 |
553 | /* Begin XCConfigurationList section */
554 | F6DE777C28F7B96400E6F79A /* Build configuration list for PBXProject "k" */ = {
555 | isa = XCConfigurationList;
556 | buildConfigurations = (
557 | F6DE778D28F7B96600E6F79A /* Debug */,
558 | F6DE778E28F7B96600E6F79A /* Release */,
559 | );
560 | defaultConfigurationIsVisible = 0;
561 | defaultConfigurationName = Release;
562 | };
563 | F6DE778F28F7B96600E6F79A /* Build configuration list for PBXNativeTarget "k" */ = {
564 | isa = XCConfigurationList;
565 | buildConfigurations = (
566 | F6DE779028F7B96600E6F79A /* Debug */,
567 | F6DE779128F7B96600E6F79A /* Release */,
568 | );
569 | defaultConfigurationIsVisible = 0;
570 | defaultConfigurationName = Release;
571 | };
572 | F6DE779E28F7BA2E00E6F79A /* Build configuration list for PBXNativeTarget "keyboard" */ = {
573 | isa = XCConfigurationList;
574 | buildConfigurations = (
575 | F6DE779F28F7BA2E00E6F79A /* Debug */,
576 | F6DE77A028F7BA2E00E6F79A /* Release */,
577 | );
578 | defaultConfigurationIsVisible = 0;
579 | defaultConfigurationName = Release;
580 | };
581 | /* End XCConfigurationList section */
582 | };
583 | rootObject = F6DE777928F7B96400E6F79A /* Project object */;
584 | }
585 |
--------------------------------------------------------------------------------