Skip to content

fix: pad the tab list around the wordmark - #48

Open
lusu007 wants to merge 1 commit into
mainfrom
fix/tab-list-logo-padding
Open

fix: pad the tab list around the wordmark#48
lusu007 wants to merge 1 commit into
mainfrom
fix/tab-list-logo-padding

Conversation

@lusu007

@lusu007 lusu007 commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

Pull Request

Description

The vanilla tab list sizes its dark box from player rows, not the header, so the Grounds wordmark overflowed on the left and right and sat flush against the names. Stretch each display name to the wordmark width and put space above, below, and beside the glyph.

Type of Change

  • 🐛 Bug fix
  • ✨ New feature
  • 💥 Breaking change
  • ♻️ Refactoring
  • 📚 Documentation
  • 🔧 Chore

Related Issues

Testing

  • Unit tests pass
  • Manual testing completed
  • New tests added for new functionality

Checklist

  • I have performed a self-review of my own code
  • Tests have been added/updated and pass (if needed)
  • Documentation has been updated (if needed)

Made with Cursor

Vanilla sizes the dark box from player rows, not the header, so the logo overflowed short names. Stretch rows to the wordmark width and give the glyph space on every side.

Co-authored-by: Cursor <cursoragent@cursor.com>

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 3490599c3d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

const val LOGO_HEIGHT = 32
const val LOGO_TEXTURE_WIDTH = 256
const val LOGO_TEXTURE_HEIGHT = 52
const val LOGO_ADVANCE = LOGO_TEXTURE_WIDTH * LOGO_HEIGHT / LOGO_TEXTURE_HEIGHT

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Include the bitmap glyph's rounded advance

When a player row is shorter than the logo, this calculates 157 px by truncating 256 * 32 / 52, but Minecraft rounds the scaled bitmap width and adds the bitmap glyph's built-in 1 px advance (the same spacing TabBadge cancels), giving this full-width texture a 159 px advance. Consequently TabName pads rows two pixels narrower than the padded header, so the wordmark can still overhang the row-sized background this change is intended to widen; derive HEADER_WIDTH from the font's actual rounded glyph advance instead.

Useful? React with 👍 / 👎.

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.

1 participant