Bridges-Python  3.2.0
Bridges(PythonAPI)
Public Member Functions | Public Attributes | List of all members
bridges.element_visualizer.ElementVisualizer Class Reference

Public Member Functions

def __init__ (self, color="green", shape="circle", size=10.0, opacity=1.0)
 ElementVisualizer constuctor. More...
 
def size (self)
 Getter for the elements size. More...
 
def size (self, size)
 Setter for the size of the element. More...
 
def color (self)
 Getter for the color of the element in the bridges visualization. More...
 
def color (self, args, kwargs)
 Setter for the color of the element in the bridges visualization. More...
 
def shape (self)
 Getter for the shape of the element. More...
 
def shape (self, a_shape)
 Setter for the shape of the element. More...
 
def opacity (self)
 Getter for the opacity of the element. More...
 
def opacity (self, opacity)
 Setter for the opacity of the element. More...
 
def set_location (self, x, y)
 Setter for the location of the element. More...
 
def location_x (self)
 Getter for the X location of element. More...
 
def location_y (self)
 Getter for the y location of the element. More...
 

Public Attributes

 prop
 
 color
 

Constructor & Destructor Documentation

◆ __init__()

def bridges.element_visualizer.ElementVisualizer.__init__ (   self,
  color = "green",
  shape = "circle",
  size = 10.0,
  opacity = 1.0 
)

ElementVisualizer constuctor.

(str) color: color for this element (str) shape: the shape of the element (float) size: the element size (float) opacity: the element opacity

Returns
None

Member Function Documentation

◆ color() [1/2]

def bridges.element_visualizer.ElementVisualizer.color (   self,
  Color 
)

Getter for the color of the element in the bridges visualization.

Returns
Color Color object representing the color of the element

◆ color() [2/2]

def bridges.element_visualizer.ElementVisualizer.color (   self,
  args,
  kwargs,
  None 
)

Setter for the color of the element in the bridges visualization.

(optional) list: requires either 3 ints 0-255 for RGB and an optional float 0.0-1.0 for alpha EX: color = [0, 255, 0, 1.0] (optional) str: string representing the element color. from web colors: https://developer.mozilla.org/en-US/docs/Web/CSS/color_value

Returns
None
Exceptions
ValueErrorif the color name provided is not available

◆ location_x()

def bridges.element_visualizer.ElementVisualizer.location_x (   self)

Getter for the X location of element.

Returns
int as the x location

◆ location_y()

def bridges.element_visualizer.ElementVisualizer.location_y (   self)

Getter for the y location of the element.

Returns
int as the y position

◆ opacity() [1/2]

def bridges.element_visualizer.ElementVisualizer.opacity (   self,
  float 
)

Getter for the opacity of the element.

Returns
float representing the opacity

◆ opacity() [2/2]

def bridges.element_visualizer.ElementVisualizer.opacity (   self,
  opacity,
  None 
)

Setter for the opacity of the element.

(float) opacity: the opacity to be applied

Returns
None

◆ set_location()

def bridges.element_visualizer.ElementVisualizer.set_location (   self,
  x,
  y 
)

Setter for the location of the element.

(int) x: x location (int) y: y location

Returns
None

◆ shape() [1/2]

def bridges.element_visualizer.ElementVisualizer.shape (   self,
  str 
)

Getter for the shape of the element.

Returns
str reperesenting the type of shape

◆ shape() [2/2]

def bridges.element_visualizer.ElementVisualizer.shape (   self,
  a_shape 
)

Setter for the shape of the element.

(str) a_shape: the name of shape for element

◆ size() [1/2]

def bridges.element_visualizer.ElementVisualizer.size (   self,
  float 
)

Getter for the elements size.

Returns
float the size

◆ size() [2/2]

def bridges.element_visualizer.ElementVisualizer.size (   self,
  size,
  None 
)

Setter for the size of the element.

(float) size: the elements desired size

Returns
None

Member Data Documentation

◆ color

bridges.element_visualizer.ElementVisualizer.color

◆ prop

bridges.element_visualizer.ElementVisualizer.prop

The documentation for this class was generated from the following file: