зеркало из https://github.com/mozilla/pjs.git
Bug #180721. floating point error when visiting web page. Paper over the fact that the style system is passing is a pixel size of 0. Not part of the default build.
This commit is contained in:
Родитель
739b4d4f2f
Коммит
49e3a77960
|
@ -272,6 +272,15 @@ nsFontMetricsXft::Init(const nsFont& aFont, nsIAtom* aLangGroup,
|
|||
mPointSize = minimum;
|
||||
}
|
||||
|
||||
// Make sure that the point size is at least greater than zero
|
||||
if (mPointSize < 1) {
|
||||
#ifdef DEBUG
|
||||
printf("*** Warning: nsFontMetricsXft was passed a point size of %d\n",
|
||||
mPointSize);
|
||||
#endif
|
||||
mPointSize = 1;
|
||||
}
|
||||
|
||||
if (NS_FAILED(RealizeFont()))
|
||||
return NS_ERROR_FAILURE;
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче