예제 #1
0
class evolve(evolve_base):
    font = aggdraw.Font("white", "./fonts/calibrib.ttf", 46)
    text_english = [u"PSYDEH and Global Citizens:", u"growing trees with rural and", u"indigenous partners in Mexico."]
    text_spanish = [u"PSYDEH y Ciudadanos del Mundo:", u"tirando paredes y plantando arboles junto",
                    u"con nuestros socios ind\u00EDgenas en M\u00e9xico."]
    phrase1 = {languages.ENGLISH: [Phrases().makeImage_runnable(text_english, font, 50), 1.0],
               languages.SPANISH: [Phrases().makeImage_runnable(text_spanish, font, 50),
                                   Helpers.getLetterRatio(text_english, text_spanish)]}
    text_english = [u"Visit PSYDEH's website for more", u"information: "]
    text_spanish = [u"Para m\u00e1s informaci\u00f3n visita la", u"p\u00e1gina web de PSYDEH: "]
    phrase2 = {languages.ENGLISH: [Phrases().makeImage_runnable(text_english, font, 50), 1.0],
               languages.SPANISH: [Phrases().makeImage_runnable(text_spanish, font, 50),
                                   Helpers.getLetterRatio(text_english, text_spanish)]}

    text_english = [u"www.psydeh.com"]
    text_spanish = [u"www.psydeh.com"]
    phrase3 = {languages.ENGLISH: [Phrases().makeImage_runnable(text_english, font, 50), 1.0],
               languages.SPANISH: [Phrases().makeImage_runnable(text_spanish, font, 50),
                                   Helpers.getLetterRatio(text_english, text_spanish)]}

    def __init__(self, start):
        self.startTime = start
        self.stopTime = start + 265
        self.list = []
        self.list.append(still(start))
        self.list.append(text(start, 265, self.phrase1, (310, 50)))
        self.list.append(text(start + 85, 195, self.phrase2, (310, 600)))
        self.list.append(
            text(start + 85 + 44, 151, self.phrase3, (310 + 252 + 1 * 210, 600 + 50),
                 slow=0, color=(80, 147, 205)))
        self.list.append(Transitions.blender(None, Image.open("./images/base16_spanish.png"), start + 225, 40))
예제 #2
0
class evolve(evolve_base):
    renderer = TextTRenderer()
    font = "Calibri Bold"
    text_english = [u"Where walls once existed, indigenous women",
                    u"unite around a strong, growing tree."]
    text_spanish = [u"En donde las paredes alguna vez existieron,",
                    u"las semillas se plantan y un \u00e1rbol crece."]

    phrase1 = {Languages.ENGLISH: [renderer.makeImage_runnable(text_english, font, 42, 60), 1.0],
               Languages.SPANISH: [renderer.makeImage_runnable(text_spanish, font, 42, 60),
                                   Helpers.getLetterRatio(text_english, text_spanish)]}

    text_english = [u"This tree", u"symbolizes", u"our work", u"to empower", u"sustainable", u"development."]
    text_spanish = [u"Este \u00e1rbol,", u"simboliza nuestro", u"trabajo y nuestra",
                    u"met\u00e1fora de", u"sustentabilidad.",
                    ]

    phrase2 = {Languages.ENGLISH: [renderer.makeImage_runnable(text_english, font, 42, 60), 1.0],
               Languages.SPANISH: [renderer.makeImage_runnable(text_spanish, font, 42, 60),
                                   Helpers.getLetterRatio(text_english, text_spanish)]}

    def __init__(self, start):
        self.startTime = start
        self.stopTime = start + 333
        self.list = []
        self.list.append(seednwater(start))
        self.list.append(growing(start + 72))
        self.list.append(text(start + 72, 70, 50, self.phrase1))
        self.list.append(text(start + 194, 70, 50, self.phrase2, scrolling_speed=2))
        self.list.append(
            Transitions.pageFlip(cairo.ImageSurface.create_from_png("./sequences/tree/frame200.png"),
                                 cairo.ImageSurface.create_from_png("./images/dreaming.png"),
                                 start + 313, 20))
