diff options
author | dgp <dgp@users.sourceforge.net> | 2019-11-20 18:50:02 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2019-11-20 18:50:02 (GMT) |
commit | 72ae3baa490baaf69b7359b378361921e532ccde (patch) | |
tree | 0ceafbb929cc0ebd5eb08a80288844c8dbad7404 /generic | |
parent | 83adf45f708233fe1bed74cc67d714c40905dbbd (diff) | |
parent | e15390471f6368e52215eb6ff7bd88d3185d66e1 (diff) | |
download | tk-72ae3baa490baaf69b7359b378361921e532ccde.zip tk-72ae3baa490baaf69b7359b378361921e532ccde.tar.gz tk-72ae3baa490baaf69b7359b378361921e532ccde.tar.bz2 |
Merge 8.6 except for the broken demo.
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tkFont.c | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/generic/tkFont.c b/generic/tkFont.c index 86fdd87..156ebf3 100644 --- a/generic/tkFont.c +++ b/generic/tkFont.c @@ -13,7 +13,9 @@ #include "tkInt.h" #include "tkFont.h" - +#if defined(MAC_OSX_TK) +#include "tkMacOSXInt.h" +#endif /* * The following structure is used to keep track of all the fonts that exist * in the current application. It must be stored in the TkMainInfo for the @@ -872,7 +874,18 @@ TheWorldHasChanged( ClientData clientData) /* Info about application's fonts. */ { TkFontInfo *fiPtr = clientData; +#if defined(MAC_OSX_TK) + /* + * On macOS it is catastrophic to recompute all widgets while the + * [NSView drawRect] method is drawing. The best that we can do in + * that situation is to abort the recomputation and hope for the best. + */ + + if (TkpAppIsDrawing()) { + return; + } +#endif fiPtr->updatePending = 0; RecomputeWidgets(fiPtr->mainPtr->winPtr); } |