garretyoder / Colorful

Android runtime theme library
Apache License 2.0
2.13k stars 193 forks source link

Feedback colorful problem #22

Closed tcqq closed 6 years ago

tcqq commented 6 years ago
  1. How to get primary and accent color res?
  2. ThemeColor have't white and black color ThemeColor.WHITE, how to set primary or accent color to white or black color?
stcojo commented 6 years ago

Is this your first day coding for Android?

tcqq commented 6 years ago

@cojoc07 These methods exist in the previous version, Do you have any other solution to the above problem?

garretyoder commented 6 years ago
Colorful().getPrimaryColor().getColorPack().light().asInt()

I recommend you use the power of your IDE's code completion to poke around Colorful and Android's platform APIs.

tcqq commented 6 years ago

@garretyoder Thanks, now I know should be how to get primary and accent color:-), But I didn't find white or black in ThemeColor, How should I set PrimaryColor to white or black?

garretyoder commented 6 years ago

White or black is something I didn't add in v2 because I didn't see a point. If it's something you really require, I can add it this weekend for v2.1 because it'll only take me a few moments.

tcqq commented 6 years ago

Yes, white and black are useful, see the picture below.

Primary Color: BLUE Accent Color: PINK Theme: DARK image

Primary Color: WHIT Accent Color: BLUE Theme: LIGHT image

garretyoder commented 6 years ago

White/Black are now added courtesy of a PR, which will be included in the 2.1 release that I'll probably push later today.

tcqq commented 6 years ago

Thanks:)