jasperPrint.setOrientation(JasperReport.ORIENTATION_LANDSCAPE);
jasperPrint.setPageWidth(convert(297));
jasperPrint.setPageHeight(convert(210));
//Fonts
JRDesignStyle bodyStyle = new JRDesignStyle();
bodyStyle.setName("Arial_Normal");
bodyStyle.setDefault(true);
bodyStyle.setFontName("Arial");
bodyStyle.setFontSize(18);
bodyStyle.setPdfFontName("Helvetica");
bodyStyle.setPdfEncoding("Cp1252");
bodyStyle.setPdfEmbedded(false);
jasperPrint.addStyle(bodyStyle);
JRDesignStyle boldStyle = new JRDesignStyle();
boldStyle.setName("Arial_Bold");
boldStyle.setDefault(true);
boldStyle.setFontName("Arial");
boldStyle.setFontSize(16);
boldStyle.setBold(true);
boldStyle.setPdfFontName("Helvetica");
boldStyle.setPdfEncoding("Cp1252");
boldStyle.setPdfEmbedded(false);
jasperPrint.addStyle(boldStyle);
JRDesignStyle titleStyle = new JRDesignStyle();
titleStyle.setName("Arial_Title");
titleStyle.setDefault(true);
titleStyle.setFontName("Arial");
titleStyle.setFontSize(26);
titleStyle.setBold(true);
titleStyle.setPdfFontName("Helvetica");
titleStyle.setPdfEncoding("Cp1252");
titleStyle.setPdfEmbedded(false);
jasperPrint.addStyle(titleStyle);
JRDesignStyle nameStyle = new JRDesignStyle();
nameStyle.setName("Arial_Footer");
nameStyle.setDefault(true);
nameStyle.setFontName("Arial");
nameStyle.setFontSize(40);
nameStyle.setBold(true);
nameStyle.setPdfFontName("Helvetica");
nameStyle.setPdfEncoding("Cp1252");
nameStyle.setPdfEmbedded(false);
jasperPrint.addStyle(nameStyle);
try {
Person person = (Person) system.query(new GetPerson(registration.getIdPerson()));
String genderChar = (person.getGender().equals("Masculino")?"o":"a");