| OLD | NEW |
| 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 _FX_PALTFORM_DEVICE_H_ | 7 #ifndef _FX_PALTFORM_DEVICE_H_ |
| 8 #define _FX_PALTFORM_DEVICE_H_ | 8 #define _FX_PALTFORM_DEVICE_H_ |
| 9 class IFPF_DeviceModule; | 9 class IFPF_DeviceModule; |
| 10 class IFPF_FontMgr; | 10 class IFPF_FontMgr; |
| 11 class IFPF_Font; | 11 class IFPF_Font; |
| 12 class IFPF_DeviceModule | 12 class IFPF_DeviceModule |
| 13 { | 13 { |
| 14 public: | 14 public: |
| 15 virtual ~IFPF_DeviceModule() { } | 15 virtual ~IFPF_DeviceModule() { } |
| 16 virtual void Destroy() = 0; | 16 virtual void Destroy() = 0; |
| 17 virtual IFPF_FontMgr* GetFontMgr() = 0; | 17 virtual IFPF_FontMgr* GetFontMgr() = 0; |
| 18 }; | 18 }; |
| 19 IFPF_DeviceModule* FPF_GetDeviceModule(); | 19 IFPF_DeviceModule* FPF_GetDeviceModule(); |
| 20 #define FPF_MATCHFONT_REPLACEANSI 1 | 20 #define FPF_MATCHFONT_REPLACEANSI 1 |
| 21 FX_DEFINEHANDLE(FPF_HFONT); | 21 typedef struct FPF_HFONT_ { |
| 22 FX_LPVOID pData; |
| 23 }* FPF_HFONT; |
| 22 class IFPF_Font | 24 class IFPF_Font |
| 23 { | 25 { |
| 24 public: | 26 public: |
| 25 virtual void Release() = 0; | 27 virtual void Release() = 0; |
| 26 virtual IFPF_Font* Retain() = 0; | 28 virtual IFPF_Font* Retain() = 0; |
| 27 virtual FPF_HFONT GetHandle() = 0; | 29 virtual FPF_HFONT GetHandle() = 0; |
| 28 virtual CFX_ByteString GetFamilyName() = 0; | 30 virtual CFX_ByteString GetFamilyName() = 0; |
| 29 virtual CFX_WideString GetPsName() = 0; | 31 virtual CFX_WideString GetPsName() = 0; |
| 30 virtual FX_DWORD GetFontStyle() const = 0; | 32 virtual FX_DWORD GetFontStyle() const = 0; |
| 31 virtual FX_BYTE GetCharset() const = 0; | 33 virtual FX_BYTE GetCharset() const = 0; |
| (...skipping 19 matching lines...) Expand all Loading... |
| 51 public: | 53 public: |
| 52 virtual ~IFPF_FontMgr() { } | 54 virtual ~IFPF_FontMgr() { } |
| 53 virtual void LoadSystemFonts() = 0; | 55 virtual void LoadSystemFonts() = 0; |
| 54 virtual void LoadPrivateFont(IFX_FileRead* pFontFile)
= 0; | 56 virtual void LoadPrivateFont(IFX_FileRead* pFontFile)
= 0; |
| 55 virtual void LoadPrivateFont(FX_BSTR bsFileName) = 0; | 57 virtual void LoadPrivateFont(FX_BSTR bsFileName) = 0; |
| 56 virtual void LoadPrivateFont(FX_LPVOID pBuffer, size_
t szBuffer) = 0; | 58 virtual void LoadPrivateFont(FX_LPVOID pBuffer, size_
t szBuffer) = 0; |
| 57 | 59 |
| 58 virtual IFPF_Font* CreateFont(FX_BSTR bsFamilyname, FX_BYTE charset
, FX_DWORD dwStyle, FX_DWORD dwMatch = 0) = 0; | 60 virtual IFPF_Font* CreateFont(FX_BSTR bsFamilyname, FX_BYTE charset
, FX_DWORD dwStyle, FX_DWORD dwMatch = 0) = 0; |
| 59 }; | 61 }; |
| 60 #endif | 62 #endif |
| OLD | NEW |