With a simple Applescript, you can perform the sort Patrick describes
starting from the current cursor position. The following script gets the
cursor position, creates the grep pattern for the sort using the cursor
position as the start point, then performs the sort.
*tell* *application* "BBEdit"
*set* theColumn *to* startColumn *of* selection
*set* thePattern *to* "^.{" & theColumn & "}(.+?)$"
*sort lines* *text* 1 *of* *text document* 1 sorting options {match pattern:
thePattern, sort subpattern key:*use_subpattern*, sort subpattern:"\\1"} output
options {replacing target:*true*}
*end* *tell*
On Saturday, June 17, 2017 at 12:23:51 PM UTC-4, Dingoe wrote:
>
> is there a way to sort lines as with texpad?
>
>
>
> <https://lh3.googleusercontent.com/-HpMhcSzwNjM/WUVUeLFRkuI/AAAAAAAEhgc/AgtQRujH4OUQAcL1taPc95l6dbUBC3_8wCLcBGAs/s1600/Region%2Bcapture%2B1.png>
>
--
This is the BBEdit Talk public discussion group. If you have a
feature request or would like to report a problem, please email
"[email protected]" rather than posting to the group.
Follow @bbedit on Twitter: <http://www.twitter.com/bbedit>
---
You received this message because you are subscribed to the Google Groups
"BBEdit Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/bbedit.