-
Notifications
You must be signed in to change notification settings - Fork 354
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement get_*_draw_list
and DrawList
drawing functions
#242
Conversation
- Rename WindowDrawList to DrawList and make [Window|Foreground|Background]DrawList into a wrapper for DrawList - Add 'ui lifetime to DrawData and *DrawList - Make all DrawList methods take &mut self instead of &self
@Gekkio I believe this PR should be a safe implementation of the drawlist apis. Notably:
Edit: looks like methods like let draw_list = ...;
{
let draw_list_channels = draw_list.channel_split(2);
draw_list_channels.add_line(...);
draw_list_channels.set_current(0);
....
// channel split is popped here
} thoughts? |
What can be done to implement this functions into imgui-rs? Anything i can help with? |
@saucesaft Aside from the merge conflict and failing CI checks, the bit in my last comment about lifetimes regarding I think @Gekkio is pretty busy (I am too!) and I believe neither of us have looked at this since the summer! Feel free to clean this up and re-propose the changes, I think some test cases that sanity check the API would catch things like in the second half of my last comment. |
Any update on this? :) In my use case I need access to the drawlist.. |
Closing, as I believe this was addressed in #414! |
Closes #220
WindowDrawList
toDrawList
and make[Window|Foreground|Background]DrawList
into a wrapper forDrawList
'ui
lifetime toDrawData
and*DrawList
DrawList
methods take&mut self
instead of&self
Breaks DrawData/DrawList API?
window_draw_list
todraw_list
, but for now, this keeps the diff sane.DrawList
,ImColor
publicly