inputmethoddescriptor.html

来自「API資料大全」· HTML 代码 · 共 303 行

HTML
303
字号
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Frameset//EN""http://www.w3.org/TR/REC-html40/frameset.dtd"><!--NewPage--><HTML><HEAD><!-- Generated by javadoc on Thu Apr 27 23:33:56 PDT 2000 --><TITLE>Java 2 Platform SE v1.3: Interface  InputMethodDescriptor</TITLE><LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style"></HEAD><BODY BGCOLOR="white"><!-- ========== START OF NAVBAR ========== --><A NAME="navbar_top"><!-- --></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0"><TR><TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_top_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>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/InputMethodDescriptor.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-files/index-1.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>  </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM><b>Java<sup><font size=-2>TM</font></sup>&nbsp;2&nbsp;Platform<br>Std.&nbsp;Ed. v1.3</b></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">&nbsp;<A HREF="../../../../java/awt/im/spi/InputMethodContext.html"><B>PREV CLASS</B></A>&nbsp;&nbsp;NEXT CLASS</FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">  <A HREF="../../../../index.html" TARGET="_top"><B>FRAMES</B></A>  &nbsp;&nbsp;<A HREF="InputMethodDescriptor.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">  SUMMARY: &nbsp;INNER&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL: &nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><!-- =========== END OF NAVBAR =========== --><HR><!-- ======== START OF CLASS DATA ======== --><H2><FONT SIZE="-1">java.awt.im.spi</FONT><BR>Interface  InputMethodDescriptor</H2><HR><DL><DT>public interface <B>InputMethodDescriptor</B></DL><P>Defines methods that provide sufficient information about an input method to enable selection and loading of that input method. The input method itself is only loaded when it is actually used.<P><DL><DT><B>Since: </B><DD>1.3</DD></DL><HR><P><!-- ======== INNER CLASS SUMMARY ======== --><!-- =========== FIELD SUMMARY =========== --><!-- ======== CONSTRUCTOR SUMMARY ======== --><!-- ========== METHOD SUMMARY =========== --><A NAME="method_summary"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=2><FONT SIZE="+2"><B>Method Summary</B></FONT></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../../java/awt/im/spi/InputMethod.html">InputMethod</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../../java/awt/im/spi/InputMethodDescriptor.html#createInputMethod()">createInputMethod</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a new instance of the corresponding input method.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../../java/util/Locale.html">Locale</A>[]</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../java/awt/im/spi/InputMethodDescriptor.html#getAvailableLocales()">getAvailableLocales</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the locales supported by the corresponding input method.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../../java/lang/String.html">String</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../../java/awt/im/spi/InputMethodDescriptor.html#getInputMethodDisplayName(java.util.Locale, java.util.Locale)">getInputMethodDisplayName</A></B>(<A HREF="../../../../java/util/Locale.html">Locale</A>&nbsp;inputLocale,                          <A HREF="../../../../java/util/Locale.html">Locale</A>&nbsp;displayLanguage)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the user-visible name of the corresponding input method for the given input locale in the language in which the name will be displayed.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../../java/awt/Image.html">Image</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../../java/awt/im/spi/InputMethodDescriptor.html#getInputMethodIcon(java.util.Locale)">getInputMethodIcon</A></B>(<A HREF="../../../../java/util/Locale.html">Locale</A>&nbsp;inputLocale)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an icon for the corresponding input method.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../java/awt/im/spi/InputMethodDescriptor.html#hasDynamicLocaleList()">hasDynamicLocaleList</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns whether the list of available locales can change at runtime.</TD></TR></TABLE>&nbsp;<P><!-- ============ FIELD DETAIL =========== --><!-- ========= CONSTRUCTOR DETAIL ======== --><!-- ============ METHOD DETAIL ========== --><A NAME="method_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Method Detail</B></FONT></TD></TR></TABLE><A NAME="getAvailableLocales()"><!-- --></A><H3>getAvailableLocales</H3><PRE>public <A HREF="../../../../java/util/Locale.html">Locale</A>[] <B>getAvailableLocales</B>()                             throws <A HREF="../../../../java/awt/AWTException.html">AWTException</A></PRE><DL><DD>Returns the locales supported by the corresponding input method. The locale may describe just the language, or may also include country and variant information if needed. The information is used to select input methods by locale (<A HREF="../../../../java/awt/im/InputContext.html#selectInputMethod(java.util.Locale)"><CODE>InputContext.selectInputMethod(Locale)</CODE></A>). It may also be used to sort input methods by locale in a user-visible list of input methods. <p> Only the input method's primary locales should be returned. For example, if a Japanese input method also has a pass-through mode for Roman characters, typically still only Japanese would be returned. Thus, the list of locales returned is typically a subset of the locales for which the corresponding input method's implementation of <A HREF="../../../../java/awt/im/spi/InputMethod.html#setLocale(java.util.Locale)"><CODE>InputMethod.setLocale(java.util.Locale)</CODE></A> returns true. <p> If <A HREF="../../../../java/awt/im/spi/InputMethodDescriptor.html#hasDynamicLocaleList()"><CODE>hasDynamicLocaleList()</CODE></A> returns true, this method is called each time the information is needed. This gives input methods that depend on network resources the chance to add or remove locales as resources become available or unavailable.<DD><DL><DT><B>Returns:</B><DD>the locales supported by the input method<DT><B>Throws:</B><DD><CODE><A HREF="../../../../java/awt/AWTException.html">AWTException</A></CODE> - if it can be determined that the input method is inoperable, for example, because of incomplete installation.</DL></DD></DL><HR><A NAME="hasDynamicLocaleList()"><!-- --></A><H3>hasDynamicLocaleList</H3><PRE>public boolean <B>hasDynamicLocaleList</B>()</PRE><DL><DD>Returns whether the list of available locales can change at runtime. This may be the case, for example, for adapters that access real input methods over the network.</DL><HR><A NAME="getInputMethodDisplayName(java.util.Locale, java.util.Locale)"><!-- --></A><H3>getInputMethodDisplayName</H3><PRE>public <A HREF="../../../../java/lang/String.html">String</A> <B>getInputMethodDisplayName</B>(<A HREF="../../../../java/util/Locale.html">Locale</A>&nbsp;inputLocale,                                        <A HREF="../../../../java/util/Locale.html">Locale</A>&nbsp;displayLanguage)</PRE><DL><DD>Returns the user-visible name of the corresponding input method for the given input locale in the language in which the name will be displayed. <p> The inputLocale parameter specifies the locale for which text is input. This parameter can only take values obtained from this descriptor's <A HREF="../../../../java/awt/im/spi/InputMethodDescriptor.html#getAvailableLocales()"><CODE>getAvailableLocales()</CODE></A> method or null. If it is null, an input locale independent name for the input method should be returned. <p> If a name for the desired display language is not available, the method may fall back to some other language.<DD><DL><DT><B>Parameters:</B><DD><CODE>inputLocale</CODE> - the locale for which text input is supported, or null<DD><CODE>displayLanguage</CODE> - the language in which the name will be displayed</DL></DD></DL><HR><A NAME="getInputMethodIcon(java.util.Locale)"><!-- --></A><H3>getInputMethodIcon</H3><PRE>public <A HREF="../../../../java/awt/Image.html">Image</A> <B>getInputMethodIcon</B>(<A HREF="../../../../java/util/Locale.html">Locale</A>&nbsp;inputLocale)</PRE><DL><DD>Returns an icon for the corresponding input method. The icon may be used by a user interface for selecting input methods. <p> The inputLocale parameter specifies the locale for which text is input. This parameter can only take values obtained from this descriptor's <A HREF="../../../../java/awt/im/spi/InputMethodDescriptor.html#getAvailableLocales()"><CODE>getAvailableLocales()</CODE></A> method or null. If it is null, an input locale independent icon for the input method should be returned. <p> The icon's size should be 16&times;16 pixels.<DD><DL><DT><B>Parameters:</B><DD><CODE>inputLocale</CODE> - the locale for which text input is supported, or null<DT><B>Returns:</B><DD>an icon for the corresponding input method, or null</DL></DD></DL><HR><A NAME="createInputMethod()"><!-- --></A><H3>createInputMethod</H3><PRE>public <A HREF="../../../../java/awt/im/spi/InputMethod.html">InputMethod</A> <B>createInputMethod</B>()                              throws <A HREF="../../../../java/lang/Exception.html">Exception</A></PRE><DL><DD>Creates a new instance of the corresponding input method.<DD><DL><DT><B>Returns:</B><DD>a new instance of the corresponding input method<DT><B>Throws:</B><DD><CODE><A HREF="../../../../java/lang/Exception.html">Exception</A></CODE> - any exception that may occur while creating the input method instance</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>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/InputMethodDescriptor.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-files/index-1.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>  </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM><b>Java<sup><font size=-2>TM</font></sup>&nbsp;2&nbsp;Platform<br>Std.&nbsp;Ed. v1.3</b></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">&nbsp;<A HREF="../../../../java/awt/im/spi/InputMethodContext.html"><B>PREV CLASS</B></A>&nbsp;&nbsp;NEXT CLASS</FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">  <A HREF="../../../../index.html" TARGET="_top"><B>FRAMES</B></A>  &nbsp;&nbsp;<A HREF="InputMethodDescriptor.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">  SUMMARY: &nbsp;INNER&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL: &nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<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 + =
减小字号Ctrl + -
显示快捷键?