예제 #3
0
class evolve(evolve_base):
    font = aggdraw.Font("white", "./fonts/calibrib.ttf", 56)

    text_english = [
        u"Where walls once existed, seeds are planted", u"and a tree grows."
    ]
    text_spanish = [
        u"En donde las paredes alguna vez existieron,",
        u"las semillas se plantan y un \u00e1rbol crece."
    ]

    phrase1 = {
        languages.ENGLISH:
        [Phrases().makeImage_runnable(text_english, font, 60), 1.0],
        languages.SPANISH: [
            Phrases().makeImage_runnable(text_spanish, font, 60),
            Helpers.getLetterRatio(text_english, text_spanish)
        ]
    }

    text_english = [
        u"This tree, our", u"metaphor for", u"sustainability,",
        u"symbolizes our", u"work."
    ]
    text_spanish = [
        u"Este \u00e1rbol,",
        u"simboliza nuestro",
        u"trabajo y nuestra",
        u"met\u00e1fora de",
        u"sustentabilidad.",
    ]

    phrase2 = {
        languages.ENGLISH:
        [Phrases().makeImage_runnable(text_english, font, 60), 1.0],
        languages.SPANISH: [
            Phrases().makeImage_runnable(text_spanish, font, 60),
            Helpers.getLetterRatio(text_english, text_spanish)
        ]
    }

    def __init__(self, start):
        self.startTime = start
        self.stopTime = start + 340
        self.list = []
        self.list.append(seeding(start))
        self.list.append(watering(start + 50))
        self.list.append(growing(start + 100))
        self.list.append(text(start + 80, 70, 50, self.phrase1))
        self.list.append(text(start + 200, 70, 50, self.phrase2))
        self.list.append(
            Transitions.pageFlip(
                Image.open("./images/base7.png"),
                Image.open("./images/base10.png").convert("RGBA"), start + 320,
                20))
예제 #4
0
class evolve(evolve_base):
    renderer = TextTRenderer()
    font = "Calibri Bold"
    text_english = [
        u"Still, our", u"movement", u"is not strong", u"enough to",
        u"bear fruit."
    ]
    text_spanish = [
        u"Sin embargo,", u"hasta mayo del", u"2016, nuestro", u"\u00e1rbol no",
        u"ha sido lo", u"suficientemente", u"fuerte para", u"brotar frutos.",
        u"Las ra\u00edzes a\u00fan", u"son d\u00e9biles."
    ]

    phrase1 = {
        Languages.ENGLISH:
        [renderer.makeImage_runnable(text_english, font, 42, 60), 1.0],
        Languages.SPANISH: [
            renderer.makeImage_runnable(text_spanish, font, 42, 60),
            Helpers.getLetterRatio(text_english, text_spanish)
        ]
    }

    def __init__(self, start):
        self.startTime = start
        self.stopTime = start + 125
        self.list = []
        self.list.append(labour(start))
        self.list.append(slider(start + 100))
        self.list.append(text(start, self.phrase1))
예제 #5
0
class evolve(evolve_base):
    font = aggdraw.Font("white", "./fonts/calibrib.ttf", 56)
    text_english = [u"Hidalgo is a small, ruggedly beautiful state in",
                    u"central Mexico where its indigenous citizens live",
                    u"in three regions in which human development",
                    u"levels are near the lowest in the world:"]
    text_spanish = [u"Hidalgo es un peque\u00f1o, rocoso y bello estado en",
                    u"M\u00e9xico central donde su poblacion indigena vive",
                    u"en tres regiones en las cuales el desarrollo humano",
                    u"se encuentra cerca de los m\u00e1s bajos del mundo:"]
    text_german = [u"Hidalgo ist ein kleiner, zerkl\u00fcfteter und pittoresker",
                   u"Bundesstatt im Herzen Mexikos in dem seine",
                   u"einheimische Bevoelkerung in drei Region lebt in",
                   u"denen die humane Entwicklung mit am niedrigsten",
                   u"in der Welt ist:"]

    phrase1 = {languages.ENGLISH: [Phrases().makeImage_runnable(text_english, font, 60), 1.0],
               languages.SPANISH: [Phrases().makeImage_runnable(text_spanish, font, 60),
                                   Helpers.getLetterRatio(text_english, text_spanish)],
               languages.GERMAN: [Phrases().makeImage_runnable(text_german, font, 60),
                                  Helpers.getLetterRatio(text_english, text_german)]}

    text_english = [u"In the Otom\u00ed-Tepehua region sit four majority",
                    u"indigenous areas:"]
    text_spanish = [u"En la regi\u00f3n Otom\u00ed-Tepehua hay cuatro \u00e1reas",
                    u"mayoritariamente ind\u00edgenas:"]
    text_german = [u"In der Region Otomi-Tepehua befinden sich 4",
                   u"mehrheitlich indigene Gebiete:"]

    phrase2 = {languages.ENGLISH: [Phrases().makeImage_runnable(text_english, font, 60), 1.0],
               languages.SPANISH: [Phrases().makeImage_runnable(text_spanish, font, 60),
                                   Helpers.getLetterRatio(text_english, text_spanish)],
               languages.GERMAN: [Phrases().makeImage_runnable(text_german, font, 60),
                                  Helpers.getLetterRatio(text_english, text_german)]}

    def __init__(self, start):
        self.startTime = start
        self.stopTime = start + 585
        self.list = [zoom(start, self.phrase1)]
        self.list.append(regions(start + 240))
        self.list.append(zoom2(start + 315))
        self.list.append(areas(start + 385))
        self.list.append(text2(start + 315, self.phrase2))
        self.list.append(
            Transitions.blender(Image.open("./images/huehuetla.png"), Helpers.open_image("./images/base4.png", 190),
                                start + 545, 40))
