|
|
On Wed, 6 Jul 2022 at 16:04, Jck_01 wrote:
>
>>
>> How many threads are in your code?
>
> Generally only one. The code in dialog windows uses one, main program thread. A new thread is created only when I call methods of network library. Could it be the reason of artefacts?
>
It depends...
If the network threads do not interact with the FLTK widgets then
there is no problem.
However, if the worker thread DOES interact with FLTK widgets, then
that will be a problem... At that point you need to determine how to
best make your network thread interact safely with the GUI render
context. The "Advanced FLTK" section of the manual addresses those
issues, either via locking (probably not a good idea in a network
thread) or via the FL::awake() callback mechanism.
--
You received this message because you are subscribed to the Google Groups "fltk.general" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fltkgeneral+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fltkgeneral/CAGFM6da04%3Dq-jsXbYY8jepHw_s96n-D2mBvazz5wpa7bdcqCxA%40mail.gmail.com.
[ Direct Link to Message ] | |
|
| |