Re: [MacPerl] Re: MacPerl 5.6.1 System Requirements

2001-08-05 Thread John W Baxter
At 13:30 -0700 8/5/2001, Cameron Kaiser wrote: >No kidding. They can make me give up this 7300 + G3/500/1MB when they pry >it from my cold, dead fingers. I didn't put 22GB of SCSI disks and 352MB >of RAM in it just so I could chuck it all for The Next Big Thing(tm). My needs for my 7300 were diff

[MacPerl] Re: MacPerl 5.6.1 System Requirements

2001-08-05 Thread John W Baxter
At 13:19 +0200 8/5/2001, ik wrote: >Here are some Webstats I happened to have. > >184486 requests from Macintosh computers visiting the particular site >were from >: 183856: Macintosh PowerPC >:570: Macintosh 68k >: 60: Unknown Macintosh That doesn't "feel like" the mac

Re: [MacPerl] local time UTC difference

2001-11-21 Thread John W Baxter
At 8:26 -0500 11/21/2001, Chris Nandor wrote: >At 14:19 +0100 2001.11.21, Louis Pouzin wrote: >>The Mac Date & Time control panel keeps the time zone. e.g. Paris. >> >>Is there a way to grab this info, in MacPerl, or at least the difference from >>UTC ? > > use Time::Local; > $diff = (

Re: [MacPerl] exotic date format

2002-02-15 Thread John W Baxter
At 18:34 -0500 2/15/2002, Chris Nandor wrote: >At 00:20 +0100 2002.02.16, Louis Pouzin wrote: >>Is there a library module that recognizes this format ? > >Date::Parse::str2time handles it all except for the "o'clock". And I've never happened to see an "o'clock" in the date in a mail header (visib

Re: [MacPerl] Edit Postscript file

2002-03-07 Thread John W Baxter
At 14:15 -0500 3/4/2002, Chris Nandor wrote: >At 10:57 +0100 2002.03.04, Bart Lateur wrote: >>On Mon, 4 Mar 2002 10:37:54 +0100, Beat Pfister wrote: >> >>>I tried to edit postscript files with perl, but no I reconiced that perl >>>changes the line ending charackters even if I only open the file an

Re: [MacPerl] AppleScript vs MacPerl

2002-03-11 Thread John W Baxter
At 15:15 -0800 3/11/2002, Crook, Richard W wrote: >Just a quick question/survey. I'm taking over an system written mostly in >AppleScript and some MacPerl. Is it worth sticking with the AppleScript or >should I port it over to MacPerl. I suppose the answer will be obvious >considering the list I'

Re: [MacPerl] MacPerl 5.6.1r1 runtimes under MacOS X?

2002-03-20 Thread John W Baxter
Chris wrote (in a mesage I tossed out) something like "Does AppleScript work properly on those machines?" (Or "Do Applescripts work...") There are a couple of definitions of "properly" at the moment. On a stock 10.1.3, we're at AppleScript 1.8. It has problems with some things. If one has in

Re: [MacPerl] macperlcat doc question and AE's

2002-04-14 Thread John W Baxter
At 13:23 -0500 4/2/2002, Chris Nandor wrote: >At 08:02 -0800 2002.04.02, Andrew O. Mellinger wrote: >>Is this last example correct? From what I am led to believe the >>"form:enum(name)" should instead be "form:indx" > >Yes. > >> I am actually getting the index of some item on the desktop, and

RE: [MacPerl] Rotate Cursor crashing MacPerl?

2002-04-14 Thread John W Baxter
At 12:11 -0800 4/2/2002, Andrew O. Mellinger wrote: > This is all the same thing. In my experience RotateCursor crashes >are from as much from not disposing of descriptors (memory leak) but >more often from double-disposing them. I think that is probably what >is happening in DoAppleScript. T

RE: [MacPerl] Rotate Cursor crashing MacPerl?

2002-04-14 Thread John W Baxter
At 12:11 -0800 4/2/2002, Andrew O. Mellinger wrote: > Overall, I've found Apple Events to be a real pain. I wish Apple >had come up with something easier to use. That's why one develops a suitable library for doing the grunt work. ;-) I got tired of building AppleEvents using inline code rema