예제 #6
0
class evolve(evolve_base):
    font = aggdraw.Font("white", "./fonts/calibrib.ttf", 56)
    text_english = [u"Still, as of May", u"2016, our tree", u"is not strong", u"enough to bear", u"fruit. The",
                    u"foundation", u"remains weak."]
    text_spanish = [u"Sin embargo,",u"hasta mayo del", u"2016, nuestro", u"\u00e1rbol no", u"ha sido lo",u"suficientemente", u"fuerte para",
                    u"brotar frutos.", u"La base a\u00fan es", u"d\u00e9bil."]

    phrase1 = {languages.ENGLISH: [Phrases().makeImage_runnable(text_english, font, 60), 1.0],
               languages.SPANISH: [Phrases().makeImage_runnable(text_spanish, font, 60),
                                   Helpers.getLetterRatio(text_english, text_spanish)]}

    def __init__(self, start):
        self.startTime = start
        self.stopTime = start + 125
        self.list = []
        self.list.append(labour(start))
        self.list.append(slider(start + 100))
        self.list.append(text(start, self.phrase1))
예제 #7
0
class evolve(evolve_base):
    renderer = TextTRenderer()
    font = "Calibri Bold"
    text_english = [
        u"Here, indigenous people have begun to break",
        u"down the wall that divide community from",
        u"community and the Region from the World.",
        u"             ",
        u"These walls include:",
        u"             ",
        u"-The majority of the Region's people earn less",
        u"  than $85usd per month.",
        u"             ",
        u"-Less than 1% of homes possess a computer.",
        "             ",
        # u"Communities rarely collaborate, municipalities", u"even less.", u"             ",
        u"-Women average three grades of schooling",
        u"  and 9 out of 10 confront violence in",
        u"  their communities."
    ]

    text_spanish = [
        u"La gente ind\u00edgena est\u00e1 separada.",
        u"Se dividen comunidad de comunidad,",
        u"municipio de municipio y la Regi\u00f3n del",
        u"mundo.",
        u"             ",
        u"La mayor\u00eda de la gente de la regi\u00f3n",
        u"gana menos de $96 d\u00f3lares al mes.",
        "             ",
        u"Menos de 1% de los hogares posee",
        u"una computadora.",
        "             ",
        # u"Las comunidades raramente colaboran entre", u"ellas, los municipios todav\u00eda menos.",
        # "             ",
        u"Las mujeres promedian solo tres",
        u"a\u00f1os de escolaridad."
    ]

    phrase1 = {
        Languages.ENGLISH:
        [renderer.makeImage_runnable(text_english, font, 42, 60), 1.],
        Languages.SPANISH: [
            renderer.makeImage_runnable(text_spanish, font, 42, 60),
            Helpers.getLetterRatio(text_english, text_spanish)
        ]
    }

    text_english = [
        u"Since 2014, an Umbrella network of 500+ Nahua,",
        u"Otom\u00ed and Tepehua indigenous women from",
        u"35+ communities partner with the Mexican NGO",
        u"PSYDEH and build their own bottom-up movement.", u"          ",
        u"Their goal?", u"          ",
        u"Plant innovative \"seeds\" to advance",
        u"their own self-reliant communities through", u"          ",
        u"          Citizen Leader Education", u"          ",
        u"          Community Organizing"
    ]

    text_spanish = [
        u"Desde 2013, las poblaciones Nahua, Otom\u00ed y",
        u"Tepehua desaf\u00edan las paredes y construyen su",
        u"propio movimiento social desde la base",
        u"piramidal con respecto a sus derechos humanos.", "             ",
        u"En colaboraci\u00f3n con la ONG mexicana PSYDEH,",
        u"en 2014 y 2015, una red de m\u00e1s de 500 mujeres",
        u"ind\u00edgenas de m\u00e1s de 35 comunidades plantaron",
        u"semillas de innovaci\u00f3n para su propio futuro", u"sustentable."
    ]

    phrase2 = {
        Languages.ENGLISH:
        [renderer.makeImage_runnable(text_english, font, 42, 60), 1.],
        Languages.SPANISH: [
            renderer.makeImage_runnable(text_spanish, font, 42, 60),
            Helpers.getLetterRatio(text_english, text_spanish)
        ]
    }

    text_english = [
        u"These seeds: ", "             ", u"   - Identify shared interests",
        "             ", u"   - Reach clarity on solutions to problems",
        "             ", u"   - Adopt leader disciplines to implement",
        u"      solutions", "             ",
        u"   - Exercise rights & laws on which solutions", u"      are based",
        "             ", u"   - Assert communal autonomy and joint power"
    ]

    text_spanish = [
        u"Estas semillas significan aprender acerca de: ", "             ",
        u"   - Problemas en com\u00fan", "             ",
        u"   - Claridad en soluciones", "             ",
        u"   - M\u00e9todos de liderazgo para implementar", u"    soluciones",
        "             ", u"   - Derechos y leyes en los que se basan las",
        u"     soluciones", "             ",
        u"   - Autonom\u00eda personal y colectiva"
    ]

    phrase3 = {
        Languages.ENGLISH:
        [renderer.makeImage_runnable(text_english, font, 42, 60), 1.],
        Languages.SPANISH: [
            renderer.makeImage_runnable(text_spanish, font, 42, 60),
            Helpers.getLetterRatio(text_english, text_spanish)
        ]
    }

    def __init__(self, start):
        self.startTime = start
        self.stopTime = start + 1170 + 50 + 25
        self.list = []
        self.list.append(
            image(start, 450,
                  Helpers.open_image("./sequences/pullWall2/frame0.png", 190)))
        self.list.append(text(start, 400, 50, self.phrase1))
        self.list.append(pullWall(start + 450))
        # self.list.append(gradient(start + 450 + 120))
        text_lines = [
            Line(304, 304 + 24, (600 - 468 - 3, 700 - 58 + 3),
                 (696 + 3, 700 - 58 + 3))
        ]
        text_lines.append(
            Line(304 + 44, 304 + 44 + 20, (600 - 468 - 3, 700 - 58 + 3 + 120),
                 (696 - 35 + 3, 700 - 58 + 3 + 120)))

        self.list.append(
            text(start + 450,
                 350,
                 50,
                 self.phrase2,
                 pos_y=400,
                 text_addons=text_lines))
        self.list.append(handShake(start + 810))
        self.list.append(text(start + 810 + 50, 290 + 25, 50, self.phrase3))
        self.list.append(
            Transitions.horizontalFlip(
                Helpers.open_image("./sequences/pullWall2/frame175.png", 190),
                cairo.ImageSurface.create_from_png(
                    "./sequences/seednwater/frame0.png"),
                start + 1150 + 50 + 25, 20))
