diff --git a/README.md b/README.md index 69c0223..8aa8de8 100644 --- a/README.md +++ b/README.md @@ -10,6 +10,8 @@ erase_presenter_notes - erases every speaker note in the entire deck. Useful whe presenter_notes_to_pages - Exports the speaker notes of decks dropped onto it as individual Pages files (one for each Keynote file). Useful for folks who just want to review their notes, for handing off to translators, closed captionists, ASL translators, etc. Good example (thanks to Sal!) of how to deal with single file vs. package files and processing of multiple dropped files. grids - creates a grid of lines on the current slide of the frontmost Keynote deck +golden_ratio_grid - draws a Golden Ratio grid using successive divisions by \u03c6 + from the top-left corner of the current slide More to come. diff --git a/golden_ratio_grid b/golden_ratio_grid new file mode 100644 index 0000000..ecf3e22 --- /dev/null +++ b/golden_ratio_grid @@ -0,0 +1,34 @@ +-- ----------------------------------------------------------------------------- +-- creates a Golden Ratio grid on the current slide of the frontmost Keynote deck +-- +-- lines are positioned according to the Golden Ratio and use a 1 point grey stroke +-- +-- As with all AppleScripts I use - many thanks and most of the credit goes to Sal Soghoian +-- +property phi : 1.618034 +property strokeGrey : {32768, 32768, 32768} +property strokeWeight : 1 + +tell application "Keynote" + activate + tell document 1 + set w to its width + set h to its height + tell current slide + set xPos to w / phi + repeat while xPos > 4 + make new line with properties {start point:{xPos, 0}, end point:{xPos, h}, reflection showing:false, stroke color:strokeGrey, stroke weight:strokeWeight} + set xPos to xPos / phi + end repeat + + set yPos to h / phi + repeat while yPos > 4 + make new line with properties {start point:{0, yPos}, end point:{w, yPos}, reflection showing:false, stroke color:strokeGrey, stroke weight:strokeWeight} + set yPos to yPos / phi + end repeat + end tell + end tell +end tell + +-- ------------------- +-- Nothing follows.