Custom background
1. Add this inside the countrygovernmentview window in interface\countrygovernmentview.gui, not in your mechanic’s own .gui file. That window sits 7 px right and 10 px down from the background image’s top-left corner, so the position below is your X minus 7 and Y minus 10.
Copy
2. Custom icon block with the same name. Replace <insert potential> with your own conditions, since this tool can’t tell which reform or mechanic should show it.
Copy
How positions are calculated The game ignores window positions, so every window is at 0,0 and the bar, frame and buttons are placed using their own positions inside it. The game centres the whole stack (Anbennar’s 12 px of dummy buttons, the bar window and the button windows) inside a 122 px tall region that starts at y = 240 in the background image. Taller or shorter windows therefore shift everything. To keep each element where you place it, the tool pads the window heights so the stack is always exactly 122 px: the bar window is 300 x 20 and the button windows are 90 tall when there is a bar, otherwise 110 (a bar on its own gets a 110 tall window). The custom background is placed relative to the whole background image instead, behind everything until you select it. If your mechanic file sorts after anb_dummy_holds.txt, Anbennar’s 12 px of dummy buttons sit above the usable area and the area starts 12 px lower; otherwise they sit below it. The button windows sit in a row below it (or at the top when the bar is under the buttons), each starting where the previous one ends. Measured in-game, the game also centres each button horizontally in its window using the button’s own width, and then adds the button’s position. The tool allows for this, so a window can end up 1 to 2 px wider than the ideal corner-aligned width, which keeps every button exactly where you placed it. Bars and frames are placed without that centring. Window heights are the furthest bottom edge of what is inside. Sizes are the in-game sizes you set, assumed to match your .gfx file.