예제 #8
0
class evolve(evolve_base):
    renderer = TextTRenderer()
    font = "Calibri"
    text_english = [
        u"PSYDEH and Global Citizens:", u"Joining indigenous women in",
        u"building self-reliant communities."
    ]
    text_spanish = [
        u"PSYDEH y Ciudadanos del Mundo:",
        u"Derrumbando paredes y plantando arboles",
        u"junto con nuestros socios ind\u00EDgenas en M\u00e9xico."
    ]
    phrase1 = {
        Languages.ENGLISH:
        [renderer.makeImage_runnable(text_english, font, 34, 50), 1.0],
        Languages.SPANISH: [
            renderer.makeImage_runnable(text_spanish, font, 34, 50),
            Helpers.getLetterRatio(text_english, text_spanish)
        ]
    }
    text_english = [u"Visit PSYDEH's website for more", u"information: "]
    text_spanish = [
        u"Para m\u00e1s informaci\u00f3n visita la",
        u"p\u00e1gina web de PSYDEH: "
    ]
    phrase2 = {
        Languages.ENGLISH:
        [renderer.makeImage_runnable(text_english, font, 34, 50), 1.0],
        Languages.SPANISH: [
            renderer.makeImage_runnable(text_spanish, font, 34, 50),
            Helpers.getLetterRatio(text_english, text_spanish)
        ]
    }

    font = "Calibri Bold"
    text_english = [u"Invest in our fruits of change campaign."]
    text_spanish = [u"www.psydeh.com"]
    phrase3 = {
        Languages.ENGLISH: [
            renderer.makeImage_runnable(text_english,
                                        font,
                                        40,
                                        55,
                                        color=(80 / 255., 147 / 255.,
                                               205 / 255.)), 1.0
        ],
        Languages.SPANISH: [
            renderer.makeImage_runnable(text_spanish,
                                        font,
                                        34,
                                        50,
                                        color=(80 / 255., 147 / 255.,
                                               205 / 255.)),
            Helpers.getLetterRatio(text_english, text_spanish)
        ]
    }

    def __init__(self, start):
        self.startTime = start
        self.stopTime = start + 280
        self.list = []
        self.list.append(still(start))
        self.list.append(text(start, 265, self.phrase1, (310, 50)))
        #self.list.append(text(start + 92, 195, self.phrase2, (310, 600)))
        self.list.append(
            color_text(start + 92 + 0 * 44, 195, self.phrase3,
                       (310 - 100 + 0 * 252, 600 + 25 + 0 * 50)))
        self.list.append(transition(start + 240))
