@rrraptor, now that most of my problems are gone, is there a progress about the 'ALT key' issues?
Updated dll, you can test it now.
now the 'ALT key is stuck' (for dragInt e.g.) issue is gone, very good.
but the other issue with ALT is still there, namely that when i press ALT and release it then gideros functions often still think that ALT is pressed (e.g. no onKeyUp(event) event seems to be registered for ALT release)
EDIT: actually it seems that consistently every second onKeyUp(event) is noticed for ALT release, perhaps this will help to find the issue.
On the latest 2021.8 gideros, is imgui's pushFont( broken for anyone else?
Coder, video game industry veteran (since the '80s, ❤'s assembler), arrested - never convicted hacker (in the '90s), dad of five, he/him (if that even matters!). https://deluxepixel.com
On the latest 2021.8 gideros, is imgui's pushFont( broken for anyone else?
Strange, I havent touched the fonts code for quite a while... Damn it happened due to code refactoring, I messed up arguments So, for now you can easily fix it by replacing colon with dot, eg:
ui:pushFont(g_font1)-- before
ui.pushFont(g_font1)-- after
Coder, video game industry veteran (since the '80s, ❤'s assembler), arrested - never convicted hacker (in the '90s), dad of five, he/him (if that even matters!). https://deluxepixel.com
Are the docs for scaledImageButtonWithText correct?
I tried ui:scaledImageButtonWithText(texture,text,iconwidth,iconheight,buttonwidth,buttonheight)
The icon height seems to make no difference at all
This resulted in no icon at all (using what I think are the default values for the extra parameters?): scaledImageButtonWithText(texture,text,iw,ih,bw,bh,0,ImGui.ImageScaleMode_LetterBox,false,0.5,0.5,ImGui.Dir_Left,0xffffff,1,0,0,0,0)
Do you have a code example?
Coder, video game industry veteran (since the '80s, ❤'s assembler), arrested - never convicted hacker (in the '90s), dad of five, he/him (if that even matters!). https://deluxepixel.com
i lost track of the many arguments, but this e.g. is what i do: imgui:scaledImageButtonWithTextPadded(self.texture, "label", 19, 19, 99, 19, 0, ImGui.ImageScaleMode_LetterBox, false, 0.5,0.5, ImGui.Dir_Left, 0,0,0xffffff, 1,0,0,0, 0)
note the "clip_offset_x = 0, clip_offset_y = 0" part in the docs.
Coder, video game industry veteran (since the '80s, ❤'s assembler), arrested - never convicted hacker (in the '90s), dad of five, he/him (if that even matters!). https://deluxepixel.com
perhaps, but not now when it breaks all my code. also it would get really long this way as in many cases one anyway wants to set the majority of parameters from something different from the defaults.
i think the best is to maintain compatibility with original imgui syntax as much as possible and add extra gideros-unique parameters to the end.
It could be done now and not break code, the table just needs to be checked for in the function. If it's a table then... else do the current way.
Coder, video game industry veteran (since the '80s, ❤'s assembler), arrested - never convicted hacker (in the '90s), dad of five, he/him (if that even matters!). https://deluxepixel.com
@rrraptor , i started to use header for a table using ImGui:tableHeadersRow(). the header items change bg color on hover, although clicking on them does nothing. can i disable these interactions on mouse? (so that the headers do not change color on hover and click) thanks
btw yet (jit?) another lua imgui wrapper: https://github.com/sonoro1234/LuaJIT-ImGui i don't think it is useful for you now but perhaps it's good to know about it if not yet.
@rrraptor Looks like there has been a hotfix for 1.84, now 1.84.1 ...
Coder, video game industry veteran (since the '80s, ❤'s assembler), arrested - never convicted hacker (in the '90s), dad of five, he/him (if that even matters!). https://deluxepixel.com
@rrraptor , i started to use header for a table using ImGui:tableHeadersRow(). the header items change bg color on hover, although clicking on them does nothing. can i disable these interactions on mouse? (so that the headers do not change color on hover and click) thanks
I think you can create a custom header by adding extra row with text and custom bg color.
btw yet (jit?) another lua imgui wrapper: https://github.com/sonoro1234/LuaJIT-ImGui i don't think it is useful for you now but perhaps it's good to know about it if not yet.
I know, there is a few more bindings, but since Im not a master of C++... I decided to create my own
It exactly looks like a problem, hovering on text does not increase HoveredId. This is what happens for me and it seems happens for you too. The link you've sent should help me? should i do something with isItemHovered? i'm stuck.
@keszegh Text widget does not have ID, so HoverIdTimer does not increment on text. You can do something like this
function ImGui:hoverableText(text)local backupX,backupY = self:getCursorPos()local w, h = self:calcTextSize(text)
self:invisibleButton("##dummy",w,h)
self:setCursorPos(backupX,backupY)
self:text(text)end
thanks, i will try this. strange though, one would think that at least with pushID one can assign an ID to a text widget too. sometimes imgui has some strange things in it, even though i like it a lot overall. one major thing i miss is those menu elements in the title row i asked for earlier.
i'm again stuck with a thing. can you help me to make a menu which looks like the one made with beginMainMenuBar() but it is not necessarily on top (and is movable) and not spanning the whole width (the size should be fixed though). i tried making a regular window with no title and menu on and height 0 but it still adds a bit of oversize below.
there are some of my questions pending, i'd be grateful for answers.
and there is a new one: my old gui had the ability that whenever a button/gui item could be right-clicked then a long click triggered the same effect. this was practical for android version where on touchscreen there is no natural way to right-click.
whenever i open a context menu with right-click, i guess i could make it react also to long click, but e.g. i don't know how to tell imgui that in this case releasing the button should not trigger the regular 'left click' event.
so can you think about a way to achieve this 'long-click as right-click" behaviour? (optimally i'd also want ctrl+click to do the same as e.g. when drawing with a desktop+drawing tablet it is again not convenient or impossible with certain pens to right-click but pressing ctrl while clicking is an easy thing to do).
is it possible to put an image in the titlebar of a window? i guess i could make it as a special font character but would be much simpler if i could just add an image at the left of a titlebar.
this leads to a crash (if i comment out one of keys/mouse it still crashes, if i change suspend to resume, it still crashes).
now i've noticed that i use imgui:resetKeysDown() instead of IO:resetKeysDown() and correcting this now it does not crash (also i've changed from suspend to resume, seems more logical).
all in all probably imgui:resetKeysDown() should not run at all and should say that there is no such function, please correct that.
hopefully with this io thing now i have this ALT key issue resolved.
is it possible to put an image in the titlebar of a window? i guess i could make it as a special font character but would be much simpler if i could just add an image at the left of a titlebar.
is it possible to put an image in the titlebar of a window? i guess i could make it as a special font character but would be much simpler if i could just add an image at the left of a titlebar.
DrawList's?
good idea, i will try, with the right offset it should work. if there is no better 'official; solution.
Comments
but the other issue with ALT is still there, namely that when i press ALT and release it then gideros functions often still think that ALT is pressed (e.g. no onKeyUp(event) event seems to be registered for ALT release)
EDIT: actually it seems that consistently every second onKeyUp(event) is noticed for ALT release, perhaps this will help to find the issue.
Fragmenter - animated loop machine and IKONOMIKON - the memory game
https://deluxepixel.com
Strange, I havent touched the fonts code for quite a while...Damn it happened due to code refactoring, I messed up arguments
So, for now you can easily fix it by replacing colon with dot, eg:
Likes: MoKaLux, SinisterSoft
https://deluxepixel.com
I tried ui:scaledImageButtonWithText(texture,text,iconwidth,iconheight,buttonwidth,buttonheight)
The icon height seems to make no difference at all
This resulted in no icon at all (using what I think are the default values for the extra parameters?):
scaledImageButtonWithText(texture,text,iw,ih,bw,bh,0,ImGui.ImageScaleMode_LetterBox,false,0.5,0.5,ImGui.Dir_Left,0xffffff,1,0,0,0,0)
Do you have a code example?
https://deluxepixel.com
imgui:scaledImageButtonWithTextPadded(self.texture, "label", 19, 19, 99, 19, 0, ImGui.ImageScaleMode_LetterBox, false, 0.5,0.5, ImGui.Dir_Left, 0,0,0xffffff, 1,0,0,0, 0)
note the "clip_offset_x = 0, clip_offset_y = 0" part in the docs.
Fragmenter - animated loop machine and IKONOMIKON - the memory game
Fragmenter - animated loop machine and IKONOMIKON - the memory game
addThing({x=23,y=38})
With all missing parameters set to defaults.
https://deluxepixel.com
i think the best is to maintain compatibility with original imgui syntax as much as possible and add extra gideros-unique parameters to the end.
Likes: MoKaLux
Fragmenter - animated loop machine and IKONOMIKON - the memory game
https://deluxepixel.com
Fragmenter - animated loop machine and IKONOMIKON - the memory game
https://github.com/ocornut/imgui/releases/tag/v1.84
You can now disable entire group of widgets by using only 2 functions: beginDisabled(flag), endDisabled()
Likes: MoKaLux, keszegh, SinisterSoft
Fragmenter - animated loop machine and IKONOMIKON - the memory game
https://github.com/sonoro1234/LuaJIT-ImGui
i don't think it is useful for you now but perhaps it's good to know about it if not yet.
Fragmenter - animated loop machine and IKONOMIKON - the memory game
https://deluxepixel.com
Likes: keszegh, SinisterSoft
Fragmenter - animated loop machine and IKONOMIKON - the memory game
https://github.com/ocornut/imgui/issues/1485
This is what happens for me and it seems happens for you too.
The link you've sent should help me? should i do something with isItemHovered? i'm stuck.
thanks for helping
Fragmenter - animated loop machine and IKONOMIKON - the memory game
Text widget does not have ID, so HoverIdTimer does not increment on text.
You can do something like this
Fragmenter - animated loop machine and IKONOMIKON - the memory game
what about the ALT recognition in gideros functions issue?
Fragmenter - animated loop machine and IKONOMIKON - the memory game
i tried making a regular window with no title and menu on and height 0 but it still adds a bit of oversize below.
Fragmenter - animated loop machine and IKONOMIKON - the memory game
how can i trigger something exactly when a popup is closed (for whatever reason, either by user or using closeCurrentPopup()).
Fragmenter - animated loop machine and IKONOMIKON - the memory game
and there is a new one:
my old gui had the ability that whenever a button/gui item could be right-clicked then a long click triggered the same effect. this was practical for android version where on touchscreen there is no natural way to right-click.
whenever i open a context menu with right-click, i guess i could make it react also to long click, but e.g. i don't know how to tell imgui that in this case releasing the button should not trigger the regular 'left click' event.
so can you think about a way to achieve this 'long-click as right-click" behaviour? (optimally i'd also want ctrl+click to do the same as e.g. when drawing with a desktop+drawing tablet it is again not convenient or impossible with certain pens to right-click but pressing ctrl while clicking is an easy thing to do).
thanks
Fragmenter - animated loop machine and IKONOMIKON - the memory game
Fragmenter - animated loop machine and IKONOMIKON - the memory game
all in all probably imgui:resetKeysDown() should not run at all and should say that there is no such function, please correct that.
hopefully with this io thing now i have this ALT key issue resolved.
thanks again
Likes: MoKaLux
Fragmenter - animated loop machine and IKONOMIKON - the memory game
Fragmenter - animated loop machine and IKONOMIKON - the memory game