On 12.05.2010 09:47, Roland Küffner wrote:
Am 12.05.2010 um 02:06 schrieb wallabadah:
I have not used AppleScript before - but it appears to be an ideal
solution in this case. I started by recording, then a little bit of
editing. I prefer to have the wrap around option turned off in this
case, and used a regular expression for finding whitespace-only lines.
Here's my version for the sake of completeness:
'next blank line' - assigned to control-option-down arrow
tell application "BBEdit"
find "^[[:space:]]*$" searching in (text 1 of window 1) options
{search mode:grep, starting at top:false, wrap around:false,
backwards:false, case sensitive:false, match words:false, extend
selection:false} with selecting match
end tell
Just to tinker a little further on this. I tried your pattern. It seems that it
has problems catching the last line break on multiple empty lines (I have no
idea why). I tried some variations of the pattern and found this to be more to
my liking:
(?s)^\s+
Together with the
select insertion point after found object of result
line this takes me directly to column zero of the next block. Exactly what I
wanted - of course YMMV on that.
Thanks for bringing this topic up. I already used this new custom shortcuts
several times since yesterday :-)
Roland
Hello all!
I would not bother with an Apple script. My suggestion: do it with
BBEdit short cuts (and BBEdit is famous for it, why not use it?):
1. select the line feed of a not empty line and drag your mouse to the
beginning of the next empty line. Now the end of the full line and the
empty line are selected.
2. Hit cmd + E (Now the search pattern is into the find field)
3. Hit cmd + G (for the next empty line)
4. Hit cmd + shift + G (for the previous empty line)
Greetings from Munich
marek
--
You received this message because you are subscribed to the
"BBEdit Talk" discussion group on Google Groups.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/bbedit?hl=en
If you have a feature request or would like to report a problem,
please email "[email protected]" rather than posting to the group.