|
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 |
* HISTORY
|
|
Packit |
b099d7 |
*/
|
|
Packit |
b099d7 |
/*
|
|
Packit |
b099d7 |
static char rcsid[] = "$XConsortium: DrawArea2.dat /main/6 1995/07/13 18:30:00 drk $"
|
|
Packit |
b099d7 |
*/
|
|
Packit |
b099d7 |
!) This is a simple Drawing Area client.
|
|
Packit |
b099d7 |
#) The focus is on the button. Press TAB to put the focus
|
|
Packit |
b099d7 |
into the drawing area. Press any key on the keyboard.
|
|
Packit |
b099d7 |
You should see a message about a keypress being received
|
|
Packit |
b099d7 |
but not processed.
|
|
Packit |
b099d7 |
This is normal and desireable.
|
|
Packit |
b099d7 |
#) The Drawing area is surrounded by a frame and
|
|
Packit |
b099d7 |
itself should have a shadow thickness of 5 pixels.
|
|
Packit |
b099d7 |
#) To use the client: Click MB1 anywhere in the client. A line will be drawn
|
|
Packit |
b099d7 |
from 0,0 to your current location. Each time you click MB1, a line will be drawn from your
|
|
Packit |
b099d7 |
previous location to your current location. If you click MB2 or MB3, no line will be drawn, but the beginning
|
|
Packit |
b099d7 |
point will be reset to your current location.
|
|
Packit |
b099d7 |
#) Click Btn1 one more time anywhere in the Drawing Area.
|
|
Packit |
b099d7 |
#) Press the Shift key. You should receive the message about keypress.
|
|
Packit |
b099d7 |
#) Press any other key alone, then with the Shift key held down. You should
|
|
Packit |
b099d7 |
receive the keypress message.
|
|
Packit |
b099d7 |
#) Draw another line with Btn1 clicks.
|
|
Packit |
b099d7 |
#) Press the PushButton. The DrawingArea will resize and several messages will
|
|
Packit |
b099d7 |
be printed out. None of the messages should mention that an error has
|
|
Packit |
b099d7 |
been encountered.
|
|
Packit |
b099d7 |
C)
|
|
Packit |
b099d7 |
#) The way button and key presses has been modified internally to use
|
|
Packit |
b099d7 |
translations. Things should work the same way in the Drawing Area.
|
|
Packit |
b099d7 |
C)
|
|
Packit |
b099d7 |
#) An override shell has popped up, containing a label "Put the focus in
|
|
Packit |
b099d7 |
this window." Move your pointer into the override shell window.
|
|
Packit |
b099d7 |
E)
|