File diff r24596:eddf98238034 → r24597:afde5721a3b6
src/bridge_gui.cpp
Show inline comments
 
@@ -194,13 +194,13 @@ public:
 
					SetDParam(1, b->speed);
 
					SetDParam(0, b->material);
 
					text_dim = maxdim(text_dim, GetStringBoundingBox(_game_mode == GM_EDITOR ? STR_SELECT_BRIDGE_SCENEDIT_INFO : STR_SELECT_BRIDGE_INFO));
 
				}
 
				sprite_dim.height++; // Sprite is rendered one pixel down in the matrix field.
 
				text_dim.height++; // Allowing the bottom row pixels to be rendered on the edge of the matrix field.
 
				resize->height = max(sprite_dim.height, text_dim.height) + 2; // Max of both sizes + account for matrix edges.
 
				resize->height = std::max(sprite_dim.height, text_dim.height) + 2; // Max of both sizes + account for matrix edges.
 

	
 
				this->bridgetext_offset = WD_MATRIX_LEFT + sprite_dim.width + 1; // Left edge of text, 1 pixel distance from the sprite.
 
				size->width = this->bridgetext_offset + text_dim.width + WD_MATRIX_RIGHT;
 
				size->height = 4 * resize->height; // Smallest bridge gui is 4 entries high in the matrix.
 
				break;
 
			}