App 2.14.0: accent colour after the MG4 paints; car colour probe
The accent is selectable in Settings → Display: Dynamic Red (default), Volcano Orange, Holborn Blue, Racing Green, Camden Grey, Monument Silver, Arctic White and Black Pearl. White, silver and black cannot be an accent on the black screen as they are, so they become light greys and a pearl blue-grey. The accent palette is now theme attributes (attrs_accent.xml) with one overlay per paint (accents.xml), applied before the activity inflates; layouts, colour lists, drawables and the views that draw in code use them, including the red tints that were hard-coded. A change recreates the activity on the same page. Android 9 crashes on gradients with theme colours, so the battery card is built from layers. Logs → "Look for the car colour" lists the head unit's system properties that mention colour, paint or car model, to find out whether the paint colour can be read from the car. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QLJfZQZeAKAwSqViTmLzki
This commit is contained in:
@@ -0,0 +1,87 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Accent palettes after the MG4 paint colours, applied over the app theme by MainActivity
|
||||
(AccentColor.java). Each: accent, text on it, light and deep variants, the tinted card
|
||||
surface, a muted stroke and the switch track. White, silver and black cannot be an accent on
|
||||
an OLED-black screen as they are, so they become cool light greys and a pearl blue-grey. -->
|
||||
<resources>
|
||||
<!-- Dynamic Red -->
|
||||
<style name="ThemeOverlay.EV.Accent.DynamicRed" parent="">
|
||||
<item name="evAccent">#E0424C</item>
|
||||
<item name="evOnAccent">#1A0B0C</item>
|
||||
<item name="evAccentLight">#FF9A9E</item>
|
||||
<item name="evAccentDeep">#3A1215</item>
|
||||
<item name="evAccentSurface">#2A1416</item>
|
||||
<item name="evAccentStroke">#80703A3D</item>
|
||||
<item name="evAccentTrack">#5E3436</item>
|
||||
</style>
|
||||
<!-- Volcano Orange -->
|
||||
<style name="ThemeOverlay.EV.Accent.VolcanoOrange" parent="">
|
||||
<item name="evAccent">#F2762E</item>
|
||||
<item name="evOnAccent">#1F0E04</item>
|
||||
<item name="evAccentLight">#FFB68A</item>
|
||||
<item name="evAccentDeep">#3D1E0C</item>
|
||||
<item name="evAccentSurface">#2B190F</item>
|
||||
<item name="evAccentStroke">#80774A2E</item>
|
||||
<item name="evAccentTrack">#6A4430</item>
|
||||
</style>
|
||||
<!-- Holborn Blue -->
|
||||
<style name="ThemeOverlay.EV.Accent.HolbornBlue" parent="">
|
||||
<item name="evAccent">#4A86E0</item>
|
||||
<item name="evOnAccent">#04101F</item>
|
||||
<item name="evAccentLight">#A6C8FF</item>
|
||||
<item name="evAccentDeep">#10233F</item>
|
||||
<item name="evAccentSurface">#141C2A</item>
|
||||
<item name="evAccentStroke">#80354E70</item>
|
||||
<item name="evAccentTrack">#34486A</item>
|
||||
</style>
|
||||
<!-- Racing Green -->
|
||||
<style name="ThemeOverlay.EV.Accent.RacingGreen" parent="">
|
||||
<item name="evAccent">#3FA66A</item>
|
||||
<item name="evOnAccent">#04140B</item>
|
||||
<item name="evAccentLight">#9EDDB6</item>
|
||||
<item name="evAccentDeep">#0F2C1B</item>
|
||||
<item name="evAccentSurface">#132118</item>
|
||||
<item name="evAccentStroke">#80305C42</item>
|
||||
<item name="evAccentTrack">#2F5A42</item>
|
||||
</style>
|
||||
<!-- Camden Grey -->
|
||||
<style name="ThemeOverlay.EV.Accent.CamdenGrey" parent="">
|
||||
<item name="evAccent">#8C959C</item>
|
||||
<item name="evOnAccent">#0E1113</item>
|
||||
<item name="evAccentLight">#C9D0D5</item>
|
||||
<item name="evAccentDeep">#23282C</item>
|
||||
<item name="evAccentSurface">#1C1F21</item>
|
||||
<item name="evAccentStroke">#80505860</item>
|
||||
<item name="evAccentTrack">#454C52</item>
|
||||
</style>
|
||||
<!-- Monument Silver -->
|
||||
<style name="ThemeOverlay.EV.Accent.MonumentSilver" parent="">
|
||||
<item name="evAccent">#B8C0C7</item>
|
||||
<item name="evOnAccent">#121516</item>
|
||||
<item name="evAccentLight">#E3E8EC</item>
|
||||
<item name="evAccentDeep">#2A2F33</item>
|
||||
<item name="evAccentSurface">#1E2124</item>
|
||||
<item name="evAccentStroke">#80646B72</item>
|
||||
<item name="evAccentTrack">#565D63</item>
|
||||
</style>
|
||||
<!-- Arctic White -->
|
||||
<style name="ThemeOverlay.EV.Accent.ArcticWhite" parent="">
|
||||
<item name="evAccent">#ECEEF0</item>
|
||||
<item name="evOnAccent">#121314</item>
|
||||
<item name="evAccentLight">#FFFFFF</item>
|
||||
<item name="evAccentDeep">#2E3033</item>
|
||||
<item name="evAccentSurface">#202224</item>
|
||||
<item name="evAccentStroke">#80767A7E</item>
|
||||
<item name="evAccentTrack">#62666A</item>
|
||||
</style>
|
||||
<!-- Black Pearl -->
|
||||
<style name="ThemeOverlay.EV.Accent.BlackPearl" parent="">
|
||||
<item name="evAccent">#7D88A0</item>
|
||||
<item name="evOnAccent">#0B0E13</item>
|
||||
<item name="evAccentLight">#BCC5D6</item>
|
||||
<item name="evAccentDeep">#1C212A</item>
|
||||
<item name="evAccentSurface">#171A20</item>
|
||||
<item name="evAccentStroke">#804A5263</item>
|
||||
<item name="evAccentTrack">#3E4656</item>
|
||||
</style>
|
||||
</resources>
|
||||
@@ -0,0 +1,13 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- The accent palette, a theme attribute each so it can follow the chosen MG4 paint colour
|
||||
(values/accents.xml, AccentColor.java). Layouts, colour lists and drawables use ?attr/… for
|
||||
these; the fixed neutrals stay in colors.xml. -->
|
||||
<resources>
|
||||
<attr name="evAccent" format="color" />
|
||||
<attr name="evOnAccent" format="color" />
|
||||
<attr name="evAccentLight" format="color" />
|
||||
<attr name="evAccentDeep" format="color" />
|
||||
<attr name="evAccentSurface" format="color" />
|
||||
<attr name="evAccentStroke" format="color" />
|
||||
<attr name="evAccentTrack" format="color" />
|
||||
</resources>
|
||||
@@ -1,8 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- User-requested app-specific OLED palette. The accent is MG red (#E0424C, the red of the
|
||||
launcher icon); it replaced upstream's muted gold on 2026-10-17. ev_gold_surface keeps its
|
||||
name but is now the dark red tint that goes with it. ev_cyan / ev_cyan_deep likewise keep
|
||||
their names but are the light and the deep red of the same palette (no turquoise left). -->
|
||||
<!-- User-requested app-specific OLED palette: the fixed neutrals. The accent colours are theme
|
||||
attributes (values/attrs_accent.xml) that follow the chosen MG4 paint colour
|
||||
(values/accents.xml); Dynamic Red, the red of the launcher icon, is the default. -->
|
||||
<resources>
|
||||
<color name="ev_background">#000000</color>
|
||||
<color name="ev_surface">#121212</color>
|
||||
|
||||
@@ -39,6 +39,11 @@
|
||||
<string name="power_kw">%1$.1f kW</string>
|
||||
<string name="power_waiting">needs a minute of data</string>
|
||||
<string name="label_tire_unit">Tyre pressure unit</string>
|
||||
<string name="label_accent">Accent colour</string>
|
||||
<string name="label_car_color">CAR COLOUR</string>
|
||||
<string name="hint_car_color">Lists the head unit\'s settings that mention a colour, paint or car model, to find out whether the car\'s colour can be read. A photo of this list helps.</string>
|
||||
<string name="btn_car_color">Look for the car colour</string>
|
||||
<string name="car_color_none">Nothing colour-related found</string>
|
||||
<string name="energy_kwh">%1$.1f kWh</string>
|
||||
<string name="energy_trip_note">net, after recuperation</string>
|
||||
<string name="energy_trip_waiting">once the car is on</string>
|
||||
|
||||
@@ -39,19 +39,19 @@
|
||||
<item name="boxCornerRadiusTopEnd">16dp</item>
|
||||
<item name="boxCornerRadiusBottomStart">16dp</item>
|
||||
<item name="boxCornerRadiusBottomEnd">16dp</item>
|
||||
<item name="hintTextColor">@color/ev_accent</item>
|
||||
<item name="hintTextColor">?attr/evAccent</item>
|
||||
<item name="endIconTint">@color/ev_text_secondary</item>
|
||||
<item name="helperTextTextAppearance">@style/Text.EV.Secondary</item>
|
||||
</style>
|
||||
<style name="Text.EV.Eyebrow" parent="Text.EV.SectionHeader">
|
||||
<item name="android:textSize">16sp</item>
|
||||
<item name="android:textColor">@color/ev_accent</item>
|
||||
<item name="android:textColor">?attr/evAccent</item>
|
||||
<item name="android:fontFamily">sans-serif-medium</item>
|
||||
<item name="android:letterSpacing">0.12</item>
|
||||
</style>
|
||||
<style name="Text.EV.VersionBadge" parent="Text.EV.Secondary">
|
||||
<item name="android:background">@drawable/bg_version_badge</item>
|
||||
<item name="android:textColor">@color/ev_cyan</item>
|
||||
<item name="android:textColor">?attr/evAccentLight</item>
|
||||
<item name="android:textSize">13sp</item>
|
||||
<item name="android:fontFamily">sans-serif-medium</item>
|
||||
<item name="android:paddingStart">10dp</item>
|
||||
|
||||
@@ -22,8 +22,8 @@
|
||||
<item name="android:textAllCaps">false</item>
|
||||
<item name="android:fontFamily">sans-serif-medium</item>
|
||||
<item name="android:letterSpacing">0.01</item>
|
||||
<item name="backgroundTint">@color/ev_accent</item>
|
||||
<item name="android:textColor">@color/ev_on_accent</item>
|
||||
<item name="backgroundTint">?attr/evAccent</item>
|
||||
<item name="android:textColor">?attr/evOnAccent</item>
|
||||
<item name="elevation">0dp</item>
|
||||
<item name="shapeAppearanceOverlay">@style/ShapeAppearanceOverlay.EV.Button</item>
|
||||
<item name="android:minHeight">@dimen/touch_target</item>
|
||||
@@ -65,7 +65,7 @@
|
||||
16sp floor without shouting. -->
|
||||
<style name="Text.EV.SectionHeader" parent="TextAppearance.Material3.LabelLarge">
|
||||
<item name="android:textSize">@dimen/text_label</item>
|
||||
<item name="android:textColor">@color/ev_accent</item>
|
||||
<item name="android:textColor">?attr/evAccent</item>
|
||||
<item name="android:letterSpacing">0.12</item>
|
||||
<item name="android:textStyle">bold</item>
|
||||
</style>
|
||||
|
||||
@@ -3,15 +3,23 @@
|
||||
|
||||
<!-- User-requested OLED theme. MainActivity fixes night mode for system widgets too. -->
|
||||
<style name="Theme.EVABRPUploader" parent="Theme.Material3.DayNight.NoActionBar">
|
||||
<item name="colorPrimary">@color/ev_accent</item>
|
||||
<item name="colorSecondary">@color/ev_cyan</item>
|
||||
<item name="colorControlActivated">@color/ev_cyan</item>
|
||||
<!-- Dynamic Red; MainActivity lays the chosen accent over these (values/accents.xml). -->
|
||||
<item name="evAccent">#E0424C</item>
|
||||
<item name="evOnAccent">#1A0B0C</item>
|
||||
<item name="evAccentLight">#FF9A9E</item>
|
||||
<item name="evAccentDeep">#3A1215</item>
|
||||
<item name="evAccentSurface">#2A1416</item>
|
||||
<item name="evAccentStroke">#80703A3D</item>
|
||||
<item name="evAccentTrack">#5E3436</item>
|
||||
<item name="colorPrimary">?attr/evAccent</item>
|
||||
<item name="colorSecondary">?attr/evAccentLight</item>
|
||||
<item name="colorControlActivated">?attr/evAccentLight</item>
|
||||
<item name="android:fontFamily">sans-serif</item>
|
||||
<item name="android:windowLightStatusBar">false</item>
|
||||
<item name="android:windowLightNavigationBar">false</item>
|
||||
<item name="android:navigationBarColor">@color/ev_background</item>
|
||||
<item name="android:forceDarkAllowed" tools:targetApi="q">false</item>
|
||||
<item name="colorOnPrimary">@color/ev_on_accent</item>
|
||||
<item name="colorOnPrimary">?attr/evOnAccent</item>
|
||||
<item name="colorSurface">@color/ev_surface</item>
|
||||
<item name="colorSurfaceContainer">@color/ev_surface_raised</item>
|
||||
<item name="android:colorBackground">@color/ev_background</item>
|
||||
|
||||
Reference in New Issue
Block a user