2 // Open Service Platform
3 // Copyright (c) 2012-2013 Samsung Electronics Co., Ltd.
5 // Licensed under the Flora License, Version 1.0 (the License);
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
9 // http://floralicense.org/license/
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an AS IS BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
18 * @file FUiCtrl_LabelPresenter.h
19 * @brief This is the header file for the _LabelPresenter class.
21 * This header file contains the declarations of the %_LabelPresenter class.
23 #ifndef _FUI_CTRL_INTERNAL_LABEL_PRESENTER_H_
24 #define _FUI_CTRL_INTERNAL_LABEL_PRESENTER_H_
26 #include <FBaseObject.h>
27 #include <FGrp_TextTextObject.h>
28 #include <FUiCtrlLabel.h>
29 #include "FUi_Control.h"
31 namespace Tizen { namespace Ui { namespace Animations
34 }}} // Tizen::Ui::Animations
36 namespace Tizen { namespace Ui { namespace Controls
42 * @class _LabelPresenter
51 : public Tizen::Base::Object
54 _LabelPresenter(void);
55 virtual ~_LabelPresenter(void);
58 virtual result Construct(const _Label& label);
59 virtual result Install(void);
63 void OnFontChanged(Tizen::Graphics::Font* pFont);
64 void OnFontInfoRequested(unsigned long& style, int& size);
65 void SetFontInfo(unsigned long style, int size);
66 result SetTextConfig(int size, LabelTextStyle style);
67 LabelTextStyle GetTextStyle(void) const;
69 virtual bool OnTouchPressed(const _Control& source, const _TouchInfo& touchinfo);
70 virtual bool OnTouchReleased(const _Control& source, const _TouchInfo& touchinfo);
71 virtual bool OnTouchMoved(const _Control& source, const _TouchInfo& touchinfo);
72 virtual bool OnTouchCanceled(const _Control& source, const _TouchInfo& touchinfo);
73 virtual void OnTouchMoveHandled(const _Control& control);
75 Tizen::Graphics::_Text::TextObject* GetTextObject(void) const;
76 result InitTextObject(void);
79 result SetModel(const _LabelModel& labelModel);
82 _LabelPresenter(const _LabelPresenter& rhs);
83 _LabelPresenter& operator =(const _LabelPresenter& rhs);
85 void DrawBackground(void);
87 bool IsEnabledStateChanged(void);
91 _LabelModel* __pLabelModel;
93 bool __previousEnabledState;
95 Tizen::Graphics::Font* __pFont;
96 Tizen::Graphics::_Text::TextObject* __pTextObject;
98 Tizen::Ui::Animations::_VisualElement* __pBase;
99 LabelTextStyle __textStyle;
100 unsigned long __fontStyle;
102 }; // _LabelPresenter
104 }}} // Tizen::Ui::Controls
106 #endif // _FUI_CTRL_INTERNAL_LABEL_PRESENTER_H_