Messed up NSTextField labels - thread issue?
Messed up NSTextField labels - thread issue?
- Subject: Messed up NSTextField labels - thread issue?
- From: email@hidden
- Date: Wed, 6 Jun 2001 14:10:07 -0700
My application has a thread that runs in the background and periodically
refreshes several UI labels (NSTextFields) via [theField
setStringValue:theNewString]. Often when those fields redraw the old
string isn't erased first, and the result is blurry and unreadable.
Sometime when those fields redraw it correctly erases all the old junk
before putting in the correct string.
I am beginning to wonder if this be an issue with the AppKit not being
thread-safe. Perhaps the call to [theField setStringValue:theNewString]
from within the background thread is interacting with the main
application drawing/event loop in a bad way?
If anyone could offer some feedback I'd appreciate it.
-Hans Andersen