summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSashi202018-05-30 14:20:28 +0530
committerGitHub2018-05-30 14:20:28 +0530
commite061f88266ba1888feb73c57330ccdc13a9567c1 (patch)
tree452eac723d0502c3f25728d4351038dd761271c6
parenta3c7a3348b6ce64f751f862df8eabe888f7b46c7 (diff)
parentd65c6386db5ba975c39445dcbd396fb52eb9061e (diff)
downloaddwsim_flowsheet-e061f88266ba1888feb73c57330ccdc13a9567c1.tar.gz
dwsim_flowsheet-e061f88266ba1888feb73c57330ccdc13a9567c1.tar.bz2
dwsim_flowsheet-e061f88266ba1888feb73c57330ccdc13a9567c1.zip
Merge pull request #27 from Sashi20/drupal_7.x
Changed background and font color for mentor certificates
-rwxr-xr-xpdf/mentor_cert_pdf.inc76
1 files changed, 42 insertions, 34 deletions
diff --git a/pdf/mentor_cert_pdf.inc b/pdf/mentor_cert_pdf.inc
index 1c59f1a..2b58665 100755
--- a/pdf/mentor_cert_pdf.inc
+++ b/pdf/mentor_cert_pdf.inc
@@ -34,47 +34,55 @@ function generate_pdf()
echo "Error!";
} //!$pdf
$pdf->AddPage();
- $image_bg = $mpath . "/pdf/images/bg_cert.png";
+ $image_bg = $mpath . "/pdf/images/bg_cert_mentor.png";
$pdf->Image($image_bg, 0, 0, $pdf->w, $pdf->h);
$pdf->SetMargins(18, 1, 18);
$path = drupal_get_path('module', 'dwsim_flowsheet');
$pdf->Ln(15);
- $pdf->Ln(20);
- $pdf->SetFont('Arial', 'BI', 25);
- $pdf->Ln(26);
- $pdf->SetFont('Arial', 'BI', 12);
- $pdf->SetTextColor(0, 0, 0);
+ $pdf->Ln(43);
+ $pdf->SetFont('Times', 'I', 12);
+ $pdf->SetTextColor(13, 5, 130);
$pdf->Cell(240, 20, 'This certificate recognizes the valuable mentorship of', '0', '1', 'C');
$pdf->Ln(-6);
- $pdf->SetFont('Arial', 'BI', 25);
- $pdf->SetTextColor(139, 69, 19);
+ $pdf->SetFont('Times', 'BI', 16);
+ $pdf->SetTextColor(13, 5, 130);
$pdf->Cell(240, 8, $data3->project_guide_name, '0', '1', 'C');
$pdf->Ln(0);
- $pdf->SetFont('Arial', 'I', 12);
+ $pdf->SetFont('Times', 'I', 12);
if (strtolower($data3->branch) != "others") {
- $pdf->SetTextColor(0, 0, 0);
- $pdf->MultiCell(240, 8, 'from ' . $data3->project_guide_university, '0','C');
+ $pdf->SetTextColor(13, 5, 130);
+ $pdf->SetFont('Times', 'I', 12);
+ $pdf->Cell(240, 8, 'from', '0', '1', 'C');
+ $pdf->Ln(0);
+ $pdf->SetFont('Times','BI',16);
+ $pdf->Cell(240, 8, $data3->project_guide_university, '0','1','C');
$pdf->Ln(0);
+ $pdf->SetFont('Times', 'I', 12);
$pdf->Cell(240, 8, 'who has mentored', '0', '1', 'C');
$pdf->Ln(0);
+ $pdf->SetFont('Times', 'BI', 16);
$pdf->Cell(240, 8, $data3->contributor_name, '0', '1', 'C');
$pdf->Ln(0);
+ $pdf->SetFont('Times', 'I', 12);
$pdf->Cell(240, 8, 'for successfully completing internship under the DWSIM Flowsheeting project. The intern(s) has created a flowsheet titled', '0', '1', 'C');
$pdf->Ln(0);
- $pdf->SetTextColor(139, 69, 19);
+ $pdf->SetFont('Times', 'BI', 16);
+ $pdf->SetTextColor(13, 5, 130);
$pdf->Cell(240, 8, $data3->project_title, '0', '1', 'C');
- $pdf->SetTextColor(0, 0, 0);
+ $pdf->SetTextColor(13, 5, 130);
$pdf->Ln(0);
+ $pdf->SetFont('Times', 'I', 12);
$pdf->Cell(240, 8, ' using DWSIM .The work done is available at', '0', '1', 'C');
$pdf->Cell(240, 4, '', '0', '1', 'C');
$pdf->SetX(120);
$pdf->SetFont('', 'U');
- $pdf->SetTextColor(139, 69, 19);
+ $pdf->SetTextColor(13, 5, 130);
+ $pdf->SetFont('Times', 'I', 12);
$pdf->write(0, 'https://dwsim.fossee.in/', 'https://dwsim.fossee.in/');
$pdf->Ln(0);
}
else {
- $pdf->SetTextColor(0, 0, 0);
+ $pdf->SetTextColor(13, 5, 130);
$pdf->Cell(240, 8, 'from ' . $data3->project_guide_university . ' has successfully', '0', '1', 'C');
$pdf->Ln(0);
$pdf->Cell(240, 8, 'completed Internship under DWSIM Flowsheeting Project', '0', '1', 'C');
@@ -110,41 +118,41 @@ function generate_pdf()
$pngAbsoluteFilePath = $tempDir . $fileName;
$urlRelativeFilePath = $path . "/pdf/temp_prcode/" . $fileName;
QRcode::png($codeContents, $pngAbsoluteFilePath);
- $pdf->SetTextColor(0, 0, 0);
- $pdf->Ln(30);
+ /*$pdf->SetTextColor(0, 0, 0);
+ $pdf->Ln(35);
$pdf->SetX(198);
$pdf->SetFont('', '');
$pdf->SetTextColor(0, 0, 0);
$pdf->SetY(-85);
$pdf->SetX(200);
- $pdf->Ln(16);
+ $pdf->Ln(20);
$pdf->Cell(240, 8, 'Prof. Kannan M. Moudgalya', 0, 1, 'R');
$pdf->SetX(199);
- $pdf->SetFont('Arial', '', 10);
+ $pdf->SetFont('Times', '', 10);
$pdf->Cell(0, 7, 'Co - Principal Investigator - FOSSEE', 0, 1, 'L');
$pdf->SetX(190);
$pdf->Cell(0, 7, ' Dept. of Chemical Engineering, IIT Bombay.', 0, 1, 'L');
- $pdf->SetX(29);
- $pdf->SetFont('Arial', 'B', 10);
+ $pdf->SetX(29);*/
+ $pdf->SetFont('Times', 'B', 12);
$pdf->SetY(-58);
- $pdf->Ln(14);
+ $pdf->Ln(13);
$pdf->SetX(10);
$pdf->Cell(0, 0, $qrstring, 0, 0, 'C');
$pdf->SetX(29);
$pdf->SetY(-50);
- $image4 = $path . "/pdf/images/verify_content.png";
+ /*$image4 = $path . "/pdf/images/bottom_line.png";
$pdf->SetY(-50);
$pdf->SetX(80);
$image3 = $path . "/pdf/images/iitb.png";
$image2 = $path . "/pdf/images/fossee.png";
- $pdf->Ln(8);
- $pdf->Image($image2, $pdf->GetX() +15, $pdf->GetY() + 7, 40, 0);
- $pdf->Ln(6);
- $pdf->Image($pngAbsoluteFilePath, $pdf->GetX() + 102, $pdf->GetY() - 5, 30, 0);
+ $pdf->Ln(15);
+ $pdf->Image($image2, $pdf->GetX() +30, $pdf->GetY() + 7, 40, 0);*/
+ $pdf->Ln(13);
+ $pdf->Image($pngAbsoluteFilePath, $pdf->GetX() + 102, $pdf->GetY() - 5, 30, 0);/*
$pdf->Image($image3, $pdf->GetX() + 200, $pdf->GetY() -3, 15, 0);
$pdf->Image($image4, $pdf->GetX() +50, $pdf->GetY() + 28, 150, 0);
- $pdf->SetFont('Arial', 'I', 8);
- $pdf->SetTextColor(0, 0, 0);
+ $pdf->SetFont('Times', 'I', 8);
+ $pdf->SetTextColor(0, 0, 0);*/
$filename = str_replace(' ', '-', $data3->contributor_name) . '-DWSIM-Flowsheet-Certificate.pdf';
$file = $path . '/pdf/temp_certificate/' . $proposal_id . '_' . $filename;
$pdf->Output($file, 'F');
@@ -214,11 +222,11 @@ function generate_copyright_form_pdf()
} //!$pdf
$pdf->AddPage();
$path = drupal_get_path('module', 'dwsim_flowsheet');
- $pdf->SetFont('Arial', 'B', 25);
+ $pdf->SetFont('Times', 'B', 25);
$pdf->Ln(30);
$pdf->Cell(200, 8, 'Copyright Transfer Form', 0, 1, 'C');
$pdf->Ln(20);
- $pdf->SetFont('Arial', '', 12);
+ $pdf->SetFont('Times', '', 12);
$pdf->MultiCell(200, 8, 'I hereby transfer the copyrights of the DWSIM Flowsheeting Project for ' . $data2->project_title . ' to FOSSEE Project, IIT Bombay.', 0);
$pdf->Ln(10);
$pdf->MultiCell(200, 8, 'I understand that the FOSSEE project will release the Flowsheet under the Creative Commons (CC) license.');
@@ -302,14 +310,14 @@ function generate_undertaking_form_pdf()
} //!$pdf
$pdf->AddPage();
$path = drupal_get_path('module', 'dwsim_flowsheet');
- $pdf->SetFont('Arial', 'B', 25);
+ $pdf->SetFont('Times', 'B', 25);
$pdf->Ln(30);
$pdf->Cell(200, 8, 'Undertaking Form', 0, 1, 'C');
$pdf->Ln(0);
- $pdf->SetFont('Arial', 'B', 10);
+ $pdf->SetFont('Times', 'B', 10);
$pdf->Cell(200, 8, '(To be signed by college teacher)', 0, 1, 'C');
$pdf->Ln(20);
- $pdf->SetFont('Arial', '', 12);
+ $pdf->SetFont('Times', '', 12);
$pdf->MultiCell(200, 8, 'I hereby certify that all the codes written by ' . $gender['salutation'] . ' ' . $data3->full_name . ' under the DWSIM Textbook Companion Project for the book ' . $data2->book . ' ( Author: ' . $data2->author . ', Edition: ' . $data2->edition . ', Publisher: ' . $data2->publisher . ', Year: ' . $data2->year . ') are correctly reproducing the results given in the aforementioned book.', 0);
$pdf->Ln(10);
$pdf->MultiCell(200, 8, 'I understand that the DWSIM Textbook Companion created is a part of FOSSEE project, IIT Bombay, and is sponsored by the National Mission on Education through Information and Communication Technology (NMEICT), under MHRD, Govt. of India. The project requires that the textbook companion is made available for public access as an open source document. Hence I undertake that this DWSIM Textbook Companion can be made public along with the information that I have certified all the codes as giving the correct answer.');