Re: Settings for Compare Two Front Documents

2013-11-22 Thread blinde
christopher -

you are such a stud... the assistance you've provided me in this group and 
privately has been invaluable. i know i can look forward to learning 
something from your posts, and seek them out.

let me know if you get tired of appreciation and thanks... in the meantime, 
thank you again for your continued awesomeness.

bruce







On Tuesday, February 28, 2012 3:41:27 PM UTC-8, Christopher Stone wrote:
>
> On Feb 28, 2012, at 12:54, Gribnif wrote:
>
> I frequently use Compare Two Front Documents, rather than Find 
> Differences, because the latter requires that you choose the documents to 
> compare (and I often have over a hundred open at once!)
>
> The problem with CTFD is that there is no way to change the Ignore Spaces 
> settings, like there is for FD. Yes, I know that if I go into FD and change 
> things the way I want them and hit the Compare button, those settings will 
> stick for CTFD, but that is very inconvenient. It also seems to me that 
> this is confusing from a UI perspective, since the settings used by CTFD 
> are not associated with its menu entry.
>
> __
>
> Hey There,
>
> I think I agree with you on this one.
>
> Unlike in the 'sort lines' command vs the 'sort lines' dialog you cannot 
> open the 'find differences' dialog, change settings, dismiss the dialog, 
> and have those new settings work for 'compare front two documents'.
>
> Does anyone know of a way around this? I've tried various modifier key 
> combinations, and can't get CTFD to show the settings dialog.
>
>
> This is what the manual says:
>
> "Performs a Find Differences on the two frontmost text documents, using 
> the same settings currently active for the Find Differences command."
>
> I think you should contact support with a feature request.  Bare Bones 
> Software >
>
> In the meantime you can script it to your liking:
>
> try
> tell *application* "BBEdit"
> *compare* *window* 1 against *window* 2 options ¬
> {case sensitive:true, ignore curly quotes:true, ignore extra spaces:true, 
> ignore 
> leading spaces:true, ignore trailing spaces:true}
> end tell
> on error eMsg number eNum
> set {c, s} to {return, "--"}
> set e to s & c & "Error: " & eMsg & c & s & c & "Error Number: " & eNum & 
> c & s
> *beep*
> *display dialog* e
> end try
>
> If you want more flexibility you can do something like this:
>
> set compOpts to {"All Options: false", "case sensitive:true", "ignore 
> curly quotes:true", "ignore extra spaces:true", "ignore leading 
> spaces:true", "ignore trailing spaces:true"}
>
> tell *application* "BBEdit"
>
>
> tell me to set compOpts to *choose from list* compOpts ¬
> with title "Compare Front Two Documents" with prompt ¬
> "Select Options" default items (*items* 2 thru -1 of compOpts) ¬
> multiple selections allowed true ¬
> with empty selection allowed
>
>
> end tell
>
> Note that this script only demonstrates using choose-from for options and 
> doesn't flesh-out the logics of actually using the items returned.
>
> --
> Best Regards,
> Chris
>
>

-- 
This is the BBEdit Talk public discussion group. If you have a 
feature request or would like to report a problem, please email
"supp...@barebones.com" rather than posting to the group.
Follow @bbedit on Twitter: 

--- 
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 bbedit+unsubscr...@googlegroups.com.
To post to this group, send email to bbedit@googlegroups.com.


Re: Settings for Compare Two Front Documents

2013-05-29 Thread BBunny
Chris, thank you for that script; this has been driving me nuts. Is there 
any way to set additional "ignore" parameters, such as "ignore comments" or 
ignore some other text that I specify?

On Tuesday, February 28, 2012 3:41:27 PM UTC-8, Christopher Stone wrote:
>
> On Feb 28, 2012, at 12:54, Gribnif wrote:
>
> I frequently use Compare Two Front Documents, rather than Find 
> Differences, because the latter requires that you choose the documents to 
> compare (and I often have over a hundred open at once!)
>
> The problem with CTFD is that there is no way to change the Ignore Spaces 
> settings, like there is for FD. Yes, I know that if I go into FD and change 
> things the way I want them and hit the Compare button, those settings will 
> stick for CTFD, but that is very inconvenient. It also seems to me that 
> this is confusing from a UI perspective, since the settings used by CTFD 
> are not associated with its menu entry.
>
> __
>
> Hey There,
>
> I think I agree with you on this one.
>
> Unlike in the 'sort lines' command vs the 'sort lines' dialog you cannot 
> open the 'find differences' dialog, change settings, dismiss the dialog, 
> and have those new settings work for 'compare front two documents'.
>
> Does anyone know of a way around this? I've tried various modifier key 
> combinations, and can't get CTFD to show the settings dialog.
>
>
> This is what the manual says:
>
> "Performs a Find Differences on the two frontmost text documents, using 
> the same settings currently active for the Find Differences command."
>
> I think you should contact support with a feature request.  Bare Bones 
> Software >
>
> In the meantime you can script it to your liking:
>
> try
> tell *application* "BBEdit"
> *compare* *window* 1 against *window* 2 options ¬
> {case sensitive:true, ignore curly quotes:true, ignore extra spaces:true, 
> ignore 
> leading spaces:true, ignore trailing spaces:true}
> end tell
> on error eMsg number eNum
> set {c, s} to {return, "--"}
> set e to s & c & "Error: " & eMsg & c & s & c & "Error Number: " & eNum & 
> c & s
> *beep*
> *display dialog* e
> end try
>
> If you want more flexibility you can do something like this:
>
> set compOpts to {"All Options: false", "case sensitive:true", "ignore 
> curly quotes:true", "ignore extra spaces:true", "ignore leading 
> spaces:true", "ignore trailing spaces:true"}
>
> tell *application* "BBEdit"
>
>
> tell me to set compOpts to *choose from list* compOpts ¬
> with title "Compare Front Two Documents" with prompt ¬
> "Select Options" default items (*items* 2 thru -1 of compOpts) ¬
> multiple selections allowed true ¬
> with empty selection allowed
>
>
> end tell
>
> Note that this script only demonstrates using choose-from for options and 
> doesn't flesh-out the logics of actually using the items returned.
>
> --
> Best Regards,
> Chris
>
>

-- 
This is the BBEdit Talk public discussion group. If you have a 
feature request or would like to report a problem, please email
"supp...@barebones.com" rather than posting to the group.
Follow @bbedit on Twitter: 

--- 
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 bbedit+unsubscr...@googlegroups.com.
To post to this group, send email to bbedit@googlegroups.com.




Re: Settings for Compare Two Front Documents

2012-02-28 Thread Christopher Stone
On Feb 28, 2012, at 12:54, Gribnif wrote:
> I frequently use Compare Two Front Documents, rather than Find Differences, 
> because the latter requires that you choose the documents to compare (and I 
> often have over a hundred open at once!)
> 
> The problem with CTFD is that there is no way to change the Ignore Spaces 
> settings, like there is for FD. Yes, I know that if I go into FD and change 
> things the way I want them and hit the Compare button, those settings will 
> stick for CTFD, but that is very inconvenient. It also seems to me that this 
> is confusing from a UI perspective, since the settings used by CTFD are not 
> associated with its menu entry.
__

Hey There,

I think I agree with you on this one.

Unlike in the 'sort lines' command vs the 'sort lines' dialog you cannot open 
the 'find differences' dialog, change settings, dismiss the dialog, and have 
those new settings work for 'compare front two documents'.

> Does anyone know of a way around this? I've tried various modifier key 
> combinations, and can't get CTFD to show the settings dialog.


This is what the manual says:

"Performs a Find Differences on the two frontmost text documents, using the 
same settings currently active for the Find Differences command."

I think you should contact support with a feature request.  Bare Bones Software 


In the meantime you can script it to your liking:

try
tell application "BBEdit"
compare window 1 against window 2 options ¬
{case sensitive:true, ignore curly quotes:true, ignore 
extra spaces:true, ignore leading spaces:true, ignore trailing spaces:true}
end tell
on error eMsg number eNum
set {c, s} to {return, "--"}
set e to s & c & "Error: " & eMsg & c & s & c & "Error Number: " & eNum 
& c & s
beep
display dialog e
end try

If you want more flexibility you can do something like this:

set compOpts to {"All Options: false", "case sensitive:true", "ignore curly 
quotes:true", "ignore extra spaces:true", "ignore leading spaces:true", "ignore 
trailing spaces:true"}

tell application "BBEdit"

tell me to set compOpts to choose from list compOpts ¬
with title "Compare Front Two Documents" with prompt ¬
"Select Options" default items (items 2 thru -1 of compOpts) ¬
multiple selections allowed true ¬
with empty selection allowed

end tell

Note that this script only demonstrates using choose-from for options and 
doesn't flesh-out the logics of actually using the items returned.

--
Best Regards,
Chris

-- 
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 bbedit@googlegroups.com
To unsubscribe from this group, send email to
bbedit+unsubscr...@googlegroups.com
For more options, visit this group at

If you have a feature request or would like to report a problem, 
please email "supp...@barebones.com" rather than posting to the group.
Follow @bbedit on Twitter: 


Settings for Compare Two Front Documents

2012-02-28 Thread Gribnif
I frequently use Compare Two Front Documents, rather than Find Differences, 
because the latter requires that you choose the documents to compare (and I 
often have over a hundred open at once!)

The problem with CTFD is that there is no way to change the Ignore Spaces 
settings, like there is for FD. Yes, I know that if I go into FD and change 
things the way I want them and hit the Compare button, those settings will 
stick for CTFD, but that is very inconvenient. It also seems to me that 
this is confusing from a UI perspective, since the settings used by CTFD 
are not associated with its menu entry.

Does anyone know of a way around this? I've tried various modifier key 
combinations, and can't get CTFD to show the settings dialog.

-- 
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 bbedit@googlegroups.com
To unsubscribe from this group, send email to
bbedit+unsubscr...@googlegroups.com
For more options, visit this group at

If you have a feature request or would like to report a problem, 
please email "supp...@barebones.com" rather than posting to the group.
Follow @bbedit on Twitter: