Merge "Unchecked GetCharacter func when index is over string length" into tizen_2.2
[platform/framework/native/uifw.git] / inc / FUiCtrlIconList.h
1 //
2 // Open Service Platform
3 // Copyright (c) 2012-2013 Samsung Electronics Co., Ltd.
4 //
5 // Licensed under the Apache License, Version 2.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
8 //
9 //     http://www.apache.org/licenses/LICENSE-2.0/
10 //
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.
16 //
17 /**
18  * @if OSPDEPREC
19  * @file        FUiCtrlIconList.h
20  * @brief       This is the header file for the %IconList class.
21  *
22  * This header file contains the declarations of the %IconList class and its helper classes.
23  * @endif
24  */
25
26 #ifndef _FUI_CTRL_ICON_LIST_H_
27 #define _FUI_CTRL_ICON_LIST_H_
28
29 #include <FBaseObject.h>
30 #include <FBaseTypes.h>
31 #include <FGrpRectangle.h>
32 #include <FUiContainer.h>
33 #include <FUiCtrlIconListTypes.h>
34 #include <FUiCtrlListTypes.h>
35 #include <FUiCtrlControlsTypes.h>
36 #include <FUiIItemEventListener.h>
37
38 // forward declarations
39 namespace Tizen { namespace Ui { namespace Controls
40 {
41
42 /**
43  * @if OSPDEPREC
44  * @class       IconList
45  * @brief  <i> [Deprecated] </i>  This class defines the common behavior of an %IconList control.
46  *
47  * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
48  * @since               2.0
49  *
50  * @remarks     %IconList can display a maximum of 64 items on the screen at once (for example, 8 x 8 grid).
51  * %IconList is not drawn properly when it is resized.
52  *
53  * The %IconList class can be used to display a list of bitmap images and icons. When
54  * a list item (or icon) is pressed by the user, an item event is generated and the
55  * item event listeners are called to notify the change in the
56  * item's state (ITEM_CHECKED, ITEM_UNCHECKED and ITEM_SELECTED).
57  *
58  * When %IconList's style is set as ICON_LIST_STYLE_RADIO, only one item
59  * can be "selected" at a time. Whereas, if ICON_LIST_STYLE_MARK is set as
60  * the %IconList's style, multiple items can be "checked" at the same time.
61  * However, no item can be selected or checked when %IconList's style is set as
62  * ICON_LIST_STYLE_NORMAL.
63  *
64  * When a list item is selected by the user, the "focused" bitmap image is displayed
65  * instead of item's "normal" bitmap image.
66  *
67  * Please note that any image resources (bitmaps) that are allocated by application
68  * must be freed after they are passed to Additem()/InsertItem()/SetItem() to
69  * minimize memory usage. @n
70  *
71  * Example:
72  *
73  * @image html ui_controls_iconlist.png
74  *
75  *@n
76  * This is a simple UI application which uses a icon list control.
77  *
78  *
79  * @code
80 //Sample code for IconListSample.h
81 #include <FUi.h>
82
83 class IconListSample
84         : public Tizen::Ui::Controls::Form
85         , public Tizen::Ui::IItemEventListener
86 {
87 public:
88         IconListSample(void)
89         : __pIconList(null){}
90
91         bool Initialize(void);
92         virtual result OnInitializing(void);
93
94         // IItemEventListener
95         virtual void OnItemStateChanged(const Tizen::Ui::Control &source, int index, int itemId, Tizen::Ui::ItemStatus status);
96
97 private:
98         static const int ID_LIST_FIRSTITEM = 101;
99         static const int ID_LIST_SECONDITEM = 102;
100
101         Tizen::Ui::Controls::IconList *__pIconList;
102 };
103  *      @endcode
104  *
105  *      @code
106 //Sample code for IconListSample.cpp
107 #include <FApp.h>
108 #include <FGraphics.h>
109
110 #include "IconListSample.h"
111
112 using namespace Tizen::App;
113 using namespace Tizen::Base;
114 using namespace Tizen::Ui;
115 using namespace Tizen::Ui::Controls;
116 using namespace Tizen::Graphics;
117
118 bool
119 IconListSample::Initialize(void)
120 {
121         Construct(FORM_STYLE_NORMAL);
122         return true;
123 }
124
125 result
126 IconListSample::OnInitializing(void)
127 {
128         result r = E_SUCCESS;
129
130         // Creates an instance of IconList
131         __pIconList = new IconList();
132         __pIconList->Construct(Rectangle(0, 100, GetClientAreaBounds().width, GetClientAreaBounds().height), ICON_LIST_STYLE_NORMAL, 96, 96);
133         __pIconList->AddItemEventListener(*this);
134
135         // Creates instances of String
136         String itemText1(L"Item1");
137         String itemText2(L"Item2");
138
139         // Gets instances of Bitmap
140         AppResource* pAppResource = Application::GetInstance()->GetAppResource();
141         Bitmap *pBitmapNormal1  = pAppResource->GetBitmapN(L"call.png");
142         Bitmap *pBitmapFocused1 = pAppResource->GetBitmapN(L"call_focused.png");
143         Bitmap *pBitmapNormal2  = pAppResource->GetBitmapN(L"home.png");
144         Bitmap *pBitmapFocused2 = pAppResource->GetBitmapN(L"home_focused.png");
145
146         // Adds the items to the icon list
147         __pIconList->AddItem(&itemText1, pBitmapNormal1, pBitmapFocused1, ID_LIST_FIRSTITEM);
148         __pIconList->AddItem(&itemText2, pBitmapNormal2, pBitmapFocused2, ID_LIST_SECONDITEM);
149
150         // Adds the icon list to the form
151         AddControl(__pIconList);
152
153         // Deallocates bitmaps
154         delete pBitmapNormal1;
155         delete pBitmapFocused1;
156         delete pBitmapNormal2;
157         delete pBitmapFocused2;
158
159         return r;
160 }
161
162 // IItemEventListener implementation
163 void
164 IconListSample::OnItemStateChanged (const Control &source, int index, int itemId, ItemStatus status)
165 {
166         switch (itemId)
167         {
168         case ID_LIST_FIRSTITEM:
169                 {
170                         // ....
171                 }
172                 break;
173         case ID_LIST_SECONDITEM:
174                 {
175                         // ....
176                 }
177                 break;
178         default:
179                 break;
180         }
181 }
182  * @endcode
183  * @endif
184  */
185 class _OSP_EXPORT_ IconList
186         : public Tizen::Ui::Control
187 {
188 public:
189         /**
190          * @if OSPDEPREC
191          * The object is not fully constructed after this constructor is called. @n
192         * For full construction, the IconList::Construct() method must be called right after calling this constructor.
193          *
194          * @brief       <i> [Deprecated] </i>
195          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
196          * @since       2.0
197          * @endif
198          */
199         IconList(void);
200
201         /**
202          * @if OSPDEPREC
203          * This polymorphic destructor should be overridden if required.@n
204          * This way, the destructors of the derived classes are called when the destructor of this interface is called.
205          *
206          * @brief       <i> [Deprecated] </i>
207          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
208          * @since       2.0
209          * @endif
210          */
211         virtual ~IconList(void);
212
213 public:
214         /**
215          * @if OSPDEPREC
216          * Initializes this instance of %IconList with the specified parameters.
217          *
218          * @brief       <i> [Deprecated] </i>
219          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
220          * @since                       2.0
221          *
222          * @return              An error code
223          * @param[in]   rect            An instance of the Graphics::Rectangle class @n
224          *                                                      This instance represents the X and Y coordinates of the top-left corner of the created %IconList along with
225          *                                                      the width and height. @n
226          * @param[in]   style                   The style set of %IconList
227          * @param[in]   itemWidth               The width of the items in the %IconList
228          * @param[in]   itemHeight              The height of the items in the %IconList
229          * @exception   E_SUCCESS               The method is successful.
230          * @exception   E_INVALID_ARG   A specified input parameter is invalid.
231          * @exception   E_SYSTEM                A system error has occurred.
232          * @remarks
233          *                              - A control is fully usable only after it has been added to a container, therefore some methods may fail if used earlier.
234          *                              - The %IconList cannot display more than 64 items on screen at once.
235          *                              - The size of the control must be within the range defined by the minimum and maximum size.
236          *                              - The minimum size of this control is 0 x 0.
237          * @endif
238          */
239         result Construct(const Tizen::Graphics::Rectangle& rect, IconListStyle style, int itemWidth, int itemHeight);
240
241
242 // Operation
243         /**
244          * @if OSPDEPREC
245          * Adds a listener instance. @n
246          * The added listener can listen to item events when they are fired. Only an item event with the ITEM_SELECTED state is fired.
247          *
248          * @brief       <i> [Deprecated] </i>
249          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
250          * @since               2.0
251          *
252          * @param[in]   listener    The listener to add
253          * @endif
254          */
255         void AddItemEventListener(Tizen::Ui::IItemEventListener& listener);
256
257         /**
258          * @if OSPDEPREC
259          * Removes a listener instance. @n
260          * The removed listener cannot listen to events when they are fired.
261          *
262          * @brief       <i> [Deprecated] </i>
263          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
264          * @since               2.0
265          *
266          * @param[in]   listener    The listener to remove
267          * @endif
268          */
269         void RemoveItemEventListener(Tizen::Ui::IItemEventListener& listener);
270
271         /**
272          * @if OSPDEPREC
273          * Sets the background bitmap of the %IconList control.
274          *
275          * @brief       <i> [Deprecated] </i>
276          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
277          * @since               2.0
278          *
279          * @param[in]   bitmap          The background bitmap
280          * @endif
281          */
282         void SetBackgroundBitmap(const Tizen::Graphics::Bitmap& bitmap);
283
284         /**
285          * @if OSPDEPREC
286          * Sets the top and left margins of the items for %IconList.
287          *
288          * @brief       <i> [Deprecated] </i>
289          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
290          * @since               2.0
291          *
292          * @return              An error code
293          * @param[in]   topMargin                       The top margin of the background bitmap
294          * @param[in]   leftMargin                      The left margin of the background bitmap
295          * @exception   E_SUCCESS                       The method is successful.
296          * @exception   E_SYSTEM                        A system error has occurred.
297          * @remarks             The %IconList cannot display more than 64 items on screen at once.
298          * @endif
299          */
300         result SetMargin(int topMargin, int leftMargin);
301
302
303         /**
304          * @if OSPDEPREC
305          * Gets the top margin of the items for the %IconList control.
306          *
307          * @brief       <i> [Deprecated] </i>
308          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
309          * @since               2.0
310          *
311          * @return              The top margin of the background bitmap
312          * @endif
313          */
314         int GetTopMargin(void) const;
315
316         /**
317          * @if OSPDEPREC
318          * Gets the left margin of the items for the %IconList control.
319          *
320          * @brief       <i> [Deprecated] </i>
321          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
322          * @since               2.0
323          *
324          * @return              The left margin of the background bitmap
325          * @endif
326          */
327         int GetLeftMargin(void) const;
328
329         /**
330          * @if OSPDEPREC
331          * Adds a list item with the specified text and bitmap images to the %IconList control.
332          *
333          * @brief       <i> [Deprecated] </i>
334          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
335          * @since               2.0
336          *
337          * @return              An error code
338          * @param[in]   pText                   The item text
339          * @param[in]   pNormalBitmap   The default bitmap image
340          * @param[in]   pFocusedBitmap  The displayed bitmap image when an item is selected
341          * @param[in]   itemId              The item ID
342          * @exception   E_SUCCESS               The method is successful.
343          * @exception   E_SYSTEM                A system error has occurred.
344          * @remarks
345          *                              - The contents of the specified texts and bitmaps are copied and kept by %List.
346          *                              - To display text in multi-lines or to denote the end of line, use '\\n'.
347          * @endif
348          */
349         result AddItem(const Tizen::Base::String* pText, const Tizen::Graphics::Bitmap* pNormalBitmap, const Tizen::Graphics::Bitmap* pFocusedBitmap, int itemId = LIST_ITEM_UNSPECIFIED_ID);
350
351
352         /**
353          * @if OSPDEPREC
354          * Inserts the specified text and bitmap item in the specified index of the specified %IconList.
355          *
356          * @brief       <i> [Deprecated] </i>
357          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
358          * @since               2.0
359          *
360          * @return              An error code
361          * @param[in]   index                   The item text
362          * @param[in]   pText                   The text item to add
363          * @param[in]   pNormalBitmap   The default bitmap image
364          * @param[in]   pFocusedBitmap  The displayed bitmap image when an item is selected
365          * @param[in]   itemId                  The item ID
366          * @exception   E_SUCCESS               The method is successful.
367          * @exception   E_SYSTEM                A system error has occurred.
368          * @remarks
369          *                              - The contents of the specified texts and bitmaps are copied and kept by %IconList.
370          *                              - To display text in multi-lines or to denote the end of line, use '\\n'.
371          * @endif
372          */
373         result InsertItemAt(int index, const Tizen::Base::String* pText, const Tizen::Graphics::Bitmap* pNormalBitmap, const Tizen::Graphics::Bitmap* pFocusedBitmap, int itemId = LIST_ITEM_UNSPECIFIED_ID);
374
375
376         /**
377          * @if OSPDEPREC
378          * Sets the specified text and bitmap item in the specified index of the specified %IconList.
379          *
380          * @brief       <i> [Deprecated] </i>
381          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
382          * @since               2.0
383          *
384          * @return              An error code
385          * @param[in]   index                   The index of the List item
386          * @param[in]   pText                   The item text
387          * @param[in]   pNormalBitmap   The default bitmap image
388          * @param[in]   pFocusedBitmap  The displayed bitmap image when an item is selected
389          * @param[in]   itemId              The item ID
390          * @exception   E_SUCCESS               The method is successful.
391          * @exception   E_SYSTEM                A system error has occurred.
392          * @remarks
393          *                              - The contents of the specified texts and bitmaps are copied and kept by %IconList.
394          *                              Call RefreshItem() to update item images.
395          *                              - To display text in multi-lines or to denote the end of line, use '\\n'.
396          * @endif
397          */
398         result SetItemAt(int index, const Tizen::Base::String* pText, const Tizen::Graphics::Bitmap* pNormalBitmap, const Tizen::Graphics::Bitmap* pFocusedBitmap, int itemId = LIST_ITEM_UNSPECIFIED_ID);
399
400
401         /**
402          * @if OSPDEPREC
403          * Removes the item at the specified index.
404          *
405          * @brief       <i> [Deprecated] </i>
406          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
407          * @since               2.0
408          *
409          * @return              An error code
410          * @param[in]   index                   The index of the %IconList item
411          * @exception   E_SUCCESS               The method is successful.
412          * @exception   E_SYSTEM                A system error has occurred.
413          * @endif
414          */
415         result RemoveItemAt(int index);
416
417         /**
418          * @if OSPDEPREC
419          * Removes all items of the %IconList control.
420          *
421          * @brief       <i> [Deprecated] </i>
422          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
423          * @since               2.0
424          *
425          * @return              An error code
426          * @exception   E_SUCCESS               The method is successful.
427          * @exception   E_SYSTEM                A system error has occurred.
428          * @endif
429          */
430         result RemoveAllItems(void);
431
432         /**
433          * @if OSPDEPREC
434          * Gets the column count of the %IconList control.
435          *
436          * @brief       <i> [Deprecated] </i>
437          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
438          * @since               2.0
439          *
440          * @return              The count of all the items of the %IconList control
441          * @endif
442          */
443         int GetColumnCount(void) const;
444
445         /**
446          * @if OSPDEPREC
447          * Gets the item count of the %IconList control.
448          *
449          * @brief       <i> [Deprecated] </i>
450          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
451          * @since               2.0
452          *
453          * @return              The count of all the items of the %IconList control
454          * @endif
455          */
456         int GetItemCount(void) const;
457
458         /**
459          * @if OSPDEPREC
460          * Sets the checked status of the specified item of the %IconList control.
461          *
462          * @brief       <i> [Deprecated] </i>
463          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
464          * @since               2.0
465          *
466          * @return              An error code
467          * @param[in]   index                   The index of the %IconList item
468          * @param[in]   check                   Set to @c true to check the specified item, @n
469          *                                                              else @c false
470          * @exception   E_SUCCESS               The method is successful.
471          * @exception   E_SYSTEM                A system error has occurred.
472          *
473          * @remarks     This method can only be used when the style of the list allows selection (ICON_LIST_STYLE_MARK).
474          * @remarks     The method only changes the state of the list item. %IconList needs to be redrawn to reflect the change on the screen.
475          * @endif
476          */
477         result SetItemChecked(int index, bool check);
478
479         /**
480          * @if OSPDEPREC
481          * Checks whether the specified item of the %IconList control is checked.
482          *
483          * @brief       <i> [Deprecated] </i>
484          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
485          * @since               2.0
486          *
487          * @return              @c true if the specified item is checked, @n
488          *                              else @c false
489          * @param[in]   index   The index of the list item
490          * @remarks             This method can only be used when the style of the list allows selection.
491          * @endif
492          */
493         bool IsItemChecked(int index) const;
494
495         /**
496          * @if OSPDEPREC
497          * Sets the checked status of all the items of the %IconList control.
498          *
499          * @brief       <i> [Deprecated] </i>
500          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
501          * @since               2.0
502          *
503          * @return              An error code
504          * @param[in]   check                   Set to @c true to check all the items, @n
505          *                                                              else @c false
506          * @exception   E_SUCCESS               The method is successful.
507          * @exception   E_SYSTEM                A system error has occurred.
508          * @remarks             This method can only be used when the style of the list allows multiple selections (ICON_LIST_STYLE_MARK).
509          * @remarks             The method only changes the states of the list items. %IconList needs to be redrawn to reflect the changes on the screen.
510          * @endif
511          */
512         result SetAllItemsChecked(bool check);
513
514         /**
515          * @if OSPDEPREC
516          * Removes all checked items of the %IconList control.
517          *
518          * @brief       <i> [Deprecated] </i>
519          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
520          * @since               2.0
521          *
522          * @return              An error code
523          * @exception   E_SUCCESS               The method is successful.
524          * @exception   E_SYSTEM                A system error has occurred.
525          * @remarks             This method can only be used when the style of the list allows multiple selections.
526          * @endif
527          */
528         result RemoveAllCheckedItems(void);
529
530         /**
531          * @if OSPDEPREC
532          * Gets the first checked items of the %IconList control.
533          *
534          * @brief       <i> [Deprecated] </i>
535          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
536          * @since               2.0
537          *
538          * @return              The index of the %IconList item
539          * @endif
540          */
541         int GetFirstCheckedItemIndex(void) const;
542
543         /**
544          * @if OSPDEPREC
545          * Gets the last checked items of the %IconList control.
546          *
547          * @brief       <i> [Deprecated] </i>
548          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
549          * @since               2.0
550          *
551          * @return              The index of the %IconList item
552          * @endif
553          */
554         int GetLastCheckedItemIndex(void) const;
555
556         /**
557          * @if OSPDEPREC
558          * Gets the next checked items at the specified index of the %IconList control.
559          *
560          * @brief       <i> [Deprecated] </i>
561          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
562          * @since               2.0
563          *
564          * @return              The index of the list item
565          * @param[in]   index   The index of the %IconList item
566          * @endif
567          */
568         int GetNextCheckedItemIndexAfter(int index) const;
569
570         /**
571          * @if OSPDEPREC
572          * Gets the index of the item at the specified item position.
573          *
574          * @brief       <i> [Deprecated] </i>
575          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
576          * @since               2.0
577          *
578          * @return              The index of the item, @n
579          *                              else @c -1 if there is no list item at the specified position
580          * @param[in]   x       The x position of the point
581          * @param[in]   y       The y position of the point
582          * @endif
583          */
584         int GetItemIndexFromPosition(int x, int y) const;
585
586         /**
587          * @if OSPDEPREC
588          * Gets the index of the item at the specified item position.
589          *
590          * @brief       <i> [Deprecated] </i>
591          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
592          * @since               2.0
593          *
594          * @return              The index of the item, @n
595          *                              else @c -1 if there is no list item at the specified position
596          * @param[in]   position        The position of the point
597          * @endif
598          */
599         int GetItemIndexFromPosition(const Tizen::Graphics::Point& position) const;
600
601         /**
602          * @if OSPDEPREC
603          * Sets a horizontal alignment of the text in the current %IconList control.
604          *
605          * @brief       <i> [Deprecated] </i>
606          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
607          * @since               2.0
608          *
609          * @param[in]   alignment       The horizontal alignment of the text
610          * @endif
611          */
612         void SetTextHorizontalAlignment(HorizontalAlignment alignment);
613
614         /**
615          * @if OSPDEPREC
616          * Sets a vertical alignment of the text of the current %IconList control.
617          *
618          * @brief       <i> [Deprecated] </i>
619          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
620          * @since               2.0
621          *
622          * @param[in]   alignment       The vertical alignment of the icon and text
623          * @endif
624          */
625         void SetTextVerticalAlignment(VerticalAlignment alignment);
626
627         /**
628          * @if OSPDEPREC
629          * Gets the horizontal alignment of the text of the current %IconList control.
630          *
631          * @brief       <i> [Deprecated] </i>
632          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
633          * @since               2.0
634          *
635          * @return              The horizontal alignment of the %IconList control
636          * @endif
637          */
638         HorizontalAlignment GetTextHorizontalAlignment(void) const;
639
640         /**
641          * @if OSPDEPREC
642          * Gets the vertical alignment of the text of the current %IconList control.
643          *
644          * @brief       <i> [Deprecated] </i>
645          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
646          * @since               2.0
647          *
648          * @return              The vertical alignment of the %IconList control
649          * @endif
650          */
651         VerticalAlignment GetTextVerticalAlignment(void) const;
652
653         /**
654          * @if OSPDEPREC
655          * Sets the background color of the %IconList control.
656          *
657          * @brief       <i> [Deprecated] </i>
658          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
659          * @since        2.0
660          *
661          * @param[in]   color   The background color
662          * @endif
663          */
664         void SetBackgroundColor(const Tizen::Graphics::Color& color);
665
666         /**
667          * @if OSPDEPREC
668          * Sets the text to display when the %IconList control contains no item.
669          *
670          * @brief       <i> [Deprecated] </i>
671          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
672          * @since               2.0
673          *
674          * @param[in]   text    The text
675          * @endif
676          */
677         void SetTextOfEmptyList(const Tizen::Base::String& text);
678
679         /**
680          * @if OSPDEPREC
681          * Sets the color of the text that is displayed when the %IconList control contains no item.
682          *
683          * @brief       <i> [Deprecated] </i>
684          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
685          * @since               2.0
686          *
687          * @param[in]   color   The color of the text
688          * @endif
689          */
690         void SetTextColorOfEmptyList(const Tizen::Graphics::Color& color);
691
692
693         /**
694          * @if OSPDEPREC
695          * Gets the color of the text that is displayed when the %IconList control contains no item.
696          *
697          * @brief       <i> [Deprecated] </i>
698          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
699          * @since               2.0
700          *
701          * @return              The color of the text, @n
702          *                              else RGBA(0, 0, 0, 0) if an error occurs
703          * @endif
704          */
705         Tizen::Graphics::Color GetTextColorOfEmptyList(void) const;
706
707
708         /**
709          * @if OSPDEPREC
710          * Sets the text color of the item.
711          *
712          * @brief       <i> [Deprecated] </i>
713          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
714          * @since               2.0
715          *
716          * @param[in]   textColor       The color of the text
717          * @endif
718          */
719         void SetItemTextColor(const Tizen::Graphics::Color& textColor);
720
721         /**
722          * @if OSPDEPREC
723          * Gets the text color of the item.
724          *
725          * @brief       <i> [Deprecated] </i>
726          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
727          * @since               2.0
728          *
729          * @return              The color of the text, @n
730          *                              else RGBA(0, 0, 0, 0) if an error occurs
731          * @endif
732          */
733         Tizen::Graphics::Color GetItemTextColor(void) const;
734
735
736         /**
737          * @if OSPDEPREC
738          * Sets the size of the text of the current %IconList control.
739          *
740          * @brief       <i> [Deprecated] </i>
741          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
742          * @since               2.0
743          *
744          * @param[in]   size                    The size of the text
745          * @exception   E_SUCCESS               The method is successful.
746          * @exception   E_INVALID_ARG   The specified input parameter is invalid.
747          * @exception   E_SYSTEM                A system error has occurred.
748          * @remarks             The specific error code can be accessed using the GetLastResult() method.
749          * @remarks             If @c size is less than the minimum size, this method fails. The minimum font size is 6 on devices of high screen density.
750          * @endif
751          */
752         void SetTextSize(int size);
753
754
755         /**
756          * @if OSPDEPREC
757          * Gets the size of the text of the current %IconList control.
758          *
759          * @brief       <i> [Deprecated] </i>
760          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
761          * @since       2.0
762          *
763          * @return  The size of the text of the current %IconList control
764          * @endif
765          */
766         int GetTextSize(void) const;
767
768         /**
769          * @if OSPDEPREC
770          * Gets the index of the item with the specified item ID.
771          *
772          * @brief       <i> [Deprecated] </i>
773          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
774          * @since               2.0
775          *
776          * @return              The index of the item, @n
777          *                              else @c -1 if there is no list item with the specified item ID
778          * @param[in]   itemId          The item ID of the list item
779          * @endif
780          */
781         int GetItemIndexFromItemId(int itemId) const;
782
783         /**
784          * @if OSPDEPREC
785          * Gets the item ID of the item at the specified index.
786          *
787          * @brief       <i> [Deprecated] </i>
788          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
789          * @since               2.0
790          *
791          * @return              The item ID of the item, @n
792          *                              else @c -1 if there is no list item at the specified index
793          * @param[in]   index           The index of the list item
794          * @endif
795          */
796         int GetItemIdAt(int index) const;
797
798         /**
799          * @if OSPDEPREC
800          * Sets the position of the checkbox of the current %IconList control.
801          *
802          * @brief       <i> [Deprecated] </i>
803          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
804          * @since               2.0
805          *
806          * @param[in]   position        The position of the checkbox of the current %IconList control
807          * @remarks             This method changes the position of the checkbox image displayed for the "selected" item(s), when the style of %IconList is either
808          *                              ICON_LIST_STYLE_RADIO or ICON_LIST_STYLE_MARK.
809          * @endif
810          */
811         void SetCheckBoxPosition(IconListCheckBoxPosition position);
812
813         /**
814          * @if OSPDEPREC
815          * Gets the position of the checkbox of the current %IconList control.
816          *
817          * @brief       <i> [Deprecated] </i>
818          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
819          * @since               2.0
820          *
821          * @return              The position of the checkbox of the current %IconList control
822          * @endif
823          */
824         IconListCheckBoxPosition GetCheckBoxPosition(void) const;
825
826         /**
827          * @if OSPDEPREC
828          * Enables or disables focus animation.
829          *
830          * @brief       <i> [Deprecated] </i>
831          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
832          * @since               2.0
833          *
834          * @param[in]   enable  Set to @c true to enable focus animation, @n
835          *                      else @c false
836          * @remarks             If a separate Focused Bitmap is to be used, the animation effect must be disabled.
837          * @endif
838          */
839         void SetFocusAnimationEnabled(bool enable);
840
841         /**
842          * @if OSPDEPREC
843          * Scrolls to the bottom of the %IconList control.
844          *
845          * @brief       <i> [Deprecated] </i>
846          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
847          * @since       2.0
848          * @endif
849          */
850         void ScrollToBottom(void);
851
852         /**
853          * @if OSPDEPREC
854          * Scrolls to the top of the %IconList control.
855          *
856          * @brief       <i> [Deprecated] </i>
857          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
858          * @since       2.0
859          * @endif
860          */
861         void ScrollToTop(void);
862
863         /**
864          * @if OSPDEPREC
865          * Scrolls the specified item to the top of %IconList control.
866          *
867          * @brief       <i> [Deprecated] </i>
868          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
869          * @since               2.0
870          *
871          * @return              An error code
872          * @param[in]   itemIndex               The index of the item
873          * @exception   E_SUCCESS               The method is successful.
874          * @exception   E_SYSTEM                A system error has occurred.
875          * @exception   E_INVALID_ARG   The specified input parameter is invalid.
876          * @endif
877          */
878         result ScrollToTop(int itemIndex);
879
880         /**
881          * @if OSPDEPREC
882          * Draws and shows the item of %IconList control.
883          *
884          * @brief       <i> [Deprecated] </i>
885          * @deprecated  This class is deprecated. Instead of using this class, use the IconListView class.
886          * @since               2.0
887          *
888          * @return              An error code
889          * @param[in]   index                   The index of the %IconList item
890          * @exception   E_SUCCESS               The method is successful.
891          * @exception   E_SYSTEM                A system error has occurred.
892          * @exception   E_INVALID_ARG   A specified input parameter is invalid.
893          * @endif
894          */
895         result RefreshItem(int index);
896
897 public:
898         friend class _IconListImpl;
899
900 private:
901         //
902         // The implementation of this copy constructor is intentionally blank and declared as private to prohibit copying of objects.
903         //
904         IconList(const IconList& rhs);
905
906         //
907         // The implementation of this copy assignment operator is intentionally blank and declared as private to prohibit copying of objects.
908         //
909         IconList& operator =(const IconList& rhs);
910 }; //IconList
911
912 }}} // Tizen::Ui::Controls
913
914 #endif // _FUI_CTRL_ICON_LIST_H_