Commit Graph

88 Commits

Author SHA1 Message Date
Alexander Bondarenko
24519778e6
Add inputTextMultiline, inputTextWithHint (#92)
- Experimental explicit encoding for CStrings.
- Fix potential buffer overruns in inputText.
2021-09-12 11:43:44 +03:00
Alexander Bondarenko
4bfc7e7099
Add invisibleButton (#91) 2021-09-11 11:01:03 +00:00
Alexander Bondarenko
efaaa5723a
Add Show instances to structs and enums (#90) 2021-09-11 10:40:05 +00:00
Alexander Bondarenko
be7aa1e9b1
Add functions for getting window position and size (#89)
- getWindowPos
- getWindowSize
- getWindowWidth
- getWindowHeight

Closes #88
2021-09-11 10:09:11 +00:00
jpwidera
08b3139477
Remove seg faults (#87)
* Removed double OpenGl3Shutdown, leading to a segmentation fault in Main.hs.
* Changed nullPtr passing with Maybe to use DearImGui default arguments.
2021-09-11 10:00:08 +00:00
Ollie Charles
cede825dff
Bump haskell.nix (#86) 2021-09-08 16:19:57 +00:00
Ollie Charles
84a6b8a8fe
Allow parser-combinators-1.4 (#85) 2021-09-08 13:10:39 +01:00
Alexander Bondarenko
cb687b8f01
Prepare 1.1.0 (#83) 2021-09-01 18:05:18 +00:00
Alexander Bondarenko
8d07a5a42b
Add more withXXX wrappers (#82)
- withStyleColor
- withStyleVar
- withIndent
- withItemWidth

Closes #63
2021-09-01 17:23:59 +00:00
Alexander Bondarenko
d3a0396623
Add GLFW callbacks (#81)
Closes #80
2021-09-01 19:22:55 +03:00
Alexander Bondarenko
f49e81c739
Fix warnings (#79) 2021-08-30 17:08:23 +00:00
Alexander Bondarenko
5699f64e95
Bump imgui to 1.84.2 (#78) 2021-08-30 19:57:00 +03:00
Alexander Bondarenko
9e5b39850e
Prepare 1.0.2 (#77) 2021-08-30 19:20:26 +03:00
Alexander Bondarenko
d7dc999e8b
Add withID (#75)
Raw versions are specialized to match overloaded C++ functions.
2021-08-28 15:52:04 +00:00
Ollie Charles
bde2030c25
Upgrade Haskell.nix and niv (#73) 2021-07-01 12:58:55 +00:00
Alexander Bondarenko
1706b7e966
Fix changelog header and links (#72) 2021-06-30 22:44:31 +00:00
Alexander Bondarenko
bfe8453891
Fix missing headers in source dist (#71)
Fixes #50 again
2021-06-30 22:33:00 +00:00
Alexander Bondarenko
532eebd8ed
Prepare Hackage release (#70) 2021-07-01 00:47:23 +03:00
Alexander Bondarenko
d42eb672a1
Bump imgui to 1.83 (#66)
Fixes reported vulkan error among others.
2021-06-20 19:43:49 +00:00
sheaf
1d6b7cc97b
Relax MonadUnliftIO constraint on vulkanInit (#65) 2021-06-20 19:17:58 +00:00
sheaf
c4f3a1e0b9
Update all flags to allow setting them manually (#64) 2021-06-20 20:24:22 +03:00
Alexander Bondarenko
ff267143d0
Bump deps (#62) 2021-06-15 21:52:39 +00:00
Alexander Bondarenko
dcaad12ca8
Add more drags and sliders (#60)
- DragFloatRange2
- DragInt..4
- DragIntRange2
- DragScalar
- DragScalarN

- SliderAngle
- SliderInt..4
- SliderScalar
- SliderScalarN
- vSliderFloat
- vSliderInt
- vSliderScalar

Scalar sliders expose format and flags arguments.
2021-06-06 19:10:34 +03:00
Alexander Bondarenko
f584319577
Add more text widgets (#59)
- Text replaced with TextUnformatted
- TextColored
- TextDisabled
- TextWrapped
- LabelText
- BulletText
2021-06-05 09:01:48 +00:00
Alexander Bondarenko
6ccee5234b
Add withFullscreen and related machinery (#55)
- `fullscreenFlags` available for those who want an alternative
  to `withFullscreen` without reinventing too much.
- Raw.begin got `open` and `flags` arguments.
- Added Raw.setNextWindowFullscreen combo block.
2021-06-04 23:18:16 +03:00
Ollie Charles
73eee5fc9e
Upgrade to dear-imgui v1.82 (#57) 2021-05-08 11:58:25 +00:00
Alexander Bondarenko
5cdce50c3a
Add wantCaptureMouse, wantCaptureKeyboard (#54) 2021-05-03 12:57:23 +03:00
Alexander Bondarenko
8723ac2625
Add withXxx and withXxxOpen wrappers for begin/end pairs (#49)
Adds dependency on unliftio for monad-preserving brackets.

Fixes #32
2021-04-18 13:10:20 +03:00
sheaf
b921a72960
Update generator for GHC 9.2 (#48) 2021-04-09 17:18:00 +03:00
Alexander Bondarenko
5634b6f67d
Extract raw C bindings (#44)
The original DearImGui interface hasn't changed.
2021-04-05 20:16:09 +03:00
Tristan de Cacqueray
3949882060
Disable build-depends when not building executables (#43)
This change follows up on https://github.com/haskell-game/dear-imgui.hs/pull/41
where it seems like cabal still need the examples dependency even when they are
not buildable, e.g.: `next goal: vulkan-utils (dependency of dear-imgui)` with
cabal-install version 3.2.0.0.
2021-03-12 15:39:24 +00:00
Alexander Bondarenko
b0337eb084
Update StateVars only when its widget reports a change (#42) 2021-03-12 11:03:54 +00:00
Alexander Bondarenko
ebd5286e1c
Build executables conditionally on features (#41)
* Build executables conditionally on features

* Put away examples under a flag
2021-03-11 22:59:57 +00:00
Alexander Bondarenko
2eddbdfa04
Recover init and shutdown from withVulkan (#40) 2021-03-11 09:00:30 +00:00
techmindful
007b3cccb8
Bindings for item widths functions, and text input widget. (#38) 2021-02-21 11:39:17 +00:00
sheaf
06921defb1
Generator: use mkName instead of newName (#37) 2021-02-09 11:23:23 +00:00
sheaf
d4aec47f4e
Handle remaining enums (#36)
This handles the remaining enum types in the headers that aren't in the enums section.

It also automatically handles adding all the enumerations to the inline-c context types table, and a small improvement to the display of parse error messages.
2021-02-07 23:07:14 +00:00
sheaf
921aefdd69
Allow building of OpenGL3 component on Windows/Darwin (#35) 2021-02-06 21:19:56 +00:00
Ollie Charles
9e5dbd755f
Add haskell-language-server to the dev shell (#34) 2021-02-06 15:43:26 +00:00
Ollie Charles
f9412effde
Wrap the OpenGL 3 backend (#20) 2021-02-06 14:44:58 +00:00
sheaf
ac74572121
Add tab bar functions (#30) 2021-02-06 13:26:28 +00:00
sheaf
860720e7c2
Define types for use in ImGui Context (#31)
Just doing a little cleanup:

* some functions were not exported,
* some functions were missing the initial | for their documentation,
* add types to the ImGui Context instead of coercing to int. This is more robust, in case upstream changes any of the larger enums to be 64 bits instead of 32 for instance
2021-02-06 10:17:37 +00:00
Tim Pierson
de0e87612c
Add setNextWindow functions, pushColor, pushStyle, indent-related functions (#27) 2021-02-05 23:46:48 +00:00
Shaun Sharples
d7686f84e4
Add support for GLFW (#26)
Co-authored-by: Oliver Charles <ollie@ocharles.org.uk>
2021-02-05 21:44:52 +00:00
Shaun Sharples
643d2ea5b7
Add combo to wrap ImGUI::Combo() (#28)
Co-authored-by: Oliver Charles <ollie@ocharles.org.uk>
2021-02-05 21:20:32 +00:00
sheaf
895f5c1926
Parse enums from headers & generate code (#19) 2021-02-05 20:57:17 +00:00
Ollie Charles
81582ba6eb
Ignore imgui.ini (#29)
This file gets generated by routine testing but we'll never want to commit it.
2021-02-05 20:22:26 +00:00
Ollie Charles
af49a7b3fb
Wrap ImGui::ListBox() (#25) 2021-01-28 23:38:59 +00:00
Ollie Charles
bb82e87553
Wrap ImGui::TreeNode, TreePush, TreePop (#24) 2021-01-28 23:28:45 +00:00
Ollie Charles
24903ce76f
Implement ImGui::DragFloat{,2,3,4} (#23) 2021-01-28 23:10:58 +00:00