Merge remote-tracking branch 'origin/tizen' into new_text
[platform/core/uifw/dali-core.git] / dali / public-api / actors / actor-enumerations.h
1 #ifndef __DALI_ACTOR_ENUMERATIONS_H__
2 #define __DALI_ACTOR_ENUMERATIONS_H__
3
4 /*
5  * Copyright (c) 2014 Samsung Electronics Co., Ltd.
6  *
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18  *
19  */
20
21 #include <dali/public-api/common/dali-common.h>
22
23 namespace Dali
24 {
25
26 /**
27  * @brief Actor color mode.
28  *
29  */
30 enum ColorMode
31 {
32   USE_OWN_COLOR,                 ///< Actor will use its own color
33   USE_PARENT_COLOR,              ///< Actor will use its parent color
34   USE_OWN_MULTIPLY_PARENT_COLOR, ///< Actor will blend its color with its parents color.
35   USE_OWN_MULTIPLY_PARENT_ALPHA  ///< Actor will blend its alpha with its parents alpha. This means when parent fades in or out child does as well. This is the default.
36 };
37
38 /**
39  * @brief Actor position inheritance mode.
40  */
41 enum PositionInheritanceMode
42 {
43   INHERIT_PARENT_POSITION,                 ///< Actor will inherit its parent position. This is the default
44   USE_PARENT_POSITION,                     ///< Actor will copy its parent position. This is useful if many actors are stacked together in the same place. This option ignores parent origin and anchor point.
45   USE_PARENT_POSITION_PLUS_LOCAL_POSITION, ///< Actor will copy its parent position and add local position. This is useful if many actors are stacked together in the same place with an offset.  This option ignores parent origin and anchor point.
46   DONT_INHERIT_POSITION                    ///< Actor will not inherit position. Local position is treated as world position. This is useful if a constraint is used to override local position or if an actor is positioned globally. This option ignores parent origin, anchor point and local position.
47 };
48
49 /**
50  * @brief Actor size relative to parent mode.
51  */
52 enum SizeMode
53 {
54   USE_OWN_SIZE,                            ///< The mode is bypassed. The size Vector3 will be used as normal.
55   SIZE_EQUAL_TO_PARENT,                    ///< The actor will have the exact same size as the parent.
56   SIZE_RELATIVE_TO_PARENT,                 ///< The actors size will be ( ParentSize * SizeRelativeToParentFactor ).
57   SIZE_FIXED_OFFSET_FROM_PARENT            ///< The actors size will be ( ParentSize + SizeRelativeToParentFactor ).
58 };
59
60 } // namespace Dali
61
62 #endif // __DALI_ACTOR_ENUMERATIONS_H__