alias_api.AlDistanceLocator
- class alias_api.AlDistanceLocator
Bases:
AlLocatorDisplays the distance between two locators.
This locator is used to display and find the distance between any two point locators (AlPointLocator). If any of the two point locators on which this locator depends is deleted, this locator is automatically deleted. This class contains methods to create the locator, query the distance, and set the display attributes of the locator.
- copy_wrapper(self: alias_api.AlDistanceLocator) alias_api.AlObject
Return an exact duplicate of this AlDistanceLocator wrapper.
- create(self: alias_api.AlDistanceLocator, start_point: AlPoint, end_point: AlPoint, true_display: SupportsInt = True) int
Create a new AlDistanceLocator in the Alias Universe.
- distance(self: alias_api.AlDistanceLocator) tuple[int, float, float, float]
- end_point(self: alias_api.AlDistanceLocator) AlPoint
Returns the ending Point of this Distance locator. However, if the distance locator is not valid, None is returned.
- length(self: alias_api.AlDistanceLocator) tuple[int, float]
Calculate the length (in centimeters) of the distance vector.
- offset(self: alias_api.AlDistanceLocator) tuple[int, float]
Get the offset of the locator display.
- Parameters
value (float) – The display offset.
- Returns
The status code result of the operation: Success - the offset was found InvalidObject - the object is not valid
- set_offset(self: alias_api.AlDistanceLocator, offset: SupportsFloat) int
Set the offset in the locator display.
- Parameters
offset (float) – The value of the offset.
- Returns
The status code result of the operation: Success - the offset was set InvalidObject - the object is not valid
- set_true_display(self: alias_api.AlDistanceLocator, value: SupportsInt) int
Set the display type of this Distance locator. If the distance locator is not valid, None is returned.
- start_point(self: alias_api.AlDistanceLocator) AlPoint
Returns the starting Point of this Distance locator. However, if the distance locator is not valid, None is returned.
- true_display(self: alias_api.AlDistanceLocator) tuple[int, int]
Returns 1 if true display is set, else 0.
- type(self: alias_api.AlDistanceLocator) alias_api.AlObjectType
Return the AlDistanceLocator type identifier.