2011-07-01 00:17:55 +04:00
|
|
|
/**
|
2012-10-09 07:02:04 +04:00
|
|
|
* FreeRDP: A Remote Desktop Protocol Implementation
|
2011-07-01 00:17:55 +04:00
|
|
|
* GDI Brush Functions
|
|
|
|
*
|
|
|
|
* Copyright 2010-2011 Marc-Andre Moreau <marcandre.moreau@gmail.com>
|
2016-04-05 18:07:45 +03:00
|
|
|
* Copyright 2016 Armin Novak <armin.novak@thincast.com>
|
|
|
|
* Copyright 2016 Thincast Technologies GmbH
|
2011-07-01 00:17:55 +04:00
|
|
|
*
|
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
* you may not use this file except in compliance with the License.
|
|
|
|
* You may obtain a copy of the License at
|
|
|
|
*
|
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
*
|
|
|
|
* Unless required by applicable law or agreed to in writing, software
|
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
* See the License for the specific language governing permissions and
|
|
|
|
* limitations under the License.
|
|
|
|
*/
|
|
|
|
|
|
|
|
/* GDI Brush Functions: http://msdn.microsoft.com/en-us/library/dd183395/ */
|
|
|
|
|
2012-08-15 01:09:01 +04:00
|
|
|
#ifdef HAVE_CONFIG_H
|
|
|
|
#include "config.h"
|
|
|
|
#endif
|
|
|
|
|
2011-07-01 00:17:55 +04:00
|
|
|
#include <stdio.h>
|
|
|
|
#include <stdlib.h>
|
|
|
|
|
|
|
|
#include <freerdp/freerdp.h>
|
2011-08-15 22:33:04 +04:00
|
|
|
#include <freerdp/gdi/gdi.h>
|
2016-04-05 18:07:45 +03:00
|
|
|
#include <freerdp/gdi/region.h>
|
|
|
|
#include <freerdp/log.h>
|
2011-07-01 00:17:55 +04:00
|
|
|
|
2016-08-11 14:40:22 +03:00
|
|
|
#include "brush.h"
|
2016-04-05 18:07:45 +03:00
|
|
|
#include "clipping.h"
|
2011-07-01 00:17:55 +04:00
|
|
|
|
2016-04-05 18:07:45 +03:00
|
|
|
#define TAG FREERDP_TAG("gdi.brush")
|
2011-07-01 00:17:55 +04:00
|
|
|
|
2016-07-13 18:33:23 +03:00
|
|
|
const char* gdi_rop_to_string(UINT32 code)
|
|
|
|
{
|
|
|
|
switch (code)
|
|
|
|
{
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_BLACKNESS:
|
|
|
|
return "0";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSoon:
|
|
|
|
return "DPSoon";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSona:
|
|
|
|
return "DPSona";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PSon:
|
|
|
|
return "PSon";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPona:
|
|
|
|
return "SDPona";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPon:
|
|
|
|
return "DPon";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSxnon:
|
|
|
|
return "PDSxnon";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSaon:
|
|
|
|
return "PDSaon";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPnaa:
|
|
|
|
return "SDPnaa";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSxon:
|
|
|
|
return "PDSxon";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPna:
|
|
|
|
return "DPna";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PSDnaon:
|
|
|
|
return "PSDnaon";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPna:
|
|
|
|
return "SPna";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSnaon:
|
|
|
|
return "PDSnaon";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSonon:
|
|
|
|
return "PDSonon";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_Pn:
|
|
|
|
return "Pn";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSona:
|
|
|
|
return "PDSona";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_NOTSRCERASE:
|
|
|
|
return "DSon";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPxnon:
|
|
|
|
return "SDPxnon";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPaon:
|
|
|
|
return "SDPaon";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSxnon:
|
|
|
|
return "DPSxnon";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSaon:
|
|
|
|
return "DPSaon";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PSDPSanaxx:
|
|
|
|
return "PSDPSanaxx";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SSPxDSxaxn:
|
|
|
|
return "SSPxDSxaxn";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPxPDxa:
|
|
|
|
return "SPxPDxa";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPSanaxn:
|
|
|
|
return "SDPSanaxn";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSPaox:
|
|
|
|
return "PDSPaox";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPSxaxn:
|
|
|
|
return "SDPSxaxn";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PSDPaox:
|
|
|
|
return "PSDPaox";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DSPDxaxn:
|
|
|
|
return "DSPDxaxn";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSox:
|
|
|
|
return "PDSox";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSoan:
|
|
|
|
return "PDSoan";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSnaa:
|
|
|
|
return "DPSnaa";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPxon:
|
|
|
|
return "SDPxon";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
|
|
|
case GDI_DSna:
|
2016-08-05 20:38:46 +03:00
|
|
|
return "DSna";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPDnaon:
|
|
|
|
return "SPDnaon";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPxDSxa:
|
|
|
|
return "SPxDSxa";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSPanaxn:
|
|
|
|
return "PDSPanaxn";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPSaox:
|
|
|
|
return "SDPSaox";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPSxnox:
|
|
|
|
return "SDPSxnox";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSxa:
|
|
|
|
return "DPSxa";
|
|
|
|
|
|
|
|
case GDI_PSDPSaoxxn:
|
|
|
|
return "PSDPSaoxxn";
|
|
|
|
|
|
|
|
case GDI_DPSana:
|
|
|
|
return "DPSana";
|
|
|
|
|
|
|
|
case GDI_SSPxPDxaxn:
|
|
|
|
return "SSPxPDxaxn";
|
|
|
|
|
|
|
|
case GDI_SPDSoax:
|
|
|
|
return "SPDSoax";
|
|
|
|
|
|
|
|
case GDI_PSDnox:
|
|
|
|
return "PSDnox";
|
2016-08-03 12:31:42 +03:00
|
|
|
|
|
|
|
case GDI_PSDPxox:
|
2016-08-05 20:38:46 +03:00
|
|
|
return "PSDPxox";
|
2016-08-03 12:31:42 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PSDnoan:
|
|
|
|
return "PSDnoan";
|
2016-08-03 12:31:42 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PSna:
|
|
|
|
return "PSna";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPnaon:
|
|
|
|
return "SDPnaon";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPSoox:
|
|
|
|
return "SDPSoox";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_NOTSRCCOPY:
|
|
|
|
return "Sn";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPDSaox:
|
|
|
|
return "SPDSaox";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPDSxnox:
|
|
|
|
return "SPDSxnox";
|
|
|
|
|
|
|
|
case GDI_SDPox:
|
|
|
|
return "SDPox";
|
|
|
|
|
|
|
|
case GDI_SDPoan:
|
|
|
|
return "SDPoan";
|
|
|
|
|
|
|
|
case GDI_PSDPoax:
|
|
|
|
return "PSDPoax";
|
|
|
|
|
|
|
|
case GDI_SPDnox:
|
|
|
|
return "SPDnox";
|
|
|
|
|
|
|
|
case GDI_SPDSxox:
|
|
|
|
return "SPDSxox";
|
|
|
|
|
|
|
|
case GDI_SPDnoan:
|
|
|
|
return "SPDnoan";
|
|
|
|
|
|
|
|
case GDI_PSx:
|
|
|
|
return "PSx";
|
|
|
|
|
|
|
|
case GDI_SPDSonox:
|
|
|
|
return "SPDSonox";
|
|
|
|
|
|
|
|
case GDI_SPDSnaox:
|
|
|
|
return "SPDSnaox";
|
|
|
|
|
|
|
|
case GDI_PSan:
|
|
|
|
return "PSan";
|
|
|
|
|
|
|
|
case GDI_PSDnaa:
|
|
|
|
return "PSDnaa";
|
|
|
|
|
|
|
|
case GDI_DPSxon:
|
|
|
|
return "DPSxon";
|
|
|
|
|
|
|
|
case GDI_SDxPDxa:
|
|
|
|
return "SDxPDxa";
|
|
|
|
|
|
|
|
case GDI_SPDSanaxn:
|
|
|
|
return "SPDSanaxn";
|
|
|
|
|
|
|
|
case GDI_SRCERASE:
|
|
|
|
return "SDna";
|
|
|
|
|
|
|
|
case GDI_DPSnaon:
|
|
|
|
return "DPSnaon";
|
|
|
|
|
|
|
|
case GDI_DSPDaox:
|
|
|
|
return "DSPDaox";
|
|
|
|
|
|
|
|
case GDI_PSDPxaxn:
|
|
|
|
return "PSDPxaxn";
|
|
|
|
|
|
|
|
case GDI_SDPxa:
|
|
|
|
return "SDPxa";
|
|
|
|
|
|
|
|
case GDI_PDSPDaoxxn:
|
|
|
|
return "PDSPDaoxxn";
|
|
|
|
|
|
|
|
case GDI_DPSDoax:
|
|
|
|
return "DPSDoax";
|
|
|
|
|
|
|
|
case GDI_PDSnox:
|
|
|
|
return "PDSnox";
|
|
|
|
|
|
|
|
case GDI_SDPana:
|
|
|
|
return "SDPana";
|
|
|
|
|
|
|
|
case GDI_SSPxDSxoxn:
|
|
|
|
return "SSPxDSxoxn";
|
|
|
|
|
|
|
|
case GDI_PDSPxox:
|
|
|
|
return "PDSPxox";
|
|
|
|
|
|
|
|
case GDI_PDSnoan:
|
|
|
|
return "PDSnoan";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
|
|
|
case GDI_PDna:
|
2016-08-05 20:38:46 +03:00
|
|
|
return "PDna";
|
|
|
|
|
|
|
|
case GDI_DSPnaon:
|
|
|
|
return "DSPnaon";
|
|
|
|
|
|
|
|
case GDI_DPSDaox:
|
|
|
|
return "DPSDaox";
|
|
|
|
|
|
|
|
case GDI_SPDSxaxn:
|
|
|
|
return "SPDSxaxn";
|
|
|
|
|
|
|
|
case GDI_DPSonon:
|
|
|
|
return "DPSonon";
|
|
|
|
|
|
|
|
case GDI_DSTINVERT:
|
|
|
|
return "Dn";
|
|
|
|
|
|
|
|
case GDI_DPSox:
|
|
|
|
return "DPSox";
|
|
|
|
|
|
|
|
case GDI_DPSoan:
|
|
|
|
return "DPSoan";
|
|
|
|
|
|
|
|
case GDI_PDSPoax:
|
|
|
|
return "PDSPoax";
|
|
|
|
|
|
|
|
case GDI_DPSnox:
|
|
|
|
return "DPSnox";
|
|
|
|
|
|
|
|
case GDI_PATINVERT:
|
|
|
|
return "DPx";
|
|
|
|
|
|
|
|
case GDI_DPSDonox:
|
|
|
|
return "DPSDonox";
|
|
|
|
|
|
|
|
case GDI_DPSDxox:
|
|
|
|
return "DPSDxox";
|
|
|
|
|
|
|
|
case GDI_DPSnoan:
|
|
|
|
return "DPSnoan";
|
|
|
|
|
|
|
|
case GDI_DPSDnaox:
|
|
|
|
return "DPSDnaox";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
|
|
|
case GDI_DPan:
|
2016-08-05 20:38:46 +03:00
|
|
|
return "DPan";
|
|
|
|
|
|
|
|
case GDI_PDSxa:
|
|
|
|
return "PDSxa";
|
|
|
|
|
|
|
|
case GDI_DSPDSaoxxn:
|
|
|
|
return "DSPDSaoxxn";
|
|
|
|
|
|
|
|
case GDI_DSPDoax:
|
|
|
|
return "DSPDoax";
|
|
|
|
|
|
|
|
case GDI_SDPnox:
|
|
|
|
return "SDPnox";
|
|
|
|
|
|
|
|
case GDI_SDPSoax:
|
|
|
|
return "SDPSoax";
|
|
|
|
|
|
|
|
case GDI_DSPnox:
|
|
|
|
return "DSPnox";
|
|
|
|
|
|
|
|
case GDI_SRCINVERT:
|
|
|
|
return "DSx";
|
|
|
|
|
|
|
|
case GDI_SDPSonox:
|
|
|
|
return "SDPSonox";
|
|
|
|
|
|
|
|
case GDI_DSPDSonoxxn:
|
|
|
|
return "DSPDSonoxxn";
|
|
|
|
|
|
|
|
case GDI_PDSxxn:
|
|
|
|
return "PDSxxn";
|
|
|
|
|
|
|
|
case GDI_DPSax:
|
|
|
|
return "DPSax";
|
|
|
|
|
|
|
|
case GDI_PSDPSoaxxn:
|
|
|
|
return "PSDPSoaxxn";
|
|
|
|
|
|
|
|
case GDI_SDPax:
|
|
|
|
return "SDPax";
|
|
|
|
|
|
|
|
case GDI_PDSPDoaxxn:
|
|
|
|
return "PDSPDoaxxn";
|
|
|
|
|
|
|
|
case GDI_SDPSnoax:
|
|
|
|
return "SDPSnoax";
|
|
|
|
|
|
|
|
case GDI_PDSxnan:
|
|
|
|
return "PDSxnan";
|
|
|
|
|
|
|
|
case GDI_PDSana:
|
|
|
|
return "PDSana";
|
|
|
|
|
|
|
|
case GDI_SSDxPDxaxn:
|
|
|
|
return "SSDxPDxaxn";
|
|
|
|
|
|
|
|
case GDI_SDPSxox:
|
|
|
|
return "SDPSxox";
|
|
|
|
|
|
|
|
case GDI_SDPnoan:
|
|
|
|
return "SDPnoan";
|
|
|
|
|
|
|
|
case GDI_DSPDxox:
|
|
|
|
return "DSPDxox";
|
|
|
|
|
|
|
|
case GDI_DSPnoan:
|
|
|
|
return "DSPnoan";
|
|
|
|
|
|
|
|
case GDI_SDPSnaox:
|
|
|
|
return "SDPSnaox";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
|
|
|
case GDI_DSan:
|
2016-08-05 20:38:46 +03:00
|
|
|
return "DSan";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSax:
|
|
|
|
return "PDSax";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DSPDSoaxxn:
|
|
|
|
return "DSPDSoaxxn";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSDnoax:
|
|
|
|
return "DPSDnoax";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPxnan:
|
|
|
|
return "SDPxnan";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPDSnoax:
|
|
|
|
return "SPDSnoax";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSxnan:
|
|
|
|
return "DPSxnan";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPxDSxo:
|
|
|
|
return "SPxDSxo";
|
2016-07-13 18:33:23 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSaan:
|
|
|
|
return "DPSaan";
|
2011-07-01 00:17:55 +04:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSaa:
|
|
|
|
return "DPSaa";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPxDSxon:
|
|
|
|
return "SPxDSxon";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSxna:
|
|
|
|
return "DPSxna";
|
2011-07-01 00:17:55 +04:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPDSnoaxn:
|
|
|
|
return "SPDSnoaxn";
|
2011-07-01 00:17:55 +04:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPxna:
|
|
|
|
return "SDPxna";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSPnoaxn:
|
|
|
|
return "PDSPnoaxn";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DSPDSoaxx:
|
|
|
|
return "DSPDSoaxx";
|
2011-07-01 00:17:55 +04:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSaxn:
|
|
|
|
return "PDSaxn";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SRCAND:
|
|
|
|
return "DSa";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPSnaoxn:
|
|
|
|
return "SDPSnaoxn";
|
2013-02-04 18:58:22 +04:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DSPnoa:
|
|
|
|
return "DSPnoa";
|
2016-08-02 09:43:26 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DSPDxoxn:
|
|
|
|
return "DSPDxoxn";
|
2016-08-02 09:43:26 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPnoa:
|
|
|
|
return "SDPnoa";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPSxoxn:
|
|
|
|
return "SDPSxoxn";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SSDxPDxax:
|
|
|
|
return "SSDxPDxax";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSanan:
|
|
|
|
return "PDSanan";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSxna:
|
|
|
|
return "PDSxna";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPSnoaxn:
|
|
|
|
return "SDPSnoaxn";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSDPoaxx:
|
|
|
|
return "DPSDPoaxx";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPDaxn:
|
|
|
|
return "SPDaxn";
|
2016-08-02 09:43:26 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PSDPSoaxx:
|
|
|
|
return "PSDPSoaxx";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSaxn:
|
|
|
|
return "DPSaxn";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSxx:
|
|
|
|
return "DPSxx";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PSDPSonoxx:
|
|
|
|
return "PSDPSonoxx";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPSonoxn:
|
|
|
|
return "SDPSonoxn";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DSxn:
|
|
|
|
return "DSxn";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSnax:
|
|
|
|
return "DPSnax";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPSoaxn:
|
|
|
|
return "SDPSoaxn";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPDnax:
|
|
|
|
return "SPDnax";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DSPDoaxn:
|
|
|
|
return "DSPDoaxn";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DSPDSaoxx:
|
|
|
|
return "DSPDSaoxx";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSxan:
|
|
|
|
return "PDSxan";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPa:
|
|
|
|
return "DPa";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSPnaoxn:
|
|
|
|
return "PDSPnaoxn";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSnoa:
|
|
|
|
return "DPSnoa";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSDxoxn:
|
|
|
|
return "DPSDxoxn";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSPonoxn:
|
|
|
|
return "PDSPonoxn";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDxn:
|
|
|
|
return "PDxn";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DSPnax:
|
|
|
|
return "DSPnax";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSPoaxn:
|
|
|
|
return "PDSPoaxn";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSoa:
|
|
|
|
return "DPSoa";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSoxn:
|
|
|
|
return "DPSoxn";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DSTCOPY:
|
|
|
|
return "D";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSono:
|
|
|
|
return "DPSono";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPDSxax:
|
|
|
|
return "SPDSxax";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSDaoxn:
|
|
|
|
return "DPSDaoxn";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DSPnao:
|
|
|
|
return "DSPnao";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPno:
|
|
|
|
return "DPno";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSnoa:
|
|
|
|
return "PDSnoa";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PDSPxoxn:
|
|
|
|
return "PDSPxoxn";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SSPxDSxox:
|
|
|
|
return "SSPxDSxox";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPanan:
|
|
|
|
return "SDPanan";
|
2011-07-01 00:17:55 +04:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PSDnax:
|
|
|
|
return "PSDnax";
|
2011-07-01 00:17:55 +04:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSDoaxn:
|
|
|
|
return "DPSDoaxn";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSDPaoxx:
|
|
|
|
return "DPSDPaoxx";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPxan:
|
|
|
|
return "SDPxan";
|
2016-08-02 09:43:26 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PSDPxax:
|
|
|
|
return "PSDPxax";
|
2016-08-02 09:43:26 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DSPDaoxn:
|
|
|
|
return "DSPDaoxn";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSnao:
|
|
|
|
return "DPSnao";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_MERGEPAINT:
|
|
|
|
return "DSno";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPDSanax:
|
|
|
|
return "SPDSanax";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDxPDxan:
|
|
|
|
return "SDxPDxan";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSxo:
|
|
|
|
return "DPSxo";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_DPSano:
|
|
|
|
return "DPSano";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_MERGECOPY:
|
|
|
|
return "PSa";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPDSnaoxn:
|
|
|
|
return "SPDSnaoxn";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPDSonoxn:
|
|
|
|
return "SPDSonoxn";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PSxn:
|
|
|
|
return "PSxn";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPDnoa:
|
|
|
|
return "SPDnoa";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPDSxoxn:
|
|
|
|
return "SPDSxoxn";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPnax:
|
|
|
|
return "SDPnax";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_PSDPoaxn:
|
|
|
|
return "PSDPoaxn";
|
2016-07-18 18:45:30 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SDPoa:
|
|
|
|
return "SDPoa";
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_SPDoxn:
|
|
|
|
return "SPDoxn";
|
|
|
|
|
|
|
|
case GDI_DPSDxax:
|
|
|
|
return "DPSDxax";
|
|
|
|
|
|
|
|
case GDI_SPDSaoxn:
|
|
|
|
return "SPDSaoxn";
|
|
|
|
|
|
|
|
case GDI_SRCCOPY:
|
|
|
|
return "S";
|
|
|
|
|
|
|
|
case GDI_SDPono:
|
|
|
|
return "SDPono";
|
|
|
|
|
|
|
|
case GDI_SDPnao:
|
|
|
|
return "SDPnao";
|
|
|
|
|
|
|
|
case GDI_SPno:
|
|
|
|
return "SPno";
|
|
|
|
|
|
|
|
case GDI_PSDnoa:
|
|
|
|
return "PSDnoa";
|
|
|
|
|
|
|
|
case GDI_PSDPxoxn:
|
|
|
|
return "PSDPxoxn";
|
|
|
|
|
|
|
|
case GDI_PDSnax:
|
|
|
|
return "PDSnax";
|
|
|
|
|
|
|
|
case GDI_SPDSoaxn:
|
|
|
|
return "SPDSoaxn";
|
|
|
|
|
|
|
|
case GDI_SSPxPDxax:
|
|
|
|
return "SSPxPDxax";
|
|
|
|
|
|
|
|
case GDI_DPSanan:
|
|
|
|
return "DPSanan";
|
|
|
|
|
|
|
|
case GDI_PSDPSaoxx:
|
|
|
|
return "PSDPSaoxx";
|
|
|
|
|
|
|
|
case GDI_DPSxan:
|
|
|
|
return "DPSxan";
|
|
|
|
|
|
|
|
case GDI_PDSPxax:
|
|
|
|
return "PDSPxax";
|
|
|
|
|
|
|
|
case GDI_SDPSaoxn:
|
|
|
|
return "SDPSaoxn";
|
|
|
|
|
|
|
|
case GDI_DPSDanax:
|
|
|
|
return "DPSDanax";
|
|
|
|
|
|
|
|
case GDI_SPxDSxan:
|
|
|
|
return "SPxDSxan";
|
|
|
|
|
|
|
|
case GDI_SPDnao:
|
|
|
|
return "SPDnao";
|
|
|
|
|
|
|
|
case GDI_SDno:
|
|
|
|
return "SDno";
|
|
|
|
|
|
|
|
case GDI_SDPxo:
|
|
|
|
return "SDPxo";
|
|
|
|
|
|
|
|
case GDI_SDPano:
|
|
|
|
return "SDPano";
|
|
|
|
|
|
|
|
case GDI_PDSoa:
|
|
|
|
return "PDSoa";
|
|
|
|
|
|
|
|
case GDI_PDSoxn:
|
|
|
|
return "PDSoxn";
|
|
|
|
|
|
|
|
case GDI_DSPDxax:
|
|
|
|
return "DSPDxax";
|
|
|
|
|
|
|
|
case GDI_PSDPaoxn:
|
|
|
|
return "PSDPaoxn";
|
|
|
|
|
|
|
|
case GDI_SDPSxax:
|
|
|
|
return "SDPSxax";
|
|
|
|
|
|
|
|
case GDI_PDSPaoxn:
|
|
|
|
return "PDSPaoxn";
|
|
|
|
|
|
|
|
case GDI_SDPSanax:
|
|
|
|
return "SDPSanax";
|
|
|
|
|
|
|
|
case GDI_SPxPDxan:
|
|
|
|
return "SPxPDxan";
|
|
|
|
|
|
|
|
case GDI_SSPxDSxax:
|
|
|
|
return "SSPxDSxax";
|
|
|
|
|
|
|
|
case GDI_DSPDSanaxxn:
|
|
|
|
return "DSPDSanaxxn";
|
|
|
|
|
|
|
|
case GDI_DPSao:
|
|
|
|
return "DPSao";
|
|
|
|
|
|
|
|
case GDI_DPSxno:
|
|
|
|
return "DPSxno";
|
|
|
|
|
|
|
|
case GDI_SDPao:
|
|
|
|
return "SDPao";
|
|
|
|
|
|
|
|
case GDI_SDPxno:
|
|
|
|
return "SDPxno";
|
|
|
|
|
|
|
|
case GDI_SRCPAINT:
|
|
|
|
return "DSo";
|
|
|
|
|
|
|
|
case GDI_SDPnoo:
|
|
|
|
return "SDPnoo";
|
|
|
|
|
|
|
|
case GDI_PATCOPY:
|
|
|
|
return "P";
|
|
|
|
|
|
|
|
case GDI_PDSono:
|
|
|
|
return "PDSono";
|
|
|
|
|
|
|
|
case GDI_PDSnao:
|
|
|
|
return "PDSnao";
|
|
|
|
|
|
|
|
case GDI_PSno:
|
|
|
|
return "PSno";
|
|
|
|
|
|
|
|
case GDI_PSDnao:
|
|
|
|
return "PSDnao";
|
|
|
|
|
|
|
|
case GDI_PDno:
|
|
|
|
return "PDno";
|
|
|
|
|
|
|
|
case GDI_PDSxo:
|
|
|
|
return "PDSxo";
|
|
|
|
|
|
|
|
case GDI_PDSano:
|
|
|
|
return "PDSano";
|
|
|
|
|
|
|
|
case GDI_PDSao:
|
|
|
|
return "PDSao";
|
|
|
|
|
|
|
|
case GDI_PDSxno:
|
|
|
|
return "PDSxno";
|
|
|
|
|
|
|
|
case GDI_DPo:
|
|
|
|
return "DPo";
|
2015-06-26 15:32:38 +03:00
|
|
|
|
2016-04-25 10:42:59 +03:00
|
|
|
case GDI_PATPAINT:
|
2016-08-05 20:38:46 +03:00
|
|
|
return "DPSnoo";
|
2016-04-25 10:42:59 +03:00
|
|
|
|
2016-08-05 15:10:53 +03:00
|
|
|
case GDI_PSo:
|
2016-08-05 20:38:46 +03:00
|
|
|
return "PSo";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
|
|
|
case GDI_PSDnoo:
|
2016-08-05 20:38:46 +03:00
|
|
|
return "PSDnoo";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
|
|
|
case GDI_DPSoo:
|
2016-08-05 20:38:46 +03:00
|
|
|
return "DPSoo";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_WHITENESS:
|
|
|
|
return "1";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
case GDI_GLYPH_ORDER:
|
|
|
|
return "SPaDSnao";
|
2016-08-05 15:10:53 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
default:
|
|
|
|
return "";
|
|
|
|
}
|
|
|
|
}
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
/**
|
2019-11-06 17:24:51 +03:00
|
|
|
* Create a new solid brush.\n
|
|
|
|
* @msdn{dd183518}
|
|
|
|
* @param crColor brush color
|
|
|
|
* @return new brush
|
|
|
|
*/
|
2016-08-05 20:38:46 +03:00
|
|
|
HGDI_BRUSH gdi_CreateSolidBrush(UINT32 crColor)
|
|
|
|
{
|
2019-11-06 17:24:51 +03:00
|
|
|
HGDI_BRUSH hBrush = (HGDI_BRUSH)calloc(1, sizeof(GDI_BRUSH));
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
if (!hBrush)
|
|
|
|
return NULL;
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
hBrush->objectType = GDIOBJECT_BRUSH;
|
|
|
|
hBrush->style = GDI_BS_SOLID;
|
|
|
|
hBrush->color = crColor;
|
|
|
|
return hBrush;
|
|
|
|
}
|
|
|
|
/**
|
2019-11-06 17:24:51 +03:00
|
|
|
* Create a new pattern brush.\n
|
|
|
|
* @msdn{dd183508}
|
|
|
|
* @param hbmp pattern bitmap
|
|
|
|
* @return new brush
|
|
|
|
*/
|
2016-08-05 20:38:46 +03:00
|
|
|
HGDI_BRUSH gdi_CreatePatternBrush(HGDI_BITMAP hbmp)
|
|
|
|
{
|
2019-11-06 17:24:51 +03:00
|
|
|
HGDI_BRUSH hBrush = (HGDI_BRUSH)calloc(1, sizeof(GDI_BRUSH));
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
if (!hBrush)
|
|
|
|
return NULL;
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
hBrush->objectType = GDIOBJECT_BRUSH;
|
|
|
|
hBrush->style = GDI_BS_PATTERN;
|
|
|
|
hBrush->pattern = hbmp;
|
|
|
|
return hBrush;
|
|
|
|
}
|
|
|
|
HGDI_BRUSH gdi_CreateHatchBrush(HGDI_BITMAP hbmp)
|
|
|
|
{
|
2019-11-06 17:24:51 +03:00
|
|
|
HGDI_BRUSH hBrush = (HGDI_BRUSH)calloc(1, sizeof(GDI_BRUSH));
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
if (!hBrush)
|
|
|
|
return NULL;
|
2016-04-05 18:07:45 +03:00
|
|
|
|
2016-08-05 20:38:46 +03:00
|
|
|
hBrush->objectType = GDIOBJECT_BRUSH;
|
|
|
|
hBrush->style = GDI_BS_HATCHED;
|
|
|
|
hBrush->pattern = hbmp;
|
|
|
|
return hBrush;
|
|
|
|
}
|