wlmaker
|
Functions | |
static void | _wlmtk_bordered_container_update_layout (wlmtk_container_t *container_ptr) |
static wlmtk_rectangle_t * | _wlmtk_bordered_create_border_rectangle (wlmtk_bordered_t *bordered_ptr) |
static void | _wlmtk_bordered_destroy_border_rectangle (wlmtk_bordered_t *bordered_ptr, wlmtk_rectangle_t **rectangle_ptr_ptr) |
static void | _wlmtk_bordered_set_positions (wlmtk_bordered_t *bordered_ptr) |
bool | wlmtk_bordered_init (wlmtk_bordered_t *bordered_ptr, wlmtk_element_t *element_ptr, const wlmtk_margin_style_t *style_ptr) |
void | wlmtk_bordered_fini (wlmtk_bordered_t *bordered_ptr) |
void | wlmtk_bordered_set_style (wlmtk_bordered_t *bordered_ptr, const wlmtk_margin_style_t *style_ptr) |
wlmtk_element_t * | wlmtk_bordered_element (wlmtk_bordered_t *bordered_ptr) |
static void | test_init_fini (bs_test_t *test_ptr) |
void | test_rectangle_pos (bs_test_t *test_ptr, wlmtk_rectangle_t *rect_ptr, int x, int y, int width, int height) |
Variables | |
static const wlmtk_container_vmt_t | bordered_container_vmt |
const bs_test_case_t | wlmtk_bordered_test_cases [] |
static const wlmtk_margin_style_t | test_style |
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
https://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
|
static |
Updates the layout of the bordered element.
container_ptr |
|
static |
Creates a border rectangle and adds it to bordered_ptr
.
|
static |
Removes the rectangle from bordered_ptr
, destroys it and NULLs it.
|
static |
Updates the position of all 4 border elements.
Retrieves the position and dimensions of wlmtk_bordered_t::element_ptr and arranges the 4 border elements around it.
bordered_ptr |
|
static |
Exercises setup and teardown.
void test_rectangle_pos | ( | bs_test_t * | test_ptr, |
wlmtk_rectangle_t * | rect_ptr, | ||
int | x, | ||
int | y, | ||
int | width, | ||
int | height | ||
) |
Helper: Tests that the rectangle is positioned as specified.
wlmtk_element_t * wlmtk_bordered_element | ( | wlmtk_bordered_t * | bordered_ptr | ) |
Returns the superclass wlmtk_element_t for bordered_ptr
.
void wlmtk_bordered_fini | ( | wlmtk_bordered_t * | bordered_ptr | ) |
Un-initializes the bordered element.
bordered_ptr |
bool wlmtk_bordered_init | ( | wlmtk_bordered_t * | bordered_ptr, |
wlmtk_element_t * | element_ptr, | ||
const wlmtk_margin_style_t * | style_ptr | ||
) |
Initializes the bordered element.
The bordered element positions the element within such that north-western corner is at (0, 0).
bordered_ptr | |
element_ptr | |
style_ptr |
void wlmtk_bordered_set_style | ( | wlmtk_bordered_t * | bordered_ptr, |
const wlmtk_margin_style_t * | style_ptr | ||
) |
Updates the style.
bordered_ptr | |
style_ptr |
|
static |
Virtual method table: wlmtk_container_t at wlmtk_bordered_t.
|
static |
Style used for tests.
const bs_test_case_t wlmtk_bordered_test_cases[] |
Unit test cases.