uilist issues from migration #74341
Describe the bug
Issues left in the code after merging #74341, see it for more info.
-
[x] I cannot see loading individual components when loading a game. It just black-screens me for a while and then the game is loaded.
- This shows for a frame or so
-
[ ] The filter
/is displayed behind the menu, as it is not yet written in ImGui. -
[ ] I would prefer on left mouse click, don't select the selected entry, but the entry under the cursor.
-
It's super annoying when clicking on the CDDA window to focus it and I select an entry instead. While testing a crash, this causes me to restart the game and reload the save.
-
If the mouse is somewhere completely different, it feels weird:
-
-
I think it works correctly in all cases except when you click outside the menu. The mouse click is just translated to the SELECT command regardless of where the user actually clicked, and we need to fix that. Probably not in this patch, however. The problem is in an entirely different part of the code.
-
Attach save file
N/A
Steps to reproduce
issue 1: load a game issues 2 & 3: go into the menu
Expected behavior
- See load screen.
- The Interactible popup window is not behind the ImGui window.
- Clicking works only if the entry is clicked.
Screenshots
No response
Versions and configuration
- OS: Windows
- OS Version: 10.0.19045.4780 (22H2)
- Game Version: 0.G-11377-g54be5797b6-dirty [64-bit]
- Graphics Version: Tiles
- Game Language: English [en]
- Mods loaded: [ Dark Days Ahead [dda], Disable NPC Needs [no_npc_food], Portal Storms Ignore NPCs [personal_portal_storms], Slowdown Fungal Growth [no_fungal_growth] ]
Additional context
No response
someone also posted this in discord
- I can confirm 1. That's really bad when you're forced to use debug builds, since those take an eternity to load.
- I can also confirm 2.
- I don't do mouse stuff, so 3 has to be done by someone else. Since this is a multi issue report and I can't confirm all parts, I can't mark it as confirmed.
I play with slightly increased font size
Window order is a problem - some windows are on top of others making it hard or impossible to read
MA selection is not only on top of list of techniques it also wider than screen, with MA names out of screen
Selecting components for crafting screen looks like this:
When examining appliances list of actions obstructs information
someone also posted this in discord
Yes, this menu could use an improvement. The same goes for the debug menu:
Note: broken on smaller screens:
I might dust off the solution I proposed: get window size from uilist entries and line break all other text.
https://github.com/db48x/Cataclysm-DDA/pull/2/commits/50fa53b9c0bba1ddffd8f6fb8fc6f5c73dc21e28
Mentioned elsewhere but putting here: the new menus do not process color tags, they just render them as text:
Spell menu also no longer shows the name of the current category. This is my Favorites section but it doesn't say so anywhere:
Spell menu also no longer shows the name of the current category.
Did you know that this is the only uilist menu in the entire game that has categories? I am thinking about rewriting it so that it doesn’t use a uilist at all.
I have filed this as a separate bug report.
[…] The same goes for the debug menu:
Yes, that big text at the top really makes it awkward. See https://github.com/CleverRaven/Cataclysm-DDA/issues/75667 for more details.
I might dust off the solution I proposed: get window size from uilist entries and line break all other text.
Try it and see how it looks. If it looks better I’ll take it. However, in this case I bet it makes the window really skinny and wraps the text to unreadability.
Mentioned elsewhere but putting here: the new menus do not process color tags, they just render them as text:
Please be precise when reporting bugs! :D The new menus do clearly support color tags, it’s just that the description field of the Magiclysm spell casting menu ignores them.
The real problem is that our ImGui code doesn’t yet support coloring text if we are also wrapping it into a paragraph. See https://github.com/CleverRaven/Cataclysm-DDA/issues/75669 for more details.
When examining appliances list of actions obstructs information
Nice. The uilist can already be offset, so the caller in this specific case just needs to calculate the correct offset.
Selecting components for crafting screen looks like this:
It looks like any menu with footer text or item descriptions has the same problem: color tags are shown to the user. I filed it separately as https://github.com/CleverRaven/Cataclysm-DDA/issues/75673
Window order is a problem - some windows are on top of others making it hard or impossible to read MA selection is not only on top of list of techniques it also wider than screen, with MA names out of screen
I’ve filed the martial arts menu problem as https://github.com/CleverRaven/Cataclysm-DDA/issues/75674.
I cannot see loading individual components when loading a game. It just black-screens me for a while and then the game is loaded.
Filed separately; https://github.com/CleverRaven/Cataclysm-DDA/issues/75678
The filter
/is displayed behind the menu, as it is not yet written in ImGui.
Filed separately; https://github.com/CleverRaven/Cataclysm-DDA/issues/75676
I would prefer on left mouse click, don't select the selected entry, but the entry under the cursor.
Previously filed as https://github.com/CleverRaven/Cataclysm-DDA/issues/75288
I might dust off the solution I proposed: get window size from uilist entries and line break all other text.
Try it and see how it looks. If it looks better I’ll take it. However, in this case I bet it makes the window really skinny and wraps the text to unreadability.
You might be right. Adding min max height to the caller might fix it, if my solution doesn't work.
I also considered a hard max to the CDDA window size, but entries cannot be broken, so it would affect only the title and description. Wrapping them to the whole width of the window would solve unreadability, but it would still look horrendous.
Pocket settings menu has some weird overlaps, and the submenu renders behind everything else.
It's like it's not completely clearing the old screen first or something. There's an afterimage until it renders another frame.
Pockets settings left list doesn't scroll when the cursor wraps around from bottom to top (or vice versa) until another scroll event happens.
Some cursed triple selection bars if you reverse directions in the middle of the list when using arrow keys.
Pocket settings menu has some weird overlaps, …
What is overlapping in that screenshot? The blue border overlaps with the text, but that’s already a known problem.
That was it, the blue box.
Can't read bottom of firearm mend menu
Examining battery not showing bottom
Thanks, those are both great examples of #75698.
Everything here is addressed or filed separately. Except for this:
Pocket settings menu has some weird overlaps, and the submenu renders behind everything else.
The priority menu is rendered behind the ImGui menu. I will fix this now.
Some cursed triple selection bars if you reverse directions in the middle of the list when using arrow keys.
I did reproduce that before, somehow, but not after #78453
Pockets settings left list doesn't scroll when the cursor wraps around from bottom to top (or vice versa) until another scroll event happens.
I can reproduce this only with PageDown not wrapping to the top. At all. But PageUp does wrap around the top. In uilist, neither wraps.
Home jumps to the last entry, as does End.
But these are for a new issue, this is too cluttered already.


