AllenDang / cimgui-go

Auto generated Go wrapper for Dear ImGui via cimgui
MIT License
332 stars 51 forks source link

GetID missing #271

Closed ptxmac closed 6 months ago

ptxmac commented 6 months ago

See https://github.com/cimgui/cimgui/blob/docking_inter/generator/output/definitions.json#L10411

gucio321 commented 6 months ago
func (self *Window) InternalIDStrV(str string, str_end string) ID {
ptxmac commented 6 months ago

Thanks, I always keep forgetting that a lot of methods are prefixed with Internal Maybe we should reconsider that? It's nice to signify that the methods are not part of the stable API, but imgui and cimgui doesn't do anything special about them

gucio321 commented 6 months ago

My reson for introducing that was, that (in my opinion) the fact that the function is in imgui_internal means that you should not use it. (note that before #99 internal functions were completely skipped :smile:)

idk if we should change this. @AllenDang ?

ptxmac commented 6 months ago

Yeah. That makes sense, but I think imgui use internal for two things: stuff that are internal and should rarely be used, but also unstable / beta apis.

For instance most of the stuff related to docking is in internal. But the docking branch is getting close to 4 years old 😬

gucio321 commented 6 months ago

For instance most of the stuff related to docking is in internal. But the docking branch is getting close to 4 years old 😬

yeah, but, honestly speaking, this is an issue of imgui, not our. _internal has a specified meaning, and this is imgui's fault that they keep docking api in there despit it shouldn't be there.

We have a specified interpretation of what internal means and it is (in my opinion) reasonable. You can always use this api, but you are informed that it is Internal method. in imgui you'd do that by including imgui_internal.h, and here in go you do it this way :smile:

AllenDang commented 6 months ago

I think we should respect the API sorting from Imgur, if something is "internal", we treat them as internal.