Skip to content

Comments

Slightly widen top tabs and reduce in-page button widths#166

Merged
plan3t merged 2 commits intomainfrom
codex/fix-ui-scaling-for-factions-mod-k5sg1q
Feb 17, 2026
Merged

Slightly widen top tabs and reduce in-page button widths#166
plan3t merged 2 commits intomainfrom
codex/fix-ui-scaling-for-factions-mod-k5sg1q

Conversation

@plan3t
Copy link
Owner

@plan3t plan3t commented Feb 17, 2026

Motivation

  • The top tab row needed a bit more horizontal space to avoid crowding under Auto GUI scale.
  • Action buttons on individual faction pages were visually wide compared to text fields and could look bulky at some scales.
  • Map and member-area layout needed consistent scaling so controls align across GUI scales and a compact members/invites view was desirable.

Description

  • Rebalanced tab sizing by increasing TAB_BUTTON_WIDTH, MIN_TAB_BUTTON_WIDTH, and TAB_BUTTON_GAP, and by centering using totalTabWidth = tabCount * tabButtonWidth + (tabCount - 1) * TAB_BUTTON_GAP; added compact tab labels via TAB_COMPACT_LABEL_THRESHOLD and FactionTab.getCompactLabel().
  • Added panel scaling fields (panelContentWidth, horizontalScale), position helper panelX(int) and scaledWidth(int) to keep edit boxes scaled consistently and introduced scaledButtonWidth(int) to size buttons slightly smaller than fields.
  • Switched per-page/action buttons (invites, permissions, member actions, rules, relations, bottom actions, and claim/map controls) from scaledWidth(...) to scaledButtonWidth(...) so buttons are narrower while inputs remain full-width.
  • Added members/invites inline toggle UI with membersSectionButton and invitesSectionButton, layout helpers layoutMemberSectionButtons() and updateMemberSectionButtonState(), a MemberSection enum, and refactored visibility handling via setButtonVisible(...) and setEditBoxVisible(...).
  • Tightened map footprint in FactionMapRenderer.buildMapRegion() by reducing max grid margins and lowering cellSize bounds so the map renders smaller and fits better at compact scales.

Testing

  • Ran ./gradlew compileJava and the build completed successfully (BUILD SUCCESSFUL).

Codex Task

@plan3t plan3t merged commit 0344379 into main Feb 17, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant