bdeSetPortFrameColor

Sets the frame color of a port.

Syntax

bdeSetPortFrameColor(port, color)

bdeSetPortFrameColor(port, red, green, blue, alpha)

Inputs

port
The port that will have it's frame color set.
Type: hwdcConnectionPoint
color
Name of the color to set the port frame color to. Can also use color of type hwt::Color.
Type: integer/hwt::Color
red
Value to set the port red frame color value to. Values can range from 0-255.
Type: integer
green
Value to set the port green frame color value to. Values can range from 0-255.
Type: integer
blue
Value to set the port blue frame color value to. Values can range from 0-255.
Type: integer
alpha
Transparency to set the port frame color to. Values can range from 0-255.
Type: integer

Examples

Set the frame color of a port to red:

          diagram = bdeGetCurrentDiagram();
          block = bdeGetSelectedBlock(diagram);
          portList = bdeGetPortsOnBlock(block);
          portX = portList{[1, 1]};
          bdeSetPortFrameColor(portX, 255, 0, 0, 255);
        
Set the frame color of a port to red:

          diagram = bdeGetCurrentDiagram();
          block = bdeGetSelectedBlock(diagram);
          portList = bdeGetPortsOnBlock(block);
          portX = portList{[1, 1]};
          bdeSetPortFrameColor(portX, 'red');