예제 #9
0
class evolve(evolve_base):
    renderer = TextTRenderer()
    font = "Calibri Bold"
    # aggdraw.Font("white", "./fonts/calibrib.ttf", 56)
    text_english = [
        u"Hidalgo is a small state in central Mexico where",
        u"its indigenous citizens live in three regions:"
    ]
    text_spanish = [
        u"Hidalgo es un peque\u00f1o, rocoso y bello estado en",
        u"M\u00e9xico central donde su poblacion indigena vive",
        u"en tres regiones en las cuales el desarrollo humano",
        u"se encuentra cerca de los m\u00e1s bajos del mundo:"
    ]
    text_german = [
        u"Hidalgo ist ein kleiner, zerkl\u00fcfteter und pittoresker",
        u"Bundesstatt im Herzen Mexikos in dem seine",
        u"einheimische Bevoelkerung in drei Region lebt in",
        u"denen die humane Entwicklung mit am niedrigsten", u"in der Welt ist:"
    ]

    phrase1 = {
        Languages.ENGLISH:
        [renderer.makeImage_runnable(text_english, font, 42, 60), 1.0],
        Languages.SPANISH: [
            renderer.makeImage_runnable(text_spanish, font, 42, 60),
            Helpers.getLetterRatio(text_english, text_spanish)
        ],
        Languages.GERMAN: [
            renderer.makeImage_runnable(text_german, font, 42, 60),
            Helpers.getLetterRatio(text_english, text_german)
        ]
    }

    text_english = [
        u"In this first stage of PSYDEH's work, ",
        u"we focus on the Otom\u00ed-Tepehua region and",
        u"its four majority indigenous areas:"
    ]
    text_spanish = [
        u"En la regi\u00f3n Otom\u00ed-Tepehua hay cuatro \u00e1reas",
        u"mayoritariamente ind\u00edgenas:"
    ]
    text_german = [
        u"In der Region Otomi-Tepehua befinden sich 4",
        u"mehrheitlich indigene Gebiete:"
    ]

    phrase2 = {
        Languages.ENGLISH:
        [renderer.makeImage_runnable(text_english, font, 42, 60), 1.0],
        Languages.SPANISH: [
            renderer.makeImage_runnable(text_spanish, font, 42, 60),
            Helpers.getLetterRatio(text_english, text_spanish)
        ],
        Languages.GERMAN: [
            renderer.makeImage_runnable(text_german, font, 42, 60),
            Helpers.getLetterRatio(text_english, text_german)
        ]
    }

    def __init__(self, start):
        self.startTime = start
        self.stopTime = start + 355 + 160 + 40
        self.list = [zoom(start, self.phrase1)]
        self.list.append(regions(start + 170))
        self.list.append(zoom2(start + 245))
        self.list.append(areas(start + 355))
        self.list.append(text2(start + 245, self.phrase2))
        self.list.append(
            Transitions.blender(
                cairo.ImageSurface.create_from_png(
                    "./images/map/huehuetla.png"),
                Helpers.open_image("./sequences/pullWall2/frame0.png", 190),
                start + 355 + 160, 40))
