Okay, I'll show my utter ignorance of OO and ask if OO in Perl is anything more (in a general sense, of course) than modularized subroutines? Aside from the global variables, I've broken the script up into numerous subroutines all of which operate (as much as is possible) independent of each other.

Also, of the 4000 lines, only about 750 are actually in the main loop of the Tk interface, the rest are taken up by the subroutines (21 in total). It's for this reason that the global variables worry me, because after a while it does become difficult to know where they have been littered throughout the subroutines and ensure that I haven't accidentally put them in a position of being modified (but I'm checking my code with a fine-toothed comb now, as the saying goes).

I'm going to see if I can get my hands on a copy of the OO Perl book, and will see what I can do about putting the globals into a module. Thanks for the responses!

matt


In reply to Re: (jeffa) Re: Passing variables is as easy as passing gas by mattg
in thread Passing variables is as easy as passing gas by mattg

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.