예제 #1
0
파일: ps.php 프로젝트: abbeet/server39
            $y -= 150;
            $x = 0;
        }
        begin_example_box($ps, LEFT_BORDER + (EXAMPLE_BOX_WIDTH + 30) * $x++, $y, "Text in a box (2)", $psfont);
        ps_setfont($ps, $psfont, 8.0);
        ps_set_value($ps, "leading", 11);
        $str2 = "Text can be put into a box of any size. This one is 80x80 pixels and its lower left corner ist at (10, 10). The text is left and right justified. The font size is 8.0.";
        ps_show_boxed($ps, $str2, 10, 10, 80, 80, "justify", NULL);
        end_example_box($ps);
    }
    if (isset($_REQUEST['box16']) && $_REQUEST['box16'] == "true") {
        if ($x > 3) {
            $y -= 150;
            $x = 0;
        }
        begin_example_box($ps, LEFT_BORDER + (EXAMPLE_BOX_WIDTH + 30) * $x++, $y, "Text with CR", $psfont);
        ps_setfont($ps, $psfont, 8.0);
        ps_set_value($ps, "leading", 11);
        ps_set_parameter($ps, "linebreak", "true");
        $str4 = "If the parameter linebreak is turned on\neach line will be ended with a carriage return.\nCR are marked with a '\\n' in this paragraph.";
        ps_show_boxed($ps, $str4, 10, 10, 80, 80, "center", NULL);
        ps_set_parameter($ps, "linebreak", "false");
        end_example_box($ps);
    }
    ps_end_page($ps);
    ps_close($ps);
    ps_delete($ps);
}
for ($x = 1; $x <= 16; $x++) {
    $checked[$x] = "";
}
예제 #2
0
파일: image.php 프로젝트: promoso/HVAC
$psfont = ps_findfont($ps, "Helvetica", "", 0);
ps_setfont($ps, $psfont, 12.0);
$x = 0;
$y = 625;
begin_example_box($ps, LEFT_BORDER + (EXAMPLE_BOX_WIDTH + 30) * $x++, $y, "Gif image", $psfont);
$psimage = ps_open_image_file($ps, "gif", "debian.gif", NULL, 0);
ps_place_image($ps, $psimage, 25, 10, 2.0);
end_example_box($ps);
begin_example_box($ps, LEFT_BORDER + (EXAMPLE_BOX_WIDTH + 30) * $x++, $y, "Gif image with transparency", $psfont);
$psimage = ps_open_image_file($ps, "gif", "debian-transparent.gif", NULL, 0);
ps_place_image($ps, $psimage, 25, 10, 2.0);
end_example_box($ps);
begin_example_box($ps, LEFT_BORDER + (EXAMPLE_BOX_WIDTH + 30) * $x++, $y, "Gif image interlaced", $psfont);
$psimage = ps_open_image_file($ps, "gif", "interlaced.gif", NULL, 0);
ps_place_image($ps, $psimage, 10, 10, 0.65);
end_example_box($ps);
$x = 0;
$y = 405;
begin_example_box($ps, LEFT_BORDER + (EXAMPLE_BOX_WIDTH + 30) * $x++, $y, "Tiff image", $psfont);
$psimage = ps_open_image_file($ps, "tiff", "debian.tiff", NULL, 0);
ps_place_image($ps, $psimage, 25, 10, 2.0);
end_example_box($ps);
$x = 0;
$y = 185;
begin_example_box($ps, LEFT_BORDER + (EXAMPLE_BOX_WIDTH + 30) * $x++, $y, "Bmp image", $psfont);
$psimage = ps_open_image_file($ps, "bmp", "debian.bmp", NULL, 0);
ps_place_image($ps, $psimage, 25, 10, 2.0);
end_example_box($ps);
ps_end_page($ps);
ps_close($ps);
ps_delete($ps);