Qyoto  4.0.6
Qyoto is a C# language binding for Qt
 All Classes Namespaces Functions Variables Typedefs Enumerations Properties
QtGui.QLinearGradient Class Reference

The QLinearGradient class is used in combination with QBrush to specify a linear gradient brush. More...

Inheritance diagram for QtGui.QLinearGradient:
Collaboration diagram for QtGui.QLinearGradient:

Public Member Functions

 QLinearGradient ()
 
 
 QLinearGradient (QLinearGradient copy)
 
 QLinearGradient (QPointF start, QPointF finalStop)
 
 
 QLinearGradient (double xStart, double yStart, double xFinalStop, double yFinalStop)
 
 
override void CreateProxy ()
 
new void SetFinalStop (double x, double y)
 
 
new void SetStart (double x, double y)
 
 
new void Dispose ()
 
- Public Member Functions inherited from QtGui.QGradient
override bool Equals (object o)
 
override int GetHashCode ()
 
 QGradient ()
 
 QGradient (QGradient copy)
 
new void SetColorAt (double pos, QColor color)
 
 
new void Dispose ()
 

Protected Member Functions

 QLinearGradient (System.Type dummy)
 
- Protected Member Functions inherited from QtGui.QGradient
 QGradient (System.Type dummy)
 

Properties

QPointF FinalStop [get, set]
 
 
QPointF Start [get, set]
 
 
- Properties inherited from QtGui.QGradient
QGradient.CoordinateMode coordinateMode [get, set]
 
 
QGradient.InterpolationMode interpolationMode [get, set]
 
QGradient.Spread spread [get, set]
 
 
QGradient.Type type [get]
 
 
virtual System.IntPtr SmokeObject [get, set]
 
static new QMetaObject StaticMetaObject [get]
 

Additional Inherited Members

- Public Types inherited from QtGui.QGradient
enum  CoordinateMode { LogicalMode = 0, ObjectBoundingMode = 2, StretchToDeviceMode = 1 }
  More...
 
enum  InterpolationMode { ColorInterpolation = 0, ComponentInterpolation = 1 }
 
enum  Spread { PadSpread = 0, ReflectSpread = 1, RepeatSpread = 2 }
  More...
 
enum  Type { ConicalGradient = 2, LinearGradient = 0, NoGradient = 3, RadialGradient = 1 }
  More...
 
- Static Public Member Functions inherited from QtGui.QGradient
static bool operator!= (QGradient one, QGradient other)
 
 
static bool operator== (QGradient one, QGradient gradient)
 
 
- Protected Attributes inherited from QtGui.QGradient
SmokeInvocation interceptor
 

Detailed Description

The QLinearGradient class is used in combination with QBrush to specify a linear gradient brush.

Linear gradients interpolate colors between start and end points. Outside these points the gradient is either padded, reflected or repeated depending on the currently set spread method:

PadSpread (default) ReflectSpread RepeatSpread

The colors in a gradient is defined using stop points of the QGradientStop type, i.e. a position and a color. Use the QGradient::setColorAt() or the QGradient::setStops() function to define the stop points. It is the gradient's complete set of stop points that describes how the gradient area should be filled. If no stop points have been specified, a gradient of black at 0 to white at 1 is used.

In addition to the functions inherited from QGradient, the QLinearGradient class provides the finalStop() function which returns the final stop point of the gradient, and the start() function returning the start point of the gradient.

See also QRadialGradient, QConicalGradient, and The Gradients Demo.

Constructor & Destructor Documentation

QtGui.QLinearGradient.QLinearGradient ( System.Type  dummy)
protected
QtGui.QLinearGradient.QLinearGradient ( )

Constructs a default linear gradient with interpolation area between (0, 0) and (1, 1).

See also QGradient::setColorAt(), setStart(), and setFinalStop().

QtGui.QLinearGradient.QLinearGradient ( QLinearGradient  copy)
QtGui.QLinearGradient.QLinearGradient ( QPointF  start,
QPointF  finalStop 
)

Constructs a linear gradient with interpolation area between the given start point and finalStop.

Note: The expected parameter values are in pixels.

See also QGradient::setColorAt() and QGradient::setStops().

QtGui.QLinearGradient.QLinearGradient ( double  xStart,
double  yStart,
double  xFinalStop,
double  yFinalStop 
)

Constructs a linear gradient with interpolation area between (x1, y1) and (x2, y2).

Note: The expected parameter values are in pixels.

See also QGradient::setColorAt() and QGradient::setStops().

Member Function Documentation

override void QtGui.QLinearGradient.CreateProxy ( )
virtual

Reimplemented from QtGui.QGradient.

new void QtGui.QLinearGradient.Dispose ( )
new void QtGui.QLinearGradient.SetFinalStop ( double  x,
double  y 
)

This is an overloaded function.

Sets the final stop point of this linear gradient in logical coordinates to x, y.

This function was introduced in Qt 4.2.

See also start().

new void QtGui.QLinearGradient.SetStart ( double  x,
double  y 
)

This is an overloaded function.

Sets the start point of this linear gradient in logical coordinates to x, y.

This function was introduced in Qt 4.2.

See also start().

Property Documentation

QPointF QtGui.QLinearGradient.FinalStop
getset

Returns the final stop point of this linear gradient in logical coordinates.

Sets the final stop point of this linear gradient in logical coordinates to stop.

This function was introduced in Qt 4.2.

QPointF QtGui.QLinearGradient.Start
getset

Returns the start point of this linear gradient in logical coordinates.

Sets the start point of this linear gradient in logical coordinates to start.

This function was introduced in Qt 4.2.