X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git;a=blobdiff_plain;f=dali-toolkit%2Finternal%2Fvisuals%2Fgradient%2Fgradient.h;h=d6dd7f4d9593a5a0e7572f8bbf71ac5f2a4446ff;hp=f08af994a21bd013404b842dfbe65258701c8032;hb=11ed6421771d05113ae1a6510167d8c2557ac20e;hpb=4ee66864e6f96d6de8c4f0b8beed439c0f3508d1 diff --git a/dali-toolkit/internal/visuals/gradient/gradient.h b/dali-toolkit/internal/visuals/gradient/gradient.h index f08af99..d6dd7f4 100644 --- a/dali-toolkit/internal/visuals/gradient/gradient.h +++ b/dali-toolkit/internal/visuals/gradient/gradient.h @@ -18,13 +18,16 @@ * */ -//EXTERNAL INCLUDES +// EXTERNAL INCLUDES #include #include #include #include #include +// INTERNAL INCLUDES +#include + namespace Dali { @@ -43,25 +46,6 @@ namespace Internal class Gradient : public RefObject { public: - /** - * Defines the coordinate system of the attributes - * (start and end position for linear gradient, circle center and radius for radial gradient) - */ - enum GradientUnits - { - USER_SPACE_ON_USE, - OBJECT_BOUNDING_BOX - }; - - /** - * Indicates what happens if the gradient starts or ends inside the bounds of the object being painted by the gradient. - */ - enum SpreadMethod - { - PAD, // use the terminal colors of the gradient to fill the remainder of the target region - REPEAT, // reflect the gradient pattern start-to-end, end-to-start, start-to-end, etc. continuously until the target rectangle is filled - REFLECT // repeat the gradient pattern start-to-end, start-to-end, start-to-end, etc. continuously until the target region is filled - }; /** * The stop node tells the gradient what color it should be at certain position. @@ -101,13 +85,13 @@ public: * Set the coordinate system used by the gradient attributes. * @param[in] gradientUnits The the attributes are defined using the current user coordinate system or the bounding box of the shape. */ - void SetGradientUnits( GradientUnits gradientUnits ); + void SetGradientUnits( Toolkit::GradientVisual::Units::Type gradientUnits ); /** * Get the coordinate system used by the gradient attributes. * @return USER_SPACE_ON_USE or OBJECT_BOUNDING_BOX */ - GradientUnits GetGradientUnits() const; + Toolkit::GradientVisual::Units::Type GetGradientUnits() const; /** * Indicates what happens if the gradient starts or ends inside the bounds of the target rectangle. @@ -115,13 +99,13 @@ public: * * @param[in] spread The method to fill the remainder of target region which is outside the gradient bounds */ - void SetSpreadMethod( SpreadMethod spread ); + void SetSpreadMethod( Toolkit::GradientVisual::SpreadMethod::Type spread ); /** * Get the filling method for the the remainder of target region which is outside the gradient boun. * @return PAD, REFLECT or REPEAT */ - SpreadMethod GetSpreadMethod() const; + Toolkit::GradientVisual::SpreadMethod::Type GetSpreadMethod() const; /** * Get the transformation matrix to align the vertices with the gradient line/circle @@ -164,10 +148,10 @@ protected: protected: - Vector mGradientStops; - Matrix3 mAlignmentTransform; - GradientUnits mGradientUnits; - SpreadMethod mSpreadMethod; + Vector mGradientStops; + Matrix3 mAlignmentTransform; + Toolkit::GradientVisual::Units::Type mGradientUnits; + Toolkit::GradientVisual::SpreadMethod::Type mSpreadMethod; };