background preloader

Tools

Facebook Twitter

The first commented line is your dabblet’s title ✿ dabblet.com. RGB-to-Hex Color Converter. RGB-to-Hex Conversion Question: How do I convert RGB values of a color to a hexadecimal string? Answer: The RGB-to-hexadecimal converter algorithm is simple: make sure that your values are in the range 0...255, convert R, G, B to hex strings, and then concatenate the three hex strings together.

Convert RGB to Hex color values here: function rgbToHex(R,G,B) {return toHex(R)+toHex(G)+toHex(B)} function toHex(n) { n = parseInt(n,10); if (isNaN(n)) return "00"; n = Math.max(0,Math.min(n,255)); return "0123456789ABCDEF".charAt((n-n%16)/16) + "0123456789ABCDEF".charAt(n%16); } Notes: The script parses the input R, G, B values as integers using the standard function parseInt(string,10); the second, optional argument 10 specifies that the value must be parsed as a decimal number.

RGB/hex codes for named colors supported in most browsers are listed below: See also: Sizzle JavaScript Selector Library. Font dragr | Drag and drop font testing. Transforms. CSS3 Please! The Cross-Browser CSS3 Rule Generator. Selectors Test, CSS3 .info. Home / About Us After starting the test-suite it will automatically run a large number of small tests which will determine if your browser is compatible with a large number of CSS selectors. If it is not compatible with a particular selector it is marked as such. You can click on each CSS selector to see the results, including a small example and explanation for each of tests.

Because it is technically not possible to simulate certain user interactions the test is limited to CSS selectors that are not dependent on user interactions. Update June 30th, 2010: The tests for the :visited and :link selectors have been removed from the test-suite. CSS3 Gradient Generator. HTML5 & CSS3 Support, Web Design Tools & Support - FindMeByIP - CSS3 & HTML5 Browser Support.

Modernizr. CSS3 Generator. Button Maker. CSS Border Radius Generator. Cascader - Cleaning Up The Web. Css3 drop shadow generator. CSS3 PIE: CSS3 decorations for IE.