Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(639)

Side by Side Diff: core/include/fxge/fx_ge.h

Issue 1828283002: support gradients and stroke+fill (Closed) Base URL: https://pdfium.googlesource.com/pdfium@master
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 PDFium Authors. All rights reserved. 1 // Copyright 2014 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6 6
7 #ifndef CORE_INCLUDE_FXGE_FX_GE_H_ 7 #ifndef CORE_INCLUDE_FXGE_FX_GE_H_
8 #define CORE_INCLUDE_FXGE_FX_GE_H_ 8 #define CORE_INCLUDE_FXGE_FX_GE_H_
9 9
10 #include "core/include/fxge/fx_dib.h" 10 #include "core/include/fxge/fx_dib.h"
11 #include "core/include/fxge/fx_font.h" 11 #include "core/include/fxge/fx_font.h"
12 12
13 class CFX_Font; 13 class CFX_Font;
14 class CFX_FontMgr; 14 class CFX_FontMgr;
15 class CFX_FontCache; 15 class CFX_FontCache;
16 class CFX_FaceCache; 16 class CFX_FaceCache;
17 class CPDF_ShadingPattern;
17 class IFX_RenderDeviceDriver; 18 class IFX_RenderDeviceDriver;
18 class CCodec_ModuleMgr; 19 class CCodec_ModuleMgr;
19 class SkPictureRecorder; 20 class SkPictureRecorder;
20 21
21 class CFX_GEModule { 22 class CFX_GEModule {
22 public: 23 public:
23 static void Create(const char** pUserFontPaths); 24 static void Create(const char** pUserFontPaths);
24 25
25 static void Use(CFX_GEModule* pMgr); 26 static void Use(CFX_GEModule* pMgr);
26 27
(...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 #define FXRC_ALPHA_MASK 0x04 209 #define FXRC_ALPHA_MASK 0x04
209 #define FXRC_ALPHA_PATH 0x10 210 #define FXRC_ALPHA_PATH 0x10
210 #define FXRC_ALPHA_IMAGE 0x20 211 #define FXRC_ALPHA_IMAGE 0x20
211 #define FXRC_ALPHA_OUTPUT 0x40 212 #define FXRC_ALPHA_OUTPUT 0x40
212 #define FXRC_BLEND_MODE 0x80 213 #define FXRC_BLEND_MODE 0x80
213 #define FXRC_SOFT_CLIP 0x100 214 #define FXRC_SOFT_CLIP 0x100
214 #define FXRC_CMYK_OUTPUT 0x200 215 #define FXRC_CMYK_OUTPUT 0x200
215 #define FXRC_BITMASK_OUTPUT 0x400 216 #define FXRC_BITMASK_OUTPUT 0x400
216 #define FXRC_BYTEMASK_OUTPUT 0x800 217 #define FXRC_BYTEMASK_OUTPUT 0x800
217 #define FXRENDER_IMAGE_LOSSY 0x1000 218 #define FXRENDER_IMAGE_LOSSY 0x1000
219 #define FXRC_FILLSTROKE_PATH 0x2000
220 #define FXRC_SHADING 0x4000
218 #define FXFILL_ALTERNATE 1 221 #define FXFILL_ALTERNATE 1
219 #define FXFILL_WINDING 2 222 #define FXFILL_WINDING 2
220 #define FXFILL_FULLCOVER 4 223 #define FXFILL_FULLCOVER 4
221 #define FXFILL_RECT_AA 8 224 #define FXFILL_RECT_AA 8
222 #define FX_FILL_STROKE 16 225 #define FX_FILL_STROKE 16
223 #define FX_STROKE_ADJUST 32 226 #define FX_STROKE_ADJUST 32
224 #define FX_STROKE_TEXT_MODE 64 227 #define FX_STROKE_TEXT_MODE 64
225 #define FX_FILL_TEXT_MODE 128 228 #define FX_FILL_TEXT_MODE 128
226 #define FX_ZEROAREA_FILL 256 229 #define FX_ZEROAREA_FILL 256
227 #define FXFILL_NOPATHSMOOTH 512 230 #define FXFILL_NOPATHSMOOTH 512
(...skipping 352 matching lines...) Expand 10 before | Expand all | Expand 10 after
580 CFX_Font* pFont, 583 CFX_Font* pFont,
581 CFX_FontCache* pCache, 584 CFX_FontCache* pCache,
582 const CFX_Matrix* pObject2Device, 585 const CFX_Matrix* pObject2Device,
583 FX_FLOAT font_size, 586 FX_FLOAT font_size,
584 FX_DWORD color, 587 FX_DWORD color,
585 int alpha_flag = 0, 588 int alpha_flag = 0,
586 void* pIccTransform = NULL) { 589 void* pIccTransform = NULL) {
587 return FALSE; 590 return FALSE;
588 } 591 }
589 592
590 virtual void* GetPlatformSurface() { return NULL; } 593 virtual void* GetPlatformSurface() { return NULL; }
Tom Sepez 2016/03/24 18:07:08 nit: should any of these be const?
caryclark 2016/03/25 20:47:56 Done.
591 594
Tom Sepez 2016/03/24 18:07:08 nit: might as well kill these blank lines?
caryclark 2016/03/25 20:47:56 Done.
592 virtual int GetDriverType() { return 0; } 595 virtual int GetDriverType() { return 0; }
593 596
594 virtual void ClearDriver() {} 597 virtual void ClearDriver() {}
598
599 virtual FX_BOOL DrawShading(CPDF_ShadingPattern* pPattern,
600 CFX_Matrix* pMatrix,
601 int alpha,
602 FX_BOOL bAlphaMode) {
603 return false;
604 }
595 }; 605 };
596 606
597 class IFX_PSOutput { 607 class IFX_PSOutput {
598 public: 608 public:
599 virtual void Release() = 0; 609 virtual void Release() = 0;
600 virtual void OutputPS(const FX_CHAR* str, int len) = 0; 610 virtual void OutputPS(const FX_CHAR* str, int len) = 0;
601 611
602 protected: 612 protected:
603 virtual ~IFX_PSOutput() {} 613 virtual ~IFX_PSOutput() {}
604 }; 614 };
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
707 void FindPSFontGlyph(CFX_FaceCache* pFaceCache, 717 void FindPSFontGlyph(CFX_FaceCache* pFaceCache,
708 CFX_Font* pFont, 718 CFX_Font* pFont,
709 const FXTEXT_CHARPOS& charpos, 719 const FXTEXT_CHARPOS& charpos,
710 int& ps_fontnum, 720 int& ps_fontnum,
711 int& ps_glyphindex); 721 int& ps_glyphindex);
712 722
713 void WritePSBinary(const uint8_t* data, int len); 723 void WritePSBinary(const uint8_t* data, int len);
714 }; 724 };
715 725
716 #endif // CORE_INCLUDE_FXGE_FX_GE_H_ 726 #endif // CORE_INCLUDE_FXGE_FX_GE_H_
OLDNEW
« core/fxge/skia/fx_skia_device.cpp ('K') | « core/fxge/skia/fx_skia_device.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698