label.html.svn-base
来自「j2me设计的界面包」· SVN-BASE 代码 · 共 756 行 · 第 1/3 页
SVN-BASE
756 行
<PRE>
public int <B>getVerticalAlignment</B>()</PRE>
<DL>
<DD>Returns the vertical aligment of the Label, this will only work when the icon is in the side of the text and not above or bellow it.
<P>
<DD><DL>
<DT><B>Returns:</B><DD>the vertical aligment of the Label one of: CENTER, TOP, BOTTOM<DT><B>See Also:</B><DD><A HREF="../../../com/sun/lwuit/Component.html#CENTER"><CODE>Component.CENTER</CODE></A>,
<A HREF="../../../com/sun/lwuit/Component.html#TOP"><CODE>Component.TOP</CODE></A>,
<A HREF="../../../com/sun/lwuit/Component.html#BOTTOM"><CODE>Component.BOTTOM</CODE></A></DL>
</DD>
</DL>
<HR>
<A NAME="getAlignment()"><!-- --></A><H3>
getAlignment</H3>
<PRE>
public int <B>getAlignment</B>()</PRE>
<DL>
<DD>Returns the aligment of the Label
<P>
<DD><DL>
<DT><B>Returns:</B><DD>the aligment of the Label one of: CENTER, LEFT, RIGHT<DT><B>See Also:</B><DD><A HREF="../../../com/sun/lwuit/Component.html#CENTER"><CODE>Component.CENTER</CODE></A>,
<A HREF="../../../com/sun/lwuit/Component.html#LEFT"><CODE>Component.LEFT</CODE></A>,
<A HREF="../../../com/sun/lwuit/Component.html#RIGHT"><CODE>Component.RIGHT</CODE></A></DL>
</DD>
</DL>
<HR>
<A NAME="setTextPosition(int)"><!-- --></A><H3>
setTextPosition</H3>
<PRE>
public void <B>setTextPosition</B>(int textPosition)</PRE>
<DL>
<DD>Sets the position of the text relative to the icon if exists
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>textPosition</CODE> - alignment value (LEFT, RIGHT, BOTTOM or TOP)<DT><B>See Also:</B><DD><A HREF="../../../com/sun/lwuit/Component.html#LEFT"><CODE>Component.LEFT</CODE></A>,
<A HREF="../../../com/sun/lwuit/Component.html#RIGHT"><CODE>Component.RIGHT</CODE></A>,
<A HREF="../../../com/sun/lwuit/Component.html#BOTTOM"><CODE>Component.BOTTOM</CODE></A>,
<A HREF="../../../com/sun/lwuit/Component.html#TOP"><CODE>Component.TOP</CODE></A></DL>
</DD>
</DL>
<HR>
<A NAME="getTextPosition()"><!-- --></A><H3>
getTextPosition</H3>
<PRE>
public int <B>getTextPosition</B>()</PRE>
<DL>
<DD>Returns The position of the text relative to the icon
<P>
<DD><DL>
<DT><B>Returns:</B><DD>The position of the text relative to the icon, one of: LEFT, RIGHT, BOTTOM, TOP<DT><B>See Also:</B><DD><A HREF="../../../com/sun/lwuit/Component.html#LEFT"><CODE>Component.LEFT</CODE></A>,
<A HREF="../../../com/sun/lwuit/Component.html#RIGHT"><CODE>Component.RIGHT</CODE></A>,
<A HREF="../../../com/sun/lwuit/Component.html#BOTTOM"><CODE>Component.BOTTOM</CODE></A>,
<A HREF="../../../com/sun/lwuit/Component.html#TOP"><CODE>Component.TOP</CODE></A></DL>
</DD>
</DL>
<HR>
<A NAME="setGap(int)"><!-- --></A><H3>
setGap</H3>
<PRE>
public void <B>setGap</B>(int gap)</PRE>
<DL>
<DD>Set the gap in pixels between the icon/text to the Label boundaries
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>gap</CODE> - the gap in pixels</DL>
</DD>
</DL>
<HR>
<A NAME="getGap()"><!-- --></A><H3>
getGap</H3>
<PRE>
public int <B>getGap</B>()</PRE>
<DL>
<DD>Returns the gap in pixels between the icon/text to the Label boundaries
<P>
<DD><DL>
<DT><B>Returns:</B><DD>the gap in pixels between the icon/text to the Label boundaries</DL>
</DD>
</DL>
<HR>
<A NAME="getUIID()"><!-- --></A><H3>
getUIID</H3>
<PRE>
protected java.lang.String <B>getUIID</B>()</PRE>
<DL>
<DD><B>Description copied from class: <CODE><A HREF="../../../com/sun/lwuit/Component.html#getUIID()">Component</A></CODE></B></DD>
<DD>Unique identifier for a component, must be overriden for a component so a style can be applied to the component
<P>
<DD><DL>
<DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/sun/lwuit/Component.html#getUIID()">getUIID</A></CODE> in class <CODE><A HREF="../../../com/sun/lwuit/Component.html" title="class in com.sun.lwuit">Component</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>unique string identifying this component for the style sheet</DL>
</DD>
</DL>
<HR>
<A NAME="paramString()"><!-- --></A><H3>
paramString</H3>
<PRE>
protected java.lang.String <B>paramString</B>()</PRE>
<DL>
<DD><B>Description copied from class: <CODE><A HREF="../../../com/sun/lwuit/Component.html#paramString()">Component</A></CODE></B></DD>
<DD>Returns a string representing the state of this component. This method is intended to be used only for debugging purposes, and the content and format of the returned string may vary between implementations. The returned string may be empty but may not be <code>null</code>.
<P>
<DD><DL>
<DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/sun/lwuit/Component.html#paramString()">paramString</A></CODE> in class <CODE><A HREF="../../../com/sun/lwuit/Component.html" title="class in com.sun.lwuit">Component</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>a string representation of this component's state</DL>
</DD>
</DL>
<HR>
<A NAME="paint(com.sun.lwuit.Graphics)"><!-- --></A><H3>
paint</H3>
<PRE>
public void <B>paint</B>(<A HREF="../../../com/sun/lwuit/Graphics.html" title="class in com.sun.lwuit">Graphics</A> g)</PRE>
<DL>
<DD><B>Description copied from class: <CODE><A HREF="../../../com/sun/lwuit/Component.html#paint(com.sun.lwuit.Graphics)">Component</A></CODE></B></DD>
<DD>This method paints the Component on the screen, it should be overriden by subclasses to perform custom drawing or invoke the UI API's to let the PLAF perform the rendering.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../com/sun/lwuit/animations/Animation.html#paint(com.sun.lwuit.Graphics)">paint</A></CODE> in interface <CODE><A HREF="../../../com/sun/lwuit/animations/Animation.html" title="interface in com.sun.lwuit.animations">Animation</A></CODE><DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/sun/lwuit/Component.html#paint(com.sun.lwuit.Graphics)">paint</A></CODE> in class <CODE><A HREF="../../../com/sun/lwuit/Component.html" title="class in com.sun.lwuit">Component</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>g</CODE> - the component graphics</DL>
</DD>
</DL>
<HR>
<A NAME="calcPreferredSize()"><!-- --></A><H3>
calcPreferredSize</H3>
<PRE>
protected <A HREF="../../../com/sun/lwuit/geom/Dimension.html" title="class in com.sun.lwuit.geom">Dimension</A> <B>calcPreferredSize</B>()</PRE>
<DL>
<DD><B>Description copied from class: <CODE><A HREF="../../../com/sun/lwuit/Component.html#calcPreferredSize()">Component</A></CODE></B></DD>
<DD>Calculates the preferred size based on component content. This method is invoked lazily by getPreferred size.
<P>
<DD><DL>
<DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/sun/lwuit/Component.html#calcPreferredSize()">calcPreferredSize</A></CODE> in class <CODE><A HREF="../../../com/sun/lwuit/Component.html" title="class in com.sun.lwuit">Component</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>the calculated preferred size based on component content</DL>
</DD>
</DL>
<HR>
<A NAME="animate()"><!-- --></A><H3>
animate</H3>
<PRE>
public boolean <B>animate</B>()</PRE>
<DL>
<DD><B>Description copied from interface: <CODE><A HREF="../../../com/sun/lwuit/animations/Animation.html#animate()">Animation</A></CODE></B></DD>
<DD>Allows the animation to reduce "repaint" calls when it returns false. It is called once for every frame. Frames are defined by the <A HREF="../../../com/sun/lwuit/Display.html" title="class in com.sun.lwuit"><CODE>Display</CODE></A> class.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../com/sun/lwuit/animations/Animation.html#animate()">animate</A></CODE> in interface <CODE><A HREF="../../../com/sun/lwuit/animations/Animation.html" title="interface in com.sun.lwuit.animations">Animation</A></CODE><DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/sun/lwuit/Component.html#animate()">animate</A></CODE> in class <CODE><A HREF="../../../com/sun/lwuit/Component.html" title="class in com.sun.lwuit">Component</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>true if a repaint is desired or false if no repaint is necessary</DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<A NAME="navbar_bottom"><!-- --></A>
<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<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/Label.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>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../com/sun/lwuit/IndexedImage.html" title="class in com.sun.lwuit"><B>PREV CLASS</B></A>
<A HREF="../../../com/sun/lwuit/List.html" title="class in com.sun.lwuit"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../index.html?com/sun/lwuit/Label.html" target="_top"><B>FRAMES</B></A>
<A HREF="Label.html" target="_top"><B>NO FRAMES</B></A>
<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY: NESTED | <A HREF="#fields_inherited_from_class_com.sun.lwuit.Component">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>
<A NAME="skip-navbar_bottom"></A>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<HR>
Copyright 2008 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.
</BODY>
</HTML>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?