Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Applescript > Re: Applescript...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 16 of 16 Topic 1609 of 1636
Post > Topic >>

Re: Applescript to work with text. I'm stuck.

by Fuddled <fuddled@[EMAIL PROTECTED] > May 7, 2008 at 06:45 AM

In article <jollyroger-E77201.22415805052008@[EMAIL PROTECTED]
>, Jolly
Roger <jollyroger@[EMAIL PROTECTED]
> wrote:

> In article <050520081954213508%jerrykindall@[EMAIL PROTECTED]
>,
>  Jerry Kindall <jerrykindall@[EMAIL PROTECTED]
> wrote:
> 
> > In article <jollyroger-687940.20565905052008@[EMAIL PROTECTED]
>, Jolly
> > Roger <jollyroger@[EMAIL PROTECTED]
> wrote:
> > 
> > > The point is if you have a collection of files and you want to use 
> > > AppleScript to change some text in them, no text editor is needed.
If 
> > > you do this in pure AppleScript instead, it's quick as lightning.
You 
> > > said you'd try the script I sent you - did you try it?  You'll find
it's 
> > > faster than any script that uses a BBEdit window to change text.
This is 
> > > because writing the AppleScript to control the text editor will only

> > > slow things down - it takes time for the text editor to draw changes
to 
> > > the window and so on.
> > 
> > I think you've wandered off into the weeds a little.  You can't select
> > some text and wrap it in tags using a batch process; by its very
nature
> > the task is interactive.
> 
> I'm not the one trying to use a batch process to wrap text in tags. So 
> it's not *me* who is "off into the weeds", but the original poster.  I'm

> just showing the OP ways to do what he has stated he wants to do.  ; )
> 
> > The real question is why the original poster is trying to write
scripts
> > to wrap text in HTML tags rather than just using BBEdit's HTML tools,
> > which already do that and more.  You can even assign keyboard
shortcuts
> > to them, so you just hit, say, Ctrl-I and it wraps the selected text
in
> > <i> and </i> tags.  No script is needed.
> 
> Yep. And, as I stated, BBEdit has excellent search and replace 
> facilities as well.


I'm not sure where the 'batch' comes in. I'm preparing (e.g.) a
paragraph (amongst many others) and I find a string that needs to be in
italics ­ and that was my question: how to quickly pop tags round a
selection. I'm the one who has to do the selection here, there's no
batch about it, so search-and-replace. Each occurence of italics has to
be selected, by human decision.

I simply asked how to write a script that does that. If ­ as Jerry
Kindall says ­ there's a way to do this with BBEdit's "HTML tools" then
I guess I should examine the manual. Or he can drift OT and tell me
here! Though I now have a script that does it; maybe all I've done is
duplicate a BBEdit function?

I'm really appreciative for the help, but Jolly Roger's Convert script
had many more features than I need. I know what file it is I want,
because I'm working in it, and I don't want to save to a new file, just
pop those tags around a selection, manually. That's it.

Anyway ­ thanks to all who responded, and I've now learned more than
I'd expected.
 




 16 Posts in Topic:
Applescript to work with text. I'm stuck.
Fuddled <fuddled@[EMAI  2008-05-04 09:41:44 
Re: Applescript to work with text. I'm stuck.
J. Stewart <cfnzrpu@[E  2008-05-04 06:50:50 
Re: Applescript to work with text. I'm stuck.
Fuddled <fuddled@[EMAI  2008-05-05 02:28:24 
Private Message
   2008-05-04 20:23:37 
Re: Applescript to work with text. I'm stuck.
J. Stewart <cfnzrpu@[E  2008-05-04 07:22:58 
Private Message
   2008-05-04 07:52:28 
Re: Applescript to work with text. I'm stuck.
Fuddled <fuddled@[EMAI  2008-05-05 02:38:32 
Re: Applescript to work with text. I'm stuck.
Jolly Roger <jollyroge  2008-05-04 14:08:18 
Re: Applescript to work with text. I'm stuck.
Fuddled <fuddled@[EMAI  2008-05-05 02:44:26 
Re: Applescript to work with text. I'm stuck.
Jolly Roger <jollyroge  2008-05-04 22:13:39 
Re: Applescript to work with text. I'm stuck.
Fuddled <fuddled@[EMAI  2008-05-05 12:09:26 
Private Message
   2008-05-05 08:17:42 
Re: Applescript to work with text. I'm stuck.
Jolly Roger <jollyroge  2008-05-05 20:56:59 
Re: Applescript to work with text. I'm stuck.
Jerry Kindall <jerryki  2008-05-05 19:54:21 
Re: Applescript to work with text. I'm stuck.
Jolly Roger <jollyroge  2008-05-05 22:41:58 
Re: Applescript to work with text. I'm stuck.
Fuddled <fuddled@[EMAI  2008-05-07 06:45:58 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sun Jul 6 10:36:54 CDT 2008.