зеркало из https://github.com/mozilla/gecko-dev.git
r=mkaply, a=blizzard Following suit - removing italicslope from OS/2
This commit is contained in:
Родитель
24855c4217
Коммит
8061036c56
|
@ -844,13 +844,6 @@ HDC ps = NULL;
|
||||||
|
|
||||||
mAveCharWidth = NSToCoordRound( fm.lAveCharWidth * dev2app);
|
mAveCharWidth = NSToCoordRound( fm.lAveCharWidth * dev2app);
|
||||||
|
|
||||||
#ifdef MOZ_MATHML
|
|
||||||
PRInt32 Degrees = fm.sCharSlope >> 7; // 9 bits (-180 .. 180)
|
|
||||||
PRInt32 Minutes = fm.sCharSlope & 0x7F; // 7 bits (0 .. 59)
|
|
||||||
float Angle = (float)Degrees + ((float)Minutes / 60.0f);
|
|
||||||
mItalicSlope = tanf (Angle * 3.141592 / 180.0);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// Cache the width of a single space.
|
// Cache the width of a single space.
|
||||||
SIZEL size;
|
SIZEL size;
|
||||||
::GetTextExtentPoint32(ps, " ", 1, &size);
|
::GetTextExtentPoint32(ps, " ", 1, &size);
|
||||||
|
@ -872,14 +865,6 @@ nsresult nsFontMetricsOS2::GetSpaceWidth(nscoord &aSpaceWidth)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Other metrics
|
// Other metrics
|
||||||
#ifdef MOZ_MATHML
|
|
||||||
NS_IMETHODIMP nsFontMetricsOS2::GetItalicSlope(float& aResult)
|
|
||||||
{
|
|
||||||
aResult = mItalicSlope;
|
|
||||||
return NS_OK;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
NS_IMETHODIMP nsFontMetricsOS2::GetXHeight( nscoord &aResult)
|
NS_IMETHODIMP nsFontMetricsOS2::GetXHeight( nscoord &aResult)
|
||||||
{
|
{
|
||||||
aResult = mXHeight;
|
aResult = mXHeight;
|
||||||
|
|
|
@ -89,7 +89,6 @@ public:
|
||||||
#ifdef MOZ_MATHML
|
#ifdef MOZ_MATHML
|
||||||
virtual nsresult
|
virtual nsresult
|
||||||
GetBoundingMetrics(HDC aDC,
|
GetBoundingMetrics(HDC aDC,
|
||||||
float aItalicSlope,
|
|
||||||
const PRUnichar* aString,
|
const PRUnichar* aString,
|
||||||
PRUint32 aLength,
|
PRUint32 aLength,
|
||||||
nsBoundingMetrics& aBoundingMetrics) = 0;
|
nsBoundingMetrics& aBoundingMetrics) = 0;
|
||||||
|
@ -130,9 +129,6 @@ class nsFontMetricsOS2 : public nsIFontMetrics
|
||||||
NS_IMETHOD Destroy();
|
NS_IMETHOD Destroy();
|
||||||
|
|
||||||
// Metrics
|
// Metrics
|
||||||
#ifdef MOZ_MATHML
|
|
||||||
NS_IMETHOD GetItalicSlope(float& aResult);
|
|
||||||
#endif
|
|
||||||
NS_IMETHOD GetXHeight( nscoord &aResult);
|
NS_IMETHOD GetXHeight( nscoord &aResult);
|
||||||
NS_IMETHOD GetSuperscriptOffset( nscoord &aResult);
|
NS_IMETHOD GetSuperscriptOffset( nscoord &aResult);
|
||||||
NS_IMETHOD GetSubscriptOffset( nscoord &aResult);
|
NS_IMETHOD GetSubscriptOffset( nscoord &aResult);
|
||||||
|
@ -192,9 +188,6 @@ class nsFontMetricsOS2 : public nsIFontMetrics
|
||||||
nscoord mSpaceWidth;
|
nscoord mSpaceWidth;
|
||||||
nscoord mXHeight;
|
nscoord mXHeight;
|
||||||
nscoord mAveCharWidth;
|
nscoord mAveCharWidth;
|
||||||
#ifdef MOZ_MATHML
|
|
||||||
float mItalicSlope;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
nsFontHandleOS2 *mFontHandle;
|
nsFontHandleOS2 *mFontHandle;
|
||||||
nsDeviceContextOS2 *mDeviceContext;
|
nsDeviceContextOS2 *mDeviceContext;
|
||||||
|
|
Загрузка…
Ссылка в новой задаче