Re: std/graphcst.e colors in OSX

new topic     » goto parent     » topic index » view thread      » older message » newer message

Shoot! No joy It's curious though, because the LSCOLORS env. var. for use with `ls', works perfectly - it displays all the ANSI colors in both xterm and the Apple terminal.

Here's the code that I'm using:

-- demo program 52 
-- from Beginners Guide to Euphoria 
 
include std/graphics.e 
integer foreground_color 
sequence list_of_colors, already_used 
 
clear_screen() 
 
list_of_colors = {"BLUE","GREEN","CYAN","RED","MAGENTA","BROWN", 
                   "WHITE","GRAY","BRIGHT_BLUE","BRIGHT_GREEN", 
                   "BRIGHT_CYAN","BRIGHT_RED","BRIGHT_MAGENTA", 
                   "YELLOW","BRIGHT_WHITE"} 
 
already_used = {} 
 
for ix = 1 to 10 do 
     foreground_color = rand(15) 
     while find(foreground_color,already_used) do 
          foreground_color = rand(15) 
     end while 
     already_used = already_used & foreground_color 
     text_color(foreground_color) 
     printf(1, "Text in %s\n",{list_of_colors[foreground_color]}) 
end for 

Can anybody see a problem with it that would send the colors into a tail-spin? duke

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu