| ![[Previous]](../image-lib/prev.gif) | ![[Contents]](../image-lib/contents.gif) | ![[Index]](../image-lib/keyword_index.gif) | ![[Next]](../image-lib/next.gif) | 
Insert a widget in the widget family hierarchy
int PtWidgetInsert ( PtWidget_t *widget,
                     PtWidget_t *new_sibling,
                     int behind );
This function inserts widget into the widget family hierarchy as a brother of the widget new_sibling, based on the value of behind:
Use this function to insert a widget into the focus order of a group. For example, if you have widget A and widget C with a focus order of A-->C, you could insert widget B into the focus order after widget A by making the following call:
PtWidgetInsert (B, A, 0);
The focus order would then be A-->B-->C.
Photon
| Safety: | |
|---|---|
| Interrupt handler | No | 
| Signal handler | No | 
| Thread | No | 
PtGetParentWidget(), PtWidgetBrotherBehind(), PtWidgetBrotherInFront(), PtWidgetChildBack(), PtWidgetChildFront(), PtWidgetInsert(), PtWidgetParent(), PtWidgetToBack(), PtWidgetToFront()
"Ordering widgets" in the Creating Widgets in Application Code chapter of the Photon Programmer's Guide
| ![[Previous]](../image-lib/prev.gif) | ![[Contents]](../image-lib/contents.gif) | ![[Index]](../image-lib/keyword_index.gif) | ![[Next]](../image-lib/next.gif) |