1 #ifndef __DALI_TOOLKIT_INTERNAL_TEXT_INPUT_TEXT_STYLE_H__
2 #define __DALI_TOOLKIT_INTERNAL_TEXT_INPUT_TEXT_STYLE_H__
5 // Copyright (c) 2014 Samsung Electronics Co., Ltd.
7 // Licensed under the Flora License, Version 1.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
11 // http://floralicense.org/license/
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.
20 #include <dali/dali.h>
24 #include <dali-toolkit/internal/controls/text-input/textview-character-positions-impl.h>
35 class TextInputTextStyle;
37 typedef IntrusivePtr<TextInputTextStyle> TextInputTextStylePtr;
40 * Stores the Input Text Style and provides functions to retrieve and manipulate it.
43 class TextInputTextStyle : ConnectionTracker
51 TextInputTextStyle(){};
56 ~TextInputTextStyle(){};
59 * @brief Returns the current Input Style, this is the style that newly inputed text will inherit.
60 * @return TextStyle object representing new style.
62 TextStyle GetInputStyle() const{return mInputStyle;};
65 * @brief Sets the Input style so newly inputed text will inherit this.
66 * @param[in] newStyle the style to now use for Input
67 * @return returns true if style changed. False if new style is the same as current setting.
69 bool SetInputStyle( const TextStyle newStyle, const TextStyle::Mask mask = TextStyle::ALL ){return false;};
72 * @brief Gets the Current Font used for newly inputed text
73 * @return the Font currently set for new text
75 Dali::Font GetInputFont() const{return Dali::Font();};
81 /* Input style changed signal.*/
82 typedef SignalV2< void( const TextStyle& style ) > StyleChangedSignalType;
85 * @brief Signal emitted when style changes.
86 * @return The signal to connect to
88 StyleChangedSignalType& StyleChangedSignal();
93 * @brief Copy Constructor
94 * @param[in] textStyle
97 TextInputTextStyle(const TextInputTextStyle& textStyle );
100 * @Assignment Constructor
104 TextInputTextStyle& operator=(const TextInputTextStyle& rhs);
108 TextStyle mInputStyle; // Stores the current input style.
109 StyleChangedSignalType mStyleChangedSignal; // Signal emitted when style changes.
112 } // namespace Internal
114 } // namespace Toolkit
118 #endif // __DALI_TOOLKIT_INTERNAL_TEXT_INPUT_TEXT_STYLE_H__