missing paint device metrics added
This commit is contained in:
parent
be16e74336
commit
b0cbb4f9e4
@ -430,7 +430,7 @@ QPaintEngine* QskGraphic::paintEngine() const
|
|||||||
|
|
||||||
int QskGraphic::metric( PaintDeviceMetric deviceMetric ) const
|
int QskGraphic::metric( PaintDeviceMetric deviceMetric ) const
|
||||||
{
|
{
|
||||||
int value;
|
int value = 0;
|
||||||
|
|
||||||
switch ( deviceMetric )
|
switch ( deviceMetric )
|
||||||
{
|
{
|
||||||
@ -472,9 +472,18 @@ int QskGraphic::metric( PaintDeviceMetric deviceMetric ) const
|
|||||||
value = qRound( metric( PdmHeight ) * 25.4 / metric( PdmDpiY ) );
|
value = qRound( metric( PdmHeight ) * 25.4 / metric( PdmDpiY ) );
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
default:
|
case PdmDevicePixelRatio:
|
||||||
value = 0;
|
{
|
||||||
|
value = 1.0;
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
case PdmDevicePixelRatioScaled:
|
||||||
|
{
|
||||||
|
value = metric( PdmDevicePixelRatio ) * devicePixelRatioFScale();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return value;
|
return value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user