예제 #10
0
class evolve(evolve_base):
    font = aggdraw.Font("white", "./fonts/calibrib.ttf", 56)
    text_english = [
        u"For centuries, indigenous people are",
        u"separated by walls, dividing community from",
        u"community and the Region from the world.",
        u"             ",
        u"The majority of the Region's people earn less",
        u"than $96usd per month.",
        u"             ",
        u"Less than 1% of homes possess a computer.",
        "             ",
        #u"Communities rarely collaborate, municipalities", u"even less.", u"             ",
        u"Women average three grades of schooling."
    ]

    text_spanish = [
        u"La gente ind\u00edgena est\u00e1 separada.",
        u"Se dividen comunidad de comunidad",
        u"y la Regi\u00f3n del mundo.",
        u"             ",
        u"La mayor\u00eda de la gente de la Regi\u00f3n",
        u"gana menos de $96 d\u00f3lares al mes.",
        "             ",
        u"Menos de 1% de los hogares poseen",
        u"una computadora.",
        "             ",
        #u"Las comunidades raramente colaboran entre", u"ellas, los municipios todav\u00eda menos.",
        #"             ",
        u"Las mujeres promedian solo tres",
        u"a\u00f1os de escolaridad."
    ]

    phrase1 = {
        languages.ENGLISH:
        [Phrases().makeImage_runnable(text_english, font, 60), 1.],
        languages.SPANISH: [
            Phrases().makeImage_runnable(text_spanish, font, 60),
            Helpers.getLetterRatio(text_english, text_spanish)
        ]
    }

    text_english = [
        u"Since 2013, Nahua, Otom\u00ed and Tepehua citizens",
        u"defy the walls and build their own bottom-up",
        u"rights-based movement.", "             ",
        u"In partnership with the Mexican NGO PSYDEH,",
        u"in 2014 and 2015, a network of 500+ indigenous",
        u"women from 35+ communities planted",
        u"innovative seeds for their sustainable future."
    ]

    text_spanish = [
        u"Desde 2013, las poblaciones Nahua, Otom\u00ed y",
        u"Tepehua desaf\u00edan las paredes y construyen su",
        u"propio movimiento social desde la base",
        u"piramidal con respecto a sus derechos humanos.", "             ",
        u"En colaboraci\u00f3n con la ONG mexicana PSYDEH,",
        u"en 2014 y 2015, una red de m\u00e1s de 500 mujeres",
        u"ind\u00edgenas de m\u00e1s de 35 comunidades plantaron",
        u"semillas de innovaci\u00f3n para su propio futuro", u"sustentable."
    ]

    phrase2 = {
        languages.ENGLISH:
        [Phrases().makeImage_runnable(text_english, font, 60), 1.],
        languages.SPANISH: [
            Phrases().makeImage_runnable(text_spanish, font, 60),
            Helpers.getLetterRatio(text_english, text_spanish)
        ]
    }

    text_english = [
        u"These seeds = learning about: ", "             ",
        u"   - shared problems", "             ", u"   - clarity on solutions",
        "             ", u"   - leader disciplines to implement solutions",
        "             ", u"   - rights & laws on which solutions are based",
        "             ", u"   - personal & communal autonomy"
    ]

    text_spanish = [
        u"Estas semillas = aprender acerca de: ", "             ",
        u"   - Problemas en com\u00fan", "             ",
        u"   - Claridad en soluciones", "             ",
        u"   - M\u00e9todos de liderazgo para implementar", u"     soluciones",
        "             ", u"   - Derechos y leyes en los que se basan las",
        u"     soluciones", "             ",
        u"   - Autonom\u00eda personal y colectiva"
    ]

    phrase3 = {
        languages.ENGLISH:
        [Phrases().makeImage_runnable(text_english, font, 60), 1.],
        languages.SPANISH: [
            Phrases().makeImage_runnable(text_spanish, font, 60),
            Helpers.getLetterRatio(text_english, text_spanish)
        ]
    }

    def __init__(self, start):
        self.startTime = start
        self.stopTime = start + 1170
        self.list = []
        self.list.append(
            image(start, 470, Helpers.open_image("./images/base4.png", 190)))
        self.list.append(text(start, 420, 50, self.phrase1))
        self.list.append(pullWall(start + 470))
        self.list.append(gradient(start + 470 + 120))
        self.list.append(text(start + 470, 310, 50, self.phrase2))
        self.list.append(handShake(start + 830))
        self.list.append(text(start + 830, 270, 50, self.phrase3))
        self.list.append(
            Transitions.horizontalFlip(
                Helpers.open_image("./images/base5.png", 190).convert("RGBA"),
                Image.open("./images/base6.png").convert("RGBA"), start + 1150,
                20))
