Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Imgui iteminfo #73456

Merged
merged 2 commits into from
Sep 3, 2024
Merged

Imgui iteminfo #73456

merged 2 commits into from
Sep 3, 2024

Conversation

mqrause
Copy link
Contributor

@mqrause mqrause commented May 2, 2024

Summary

Interface "Add imgui version of the iteminfo window"

Purpose of change

Part of the migration to imgui UIs. I specifically need this for #55503, but it's standalone and used in many other places, too, so it gets a separate PR.

Describe the solution

Add an imgui version of iteminfo, both as a separate window and as separate controls available for embedding in already existing imgui windows.
Use the separate window for examining items in the inventory selector, AIM and crafting menu.

Still have to work out some issues.

  • damage info is slightly broken
  • closing the window by clicking the x doesn't exit the execute method.
  • keyboard scrolling refactor
  • window size in AIM?
  • don't forget to change the window title again

Describe alternatives you've considered

Going further with the migration of this, but I'm mainly doing this for #55503, and this does all I need for that plus some simple examples.

Testing

Examined items in the aforementioned menus.

Additional context

Other menus that display iteminfo, but that need proper migrations to use it:

Examine in inventory:
i

Examine in crafting menu:
jpg

Examine in AIM:
aim

(Examining worn/wielded items still uses the old version since it's different.)

@github-actions github-actions bot added Info / User Interface Game - player communication, menus, etc. Crafting / Construction / Recipes Includes: Uncrafting / Disassembling [C++] Changes (can be) made in C++. Previously named `Code` json-styled JSON lint passed, label assigned by github actions astyled astyled PR, label is assigned by github actions labels May 2, 2024
@NetSysFire NetSysFire added the ImGui Anything related to the new ImGui UI for SDL/tiles or ImTui for curses builds label May 2, 2024
@github-actions github-actions bot added the BasicBuildPassed This PR builds correctly, label assigned by github actions label May 2, 2024
@mqrause mqrause force-pushed the imgui_iteminfo branch 3 times, most recently from 6862caa to 3e1e202 Compare May 2, 2024 14:51
Copy link
Contributor

@db48x db48x left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a couple of small suggestions

src/ui_iteminfo.cpp Outdated Show resolved Hide resolved
src/ui_iteminfo.cpp Outdated Show resolved Hide resolved
src/ui_iteminfo.cpp Outdated Show resolved Hide resolved
src/ui_iteminfo.cpp Show resolved Hide resolved
Copy link
Contributor

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. Please do not bump or comment on this issue unless you are actively working on it. Stale issues, and stale issues that are closed are still considered.

@github-actions github-actions bot added the stale Closed for lack of activity, but still valid. label Jun 12, 2024
@github-actions github-actions bot closed this Jul 12, 2024
@GuardianDll GuardianDll reopened this Aug 26, 2024
@github-actions github-actions bot removed the BasicBuildPassed This PR builds correctly, label assigned by github actions label Aug 26, 2024
@mqrause mqrause marked this pull request as ready for review August 28, 2024 09:04
Copy link
Contributor

@db48x db48x left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Feels great! Just two tiny nits :)

src/ui_iteminfo.cpp Outdated Show resolved Hide resolved
src/ui_iteminfo.cpp Outdated Show resolved Hide resolved
src/ui_iteminfo.cpp Show resolved Hide resolved
@github-actions github-actions bot added the BasicBuildPassed This PR builds correctly, label assigned by github actions label Aug 28, 2024
@Maleclypse Maleclypse merged commit 4f10484 into CleverRaven:master Sep 3, 2024
25 of 26 checks passed
@mqrause mqrause deleted the imgui_iteminfo branch September 3, 2024 06:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions [C++] Changes (can be) made in C++. Previously named `Code` Crafting / Construction / Recipes Includes: Uncrafting / Disassembling ImGui Anything related to the new ImGui UI for SDL/tiles or ImTui for curses builds Info / User Interface Game - player communication, menus, etc. json-styled JSON lint passed, label assigned by github actions stale Closed for lack of activity, but still valid.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants