colors

CIELab Colorspace conversion

Is there a canonical colorspace conversion library? I can't find any pre-existing solutions. Is CIELab conversion is too obscure? ...

Preview colours in Emacs-ESS

I accidentally managed to get colour names, #HEX, and a colour preview in Emacs. Don't have a bloody idea how, must've pressed some keybinding or menu item... But, now I can't seem to find where's that feature... I'm quite sure I wasn't hallucinating, so it's gotta be there, under some keystroke that I can't reproduce!!! =) ...

Changing UI color in Eclipse

I'm aware of this topic: I've used it to change most of the editor colors, and that's great. But that wasn't enought, there's still too much white (and I need to change it because it hurts my eyes). I've searched in the preferences (both using Eclipse itself and editing the files) for instances of while (255,255,255) and changed them a...

Override colorscheme

I often find myself wanting to change just something little in a colorscheme, but i don't want to edit the original file. I tried putting my change in '~/.vim/after/colors/blah.vim', but that doesn't work for me. Example, I want to change the CursorLine highlight in BusyBee.vim.. ~/.vim/colors/BusyBee.vim I create the file '~/.vim/a...

What is the target color profile in Image.FromFile?

I am curious what the useEmbeddedColorManagement parameter in System.Drawing.Image.FromFile actually does. This parameter directory corresponds to a GDI+ parameter in the same method of the same class. So debugging .NET source does not lead anywhere. If my understanding of color profiles is correct, a color profile is basically a mappin...

Android Color Picker

Does anyone know of a quick color picker widget that I could grab to use in my application? I've seen one in a few different applications that has a wheel with colors, and that you tap in the center to select, but I'm not sure where to find it. Google brings up nothing. Any color picker would be fine though. Thanks. ...

How does one convert 16-bit RGB565 to 24-bit RGB888?

I’ve got my hands on a 16-bit rgb565 image (specifically, an Android framebuffer dump), and I would like to convert it to 24-bit rgb888 for viewing on a normal monitor. The question is, how does one convert a 5- or 6-bit channel to 8 bits? The obvious answer is to shift it. I started out by writing this: puts("P6 320 480 255"); uint16_...

PHP: Convert shorthand Hex Colors to Regular

I'm trying to make a function that will take short hand hex color to the long hex color. For example if someone submits "f60" it will convert to "ff6600". I understand I need to repeat each number as itself, but what is the most efficient way to do this? Thank you. ...

Colour instead of color?

I'm working on a game engine in C++ and I have methods like setColour and things that use british grammar. While I was thinking how C++ compilers mostly use the english language (correct me if I'm wrong) and how most APIs use american grammar, should I go with the flow and continue the unofficial standard in the grammar programmer high c...

Graph coloring Algorithm

From wiki http://en.wikipedia.org/wiki/Graph_coloring In its simplest form, it is a way of coloring the vertices of a graph such that no two adjacent vertices share the same color; this is called a vertex coloring. Similarly, an edge coloring assigns a color to each edge so that no two adjacent edges share the same col...

How can I get colored output with printf and Perl's Term::ANSIColor?

Hello, is there a way to get with printf colored output? #!/usr/bin/perl use warnings; use strict; use Term::ANSIColor; printf "%4.4s\n", colored( '0123456789', 'magenta' ); Output: (only newline) ...

Where can I find a jQuery color animation plugin?

I need an up-to-date jQuery color animation plugin that works in IE 8. I tried using the one at http://plugins.jquery.com/project/color but it causes errors like "Invalid property value." in the following line of code from color.js: fx.elem.style[attr] = "rgb(" + [ Math.max(Math.min( parseInt((fx.pos * (fx.end[0] - fx.start[0])) + f...

Databinding custom XML serializable Color class in C#

I have a class, SerializableColor, to allow me to XML serialize Colors. public class SerializableColor { // omitted constructors, etc. ... [XmlIgnore] public Color Color { get { return Color.FromArgb(this.Alpha, this.Red, this.Green, this.Blue); } set { this.Alpha = value.A; ...

silverlight datagrid row highlight dynamically

Hello, I have a datagrid populated with data and holding 8 columns. One of those column is "Verification Status". Now this "Verification Status" column contains Values "Yes" or "No". What I want to achieve is that when the grid is loading based on the values (Yes or No) I want to dynamically change the datagrid's row background color to...

Convert RGB Colour to OLE_Color

I have the unenviable task of maintaining an ActiveX control that expects OLE_Colors as the back/for colour of the control. Is there a tool or a .NET code sample that will convert from an RGB colour (or a hex colour) to an OLE_Color? ...

WPF global Controls color changes

Hi ! Suppose you want to override the Background / Foreground / TextSelection ... Colors for your WPF Controls. In my opinion, you need 2 things: Override the SystemColors in your Resources files Override the ControlTemplates (by adding additional Triggers etc.) The reason for this is, that some Controls in .NET 3.5 don't all...

CIE XYZ colorspace: do I have RGBA or XYZA?

I plan to write a painting program based on linear combinations of xy plane points (0,1), (1,0) and (0,0). Such system works identically to RGB, except that the primaries are not within the gamut but at the corners of a triangle that encloses the entire gamut. I have seen the three points being referred to as X, Y and Z (upper case) so...

Compute hex color code for an arbitrary string

Heading Is there a way to map an arbitrary string to a HEX COLOR code. I tried to compute the HEX number for string using string hashcode. Now I need to convert this hex number to six digits which are in HEX color code range. Any suggestions ? String [] programs = {"XYZ", "TEST1", "TEST2", "TEST3", "SDFSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSS...

Choosing colors that convert nicely to greyscale

If I'm designing af tool that must "screenshot" well for printed documentation, can I easily choose colors that look different even when printed in greyscale? EDIT: I was hoping for some easy-to-use palette or tool, but the inputs given already is very insightfull for sure ...

Custom Delphi Colours

If i want to set a colour property to something thats non-standard (i.e. not something like clBlack or clRed) how can i do this? Can i set something like hexadecimal colours? ...