Repository: flutter
Issue: [Impeller] Uneven letter spacing when text is scaled
Labels: engine,c: rendering,has reproducible steps,P1,e: impeller,team-engine,triaged-engine,found in release: 3.24,found in release: 3.27

### Steps to reproduce

Scaling using textScaler parameter in a Text widget looks nice, but a Text widget inside a Transform widget does not.

Tested on macOS.

### Expected results

How it looks in Skia:
<img width="250" alt="textscaling-skia" src="https://github.com/user-attachments/assets/91fd1db3-38d1-4db8-8db2-8b0d0fd65319">

### Actual results

How it looks in Impeller:
<img width="250" alt="textscaling-impeller" src="https://github.com/user-attachments/assets/cc8df5e2-d341-4f97-9eac-f16301e022d3">

Here's a GIF for easier comparison:
![textscaling](https://github.com/user-attachments/assets/6870d7f2-159a-4dbd-a8fe-056531703d49)

(It's also interesting that the font weight appears to be thinner in Impeller, but that's not why I'm here)

### Code sample

<details open><summary>Code sample</summary>

```dart
import 'package:flutter/material.dart';
import 'package:google_fonts/google_fonts.dart';

void main() async {
  WidgetsFlutterBinding.ensureInitialized();
  runApp(const MainApp2());
}

class MainApp2 extends StatefulWidget {
  const MainApp2({super.key});
  
  @override
  State<MainApp2> createState() => _MainApp2State();
}

class _MainApp2State extends State<MainApp2> {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: DefaultTextStyle(
        style: TextStyle(fontFamily: GoogleFonts.roboto().fontFamily, fontSize: 12),
        child: Column(mainAxisAlignment: MainAxisAlignment.center, children: [
          Transform.scale(
            scale: 0.7,
            child: const Text(
"""With Transform widget:
The quick brown fox jumps over the lazy dog
lllllllllllllllllllllllllllllllllllllllllll
iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii"""
            )
          ),
          const Text(
            textScaler: TextScaler.linear(0.7),
"""With TextScaler:
The quick brown fox jumps over the lazy dog
lllllllllllllllllllllllllllllllllllllllllll
iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii"""
          )
        ])
      )
    );
  }
}
```

</details>


### Screenshots or Video

_No response_

### Logs

_No response_

### Flutter Doctor output

<details open><summary>Doctor output</summary>

```console
[✓] Flutter (Channel master, 3.26.0-1.0.pre.367, on macOS 13.6.7 22G720 darwin-arm64, locale en-US)
    • Flutter version 3.26.0-1.0.pre.367 on channel master at /Users/weirdhat/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 572b1d7b08 (7 weeks ago), 2024-10-04 22:04:06 -0400
    • Engine revision 92b5b31819
    • Dart version 3.6.0 (build 3.6.0-324.0.dev)
    • DevTools version 2.40.0

[!] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
    • Android SDK at /Users/weirdhat/Library/Android/sdk
    ✗ cmdline-tools component is missing
      Run `path/to/sdkmanager --install "cmdline-tools;latest"`
      See https://developer.android.com/studio/command-line for more details.
    ✗ Android license status unknown.
      Run `flutter doctor --android-licenses` to accept the SDK licenses.
      See https://flutter.dev/to/macos-android-setup for more details.

[!] Xcode - develop for iOS and macOS (Xcode 15.0)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 15A240d
    ! CocoaPods 1.12.1 out of date (1.13.0 is recommended).
        CocoaPods is a package manager for iOS or macOS platform code.
        Without CocoaPods, plugins will not work on iOS or macOS.
        For more info, see https://flutter.dev/to/platform-plugins
      To update CocoaPods, see https://guides.cocoapods.org/using/getting-started.html#updating-cocoapods

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2024.1)
    • 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.11+0-17.0.11b1207.24-11852314)

[✓] VS Code (version 1.95.3)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.100.0

[✓] Connected device (4 available)
    • JK iPad 2024 (mobile)           • 00008103-001659302668801E • ios            • iOS 17.6.1 21G93
    • macOS (desktop)                 • macos                     • darwin-arm64   • macOS 13.6.7 22G720 darwin-arm64
    • Mac Designed for iPad (desktop) • mac-designed-for-ipad     • darwin         • macOS 13.6.7 22G720 darwin-arm64
    • Chrome (web)                    • chrome                    • web-javascript • Google Chrome 131.0.6778.71
    ! Error: Browsing on the local area network for JACOB’s iPad (2). 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.

! Doctor found issues in 2 categories.
```

</details>