JetBrains / compose-multiplatform

Compose Multiplatform, a modern UI framework for Kotlin that makes building performant and beautiful user interfaces easy and enjoyable.
https://jetbrains.com/lp/compose-multiplatform
Apache License 2.0
16.24k stars 1.18k forks source link

is there way for Hex String Color format (#1F1F1E) to parse in Color #3768

Closed adelsaramii closed 1 year ago

adelsaramii commented 1 year ago

in android side we used android.graphics.Color.parseColor for parsing Hex String Color what is the solution in compose multiplatform

alexzhirkevich commented 1 year ago

You can do it as in android compose:

androidx.compose.ui.graphics.Color(0xFF1F1F1E)
adelsaramii commented 1 year ago

You can do it as in android compose:

androidx.compose.ui.graphics.Color(0xFF1F1F1E)

im lookin for multiplatform solution is there a way?

alexzhirkevich commented 1 year ago

Yep. It works everywhere

adelsaramii commented 1 year ago

i find the solution in case if any one need it https://stackoverflow.com/a/69604651

okushnikov commented 2 months ago

Please check the following ticket on YouTrack for follow-ups to this issue. GitHub issues will be closed in the coming weeks.