Location: PHPKode > projects > Lithron > lithron-1.0.2/examples/bug103-image_mode_clip.xml.php
<?php echo '<?xml version="1.0" encoding="UTF-8"?>'; ?>
<lithron>
	<style>
		page.A4 {
            height: 297mm;
            width: 210mm
        }

        wrapper {
            display: block;
            margin-top: 2cm;
            margin-right: 3cm;
            margin-bottom: 2cm;
            margin-left: 2cm;
        }
        
        image
        {
            width: 3cm;
            height: 3cm;
            background-color: cmyk(0,0,0,10);
        }

	</style>

    <file name="<?php echo "lithron-".basename(__FILE__,"xml.php")."pdf" ?>">
		<page class="A4">
            <wrapper>
			<h1>Image Modes</h1>
			<h2>clip</h2>
            <image
                img-position-mode="clip"
                src="<?php echo dirname(__FILE__)."/media/test1.tif" ?>" />
			<h2>clip, scale 0.1</h2>
            <image
                img-position-mode="clip"
                img-scale="0.1"
                src="<?php echo dirname(__FILE__)."/media/test1.tif" ?>" />
			<h2>clip, scale 0.1, img-position-x: 0.5, img-position-y: 0.5</h2>
            <image
                img-position-mode="clip"
                img-scale="0.1"
                img-position-x="0.5"
                img-position-y="0.5"
                src="<?php echo dirname(__FILE__)."/media/test1.tif" ?>" />
			<h2>clip, scale 0.1, img-position-x: -0.5, img-position-y: 0.5</h2>
            <image
                img-position-mode="clip"
                img-scale="0.1"
                img-position-x="-0.5"
                img-position-y="0.5"
                src="<?php echo dirname(__FILE__)."/media/test1.tif" ?>" />
            </wrapper>
        </page>
	</file>


	
</lithron>
Return current item: Lithron