You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
License page colors cannot be changed when wrapped with Theme widget #44922
The buttons in the AboutDialoog seem to be using the default colors and ignore coloring themes defined higher up.
On Android, this results in "View Licences" and "Close" buttons in some shade of cyan (I believe this is the default Material accentColor).
On iOS, it results in standard blue buttons and a blue AppBar on the "Licences" page when clicking the "View Licences" button.
I'm grateful for any hints on how to work around this.
[√] Flutter (Channel dev, v1.12.1, on Microsoft Windows [Version 10.0.19013.1122], locale en-US)
• Flutter version 1.12.1 at C:\src\flutter
• Framework revision 86c91b12d8 (4 days ago), 2019-11-11 13:29:46 -0800
• Engine revision 31cd2dfca2
• Dart version 2.7.0
[√] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
• Android SDK at C:\Users\iapic\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:\Program Files\Android\Android Studio\jre\bin\java
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b03)
• All Android licenses accepted.
[√] Chrome - develop for the web
• Chrome at C:\Program Files (x86)\Google\Chrome\Application\chrome.exe
[√] Android Studio (version 3.5)
• Android Studio at C:\Program Files\Android\Android Studio
• Flutter plugin version 41.1.2
• Dart plugin version 191.8593
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b03)
[√] VS Code, 64-bit edition (version 1.40.1)
• VS Code at C:\Program Files\Microsoft VS Code
• Flutter extension version 3.6.0
[√] Connected device (3 available)
• Pixel 3a • 965AY0WP5C • android-arm64 • Android 10 (API 29)
• Chrome • chrome • web-javascript • Google Chrome 78.0.3904.97
• Web Server • web-server • web-javascript • Flutter Tools
• No issues found!
I'm not sure to understand the issue,
the colors of the buttons respond to the different Theme;
can you provide more details about the issue?
thank you
Indeed, your code works in a fresh sample project, which I guess should be kind of embarassing for me...
In my code, I use an AboutListTile() (but the behaviour is the same with showAboutDialog(). What strikes me as strange is that I can directly wrap the widget with
The result: The color of the text in the AboutListTile changes (to unreadable white because of the dark theme), however the upcoming AboutDialog still has the same (default) button colors.
doctor
[√] Flutter (Channel stable, v1.9.1+hotfix.6, on Microsoft Windows [Version 10.0.18362.418], locale de-CH)
• Flutter version 1.9.1+hotfix.6 at C:\src\flutter
• Framework revision 68587a0 (9 weeks ago), 2019-09-13 19:46:58 -0700
• Engine revision b863200
• Dart version 2.5.0
[√] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
• Android SDK at C:\Users\gregr\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:\Program Files\Android\Android Studio\jre\bin\java
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b03)
• All Android licenses accepted.
[√] Android Studio (version 3.5)
• Android Studio at C:\Program Files\Android\Android Studio
• Flutter plugin version 41.1.2
• Dart plugin version 191.8593
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b03)
Well, I guess that particular weirdness seems to be specific to my project.
Still grateful for any pointers on what to check - otherwise I'm okay with closing this issue.
Thank you!
Hi everybody,
Just a quick update in case that helps: We built our latest release with the new stable flutter version (1.12.3+hotfix.8) and the buttons in the AboutDialog are still acting weird, albeit in a slightly different way:
on iOS (no change): AboutDialog buttons ("View Licences" and "Close") are in the standard blue color, ignoring the Theme defined higher up. When clicking "View Licences", the licences page is in the standard blue color as well.
on Android: AboutDialog buttons are not cyan anymore, but white on white (and thus invisible, which is doubly annoying...). When clicking "View Licences", the licences page follows the design theme defined higher up.
Hi there. The AboutDialog now uses the app's primary color for the button text, this solves my specific problem and I'm okay with closing this issue if you think that makes sense.
(However, from my short tests it seems wrapping the AboutListTile in a Theme widget still doesn't do anything...?)
changed the title [-]AboutListTile colors cannot be changed when wrapped with Theme widgets[/-][+]License page colors cannot be changed when wrapped with Theme widgets[/+]on Jan 14, 2025
changed the title [-]License page colors cannot be changed when wrapped with Theme widgets[/-][+]License page colors cannot be changed when wrapped with `Theme` widget[/+]on Jan 14, 2025
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.
Activity
iapicca commentedon Nov 15, 2019
Hi @rgisi
does this code represent the situation you are describing?
sample code
doctor
I'm not sure to understand the issue,
the colors of the buttons respond to the different
Theme;can you provide more details about the issue?
thank you
rgisi commentedon Nov 15, 2019
Thank you for your input, @iapicca !
Indeed, your code works in a fresh sample project, which I guess should be kind of embarassing for me...
In my code, I use an
AboutListTile()(but the behaviour is the same withshowAboutDialog(). What strikes me as strange is that I can directly wrap the widget withThe result: The color of the text in the AboutListTile changes (to unreadable white because of the dark theme), however the upcoming AboutDialog still has the same (default) button colors.
doctor
[√] Flutter (Channel stable, v1.9.1+hotfix.6, on Microsoft Windows [Version 10.0.18362.418], locale de-CH)
• Flutter version 1.9.1+hotfix.6 at C:\src\flutter
• Framework revision 68587a0 (9 weeks ago), 2019-09-13 19:46:58 -0700
• Engine revision b863200
• Dart version 2.5.0
[√] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
• Android SDK at C:\Users\gregr\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:\Program Files\Android\Android Studio\jre\bin\java
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b03)
• All Android licenses accepted.
[√] Android Studio (version 3.5)
• Android Studio at C:\Program Files\Android\Android Studio
• Flutter plugin version 41.1.2
• Dart plugin version 191.8593
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b03)
[√] Connected device (1 available)
• LG H870 • LGH870f4432d2 • android-arm64 • Android 9 (API 28)
• No issues found!
Well, I guess that particular weirdness seems to be specific to my project.
Still grateful for any pointers on what to check - otherwise I'm okay with closing this issue.
Thank you!
HansMuller commentedon Nov 15, 2019
CC @darrenaustin
rgisi commentedon Feb 18, 2020
Hi everybody,
Just a quick update in case that helps: We built our latest release with the new stable flutter version (1.12.3+hotfix.8) and the buttons in the AboutDialog are still acting weird, albeit in a slightly different way:
Hope that helps.
Thanks for your awesome work!
rgisi commentedon Mar 27, 2020
... and with the current flutter dev version (1.15.17) as well, same behaviour still
rgisi commentedon Jun 25, 2020
Update: The "white on white" problem on Android apparently was a product of my own stupidity: A ButtonTheme with colorScheme.dark() caused it.
Now it's the default blue an Android an iOS, even when wrapping the AboutListTile directly in my Theme().
[-]AboutDialog uses default colors[/-][+]AboutListTile colors cannot be changed when wrapped with Theme widgets[/+]TahaTesser commentedon Jul 2, 2020
Code Sample
flutter doctor -v
rgisi commentedon Aug 11, 2020
Hi there. The AboutDialog now uses the app's primary color for the button text, this solves my specific problem and I'm okay with closing this issue if you think that makes sense.
(However, from my short tests it seems wrapping the AboutListTile in a Theme widget still doesn't do anything...?)
9 remaining items
[-]AboutListTile colors cannot be changed when wrapped with Theme widgets[/-][+]License page colors cannot be changed when wrapped with Theme widgets[/+][-]License page colors cannot be changed when wrapped with Theme widgets[/-][+]License page colors cannot be changed when wrapped with `Theme` widget[/+]Fix `showLicensePage` does not inherit ambient `Theme` (#161599)
Fix `showLicensePage` does not inherit ambient `Theme` (flutter#161599)
github-actions commentedon Jan 28, 2025
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of
flutter doctor -vand a minimal reproduction of the issue.