Skip to content

Commit

Permalink
Merge pull request #140 from Gnimuc/docs
Browse files Browse the repository at this point in the history
Minor docs improvements
  • Loading branch information
JamesWrigley authored Aug 9, 2024
2 parents fcf3cd9 + a71acdf commit 333742a
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 3 deletions.
2 changes: 1 addition & 1 deletion docs/src/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ CollapsedDocStrings = true

# API Reference
This page documents the wrapper functions we have for the ImGui API. The
backends are documented separately in [Backends](@ref).
[Backends](@ref) and the [Makie integration](@ref) are documented separately.

You can always get the current ImGui version with:
```@docs
Expand Down
4 changes: 2 additions & 2 deletions docs/src/index.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# CImGui
This package provides a Julia language wrapper for
[cimgui](https://github.com/cimgui/cimgui): a thin c-api wrapper
[cimgui](https://github.com/cimgui/cimgui): a thin C wrapper
programmatically generated for the excellent C++ immediate mode gui [Dear
ImGui](https://github.com/ocornut/imgui). Dear ImGui is mainly for creating
content creation tools and visualization / debug tools. You could browse
Expand Down Expand Up @@ -100,7 +100,7 @@ interest to you if you're looking for state management frameworks.
### Backend
The default backend is based on
[ModernGL](https://github.com/JuliaGL/ModernGL.jl) and
[GLFW](https://github.com/JuliaGL/GLFW.jl) which are stable and under actively
[GLFW](https://github.com/JuliaGL/GLFW.jl) which are stable and actively
maintained. Other popular backends like
[SFML](https://github.com/zyedidia/SFML.jl) and
[SDL](https://github.com/ariejdl/SDL.jl) could be added in the future if someone
Expand Down
12 changes: 12 additions & 0 deletions docs/src/makie.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,18 @@ Here's a quick demo using
(you may want to `Right click -> Open in new tab` to see it in full resolution):
![Makie demo](assets/makie-demo.gif)

## Thread safety
None of this is thread-safe. Here's what you can and can't do:
- You can create a `Figure` on any thread and pass it to [`MakieFigure()`](@ref)
to display.
- You cannot call [`MakieFigure()`](@ref) (or generally any ImGui functions) on
a different thread from the [`render()`](@ref) thread.
- You cannot update a `Figure` from a separate thread, including with
observables. Updating it from the same thread (i.e. in the renderloop) is
fine.

## API

```@docs
MakieFigure
```

0 comments on commit 333742a

Please sign in to comment.