blob: 4d89005d610a907cae7324b1136592cf51ccd66f [file] [log] [blame]
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +00001/*
2 * Metafile GDI mapping mode functions
3 *
4 * Copyright 1996 Alexandre Julliard
5 */
6
7#include "gdi.h"
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +00008#include "metafiledrv.h"
9
10
11/***********************************************************************
12 * MFDRV_SetMapMode
13 */
Alexandre Julliarda3960291999-02-26 11:11:13 +000014INT MFDRV_SetMapMode( DC *dc, INT mode )
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +000015{
Alexandre Julliard2239abb2000-11-05 02:05:07 +000016 INT prevMode = dc->MapMode;
Huw D M Daviesb94e4331999-04-15 16:46:51 +000017 MFDRV_MetaParam1( dc, META_SETMAPMODE, mode );
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +000018 return prevMode;
19}
20
21
22/***********************************************************************
23 * MFDRV_SetViewportExt
24 */
Alexandre Julliarda3960291999-02-26 11:11:13 +000025BOOL MFDRV_SetViewportExt( DC *dc, INT x, INT y )
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +000026{
Huw D M Daviesb94e4331999-04-15 16:46:51 +000027 MFDRV_MetaParam2( dc, META_SETVIEWPORTEXT, x, y );
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +000028 return TRUE;
29}
30
31
32/***********************************************************************
33 * MFDRV_SetViewportOrg
34 */
Alexandre Julliarda3960291999-02-26 11:11:13 +000035BOOL MFDRV_SetViewportOrg( DC *dc, INT x, INT y )
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +000036{
Huw D M Daviesb94e4331999-04-15 16:46:51 +000037 MFDRV_MetaParam2( dc, META_SETVIEWPORTORG, x, y );
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +000038 return TRUE;
39}
40
41
42/***********************************************************************
43 * MFDRV_SetWindowExt
44 */
Alexandre Julliarda3960291999-02-26 11:11:13 +000045BOOL MFDRV_SetWindowExt( DC *dc, INT x, INT y )
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +000046{
Huw D M Daviesb94e4331999-04-15 16:46:51 +000047 MFDRV_MetaParam2( dc, META_SETWINDOWEXT, x, y );
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +000048 return TRUE;
49}
50
51
52/***********************************************************************
53 * MFDRV_SetWindowOrg
54 */
Alexandre Julliarda3960291999-02-26 11:11:13 +000055BOOL MFDRV_SetWindowOrg( DC *dc, INT x, INT y )
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +000056{
Huw D M Daviesb94e4331999-04-15 16:46:51 +000057 MFDRV_MetaParam2( dc, META_SETWINDOWORG, x, y );
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +000058 return TRUE;
59}
60
61
62/***********************************************************************
63 * MFDRV_OffsetViewportOrg
64 */
Alexandre Julliarda3960291999-02-26 11:11:13 +000065BOOL MFDRV_OffsetViewportOrg( DC *dc, INT x, INT y )
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +000066{
Huw D M Daviesb94e4331999-04-15 16:46:51 +000067 MFDRV_MetaParam2( dc, META_OFFSETVIEWPORTORG, x, y );
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +000068 return TRUE;
69}
70
71
72/***********************************************************************
73 * MFDRV_OffsetWindowOrg
74 */
Alexandre Julliarda3960291999-02-26 11:11:13 +000075BOOL MFDRV_OffsetWindowOrg( DC *dc, INT x, INT y )
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +000076{
Huw D M Daviesb94e4331999-04-15 16:46:51 +000077 MFDRV_MetaParam2( dc, META_OFFSETWINDOWORG, x, y );
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +000078 return TRUE;
79}
80
81
82/***********************************************************************
83 * MFDRV_ScaleViewportExt
84 */
Alexandre Julliarda3960291999-02-26 11:11:13 +000085BOOL MFDRV_ScaleViewportExt( DC *dc, INT xNum, INT xDenom,
86 INT yNum, INT yDenom )
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +000087{
Huw D M Daviesb94e4331999-04-15 16:46:51 +000088 MFDRV_MetaParam4( dc, META_SCALEVIEWPORTEXT, xNum, xDenom, yNum, yDenom );
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +000089 return TRUE;
90}
91
92
93/***********************************************************************
94 * MFDRV_ScaleWindowExt
95 */
Alexandre Julliarda3960291999-02-26 11:11:13 +000096BOOL MFDRV_ScaleWindowExt( DC *dc, INT xNum, INT xDenom,
97 INT yNum, INT yDenom )
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +000098{
Huw D M Daviesb94e4331999-04-15 16:46:51 +000099 MFDRV_MetaParam4( dc, META_SCALEWINDOWEXT, xNum, xDenom, yNum, yDenom );
Alexandre Julliard7ebe1a41996-12-22 18:27:48 +0000100 return TRUE;
101}
Huw D M Daviesb94e4331999-04-15 16:46:51 +0000102