|
Packit |
b099d7 |
/* $XConsortium: InputMethod2b.dat /main/4 1995/07/17 10:06:08 drk $ */
|
|
Packit |
b099d7 |
/*
|
|
Packit |
b099d7 |
* Motif
|
|
Packit |
b099d7 |
*
|
|
Packit |
b099d7 |
* Copyright (c) 1987-2012, The Open Group. All rights reserved.
|
|
Packit |
b099d7 |
*
|
|
Packit |
b099d7 |
* These libraries and programs are free software; you can
|
|
Packit |
b099d7 |
* redistribute them and/or modify them under the terms of the GNU
|
|
Packit |
b099d7 |
* Lesser General Public License as published by the Free Software
|
|
Packit |
b099d7 |
* Foundation; either version 2 of the License, or (at your option)
|
|
Packit |
b099d7 |
* any later version.
|
|
Packit |
b099d7 |
*
|
|
Packit |
b099d7 |
* These libraries and programs are distributed in the hope that
|
|
Packit |
b099d7 |
* they will be useful, but WITHOUT ANY WARRANTY; without even the
|
|
Packit |
b099d7 |
* implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
|
Packit |
b099d7 |
* PURPOSE. See the GNU Lesser General Public License for more
|
|
Packit |
b099d7 |
* details.
|
|
Packit |
b099d7 |
*
|
|
Packit |
b099d7 |
* You should have received a copy of the GNU Lesser General Public
|
|
Packit |
b099d7 |
* License along with these librararies and programs; if not, write
|
|
Packit |
b099d7 |
* to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
|
|
Packit |
b099d7 |
* Floor, Boston, MA 02110-1301 USA
|
|
Packit |
b099d7 |
*
|
|
Packit |
b099d7 |
*/
|
|
Packit |
b099d7 |
/*
|
|
Packit |
b099d7 |
* HISTORY
|
|
Packit |
b099d7 |
*/
|
|
Packit |
b099d7 |
|
|
Packit |
b099d7 |
#) This test, running with the "-I InputMethod2b.Dat -u b" option is for
|
|
Packit |
b099d7 |
testing how the Motif Text and TextField widgets react to an OffTheSpot
|
|
Packit |
b099d7 |
style Input Method, with per widget Input Context.
|
|
Packit |
b099d7 |
#) It is running with the LANG environment variable set to japanese.
|
|
Packit |
b099d7 |
|
|
Packit |
b099d7 |
C)
|
|
Packit |
b099d7 |
|
|
Packit |
b099d7 |
#) Testing the XmImGetXIM function.
|
|
Packit |
b099d7 |
#) The XmNinputMethod has not been set on the VendorShell, so it should be
|
|
Packit |
b099d7 |
NULL, and the function should try to open an input method using the current
|
|
Packit |
b099d7 |
locale.
|
|
Packit |
b099d7 |
#) If this failed, you will see a failure message in your term window and the
|
|
Packit |
b099d7 |
test will exit. Else, you should see the following message in your term
|
|
Packit |
b099d7 |
window:
|
|
Packit |
b099d7 |
!)
|
|
Packit |
b099d7 |
Input method opened successfully for locale <locale_name>.
|
|
Packit |
b099d7 |
|
|
Packit |
b099d7 |
where <locale_name> should be japanese.
|
|
Packit |
b099d7 |
|
|
Packit |
b099d7 |
C)
|
|
Packit |
b099d7 |
|
|
Packit |
b099d7 |
#) Print the supported input styles of the open Input Method.
|
|
Packit |
b099d7 |
#) You will see in your term window the number of supported input styles,
|
|
Packit |
b099d7 |
and their values.
|
|
Packit |
b099d7 |
#) If the Input Method cannot support an OverTheSpot style, print an error
|
|
Packit |
b099d7 |
and exit. Else you should see the following message in your term window:
|
|
Packit |
b099d7 |
!)
|
|
Packit |
b099d7 |
Input Method and Application support the same input style.
|
|
Packit |
b099d7 |
C)
|
|
Packit |
b099d7 |
|
|
Packit |
b099d7 |
#) A window should appear containing a Scrolled Text widget, a Text widget and
|
|
Packit |
b099d7 |
a TextField widget.
|
|
Packit |
b099d7 |
#) A panel should also appear, displaying information about the input style
|
|
Packit |
b099d7 |
currently tested, and resources to test for the Input Context.
|
|
Packit |
b099d7 |
#) Invoke the Input Method by pressing the <Extend char> key on the rigth of
|
|
Packit |
b099d7 |
your space bar, while focus is in the Scrolled Text widget. The Status
|
|
Packit |
b099d7 |
area appears at the bottom left, outside the application window.
|
|
Packit |
b099d7 |
#) Move the input focus to the other widgets.
|
|
Packit |
b099d7 |
#) Go to the end of the word "Testing" in the Scrolled Text widget, and start
|
|
Packit |
b099d7 |
typing "fuji". When typing "f", the Preedit Area appears at some fixed
|
|
Packit |
b099d7 |
location (often near the bottom), displaying the letter "f". After typing
|
|
Packit |
b099d7 |
"u", you see a new character overriding the "f", which is the phonetic
|
|
Packit |
b099d7 |
equivalent of the English letters "fu" in Hiragana. You will notice the
|
|
Packit |
b099d7 |
same behavior while typing "ji".
|
|
Packit |
b099d7 |
#) Now press the <tab> key to get the Katakana symbols.
|
|
Packit |
b099d7 |
#) Press on the <Extend char> key on the left of your space bar, to enter the
|
|
Packit |
b099d7 |
symbols in your text and get disconnected from the Input Method.
|
|
Packit |
b099d7 |
C)
|
|
Packit |
b099d7 |
|
|
Packit |
b099d7 |
#) Test the XmImSetValues function.
|
|
Packit |
b099d7 |
#) Invoke again the Input Method by pressing the rigth <Extend char> key.
|
|
Packit |
b099d7 |
#) Enter "to". A new phonetic symbol appears in the Preedit area.
|
|
Packit |
b099d7 |
#) Change the input focus to the other text widgets. The Preedit area is moved
|
|
Packit |
b099d7 |
to the other widgets, preserving its contents.
|
|
Packit |
b099d7 |
#) Go back to the Scrolled Text widget. In the Panel, select "Scrolled Text"
|
|
Packit |
b099d7 |
in the "Apply to" Radio Box, and select "Yellow" from the
|
|
Packit |
b099d7 |
"Background" pulldown. The Preedit area foreground and the Status area
|
|
Packit |
b099d7 |
background change to yellow.
|
|
Packit |
b099d7 |
#) Give the input focus to the other text widgets. The yellow color should
|
|
Packit |
b099d7 |
not be maintained.
|
|
Packit |
b099d7 |
#) Play with the other values of the different resources, in each widget.
|
|
Packit |
b099d7 |
#) Press the left <Extend char> key.
|
|
Packit |
b099d7 |
C)
|
|
Packit |
b099d7 |
|
|
Packit |
b099d7 |
#) Test the XmImUnregister function.
|
|
Packit |
b099d7 |
#) The Scrolled Text widget has been unregistered from the Input Method.
|
|
Packit |
b099d7 |
#) While focus in the Scrolled Text widget, try to invoke the Input
|
|
Packit |
b099d7 |
Method. No Status area
|
|
Packit |
b099d7 |
should appear, and when typing no Preedit Area should appear.
|
|
Packit |
b099d7 |
C)
|
|
Packit |
b099d7 |
|
|
Packit |
b099d7 |
E)
|