1996-12-22 19:27:48 +01:00
|
|
|
/*
|
|
|
|
* Metafile GDI mapping mode functions
|
|
|
|
*
|
|
|
|
* Copyright 1996 Alexandre Julliard
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include "gdi.h"
|
|
|
|
#include "metafiledrv.h"
|
|
|
|
|
|
|
|
|
|
|
|
/***********************************************************************
|
|
|
|
* MFDRV_SetMapMode
|
|
|
|
*/
|
1999-02-26 12:11:13 +01:00
|
|
|
INT MFDRV_SetMapMode( DC *dc, INT mode )
|
1996-12-22 19:27:48 +01:00
|
|
|
{
|
2000-11-05 03:05:07 +01:00
|
|
|
INT prevMode = dc->MapMode;
|
1999-04-15 18:46:51 +02:00
|
|
|
MFDRV_MetaParam1( dc, META_SETMAPMODE, mode );
|
1996-12-22 19:27:48 +01:00
|
|
|
return prevMode;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/***********************************************************************
|
|
|
|
* MFDRV_SetViewportExt
|
|
|
|
*/
|
1999-02-26 12:11:13 +01:00
|
|
|
BOOL MFDRV_SetViewportExt( DC *dc, INT x, INT y )
|
1996-12-22 19:27:48 +01:00
|
|
|
{
|
1999-04-15 18:46:51 +02:00
|
|
|
MFDRV_MetaParam2( dc, META_SETVIEWPORTEXT, x, y );
|
1996-12-22 19:27:48 +01:00
|
|
|
return TRUE;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/***********************************************************************
|
|
|
|
* MFDRV_SetViewportOrg
|
|
|
|
*/
|
1999-02-26 12:11:13 +01:00
|
|
|
BOOL MFDRV_SetViewportOrg( DC *dc, INT x, INT y )
|
1996-12-22 19:27:48 +01:00
|
|
|
{
|
1999-04-15 18:46:51 +02:00
|
|
|
MFDRV_MetaParam2( dc, META_SETVIEWPORTORG, x, y );
|
1996-12-22 19:27:48 +01:00
|
|
|
return TRUE;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/***********************************************************************
|
|
|
|
* MFDRV_SetWindowExt
|
|
|
|
*/
|
1999-02-26 12:11:13 +01:00
|
|
|
BOOL MFDRV_SetWindowExt( DC *dc, INT x, INT y )
|
1996-12-22 19:27:48 +01:00
|
|
|
{
|
1999-04-15 18:46:51 +02:00
|
|
|
MFDRV_MetaParam2( dc, META_SETWINDOWEXT, x, y );
|
1996-12-22 19:27:48 +01:00
|
|
|
return TRUE;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/***********************************************************************
|
|
|
|
* MFDRV_SetWindowOrg
|
|
|
|
*/
|
1999-02-26 12:11:13 +01:00
|
|
|
BOOL MFDRV_SetWindowOrg( DC *dc, INT x, INT y )
|
1996-12-22 19:27:48 +01:00
|
|
|
{
|
1999-04-15 18:46:51 +02:00
|
|
|
MFDRV_MetaParam2( dc, META_SETWINDOWORG, x, y );
|
1996-12-22 19:27:48 +01:00
|
|
|
return TRUE;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/***********************************************************************
|
|
|
|
* MFDRV_OffsetViewportOrg
|
|
|
|
*/
|
1999-02-26 12:11:13 +01:00
|
|
|
BOOL MFDRV_OffsetViewportOrg( DC *dc, INT x, INT y )
|
1996-12-22 19:27:48 +01:00
|
|
|
{
|
1999-04-15 18:46:51 +02:00
|
|
|
MFDRV_MetaParam2( dc, META_OFFSETVIEWPORTORG, x, y );
|
1996-12-22 19:27:48 +01:00
|
|
|
return TRUE;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/***********************************************************************
|
|
|
|
* MFDRV_OffsetWindowOrg
|
|
|
|
*/
|
1999-02-26 12:11:13 +01:00
|
|
|
BOOL MFDRV_OffsetWindowOrg( DC *dc, INT x, INT y )
|
1996-12-22 19:27:48 +01:00
|
|
|
{
|
1999-04-15 18:46:51 +02:00
|
|
|
MFDRV_MetaParam2( dc, META_OFFSETWINDOWORG, x, y );
|
1996-12-22 19:27:48 +01:00
|
|
|
return TRUE;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/***********************************************************************
|
|
|
|
* MFDRV_ScaleViewportExt
|
|
|
|
*/
|
1999-02-26 12:11:13 +01:00
|
|
|
BOOL MFDRV_ScaleViewportExt( DC *dc, INT xNum, INT xDenom,
|
|
|
|
INT yNum, INT yDenom )
|
1996-12-22 19:27:48 +01:00
|
|
|
{
|
1999-04-15 18:46:51 +02:00
|
|
|
MFDRV_MetaParam4( dc, META_SCALEVIEWPORTEXT, xNum, xDenom, yNum, yDenom );
|
1996-12-22 19:27:48 +01:00
|
|
|
return TRUE;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/***********************************************************************
|
|
|
|
* MFDRV_ScaleWindowExt
|
|
|
|
*/
|
1999-02-26 12:11:13 +01:00
|
|
|
BOOL MFDRV_ScaleWindowExt( DC *dc, INT xNum, INT xDenom,
|
|
|
|
INT yNum, INT yDenom )
|
1996-12-22 19:27:48 +01:00
|
|
|
{
|
1999-04-15 18:46:51 +02:00
|
|
|
MFDRV_MetaParam4( dc, META_SCALEWINDOWEXT, xNum, xDenom, yNum, yDenom );
|
1996-12-22 19:27:48 +01:00
|
|
|
return TRUE;
|
|
|
|
}
|
1999-04-15 18:46:51 +02:00
|
|
|
|