当前位置: 首页>>代码示例>>PHP>>正文


PHP PDF::SetDrawColor方法代码示例

本文整理汇总了PHP中PDF::SetDrawColor方法的典型用法代码示例。如果您正苦于以下问题:PHP PDF::SetDrawColor方法的具体用法?PHP PDF::SetDrawColor怎么用?PHP PDF::SetDrawColor使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在PDF的用法示例。


在下文中一共展示了PDF::SetDrawColor方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: erstelle_neu

function erstelle_neu($_drucktime)
{
    global $_user;
    global $_time;
    global $_settings;
    global $_absenz;
    global $_month;
    //Daten für die Anzeige
    $_sum = array();
    if ($_drucktime) {
        $tmp_jahr = date("Y", time());
        $tmp_monat = date("n", time()) - 1;
        if ($tmp_monat == 0) {
            $tmp_monat = 12;
            $tmp_jahr = $tmp_jahr - 1;
        }
        // Falls der Mitarbeiter Drucken darf ist das nur der letzte Monat
        $_monat = new time_month($_settings->_array[12][1], $_time->_letzterTag, $_user->_ordnerpfad, $tmp_jahr, $tmp_monat, $_user->_arbeitstage, $_user->_feiertage, $_user->_SollZeitProTag, $_user->_BeginnDerZeitrechnung, $_settings->_array[21][1], $_settings->_array[22][1], $_settings->_array[27][1]);
        $_jahr = new time_jahr($_user->_ordnerpfad, 0, $_user->_BeginnDerZeitrechnung, $_user->_Stunden_uebertrag, $_user->_Ferienguthaben_uebertrag, $_user->_Ferien_pro_Jahr, $_user->_Vorholzeit_pro_Jahr, $_user->_modell, $_drucktime);
    } else {
        $_monat = new time_month($_settings->_array[12][1], $_time->_letzterTag, $_user->_ordnerpfad, $_time->_jahr, $_time->_monat, $_user->_arbeitstage, $_user->_feiertage, $_user->_SollZeitProTag, $_user->_BeginnDerZeitrechnung, $_settings->_array[21][1], $_settings->_array[22][1], $_settings->_array[27][1]);
        $_jahr = new time_jahr($_user->_ordnerpfad, 0, $_user->_BeginnDerZeitrechnung, $_user->_Stunden_uebertrag, $_user->_Ferienguthaben_uebertrag, $_user->_Ferien_pro_Jahr, $_user->_Vorholzeit_pro_Jahr, $_user->_modell, $_time->_timestamp);
    }
    // PDF erstellen
    $pdf = new PDF();
    // Schrift auf Fett stellen (B)
    $pdf->SetFont('Arial', 'B', 10);
    $pdf->SetDrawColor(150, 150, 150);
    $pdf->AddPage();
    $pdf->SetFillColor(220, 220, 220);
    // -------------------------------------------------------------------------
    // Mitarbeitername und Monat
    // -------------------------------------------------------------------------
    $pdf->Cell(11, 6, '', 0, '', 'L');
    $pdf->Cell(30, 6, 'Name : ', 0, 0, 'L', '1');
    $pdf->Cell(59, 6, $_user->_name, 0, 0, 'L', '1');
    $pdf->Cell(30, 6, 'Monat : ', 0, 0, 'L', '1');
    $_monatname = iconv("UTF-8", "ISO-8859-1", $_time->_monatname);
    $pdf->Cell(59, 6, $_monatname . " " . $_time->_jahr, 0, 0, 'L', '1');
    $pdf->Ln();
    $pdf->Ln(1);
    // -------------------------------------------------------------------------
    // Monatsveränderungen - Berechnungen und anzeigen
    // -------------------------------------------------------------------------
    // Hintergrund weiss setzten und Schriftart Arial, normal, 10px
    $_ferien = 0;
    $_absenzenvorhanden = 0;
    $_ftxt = "";
    $_ftxtA = "";
    $_ftxtE = "";
    foreach ($_monat->get_calc_absenz() as $werte) {
        if ($werte[1] == "F") {
            $_ferien = trim($werte[3]);
            if ($_ferien == 1) {
                $_ftxt = " Tag";
            } else {
                $_ftxt = " Tage";
            }
        }
        if ($werte[3] > 0 & $_absenzenvorhanden == 0) {
            $_absenzenvorhanden = 1;
        }
    }
    // $_ferienstart = $_jahr->_saldo_F + $_ferien;
    $_ferienstart = 0;
    $_ferienstart = round($_jahr->_saldo_F, 2);
    $_ferienstart = $_ferienstart + round($_ferien, 2);
    $_ferienstart = round($_ferienstart, 2);
    if ($_ferienstart == 1) {
        $_ftxtA = " Tag";
    } elseif ($_ferienstart > 1) {
        $_ftxtA = " Tage";
    }
    if ($_jahr->_saldo_F == 1) {
        $_ftxtE = " Tag";
    } else {
        $_ftxtE = " Tage";
    }
    $_saldo_start = 0;
    $_sum['zeit']['monat_ende'] = $_jahr->_saldo_t;
    $_sum['zeit']['vorholzeit'] = round($_jahr->_Vorholzeit_pro_Jahr / 12, 2);
    $ausz = new auszahlung($_time->_monat, $_time->_jahr);
    $wert = trim($ausz->get_auszahlung($_time->_monat, $_time->_jahr));
    $_sum['zeit']['auszahlung'] = $wert;
    $_sum['zeit']['summe'] = $_monat->_SummeSaldoProMonat;
    $_sum['ferien']['monat_ende'] = $_jahr->_saldo_F;
    $_sum['ferien']['bezug'] = $_ferien;
    if ($_time->_jahr == time_user::get_user_startyear() && $_time->_monat == time_user::get_user_startmonth()) {
        $_sum['zeit']['monat_start'] = 0;
        $_sum['zeit']['uebertrag'] = $_user->_Stunden_uebertrag;
        $_sum['ferien']['uebertrag'] = $_user->_Ferienguthaben_uebertrag;
    } else {
        $_sum['zeit']['monat_start'] = $_sum['zeit']['monat_ende'];
        $_sum['zeit']['monat_start'] += $_sum['zeit']['vorholzeit'];
        $_sum['zeit']['monat_start'] += $_sum['zeit']['auszahlung'];
        $_sum['zeit']['monat_start'] -= $_sum['zeit']['summe'];
        $_sum['zeit']['uebertrag'] = 0;
        $_sum['ferien']['uebertrag'] = 0;
    }
    $_sum['ferien']['monat_start'] = $_sum['ferien']['monat_ende'] - $_sum['ferien']['uebertrag'] + $_sum['ferien']['bezug'];
//.........这里部分代码省略.........
开发者ID:karu,项目名称:SmallTime,代码行数:101,代码来源:time_funktion_pdf.php

示例2: foreach

                $pdf->setFont('Arial', 'B', '10');
                $pdf->Cell($cellsize, $cell_height, $p_weekly['past']);
                $pdf->setFont('Arial', '', '10');
                $pdf->setXY($cellsizecollweek + 2, $ypos + 8);
                $pdf->Cell($cellsize, $cell_height, $p_weekly['range_date']);
                $ypostTotal = $ypos + 13;
                foreach ($p_weekly['sales'] as $sales) {
                    $pdf->setXY($cellsizecollweek + 2, $ypostTotal);
                    $pdf->Cell($cellsize_half, $cell_height, $sales['name'] . ':');
                    $pdf->Cell($cellsize_half - 4, $cell_height, $sales['total'], 0, 0, 'R');
                    $ypostTotal += 5;
                }
                $line_ypos = $ypos + 43.5;
                $line_xpos_start = $cellsizecollweek + 2;
                $line_xpos_end = $cellsizecollweek + ($cellsize - 2);
                $pdf->SetDrawColor(200, 200, 200);
                $pdf->Line($line_xpos_start, $line_ypos, $line_xpos_end, $line_ypos);
                $pdf->SetDrawColor(0, 0, 0);
                $pdf->setXY($cellsizecollweek + 2, $ypos + 45);
                $pdf->Cell($cellsize_half, $cell_height, 'Total Sold:');
                $pdf->Cell($cellsize_half - 4, $cell_height, $p_weekly['total_sold'], 0, 0, 'R');
                $cellsizecollweek += $cellsize;
            }
            $ypos += 55;
            $pdf->setXY($cellstart, $ypos);
            $cellsizecollweek = $cellsize + $margin;
            $firstorder = false;
        }
        $no = 1;
    }
}
开发者ID:blasiuscosa,项目名称:manobo-2008,代码行数:31,代码来源:sales-report-weekly-products.php

