# $XConsortium: IconGadget1.scr /main/4 1995/07/17 20:17:08 drk $ # @OPENGROUP_COPYRIGHT@ # COPYRIGHT NOTICE # Copyright (c) 1990, 1991, 1992, 1993 Open Software Foundation, Inc. # Copyright (c) 1996, 1997, 1998, 1999, 2000 The Open Group # ALL RIGHTS RESERVED (MOTIF). See the file named COPYRIGHT.MOTIF for # the full copyright text. # # This software is subject to an open license. It may only be # used on, with or for operating systems which are themselves open # source systems. You must contact The Open Group for a license # allowing distribution and sublicensing of this software on, with, # or for operating systems which are not Open Source programs. # # See http://www.opengroup.org/openmotif/license for full # details of the license agreement. Any use, reproduction, or # distribution of the program constitutes recipient's acceptance of # this agreement. # # EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS # PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY # KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY # WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY # OR FITNESS FOR A PARTICULAR PURPOSE # # EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT # NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, # INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED # AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT # LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN # ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE # EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGES. # # # HISTORY # #) A drawing area will appear containing 3 icon gadgets. # #) "IconGad1" is displayed in its LARGE_ICON view, using the mountain bitmap. # The label string "IconGad1" should be beneath the icon. # It has 3 details displayed next to it, saying "First object Chocolate 33". # #) "IconGad2" and "IconGad3" are also displayed in their large icon view, # but are not using any pixmap. # #) The respective position of the 3 icon gadgets should be (20,20), (50,100) # and (30,170). # #) A control panel should appear composed of 10 rows of resources, # then an "Apply" button and a check box for selecting the icon gadgets # you want the resources to be applied to. # #) Each row of resources is composed of a check box, and an option # menu displaying the different values you can set for this resource. # C) LocatePointer IconGadget1 CompareVisual IconGadget1 Continue # #) Select the following resources, and every time the check mark on the # left: # !) # labelString How about something longer ... # smallIconPixmap large.xpm # smallIconMask none # detail 3 details # detailCount 3 # viewType XmSMALL_ICON LocatePointer TogSet_labelString ClickMB Btn1 LocatePointer OM_labelString ROptionButton PressMB Btn1 LocatePointer labelStringPB3 ReleaseMB Btn1 LocatePointer TogSet_smallIconPixmap ClickMB Btn1 LocatePointer OM_smallIconPixmap ROptionButton PressMB Btn1 LocatePointer smallIconPixmapPB0 ReleaseMB Btn1 LocatePointer TogSet_smallIconMask ClickMB Btn1 LocatePointer OM_smallIconMask ROptionButton PressMB Btn1 LocatePointer smallIconMaskPB3 ReleaseMB Btn1 LocatePointer TogSet_detail ClickMB Btn1 LocatePointer OM_detail ROptionButton PressMB Btn1 LocatePointer detailPB2 ReleaseMB Btn1 LocatePointer TogSet_detailCount ClickMB Btn1 LocatePointer OM_detailCount ROptionButton PressMB Btn1 LocatePointer detailCountPB3 ReleaseMB Btn1 LocatePointer TogSet_viewType ClickMB Btn1 LocatePointer OM_viewType ROptionButton PressMB Btn1 LocatePointer viewTypePB1 ReleaseMB Btn1 # #) Now select the "IconGad2" toggle button and click on the "Apply" button. # #) You should see the bee pixmap displayed on the left of the labelString, # and 3 details added on the same line. LocatePointer TB_IconGad2 ClickMB Btn1 LocatePointer Apply ClickMB Btn1 WindowRaise IconGadget1 CompareVisual IconGadget1 # #) Select "large_m.xpm" from the "smallIconMask", and unselected the other # check marks. Select 5 from "shadowThickness" and click on the check mark. # #) Click on the "Apply" button. A mask is applied on the bee pixmap, so # that the pixmap is no longer in a box. The details should not # disappear. The label should be fully visible and not truncated on its # left. # C) LocatePointer OM_smallIconMask ROptionButton PressMB Btn1 LocatePointer smallIconMaskPB0 ReleaseMB Btn1 LocatePointer TogSet_labelString ClickMB Btn1 LocatePointer TogSet_smallIconPixmap ClickMB Btn1 LocatePointer TogSet_detail ClickMB Btn1 LocatePointer TogSet_detailCount ClickMB Btn1 LocatePointer TogSet_viewType ClickMB Btn1 LocatePointer TogSet_shadowThickness ClickMB Btn1 LocatePointer OM_shadowThickness ROptionButton PressMB Btn1 LocatePointer shadowThicknessPB3 ReleaseMB Btn1 LocatePointer Apply ClickMB Btn1 WindowRaise IconGadget1 CompareVisual IconGadget1 Continue # #) Select the following resources, and every time the check mark on the # left: # !) # labelString A # largeIconPixmap small.xpm # largeIconMask none # detail 2 details # detailCount 2 # shadowThickness 10 # LocatePointer TogSet_labelString ClickMB Btn1 LocatePointer OM_labelString ROptionButton PressMB Btn1 LocatePointer labelStringPB0 ReleaseMB Btn1 LocatePointer TogSet_largeIconPixmap ClickMB Btn1 LocatePointer OM_largeIconPixmap ROptionButton PressMB Btn1 LocatePointer largeIconPixmapPB1 ReleaseMB Btn1 LocatePointer TogSet_largeIconMask ClickMB Btn1 LocatePointer OM_largeIconMask ROptionButton PressMB Btn1 LocatePointer largeIconMaskPB3 ReleaseMB Btn1 LocatePointer TogSet_detail ClickMB Btn1 LocatePointer OM_detail ROptionButton PressMB Btn1 LocatePointer detailPB1 ReleaseMB Btn1 LocatePointer TogSet_detailCount ClickMB Btn1 LocatePointer OM_detailCount ROptionButton PressMB Btn1 LocatePointer detailCountPB2 ReleaseMB Btn1 LocatePointer OM_shadowThickness ROptionButton PressMB Btn1 LocatePointer shadowThicknessPB4 ReleaseMB Btn1 # #) Unselect the other check marks you don't need. # #) Now select the "IconGad3" toggle button and unselect "IconGad2". # Click on the "Apply" button. # #) You should see the girl pixmap displayed on top of the labelString, # and 2 details added on the same line. The shadow thickness is around # both the icon and the label. The pixmap should be fully visible. LocatePointer TogSet_smallIconMask ClickMB Btn1 LocatePointer TB_IconGad2 ClickMB Btn1 LocatePointer TB_IconGad3 ClickMB Btn1 LocatePointer Apply ClickMB Btn1 WindowRaise IconGadget1 CompareVisual IconGadget1 # #) Select "small_m.xpm" from the "largeIconMask", and unselected the other # check marks. # #) Click on the "Apply" button. A mask is applied on the girl pixmap, so # that the background is no longer a black box. The details should not # disappear. Now the shadow thickness is only around the label. # The pixmap should be fully visible. # C) LocatePointer OM_largeIconMask ROptionButton PressMB Btn1 LocatePointer largeIconMaskPB1 ReleaseMB Btn1 LocatePointer TogSet_labelString ClickMB Btn1 LocatePointer TogSet_largeIconPixmap ClickMB Btn1 LocatePointer TogSet_detail ClickMB Btn1 LocatePointer TogSet_detailCount ClickMB Btn1 LocatePointer TogSet_shadowThickness ClickMB Btn1 LocatePointer Apply ClickMB Btn1 WindowRaise IconGadget1 CompareVisual IconGadget1 Continue # # #) Select "0" from "detailCount" and its check mark, and unselect the # other check marks. # #) Select "IconGad1", "IconGad2" and "IconGad3", and click on the "Apply" # button. # #) All the details should disappear. LocatePointer TogSet_largeIconMask ClickMB Btn1 LocatePointer TogSet_detailCount ClickMB Btn1 LocatePointer OM_detailCount ROptionButton PressMB Btn1 LocatePointer detailCountPB0 ReleaseMB Btn1 LocatePointer TB_IconGad1 ClickMB Btn1 LocatePointer TB_IconGad2 ClickMB Btn1 LocatePointer Apply ClickMB Btn1 WindowRaise IconGadget1 CompareVisual IconGadget1 # #) Select "3" from "detailCount". # #) Select only "IconGad1", and click on the "Apply" button. # #) The details "First object Chocolate 33" should reappear. LocatePointer OM_detailCount ROptionButton PressMB Btn1 LocatePointer detailCountPB3 ReleaseMB Btn1 LocatePointer TB_IconGad2 ClickMB Btn1 LocatePointer TB_IconGad3 ClickMB Btn1 LocatePointer Apply ClickMB Btn1 WindowRaise IconGadget1 CompareVisual IconGadget1 # #) Now select "3 details" from "detail", and its check mark. # #) Click again on the "Apply button". # #) New details appear "First detail Second detail Last detail". # C) LocatePointer TogSet_detail ClickMB Btn1 LocatePointer OM_detail ROptionButton PressMB Btn1 LocatePointer detailPB2 ReleaseMB Btn1 LocatePointer Apply ClickMB Btn1 WindowRaise IconGadget1 CompareVisual IconGadget1 Continue # # #) Select the following resources, and every time the check mark on the # left: # !) # largeIconPixmap small.xbm # largeIconMask round.xbm # visualEmphasis XmSELECTED # LocatePointer TogSet_largeIconPixmap ClickMB Btn1 LocatePointer OM_largeIconPixmap ROptionButton PressMB Btn1 LocatePointer largeIconPixmapPB3 ReleaseMB Btn1 LocatePointer TogSet_largeIconMask ClickMB Btn1 LocatePointer OM_largeIconMask ROptionButton PressMB Btn1 LocatePointer largeIconMaskPB2 ReleaseMB Btn1 LocatePointer TogSet_visualEmphasis ClickMB Btn1 LocatePointer OM_visualEmphasis ROptionButton PressMB Btn1 LocatePointer visualEmphasisPB1 ReleaseMB Btn1 # #) Unselect the other check marks you don't need. # #) Now select only the "IconGad1" toggle button and click on the # "Apply" button. # #) You should see the girl bitmap displayed on top of the labelString, # in a round mask. # #) The icon gadget is selected. LocatePointer TogSet_detail ClickMB Btn1 LocatePointer TogSet_detailCount ClickMB Btn1 LocatePointer Apply ClickMB Btn1 WindowRaise IconGadget1 CompareVisual IconGadget1 # #) Keep the visualEmphasis to "XmSELECTED" and removed the other check # marks. # #) Select "IconGad3" and click on the "Apply" button. # #) Only the label appears selected. LocatePointer TogSet_largeIconPixmap ClickMB Btn1 LocatePointer TogSet_largeIconMask ClickMB Btn1 LocatePointer TB_IconGad1 ClickMB Btn1 LocatePointer TB_IconGad3 ClickMB Btn1 LocatePointer Apply ClickMB Btn1 WindowRaise IconGadget1 CompareVisual IconGadget1 # #) Select "How about something longer but useless" from "labelString" option # menu, and its check mark. Click on the "Apply" button. The label should # be centered under the icon. # C) LocatePointer TogSet_labelString ClickMB Btn1 LocatePointer OM_labelString ROptionButton PressMB Btn1 LocatePointer labelStringPB3 ReleaseMB Btn1 LocatePointer Apply ClickMB Btn1 WindowRaise IconGadget1 CompareVisual IconGadget1 Continue # # #) The function XmObjectAtPoint is called. # #) You should see the following message in your term window: # !) # The following Icon Gadget is located at 50 200: IconGad3 # # E) Exit