Skip to content

feat: dynamic colors - #864

Open
eames-palmer wants to merge 1 commit into
quik-sms:masterfrom
eames-palmer:feat/dynamic-colors
Open

feat: dynamic colors#864
eames-palmer wants to merge 1 commit into
quik-sms:masterfrom
eames-palmer:feat/dynamic-colors

Conversation

@eames-palmer

@eames-palmer eames-palmer commented Aug 16, 2026

Copy link
Copy Markdown

Revision 1 Changes

  1. Add support for dynamic colors across Quik.
  2. Disabled manual theme selection while dynamic colors are enabled.

Why

  • 1.1: Lets Quik follow the user’s Android system color palette.
  • 1.2: Prevents manual theme settings from conflicting with Dynamic colors.

Testing

Screenshot_20260816-001616 Screenshot_20260816-001602 Screenshot_20260816-001542 Screenshot_20260816-001641 Screenshot_20260816-001629

Related Links

  1. Addresses ✏️ [ FEAT REQ ] Add Dynamic Material You Theme #88.

@eames-palmer

Copy link
Copy Markdown
Author

Colors now match screenshots in description. Attempted a slightly different approach previously that should have been reverted prior to publishing this CR as a draft.

@eames-palmer
eames-palmer marked this pull request as ready for review August 16, 2026 22:37

@Inhishonor Inhishonor left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you very much for doing this! It appears very well done. A few minor things are reviewed below. The only main concern is whether or not we should go all the way and add support for Material 3. Love to hear your thoughts on this.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the point of this file? If we are going to merge it, we intend to support it. I would prefer you remove this.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we use Material Components attributes here instead? If you are unwilling to switch to Material colors, I can potentially do that. I would just prefer, if we are updating the theming engine, then maybe we should update to Material 3 as well?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll explore a larger migration/refactor soon, as mentioned in #864 (comment).

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as above, not needed.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.


import android.app.Activity
import android.content.Intent
import android.os.Build

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this import needed?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, I missed cleaning that up from the initial use of https://developer.android.com/reference/android/os/Build.VERSION.

Thanks for catching it!

Comment on lines +42 to +44
val dynamicColorsSupported: Boolean
get() = context.resources.getBoolean(R.bool.dynamic_colors_supported)

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think supported should matter based on a config, rather it should matter based on android version.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Initially I had this as an OS version check, but this approach felt more natural to me.

My reasoning is that we need new SDK v31 (Android 12) theme files for Dynamic Color support, and they get automatically preferred based on the OS version. So by having this bool file, the OS level determines which resource files to use and this comes along with it. This boolean will be available everywhere that the values are.

I do see your point about the file just containing a boolean though. Wrapping a version check in a properly named function could probably also be sufficient.

I'm happy to go either way if you have a strong preference.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the version check would be better, as that is the pattern in the rest of the codebase, and is more idiomatic to Android. Nice thought though.

Comment on lines +118 to +119
android.R.color.system_accent1_600,
android.R.color.system_accent1_200,

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it possible not to hardcode these?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can see if there is a more natural way to handle this when exploring the Material 3 migration.

android.R.color.system_neutral1_10,
android.R.color.system_neutral1_900,
isNight
)

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it possible to not hardcode these?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as #864 (comment).

@eames-palmer

Copy link
Copy Markdown
Author

Thank you very much for doing this! It appears very well done. A few minor things are reviewed below. The only main concern is whether or not we should go all the way and add support for Material 3. Love to hear your thoughts on this.

No problem, thank you for the thoughtful review! I considered this before starting, and my thought was that this could be an incremental step to full Material 3 and/or Material 3 Expressive support. I didn't look into that very thoroughly though, and focused on fitting this into the existing codebase.

I'll be out of town for a couple of days, but I'd be happy to look into a migration once I'm back. We can see how large the scope is and go from there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants