Effective Texture Menu
An EffectiveMenu whose title renders a custom resource-pack texture instead of plain text.
The subclass provides a getTextureGlyph; the menu registers it with the resource pack and builds a title that shifts the cursor by getTitleOffset pixels and then draws the glyph. Positioning is done with space glyphs — Forward shifts right (positive advance), BackSpace shifts left. Override getTitleOffset for a simple shift, or getMenuTitle itself for full control.
Types
Properties
The stable InventoryHolder shared by every inventory this menu opens. Read-only: it can't be replaced, but it is exposed so external code can identify "is this open/closed inventory mine?" via identity — inventory.holder === someMenu.inventoryHolder (every getMenu call builds a fresh Inventory but reuses this same holder).
Functions
Builds a string of space glyphs shifting the cursor by pixels: positive → right (forward), negative → left (back-space), 0 → empty.
Slot indices marked editable by getFreeSlotSymbol in whoOpen's layout, or null if none.
Pattern character marking player-editable slots, or null if the menu is read-only.
Inventory title shown at the top.
Owning plugin and a plugin-unique id; together they form the getNamespacedName.
Unique identity as "<plugin-name>:<id>", lowercased.
Row strings (9 chars each) mapping characters to items via getSymbolsToItems; null for empty.
Explicit inventory size, or null to size automatically from the pattern.
Maps each pattern character to its SlotData (item + click handlers).
The resource-pack glyph rendered as this menu's title texture.
Cursor shift (px) applied before drawing the texture: positive shifts right, negative shifts left. Default -8 reproduces the previous left shift; override to reposition the menu texture.
Players who currently have this menu open.
Called when player closes this menu, before the framework decides what to do with the free-slot items. Read the final inventory state here if you need it (e.g. persist the contents), then return a CloseAction telling the framework how to dispose of the free slots.
Called before a free-slot change is applied. React to it and/or veto it: return SlotChangeResult.CANCEL to block the change (the Bukkit interaction is cancelled, so the item stays put), or SlotChangeResult.ALLOW to let it through. Use it as a slot filter (reject certain items), a read-only guard, or just to persist/update on change.
Opens the menu for whoOpen with contents pre-loaded into the free slots (in getFreeSlots order): the i-th non-null entry is placed into the i-th free slot; extras beyond the free-slot count are ignored.