Change current font only if new graphics font is successfully created

If new graphics font couldn't be created successfully there is no need
to reset current font by updating it to wxNullGraphicsFont.

Closes #17790.
This commit is contained in:
Artur Wieczorek
2017-04-17 18:32:31 +02:00
parent 7f9453dfdf
commit 06963940fb
2 changed files with 15 additions and 2 deletions

View File

@@ -10,6 +10,10 @@
wxGCDC is a device context that draws on a wxGraphicsContext.
@remarks
If Direct2D is a renderer of underlying graphics context, only wxFont objects
representing TrueType fonts can be used in the font-related functions.
@library{wxcore}
@category{dc}