Re: [MacPerl] Mac::Glue and properties

2002-04-14 Thread John W Baxter
At 13:15 -0800 4/2/2002, Andrew O. Mellinger wrote: > For example, I'm using the Finder. How do I find the name of the >startup disk? In AppleScript it is: > > tell application "Finder" > return Startup Disk as text > end tell > > What would the be in Mac::Glue? In

Re: [MacPerl] OT: Browsers (was: The State of MacPerl)

2001-01-31 Thread John W Baxter
At 2:04 PM +0100 1/31/01, Bart Lateur wrote: >On Wed, 31 Jan 2001 07:31:45 -0500, Chris Nandor wrote: > >>When does IE 5.5 come out? > >It IS out, at least for Windows. You'll probably will have to wait a bit >(?) for the Mac version. It's not available for download yet on >Microsoft's site. > >>N

Re: [MacPerl] Sprintf() huh?

2001-03-04 Thread John W Baxter
At 6:33 +0900 3/5/01, [EMAIL PROTECTED] wrote: >?One for the Perl gurus on the list- not a major problem but more of a >philosophical debate, while doing some date related work I noticed that >sprintf() & printf() didn't behave as I expected them to, the following >snippet: > >#!perl-w > >printf("

Re: [MacPerl] Sprintf() huh?

2001-03-05 Thread John W Baxter
Robin wrote: >?Ronald J Kimball <[EMAIL PROTECTED]>wrote: >>Do not subtract 100 from the year returned by localtime! >>Apparently some programmers have a very short memory >>Unless you want your script to fail for years before 2000 and after 2999 > >on a purely programmatical basis, using the modu

Re: [MacPerl] number 3 in my series of beginner problems

2001-03-11 Thread John W Baxter
Some people who continually get bitten by the = vs == thing in C and Perl adopt the style of writing the literal first (if the test value is a literal)... ... until (10 == $j) That becomes a compile time error if you forgetfully write = instead of ==. This doesn't work in Perl if you elimin

Re: [MacPerl] StyledText data into a record of text and styl

2001-03-18 Thread John W Baxter
At 20:17 +0100 3/18/01, Bart Lateur wrote: >I think that that "mush" itself is stored in some kind of tree. The key >to traversing this tree should be some length words/longs, indicating >how long the individual parts are. I expect it to be not to different >from how JPEG and/or TIFF files are sto

Re: [MacPerl] StyledText data into a record of text and styl

2001-03-18 Thread John W Baxter
At 12:45 -0800 3/18/01, John W Baxter wrote: >4 bytes: type code (TEXT, PICT, styl, etc etc) >4 bytes: length of the data (must be even) >n bytes: the data >Repeated until one runs out of stuff. I put "(must be even)" in the wrong place...IM attaches it to "n b

Re: [MacPerl] StyledText data into a record of text and styl

2001-03-19 Thread John W Baxter
At 12:35 + 3/19/01, Alan Fry wrote: >As you said in an earlier post this _presumes_ that the number >following each 'four character group' will be a 'long'. In the case >of the MSWD extract above 'DSIG' is an MS key, rather than a MacOS >key, so one would be reliant on BG doing the expected th

Re: [MacPerl] StyledText data into a record of text and styl

2001-03-19 Thread John W Baxter
At 15:21 +0100 3/19/01, Bart Lateur wrote: >>This issue of processing StyledText data is a long story for me. Years >>ago, I first was interested in it when I downloaded and studied a Frontier >>suite named "StyledText", written by John (Baxter). > >John Baxter? Could this possibly be the same Jo

Re: [MacPerl] StyledText data into a record of text and styl

