Sophie

Sophie

distrib > Mandriva > 2008.1 > x86_64 > by-pkgid > 05cd670d8a02b2b4a0ffb1756f2e8308 > files > 3943

php-manual-zh-5.2.4-1mdv2008.1.noarch.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<HTML
><HEAD
><TITLE
>ps_show_boxed</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.79"><LINK
REL="HOME"
TITLE="PHP 手册"
HREF="index.html"><LINK
REL="UP"
TITLE="PostScript document creation"
HREF="ref.ps.html"><LINK
REL="PREVIOUS"
TITLE="ps_shfill"
HREF="function.ps-shfill.html"><LINK
REL="NEXT"
TITLE="ps_show_xy2"
HREF="function.ps-show-xy2.html"><META
HTTP-EQUIV="Content-type"
CONTENT="text/html; charset=UTF-8"></HEAD
><BODY
CLASS="refentry"
BGCOLOR="#FFFFFF"
TEXT="#000000"
LINK="#0000FF"
VLINK="#840084"
ALINK="#0000FF"
><DIV
CLASS="NAVHEADER"
><TABLE
SUMMARY="Header navigation table"
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TH
COLSPAN="3"
ALIGN="center"
>PHP 手册</TH
></TR
><TR
><TD
WIDTH="10%"
ALIGN="left"
VALIGN="bottom"
><A
HREF="function.ps-shfill.html"
ACCESSKEY="P"
>上一页</A
></TD
><TD
WIDTH="80%"
ALIGN="center"
VALIGN="bottom"
></TD
><TD
WIDTH="10%"
ALIGN="right"
VALIGN="bottom"
><A
HREF="function.ps-show-xy2.html"
ACCESSKEY="N"
>下一页</A
></TD
></TR
></TABLE
><HR
ALIGN="LEFT"
WIDTH="100%"></DIV
><H1
><A
NAME="function.ps-show-boxed"
></A
>ps_show_boxed</H1
><DIV
CLASS="refnamediv"
><A
NAME="AEN193611"
></A
><P
>    (PECL)</P
>ps_show_boxed&nbsp;--&nbsp;Output text in a box</DIV
><DIV
CLASS="refsect1"
><A
NAME="AEN193614"
></A
><H2
>说明</H2
>int <B
CLASS="methodname"
>ps_show_boxed</B
> ( resource psdoc, string text, float left, float bottom, float width, float height, string hmode [, string feature] )<BR
></BR
><P
>&#13;   Outputs a text in a given box. The lower left corner of the box is at
   (<CODE
CLASS="parameter"
>left</CODE
>, <CODE
CLASS="parameter"
>bottom</CODE
>). Line breaks
   will be inserted where needed. Multiple spaces are treated as one.
   Tabulators are treated as spaces.
  </P
><P
>&#13;   The text will be hyphenated if the parameter
   <CODE
CLASS="parameter"
>hyphenation</CODE
> is set to <TT
CLASS="literal"
>true</TT
>
   and the parameter <CODE
CLASS="parameter"
>hyphendict</CODE
> contains a valid
   filename for a hyphenation
   file. The line spacing is taken from the value <TT
CLASS="literal"
>leading</TT
>.
   Paragraphs can be
   separated by an empty line just like in TeX. If the value
   <TT
CLASS="literal"
>parindent</TT
> is
   set to value &#62; 0.0 then the first n lines will be indented. The number n
   of lines is set by the parameter <TT
CLASS="literal"
>numindentlines</TT
>.
   In order to prevent
   indenting of the first m paragraphs set the value
   <TT
CLASS="literal"
>parindentskip</TT
> to a
   positive number.
  </P
></DIV
><DIV
CLASS="refsect1"
><A
NAME="AEN193654"
></A
><H2
>参数</H2
><P
>&#13;   <P
></P
><DIV
CLASS="variablelist"
><DL
><DT
><CODE
CLASS="parameter"
>psdoc</CODE
></DT
><DD
><P
>&#13;       Resource identifier of the postscript file
       as returned by <A
HREF="function.ps-new.html"
><B
CLASS="function"
>ps_new()</B
></A
>.
      </P
></DD
><DT
><CODE
CLASS="parameter"
>text</CODE
></DT
><DD
><P
>&#13;       The text to be output into the given box.
      </P
></DD
><DT
><CODE
CLASS="parameter"
>left</CODE
></DT
><DD
><P
>&#13;       x-coordinate of the lower left corner of the box.
      </P
></DD
><DT
><CODE
CLASS="parameter"
>bottom</CODE
></DT
><DD
><P
>&#13;       y-coordinate of the lower left corner of the box.
      </P
></DD
><DT
><CODE
CLASS="parameter"
>width</CODE
></DT
><DD
><P
>&#13;       Width of the box.
      </P
></DD
><DT
><CODE
CLASS="parameter"
>height</CODE
></DT
><DD
><P
>&#13;       Height of the box.
      </P
></DD
><DT
><CODE
CLASS="parameter"
>hmode</CODE
></DT
><DD
><P
>&#13;       The parameter <CODE
CLASS="parameter"
>hmode</CODE
> can be "justify",
       "fulljustify", "right", "left", or "center". The difference of
       "justify" and "fulljustify" just affects the last line of the box. In
       fulljustify mode the last line will be left and right justified unless
       this is also the last line of paragraph. In justify mode it will always
       be left justified.
      </P
></DD
><DT
><CODE
CLASS="parameter"
>feature</CODE
></DT
><DD
><P
>&#13;       
      </P
></DD
></DL
></DIV
>
  </P
></DIV
><DIV
CLASS="refsect1"
><A
NAME="AEN193700"
></A
><H2
>Used parameters</H2
><P
>&#13;   The output of <B
CLASS="function"
>ps_show_boxed()</B
> can be configured with
   several parameters and values which must be set with either
   <A
HREF="function.ps-set-parameter.html"
><B
CLASS="function"
>ps_set_parameter()</B
></A
> or <A
HREF="function.ps-set-value.html"
><B
CLASS="function"
>ps_set_value()</B
></A
>.
   Beside the parameters and values which affect text output, the following
   parameters and values are evaluated.
   <P
></P
><DIV
CLASS="variablelist"
><DL
><DT
>leading (value)</DT
><DD
><P
>Distance between baselines of two consecutive lines.</P
></DD
><DT
>linebreak (parameter)</DT
><DD
><P
>&#13;       Set to "true" if you want a carriage return to start a new line instead
       of treating it as a space. Defaults to "false".
      </P
></DD
><DT
>parbreak (parameter)</DT
><DD
><P
>&#13;       Set to "true" if you want a carriage return on a single line to start a
       new paragraph instead of treating it as a space. Defaults to "true".
      </P
></DD
><DT
>hyphenation (parameter)</DT
><DD
><P
>&#13;       Set to "true" in order to turn hyphenation on. This requires a
       dictionary to be set with the parameter "hyphendict". Defaults to
       "false".
      </P
></DD
><DT
>hyphendict (parameter)</DT
><DD
><P
>&#13;       Filename of the dictionary used for hyphenation pattern (see below).
      </P
></DD
><DT
>hyphenminchar (value)</DT
><DD
><P
>&#13;       The number of chars which must at least be left over before or after
       the hyphen. This implies that only words of at least two times this
       value will be hyphenated. The default value is three. Setting a value
       of zero will result in the default value.
      </P
></DD
><DT
>parindent (value)</DT
><DD
><P
>&#13;       Set the amount of space in pixel for indenting the first m lines of a
       paragraph. m can be set with the value "numindentlines".
      </P
></DD
><DT
>parskip (value)</DT
><DD
><P
>&#13;       Set the amount of extra space in pixel between paragraphs. Defaults to
       0 which will result in a normal line distance.
      </P
></DD
><DT
>numindentlines (value)</DT
><DD
><P
>&#13;       Number of lines from the start of the paragraph which will be indented.
       Defaults to 1.
      </P
></DD
><DT
>parindentskip (value)</DT
><DD
><P
>&#13;       Number of paragraphs in the box whose first lines will not be indented.
       This defaults to 0. This is useful for paragraphs right after a section
       heading or text being continued in a second box. In both case one would
       set this to 1.
      </P
></DD
><DT
>linenumbermode (parameter)</DT
><DD
><P
>&#13;       Set how lines are to be numbered. Possible values are "box" for
       numbering lines in the whole box or "paragraph" to number lines within
       each paragraph.
      </P
></DD
><DT
>linenumberspace (value)</DT
><DD
><P
>&#13;       The space for the column left of the numbered line containing the line
       number. The line number will be right justified into this column.
       Defaults to 20.
      </P
></DD
><DT
>linenumbersep (value)</DT
><DD
><P
>&#13;       The space between the column with line numbers and the line itself.
       Defaults to 5.
      </P
></DD
></DL
></DIV
>
  </P
></DIV
><DIV
CLASS="refsect1"
><A
NAME="AEN193759"
></A
><H2
>Hyphenation</H2
><P
>&#13;   Text is hyphenated if the parameter <TT
CLASS="literal"
>hyphenation</TT
> is set
   to true and a valid hyphenation dictionary is set. pslib does not ship its own
   hyphenation dictionary but uses one from openoffice, scribus or koffice.
   You can find their dictionaries for different languages in one of the
   following directories if the software is installed:
   <P
></P
><TABLE
BORDER="0"
><TBODY
><TR
><TD
>&#13;     <TT
CLASS="filename"
>/usr/share/apps/koffice/hyphdicts/</TT
>
    </TD
></TR
><TR
><TD
>&#13;     <TT
CLASS="filename"
>/usr/lib/scribus/dicts/</TT
>
    </TD
></TR
><TR
><TD
>&#13;     <TT
CLASS="filename"
>/usr/lib/openoffice/share/dict/ooo/</TT
>
    </TD
></TR
></TBODY
></TABLE
><P
></P
>
   Currently scribus appears to have the most complete hyphenation
   dictionaries.
  </P
></DIV
><DIV
CLASS="refsect1"
><A
NAME="AEN193770"
></A
><H2
>返回值</H2
><P
>&#13;   Number of characters that could not be written.
  </P
></DIV
><DIV
CLASS="refsect1"
><A
NAME="AEN193773"
></A
><H2
>参见</H2
><P
>&#13;   <P
></P
><TABLE
BORDER="0"
><TBODY
><TR
><TD
><A
HREF="function.ps-continue-text.html"
><B
CLASS="function"
>ps_continue_text()</B
></A
></TD
></TR
></TBODY
></TABLE
><P
></P
>
  </P
></DIV
><DIV
CLASS="NAVFOOTER"
><HR
ALIGN="LEFT"
WIDTH="100%"><TABLE
SUMMARY="Footer navigation table"
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
><A
HREF="function.ps-shfill.html"
ACCESSKEY="P"
>上一页</A
></TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="index.html"
ACCESSKEY="H"
>起始页</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
><A
HREF="function.ps-show-xy2.html"
ACCESSKEY="N"
>下一页</A
></TD
></TR
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
>ps_shfill</TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="ref.ps.html"
ACCESSKEY="U"
>上一级</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
>ps_show_xy2</TD
></TR
></TABLE
></DIV
></BODY
></HTML
>