colorpicker-compose icon indicating copy to clipboard operation
colorpicker-compose copied to clipboard

HsvColorPicker selectByColor() can't set color (0,1,1)

Open j-jmz opened this issue 1 year ago • 3 comments

  • Library Version [e.g. v1.0.7]
  • Affected Device(s) [Samsung Galaxy s20 with Android 13, Emulator Pixel 7Pro wit Android 14]

Describe the Bug:

Tried using the setByColor() method to set color Color(0.0, 1.0, 1.0, 1.0, sRGB IEC61966-2.1) into the HsvColorPicker, it was not set.

Apparently it calculates the coordinates to be set by the setByCoordinate() method, that color result in a coordinate (x=0.0, y=627.0) which makes extractPixelHsvColor() function in the setByCoordinate() method to return Color.Transparent and failing to set the color.

Expected Behavior:

I expected the color Color(0.0, 1.0, 1.0, 1.0, sRGB IEC61966-2.1) to be set in the HsvColorPicker.

j-jmz avatar Jan 23 '24 12:01 j-jmz

There's the same issue for other colors like #55aa00, this prevent pre selecting some colors and adding an edit textfield.

Tolriq avatar Mar 27 '24 16:03 Tolriq

Hey guys, would you try to build with the recent release, 1.1.0?

skydoves avatar Jun 29 '24 13:06 skydoves