Code Monkey home page Code Monkey logo

cyotek.windows.forms.colorpicker's People

Contributors

cyotek avatar gfolchez avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

cyotek.windows.forms.colorpicker's Issues

Color Picking Error in Windows 10

Actually, I used your library for making a Color Picking basic application in C#. OK.. Works great in Windows 8,8.1,7. But now when I upgrade my PC to Win 10, the same application I made using your lib giving error in color picking, I mean when I point the picker to white color it gives me black color.. and such things.. is happening. Plzz help !

Thanks in Advance !

ColorGrid modifying added custom color

Hi,
A big thank you for your tool, I love it!
I'm using the colorgrid, and I'm adding the customcolors based on the latest customcolorcollection that the user used. So everytime my dialog is closed with the OK button, the software keeps the CustomColors collection in a public collection. Then when the user reopen the color grid, his latest customcolors are reinserted like this
If MyCustomColorCollection IsNot Nothing Then my_colorpicker.CustomColors = MyCustomColorCollection
If the user dblclick on those custom colors, modify one and click ok, i get this message
System.Collections.Generic.KeyNotFoundException: 'The given key was not present in the dictionary.'

and the line 482 of colorgrid.cs is highlighted.
If I'm doing something wrong, let me know. I would like to use those user customecolor as much as possible

Color Picker returns wrong color

Picking the main color (in Inkscape rgb(87, 106, 121)) returns rgb(87, 106, 120) .
And that is only ONE example.

Using Cyotek.Windows.Forms.ColorPicker v 1.7.2.

Inkscape:
image

Colorpicker
image

Another wrong color: Inkscape rgb(226,230,238) will be picked up as rgb(224, 229, 237).
Confirmed with screenshots and color picker from paint.NET.

Bottom/right sliders one pixel out of bounds

#28 introduced an issue where the slider drag handles on the right or bottom are one pixel out of position. 🤦

(Or, the issue was there all along but I never noticed as previously it was a solid colour. Either way, needs fixing!)

sliderbug

Westwood .PAL palette

Hello.
First of all, thank you for creating this software.

Here is my request:
I am a fan and player of (old) Command & Conquer games. The community is still very active and there are many people who create "mods" for these games. Yes, even in 2017. 😊

Here are some websites/forums to prove that there are still many people who are interested in modding these games:
http://ppmsite.com > https://ppmforums.com
http://www.openra.net > http://www.sleipnirstuff.com/forum
http://cncnz.com > http://forums.cncnz.com
https://cncnet.org > https://forums.cncnet.org

Most of these games were developped by Westwood Studios, a game company which litteraly created the RTS (strategy) genre.

Why do I tell you all that? Well, because I think your software could be really useful for modders.
These 2D games use .SHP and .VXL files for units/tanks/buildings.

SHP files contain many frames (256 colors indexed images), used for the animations of these sprites. But to create .SHP files, palette files are needed: C&C games use Westwood .PAL palette files.

Tools used by modders:

Here is some documentation about this .PAL file format:
https://www.gamefaqs.com/pc/196957-command-and-conquer/faqs/1835 (2nd paragraph)
https://github.com/OpenRA/OpenRA/wiki/Palettes-and-Remaps

According to what one of the OpenRA developers told me:

These palettes are standard vga palettes. They are a bucket of bytes that contain 6bit per channel brightness values which gets pushed directly to a block of memory on the graphics card.

You can download these palette files here: LKOccallpal.zip. I got them from this ppmforums thread.

And here is how OpenRA supports this file format (OpenRA is an open-source RTS game engine coded in C#):
https://github.com/OpenRA/OpenRA/blob/bleed/OpenRA.Game/Graphics/Palette.cs

That's why I ask you (if you agree, please say yes) to support Westwood .pal files in your software.

This "feature request" matters a lot to me because supporting this palette filetype will let modders convert .ACT/.ACO/.ASE/.GPL to Westwood .PAL files and vice versa.

Black != ff000000

Named colours don't match non-named ones. Shows up in the ToolStrip ColorGrid demo where the palette uses the Office 2010 colour set (which includes black as ff000000) and the Color property is set to Color.Black. This then ends up as a custom colour instead of using the existing entry in the palette.

Color of the bar for value L is not changing.

I compared some color selectors and I mentioned that you bar for value L is not changing it's color.
If you use for example Paint-NET you see that the bar for the V value (I know L is not V but that doesn't matter in that case) is changing it's color matching to what color you would get if you move the slider on it.
Yours is always black to white in gray scale but if I have a red tone it should be black to white in a red gradient. .

Refreshing ColorGrid in code - no refresh = crasj

Hi - thanks for this library - it's really good.

I'm using it to build a custom ColorPicker. One problem I'm having is that I manipulate the custom colors in code (in colorgrid), but can't find a way to refresh it in code once custom colors are added or removed. The only way I can find is by changing the color via the colorwheel or coloreditor (all linked via cloreditor manager). The change of color then (I assume) forces a redraw of the colorgrid.

Another problem is that if I don't refresh manually and change the custom colors, this can cause a crash when you mouseover the colors.

Here's a vid of my loading some custom colors - you'll see it doesn't refresh until I click the colorwheel:

https://youtu.be/-PdJKmOl6-Y?t=134

I tried various permutation of control.invalidate(true); control.refresh + control.update on the colorgird and parent controls, but nothing forces a refresh.

I'd really appreciate a answer as apart from this - your library's perfect!

Thanks
Steve

SmoothingMode.AntiAlias doesn't work on Color Wheel

The smoothing mode specifies whether lines, curves, and the edges of filled areas use smoothing (also called antialiasing). One exception is that path gradient brushes do not obey the smoothing mode. Areas filled using a PathGradientBrush are rendered the same way (aliased) regardless of the SmoothingMode property.

How to fix it?

if Color=Color.Black ColorPickerDialog doesn't work correctly

 ColorPickerDialogDemoForm.cs  --->  BrowseColorButton_Click
 Color = Color.FromArgb(255, 0, 0, 0)

ColorPickerDialog doesn't work correctly。

 HslColor hc = new HslColor(Color.FromArgb(255, 0, 0, 0));
 if (hc.L == 0) hc.L = 0.5;   
 Color color = hc.ToRgbColor();

ColorPickerDialog works fine.

ColorPickerDialog does not support Color.Black?

Custom Color boxes not being painted

In ColorGrid.cs on line 558

 if (this.ColorRegions.TryGetValue(colorCount + 1, out bounds) && e.ClipRectangle.IntersectsWith(bounds))

the +1 should be +i instead. Otherwise only the 2nd custom color will ever be painted:

 if (this.ColorRegions.TryGetValue(colorCount + i, out bounds) && e.ClipRectangle.IntersectsWith(bounds))

Color wheel jumps a lot in ColorEditManager Component Demonstration

When I move the S slider the color marker of the wheel sometimes jumps around, same when using the L slider.
Do you bound the end color to the wheel?
Usually the wheel is only attached to the H and S slider and L is ignored. Also L is often not even set if you change the color selector in the wheel. On your example it is always set to 50 which is annoying.

For example take a look how Pain.NET color picker behaves and you see what I mean.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.