Update: I changed my mind on this - see my newest node at the end of the discussion.

Hi stefp,

Maybe I'm just too pratical, but I think I'm the only person that isn't repulsed by Tk's appearance. I like programming in it and with a little effort you can make your stuff look pretty decent. Oh well, back to the matter at hand.

I might be missing something obvious here, but I would think the best way to get around this problem is to fork before dealing with Tk at all. That way the kiddie won't inherit any of the nasty X (or other wm) stuff. There are situations when that may not be easy, but for the most part I think it saves you.

Maybe if you gave us a better idea of what kind of stuff it was doing we could provide more useful information. But I think even if you have, say, a front end with buttons and each button when clicked forks a child to perform a given task, there really isn't any reason a preforked child couldn't get a message over IPC (or socket, I've become a huge fan of IO::Socket/IO::Select recently, mmmm) and just handle the task instead of forking again.

Anyway, please provide a bit more information - an example would be nice, perhaps. I'll stop back and look again as I'm sure other monks will.

Good luck,
{NULE}
--
http://www.nule.org


In reply to Re: forking in Tk and letting the dad alone deal with X stuff by {NULE}
in thread forking in Tk and letting the dad alone deal with X stuff by stefp

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.