cvs: phpdoc /en/reference/imagick/imagick newimage.xml
| From: | Mikko Koppanen | Date: | Sun, 07 Oct 2007 12:17:47 +0000 |
| Subject: | cvs: phpdoc /en/reference/imagick/imagick newimage.xml | ||
| Groups: | php.doc.cvs | ||
| Request: | Send a blank email to doc-cvs+get-164@lists.php.net to get a copy of this message | ||
mkoppanen Sun Oct 7 12:17:47 2007 UTC
Modified files:
/phpdoc/en/reference/imagick/imagick newimage.xml
Log:
Added documentation for the optional parameter
Added an example
http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/imagick/imagick/newimage.xml?r1=1.5&r2=1.6&diff_format=u
Index: phpdoc/en/reference/imagick/imagick/newimage.xml
diff -u phpdoc/en/reference/imagick/imagick/newimage.xml:1.5
phpdoc/en/reference/imagick/imagick/newimage.xml:1.6
--- phpdoc/en/reference/imagick/imagick/newimage.xml:1.5 Tue Aug 28 02:02:52 2007
+++ phpdoc/en/reference/imagick/imagick/newimage.xml Sun Oct 7 12:17:46 2007
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="iso-8859-1"?>
-<!-- $Revision: 1.5 $ -->
+<!-- $Revision: 1.6 $ -->
<refentry xmlns="http://docbook.org/ns/docbook"
xml:id="function.imagick-newimage">
<refnamediv>
<refname>Imagick::newImage</refname>
@@ -13,6 +13,7 @@
<methodparam><type>int</type><parameter>cols</parameter></methodparam>
<methodparam><type>int</type><parameter>rows</parameter></methodparam>
<methodparam><type>ImagickPixel</type><parameter>background</parameter></methodparam>
+ <methodparam
choice="opt"><type>string</type><parameter>format</parameter></methodparam>
</methodsynopsis>
&warn.undocumented.func;
&warn.experimental.func;
@@ -29,6 +30,7 @@
<term><parameter>cols</parameter></term>
<listitem>
<para>
+ Columns in the new image
</para>
</listitem>
</varlistentry>
@@ -36,6 +38,7 @@
<term><parameter>rows</parameter></term>
<listitem>
<para>
+ Rows in the new image
</para>
</listitem>
</varlistentry>
@@ -43,6 +46,15 @@
<term><parameter>background</parameter></term>
<listitem>
<para>
+ The background color used for this image
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><parameter>format</parameter></term>
+ <listitem>
+ <para>
+ Image format
</para>
</listitem>
</varlistentry>
@@ -90,36 +102,31 @@
</refsect1>
-->
- <!-- Use when examples exist
<refsect1 role="examples">
&reftitle.examples;
<para>
<example>
- <title>A <function>Imagick::newImage</function> example</title>
+ <title>Using <function>Imagick::newImage</function>:</title>
<para>
- Any text that describes the purpose of the example, or
- what goes on in the example should go here (inside the
- <example> tag, not out
+ Create a new image and display it.
</para>
<programlisting role="php">
<![CDATA[
<?php
-if ($anexample === true) {
- echo 'Use the PEAR Coding Standards';
-}
+
+$image = new Imagick();
+$image->newImage(100, 100, new ImagickPixel('red'));
+$image->setImageFormat('png');
+
+header('Content-type: image/png');
+echo $image;
+
?>
]]>
</programlisting>
- &example.outputs;
- <screen>
-<![CDATA[
-Use the PEAR Coding Standards
-]]>
- </screen>
</example>
</para>
</refsect1>
- -->
<!-- Use when adding See Also links
<refsect1 role="seealso">