Skip to content

Commit

Permalink
final polish
Browse files Browse the repository at this point in the history
  • Loading branch information
Clemapfel committed Sep 14, 2023
1 parent e720c48 commit 636c787
Show file tree
Hide file tree
Showing 4 changed files with 56 additions and 68 deletions.
11 changes: 8 additions & 3 deletions docs/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ using Documenter, Pkg, InteractiveUtils
using Mousetrap

let file = open("docs/src/02_library/classes.md", "w+")
@info "Exporting..."
@info "Mousetrap: Exporting Index..."
write(file, "# Index: Classes\n")

for name in sort(union(
Expand Down Expand Up @@ -144,7 +144,12 @@ let file = open("docs/src/02_library/classes.md", "w+")
write(file, "```\n")
end
close(file)
@info "Done."
end

makedocs(sitename="Mousetrap")
makedocs(
sitename="Mousetrap",
format = Documenter.HTML(
size_threshold_warn = nothing,
size_threshold = Integer(2e+6)
)
)
7 changes: 3 additions & 4 deletions docs/src/01_manual/04_widgets.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ In this chapter, we will learn:
```

!!! note "Images in this Chapter"
Images for this chapter were captured on a Fedora Linux machine running Gnome 44.2. The exact look of each window and widget may be slightly different, depending on the users operating system and application theme. We will learn how to manually change the global theme in the [section on app customization](./07_os_interface.md#theme).
Images for this chapter were captured on a Fedora Linux machine running Gnome 44.2. The exact look of each window and widget may be slightly different, depending on the users operating system and application theme. We will learn how to manually change the look of widgets by creating our own theme in the [section on app customization](./10_theme_customization.md).

---

Expand Down Expand Up @@ -553,7 +553,7 @@ center_box = CenterBox(ORIENTATION_HORIZONTAL, Label("start"), Button(), Label("

## FlowBox

Third of the `Box` relatives, we have [`FlowBox`](@ref), which, unlike `Box`, **redistributes** its children along more than one row (or column, if vertical) depending on the available width (or height) of the `FlowBox`. This is useful for situations where we want to group a number of widgets in a way that does not impact resizability.
Third of the `Box` relatives, we have [`FlowBox`](@ref). This widget is similiar to `Box`, except that it will **redistribute** its children along more than one row (or column, if vertical) depending on the available width (or height) of the `FlowBox`. This is useful for situations where we want to group a number of widgets in a way that does not impact resizability.

```julia
flow_box = FlowBox(ORIENTATION_VERTICAL)
Expand Down Expand Up @@ -766,8 +766,7 @@ set_child!(window, toggle_button)
```@eval
using Mousetrap
Mousetrap.@signal_table(ToggleButton,
toggled,
clicked
toggled
)
```

Expand Down
20 changes: 10 additions & 10 deletions src/docgen/signals.jl
Original file line number Diff line number Diff line change
Expand Up @@ -35,31 +35,31 @@ const signal_descriptors = Dict([
),
:realize => (
void_signature,
"Emitted when a widget is shown for the first time after being initialized."
"Emitted when the widget is shown for the first time after being initialized."
),
:unrealize => (
void_signature,
"Emitted when a widget was hidden and no longer has an allocated area on screen."
"Emitted when the widget was hidden and no longer has an allocated area on screen."
),
:destroy => (
void_signature,
"Emitted when a widgets reference count reaches 0, it will be finalized and deleted permanently."
"Emitted when the widgets reference count reaches 0, it will be finalized and deleted permanently."
),
:hide => (
void_signature,
"Emitted when a widget is hidden, for example by calling `hide!`, being removed from its parent, or its parent being hidden."
"Emitted when the widget is hidden, for example by calling `hide!`, being removed from its parent, or its parent being hidden."
),
:show => (
void_signature,
"Emitted when a widget is shown, for example by calling `show!` or its parent being shown."
"Emitted when the widget is shown, for example by calling `show!` or its parent being shown."
),
:map => (
void_signature,
"Emitted when a widget has chosen its final size allocation and is assuming its size and position on screen."
"Emitted when the widget has chosen its final size allocation and is assuming its size and position on screen."
),
:unmap => (
void_signature,
"Emitted when a widget looses its current size allocation, usually in the process of being hidden or destroyed."
"Emitted when the widget looses its current size allocation, usually in the process of being hidden or destroyed."
),
:close_request => (
"(::T, [::Data_t]) -> WindowCloseRequestResult",
Expand All @@ -79,7 +79,7 @@ const signal_descriptors = Dict([
),
:clicked => (
void_signature,
"Emitted when the user clicks a widget using a mouse or touchscreen."
"Emitted when the user clicks the widget using a mouse or touchscreen."
),
:toggled => (
void_signature,
Expand Down Expand Up @@ -131,11 +131,11 @@ const signal_descriptors = Dict([
),
:focus_gained => (
void_signature,
"Emitted when a widget that is currently not focused becomes focus."
"Emitted when the widget that is currently not focused becomes focus."
),
:focus_lost => (
void_signature,
"Emitted when a widget that is currently focused looses focus."
"Emitted when the widget that is currently focused looses focus."
),
:pressed => (
"(::T, x::AbstractFloat, y::AbstractFloat, [::Data_t]) -> Nothing",
Expand Down
Loading

0 comments on commit 636c787

Please sign in to comment.