blob: 4628104c1e2b7cce2fc2cd210bbd688a01b0fbfd (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
## Name
Library or Application Defined Widgets
## Description
Some applications and libraries find it useful to define their own **LibGUI** widgets.
## Examples
```gml
@Web::OutOfProcessWebView {
name: "web_view"
min_width: 340
min_height: 160
visible: false
}
```
They are defined using `REGISTER_WIDGET()`, just as they are in **LIbGUI**.
```cpp
REGISTER_WIDGET(Web, OutOfProcessWebView)
...
OutOfProcessWebView::OutOfProcessWebView()
{
set_should_hide_unnecessary_scrollbars(true);
set_focus_policy(GUI::FocusPolicy::StrongFocus);
create_client();
}
...
```
|