At 22:21 +0900 2001-03-19, Nobumi Iyanaga wrote: >On the other hand, if there is a way to pass "styl" and "TEXT" data to >MacPerl as @ARGV data, we would be able to write an AppleScript script >looking like this: > >set stxt to "" >tell application "Style" > set stxt to selection of front document as styled text >end tell > >set stxtRecord to stxt as record >set txt to <<class ktxt>> of stxtRecord >set styl to <<class ksty>> of stxtRecord > >tell application "MacJPerl" > activate > set res to Do Script {"my_read_StyledText.pl", txt, styl} mode Batch >end tell You could do that with Sigmas Coercions, a free Scripting Addition. http://members.home.net/eric-allen-grant/Sigmas-Coercions.sit.hqx tell application "MacJPerl" activate set res to Do Script {"my_read_StyledText.pl", txt, styl as hex string} mode Batch end tell In MacPerl, you would have to decode the hex string. my $styl = pack 'H*', $ARGV[1]; Gero Herrmann Niigata, Japan
- Re: [MacPerl] StyledText data into a record of text and ... John W Baxter
- Re: [MacPerl] StyledText data into a record of text... John W Baxter
- Re: [MacPerl] StyledText data into a record of text... John W Baxter
- Re: [MacPerl] StyledText data into a record of text and ... Detlef Lindenthal
- Re: [MacPerl] StyledText data into a record of text and ... Ronald J Kimball
- Re: [MacPerl] StyledText data into a record of text and ... Detlef Lindenthal
- Re: [MacPerl] StyledText data into a record of text and ... Alan Fry
- Re: [MacPerl] StyledText data into a record of text... John W Baxter
- Re: [MacPerl] StyledText data into a record of text and ... Nobumi Iyanaga
- Re: [MacPerl] StyledText data into a record of text... Gero Herrmann
- Re: [MacPerl] StyledText data into a record of text and ... Bart Lateur
- Re: [MacPerl] StyledText data into a record of text... Nobumi Iyanaga
- Re: [MacPerl] StyledText data into a record of text... John W Baxter
- Re: [MacPerl] StyledText data into a record of text and ... Ronald J Kimball
- Re: [MacPerl] StyledText data into a record of text and ... Alan Fry
- Re: [MacPerl] StyledText data into a record of text and ... Ronald J Kimball
- Re: [MacPerl] StyledText data into a record of text and ... Bart Lateur
- Re: [MacPerl] StyledText data into a record of text and ... Alan Fry
- [MacPerl] How to generate StyledText data and "... Nobumi Iyanaga