2

Is there a way to achieve this:

nested slides

when creating a presentation programatically via Applescript?

As an aside the code I have now looks like this:

tell application "Keynote"
    set themeprops to {theme:"Gradient", slideSize:{800, 600}}
    set s to make new slideshow at end of slideshows with data themeprops
    repeat with content in {"a", "b", "c", "d"}
        tell s
            set titleMaster to item 7 of master slides -- using magic number :(
            set newslide to make new slide
            tell current slide
                set title to content
                set master to titleMaster
            end tell
        end tell
    end repeat
end tell

For ideas about workarounds: My app will generate this code from a Markdown document, thus enabling writing your presentation in Markdown. I hoped that different levels of headings could mea different levels of nesting in the final output.

Jakub Hampl
  • 39,863
  • 10
  • 77
  • 106
  • I've checked this out and it seems that the element 'slides' does not have a property to set its parent slide. So applescript won't technically let you do this. A potential workaround would be to create a template and with applescript open that template. – Kassym Dorsel Oct 21 '11 at 13:35
  • Well it definitely doesn't have it publicly, I was wondering about either some sort of unpublished property or some really clever workaround. – Jakub Hampl Oct 21 '11 at 16:26
  • Actually I have a [very similar question](http://apple.stackexchange.com/q/78898/26522) on apple.stackexchange now. – myhd Jan 16 '13 at 10:29

0 Answers0