MCPcopy Create free account
hub / github.com/OpenTTD/OpenTTD / GetMinLegendWidth

Method GetMinLegendWidth

src/smallmap_gui.cpp:697–700  ·  view source on GitHub ↗

* Compute minimal required width of the legends. * @return Minimally needed width for displaying the smallmap legends in pixels. */

Source from the content-addressed store, hash-verified

695 * @return Minimally needed width for displaying the smallmap legends in pixels.
696 */
697 inline uint GetMinLegendWidth() const
698 {
699 return WidgetDimensions::scaled.framerect.left + this->min_number_of_columns * this->column_width;
700 }
701
702 /**
703 * Return number of columns that can be displayed in \a width pixels.

Callers 1

SetupSmallestSizeMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected