X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=dali-toolkit%2Fdevel-api%2Flayouting%2Fflex-node.h;h=3542f7db8d9d557164cfe1955d2d88557f1b116b;hb=e4a3c7b18f3a6168ec3967d4881663f7ed54f8d5;hp=034e555b8238fb87303078479b4d30bb0442908c;hpb=94676883816fd9006acf918be6d8ff2141910f8d;p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git diff --git a/dali-toolkit/devel-api/layouting/flex-node.h b/dali-toolkit/devel-api/layouting/flex-node.h index 034e555..3542f7d 100644 --- a/dali-toolkit/devel-api/layouting/flex-node.h +++ b/dali-toolkit/devel-api/layouting/flex-node.h @@ -84,6 +84,14 @@ enum class Alignment STRETCH ///< Stretch to fit the container }; +/** + * @brief Enumeration for the position type of the flex item how it is positioned within its parent. + */ +enum class PositionType +{ + RELATIVE, ///< Flex items laid out relatively + ABSOLUTE ///< Flex items laid out absolutely +}; /** * Struct used for MeasureCallback @@ -130,10 +138,12 @@ public: /** * @brief Insert child into the FlexLayout at the given index. * @param[in] child Actor to insert. + * @param[in] margin of child Actor. * @param[in] measureFunction for the child. * @param[in] index to insert at. + * @return child node pointer */ - void AddChild( Actor child, MeasureCallback measureFunction, int index ); + Node* AddChild( Actor child, Extents margin, MeasureCallback measureFunction, int index ); /** * @brief Remove child from the FlexLayout at the given index. @@ -240,6 +250,78 @@ public: Alignment GetFlexItemsAlignment() const; /** + * @brief Set the alignment self of the layout items. + * @param[in] flexAlignmentSelf The alignment self of the items. + */ + void SetFlexAlignmentSelf( Alignment flexAlignmentSelf ); + + /** + * @brief Get the alignment self of the layout items. + * @return The flex items alignment self. + */ + Alignment GetFlexAlignmentSelf() const; + + /** + * @brief Set the position type of the layout items. + * @param[in] flexPositionType The position type of the items. + */ + void SetFlexPositionType( PositionType flexPositionType ); + + /** + * @brief Get the position type of the layout items. + * @return The flex position type. + */ + PositionType GetFlexPositionType() const; + + /** + * @brief Set the aspect ratio of the layout items. + * @param[in] flexAspectRatio The aspect ratio of the items. + */ + void SetFlexAspectRatio( float flexAspectRatio ); + + /** + * @brief Get the aspect ratio of the layout items. + * @return The flex aspect ratio. + */ + float GetFlexAspectRatio() const; + + /** + * @brief Set the basis of the layout items. + * @param[in] flexBasis The basis of the items. + */ + void SetFlexBasis( float flexBasis ); + + /** + * @brief Get the basis of the layout items. + * @return The flex basis. + */ + float GetFlexBasis() const; + + /** + * @brief Set the shrink of the layout items. + * @param[in] flexShrink The shrink of the items. + */ + void SetFlexShrink( float flexShrink ); + + /** + * @brief Get the shrink of the layout items. + * @return The flex shrink. + */ + float GetFlexShrink() const; + + /** + * @brief Set the grow of the layout items. + * @param[in] flexGrow The grow of the items. + */ + void SetFlexGrow( float flexGrow ); + + /** + * @brief Get the grow of the layout items. + * @return The flex grow. + */ + float GetFlexGrow() const; + + /** * @brief Set the margin. * @param[in] margin The margin value. */