Skip to content

Commit c8c1642

Browse files
committed
Initial commit; all required files
1 parent e1010aa commit c8c1642

33 files changed

+135
-0
lines changed

EC.png

126 KB
Loading

V14.png

443 KB
Loading

certi.tex

+90
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
\documentclass[12pt]{article}
2+
\usepackage[utf8]{inputenc}
3+
\usepackage[spanish]{babel}
4+
\usepackage{mathpazo}
5+
\renewcommand{\familydefault}{\rmdefault}
6+
\usepackage[landscape,a4paper]{geometry}
7+
\geometry{verbose,tmargin=0cm,bmargin=0cm,lmargin=0cm,rmargin=0cm}
8+
\usepackage{fancybox}
9+
\usepackage{calc}
10+
\usepackage{multicol}
11+
\usepackage{graphicx}
12+
\usepackage{url}
13+
\usepackage{eso-pic}
14+
15+
\newcommand\BackgroundPic{%
16+
\put(0,0){%
17+
\parbox[b][\paperheight]{\paperwidth}{%
18+
\vfill
19+
\centering
20+
\includegraphics[width=\paperwidth,height=\paperheight,%
21+
keepaspectratio]{V14.png}%
22+
\vfill
23+
}}}
24+
25+
26+
\begin{document}
27+
\AddToShipoutPicture{\BackgroundPic}
28+
~
29+
\vspace{1.2cm}
30+
~
31+
\begin{center}
32+
33+
\begin{table}[h]
34+
\footnotesize
35+
\begin{center}
36+
\begin{tabular}{lr}
37+
%~\hspace{0.7cm}
38+
\includegraphics[height=3.4cm]{codeweekeu.png}
39+
\includegraphics[height=3.4cm]{EC.png}
40+
\end{tabular}
41+
\end{center}
42+
\end{table}
43+
\vspace{-0.2cm}
44+
\LARGE{CodeWeek EU organisers are honoured\\
45+
\vspace{1cm}
46+
\fontsize{50}{60}{\textbf{TO CERTIFY}}
47+
48+
\vspace{0.4cm}
49+
50+
\Huge{that \textbf{%pointname
51+
}}
52+
53+
\vspace{0.4cm}
54+
55+
\Huge{actively contributed to the success of}
56+
57+
\vspace{0.3cm}
58+
59+
\Huge{\textbf{EUROPE CODE WEEK 2015}}
60+
61+
\vspace{0.3cm}
62+
63+
\Large{by running a coding event.}
64+
65+
\vspace{.2cm}
66+
67+
\vspace{1cm}
68+
69+
\begin{table}[h]
70+
\footnotesize
71+
\begin{center}
72+
73+
\end{center}
74+
\end{table}
75+
76+
\vspace{-2cm}
77+
\includegraphics[height=2.5cm]{signature.png}
78+
79+
\vspace{-0.5cm}
80+
\begin{center}
81+
\footnotesize{Alessandro Bogliolo, Europe Code Week coordinator}\\
82+
\end{tabular}
83+
\end{center}
84+
85+
%Diploma elaborado con el software libre \texttt{Pyploma}, (c)
86+
%\url{[email protected]} bajo licencia
87+
%GPLv3. Visite: \url{http://code.google.com/p/pyploma}
88+
89+
\end{center}
90+
\end{document}

codeweekeu.png

32.5 KB
Loading
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

pyploma.py

+45
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# -*- coding: utf-8 -*-
2+
# This diploma generator read a list of names to
3+
# fill a LaTeX template with a point for the name.
4+
# Optinally, it can compile the LaTeX files and join them.
5+
# If LaTeX errors are present, then press Enter.
6+
7+
print "Pyploma: Diploma generator for LaTeX and pdf.\n"
8+
9+
# Invocar al terminal
10+
from commands import *
11+
import commands
12+
def run_command(cmd):
13+
getstatusoutput(cmd)
14+
15+
# Cargar lista de nombres
16+
lista = open("listadip", "r").readlines()
17+
18+
#contador
19+
a = 100
20+
21+
for line in lista: # for each person in the list
22+
23+
a += 1 #counter
24+
b = str(a) #transform counter into string
25+
salida = open("output" + b + ".tex","w") # create a LaTeX file for each person in the list
26+
27+
text = open("certi.tex") # open the LaTeX document
28+
text = text.read() # read it
29+
text_list = list(text) # transform it into a list
30+
31+
y_name = text.find("%pointname") #search the point for name inclusion
32+
z_name = len("%pointname")+2
33+
text_list[y_name+z_name:y_name+z_name] = line # insert the name
34+
35+
text_final = "".join(text_list) # from list to string
36+
37+
salida.write(text_final) # save changes in the created file
38+
salida.close() # closes the file
39+
40+
run_command(str("pdflatex " + "output" + b + ".tex")) # compile LaTeX a pdf (optional)
41+
print line #control
42+
43+
run_command(str("pdftk output*.pdf cat output todos_diplomas.pdf")) # create pdf with all the created diplomas (optional)
44+
45+
print "\nAnd we are done! :-)" #control

signature.png

320 KB
Loading

0 commit comments

Comments
 (0)