Random :)

  • ScottG
  • Proficient
  • Proficient
  • ScottG
  • Posts: 476

Post 3+ Months Ago

So on my wall at work I have this paper. On this paper I wrote this.
Code: [ Select ]
for 6x's
  for 6x's
    for 6x's
  1. for 6x's
  2.   for 6x's
  3.     for 6x's

I wrote this years ago and it has been pinned the the wall ever since. I know that this doesn't seem like it means much but it does. This is how to make 216 color web safe color swatches. So here is a fiddle of the actual swatch builder in a stripped down form http://jsfiddle.net/x6fKK/
  • Anonymous
  • Bot
  • No Avatar
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post 3+ Months Ago

  • ScottG
  • Proficient
  • Proficient
  • ScottG
  • Posts: 476

Post 3+ Months Ago

I know that its missing 40 colors that is the nature of this process in my color picker i did write the other 40 color in be doing something like this and then combined them so that there would be 256 colors.

JAVASCRIPT Code: [ Select ]
var odd_indexs = new Array('11','22','44','55','77','88','AA','BB','DD','EE');
 
for(i=0; i<odd_indexs.length; i++) {
   
   index = odd_indexs[i];
   
   // Make the colors.
   var reds = '#' + index + '0000';
   var greens = '#00' + index + '00';
   var blues = '#0000' + index;
   var grays = '#' + index + index + index;
   
   alert(reds + ' ' + greens + ' ' + blues + ' ' + grays);
           
}
 
  1. var odd_indexs = new Array('11','22','44','55','77','88','AA','BB','DD','EE');
  2.  
  3. for(i=0; i<odd_indexs.length; i++) {
  4.    
  5.    index = odd_indexs[i];
  6.    
  7.    // Make the colors.
  8.    var reds = '#' + index + '0000';
  9.    var greens = '#00' + index + '00';
  10.    var blues = '#0000' + index;
  11.    var grays = '#' + index + index + index;
  12.    
  13.    alert(reds + ' ' + greens + ' ' + blues + ' ' + grays);
  14.            
  15. }
  16.  
  • ScottG
  • Proficient
  • Proficient
  • ScottG
  • Posts: 476

Post 3+ Months Ago

You know thinking about it now I could have gone about it in a completely different way and got the desired effect.

That's one reason I don't like looking at my old code. I wrote this like 4 years ago. lol

Post Information

  • Total Posts in this topic: 3 posts
  • Users browsing this forum: No registered users and 110 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
cron
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.