Repository: flutter
Issue: Spell checking should be according to current selected language in keyboard, not locale of device.
Labels: a: text input,platform-ios,framework,engine,a: internationalization,has reproducible steps,P2,team-ios,triaged-ios,found in release: 3.16,found in release: 3.17,fyi-text-input


- [X] I have searched the [existing issues](https://github.com/flutter/flutter/issues)
- [X] I have read the [guide to filing a bug](https://flutter.dev/docs/resources/bug-reports)

### Steps to reproduce

1. Locale of device should be ru_RU
2. Write english words with english keyboard.

### Expected results

1. Locale of device is ru_RU
2. When typing in english keyboard, spell checking should also be in english. And correct english words should not be underlined with red

### Actual results

Correct english words are underlined with red.

### Code sample

<details><summary>Code sample</summary>

```dart
Localizations.override(
            locale: Locale(
                "ru",
                "RU"),
            context: context,
            child: TextField(
              autocorrect: true,
              enableSuggestions: true,
              style: TextStyle(
                  fontSize: 17,
                  height: 1.3),
              spellCheckConfiguration: SpellCheckConfiguration(
                misspelledTextStyle: TextStyle(
                  fontSize: 17,
                    decoration: TextDecoration.underline,
                    decorationColor: Colors.red,
                    height: 1.3),
                spellCheckService: DefaultSpellCheckService(),
              ),
            ),
          ),
```

</details>


### Screenshots or Video

<details>
<summary>Screenshots / Video demonstration</summary>

[Upload media here]

</details>


### Logs

<details><summary>Logs</summary>

```console
[Paste your logs here]
```

</details>


### Flutter Doctor output

<details><summary>Doctor output</summary>

```console
[✓] Flutter (Channel stable, 3.13.4, on macOS 14.0 23A344 darwin-arm64, locale en-UZ)
    • Flutter version 3.13.4 on channel stable at /Users/durbek/Downloads/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 367f9ea16b (8 weeks ago), 2023-09-12 23:27:53 -0500
    • Engine revision 9064459a8b
    • Dart version 3.1.2
    • DevTools version 2.25.0

[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
    • Android SDK at /Users/durbek/Library/Android/sdk
    • Platform android-34, build-tools 34.0.0
    • Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 17.0.6+0-17.0.6b829.9-10027231)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 15.0)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 15A240d
    • CocoaPods version 1.12.1

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2022.3)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 17.0.6+0-17.0.6b829.9-10027231)

[✓] IntelliJ IDEA Ultimate Edition (version 2023.2.2)
    • IntelliJ at /Applications/IntelliJ IDEA.app
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin version 232.9559.10

[✓] Connected device (3 available)
    • Hometasker Iphone (mobile) • 00008110-001134803EFA401E • ios            • iOS 17.0.3 21A360
    • macOS (desktop)            • macos                     • darwin-arm64   • macOS 14.0 23A344 darwin-arm64
    • Chrome (web)               • chrome                    • web-javascript • Google Chrome 119.0.6045.123
    ! Error: Browsing on the local area network for Shahzod’s iPhone. Ensure the device is unlocked and attached with a cable or associated with the same local area
      network as this Mac.
      The device must be opted into Developer Mode to connect wirelessly. (code -27)

[✓] Network resources
    • All expected network resources are available.

• No issues found!
```

</details>