CNeutrinoFonts: reduce debug spam

In some cases with many following dynamic size changes,
it could be better to suppress this output.


Origin commit data
------------------
Branch: ni/coolstream
Commit: 96e05c69dc
Author: Thilo Graf <dbt@novatux.de>
Date: 2017-03-19 (Sun, 19 Mar 2017)

Origin message was:
------------------
CNeutrinoFonts: reduce debug spam

In some cases with many following dynamic size changes,
it could be better to suppress this output.


------------------
This commit was generated by Migit
This commit is contained in:
2017-03-19 22:15:36 +01:00
parent c40ccb5ff3
commit 8d67cc08b7

View File

@@ -269,10 +269,12 @@ int CNeutrinoFonts::getDynFontSize(int dx, int dy, std::string text, int style)
if (text.empty()) tmpText = "x";
_width = dynFont->getRenderWidth(tmpText);
if ((_height > dy) || (_width > dx)) {
if (dynFlag)
if (dynFlag){
dynSize--;
else
printf("##### [%s] Specified size (dx=%d, dy=%d) too small, use minimal font size.\n", __FUNCTION__, dx, dy);
}else{
if (debug)
printf("##### [%s] Specified size (dx=%d, dy=%d) too small, use minimal font size.\n", __FUNCTION__, dx, dy);
}
break;
}
else if ((_height < dy) || (_width < dx)) {