VS:GetGradientSliderData

From Vectorworks Developer
Revision as of 14:30, 12 August 2013 by Root (talk | contribs) (1 revision)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

.VectorScript|VectorScript ..VS:Function Reference|Function Reference ..VS:Function_Reference_Appendix|Appendix

Description

Gets the spot position, midpoint position and color of the specified gradient slider segment.

PROCEDURE GetGradientSliderData(
dialogID :LONGINT;
componentID :LONGINT;
segmentIndex :INTEGER;
VAR spotPosition :REAL;
VAR midpointPosition :REAL;
VAR red :LONGINT;
VAR green :LONGINT;
VAR blue :LONGINT);
def vs.GetGradientSliderData(dialogID, componentID, segmentIndex):
    return (spotPosition, midpointPosition, red, green, blue)

Parameters

dialogID LONGINT Index to the dialog layout that contains the gradient slider component.
componentID LONGINT Index to a specific gradient slider component.
segmentIndex INTEGER Segment from which to get the data.
spotPosition REAL Position of the segment's color marker relative to left-most point of the slider.
midpointPosition REAL Position of the segment's midpoint marker relative to color marker immediately to left.
red LONGINT Red component of the color spot's color.
green LONGINT Green component of the color spot's color.
blue LONGINT Blue component of the color spot's color.

Example

VectorScript

GetGradientSliderData(dialogID, componentID, 4, 0.7, 0.3, 255, 255, 255);

Python

vs.GetGradientSliderData(dialogID, componentID, 4)

Version

Availability: from VectorWorks10.0