| 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 #include "../../../include/fxge/fx_ge.h" | 7 #include "../../../include/fxge/fx_ge.h" |
| 8 #if _FX_OS_ == _FX_WIN32_DESKTOP_ || _FX_OS_ == _FX_WIN64_DESKTOP_ | 8 #if _FX_OS_ == _FX_WIN32_DESKTOP_ || _FX_OS_ == _FX_WIN64_DESKTOP_ |
| 9 #include "../../../include/fxge/fx_ge_win32.h" | 9 #include "../../../include/fxge/fx_ge_win32.h" |
| 10 #include "dwrite_int.h" | 10 #include "dwrite_int.h" |
| (...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 259 pMatrix ? &transform : NULL, | 259 pMatrix ? &transform : NULL, |
| 260 baselineOriginX, baselineOriginY, | 260 baselineOriginX, baselineOriginY, |
| 261 DWRITE_MEASURING_MODE_NATURAL, | 261 DWRITE_MEASURING_MODE_NATURAL, |
| 262 &glyphRun, | 262 &glyphRun, |
| 263 RGB(FXARGB_R(text_color), FXARGB_G(text_color), FXARGB_B(text_color
)) | 263 RGB(FXARGB_R(text_color), FXARGB_G(text_color), FXARGB_B(text_color
)) |
| 264 ); | 264 ); |
| 265 return SUCCEEDED(hr) ? TRUE : FALSE; | 265 return SUCCEEDED(hr) ? TRUE : FALSE; |
| 266 } | 266 } |
| 267 void CDWriteExt::DwDeleteRenderingTarget(void* renderTarget) | 267 void CDWriteExt::DwDeleteRenderingTarget(void* renderTarget) |
| 268 { | 268 { |
| 269 if (renderTarget) { | 269 delete (CDwGdiTextRenderer*)renderTarget; |
| 270 delete (CDwGdiTextRenderer*)renderTarget; | |
| 271 } | |
| 272 } | 270 } |
| 273 void CDWriteExt::DwDeleteFont(void* pFont) | 271 void CDWriteExt::DwDeleteFont(void* pFont) |
| 274 { | 272 { |
| 275 if (pFont) { | 273 if (pFont) { |
| 276 SafeRelease((IDWriteFontFace**)&pFont); | 274 SafeRelease((IDWriteFontFace**)&pFont); |
| 277 } | 275 } |
| 278 } | 276 } |
| 279 CDwFontFileStream::CDwFontFileStream(void const* fontFileReferenceKey, UINT32 fo
ntFileReferenceKeySize) | 277 CDwFontFileStream::CDwFontFileStream(void const* fontFileReferenceKey, UINT32 fo
ntFileReferenceKeySize) |
| 280 { | 278 { |
| 281 refCount_ = 0; | 279 refCount_ = 0; |
| (...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 471 text_bbox.Height(), | 469 text_bbox.Height(), |
| 472 &dib, | 470 &dib, |
| 473 text_bbox.left, | 471 text_bbox.left, |
| 474 text_bbox.top, | 472 text_bbox.top, |
| 475 FXDIB_BLEND_NORMAL, | 473 FXDIB_BLEND_NORMAL, |
| 476 pClipRgn | 474 pClipRgn |
| 477 ); | 475 ); |
| 478 return hr; | 476 return hr; |
| 479 } | 477 } |
| 480 #endif | 478 #endif |
| OLD | NEW |