Sha256: 92ad87c676f8201eb65906cf610192e851213858e34ed3d671a0a8ca436bbd18
Contents?: true
Size: 980 Bytes
Versions: 2
Compression:
Stored size: 980 Bytes
Contents
module Asposeslidesjava module CreatingSvg def initialize() data_dir = File.dirname(File.dirname(File.dirname(File.dirname(__FILE__)))) + '/data/' # Instantiate Presentation class that represents the presentation file pres = Rjb::import('com.aspose.slides.Presentation').new(data_dir + 'demo.pptx') # Getting last slide index last_slide_position = pres.getSlides().size() #Iterating through every presentation slide and generating SVG image i = 0 while i < last_slide_position # Accessing Slides slide = pres.getSlides().get_Item(i) # Getting and saving the slide SVG image slide.writeAsSvg(Rjb::import('java.io.FileOutputStream').new(data_dir + "SvgImage#{i}.svg")) i +=1 end puts "Created SVG images, please check output files." end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
asposeslidesjava-0.0.2 | lib/asposeslidesjava/Slides/creatingsvg.rb |
asposeslidesjava-0.0.1 | lib/asposeslidesjava/Slides/creatingsvg.rb |