예제 #11
0
class evolve(evolve_base):
    font = aggdraw.Font("white", "./fonts/calibri.ttf", 46)
    text_english = [
        u"In just 1.5 years, ", u"the Region's", u"indigenous women",
        u"and PSYDEH have", u"dismantled walls,", u"planted seeds and",
        u"dream of fruits", u"to come."
    ]
    text_spanish = [
        u"En solo un a\u00f1o y medio,", u"las mujeres ind\u00edgenas",
        u"de la Regi\u00f3n y PSYDEH", u"han desmantelado las",
        u"paredes, plantado", u"semillas y sue\u00f1an con",
        u"los frutos que brotar\u00e1n."
    ]

    phrase1 = {
        languages.ENGLISH:
        [Phrases().makeImage_runnable(text_english, font, 46), 1.0],
        languages.SPANISH: [
            Phrases().makeImage_runnable(text_spanish, font, 46),
            Helpers.getLetterRatio(text_english, text_spanish)
        ]
    }

    def __init__(self, start):
        self.startTime = start
        self.stopTime = start + 430
        self.list = []
        positions = [(600, 950), (400, 237), (600, 333), (396, 380),
                     (568, 193), (529, 352), (663, 238),
                     (409, 304)]  # ,(723,372)]
        phrases = [None]

        phrases.append({
            languages.ENGLISH: [u"sustainable", u"economic", u"development"],
            languages.SPANISH:
            [u"Desarrollo", u"econ\u00f3mico", u"sustentable."]
        })
        phrases.append({
            languages.ENGLISH: [u"education", u"that", u"empowers"],
            languages.SPANISH: [u"Educaci\u00f3n", u"que", u"fortalece."]
        })
        phrases.append({
            languages.ENGLISH: [u"protected rights", u"and", u"justice"],
            languages.SPANISH:
            [u"Protecci\u00f3n de", u"derechos y justicia."]
        })
        phrases.append({
            languages.ENGLISH:
            [u"healthy relations", u"between", u"women and men"],
            languages.SPANISH:
            [u"Relaciones saludables", u"entre mujeres", u"y hombres."]
        })
        phrases.append({
            languages.ENGLISH: [u"responsible", u"government"],
            languages.SPANISH: [u"Gobierno", u"responsable."]
        })
        phrases.append({
            languages.ENGLISH: [u"protected", u"environment"],
            languages.SPANISH: [u"Medio ambiente", u"protegido."]
        })
        phrases.append({
            languages.ENGLISH: [u"quality", u"health", u"care"],
            languages.SPANISH: [u"Sistema", u"de salud", u"de calidad."]
        })
        # phrases.append(["umbrella network","of","local NGOs"])
        self.list.append(still(start))
        self.list.append(text(start, 430, self.phrase1))
        self.list.append(
            apple(start + 70, start + 410,
                  positions[1]))  # could put the commands into a loop
        self.list.append(apple(start + 75, start + 410, positions[2]))
        self.list.append(apple(start + 80, start + 410, positions[3]))
        self.list.append(apple(start + 85, start + 410, positions[4]))
        self.list.append(apple(start + 90, start + 410, positions[5]))
        self.list.append(apple(start + 95, start + 410, positions[6]))
        # self.list.append(apple(start + 100, start + 450, positions[7] ))
        self.list.append(
            lupa(start + 110, start + 430, self.zipper(positions, phrases)))
        self.list.append(
            Transitions.pageFlip(
                Image.open("./images/base12.png").convert("RGBA"), None,
                start + 410, 20, True))

    def zipper(self, a, b):
        font = aggdraw.Font("white", "./fonts/sans.ttf", 28)
        phrases = Phrases()
        retArray = []
        for pos, texts in zip(a, b):
            l_dict = {}
            if texts == None:
                retArray.append([pos, None])
            else:
                for language in languages.list_of_languages:
                    l_dict[language] = phrases.makeImage_centered(
                        texts[language], font)
                retArray.append([pos, l_dict])
        return retArray
