Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: Weird Output with Threads and NCurses

by BrowserUk (Pope)
on Jul 17, 2016 at 05:40 UTC ( #1167901=note: print w/replies, xml ) Need Help??


in reply to Weird Output with Threads and NCurses

I don't use *nix; and the last time I used curses, was very brief & last century; but the idea that it would work correctly being accessed concurrently from multiple threads seems ... very remote.

As with most GUI frameworks that weren't developed specifically to work with threading; if you have to use curses, use it from one thread only and route all console IO from other threads, through that CUI thread via a queue.

Attempting to get anything else to work is a waste of your time; and is very unlikely to receive anything by way of support.


With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority". I knew I was on the right track :)
In the absence of evidence, opinion is indistinguishable from prejudice.
  • Comment on Re: Weird Output with Threads and NCurses

Replies are listed 'Best First'.
Re^2: Weird Output with Threads and NCurses
by var121 (Initiate) on Jul 17, 2016 at 07:14 UTC
    perldoc perlthrtut, says that Boss/Worker model is common in GUI applications. Can you kindly elaborate your comment, I didn't understand parts of it. I am new to Threads concepts.

      See Re: Tk, threads, and mjpeg stream or any of any of the many threads turned up by this search for examples and discussion of using Tk and threads.

      I cannot offer anything that uses curses directly as I don't use it, it doesn't run on my platform and whatever transient knowledge I had of it has long since been archived into long-term write-only storage :)


      With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
      Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
      "Science is about questioning the status quo. Questioning authority". I knew I was on the right track :)
      In the absence of evidence, opinion is indistinguishable from prejudice.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1167901]
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (7)
As of 2018-01-17 01:49 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    How did you see in the new year?










    Results (194 votes). Check out past polls.

    Notices?