text
stringlengths 0
15.7k
| source
stringlengths 6
112
|
---|---|
set assembliedFilePath to separatedFilePath as string
|
word2pdf.applescript
|
return assembliedFilePath
|
word2pdf.applescript
|
end assemblyMacOSPath
|
word2pdf.applescript
|
set testTXT to "Jackie Jackie (Spend This Winter With Me)"
|
strings copy.applescript
|
change_case(justTheLetters(testTXT), 0)
|
strings copy.applescript
|
on justTheLetters(inputString)
|
strings copy.applescript
|
set theLetters to "qwertyuiopasdfghjklzxcvbnm"
|
strings copy.applescript
|
set outputString to ""
|
strings copy.applescript
|
repeat with anChar in inputString
|
strings copy.applescript
|
if theLetters contains anChar then set outputString to outputString & anChar
|
strings copy.applescript
|
return outputString
|
strings copy.applescript
|
end justTheLetters
|
strings copy.applescript
|
on change_case(this_text, this_case)
|
strings copy.applescript
|
if this_case is 0 then
|
strings copy.applescript
|
set the comparison_string to "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
|
strings copy.applescript
|
set the source_string to "abcdefghijklmnopqrstuvwxyz"
|
strings copy.applescript
|
set the comparison_string to "abcdefghijklmnopqrstuvwxyz"
|
strings copy.applescript
|
set the source_string to "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
|
strings copy.applescript
|
set the new_text to ""
|
strings copy.applescript
|
set x to the offset of this_char in the comparison_string
|
strings copy.applescript
|
if x is not 0 then
|
strings copy.applescript
|
set the new_text to (the new_text & character x of the source_string) as string
|
strings copy.applescript
|
set the new_text to (the new_text & this_char) as string
|
strings copy.applescript
|
return the new_text
|
strings copy.applescript
|
end change_case
|
strings copy.applescript
|
to makeSwitch at origin given controlSize:controlSize : 0, state:state : 0, tag:tag : missing value, action:action : "switchAction:", target:target : missing value
|
NSButton.applescript
|
tell (current application's NSSwitch's alloc's initWithFrame:{origin, {42, 25}}) -- just size for largest
|
NSButton.applescript
|
its setControlSize:controlSize -- 0-2 or NSControlSize enum
|
NSButton.applescript
|
end makeSwitch
|
NSButton.applescript
|
on switchAction:sender
|
NSButton.applescript
|
set theTag to sender's tag
|
NSButton.applescript
|
if (sender's state as integer) is 1 then
|
NSButton.applescript
|
set theState to "on"
|
NSButton.applescript
|
set theState to "off"
|
NSButton.applescript
|
display dialog "A switch tagged " & theTag & " was turned " & theState & "." buttons {"OK"} default button 1 giving up after 2
|
NSButton.applescript
|
end switchAction:
|
NSButton.applescript
|
to makeButton at origin given controlSize:controlSize : 0, width:width : missing value, title:title : "Button", alternateTitle:alternateTitle : missing value, titleFont:titleFont : missing value, buttonType:buttonType : missing value, bezelStyle:bezelStyle : 1, bordered:bordered : missing value, transparent:transparent : missing value, tag:tag : missing value, action:action : "buttonAction:", target:target : missing value
|
NSButton.applescript
|
if width is in {0, false, missing value} then set width to 0
|
NSButton.applescript
|
tell (current application's NSButton's alloc's initWithFrame:{origin, {width, 40}}) -- old style
|
NSButton.applescript
|
its setTitle:title
|
NSButton.applescript
|
if alternateTitle is not missing value then its setAlternateTitle:alternateTitle
|
NSButton.applescript
|
if titleFont is not missing value then its setFont:titleFont
|
NSButton.applescript
|
its setBezelStyle:bezelStyle -- 1-15 or NSBezelStyle enum
|
NSButton.applescript
|
its setControlSize:controlSize -- 0-3 or NSControlSize enum
|
NSButton.applescript
|
if buttonType is not missing value then its setButtonType:buttonType -- 0-9 or NSButtonType enum
|
NSButton.applescript
|
if bordered is not missing value then its setBordered:bordered
|
NSButton.applescript
|
if transparent is not missing value then its setTransparent:transparent
|
NSButton.applescript
|
if width is 0 then its sizeToFit()
|
NSButton.applescript
|
set userPrefix to "sd"
|
DiGiCo CC Generator.applescript
|
set userCueName to "SD Snapshot "
|
DiGiCo CC Generator.applescript
|
set userShowMIDIInfo to true
|
DiGiCo CC Generator.applescript
|
set userCount to 118 -- The number of snapshot triggers to generate. Do not set above 384.
|
DiGiCo CC Generator.applescript
|
repeat userCount times
|
DiGiCo CC Generator.applescript
|
set q number of newCue to userPrefix & (scene)
|
DiGiCo CC Generator.applescript
|
set command of newCue to control_change
|
DiGiCo CC Generator.applescript
|
if i is less than 129 then
|
DiGiCo CC Generator.applescript
|
set byteOne to 16
|
DiGiCo CC Generator.applescript
|
set byteTwo to i
|
DiGiCo CC Generator.applescript
|
else if i is less than 257 then
|
DiGiCo CC Generator.applescript
|
set byteOne to 17
|
DiGiCo CC Generator.applescript
|
set byteTwo to (i - 128)
|
DiGiCo CC Generator.applescript
|
set byteOne to 18
|
DiGiCo CC Generator.applescript
|
set byteTwo to (i - 256)
|
DiGiCo CC Generator.applescript
|
set channel of newCue to 16
|
DiGiCo CC Generator.applescript
|
set byte two of newCue to byteTwo
|
DiGiCo CC Generator.applescript
|
if userShowMIDIInfo then
|
DiGiCo CC Generator.applescript
|
set q name of newCue to userCueName & (scene) & " (Ch 16 / CC " & byteOne & " - " & byteTwo & ")"
|
DiGiCo CC Generator.applescript
|
set q name of newCue to userCueName & (scene)
|
DiGiCo CC Generator.applescript
|
open location "https://docs.python.org/3/search.html?q=" & argv
|
pydoc3.applescript
|
eject (every disk)
|
Eject Disks.applescript
|
set time_difference to (time to GMT) / hours
|
Script 9–5.applescript
|
if time_difference mod 1 = 0 then
|
Script 9–5.applescript
|
set time_difference to time_difference as integer
|
Script 9–5.applescript
|
if time_difference < 0 then
|
Script 9–5.applescript
|
set time_difference to -time_difference
|
Script 9–5.applescript
|
set the_message to "You are " & time_difference & " hours behind GMT"
|
Script 9–5.applescript
|
else if time_difference > 0 then
|
Script 9–5.applescript
|
set the_message to "You are " & time_difference & " hours ahead of GMT"
|
Script 9–5.applescript
|
set the_message to "Your time zone is GMT"
|
Script 9–5.applescript
|
display dialog the_message
|
Script 9–5.applescript
|
tell application "Money Pro" to activate
|
money_pro.applescript
|
set dialogResult to display dialog "请输入金额:" default answer "" with icon file "Applications:Money Pro.app:Contents:Resources:AppIcon.icns" buttons {"Cancel", "Continue"} default button "Continue"
|
money_pro.applescript
|
if button returned of dialogResult is "Cancel" then return
|
money_pro.applescript
|
set theCost to text returned of dialogResult
|
money_pro.applescript
|
if theCost is equal to "" then
|
money_pro.applescript
|
display notification "因为你他喵的啥也没输入……" with title "AppleScript 已停止"
|
money_pro.applescript
|
set theCostNumber to theCost as number
|
money_pro.applescript
|
display notification "你必须输入数字才行!" with title "AppleScript 已停止"
|
money_pro.applescript
|
set theNote to text returned of (display dialog "请输入项目内容:" default answer ¬
|
money_pro.applescript
|
(linefeed & linefeed & linefeed) with icon file "Applications:Money Pro.app:Contents:Resources:AppIcon.icns")
|
money_pro.applescript
|
tell process "Money Pro"
|
money_pro.applescript
|
click button 2 of group 1 of group 1 of group 1 of window 1
|
money_pro.applescript
|
click pop up button 1 of UI element 1 of row 1 of table 1 of scroll area 1 of window 1
|
money_pro.applescript
|
click (first menu item whose title contains "Discover") of menu 1 of pop up button 1 of UI element 1 of row 1 of table 1 of scroll area 1 of window 1
|
money_pro.applescript
|
click pop up button 1 of UI element 1 of row 2 of table 1 of scroll area 1 of window 1
|
money_pro.applescript
|
click menu item "买买买" of menu 1 of pop up button 1 of UI element 1 of row 2 of table 1 of scroll area 1 of window 1
|
money_pro.applescript
|
click menu item "软件" of menu 1 of menu item "买买买" of menu 1 of pop up button 1 of UI element 1 of row 2 of table 1 of scroll area 1 of window 1
|
money_pro.applescript
|
set value of text field 1 of UI element 1 of row 2 of table 1 of scroll area 1 of window 1 to theCost
|
money_pro.applescript
|
click button 1 of UI element 1 of row 5 of table 1 of scroll area 1 of window 1
|
money_pro.applescript
|
set value of text area 1 of scroll area 1 of UI element 1 of row 6 of table 1 of scroll area 1 of window 1 to theNote
|
money_pro.applescript
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.