Quaver
Quaver copied to clipboard
[Wayland] Copying text appends null byte
Describe the bug
Copying notes, copying text from ImGui editor plugins, or using imgui.SetClipboardText
causes an unexpected null byte to be copied alongside the text. This causes dialogs that restrict character inputs to be unable to paste text copied within Quaver.
To Reproduce
- Launch the game on a machine that runs Wayland on Linux.
- Open the editor.
- Copy any hit object.
- Attempt to paste it in the "Go To Objects" dialog. This will fail due to the appended null byte.
Expected behavior
There is no null byte appended to the end of the string in all three scenarios. This extra character can also trip up plugins, as there is now a discrepancy between different operating systems:
local function isWayland()
imgui.SetClipboardText("test")
return imgui.GetClipboardText() ~= "test"
end
Log Files
N/A