Repository: flutter
Issue: AppBarTheme not localized correctly
Labels: framework,f: material design,a: quality,has reproducible steps,P2,found in release: 3.3,found in release: 3.7,team-design,triaged-design

<!-- Thank you for using Flutter!

     If you are looking for support, please check out our documentation
     or consider asking a question on Stack Overflow:
      * https://flutter.dev/
      * https://api.flutter.dev/
      * https://stackoverflow.com/questions/tagged/flutter?sort=frequent

     If you have found a bug or if our documentation doesn't have an answer
     to what you're looking for, then fill our the template below. Please read
     our guide to filing a bug first: https://flutter.dev/docs/resources/bug-reports
-->

## Steps to Reproduce

<!--
     Please tell us exactly how to reproduce the problem you are running into.

     Please attach a small application (ideally just one main.dart file) that
     reproduces the problem. You could use https://gist.github.com/ for this.

     If the problem is with your application's rendering, then please attach
     a screenshot and explain what the problem is.
-->

**Minimal Reproduction + Workaround:** https://gist.github.com/JonasWanke/40b49e683810641f9f682ddfda28cc2f

I am using a customized `AppBarTheme` because I want the background color to be a light grey instead of the primary color. My primary color is dark, hence the inferred white text color is not legible on the new bar. Therefore I manually overwrite the `AppBarTheme.textTheme`  to the default `textTheme` of my (light) theme.

The problem with this method is that no geometry is set on the new `textTheme` (see screenshot below) because [ThemeData.localize](https://github.com/flutter/flutter/blob/20e59316b8/packages/flutter/lib/src/material/theme_data.dart#L870) (used by [Theme.of](https://github.com/flutter/flutter/blob/20e59316b8/packages/flutter/lib/src/material/theme.dart#L127)) only applies geometry to `primaryTextTheme`, `accentTextTheme` and `textTheme`. Maybe this could be extended to include something like the following:
```
appBarTheme: baseTheme.appBarTheme.copyWith(
  textTheme: localTextGeometry.merge(baseTheme.appBarTheme.textTheme)
)
```

*Note:* Though I didn't test it, this problem might also occur with other widget's themes.

![image](https://user-images.githubusercontent.com/19330937/63198888-756bfd80-c07c-11e9-8632-b2105c537a88.png)

## Logs

<!--
      Run your application with `flutter run --verbose` and attach all the
      log output below between the lines with the backticks. If there is an
      exception, please see if the error message includes enough information
      to explain how to solve the issue.

```
```
-->

<!--
     Run `flutter analyze` and attach any output of that command below.
     If there are any analysis errors, try resolving them before filing this issue.
-->

`flutter analyze`:
```
Analyzing flutter_bug_appbartheme...
No issues found! (ran in 13.9s)
```

<!-- Finally, paste the output of running `flutter doctor -v` here. -->
`flutter doctor -v`:
```
[√] Flutter (Channel master, v1.8.5-pre.117, on Microsoft Windows [Version 10.0.18362.267], locale en-US)
    • Flutter version 1.8.5-pre.117 at C:\programs\flutter
    • Framework revision 83a8a575ee (6 days ago), 2019-08-10 12:38:20 -0700
    • Engine revision ff49ca1c6e
    • Dart version 2.5.0 (build 2.5.0-dev.1.0 f29f41f1a5)

 
[√] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
    • Android SDK at C:\Users\jowan\AppData\Local\Android\sdk
    • Android NDK location not configured (optional; useful for native profiling support)
    • Platform android-28, build-tools 28.0.3
    • Java binary at: C:\programs\android-studio 3.5-beta.4\jre\bin\java
    • Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b03)
    • All Android licenses accepted.

[√] Visual Studio - develop for Windows (Visual Studio Community 2019 16.1.0)
    • Visual Studio at C:\Program Files (x86)\Microsoft Visual Studio\2019\Community
    • Visual Studio Community 2019 version 16.1.28917.181

[√] Android Studio (version 3.4)
    • Android Studio at C:\Program Files\Android\Android Studio
    • Flutter plugin version 36.1.1
    • Dart plugin version 183.6270
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1343-b01)

[√] Android Studio (version 3.5)
    • Android Studio at C:\programs\android-studio 3.5-beta.4
    • Flutter plugin version 36.1.1
    • Dart plugin version 183.6270
    • Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b03)

[!] IntelliJ IDEA Ultimate Edition (version 2019.2)
    • IntelliJ at C:\Program Files\JetBrains\IntelliJ IDEA 2019.1.1
    X Flutter plugin not installed; this adds Flutter specific functionality.
    X Dart plugin not installed; this adds Dart specific functionality.
    • For information about installing plugins, see
      https://flutter.dev/intellij-setup/#installing-the-plugins

[√] VS Code, 64-bit edition (version 1.36.1)
    • VS Code at C:\Program Files\Microsoft VS Code
    • Flutter extension version 3.3.0

[√] Connected device (2 available)
    • SM G955F • 9889db373853574a45 • android-arm64 • Android 9 (API 28)
    • Windows  • Windows            • windows-x64   • Microsoft Windows [Version 10.0.18362.267]

! Doctor found issues in 1 category.
```
(using VS Code)