merging dali-sharp class scope with nui
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / public / TableView.cs
1 /** Copyright (c) 2017 Samsung Electronics Co., Ltd.
2 *
3 * Licensed under the Apache License, Version 2.0 (the "License");
4 * you may not use this file except in compliance with the License.
5 * You may obtain a copy of the License at
6 *
7 * http://www.apache.org/licenses/LICENSE-2.0
8 *
9 * Unless required by applicable law or agreed to in writing, software
10 * distributed under the License is distributed on an "AS IS" BASIS,
11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 * See the License for the specific language governing permissions and
13 * limitations under the License.
14 *
15 */
16 // This File has been auto-generated by SWIG and then modified using DALi Ruby Scripts
17 //------------------------------------------------------------------------------
18 // <auto-generated />
19 //
20 // This file was automatically generated by SWIG (http://www.swig.org).
21 // Version 3.0.9
22 //
23 // Do not make changes to this file unless you know what you are doing--modify
24 // the SWIG interface file instead.
25 //------------------------------------------------------------------------------
26
27 using Tizen.NUI.BaseComponents;
28
29 namespace Tizen.NUI
30 {
31     using Tizen.NUI.BaseComponents;
32     /// <summary>
33     /// TableView is a layout container for aligning child actors in a grid like layout.<br>
34     /// TableView constrains the x and y position and width and height of the child actors.<br>
35     /// z position and depth are left intact so that 3D model actors can also be laid out
36     /// in a grid without loosing their depth scaling.<br>
37     /// </summary>
38     public class TableView : View
39     {
40         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
41
42         internal TableView(global::System.IntPtr cPtr, bool cMemoryOwn) : base(NDalicPINVOKE.TableView_SWIGUpcast(cPtr), cMemoryOwn)
43         {
44             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
45             // By default, we do not want the position to use the anchor point
46             PositionUsesAnchorPoint = false;
47         }
48
49         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(TableView obj)
50         {
51             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
52         }
53
54         protected override void Dispose(DisposeTypes type)
55         {
56             if(disposed)
57             {
58                 return;
59             }
60
61             if(type == DisposeTypes.Explicit)
62             {
63                 //Called by User
64                 //Release your own managed resources here.
65                 //You should release all of your own disposable objects here.
66             }
67
68             //Release your own unmanaged resources here.
69             //You should not access any managed member here except static instance.
70             //because the execution order of Finalizes is non-deterministic.
71
72             if (swigCPtr.Handle != global::System.IntPtr.Zero)
73             {
74                 if (swigCMemOwn)
75                 {
76                     swigCMemOwn = false;
77                     NDalicPINVOKE.delete_TableView(swigCPtr);
78                 }
79                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
80             }
81
82             base.Dispose(type);
83         }
84
85
86         internal class Property : global::System.IDisposable
87         {
88             private global::System.Runtime.InteropServices.HandleRef swigCPtr;
89             protected bool swigCMemOwn;
90
91             internal Property(global::System.IntPtr cPtr, bool cMemoryOwn)
92             {
93                 swigCMemOwn = cMemoryOwn;
94                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
95             }
96
97             internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Property obj)
98             {
99                 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
100             }
101
102             //NUI Dispose Pattern written by Jinwoo Nam(jjw.nam) 
103
104             //A Flag to check who called Dispose(). (By User or DisposeQueue)
105             private bool isDisposeQueued = false;
106             //A Flat to check if it is already disposed.
107             protected bool disposed = false;
108
109             ~Property()
110             {
111                 if(!isDisposeQueued)
112                 {
113                     isDisposeQueued = true;
114                     DisposeQueue.Instance.Add(this);
115                 }
116             }
117
118             public void Dispose()
119             {
120                 //Throw excpetion if Dispose() is called in separate thread.
121                 if (!Window.IsInstalled())
122                 {
123                     throw new System.InvalidOperationException("This API called from separate thread. This API must be called from MainThread.");
124                 }
125
126                 if (isDisposeQueued)
127                 {
128                     Dispose(DisposeTypes.Implicit);
129                 }
130                 else
131                 {
132                     Dispose(DisposeTypes.Explicit);
133                     System.GC.SuppressFinalize(this);
134                 }
135             }
136
137             protected virtual void Dispose(DisposeTypes type)
138             {
139                 if (disposed)
140                 {
141                     return;
142                 }
143
144                 if(type == DisposeTypes.Explicit)
145                 {
146                     //Called by User
147                     //Release your own managed resources here.
148                     //You should release all of your own disposable objects here.
149                 }
150
151                 //Release your own unmanaged resources here.
152                 //You should not access any managed member here except static instance.
153                 //because the execution order of Finalizes is non-deterministic.
154
155                 if (swigCPtr.Handle != global::System.IntPtr.Zero)
156                 {
157                     if (swigCMemOwn)
158                     {
159                         swigCMemOwn = false;
160                         NDalicPINVOKE.delete_TableView_Property(swigCPtr);
161                     }
162                     swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
163                 }
164                 disposed = true;
165             }
166
167             public Property() : this(NDalicPINVOKE.new_TableView_Property(), true)
168             {
169                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
170             }
171
172             internal static readonly int ROWS = NDalicPINVOKE.TableView_Property_ROWS_get();
173             internal static readonly int COLUMNS = NDalicPINVOKE.TableView_Property_COLUMNS_get();
174             internal static readonly int CELL_PADDING = NDalicPINVOKE.TableView_Property_CELL_PADDING_get();
175             internal static readonly int LAYOUT_ROWS = NDalicPINVOKE.TableView_Property_LAYOUT_ROWS_get();
176             internal static readonly int LAYOUT_COLUMNS = NDalicPINVOKE.TableView_Property_LAYOUT_COLUMNS_get();
177
178         }
179
180         internal class ChildProperty : global::System.IDisposable
181         {
182             private global::System.Runtime.InteropServices.HandleRef swigCPtr;
183             protected bool swigCMemOwn;
184
185             internal ChildProperty(global::System.IntPtr cPtr, bool cMemoryOwn)
186             {
187                 swigCMemOwn = cMemoryOwn;
188                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
189             }
190
191             internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ChildProperty obj)
192             {
193                 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
194             }
195
196             //NUI Dispose Pattern written by Jinwoo Nam(jjw.nam) 
197
198             //A Flag to check who called Dispose(). (By User or DisposeQueue)
199             private bool isDisposeQueued = false;
200             //A Flat to check if it is already disposed.
201             protected bool disposed = false;
202
203             ~ChildProperty()
204             {
205                 if(!isDisposeQueued)
206                 {
207                     isDisposeQueued = true;
208                     DisposeQueue.Instance.Add(this);
209                 }
210             }
211
212             public void Dispose()
213             {
214                 //Throw excpetion if Dispose() is called in separate thread.
215                 if (!Window.IsInstalled())
216                 {
217                     throw new System.InvalidOperationException("This API called from separate thread. This API must be called from MainThread.");
218                 }
219
220                 if (isDisposeQueued)
221                 {
222                     Dispose(DisposeTypes.Implicit);
223                 }
224                 else
225                 {
226                     Dispose(DisposeTypes.Explicit);
227                     System.GC.SuppressFinalize(this);
228                 }
229             }
230
231             protected virtual void Dispose(DisposeTypes type)
232             {
233                 if (disposed)
234                 {
235                     return;
236                 }
237
238                 if(type == DisposeTypes.Explicit)
239                 {
240                     //Called by User
241                     //Release your own managed resources here.
242                     //You should release all of your own disposable objects here.
243                 }
244
245                 //Release your own unmanaged resources here.
246                 //You should not access any managed member here except static instance.
247                 //because the execution order of Finalizes is non-deterministic.
248
249                 if (swigCPtr.Handle != global::System.IntPtr.Zero)
250                 {
251                     if (swigCMemOwn)
252                     {
253                         swigCMemOwn = false;
254                         NDalicPINVOKE.delete_TableView_ChildProperty(swigCPtr);
255                     }
256                     swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
257                 }
258                 disposed = true;
259             }
260
261             public ChildProperty() : this(NDalicPINVOKE.new_TableView_ChildProperty(), true)
262             {
263                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
264             }
265
266             internal static readonly int CELL_INDEX = NDalicPINVOKE.TableView_ChildProperty_CELL_INDEX_get();
267             internal static readonly int ROW_SPAN = NDalicPINVOKE.TableView_ChildProperty_ROW_SPAN_get();
268             internal static readonly int COLUMN_SPAN = NDalicPINVOKE.TableView_ChildProperty_COLUMN_SPAN_get();
269             internal static readonly int CELL_HORIZONTAL_ALIGNMENT = NDalicPINVOKE.TableView_ChildProperty_CELL_HORIZONTAL_ALIGNMENT_get();
270             internal static readonly int CELL_VERTICAL_ALIGNMENT = NDalicPINVOKE.TableView_ChildProperty_CELL_VERTICAL_ALIGNMENT_get();
271
272         }
273
274         /// <summary>
275         /// Class to specify layout position for child view.
276         /// </summary>
277         public class CellPosition : global::System.IDisposable
278         {
279             private global::System.Runtime.InteropServices.HandleRef swigCPtr;
280             protected bool swigCMemOwn;
281
282             internal CellPosition(global::System.IntPtr cPtr, bool cMemoryOwn)
283             {
284                 swigCMemOwn = cMemoryOwn;
285                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
286             }
287
288             internal static global::System.Runtime.InteropServices.HandleRef getCPtr(CellPosition obj)
289             {
290                 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
291             }
292
293             //NUI Dispose Pattern written by Jinwoo Nam(jjw.nam) 
294
295             //A Flag to check who called Dispose(). (By User or DisposeQueue)
296             private bool isDisposeQueued = false;
297             //A Flat to check if it is already disposed.
298             protected bool disposed = false;
299
300             ~CellPosition()
301             {
302                 if(!isDisposeQueued)
303                 {
304                     isDisposeQueued = true;
305                     DisposeQueue.Instance.Add(this);
306                 }
307             }
308
309             public void Dispose()
310             {
311                 //Throw excpetion if Dispose() is called in separate thread.
312                 if (!Window.IsInstalled())
313                 {
314                     throw new System.InvalidOperationException("This API called from separate thread. This API must be called from MainThread.");
315                 }
316
317                 if (isDisposeQueued)
318                 {
319                     Dispose(DisposeTypes.Implicit);
320                 }
321                 else
322                 {
323                     Dispose(DisposeTypes.Explicit);
324                     System.GC.SuppressFinalize(this);
325                 }
326             }
327
328             protected virtual void Dispose(DisposeTypes type)
329             {
330                 if (disposed)
331                 {
332                     return;
333                 }
334
335                 if(type == DisposeTypes.Explicit)
336                 {
337                     //Called by User
338                     //Release your own managed resources here.
339                     //You should release all of your own disposable objects here.
340                 }
341
342                 //Release your own unmanaged resources here.
343                 //You should not access any managed member here except static instance.
344                 //because the execution order of Finalizes is non-deterministic.
345
346                 if (swigCPtr.Handle != global::System.IntPtr.Zero)
347                 {
348                     if (swigCMemOwn)
349                     {
350                         swigCMemOwn = false;
351                         NDalicPINVOKE.delete_TableView_CellPosition(swigCPtr);
352                     }
353                     swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
354                 }
355                 disposed = true;
356             }
357
358             /// <summary>
359             /// Constructor.
360             /// </summary>
361             /// <param name="rowIndex">The row index initialized</param>
362             /// <param name="columnIndex">The column index initialized</param>
363             /// <param name="rowSpan">The row span initialized</param>
364             /// <param name="columnSpan">The column span initialized</param>
365             public CellPosition(uint rowIndex, uint columnIndex, uint rowSpan, uint columnSpan) : this(NDalicPINVOKE.new_TableView_CellPosition__SWIG_0(rowIndex, columnIndex, rowSpan, columnSpan), true)
366             {
367                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
368             }
369
370             /// <summary>
371             /// Constructor to initialise values to defaults for convenience.
372             /// </summary>
373             /// <param name="rowIndex">The row index initialized</param>
374             /// <param name="columnIndex">The column index initialized</param>
375             /// <param name="rowSpan">The row span initialized</param>
376             public CellPosition(uint rowIndex, uint columnIndex, uint rowSpan) : this(NDalicPINVOKE.new_TableView_CellPosition__SWIG_1(rowIndex, columnIndex, rowSpan), true)
377             {
378                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
379             }
380
381             /// <summary>
382             /// Constructor to initialise values to defaults for convenience.
383             /// </summary>
384             /// <param name="rowIndex">The row index initialized</param>
385             /// <param name="columnIndex">The column index initialized</param>
386             public CellPosition(uint rowIndex, uint columnIndex) : this(NDalicPINVOKE.new_TableView_CellPosition__SWIG_2(rowIndex, columnIndex), true)
387             {
388                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
389             }
390
391             /// <summary>
392             /// Constructor to initialise values to defaults for convenience.
393             /// </summary>
394             /// <param name="rowIndex">The row index initialized</param>
395             public CellPosition(uint rowIndex) : this(NDalicPINVOKE.new_TableView_CellPosition__SWIG_3(rowIndex), true)
396             {
397                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
398             }
399
400             /// <summary>
401             /// Default constructor
402             /// </summary>
403             public CellPosition() : this(NDalicPINVOKE.new_TableView_CellPosition__SWIG_4(), true)
404             {
405                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
406             }
407
408             /// <summary>
409             /// Index of row
410             /// </summary>
411             public uint rowIndex
412             {
413                 set
414                 {
415                     NDalicPINVOKE.TableView_CellPosition_rowIndex_set(swigCPtr, value);
416                     if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
417                 }
418                 get
419                 {
420                     uint ret = NDalicPINVOKE.TableView_CellPosition_rowIndex_get(swigCPtr);
421                     if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
422                     return ret;
423                 }
424             }
425
426             /// <summary>
427             /// Index of column
428             /// </summary>
429             public uint columnIndex
430             {
431                 set
432                 {
433                     NDalicPINVOKE.TableView_CellPosition_columnIndex_set(swigCPtr, value);
434                     if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
435                 }
436                 get
437                 {
438                     uint ret = NDalicPINVOKE.TableView_CellPosition_columnIndex_get(swigCPtr);
439                     if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
440                     return ret;
441                 }
442             }
443
444             /// <summary>
445             /// Span of row
446             /// </summary>
447             public uint rowSpan
448             {
449                 set
450                 {
451                     NDalicPINVOKE.TableView_CellPosition_rowSpan_set(swigCPtr, value);
452                     if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
453                 }
454                 get
455                 {
456                     uint ret = NDalicPINVOKE.TableView_CellPosition_rowSpan_get(swigCPtr);
457                     if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
458                     return ret;
459                 }
460             }
461
462             /// <summary>
463             /// Span of column
464             /// </summary>
465             public uint columnSpan
466             {
467                 set
468                 {
469                     NDalicPINVOKE.TableView_CellPosition_columnSpan_set(swigCPtr, value);
470                     if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
471                 }
472                 get
473                 {
474                     uint ret = NDalicPINVOKE.TableView_CellPosition_columnSpan_get(swigCPtr);
475                     if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
476                     return ret;
477                 }
478             }
479
480         }
481
482         /// <summary>
483         /// Creates the TableView view.
484         /// </summary>
485         /// <param name="initialRows">initialRows for the table</param>
486         /// <param name="initialColumns">initialColumns for the table</param>
487         public TableView(uint initialRows, uint initialColumns) : this(NDalicPINVOKE.TableView_New(initialRows, initialColumns), true)
488         {
489             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
490
491         }
492
493         /// <summary>
494         /// Copy constructor. Creates another handle that points to the same real object.
495         /// </summary>
496         /// <param name="handle">Handle to copy from</param>
497         public TableView(TableView handle) : this(NDalicPINVOKE.new_TableView__SWIG_1(TableView.getCPtr(handle)), true)
498         {
499             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
500         }
501
502         /// <summary>
503         /// Changes this handle to point to another real object.
504         /// </summary>
505         /// <param name="handle">Handle to an object</param>
506         /// <returns>A reference to this</returns>
507         public TableView Assign(TableView handle)
508         {
509             TableView ret = new TableView(NDalicPINVOKE.TableView_Assign(swigCPtr, TableView.getCPtr(handle)), false);
510             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
511             return ret;
512         }
513
514         /// <summary>
515         /// Downcasts a handle to TableView handle.<br>
516         /// If handle points to a TableView, the downcast produces valid handle.<br>
517         /// If not, the returned handle is left uninitialized.<br>
518         /// </summary>
519         /// <param name="handle">Handle to an object</param>
520         /// <returns>Handle to a TableView or an uninitialized handle</returns>
521         public new static TableView DownCast(BaseHandle handle)
522         {
523             TableView ret = new TableView(NDalicPINVOKE.TableView_DownCast(BaseHandle.getCPtr(handle)), true);
524             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
525             return ret;
526         }
527
528         /// <summary>
529         /// Adds a child to the table.<br>
530         /// If the row or column index is outside the table, the table gets resized bigger.<br>
531         /// </summary>
532         /// <param name="child">The child to add</param>
533         /// <param name="position">The position for the child</param>
534         /// <returns>Tue if the addition succeeded and false if the cell is already occupied</returns>
535         public bool AddChild(View child, TableView.CellPosition position)
536         {
537             bool ret = NDalicPINVOKE.TableView_AddChild(swigCPtr, View.getCPtr(child), TableView.CellPosition.getCPtr(position));
538             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
539             return ret;
540         }
541
542         /// <summary>
543         /// Returns a child from the given layout position.
544         /// </summary>
545         /// <param name="position">The position in the table</param>
546         /// <returns>Child that was in the cell or an uninitialized handle</returns>
547         public View GetChildAt(TableView.CellPosition position)
548         {
549             View ret = new View(NDalicPINVOKE.TableView_GetChildAt(swigCPtr, TableView.CellPosition.getCPtr(position)), true);
550             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
551             return ret;
552         }
553
554         /// <summary>
555         /// Removes a child from the given layout position.
556         /// </summary>
557         /// <param name="position">The position for the child to remove</param>
558         /// <returns>Child that was removed or an uninitialized handle</returns>
559         public View RemoveChildAt(TableView.CellPosition position)
560         {
561             View ret = new View(NDalicPINVOKE.TableView_RemoveChildAt(swigCPtr, TableView.CellPosition.getCPtr(position)), true);
562             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
563             return ret;
564         }
565
566         /// <summary>
567         /// Finds the child's layout position.
568         /// </summary>
569         /// <param name="child">The child to search for</param>
570         /// <param name="position">The position for the child</param>
571         /// <returns>true if the child was included in this TableView</returns>
572         public bool FindChildPosition(View child, TableView.CellPosition position)
573         {
574             bool ret = NDalicPINVOKE.TableView_FindChildPosition(swigCPtr, View.getCPtr(child), TableView.CellPosition.getCPtr(position));
575             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
576             return ret;
577         }
578
579         /// <summary>
580         /// Inserts a new row to given index.
581         /// </summary>
582         /// <param name="rowIndex">The rowIndex of the new row</param>
583         public void InsertRow(uint rowIndex)
584         {
585             NDalicPINVOKE.TableView_InsertRow(swigCPtr, rowIndex);
586             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
587         }
588
589         /// <summary>
590         /// Deletes a row from the given index.<br>
591         /// Removed elements are deleted.<br>
592         /// </summary>
593         /// <param name="rowIndex">The rowIndex of the row to delete</param>
594         public void DeleteRow(uint rowIndex)
595         {
596             NDalicPINVOKE.TableView_DeleteRow__SWIG_0(swigCPtr, rowIndex);
597             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
598         }
599
600         /// <summary>
601         /// Inserts a new column to the given index.
602         /// </summary>
603         /// <param name="columnIndex">The columnIndex of the new column</param>
604         public void InsertColumn(uint columnIndex)
605         {
606             NDalicPINVOKE.TableView_InsertColumn(swigCPtr, columnIndex);
607             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
608         }
609
610         /// <summary>
611         /// Deletes a column from the given index.<br>
612         /// Removed elements are deleted.<br>
613         /// </summary>
614         /// <param name="columnIndex">The columnIndex of the column to delete</param>
615         public void DeleteColumn(uint columnIndex)
616         {
617             NDalicPINVOKE.TableView_DeleteColumn__SWIG_0(swigCPtr, columnIndex);
618             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
619         }
620
621         /// <summary>
622         /// Resizes the TableView.
623         /// </summary>
624         /// <param name="rows">The rows for the table</param>
625         /// <param name="columns">The columns for the table</param>
626         public void Resize(uint rows, uint columns)
627         {
628             NDalicPINVOKE.TableView_Resize__SWIG_0(swigCPtr, rows, columns);
629             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
630         }
631
632         /// <summary>
633         /// Sets horizontal and vertical padding between cells.
634         /// </summary>
635         /// <param name="padding">Width and height</param>
636         public void SetCellPadding(Size2D padding)
637         {
638             NDalicPINVOKE.TableView_SetCellPadding(swigCPtr, Size2D.getCPtr(padding));
639             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
640         }
641
642         /// <summary>
643         /// Gets the current padding as width and height.
644         /// </summary>
645         /// <returns>The current padding as width and height</returns>
646         public Vector2 GetCellPadding()
647         {
648             Vector2 ret = new Vector2(NDalicPINVOKE.TableView_GetCellPadding(swigCPtr), true);
649             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
650             return ret;
651         }
652
653         /// <summary>
654         /// Specifies this row as fitting its height to its children.
655         /// </summary>
656         /// <param name="rowIndex">The row to set</param>
657         public void SetFitHeight(uint rowIndex)
658         {
659             NDalicPINVOKE.TableView_SetFitHeight(swigCPtr, rowIndex);
660             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
661         }
662
663         /// <summary>
664         /// Checks if the row is a fit row.
665         /// </summary>
666         /// <param name="rowIndex">The row to check</param>
667         /// <returns>true if the row is fit</returns>
668         public bool IsFitHeight(uint rowIndex)
669         {
670             bool ret = NDalicPINVOKE.TableView_IsFitHeight(swigCPtr, rowIndex);
671             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
672             return ret;
673         }
674
675         /// <summary>
676         /// Specifies this column as fitting its width to its children.
677         /// </summary>
678         /// <param name="columnIndex">The column to set</param>
679         public void SetFitWidth(uint columnIndex)
680         {
681             NDalicPINVOKE.TableView_SetFitWidth(swigCPtr, columnIndex);
682             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
683         }
684
685         /// <summary>
686         /// Checks if the column is a fit column.
687         /// </summary>
688         /// <param name="columnIndex">The column to check</param>
689         /// <returns>true if the column is fit</returns>
690         public bool IsFitWidth(uint columnIndex)
691         {
692             bool ret = NDalicPINVOKE.TableView_IsFitWidth(swigCPtr, columnIndex);
693             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
694             return ret;
695         }
696
697         /// <summary>
698         /// Sets a row to have fixed height.<br>
699         /// Setting a fixed height of 0 has no effect.<br>
700         /// </summary>
701         /// <param name="rowIndex">The rowIndex for row with fixed height</param>
702         /// <param name="height">The height in world coordinate units</param>
703         public void SetFixedHeight(uint rowIndex, float height)
704         {
705             NDalicPINVOKE.TableView_SetFixedHeight(swigCPtr, rowIndex, height);
706             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
707         }
708
709         /// <summary>
710         /// Gets a row's fixed height.
711         /// </summary>
712         /// <param name="rowIndex">The row index with fixed height</param>
713         /// <returns>height The height in world coordinate units</returns>
714         public float GetFixedHeight(uint rowIndex)
715         {
716             float ret = NDalicPINVOKE.TableView_GetFixedHeight(swigCPtr, rowIndex);
717             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
718             return ret;
719         }
720
721         /// <summary>
722         /// Sets a row to have relative height. Relative height means percentage of
723         /// the remainder of the table height after subtracting Padding and Fixed height rows.<br>
724         /// Setting a relative height of 0 has no effect.<br>
725         /// </summary>
726         /// <param name="rowIndex">The rowIndex for row with relative height</param>
727         /// <param name="heightPercentage">The height percentage between 0.0f and 1.0f</param>
728         public void SetRelativeHeight(uint rowIndex, float heightPercentage)
729         {
730             NDalicPINVOKE.TableView_SetRelativeHeight(swigCPtr, rowIndex, heightPercentage);
731             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
732         }
733
734         /// <summary>
735         /// Gets a row's relative height.
736         /// </summary>
737         /// <param name="rowIndex">The row index with relative height</param>
738         /// <returns>Height in percentage units, between 0.0f and 1.0f</returns>
739         public float GetRelativeHeight(uint rowIndex)
740         {
741             float ret = NDalicPINVOKE.TableView_GetRelativeHeight(swigCPtr, rowIndex);
742             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
743             return ret;
744         }
745
746         /// <summary>
747         /// Sets a column to have fixed width.<br>
748         /// Setting a fixed width of 0 has no effect.<br>
749         /// </summary>
750         /// <param name="columnIndex">The columnIndex for column with fixed width</param>
751         /// <param name="width">The width in world coordinate units</param>
752         public void SetFixedWidth(uint columnIndex, float width)
753         {
754             NDalicPINVOKE.TableView_SetFixedWidth(swigCPtr, columnIndex, width);
755             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
756         }
757
758         /// <summary>
759         /// Gets a column's fixed width.
760         /// </summary>
761         /// <param name="columnIndex">The column index with fixed width</param>
762         /// <returns>Width in world coordinate units</returns>
763         public float GetFixedWidth(uint columnIndex)
764         {
765             float ret = NDalicPINVOKE.TableView_GetFixedWidth(swigCPtr, columnIndex);
766             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
767             return ret;
768         }
769
770         /// <summary>
771         /// Sets a column to have relative width. Relative width means percentage of
772         /// the remainder of table width after subtracting Padding and Fixed width columns.<br>
773         /// Setting a relative width of 0 has no effect.<br>
774         /// </summary>
775         /// <param name="columnIndex">The columnIndex for column with fixed width</param>
776         /// <param name="widthPercentage">The widthPercentage between 0.0f and 1.0f</param>
777         public void SetRelativeWidth(uint columnIndex, float widthPercentage)
778         {
779             NDalicPINVOKE.TableView_SetRelativeWidth(swigCPtr, columnIndex, widthPercentage);
780             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
781         }
782
783         /// <summary>
784         /// Gets a column's relative width.
785         /// </summary>
786         /// <param name="columnIndex">The column index with relative width</param>
787         /// <returns>Width in percentage units, between 0.0f and 1.0f</returns>
788         public float GetRelativeWidth(uint columnIndex)
789         {
790             float ret = NDalicPINVOKE.TableView_GetRelativeWidth(swigCPtr, columnIndex);
791             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
792             return ret;
793         }
794
795         /// <summary>
796         /// Gets the amount of rows in the table.
797         /// </summary>
798         /// <returns>The amount of rows in the table</returns>
799         public uint GetRows()
800         {
801             uint ret = NDalicPINVOKE.TableView_GetRows(swigCPtr);
802             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
803             return ret;
804         }
805
806         /// <summary>
807         /// Gets the amount of columns in the table.
808         /// </summary>
809         /// <returns>The amount of columns in the table</returns>
810         public uint GetColumns()
811         {
812             uint ret = NDalicPINVOKE.TableView_GetColumns(swigCPtr);
813             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
814             return ret;
815         }
816
817         /// <summary>
818         /// Sets the alignment on a cell.<br>
819         /// Cells without calling this function have the default values of LEFT and TOP respectively.<br>
820         /// </summary>
821         /// <param name="position">The cell to set alignment on</param>
822         /// <param name="horizontal">The horizontal alignment</param>
823         /// <param name="vertical">The vertical alignment</param>
824         public void SetCellAlignment(TableView.CellPosition position, HorizontalAlignmentType horizontal, VerticalAlignmentType vertical)
825         {
826             NDalicPINVOKE.TableView_SetCellAlignment(swigCPtr, TableView.CellPosition.getCPtr(position), (int)horizontal, (int)vertical);
827             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
828         }
829
830         internal enum PropertyRange
831         {
832             PROPERTY_START_INDEX = PropertyRanges.PROPERTY_REGISTRATION_START_INDEX,
833             PROPERTY_END_INDEX = View.PropertyRange.PROPERTY_START_INDEX + 1000,
834             CHILD_PROPERTY_START_INDEX = PropertyRanges.CHILD_PROPERTY_REGISTRATION_START_INDEX,
835             CHILD_PROPERTY_END_INDEX = PropertyRanges.CHILD_PROPERTY_REGISTRATION_START_INDEX + 1000
836         }
837
838         /// <summary>
839         /// Enumeration for describing how the size of a row / column has been set.
840         /// </summary>
841         public enum LayoutPolicy
842         {
843             Fixed,
844             Relative,
845             Fill,
846             Fit
847         }
848
849         /// <summary>
850         /// the amount of rows in the table.
851         /// </summary>
852         public int Rows
853         {
854             get
855             {
856                 int temp = 0;
857                 GetProperty(TableView.Property.ROWS).Get(ref temp);
858                 return temp;
859             }
860             set
861             {
862                 SetProperty(TableView.Property.ROWS, new Tizen.NUI.PropertyValue(value));
863             }
864         }
865         /// <summary>
866         /// the amount of columns in the table.
867         /// </summary>
868         public int Columns
869         {
870             get
871             {
872                 int temp = 0;
873                 GetProperty(TableView.Property.COLUMNS).Get(ref temp);
874                 return temp;
875             }
876             set
877             {
878                 SetProperty(TableView.Property.COLUMNS, new Tizen.NUI.PropertyValue(value));
879             }
880         }
881         /// <summary>
882         /// padding between cells.
883         /// </summary>
884         public Vector2 CellPadding
885         {
886             get
887             {
888                 Vector2 temp = new Vector2(0.0f, 0.0f);
889                 GetProperty(TableView.Property.CELL_PADDING).Get(temp);
890                 return temp;
891             }
892             set
893             {
894                 SetProperty(TableView.Property.CELL_PADDING, new Tizen.NUI.PropertyValue(value));
895             }
896         }
897
898         /// <summary>
899         /// The number of layout rows
900         /// </summary>
901         public PropertyMap LayoutRows
902         {
903             get
904             {
905                 PropertyMap temp = new PropertyMap();
906                 GetProperty(TableView.Property.LAYOUT_ROWS).Get(temp);
907                 return temp;
908             }
909             set
910             {
911                 SetProperty(TableView.Property.LAYOUT_ROWS, new Tizen.NUI.PropertyValue(value));
912             }
913         }
914
915         /// <summary>
916         /// The number of layout columns
917         /// </summary>
918         public PropertyMap LayoutColumns
919         {
920             get
921             {
922                 PropertyMap temp = new PropertyMap();
923                 GetProperty(TableView.Property.LAYOUT_COLUMNS).Get(temp);
924                 return temp;
925             }
926             set
927             {
928                 SetProperty(TableView.Property.LAYOUT_COLUMNS, new Tizen.NUI.PropertyValue(value));
929             }
930         }
931
932     }
933 }