Scribe-iOS icon indicating copy to clipboard operation
Scribe-iOS copied to clipboard

Transition away from switch case for determining keyboard layouts

Open henrikth93 opened this issue 1 year ago • 0 comments

Terms

Issue

The code in KeyboardKeys is currently using switch cases for setting various widths, we want to avoid using switch cases and instead use a more general solution, where we only set the width for the current keyboard being used.

Reference: https://github.com/scribe-org/Scribe-iOS/blob/855228085d7523a82e4af5e1f2e92274d4660f72/Keyboards/KeyboardsBase/KeyboardKeys.swift#L255

scalarCapsLockKeyWidth = currentLanguage.scalarCapsLockKeyWidth scalarReturnKeyWidth = currentLanguage.scalarReturnKeyWidth scalarSpecialKeysWidth = currentLanguage.scalarSpecialKeysWidth scalarReturnKeyWidth = currentLanguage.scalarReturnKeyWidth

This is a good first issue for GSoC

henrikth93 avatar Feb 18 '24 19:02 henrikth93