INNER CODE UNIT · Python
get_random_color
crocs-muni/JCAlgTest · AlgTest_Process/cplc.py:209
def get_random_color():
"""
Returns randomly selected color out of defined
@returns color string
"""
colors = ['green','red', 'blue', 'magenta', 'brown', 'darkgreen', 'black', 'gray', 'gold', 'chocolate', 'darkorange1', 'deeppink1', 'cadetblue']
return colors[random.randint(0, len(colors) - 1)]
def get_random_edge_style():
"""
Returns randomly selected edge style
@returns edge style string
"""
edge_styles = ['solid', 'dashed', 'bold']
return edge_styles[random.randint(0, len(edge_styles) - 1)]