Sets the size of an object
Contents |
bool wb_set_size (int wbobject, mixed width [, int height])
| width | height | Applies to | Action taken |
|---|---|---|---|
| Positive integer | Positive integer | window or control | Sets the window or control size to width and height pixels. |
| WBC_NORMAL | (not supplied) | window | Restores the window, if it is not already. |
| WBC_MINIMIZED | (not supplied) | window | Minimizes the window, if it is not already. |
| WBC_MAXIMIZED | (not supplied) | window | Maximizes the window, if it is not already. |
| Array of integers | (not supplied) | ListView | Changes the column widths of the control. |
Returns TRUE on success or FALSE if an error occurs.
// Set the size of a control wb_set_size($ctrl, 120, 30); // Maximize a window wb_set_size($win, WBC_MAXIMIZED); // Set the column widths of a treeview. // First column is set to 100 pixels, second is left alone, third is set to default. wb_set_size($list, array(100, null, -1));