示例3: array

$nombreentidad = $_POST["nombrecobrador"];
$codentidad = $_POST["codcobrador"];
$where = "1=1";
if ($codcobrador != "") {
    $where .= " AND codcobrador='{$codcobrador}'";
}
if ($nombrecobrador != "") {
    $where .= " AND nombrecobrador like '%" . $nombrecobrador . "%'";
}
$where2 .= " ORDER BY nombrecobrador ASC";
//Ttulos de las columnas
$header = array('Cod. Cobrador', 'Nombre Cobrador');
//Colores, ancho de lnea y fuente en negrita
$pdf->SetFillColor(200, 200, 200);
$pdf->SetTextColor(0);
$pdf->SetDrawColor(0, 0, 0);
$pdf->SetLineWidth(0.2);
$pdf->SetFont('Arial', 'B', 8);
//Cabecera
$pdf->SetX(60);
$w = array(20, 60);
for ($i = 0; $i < count($header); $i++) {
    $pdf->Cell($w[$i], 7, $header[$i], 1, 0, 'C', 1);
}
$pdf->Ln();
$pdf->SetFont('Arial', '', 8);
$sel_resultado = "SELECT * FROM cobradores WHERE borrado=0 AND " . $where . $where2;
$res_resultado = mysql_query($sel_resultado);
$contador = 0;
while ($contador < mysql_num_rows($res_resultado)) {
    $pdf->SetX(60);
开发者ID:decimerulo,项目名称:ERP,代码行数:31,代码来源:imprimir_cobradores.php

示例4: pdf

/**
 * Genera un reporte en PDF
 *
 * @param array $result
 * @param array $sumArray
 * @param string $title
 * @param array $weightArray
 * @param array $headerArray
 */
function pdf($result, $sumArray, $title, $weightArray, $headerArray)
{
    $config = Config::read('config');
    $active_app = Router::get_application();
    //Orientación
    if ($sumArray > 200) {
        $orientation = 'L';
    } else {
        $orientation = 'P';
    }
    $numRows = 140;
    //Tipo de Papel
    if ($sumArray > 250) {
        $paper = 'legal';
    } else {
        $paper = 'letter';
    }
    if ($paper == 'letter' && $orientation == 'P') {
        $widthPage = 220;
        $numRows = 42;
    }
    if ($paper == 'legal' && $orientation == 'L') {
        $widthPage = 355;
        $numRows = 30;
    }
    if ($paper == 'letter' && $orientation == 'L') {
        $widthPage = 270;
        $numRows = 30;
    }
    //Crear Documento PDF
    $pdf = new PDF($orientation, 'mm', $paper);
    $pdf->Open();
    $pdf->AddPage();
    //Nombre del Listado
    $pdf->SetFillColor(255, 255, 255);
    $pdf->AddFont('Verdana', '', 'verdana.php');
    $pdf->SetFont('Verdana', '', 14);
    $pdf->SetY(20);
    $pdf->SetX(0);
    $pdf->Ln();
    if ($config->{$active_app}->name) {
        $pdf->MultiCell(0, 6, strtoupper($config->{$active_app}->name), 0, "C", 0);
    }
    $pdf->MultiCell(0, 6, "REPORTE DE " . strtoupper($title), 0, "C", 0);
    $pdf->SetFont('Verdana', '', 12);
    if (isset($_SESSION['fecsis'])) {
        $pdf->MultiCell(0, 6, "FECHA " . date("Y-m-d"), 0, "C", 0);
    }
    $pdf->Ln();
    //Colores, ancho de línea y fuente en negrita
    $pdf->SetFillColor(0xf2, 0xf2, 0xf2);
    $pdf->SetTextColor(0);
    $pdf->SetDrawColor(0, 0, 0);
    $pdf->SetLineWidth(0.2);
    $pdf->SetFont('Arial', 'B', 10);
    if ($weightArray[0] < 11) {
        $weightArray[0] = 11;
    }
    //Parametros del Reporte
    $pos = floor($widthPage / 2 - $sumArray / 2);
    $pdf->SetX($pos);
    for ($i = 0; $i <= count($headerArray) - 1; $i++) {
        $pdf->Cell($weightArray[$i], 7, $headerArray[$i], 1, 0, 'C', 1);
    }
    $pdf->Ln();
    //Restauración de colores y fuentes
    $pdf->SetFillColor(224, 235, 255);
    $pdf->SetTextColor(0);
    $pdf->SetFont('Arial', 'B', 7);
    //print_r($weightArray);
    //Buscamos y listamos
    $n = 1;
    $p = 1;
    $t = 0;
    foreach ($result as $row) {
        //$pdf->Cell(Ancho, Alto, contenido, ?, ?, Align)
        if ($n > $numRows || $p == 1 && $n > $numRows - 3) {
            $pdf->AddPage($orientation);
            $pdf->SetY(30);
            $pdf->SetX($pos);
            $pdf->SetFillColor(0xf2, 0xf2, 0xf2);
            $pdf->SetTextColor(0);
            $pdf->SetDrawColor(0, 0, 0);
            $pdf->SetLineWidth(0.2);
            $pdf->SetFont('Arial', 'B', 10);
            for ($i = 0; $i < count($headerArray); $i++) {
                $pdf->Cell($weightArray[$i], 7, $headerArray[$i], 1, 0, 'C', 1);
            }
            $pdf->Ln();
            $pdf->SetFillColor(224, 235, 255);
            $pdf->SetTextColor(0);
//.........这里部分代码省略.........
开发者ID:raalveco,项目名称:Escuela,代码行数:101,代码来源:pdf.php

示例5: query

    $nombre = str_replace('&#038;', '&', $nombre);
}
$sql = "Select *  " . "       from " . "       ges_comprobantes " . "where  ges_comprobantes.IdComprobante='{$IdComprobante}' " . "and    ges_comprobantes.IdLocal='{$IdLocal}' " . "and    ges_comprobantes.Eliminado='0'";
$res = query($sql);
$lafila = Row($res);
//$pdf=new PDF();
$pdf = new PDF('P', 'mm', array(210, 297));
$pdf->Open();
$pdf->AddPage();
$pdf->Ln(2);
$pdf->Cell(95);
$pdf->Cell(80, 4, "", '', 0, 'C');
$pdf->Ln(5);
$pdf->SetFillColor(255, 255, 255);
$pdf->SetTextColor(0);
$pdf->SetDrawColor(0, 0, 0);
$pdf->SetLineWidth(0.2);
$pdf->SetFont('Arial', 'B', 10);
$pdf->SetX(130);
$pdf->Ln(40);
// Datos Cliente
$pdf->SetFont('Arial', 'B', 10);
$pdf->SetX(27);
// NOMBRE
$pdf->Cell(130, 4, $nombre);
//$igv=$lafila["IGV"];
$igv = 0;
$pdf->Ln(6);
$pdf->SetX(180);
// NUM GUIA REMIS.
$pdf->Cell(70, 4, "");
开发者ID:klich3,项目名称:gPOS,代码行数:31,代码来源:imprimir_Factura_tpv.php

示例6:

$pdf->Cell(25, 5, '95', 0, 0, 'L');
$pdf->SetY(167);
$pdf->SetX(280);
$pdf->Cell(25, 5, '100', 0, 0, 'L');
$pdf->SetY(167);
$pdf->SetX(290);
$pdf->Cell(25, 5, '105', 0, 0, 'L');
$pdf->SetY(167);
$pdf->SetX(300);
$pdf->Cell(25, 5, '110', 0, 0, 'L');
$pdf->SetY(180);
$pdf->SetX(80);
$pdf->Cell(25, 5, '1:200,000', 0, 0, 'L');
if ($graphtax1 > 0) {
    $pdf->SetLineWidth(2);
    $pdf->SetDrawColor(255, 0, 0);
    $pdf->Line(80, 70, 80 + $graphtax1, 70);
}
$pdf->SetY(67);
$pdf->SetX(80 + $graphtax1 + 3);
$pdf->Cell(25, 5, 'Year ' . $dateprev . ' (' . number_format($sumtax1[0], 2) . ')', 0, 0, 'L');
if ($graphtax2 > 0) {
    $pdf->SetLineWidth(2);
    $pdf->SetDrawColor(255, 100, 0);
    $pdf->Line(80, 75, 80 + $graphtax2, 75);
}
$pdf->SetY(72);
$pdf->SetX(80 + $graphtax2 + 3);
$pdf->Cell(25, 5, 'Year ' . $datenext . ' (' . number_format($sumtax2[0], 2) . ')', 0, 0, 'L');
if ($graphfee1 > 0) {
    $pdf->SetLineWidth(2);
开发者ID:laiello,项目名称:ebpls,代码行数:31,代码来源:ebpls_comparative_annual_chart.php

示例7:

 /**
  *   Show table for lines
  *
  *   @param		PDF			$pdf     		Object PDF
  *   @param		string		$tab_top		Top position of table
  *   @param		string		$tab_height		Height of table (rectangle)
  *   @param		int			$nexY			Y
  *   @param		Translate	$outputlangs	Langs object
  *   @param		int			$hidetop		Hide top bar of array
  *   @param		int			$hidebottom		Hide bottom bar of array
  *   @return	void
  */
 function _tableau(&$pdf, $tab_top, $tab_height, $nexY, $outputlangs, $hidetop = 0, $hidebottom = 0)
 {
     global $conf, $mysoc;
     $default_font_size = pdf_getPDFFontSize($outputlangs);
     $pdf->SetDrawColor(128, 128, 128);
     // Rect prend une longueur en 3eme param
     $pdf->Rect($this->marge_gauche, $tab_top, $this->page_largeur - $this->marge_gauche - $this->marge_droite, $tab_height);
     // line prend une position y en 3eme param
     $pdf->line($this->marge_gauche, $tab_top + 6, $this->page_largeur - $this->marge_droite, $tab_top + 6);
     $pdf->SetTextColor(0, 0, 0);
     $pdf->SetFont('', '', $default_font_size);
     $pdf->SetXY($this->posxref, $tab_top + 1);
     $pdf->MultiCell($this->posxlabel - $this->posxref, 3, $outputlangs->transnoentities("Tasks"), '', 'L');
     $pdf->SetXY($this->posxlabel, $tab_top + 1);
     $pdf->MultiCell($this->posxworkload - $this->posxlabel, 3, $outputlangs->transnoentities("Description"), 0, 'L');
     $pdf->SetXY($this->posxworkload, $tab_top + 1);
     $pdf->MultiCell($this->posxprogress - $this->posxworkload, 3, $outputlangs->transnoentities("PlannedWorkloadShort"), 0, 'R');
     $pdf->SetXY($this->posxprogress, $tab_top + 1);
     $pdf->MultiCell($this->posxdatestart - $this->posxprogress, 3, '%', 0, 'R');
     $pdf->SetXY($this->posxdatestart, $tab_top + 1);
     $pdf->MultiCell($this->posxdateend - $this->posxdatestart, 3, '', 0, 'C');
     $pdf->SetXY($this->posxdateend, $tab_top + 1);
     $pdf->MultiCell($this->page_largeur - $this->marge_droite - $this->posxdatestart, 3, '', 0, 'C');
 }
开发者ID:Albertopf,项目名称:prueba,代码行数:36,代码来源:pdf_baleine.modules.php

示例8: fputs

 for ($i = 0; $i < count($data['qty']); $i++) {
     if ($data['qty'][$i] > 0) {
         fputs($f, '"' . $data['description'][$i] . '";"' . $data['partnumber'][$i] . '";' . $data['qty'][$i] . "\n");
     }
 }
 if ($_POST['notiz'] != '') {
     fputs($f, '"###' . $_POST['notiz'] . '"');
 }
 fclose($f);
 $pdf = new PDF();
 $data = $pdf->LoadData($dir . $filecsv);
 $pdf->SetFont('Arial', '', 10);
 $pdf->AddPage();
 $pdf->SetTitle('Packliste ab ' . $datum);
 $pdf->Titel('Packliste ab ' . $datum);
 $pdf->SetDrawColor(255, 255, 255);
 $pdf->BasicTable($data);
 $pdf->Output($dir . $filepdf, "F");
 if (file_exists($dir . $filepdf)) {
     if ($_POST['weg'] == 2) {
         $headers = array("From" => $_SESSION['email'], "X-Mailer" => "PHP/" . phpversion(), "Subject" => 'Packliste ab ' . $datum);
         $mime = new Mail_Mime(array('eol' => "\n"));
         $csv = $mime->addAttachment($dir . $filecsv, mime_content_type($dir . $filecsv), $filecsv);
         $pdf = $mime->addAttachment($dir . $filepdf, mime_content_type($dir . $filepdf), $filepdf);
         $mime->setTXTBody('Packliste');
         $hdrs = $mime->headers($headers);
         $body = $mime->get();
         $mail = Mail::factory("mail");
         $mail->_params = "-f " . $_SESSION['email'];
         $rc = $mail->send($_SESSION['email'], $hdrs, $body);
         $output = 'E-Mail verschickt';
开发者ID:vanloswang,项目名称:kivitendo-crm,代码行数:31,代码来源:packliste.php

示例9: render

 /**
  * PDF Cell renderer
  *
  * @param PDF $pdf
  *
  * @return void
  */
 function render($pdf)
 {
     /**
      * Use these variables to update/manipulate values
      * Repeted classes would reupdate all their class variables again, Header/Page Header/Footer
      * This is the bugfree version
      */
     $cX = 0;
     // Class Left
     // Set up the text style
     if ($pdf->getCurrentStyle() != $this->styleName) {
         $pdf->setCurrentStyle($this->styleName);
     }
     $temptext = str_replace("#PAGENUM#", $pdf->PageNo(), $this->text);
     // underline «title» part of Source item
     $temptext = str_replace(array('«', '»'), array('<u>', '</u>'), $temptext);
     $match = array();
     // Indicates if the cell background must be painted (1) or transparent (0)
     if ($this->fill == 1) {
         if (!empty($this->bgcolor)) {
             // HTML color to RGB
             if (preg_match("/#?(..)(..)(..)/", $this->bgcolor, $match)) {
                 $r = hexdec($match[1]);
                 $g = hexdec($match[2]);
                 $b = hexdec($match[3]);
                 $pdf->SetFillColor($r, $g, $b);
             }
         } else {
             $this->fill = 0;
         }
     }
     // Paint the Border color if set
     if (!empty($this->bocolor)) {
         // HTML color to RGB
         if (preg_match("/#?(..)(..)(..)/", $this->bocolor, $match)) {
             $r = hexdec($match[1]);
             $g = hexdec($match[2]);
             $b = hexdec($match[3]);
             $pdf->SetDrawColor($r, $g, $b);
         }
     }
     // Paint the text color or they might use inherited colors by the previous function
     if (preg_match("/#?(..)(..)(..)/", $this->tcolor, $match)) {
         $r = hexdec($match[1]);
         $g = hexdec($match[2]);
         $b = hexdec($match[3]);
         $pdf->SetTextColor($r, $g, $b);
     } else {
         $pdf->SetTextColor(0, 0, 0);
     }
     // If current position (left)
     if ($this->left == ".") {
         $cX = $pdf->GetX();
     } else {
         $cX = $pdf->addMarginX($this->left);
     }
     // Check the width if set to page wide OR set by xml to larger then page wide
     if ($this->width == 0 || $this->width > $pdf->getRemainingWidthPDF()) {
         $this->width = $pdf->getRemainingWidthPDF();
     }
     // For current position
     if ($this->top == ".") {
         $this->top = $pdf->GetY();
     } else {
         $pdf->SetY($this->top);
     }
     // Check the last cell height and adjust the current cell height if needed
     if ($pdf->lastCellHeight > $this->height) {
         $this->height = $pdf->lastCellHeight;
     }
     // Check for pagebreak
     if (!empty($temptext)) {
         $cHT = $pdf->getNumLines($temptext, $this->width);
         $cHT = $cHT * $pdf->getCellHeightRatio() * $pdf->getCurrentStyleHeight();
         $cM = $pdf->getMargins();
         // Add padding
         if (is_array($cM['cell'])) {
             $cHT += $cM['padding_bottom'] + $cM['padding_top'];
         } else {
             $cHT += $cM['cell'] * 2;
         }
         // Add a new page if needed
         if ($pdf->checkPageBreakPDF($cHT)) {
             $this->top = $pdf->GetY();
         }
         $temptext = spanLTRRTL($temptext, "BOTH");
     }
     // HTML ready - last value is true
     $pdf->MultiCell($this->width, $this->height, $temptext, $this->border, $this->align, $this->fill, $this->newline, $cX, $this->top, $this->reseth, $this->stretch, true);
     // Reset the last cell height for the next line
     if ($this->newline >= 1) {
         $pdf->lastCellHeight = 0;
     } elseif ($pdf->lastCellHeight < $pdf->getLastH()) {
//.........这里部分代码省略.........
开发者ID:sadr110,项目名称:webtrees,代码行数:101,代码来源:PDF.php

示例10: PDF

        $this->Image($file, $x, $y, $w, $h);
        $this->Rotate(0);
    }
}
$pdf = new PDF();
$pdf->AddPage();
$pdf->SetFont('Arial', '', 8);
$pdf->RotatedText(15, 11, utf8_decode('Je soussigné-e                                    formatrice(formateur) au centre de formation                                    certificie que le candidat(la candidate) a bien effectué en formation les activités et missions présentées dans ce tableau'), -90);
$pdf->SetFont('Arial', '', 14);
$pdf->RotatedText(200, 50, utf8_decode('BTS SERVICES INFORMATIQUES AUX ORGANISATIONS-TABLEAU DE SYNTHESE'), -90);
$pdf->SetFont('Arial', '', 12);
$pdf->RotatedText(180, 35, utf8_decode('Nom et prénom du candidat: ' . $nom . ' ' . $prenom . '                    Parcours: ' . $parcours . '                     Numéro du candidat: ' . $numeroINE), -90);
$pdf->SetFont('Arial', '', 5);
$pdf->SetX(30);
$pdf->Cell(15, 4, '', 1, 0, '');
$pdf->SetDrawColor(235, 235, 235);
$pdf->Cell(25, 4, '', 1, 0, '');
$pdf->SetDrawColor(0, 0, 0);
$pdf->Cell(60, 4, '', 1, 0, '');
$pdf->RotatedText(140, 11, 'Situation obligatoire', -90);
$pdf->Cell(20, 16, '', 1, 0, '');
$i = 0;
foreach ($rowsObligatoire as $data) {
    $i = $i + 1;
    $pdf->SetX(30);
    $ref = false;
    foreach ($rowsObligatoireRef as $data1) {
        if ($data['CODEOBLIGATIONSITUATION'] == $data1['codeobligationsituation'] and $data1['nbRef'] > 0) {
            $ref = true;
        }
    }
开发者ID:Shagril,项目名称:gestcomp,代码行数:31,代码来源:pdf.php

示例11: PDF

require_once ".././include/initialize.php";
$oferta = Oferta::find_by_id($_GET['id']);
$apartament = Apartament::find_by_id($oferta->idApartament);
$client = Client::find_by_id($apartament->idClient);
$agent = User::find_by_id($client->idUtilizator);
$pdf = new PDF();
$pdf->AddPage();
$pdf->SetMargins(15, 15);
//descriere proprietate
$pdf->Image(PDF_PATH . DS . 'bara1.png', 15, 45, 130.5);
$pdf->SetFont("Times", "", 14);
$pdf->SetXY(25, 42.5);
$pdf->SetTextColor(255, 255, 255);
$pdf->Cell(15, 11, 'PROPRIETATE ', 0, 1);
$pdf->SetXY(15.35, 51);
$pdf->SetDrawColor(175, 37, 28);
$pdf->SetLineWidth(0.5);
$pdf->Cell(130, 18, "", 1);
// descriere proprietate
$pdf->SetXY(18, 53);
$pdf->SetTextColor(0);
$pdf->Cell(130, 7, $oferta->Titlu);
//$pdf->SetXY(18, 60);
//$pdf->Cell(130,7,$proprietate->Descriere);
//pret
$pdf->Image(PDF_PATH . DS . 'bara2.png', 155, 45, 42);
$pdf->SetFont("Times", "", 14);
$pdf->SetXY(165, 42.5);
$pdf->SetTextColor(255, 255, 255);
$pdf->Cell(15, 11, 'PRET', 0, 1);
$pdf->SetXY(155.35, 51);
开发者ID:hionuth,项目名称:Imob2009,代码行数:31,代码来源:ofertapdf.php

示例12: Datos

    $pdf->Valor($participante['p_nserie_ipad']);
    $pdf->Ln(14);
    //$pdf->Cell(10);
    //$pdf->MultiCell(170,6,utf8_decode(''),'',1,'L',1);
    //$pdf->Cell(0);
    //$pdf->Ln(28);
    $pdf->SetFont('Helvetica', 'B', 12);
    $pdf->Cell(0, 6, utf8_decode('Certifico que los datos aquí expuestos son verídicos.'), '', 1, 'C');
    $pdf->Ln(8);
    $pdf->SetFont('Helvetica', '', 12);
    $pdf->Cell(0, 6, utf8_decode($fecha_validacion), '', 1, 'C');
    $pdf->Ln(8);
    $pdf->Cell(0, 6, '___________________________________', '', 1, 'C');
    $pdf->Cell(0, 6, utf8_decode($nombre_participante), '', 1, 'C');
    // ley de protección
    $pdf->Ln(20);
    $pdf->SetFont('Helvetica', '', 8);
    $pdf->SetFillColor(255, 255, 255);
    $pdf->SetTextColor(107, 107, 107);
    $pdf->SetDrawColor(239, 239, 239);
    $pdf->MultiCell(0, 6, utf8_decode('Los datos personales que nos proporcione serán protegidos conforme a lo dispuesto por la Ley Federal de Transparencia y Acceso a la Información Pública Gubernamental, los cuales serán incorporados y tratados en el sistema de datos personales denominado REGISTRO DE ORIENTACIÓN A LOS PARTICULARES. Dicho sistema fue registrado en el listado de sistemas de datos personales que administra el Instituto Federal de Acceso a la Información y Protección de Datos (www.ifai.mx).'), 'B', 1, 'L', 1);
    $pdf->Output();
    ?>

<?php 
}
// end of the loop.
?>

<?php 
//get_footer();
开发者ID:hibamiru,项目名称:app.emobile.mx,代码行数:31,代码来源:imprimir-pdf.php

示例13: PDF

        //largor,ubicacion derecha,inicio,ubicacion izquierda
    }
}
$pdf = new PDF();
//'P'=vertical o 'L'=horizontal,'mm','A4' o 'Legal'
$pdf->AddPage('L', 'Legal');
$pdf->AliasNbPages();
$pdf->SetFont('Arial', 'B', 16);
$pdf->SetTitle('LISTADO DE SUELDOS');
$pdf->Cell(300, 10, 'Listado Sueldos por Funcionario', 100, 100, 'C');
//Titulo
//Set font and colors
$pdf->SetFont('Arial', 'B', 10);
$pdf->SetFillColor(153, 192, 141);
$pdf->SetTextColor(255);
$pdf->SetDrawColor(153, 192, 141);
$pdf->SetLineWidth(0.3);
//Table header
/*$pdf->Cell(20,10,'SIAPE',1,0,'L',1);
$pdf->Cell(50,10,'Nome',1,1,'L',1);*/
$pdf->Cell(15, 10, 'Item', 1, 0, 'C', 1);
$pdf->Cell(55, 10, 'Funcionario', 1, 0, 'C', 1);
$pdf->Cell(20, 10, 'Fecha', 1, 0, 'C', 1);
$pdf->Cell(25, 10, 'Sueldo Bruto', 1, 0, 'C', 1);
$pdf->Cell(25, 10, 'IPS', 1, 0, 'C', 1);
$pdf->Cell(25, 10, 'Ausencia', 1, 0, 'C', 1);
$pdf->Cell(25, 10, 'Permisos', 1, 0, 'C', 1);
$pdf->Cell(25, 10, 'Judicial', 1, 0, 'C', 1);
$pdf->Cell(25, 10, 'ASO', 1, 0, 'C', 1);
$pdf->Cell(25, 10, 'Reposo', 1, 0, 'C', 1);
$pdf->Cell(30, 10, 'Otros Descuentos', 1, 0, 'C', 1);
开发者ID:mriveros,项目名称:PHPESTACIONES,代码行数:31,代码来源:ResumenSueldoFunc.php

示例14:

 /**
  *   Show table for lines
  *
  *   @param		PDF			$pdf     		Object PDF
  *   @param		string		$tab_top		Top position of table
  *   @param		string		$tab_height		Height of table (rectangle)
  *   @param		int			$nexY			Y
  *   @param		Translate	$outputlangs	Langs object
  *   @param		int			$hidetop		Hide top bar of array
  *   @param		int			$hidebottom		Hide bottom bar of array
  *   @return	void
  */
 function _tableau(&$pdf, $tab_top, $tab_height, $nexY, $outputlangs, $hidetop = 0, $hidebottom = 0)
 {
     global $conf, $mysoc;
     $default_font_size = pdf_getPDFFontSize($outputlangs);
     $pdf->SetDrawColor(128, 128, 128);
     // Rect prend une longueur en 3eme param
     $pdf->Rect($this->marge_gauche, $tab_top, $this->page_largeur - $this->marge_gauche - $this->marge_droite, $tab_height);
     // line prend une position y en 3eme param
     $pdf->line($this->marge_gauche, $tab_top + 6, $this->page_largeur - $this->marge_droite, $tab_top + 6);
     $pdf->SetTextColor(0, 0, 0);
     $pdf->SetFont('', '', $default_font_size);
     $pdf->SetXY($this->posxref - 1, $tab_top + 2);
     $pdf->MultiCell(80, 2, $outputlangs->transnoentities("Tasks"), '', 'L');
 }
开发者ID:LionSystemsSolutions,项目名称:El-Canelo-ERP,代码行数:26,代码来源:pdf_baleine.modules.php

示例15: home__memberlist_printview

function home__memberlist_printview()
{
    global $base_url, $files_dir, $config;
    // $content='<html><head><meta http-equiv="Content-Type" content="application/pdf; charset=utf-8" />';
    // drupal_add_css(BOOTSTRAP.'/css/bootstrap.min.css');
    // drupal_add_css(CHURCHDB.'/cdb_printview.css');
    // $content=$content.drupal_get_header();
    if (!user_access("view memberliste", "churchdb")) {
        addErrorMessage(t("no.permission.for", t("list.of.members")));
        return " ";
    }
    require_once ASSETS . '/fpdf17/fpdf.php';
    $compact = true;
    if (isset($_GET["compact"])) {
        $compact = $_GET["compact"];
    }
    // Instanciation of inherited class
    $pdf = new PDF('P', 'mm', 'A4');
    $pdf->AliasNbPages();
    $pdf->AddPage();
    $pdf->SetFont('Arial', '', 9);
    $res = home_getMemberList();
    $pdf->SetLineWidth(0.4);
    $pdf->SetDrawColor(200, 200, 200);
    $fields = _home__memberlist_getSettingFields()->fields;
    foreach ($res as $p) {
        $pdf->Line(8, $pdf->GetY() - 1, 204, $pdf->GetY() - 1);
        $pdf->Cell(10, 10, "", 0);
        if ($p->imageurl == null || !file_exists("{$files_dir}/fotos/{$p->imageurl}")) {
            $p->imageurl = "nobody.gif";
        }
        $pdf->Image("{$files_dir}/fotos/{$p->imageurl}", $pdf->GetX() - 10, $pdf->GetY() + 1, 9);
        $pdf->Cell(2);
        $pdf->Cell(13, 9, $p->anrede, 0, 0, 'L');
        $pdf->Cell(48, 9, utf8_decode("{$p->name}, {$p->vorname}"), 0, 0, 'L');
        $pdf->Cell(45, 9, utf8_decode("{$p->strasse}"), 0, 0, 'L');
        // TODO: second occurence of code part - whats this for?
        $birthday = "";
        if ($p->geburtsdatum != null) {
            if ($p->year < 7000) {
                $birthday = "{$p->day}.{$p->month}.";
            }
            if ($p->year != 1004 && $fields["memberlist_birthday_full"]->getValue()) {
                if ($p->year < 7000) {
                    $birthday = $birthday . $p->year;
                } else {
                    $birthday = $birthday . $p->year - 7000;
                }
            }
        }
        $pdf->Cell(20, 9, $birthday, 0, 0, 'L');
        if ($fields["memberlist_telefonprivat"]->getValue() && $p->telefonprivat != "") {
            $pdf->Cell(30, 9, $p->telefonprivat, 0, 0, 'L');
        } else {
            if ($fields["memberlist_telefongeschaeftlich"]->getValue() && $p->telefongeschaeftlich != "") {
                $pdf->Cell(30, 9, $p->telefongeschaeftlich, 0, 0, 'L');
            } else {
                if ($fields["memberlist_telefongeschaeftlich"]->getValue() && $p->fax != "") {
                    $pdf->Cell(30, 9, $p->fax . " (Fax)", 0, 0, 'L');
                } else {
                    $pdf->Cell(30, 9, "", 0, 0, 'L');
                }
            }
        }
        if ($fields["memberlist_telefonhandy"]->getValue() && $p->telefonhandy != "") {
            $pdf->Cell(30, 9, $p->telefonhandy, 0, 0, 'L');
        }
        // Zeilenumbruch
        $pdf->Ln(5);
        $pdf->Cell(73);
        $pdf->Cell(48, 10, "{$p->plz} " . utf8_decode($p->ort), 0, 0, 'L');
        $pdf->Cell(17);
        if ($fields["memberlist_email"]->getValue() && $p->email != "") {
            $pdf->SetFont('Arial', '', 8);
            $pdf->Cell(30, 9, $p->email);
            $pdf->SetFont('Arial', '', 9);
        }
        $pdf->Ln(12);
    }
    $pdf->Output(t("list.of.members") . '.pdf', 'I');
}
开发者ID:lhaselauer,项目名称:churchtools_basic,代码行数:81,代码来源:home.php


注:本文中的PDF::SetDrawColor方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。