From ccd361c98f1fef2300e922f1de90ff0f3311d5c2 Mon Sep 17 00:00:00 2001 From: David Vanderson Date: Sat, 13 Feb 2016 12:49:21 +0100 Subject: [PATCH] Fix strike-through support in wxFont with GDI+ Pass down the strike-through flag to GDI+ (see #9907). Closes #17372. --- docs/changes.txt | 1 + src/msw/graphics.cpp | 2 ++ 2 files changed, 3 insertions(+) diff --git a/docs/changes.txt b/docs/changes.txt index acd9a61572..f4cafef118 100644 --- a/docs/changes.txt +++ b/docs/changes.txt @@ -209,6 +209,7 @@ wxMSW: - Fix crash in wxD2DContext when using non-MSVC compiler (iwbnwif). - Notify shell about the changes done by wxMimeTypesManager (Maarten Bent). - Fix wxPrintf() and friends when using MinGW with ANSI stdio option. +- Fix strike-through support in wxFont with GDI+ (David Vanderson). wxOSX/Cocoa: diff --git a/src/msw/graphics.cpp b/src/msw/graphics.cpp index 2aee500870..da9da365da 100644 --- a/src/msw/graphics.cpp +++ b/src/msw/graphics.cpp @@ -962,6 +962,8 @@ wxGDIPlusFontData::wxGDIPlusFontData( wxGraphicsRenderer* renderer, style |= FontStyleItalic; if ( font.GetUnderlined() ) style |= FontStyleUnderline; + if ( font.GetStrikethrough() ) + style |= FontStyleStrikeout; if ( font.GetWeight() == wxFONTWEIGHT_BOLD ) style |= FontStyleBold;