<?xml version="1.0" encoding="UTF-8"?>
<!--
 * Scilab ( https://www.scilab.org/ ) - This file is part of Scilab
 * Copyright (C) ENPC - Jean-Philippe Chancelier
 *
 * Copyright (C) 2012 - 2016 - Scilab Enterprises
 *
 * This file is hereby licensed under the terms of the GNU GPL v2.0,
 * pursuant to article 5.3.4 of the CeCILL v.2.1.
 * This file was originally licensed under the terms of the CeCILL v2.1,
 * and continues to be available under such terms.
 * For more information, see the COPYING file which you should have received
 * along with this program.
 *
 -->
<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns3="http://www.w3.org/1999/xhtml" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" xmlns:scilab="http://www.scilab.org" xml:id="xpoly" xml:lang="pt">
    <refnamediv>
        <refname>xpoly</refname>
        <refpurpose>desenha uma poligonal ou um polígono</refpurpose>
    </refnamediv>
    <refsynopsisdiv>
        <title>Seqüência de Chamamento</title>
        <synopsis>xpoly(xv,yv [,dtype [,close]])</synopsis>
    </refsynopsisdiv>
    <refsection>
        <title>Parâmetros</title>
        <variablelist>
            <varlistentry>
                <term>xv,yv</term>
                <listitem>
                    <para>matrizes de mesmo tamanho (os pontos da poligonal). </para>
                </listitem>
            </varlistentry>
            <varlistentry>
                <term>dtype</term>
                <listitem>
                    <para>string (estilo de desenho). O valor padrão é "lines". </para>
                </listitem>
            </varlistentry>
            <varlistentry>
                <term>close</term>
                <listitem>
                    <para>inteiro. Se close= 1,a poligonal é fechada; o valor padrão é
                        0.
                    </para>
                </listitem>
            </varlistentry>
        </variablelist>
    </refsection>
    <refsection>
        <title>Descrição</title>
        <para>
            <literal>xpoly</literal> desenha uma poligonal descrita pelos
            vetores de coordenadas <literal>xv</literal> e <literal>yv</literal>. Se
            <literal>xv</literal> e <literal>yv</literal> forem matrizes, serão
            considerados vetores obtidos por concatenação de suas colunas.
            <literal>dtype</literal> pode ser <literal>"lines"</literal> para uso do
            estilo de linha corrente ou <literal>"marks"</literal> para utilizar a
            marca corrente para desenho da poligonal.
        </para>
    </refsection>
    <refsection>
        <title>Exemplos</title>
        <programlisting role="example"><![CDATA[
x = sin(2*%pi*(0:4)/5);
y = cos(2*%pi*(0:4)/5);

plot2d(0,0,-1,"010"," ",[-1,-1,1,1])  // draw an empty bounded axes
xpoly(x, y)
set(gce(), "foreground", color("red"), "closed", "on");
    ]]></programlisting>
        <scilab:image>
          x = sin(2*%pi*(0:4)/5);
          y = cos(2*%pi*(0:4)/5);
          plot2d(0,0,-1,"010"," ",[-1,-1,1,1])
          xpoly(x, y)
          set(gce(), "foreground", color("red"), "closed", "on");
          gcf().axes_size = [300 300];
        </scilab:image>
    </refsection>
    <refsection role="see also">
        <title>Ver Também</title>
        <simplelist type="inline">
            <member>
                <link linkend="xfpoly">xfpoly</link>
            </member>
            <member>
                <link linkend="xfpolys">xfpolys</link>
            </member>
            <member>
                <link linkend="xpolys">xpolys</link>
            </member>
        </simplelist>
    </refsection>
</refentry>
