Hi Keith..

Do file it as a bug.. either the app is broken or the dictionary needs updating!

Cheers,

Dave

> On 11-February-2019, at 2:08 PM, Keith Irwin <[email protected]> wrote:
> 
> Here’s mine so far:
> 
> tell application "BBEdit"
>       activate
>       try
>               set win to text window 1
>               tell win
>                       set show gutter to false
>                       set show navigation bar to false
>                       set smart quotes to true
>                       set sidebar visible to false
>                       set show line numbers to false
>                       set soft wrap width to 80
>                       set soft wrap text to true
>                       set soft wrap mode to window width
>                       set display magnification to 1.25
>               end tell
>       on error str
>               display alert str
>       end try
> end tell
> 
> A bit of redundancy with activate and setting a win variable, but this is 
> where I left off. I have other scripts for other modes so I don’t worry about 
> toggles in this case.
> 
> Do you think we should report the show status bar property as a bug?
> 
> Keith
> 
>> On Feb 11, 2019, at 6:42 AM, David Rostenne <[email protected]> wrote:
>> 
>> Funny you should ask this as I was looking at someone else’s script to do 
>> just this.. and also ran into issues. The script:
>> 
>> tell application "BBEdit"
>>      tell window 1
>>              set show line numbers to (not show line numbers)
>>              set show gutter to (not show gutter)
>>              set show navigation bar to (not show navigation bar)
>>              -- set show status bar to false
>>              set sidebar visible to false
>>      end tell
>> end tell
>> 
>> If I uncomment the ‘show status bar’ line and run it I get:
>> 
>> error "BBEdit got an error: An unexpected error occurred while processing an 
>> Apple Event (macOS error code: -10000)." number -10000
>> 
>> I use get statements to test with and getting status bar works fine.. but 
>> changing it fails.
>> 
>> Can you share your script? I’m interested in setting up a distraction free 
>> writing mode as well.
>> 
>> Cheers,
>> 
>> Dave
>> 
>>> On 10-February-2019, at 1:35 AM, Keith Irwin <[email protected]> wrote:
>>> 
>>> I thought I’d write a little script to set BBEdit into distraction free 
>>> mode:
>>> 
>>> So far I can:
>>> 
>>> - Hide the nav and gutter and sidebar line numbers
>>> - Set the wrap mode I like
>>> - Set magnification, smart quotes, etc
>>> 
>>> via AppleScript.
>>> 
>>> However, I can’t:
>>> 
>>> - hide the text status bar (the bottom thing), 
>>> - or the right-side scroll bar.
>>> 
>>> - The Text Window properties have a “show status bar” prop — setting this 
>>> generates an error.
>>> 
>>> - Prefs -> Appearance -> Text Status Bar: unchecking all works — 
>>> AppleScript accessible?
>>> 
>>> Question: Is there a way to revert the right-side scroll bar to “auto hide” 
>>> like all the other windows on macOS? (I tried unchecking 'show spelling' or 
>>> ‘find' ticks — no go. Couldn’t find an Expert Pref for it either.)
>>> 
>>> Question: Is there a way to change preferences via AppleScript? Do I need 
>>> to use System Events with key commands or guess property names? (They don’t 
>>> show up in Script Debugger’s explorer or object model).
>>> 
>>> Thanks for any help!
>>> 
>>> Keith
>>> version 12.6 (412025, 64-bit, sandboxed)
>>> 
>>> -- 
>>> This is the BBEdit Talk public discussion group. If you have a 
>>> feature request or need technical support, please email
>>> "[email protected]" rather than posting to the group.
>>> Follow @bbedit on Twitter: <https://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.
>> 
>> -- 
>> This is the BBEdit Talk public discussion group. If you have a 
>> feature request or need technical support, please email
>> "[email protected]" rather than posting to the group.
>> Follow @bbedit on Twitter: <https://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.
> 
> 
> -- 
> This is the BBEdit Talk public discussion group. If you have a 
> feature request or need technical support, please email
> "[email protected]" rather than posting to the group.
> Follow @bbedit on Twitter: <https://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.

-- 
This is the BBEdit Talk public discussion group. If you have a 
feature request or need technical support, please email
"[email protected]" rather than posting to the group.
Follow @bbedit on Twitter: <https://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.

Reply via email to