Replies: 4 comments 3 replies
-
Question 1: is_text_changed() is_text_changed() will return True only in the frame where the text is modified. |
Beta Was this translation helpful? Give feedback.
-
Question 2: color_convert_float4_to_u32 The code below color_floats = [
ImVec4(1.0, 0.0, 0.0, 0.0),
ImVec4(0.0, 1.0, 0.0, 0.0),
ImVec4(0.0, 0.0, 1.0, 0.0),
ImVec4(0.0, 0.0, 0.0, 1.0),
ImVec4(1.0, 0.0, 0.0, 1.0),
]
for color_float in color_floats:
color_int = imgui.color_convert_float4_to_u32(color_float)
print(f"color_float: {color_float} color_int(binary): {color_int:b}") prints
So, this seems to prove that Your issue is perhaps related to a small issue in the Text Editor itself. |
Beta Was this translation helpful? Give feedback.
-
Hi, ImGuiColorTextEdit is already using the version maintained by Santaclose. |
Beta Was this translation helpful? Give feedback.
-
I believe my questions have been satisfactorily answered, so we can consider this matter resolved ^___^ |
Beta Was this translation helpful? Give feedback.
-
Hello,
I am encountering two issues while using ImGui Bundle and would appreciate any guidance or clarification.
System Details:
Question 1:
is_text_changed()
behaviorI am trying to use the
is_text_changed()
method fromimgui_color_text_edit.TextEditor
to detect text modifications. However, the return value does not seem to persist after the text has been modified. Is this a bug, or am I using the method incorrectly?Here is a code snippet illustrating the issue:
Question 2:
color_convert_float4_to_u32()
behaviorI am having trouble with the behavior of
imgui.color_convert_float4_to_u32()
. I expected it to take anImVec4
in RGBA format, but it only seems to work as expected when I pass the colors in ABGR format. Am I missing something here?Here is a code snippet demonstrating the behavior:
With RGBA inputs, the colors do not appear as expected. However, when I swap to ABGR inputs, the colors work correctly. Is this the intended behavior, or am I misunderstanding how this function works?
Working Example
I’ve created a minimal working example where the two questions are marked as QUESTION #1 and QUESTION #2:
Thank you in advance for your help! Any insights or guidance would be greatly appreciated.
Beta Was this translation helpful? Give feedback.
All reactions