Skip to content

Add toolbar button for gui/design #1425

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

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

realSquidCoder
Copy link
Contributor

@realSquidCoder realSquidCoder commented Mar 28, 2025

Merge after DFHack/dfhack#5365

Also wait until I can make this use this PR's code library to make it work cleanly

@realSquidCoder realSquidCoder marked this pull request as ready for review March 28, 2025 20:27
@ChrisJohnsen
Copy link
Contributor

If you try a minimum-size DF window (912x552px, 114x46 UI tiles@8x12px), I think you will see that there are only 7 unused-by-DF columns between the left and "center" toolbars. So the sitemap button and this button will not both fit in a minimum size interface area.

Not sure what might be best

  • squash them both in?
    • one would need to overwrite the center toolbar's "left border" (just to the right of the dig button)
    • maybe they could "spread out" when there is enough area, but this might get complicated to manage, especially if more buttons are to be added
  • hide one when there isn't enough space?
  • if one is disabled, should the other "take over" the whole area?
  • move one to the other side of the window where there is more room (14 unused-by-DF columns between center and right toolbars)?

Comment on lines +1648 to +1650
function DesignToolbarOverlay:onInput(keys)
return DesignToolbarOverlay.super.onInput(self, keys)
end
Copy link
Member

Choose a reason for hiding this comment

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

this function is a noop and can be removed

DesignToolbarOverlay = defclass(DesignToolbarOverlay, overlay.OverlayWidget)
DesignToolbarOverlay.ATTRS{
desc='Adds a button to the toolbar at the bottom of the screen for launching gui/design.',
default_pos={x=50, y=-1},
Copy link
Member

@myk002 myk002 Apr 3, 2025

Choose a reason for hiding this comment

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

This position isn't going to work:
image

mayyybe here in the dig toolbar?
image

though that bar is already quite crowded..

another option could be moving the sitemap button over one tile and placing this next to it, but that might also be too crowded. The space next to the sitemap button is there for a reason.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants