Ejemplo n.º 1
0
class MyTest(unittest.TestCase):

    def setUp(self):
        unittest.TestCase.setUp(self)
        self.myclass = Presentation()

    def tearDown(self):
        unittest.TestCase.tearDown(self)
        del( self.myclass )

    def test_should_always_pass_cleanly(self):
        """Should always pass cleanly."""
        pass

    def test_myclass_existence(self):
        """Check that myclass exists"""
        result = self.myclass

        # See if the self.myclass object exists
        self.assertTrue(result)

    def test_save(self):
        """Check that save operates cleanly"""

        self.myclass = Presentation()
        
        self.myclass.save( filename=os.path.join(here,'my_ppt'), launch=False)
Ejemplo n.º 2
0
class MyTest(unittest.TestCase):
    def setUp(self):
        unittest.TestCase.setUp(self)
        self.myclass = Presentation()

    def tearDown(self):
        unittest.TestCase.tearDown(self)
        del (self.myclass)

    def test_should_always_pass_cleanly(self):
        """Should always pass cleanly."""
        pass

    def test_myclass_existence(self):
        """Check that myclass exists"""
        result = self.myclass

        # See if the self.myclass object exists
        self.assertTrue(result)

    def test_save(self):
        """Check that save operates cleanly"""

        self.myclass = Presentation()

        self.myclass.save(filename=os.path.join(here, 'my_ppt'), launch=False)
Ejemplo n.º 3
0
from odpslides.presentation import Presentation

P = Presentation(grad_start_color='ff9999',
                 grad_end_color="#ffffff",
                 grad_angle_deg=45,
                 grad_draw_style='linear',
                 footer='Gaea Trilogy',
                 show_date=True)

P.add_title_chart(title='Titan, Wizard, Demon', subtitle='John Varley')

P.add_titled_image(title='Locus, Nebula, Hugo',
                   image_file='Titan.jpg',
                   image_2_file='Wizard.jpg',
                   image_3_file='Demon.jpg',
                   pcent_stretch_center=80,
                   pcent_stretch_content=80)

P.save(filename='varley.odp', launch=1)
Ejemplo n.º 4
0
from odpslides.presentation import Presentation

P = Presentation(grad_start_color='ff9999', grad_end_color="#ffffff", 
                 grad_angle_deg=45, grad_draw_style='rectangle',
                 footer='Gaea Trilogy', show_date=True)

P.add_title_chart( title='Titan, Wizard, Demon', subtitle='John Varley')


P.add_titled_image( title='Locus, Nebula, Hugo', image_file='Titan.jpg',
                    image_2_file='Wizard.jpg', image_3_file='Demon.jpg',
                    pcent_stretch_center=80, pcent_stretch_content=80)

P.save( filename='varley.odp', launch=1 )
Ejemplo n.º 5
0
from odpslides.presentation import Presentation

P = Presentation(background_color='darkseagreen', footer="slan example")

P.add_title_chart( title='Slan, from 1946', subtitle='A. E. van Vogt')

P.add_titled_outline_chart( title='Slans Are Evolved Humans', outline="""
The Slan are named after Samuel Lann
    The creator of Slans
There are two kinds of Slans
    With tendrils
        can read minds of ordinary humans
        can communicate telepathically with other Slans
    Without tendrils
        super intelligent
        no telepathy
        can hide thoughts from other Slan""")

P.add_titled_image( title='Ninth Big Printing', image_file='slan.png',
                    pcent_stretch_center=80, pcent_stretch_content=80)

P.save( filename='slan.odp', launch=1 )
Ejemplo n.º 6
0
                 footer='Foundation Trilogy',
                 show_date=True,
                 date_font_color='i',
                 footer_font_color='i',
                 page_number_font_color="i")

P.add_title_chart(title='The Foundation Series', subtitle='Isaac Asimov')

P.add_titled_text_and_image(text_location='top',
                            title='"Best All-Time Series" in 1966',
                            title_font_color='',
                            outline=[
                                "Psychohistory", "    Hari Seldon's Invention",
                                "R. Daneel Olivaw", "    Humanity's Protector"
                            ],
                            text_font_color='dm',
                            image_file='Foundation_Series.jpg',
                            keep_aspect_ratio=True,
                            pcent_stretch_center=50,
                            pcent_stretch_content=100)

P.add_titled_image(title='Two Prequels, Two Sequels, Many Reprints',
                   image_file='Foudation_Series_v3.jpg',
                   image_2_file='foundation_x7.png',
                   image_3_file='Foudation_Series_v2.jpg',
                   image_4_file='r_daneel_olivaw.jpg',
                   pcent_stretch_center=80,
                   pcent_stretch_content=80)

P.save(filename='asimov.odp', launch=1)