diff --git a/CHANGELOG.md b/CHANGELOG.md index 508c3478..7cce4beb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,15 +14,16 @@ Emojis for the following are chosen based on [gitmoji](https://gitmoji.dev/). ### ✨ New Features -- German indefinite pronouns are now selectable from the case-declension display. -- German imperfect verb conjugations now insert both the auxiliary verb and the past participle with the cursor between them. - Adds a new menu to the Scribe app allowing users to set their preferences for their respective language keyboards! - Users now have easy access to the Scribe GitHub, the Matrix community, rating the app, sending bug reports and emailing the team. - Settings options include: - Allowing the user to add a command and period to the letter keys. - Allowing the user to disable emoji autosuggestions and autocompletions. - Allowing the user to disable accented characters on the letter keys. - - Mneu screens can be swiped between via an implementation using SwipeableTabBarController. + - Menu screens can be swiped between via an implementation using SwipeableTabBarController. +- German indefinite pronouns are now selectable from the case-declension display. +- German imperfect verb conjugations now insert both the auxiliary verb and the past participle with the cursor between them. +- Tab and caps lock keys and their functionalities have been added to expanded iPad layouts ([#371](https://github.com/scribe-org/Scribe-iOS/issues/371)). ### 🎨 Design Changes diff --git a/Keyboards/InterfaceConstants.swift b/Keyboards/InterfaceConstants.swift index 73135f27..09cb9011 100644 --- a/Keyboards/InterfaceConstants.swift +++ b/Keyboards/InterfaceConstants.swift @@ -1,9 +1,10 @@ // // Scribe // +// Constants for Scribe keyboard interfaces. +// -struct SpecialKeys { - +enum SpecialKeys { static let indent = "indent" static let capsLock = "capslock" } diff --git a/Keyboards/KeyboardsBase/KeyboardKeys.swift b/Keyboards/KeyboardsBase/KeyboardKeys.swift index d60541c6..ddbb6f3e 100644 --- a/Keyboards/KeyboardsBase/KeyboardKeys.swift +++ b/Keyboards/KeyboardsBase/KeyboardKeys.swift @@ -261,9 +261,9 @@ class KeyboardKey: UIButton { widthAnchor.constraint(equalToConstant: numSymKeyWidth * 1).isActive = true } else if ["123", ".?123", "return", "hideKeyboard"].contains(key) { if key == "return" - && (controllerLanguage == "Portuguese" || controllerLanguage == "Italian" || commandState == .translate) - && row == 1 - && DeviceType.isPad + && (controllerLanguage == "Portuguese" || controllerLanguage == "Italian" || commandState == .translate) + && row == 1 + && DeviceType.isPad { layer.setValue(true, forKey: "isSpecial") widthAnchor.constraint(equalToConstant: numSymKeyWidth * 1.5).isActive = true @@ -295,7 +295,6 @@ class KeyboardKey: UIButton { case SpecialKeys.capsLock: switch capsLockButtonState { - case .normal: backgroundColor = specialKeyColor styleIconBtn(btn: self, color: UIColor.label, iconName: "capslock") @@ -311,7 +310,7 @@ class KeyboardKey: UIButton { styleIconBtn(btn: self, color: UIColor.label, iconName: "shift.fill") } else if DeviceType.isPhone && capsLockButtonState == .locked { - // We need to style the SHIFT button instead of the CAPSLOCK since the keyboard is smaller + // We need to style the SHIFT button instead of the CAPSLOCK since the keyboard is smaller. backgroundColor = keyPressedColor styleIconBtn(btn: self, color: UIColor.label, iconName: "capslock.fill") diff --git a/Keyboards/KeyboardsBase/KeyboardViewController.swift b/Keyboards/KeyboardsBase/KeyboardViewController.swift index 869dedec..c2b8c0c0 100644 --- a/Keyboards/KeyboardsBase/KeyboardViewController.swift +++ b/Keyboards/KeyboardsBase/KeyboardViewController.swift @@ -1938,7 +1938,7 @@ class KeyboardViewController: UIInputViewController { // Set the width of the key given device and the given key. btn.adjustKeyWidth() - // Update the button style + // Update the button style. btn.adjustButtonStyle() if key == "return" && proxy.keyboardType == .webSearch && ![.translate, .conjugate, .plural].contains(commandState) { @@ -2066,7 +2066,7 @@ class KeyboardViewController: UIInputViewController { let letterKeysHaveCommaPeriod = userDefaults.bool(forKey: dictionaryKey) if letterKeysHaveCommaPeriod { - let spaceIndex = letterKeys[3].firstIndex(where: {$0 == "space"}) + let spaceIndex = letterKeys[3].firstIndex(where: { $0 == "space" }) letterKeys[3].insert(",", at: spaceIndex!) letterKeys[3].insert(".", at: spaceIndex! + 2) } @@ -2499,7 +2499,7 @@ class KeyboardViewController: UIInputViewController { case "shift": if capsLockButtonState == .locked { - // Return capitalization to default + // Return capitalization to default. capsLockButtonState = .normal shiftButtonState = .normal } else { @@ -2685,7 +2685,7 @@ class KeyboardViewController: UIInputViewController { } private func switchToFullCaps() { - // Return SHIFT button to normal state as the ALLCAPS button will be enabled + // Return SHIFT button to normal state as the CAPSLOCK button will be enabled. shiftButtonState = .normal capsLockButtonState = capsLockButtonState == .normal ? .locked : .normal diff --git a/Keyboards/KeyboardsBase/ScribeFunctionality/Annotate.swift b/Keyboards/KeyboardsBase/ScribeFunctionality/Annotate.swift index fa6009c4..b8e411fb 100644 --- a/Keyboards/KeyboardsBase/ScribeFunctionality/Annotate.swift +++ b/Keyboards/KeyboardsBase/ScribeFunctionality/Annotate.swift @@ -238,7 +238,7 @@ func typedWordAnnotation(KVC: KeyboardViewController) { guard let lastWordTyped = wordsTyped.secondToLast() else { return } - + if !languagesWithCapitalizedNouns.contains(controllerLanguage) { wordToCheck = lastWordTyped.lowercased() } else {