| 203 | |
| 204 | |
| 205 | void HUDuiServerListCustomTab::resize() { |
| 206 | FontManager& fm = FontManager::instance(); |
| 207 | |
| 208 | float _fontheight = fm.getStringHeight(getFontFace()->getFMFace(), getFontSize()); |
| 209 | |
| 210 | float y = getY() + getHeight() - _fontheight; |
| 211 | |
| 212 | float spacer = fm.getStringWidth(getFontFace()->getFMFace(), getFontSize(), "XXXI"); |
| 213 | |
| 214 | float width = fm.getStringWidth(getFontFace()->getFMFace(), getFontSize(), tabName->getLabel()); |
| 215 | |
| 216 | tabName->setFontFace(getFontFace()); |
| 217 | tabName->setFontSize(getFontSize()); |
| 218 | tabName->setPosition(getX() + width + spacer, y); |
| 219 | |
| 220 | y = y - _fontheight; |
| 221 | |
| 222 | const int faceID = getFontFace()->getFMFace(); |
| 223 | const float fontSize = getFontSize(); |
| 224 | |
| 225 | width = fm.getStringWidth(faceID, fontSize, domainName->getLabel()); |
| 226 | |
| 227 | domainName->setFontFace(getFontFace()); |
| 228 | domainName->setFontSize(fontSize); |
| 229 | domainName->setPosition(getX() + width + spacer, y); |
| 230 | |
| 231 | y = y - _fontheight; |
| 232 | |
| 233 | width = fm.getStringWidth(faceID, fontSize, serverName->getLabel()); |
| 234 | |
| 235 | serverName->setFontFace(getFontFace()); |
| 236 | serverName->setFontSize(fontSize); |
| 237 | serverName->setPosition(getX() + width + spacer, y); |
| 238 | |
| 239 | y = y - _fontheight; |
| 240 | |
| 241 | width = fm.getStringWidth(faceID, fontSize, emptyServer->getLabel()); |
| 242 | |
| 243 | emptyServer->setFontFace(getFontFace()); |
| 244 | emptyServer->setFontSize(fontSize); |
| 245 | emptyServer->setPosition(getX() + width + spacer, y); |
| 246 | |
| 247 | y = y - _fontheight; |
| 248 | |
| 249 | width = fm.getStringWidth(faceID, fontSize, fullServer->getLabel()); |
| 250 | |
| 251 | fullServer->setFontFace(getFontFace()); |
| 252 | fullServer->setFontSize(fontSize); |
| 253 | fullServer->setPosition(getX() + width + spacer, y); |
| 254 | |
| 255 | y = y - _fontheight; |
| 256 | |
| 257 | width = fm.getStringWidth(faceID, fontSize, teamFFAServers->getLabel()); |
| 258 | |
| 259 | teamFFAServers->setFontFace(getFontFace()); |
| 260 | teamFFAServers->setFontSize(fontSize); |
| 261 | teamFFAServers->setPosition(getX() + width + spacer, y); |
| 262 |
nothing calls this directly
no test coverage detected