예제 #12
0
class evolve(evolve_base):
    renderer = TextTRenderer()
    font = "Calibri"
    text_english = [u"In just 1.5 years, the ", u"Region's women and", u"PSYDEH have used citizen",
                    u"education training and", u"community organizing",
                    u"to dismantle walls and", u"plant seeds. Now they", u"work  to harvest the fruits."]
    text_spanish = [u"En solo un a\u00f1o y medio,", u"las mujeres ind\u00edgenas", u"de la Regi\u00f3n y PSYDEH",
                    u"han desmantelado las", u"paredes, plantado", u"semillas y sue\u00f1an con",
                    u"los frutos que brotar\u00e1n."]

    phrase1 = {Languages.ENGLISH: [renderer.makeImage_runnable(text_english, font, 34, 46), 1.0],
               Languages.SPANISH: [renderer.makeImage_runnable(text_spanish, font, 34, 46),
                                   Helpers.getLetterRatio(text_english, text_spanish)]}

    def __init__(self, start):
        self.startTime = start
        self.stopTime = start + 430 + 60
        self.list = []
        positions = [(600, 950), (400, 237), (600, 333), (396, 380), (568, 193), (529, 352), (663, 238),
                     (409, 304)]  # ,(723,372)]
        phrases = [None]

        phrases.append({Languages.ENGLISH: [u"Sustainable", u"economic", u"development"],
                        Languages.SPANISH: [u"Desarrollo", u"econ\u00f3mico", u"sustentable."]})
        phrases.append({Languages.ENGLISH: [u"Education", u"that", u"empowers"],
                        Languages.SPANISH: [u"Educaci\u00f3n", u"que", u"fortalece."]})
        phrases.append({Languages.ENGLISH: [u"Protected rights", u"and", u"justice"],
                        Languages.SPANISH: [u"Protecci\u00f3n de", u"derechos y justicia."]})
        phrases.append({Languages.ENGLISH: [u"Gender", u"equalty"],
                        Languages.SPANISH: [u"Relaciones saludables", u"entre mujeres", u"y hombres."]})
        phrases.append(
            {Languages.ENGLISH: [u"Responsible", u"government"], Languages.SPANISH: [u"Gobierno", u"responsable."]})
        phrases.append(
            {Languages.ENGLISH: [u"Protected", u"environment"], Languages.SPANISH: [u"Medio ambiente", u"protegido."]})
        phrases.append({Languages.ENGLISH: [u"Quality", u"health", u"care"],
                        Languages.SPANISH: [u"Sistema", u"de salud", u"de calidad."]})
        # phrases.append(["umbrella network","of","local NGOs"])
        self.list.append(still(start))
        self.list.append(text(start, 430 + 60, self.phrase1))

        self.list.append(Line(start + 79-20, start + 79 -20 + 7, (1098, 185 + 4), (1216, 185 + 4)))
        #self.list.append(Line(start + 86, start + 86 + 9, (752 - 3, 277 + 4), (930 + 3, 277 + 4)))
        #self.list.append(Line(start + 96, start + 96 + 8, (944 - 3, 277 + 4), (1083 + 3, 277 + 4)))
        self.list.append(Line(start + 86-20, start + 96 -20 + 8, (752 - 3, 231 + 4), (1083 + 3, 231 + 4)))

        #self.list.append(Line(start + 109, start + 109 + 8, (753 - 3, 323 + 4), (957 + 3, 323 + 4)))
        #self.list.append(Line(start + 118, start + 118 + 10, (970 - 3, 323 + 4), (1154 + 3, 323 + 4)))
        self.list.append(Line(start + 108-20, start + 118 -20+ 10, (753 - 3, 277 + 4), (1154 + 3, 277 + 4)))

        self.list.append(apple(start + 70, start + 410 + 60, positions[1]))  # could put the commands into a loop
        self.list.append(apple(start + 75, start + 410 + 60, positions[2]))
        self.list.append(apple(start + 80, start + 410 + 60, positions[3]))
        self.list.append(apple(start + 85, start + 410 + 60, positions[4]))
        self.list.append(apple(start + 90, start + 410 + 60, positions[5]))
        self.list.append(apple(start + 95, start + 410 + 60, positions[6]))
        # self.list.append(apple(start + 100, start + 450, positions[7] ))
        self.list.append(lupa(start + 110 + 60, start + 430 + 60, self.zipper(positions, phrases)))

        self.list.append(
            Transitions.pageFlip(cairo.ImageSurface.create_from_png("./sequences/stillworkin/frame0.png"),
                                 None, start + 410 + 60, 20, True))

    def zipper(self, a, b):
        retArray = []
        for pos, texts in zip(a, b):
            l_dict = {}
            if texts == None:
                retArray.append([pos, None])
            else:
                for language in Languages.list_of_languages:
                    l_dict[language] = self.renderer.makeImage_centered(texts[language], "sans", 20, 30,
                                                                        color=(1, 1, 1))
                retArray.append([pos, l_dict])
        return retArray