X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=dali-toolkit%2Finternal%2Ftext%2Ftext-effects-style.h;h=240a76ebfe292fb788302d585df3bd498bc184a9;hb=0686e6d654472bffc56910890f39031ceac32d3b;hp=fb21fe9b95473380d67d135a71dcbb6b3f4697f5;hpb=754246a1c8812496ac70cdef21c122069ad21640;p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git diff --git a/dali-toolkit/internal/text/text-effects-style.h b/dali-toolkit/internal/text/text-effects-style.h old mode 100644 new mode 100755 index fb21fe9..240a76e --- a/dali-toolkit/internal/text/text-effects-style.h +++ b/dali-toolkit/internal/text/text-effects-style.h @@ -2,7 +2,7 @@ #define __DALI_TOOLKIT_INTERNAL_TEXT_EFFECTS_STYLE_H__ /* - * Copyright (c) 2016 Samsung Electronics Co., Ltd. + * Copyright (c) 2018 Samsung Electronics Co., Ltd. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -42,32 +42,63 @@ namespace EffectStyle /** * @brief Parses the shadow properties. * + * @param[in] shadowProperties The map with the shadow properties. * @param[out] colorDefined Whether the shadow's color is defined. * @param[out] color The shadow's color. * @param[out] offsetDefined Whether the shadow's offset is defined. * @param[out] offset The shadow's offset. */ -bool ParseProperties( const std::string& shadowProperties, - bool& colorDefined, - Vector4& color, - bool& offsetDefined, - Vector2& offset ); +bool ParseShadowProperties( const Property::Map& shadowProperties, + bool& colorDefined, + Vector4& color, + bool& offsetDefined, + Vector2& offset ); /** * @brief Parses the underline properties. * + * @param[in] underlineProperties The map with the underline properties. * @param[out] enabled Whether the underline is enabled. * @param[out] colorDefined Whether the underline's color is defined. * @param[out] color The underline's color. * @param[out] heightDefined Whether the underline's height is defined. * @param[out] height The underline's height. */ -bool ParseProperties( const std::string& underlineProperties, - bool& enabled, - bool& colorDefined, - Vector4& color, - bool& heightDefined, - float& height ); +bool ParseUnderlineProperties( const Property::Map& underlineProperties, + bool& enabled, + bool& colorDefined, + Vector4& color, + bool& heightDefined, + float& height ); + +/** + * @brief Parses the outline properties. + * + * @param[in] outlineProperties The map with the outline properties. + * @param[out] colorDefined Whether the outline's color is defined. + * @param[out] color The outline's color. + * @param[out] widthDefined Whether the outline's width is defined. + * @param[out] width The outline's width. + */ +bool ParseOutlineProperties( const Property::Map& outlineProperties, + bool& colorDefined, + Vector4& color, + bool& widthDefined, + unsigned int& width ); + + +/** + * @brief Parses the background properties. + * + * @param[in] backgroundProperties The map with the background properties. + * @param[out] enabled Whether the background is enabled. + * @param[out] colorDefined Whether the background color is defined. + * @param[out] color The background color. + */ +bool ParseBackgroundProperties( const Property::Map& backgroundProperties, + bool& enabled, + bool& colorDefined, + Vector4& color ); /** * @brief Sets the underline properties. @@ -149,6 +180,26 @@ bool SetOutlineProperties( ControllerPtr controller, const Property::Value& valu */ void GetOutlineProperties( ControllerPtr controller, Property::Value& value, EffectStyle::Type type ); +/** + * @brief Sets the background properties. + * + * @param[in] controller The text's controller. + * @param[in] value The values of the background's properties. + * @param[in] type Whether the property is for the default background or the input background. + * + * @return Whether the background properties have been updated. + */ +bool SetBackgroundProperties( ControllerPtr controller, const Property::Value& value, EffectStyle::Type type ); + +/** + * @brief Retrieves the background's properties. + * + * @param[in] controller The text's controller. + * @param[out] value The value of the underline's properties. + * @param[in] type Whether the property is for the default background or the input background. + */ +void GetBackgroundProperties( ControllerPtr controller, Property::Value& value, EffectStyle::Type type ); + } // namespace Text } // namespace Toolkit