text stringlengths 0 15.7k | source stringlengths 6 112 |
|---|---|
if not my windowWaitUntil_FrontIS({windowName:"Select Menu"}) then error "Timed out waiting for 'Select Menu' window." number 1024 | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
select (first row of table 1 of scroll area 1 of window 1 whose value of static text 1 is menuName of oneMenuRec) | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
my fmGUI_ObjectClick_AffectsWindow(button "Select" of window 1) | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
if debugMode then my logConsole(ScriptName, "Select Menu failed ( need to create ): " & errMsg) | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
my fmGUI_ObjectClick_AffectsWindow(first button of window 1 whose description starts with "New Menu") | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
if my isNullOrEmpty(menuBasedOn of oneMenuRec) or menuBasedOn of oneMenuRec is "none" then | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
click (first checkbox of window 1 whose name contains "empty") | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
click (first checkbox of window 1 whose name contains "standard") | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
select (first row of table 1 of scroll area 1 of window 1 whose value of static text 1 is menuBasedOn of oneMenuRec) | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
my fmGUI_ObjectClick_AffectsWindow(button "OK" of window 1) | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
if not my windowWaitUntil_FrontIS({windowName:"Edit Custom Menu"}) then error "Timed out waiting for 'Edit Custom Menu' window to OPEN" number 1024 | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
if debugMode then my logConsole(ScriptName, menuName of oneMenuRec & " - " & nextCommand & " (so far)") | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
if nextCommand is not "DONE" then | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
if (builtinMenu of oneMenuRec) then | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
if (value of static text 1 of (first row of menuTable whose selected is true)) is equal to (menuName of oneMenuRec) then set nextCommand to "DONE" | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
if debugMode then my logConsole(ScriptName, "Did not edit MENU, since it is using the correct built-in menu: " & menuName of oneMenuRec) | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
if name of window 1 is not "Edit Custom Menu" then | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
my fmGUI_ObjectClick_AffectsWindow(menuEditButton) | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
if debugMode then my logConsole(ScriptName, "About to edit menu: " & menuName of oneMenuRec) | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
set menuEditResult to my fmGUI_CustomMenus_Menu_Edit({CustomMenu:oneMenuRec}) | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
if menuEditResult is true then | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
if name of window 1 is "Select Menu" then | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
delay 0.5 --seconds | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
set windowClosed to windowWaitUntil_FrontIsNOT({windowName:"Select Menu", waitCycleDelaySeconds:0.5, waitCycleMax:50}) | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
if not windowClosed then error "Timed out waiting for 'Select Menu' window to CLOSE after we edited/created a Custom Menu '" & menuName of oneMenuRec & "' in order to select it to add to the set" number 1024 | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
if nextCommand is "REPLACE" then | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
click menuRemoveButton | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
if debugMode then my logConsole(ScriptName, "Removed wrong menu after replacing it with: " & menuName of oneMenuRec) | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
if debugMode then my logConsole(ScriptName, "finished looping over desired menus") | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
repeat while (count of rows of menuTable) is greater than menuNeededCount | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
select row (menuNeededCount + 1) of menuTable | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
click (first button of window 1 whose name starts with "Remove") | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
set errMsg to "unable to fmGUI_CustomMenus_MenuSet_CreateUpdate - " & errMsg | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
end fmGUI_CustomMenus_MenuSet_CreateUpdate | WIP_fmGUI_CustomMenus_MenuSet_CreateUpdate.applescript |
click menu item 16 of menu 7 of menu bar 1 | Pinboard copy.applescript |
set gSubject to name of i | Mail url via Outlook copy.scpt |
set gEmailBody to "[" & name of i & "]( " & URL of i & " )" -- in markdown format | Mail url via Outlook copy.scpt |
set gEmailBody to name of i & " -- " & URL of i -- in user friendly format | Mail url via Outlook copy.scpt |
set search_url to "https://meet.google.com/" | find-url-and-send-keystroke.applescript |
if URL of t starts with search_url then | find-url-and-send-keystroke.applescript |
set active tab index of w to i | find-url-and-send-keystroke.applescript |
set libPath to POSIX path of (path to library folder from user domain) | Get%20List%20of%20Finder%20Tags.applescript |
set libPath to current application's NSString's stringWithString:libPath | Get%20List%20of%20Finder%20Tags.applescript |
set prefsPath to libPath's stringByAppendingPathComponent:"SyncedPreferences/com.apple.finder.plist" | Get%20List%20of%20Finder%20Tags.applescript |
set {theStuff, theError} to current application's NSPropertyListSerialization's propertyListWithData:theData options:0 |format|:(missing value) |error|:(reference) | Get%20List%20of%20Finder%20Tags.applescript |
if theStuff is missing value then error theError's localizedDescription() as text | Get%20List%20of%20Finder%20Tags.applescript |
set theTags to (theStuff's valueForKeyPath:"values.FinderTagDict.value.FinderTags.n") | Get%20List%20of%20Finder%20Tags.applescript |
set theTags to theTags's sortedArrayUsingSelector:"localizedStandardCompare:" | Get%20List%20of%20Finder%20Tags.applescript |
set tagList to theTags as list | Get%20List%20of%20Finder%20Tags.applescript |
set question to display dialog "Show or hide hidden files?" & return & "Don't that forget this will relaunch Finder." buttons {"Show hidden files", "Hide hidden files", "Cancel"} | Show%20Hide%20Hidden%20Files.applescript |
set theAnswer to button returned of result | Show%20Hide%20Hidden%20Files.applescript |
if theAnswer is "Show hidden files" then | Show%20Hide%20Hidden%20Files.applescript |
do shell script "defaults write com.apple.Finder AppleShowAllFiles TRUE && killall Finder" | Show%20Hide%20Hidden%20Files.applescript |
if theAnswer is "Hide hidden files" then | Show%20Hide%20Hidden%20Files.applescript |
do shell script "defaults write com.apple.Finder AppleShowAllFiles FALSE && killall Finder" | Show%20Hide%20Hidden%20Files.applescript |
if theAnswer is "Cancel" then | Show%20Hide%20Hidden%20Files.applescript |
make new inbox task with properties {name:activeName, note:activeURL} | Add URL to OmniFocus.applescript |
tell process "Finder" to set isDesktopFocused to focused of scroll area 1 # scroll area 1 === desktop "window" | cleanDesktop-command-opt-2.applescript |
if isDesktopFocused is equal to true and autohide_status is equal to false | cleanDesktop-command-opt-2.applescript |
tell menu 1 of menu item "Clean Up By" of menu 1 of menu bar item "View" of menu bar 1 | cleanDesktop-command-opt-2.applescript |
click menu item "Kind" | cleanDesktop-command-opt-2.applescript |
if isDesktopFocused is equal to true and autohide_status is equal to false then set autohide of dock preferences to false | cleanDesktop-command-opt-2.applescript |
set file_id to open for access file "Macintosh HD:Users:hanaan:work.txt"with write permission | Script 17-8.applescript |
write "abcdefghij" to file_id for 5 | Script 17-8.applescript |
set desiredPosition to {0.333, 0.0} | 9 - ⬛️🟨🟨 … Right 2|3.scpt |
set addr to "https://paperpile.com/app" | SelectOrOpen_paperpile.applescript |
property type_list : {"JPEG", "TIFF", "PNGf", "8BPS", "BMPf", "GIFf", "PDF ", "PICT"} | add_border.applescript |
property extension_list : {"jpg", "jpeg", "tif", "tiff", "png", "psd", "bmp", "gif", "jp2", "pdf", "pict", "pct", "sgi", "tga"} | add_border.applescript |
property typeIDs_list : {"public.jpeg", "public.tiff", "public.png", "com.adobe.photoshop-image", "com.microsoft.bmp", "com.compuserve.gif", "public.jpeg-2000", "com.adobe.pdf", "com.apple.pict", "com.sgi.sgi-image", "com.truevision.tga-image"} | add_border.applescript |
property padding : 4 --set interior border width to 2 pixel on each side - total of 4 pixels | add_border.applescript |
set {this_filename, this_extension, this_filetype, this_typeID} to {name, name extension, file type, type identifier} of item_info | add_border.applescript |
set {this_filename, this_extension, this_filetype, this_typeID} to {"", "", "", ""} | add_border.applescript |
set this_path to quoted form of POSIX path of this_item | add_border.applescript |
if ((this_filetype is in type_list) or (this_extension is in extension_list) or (this_typeID is in typeIDs_list)) then | add_border.applescript |
set theRes to (do shell script (("sips -g pixelHeight -g pixelWidth " & this_path as string) & " | tail -2")) | add_border.applescript |
set {y, x} to {last word of first paragraph, last word of last paragraph} of theRes | add_border.applescript |
set pixelHeight to y + padding | add_border.applescript |
set pixelWidth to x + padding | add_border.applescript |
do shell script "sips " & this_path & " -p " & (pixelHeight as integer) & " " & (pixelWidth as integer) & " --padColor ffffff -i" | add_border.applescript |
display dialog "Droplet ERROR: " & errStr & ": " & (errorNumber as text) & "on file " & this_filename | add_border.applescript |
if x is greater than y then -- set outer border width to 4% of shortest edge in pixels | add_border.applescript |
set border to padding + (padding / 100 * y) | add_border.applescript |
set border to padding + (padding / 100 * x) | add_border.applescript |
set pixelHeight to y + border | add_border.applescript |
set pixelWidth to x + border | add_border.applescript |
set theSIP to do shell script "sips " & this_path & " -p " & (pixelHeight as integer) & " " & (pixelWidth as integer) & " --padColor 000000 -i" | add_border.applescript |
set deadorlive to application "xxx.app" is running | keep_appwake.scpt |
if deadorlive is false then | keep_appwake.scpt |
tell application "xxx.app" to quit | keep_appwake.scpt |
tell application "xxx.app" | keep_appwake.scpt |
tell home | Script 5-5.applescript |
tell container window | Script 5-5.applescript |
set bounds to {40, 40, 800, 800} | Script 5-5.applescript |
set current view to list view | Script 5-5.applescript |
tell its list view options -- Equivalent to: tell list view options of it | Script 5-5.applescript |
set calculates folder sizes to true | Script 5-5.applescript |
set sort column to column id modification date column | Script 5-5.applescript |
on format_phone(the_phone_number) | Script 18-5.applescript |
return "(" & (text 1 thru 3 of the_phone_number) & ") " & (text 4 thru 6 of the_phone_number) & "-" & (text 7 thru 10 of the_phone_number) | Script 18-5.applescript |
end format_phone | Script 18-5.applescript |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.