2001-03-19 Thread John W Baxter
At 12:07 +0100 3/19/01, Bart Lateur wrote: >* The length of the data, is that including this 8 byte header (as with >JPEG), or just the appended data? If memory serves (and I think it does, because the IM wording seems to agree), it is the length of the data, so that the offset from type n to typ

re: [MacPerl] Problems with CGI

2001-03-23 Thread John W Baxter
At 14:19 +0900 3/23/01, [EMAIL PROTECTED] wrote: >?From: [EMAIL PROTECTED] wrote: >>Hello all. I am new to this mailing list so I am not sure if this message >>belongs here, >As will undoubtedly be pointed out more than once, there is a separate list >for cgi related stuff, so next time cgi re

Re: [MacPerl] Processes, Command Parameters, and Other Apps...

2001-04-12 Thread John W Baxter
At 0:33 +0900 4/13/01, Gero Herrmann wrote: > $path =~ s/(["\\])/\\$1/g; > $url =~ s/(["\\])/\\$1/g; It is this sort of thing which led, years ago, to the coining of "LTS" or "leaning toothpick syndrome" to describe the effect. Having to use \ to escape \ in an 'outer' language only

Re: [MacPerl] Processes, Command Parameters, and Other Apps...

2001-04-13 Thread John W Baxter
At 11:18 -0400 4/13/01, Chris Nandor wrote: >At 07:48 -0400 2001.04.13, Paul J. Schinder wrote: >>Now if we could only come up with something for Python and all the >>stupid tabs... > >Please You Tab-Hit Often and Necessarily appending: or space out. -- John Baxter [EMAIL PROTECTED] P

Re: [MacPerl] Transfering a script from unix to a mac.....

2001-04-18 Thread John W Baxter
At 14:36 +0900 4/18/01, [EMAIL PROTECTED] wrote: >back ticks- Unix system commands aren't supported under MacOS, (some >commands like `pwd` for example, are emulated). To further produce confusion, more stuff is supported in back ticks if Toolserver (the MPW thing) is present for the use of the fr

Re: [MacPerl] Zap Research Fork...?

2001-04-24 Thread John W Baxter
If one has MPW lying around, one can do duplicate -d ... Check the help to be sure I got that right. --John -- John Baxter [EMAIL PROTECTED] Port Ludlow, WA, USA

Re: [MacPerl] parsing files in a directory

2001-06-14 Thread John W Baxter
At 16:45 +0200 6/13/2001, Bart Lateur wrote: >And "." doesn't exist on the Mac, I would think. It's not special, if it >does. A leading . on a file name was *once* special on Mac: it meant (except when misused) "I am a driver". [The system had a tendency to try to execute such files as drivers

Re: [MacPerl] how to get just the file name from full path

2001-07-09 Thread John W Baxter
At 15:16 -0400 7/9/2001, Morbus Iff wrote: > >$f =~ m/:(.*)$/ ? print "$1\n" : print "$f\n"; > >This will fail if you're more than one directory deep, ie, it'll work fine >on "HD:filename.xml", but will fail on "HD:Directory:filename.xml". In the >first case, it will properly return "filename.

Re: [MacPerl] how to get just the file name from full path

2001-07-09 Thread John W Baxter
Repost, with a working regex (and no -w complaints). >At 15:16 -0400 7/9/2001, Morbus Iff wrote: >> >$f =~ m/:(.*)$/ ? print "$1\n" : print "$f\n"; >> >>This will fail if you're more than one directory deep, ie, it'll work fine >>on "HD:filename.xml", but will fail on "HD:Directory:filename.x

Re: [MacPerl] how to get just the file name from full path

2001-07-09 Thread John W Baxter
At 22:33 -0700 7/9/01, Bruce Van Allen wrote: >Wait -- doesn't the $ 'anchor' the regex to the end of the string? If >so, that's where the matching attempts *start*, yes? Not according to Jeffrey E.F. Friedl's excellent discussion in "Mastering Regular Expressions." It does work at the other end