Line

From HSYCO
Jump to navigation Jump to search
Note  For a description and a complete list of UI Objects, see UI Objects.

A line.

Parameters

  • id: the object's ID, used by UISets
  • startpoint: the line's first point. Coordinates are relative to the interface. Use the pixel coordinates format (x<x>y<y>)
  • endpoint: the line's second point. Coordinates are relative to the interface. Use the pixel coordinates format (x<x>y<y>)
  • strokecolor: CSS color of the stroke (e.g. #ff0000, "red" or rgb(255,0,0))
  • strokewidth: the width of the stroke in pixels
  • cap: the shape to be used at both ends of the line
  • dash: a list of comma and/or white space separated <length>s and <percentage>s that specify the lengths of alternating dashes and gaps. If an odd number of values is provided, then the list of values is repeated to yield an even number of values. Thus, 5,3,2 is equivalent to 5,3,2,5,3,2.

Syntax

(line[!<id>] <startpoint>; <endpoint>; <strokecolor>; <strokewidth>; <cap>; <dash>)

UI Attributes

Common attributes

Name Value Description
visible true Default. Show the object
false Hide the object
blink true | slow Blink the object at a slow speed
fast Blink the object at a fast speed
false Stop the blinking
opacity 0.0 ... 1.0 Object opacity from 0 (not visible) to 1 (fully visible)
rotation 0 ... 360 Object rotation in degrees. By default a line object is rotated around the center point
rotationorigin start Rotate the line around its first point
end Rotate the line around its second point
<x-axis> <y-axis> Rotate the line around a specific axis:
x-axis Defines where the view is placed at the x-axis. Possible values:
  • left
  • center
  • right
  • length in pixels (e.g. 20px)
  • % (e.g. 2%)
y-axis Defines where the view is placed at the y-axis. Possible values:
  • top
  • center
  • bottom
  • length in pixels (e.g. 20px)
  • % (e.g. 2%)


Line attributes

Name Value Description
startpoint x<x>y<y> The line's first point specified as x/y coordinates. Coordinates are relative to the interface.. E.g. x5y10
endpoint x<x>y<y> The line's first point specified as x/y coordinates. Coordinates are relative to the interface.. E.g. x55y70
strokecolor <CSS color> CSS color of the stroke (e.g. #ff0000, "red" or rgb(255,0,0))
strokewidth <width> Width of the stroke in pixels
cap butt Use a "butt" shape at both ends of the line
round Use a "round" shape at both ends of the line
square Use a "square" shape at both ends of the line