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

Add text width-adapted CANCEL button, change to StandardWindow for Resolution, Language, Adventure, File and Scenario Info dialogs #8154

Merged
merged 81 commits into from
Jan 5, 2024

Conversation

zenseii
Copy link
Collaborator

@zenseii zenseii commented Dec 20, 2023

This PR makes the single-lined CANCEL button adapt its width according to the text on it.

To make this possible it was necessary to switch to the StandardWindow class for the Language, Resolution, Adventure, File and Scenario Info dialogs. This also gives an evil interface mode for the first two mentioned dialogs plus the Scenario Info dialog.

The Uniform CANCEL button was adapted too and the Player name input dialog's keyboard button had to be moved to allow for that extra button width, since we don't have a way of widening that dialog yet.

The Scenario Info dialog's height was increased by a few pixels to avoid the overlapping of the handicap icons' shadow with the Okay and Cancel buttons.

@zenseii zenseii added improvement New feature, request or improvement ui UI/GUI related stuff labels Dec 20, 2023
@zenseii zenseii added this to the 1.0.11 milestone Dec 20, 2023
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

⚠️ Clang-Tidy found issue(s) with the introduced code (1/1)

src/fheroes2/dialog/dialog_resolution.cpp Outdated Show resolved Hide resolved
@zenseii zenseii changed the title Widen the single-line CANCEL button, Chance to StandardWindow for Resolution and Language dialogs Widen the single-line CANCEL button, Change to StandardWindow for Resolution and Language dialogs Dec 20, 2023
@zenseii zenseii changed the title Widen the single-line CANCEL button, Change to StandardWindow for Resolution and Language dialogs Text width-adapted CANCEL button, change to new window class for Resolution and Language dialogs Dec 21, 2023
@zenseii zenseii changed the title Text width-adapted CANCEL button, change to new window class for Resolution and Language dialogs Text width-adapted CANCEL button, change to new window class for Resolution and Language dialogs and add evil interface for them Dec 21, 2023
@zenseii zenseii changed the title Text width-adapted CANCEL button, change to new window class for Resolution and Language dialogs and add evil interface for them Text width-adapted CANCEL button, change to new window class for Resolution and Language dialogs adding evil interface to them Dec 21, 2023
@zenseii zenseii requested a review from ihhub December 21, 2023 04:38
@zenseii zenseii marked this pull request as ready for review December 21, 2023 04:38
Copy link
Owner

@ihhub ihhub left a comment

Choose a reason for hiding this comment

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

Hi @zenseii , I left several comments here. Would you mind to take a look at them in your spare time?

src/fheroes2/agg/agg_image.cpp Outdated Show resolved Hide resolved
src/fheroes2/agg/agg_image.cpp Outdated Show resolved Hide resolved
src/fheroes2/agg/agg_image.cpp Outdated Show resolved Hide resolved
src/fheroes2/agg/agg_image.cpp Outdated Show resolved Hide resolved
src/fheroes2/agg/agg_image.cpp Outdated Show resolved Hide resolved
@zenseii zenseii requested a review from ihhub January 2, 2024 21:05
Copy link
Collaborator

@Districh-ru Districh-ru left a comment

Choose a reason for hiding this comment

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

Hi, @zenseii, I did a quick overview of PR and left some comments. Could you please check them when you have time.
I'll do a more thorough review tomorrow.

src/fheroes2/agg/agg_image.cpp Outdated Show resolved Hide resolved
src/fheroes2/dialog/dialog_adventure.cpp Show resolved Hide resolved
src/fheroes2/dialog/dialog_adventure.cpp Outdated Show resolved Hide resolved
Add EVIL ICN metallic box. Add disabled button draw call. Remove unnecessary redraws of dialog area outside of event loops.
Copy link
Collaborator

@Districh-ru Districh-ru left a comment

Choose a reason for hiding this comment

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

Hi, @zenseii, I left several comment. Could you please take a look when you have time?

src/fheroes2/dialog/dialog_adventure.cpp Outdated Show resolved Hide resolved
src/fheroes2/dialog/dialog_adventure.cpp Outdated Show resolved Hide resolved
src/fheroes2/dialog/dialog_adventure.cpp Outdated Show resolved Hide resolved
src/fheroes2/dialog/dialog_adventure.cpp Show resolved Hide resolved
src/fheroes2/dialog/dialog_file.cpp Show resolved Hide resolved
src/fheroes2/game/game_scenarioinfo.cpp Show resolved Hide resolved
src/fheroes2/game/game_scenarioinfo.cpp Show resolved Hide resolved
src/fheroes2/game/game_scenarioinfo.cpp Outdated Show resolved Hide resolved
src/fheroes2/game/game_scenarioinfo.cpp Outdated Show resolved Hide resolved
src/fheroes2/game/game_scenarioinfo.cpp Outdated Show resolved Hide resolved
@Districh-ru
Copy link
Collaborator

@zenseii, could you please resolve the merge conflicts.

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

⚠️ Clang-Tidy found issue(s) with the introduced code (1/1)

src/fheroes2/dialog/dialog_adventure.cpp Outdated Show resolved Hide resolved
src/fheroes2/dialog/dialog_adventure.cpp Outdated Show resolved Hide resolved
Copy link
Collaborator

@Districh-ru Districh-ru left a comment

Choose a reason for hiding this comment

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

Well done @zenseii, the GUI gets better and better!

@ihhub ihhub merged commit 5dfd271 into ihhub:master Jan 5, 2024
20 checks passed
@ihhub
Copy link
Owner

ihhub commented Jan 5, 2024

@zenseii , huge thanks for these essential updates!

@zenseii zenseii deleted the wider-cancel-button branch January 5, 2024 13:56
Kazhuu pushed a commit to Kazhuu/fheroes2 that referenced this pull request Jan 31, 2024
…solution, Language, Adventure, File and Scenario Info dialogs (ihhub#8154)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improvement New feature, request or improvement ui UI/GUI related stuff
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants