Skip to content

Instantly share code, notes, and snippets.

@ytomino
Last active January 3, 2016 14:29
Show Gist options
  • Save ytomino/8476213 to your computer and use it in GitHub Desktop.
Save ytomino/8476213 to your computer and use it in GitHub Desktop.
BBAutoCompleteに補完候補を追加する方法
-- BBAutoComplete.scptを編集する
...
on makeAlsoTexts()
tell application "TextWrangler"
set theResult to {}
-- this will include the first document from window 1, but that's OK
repeat with w in windows
...
end repeat
-- ここから追加
set the_doc to front text document
if on disk of the_doc then
set the_doc_name to name of the_doc
if (the_doc_name ends with ".拡張子") or ... then
-- ここで補完候補を配列theResultに追加
set theResult to theResult & {"ONEWORD", "ANOTHERWORD"}
end if
end if
-- ここまで追加
return theResult
end tell
end makeAlsoTexts
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment