📄 fieldview.html
字号:
<A NAME="paint(java.awt.Graphics, java.awt.Shape)"><!-- --></A><H3>paint</H3><PRE>public void <B>paint</B>(<A HREF="../../../java/awt/Graphics.html">Graphics</A> g, <A HREF="../../../java/awt/Shape.html">Shape</A> a)</PRE><DL><DD>Renders using the given rendering surface and area on that surface. The view may need to do layout and create child views to enable itself to render into the given allocation.<DD><DL><DT><B>Overrides:</B><DD><CODE><A HREF="../../../javax/swing/text/PlainView.html#paint(java.awt.Graphics, java.awt.Shape)">paint</A></CODE> in class <CODE><A HREF="../../../javax/swing/text/PlainView.html">PlainView</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>g</CODE> - the rendering surface to use<DD><CODE>a</CODE> - the allocated region to render into<DT><B>See Also: </B><DD><A HREF="../../../javax/swing/text/View.html#paint(java.awt.Graphics, java.awt.Shape)"><CODE>View.paint(java.awt.Graphics, java.awt.Shape)</CODE></A></DL></DD></DL><HR><A NAME="getPreferredSpan(int)"><!-- --></A><H3>getPreferredSpan</H3><PRE>public float <B>getPreferredSpan</B>(int axis)</PRE><DL><DD>Determines the preferred span for this view along an axis.<DD><DL><DT><B>Overrides:</B><DD><CODE><A HREF="../../../javax/swing/text/PlainView.html#getPreferredSpan(int)">getPreferredSpan</A></CODE> in class <CODE><A HREF="../../../javax/swing/text/PlainView.html">PlainView</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>axis</CODE> - may be either View.X_AXIS or View.Y_AXIS</DL></DD></DL><HR><A NAME="getResizeWeight(int)"><!-- --></A><H3>getResizeWeight</H3><PRE>public int <B>getResizeWeight</B>(int axis)</PRE><DL><DD>Determines the resizability of the view along the given axis. A value of 0 or less is not resizable.<DD><DL><DT><B>Overrides:</B><DD><CODE><A HREF="../../../javax/swing/text/View.html#getResizeWeight(int)">getResizeWeight</A></CODE> in class <CODE><A HREF="../../../javax/swing/text/View.html">View</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>axis</CODE> - View.X_AXIS or View.Y_AXIS<DT><B>Returns:</B><DD>the weight -> 1 for View.X_AXIS, else 0</DL></DD></DL><HR><A NAME="modelToView(int, java.awt.Shape, javax.swing.text.Position.Bias)"><!-- --></A><H3>modelToView</H3><PRE>public <A HREF="../../../java/awt/Shape.html">Shape</A> <B>modelToView</B>(int pos, <A HREF="../../../java/awt/Shape.html">Shape</A> a, <A HREF="../../../javax/swing/text/Position.Bias.html">Position.Bias</A> b) throws <A HREF="../../../javax/swing/text/BadLocationException.html">BadLocationException</A></PRE><DL><DD>Provides a mapping from the document model coordinate space to the coordinate space of the view mapped to it.<DD><DL><DT><B>Overrides:</B><DD><CODE><A HREF="../../../javax/swing/text/PlainView.html#modelToView(int, java.awt.Shape, javax.swing.text.Position.Bias)">modelToView</A></CODE> in class <CODE><A HREF="../../../javax/swing/text/PlainView.html">PlainView</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>pos</CODE> - the position to convert >= 0<DD><CODE>a</CODE> - the allocated region to render into<DT><B>Returns:</B><DD>the bounding box of the given position<DT><B>Throws:</B><DD><CODE><A HREF="../../../javax/swing/text/BadLocationException.html">BadLocationException</A></CODE> - if the given position does not represent a valid location in the associated document<DT><B>See Also: </B><DD><A HREF="../../../javax/swing/text/View.html#modelToView(int, java.awt.Shape, javax.swing.text.Position.Bias)"><CODE>View.modelToView(int, java.awt.Shape, javax.swing.text.Position.Bias)</CODE></A></DL></DD></DL><HR><A NAME="viewToModel(float, float, java.awt.Shape, javax.swing.text.Position.Bias[])"><!-- --></A><H3>viewToModel</H3><PRE>public int <B>viewToModel</B>(float fx, float fy, <A HREF="../../../java/awt/Shape.html">Shape</A> a, <A HREF="../../../javax/swing/text/Position.Bias.html">Position.Bias</A>[] bias)</PRE><DL><DD>Provides a mapping from the view coordinate space to the logical coordinate space of the model.<DD><DL><DT><B>Overrides:</B><DD><CODE><A HREF="../../../javax/swing/text/PlainView.html#viewToModel(float, float, java.awt.Shape, javax.swing.text.Position.Bias[])">viewToModel</A></CODE> in class <CODE><A HREF="../../../javax/swing/text/PlainView.html">PlainView</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>fx</CODE> - the X coordinate >= 0.0f<DD><CODE>fy</CODE> - the Y coordinate >= 0.0f<DD><CODE>a</CODE> - the allocated region to render into<DT><B>Returns:</B><DD>the location within the model that best represents the given point in the view<DT><B>See Also: </B><DD><A HREF="../../../javax/swing/text/View.html#viewToModel(float, float, java.awt.Shape, javax.swing.text.Position.Bias[])"><CODE>View.viewToModel(float, float, java.awt.Shape, javax.swing.text.Position.Bias[])</CODE></A></DL></DD></DL><HR><A NAME="insertUpdate(javax.swing.event.DocumentEvent, java.awt.Shape, javax.swing.text.ViewFactory)"><!-- --></A><H3>insertUpdate</H3><PRE>public void <B>insertUpdate</B>(<A HREF="../../../javax/swing/event/DocumentEvent.html">DocumentEvent</A> changes, <A HREF="../../../java/awt/Shape.html">Shape</A> a, <A HREF="../../../javax/swing/text/ViewFactory.html">ViewFactory</A> f)</PRE><DL><DD>Gives notification that something was inserted into the document in a location that this view is responsible for.<DD><DL><DT><B>Overrides:</B><DD><CODE><A HREF="../../../javax/swing/text/PlainView.html#insertUpdate(javax.swing.event.DocumentEvent, java.awt.Shape, javax.swing.text.ViewFactory)">insertUpdate</A></CODE> in class <CODE><A HREF="../../../javax/swing/text/PlainView.html">PlainView</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>changes</CODE> - the change information from the associated document<DD><CODE>a</CODE> - the current allocation of the view<DD><CODE>f</CODE> - the factory to use to rebuild if the view has children<DT><B>See Also: </B><DD><A HREF="../../../javax/swing/text/View.html#insertUpdate(javax.swing.event.DocumentEvent, java.awt.Shape, javax.swing.text.ViewFactory)"><CODE>View.insertUpdate(javax.swing.event.DocumentEvent, java.awt.Shape, javax.swing.text.ViewFactory)</CODE></A></DL></DD></DL><HR><A NAME="removeUpdate(javax.swing.event.DocumentEvent, java.awt.Shape, javax.swing.text.ViewFactory)"><!-- --></A><H3>removeUpdate</H3><PRE>public void <B>removeUpdate</B>(<A HREF="../../../javax/swing/event/DocumentEvent.html">DocumentEvent</A> changes, <A HREF="../../../java/awt/Shape.html">Shape</A> a, <A HREF="../../../javax/swing/text/ViewFactory.html">ViewFactory</A> f)</PRE><DL><DD>Gives notification that something was removed from the document in a location that this view is responsible for.<DD><DL><DT><B>Overrides:</B><DD><CODE><A HREF="../../../javax/swing/text/PlainView.html#removeUpdate(javax.swing.event.DocumentEvent, java.awt.Shape, javax.swing.text.ViewFactory)">removeUpdate</A></CODE> in class <CODE><A HREF="../../../javax/swing/text/PlainView.html">PlainView</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>changes</CODE> - the change information from the associated document<DD><CODE>a</CODE> - the current allocation of the view<DD><CODE>f</CODE> - the factory to use to rebuild if the view has children<DT><B>See Also: </B><DD><A HREF="../../../javax/swing/text/View.html#removeUpdate(javax.swing.event.DocumentEvent, java.awt.Shape, javax.swing.text.ViewFactory)"><CODE>View.removeUpdate(javax.swing.event.DocumentEvent, java.awt.Shape, javax.swing.text.ViewFactory)</CODE></A></DL></DD></DL><!-- ========= END OF CLASS DATA ========= --><HR><!-- ========== START OF NAVBAR ========== --><A NAME="navbar_bottom"><!-- --></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0"><TR><TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_bottom_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3"> <TR ALIGN="center" VALIGN="top"> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/FieldView.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-files/index-1.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD> </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM><b>Java<sup><font size=-2>TM</font></sup> 2 Platform<br>Std. Ed. v1.3</b></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../javax/swing/text/ElementIterator.html"><B>PREV CLASS</B></A> <A HREF="../../../javax/swing/text/FlowView.html"><B>NEXT CLASS</B></A></FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../index.html" TARGET="_top"><B>FRAMES</B></A> <A HREF="FieldView.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> SUMMARY: INNER | <A HREF="#fields_inherited_from_class_javax.swing.text.PlainView">FIELD</A> | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL: FIELD | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><!-- =========== END OF NAVBAR =========== --><HR><font size="-1"><a href="http://java.sun.com/cgi-bin/bugreport.cgi">Submit a bug or feature</a><br>For further API reference and developer documentation, see <a href="http://java.sun.com/products/jdk/1.3/devdocs-vs-specs.html">Java 2 SDK SE Developer Documentation</a>. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples. <p>Java, Java 2D, and JDBC are trademarks or registered trademarks of Sun Microsystems, Inc. in the US and other countries.<br>Copyright 1993-2000 Sun Microsystems, Inc. 901 San Antonio Road<br>Palo Alto, California, 94303, U.S.A. All Rights Reserved.</font></BODY></HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -