Skip to content

Commit

Permalink
add common issues page
Browse files Browse the repository at this point in the history
  • Loading branch information
Aylur committed Jan 8, 2024
1 parent 926ba0b commit bea710a
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
1 change: 1 addition & 0 deletions astro.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ const config = [
'Custom Service',
'Subclassing GTK Widgets',
'Examples',
'Common Issues'
];

const widgets = [
Expand Down
21 changes: 21 additions & 0 deletions src/content/docs/config/common-issues.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
---
title: Common Issues
---

## Window doesn't show up

When a window doesn't have a size allocation on construction,
it will never show up.
You can solve this by wrapping the children in a box
and forcing the box to have some size.
For example when the window's direct child is a
revealer that starts off with `reveal_child: false`

```js
Widget.Window({
child: Widget.Box({
css: 'padding: 1px;',
child: Widget.Revealer(),
}),
})
```

0 comments on commit bea710a

Please sign in to comment.