home *** CD-ROM | disk | FTP | other *** search
/ Club Amiga de Montreal - CAM / CAM_CD_1.iso / files / 138.lha / V_Gad / test.c < prev    next >
C/C++ Source or Header  |  1986-11-20  |  24KB  |  1,024 lines

  1. /*****************************************
  2.   This file created by Vgad Version 1.00
  3. ******************************************/
  4.  
  5. #include <intuition/intuition.h>
  6.  
  7. USHORT test0_data[] =
  8. {
  9.   0x8000,  0x0,
  10.   0x0,  0x0,
  11.   0xffff,  0xff80,
  12.   0x7ffb,  0xff80,
  13.   0xfffb,  0xff80,
  14.   0x7ffb,  0xff80,
  15.   0xffbb,  0xff80,
  16.   0x7ffb,  0xbf80,
  17.   0xfffb,  0xff80,
  18.   0x7ffb,  0xff80,
  19.   0xe000,  0x80,
  20.   0x7ffb,  0xff80,
  21.   0xfffb,  0xff80,
  22.   0x7ffb,  0xbf80,
  23.   0xff7b,  0xff80,
  24.   0x7ffb,  0xff80,
  25.   0xfffb,  0xff80,
  26.   0x7ffb,  0xff80,
  27.   0xffff,  0xff80,
  28.   0x7fff,  0xff80,
  29.   0xaaaa,  0xaaa0,
  30. /*  end of plane 0 */
  31.   0x7fff,  0xffe0,
  32.   0xffff,  0xffe0,
  33.   0x0,  0x60,
  34.   0x8004,  0x60,
  35.   0x4,  0x60,
  36.   0x8004,  0x60,
  37.   0x44,  0x60,
  38.   0x8004,  0x4060,
  39.   0x4,  0x60,
  40.   0x8004,  0x60,
  41.   0x1fff,  0xff60,
  42.   0x8004,  0x60,
  43.   0x4,  0x60,
  44.   0x8004,  0x4060,
  45.   0x84,  0x60,
  46.   0x8004,  0x60,
  47.   0x4,  0x60,
  48.   0x8004,  0x60,
  49.   0x0,  0x60,
  50.   0x8000,  0x60,
  51.   0x5555,  0x5540,
  52. /*  end of plane 1 */
  53. };  /* end of test0_data[] */
  54.  
  55. struct Image test0_image =
  56. {
  57.   0, 0,               /* left, top */
  58.   27, 21, 2,     /* width, height, depth */
  59.   &test0_data[0],   /* image data */
  60.   3, 0x0,       /* plane pick, plane on/off */
  61.   NULL              /* next image */
  62. };
  63.  
  64. USHORT test1_data[] =
  65. {
  66.   0x8000,  0x0,
  67.   0x0,  0x0,
  68.   0x8000,  0x0,
  69.   0x4,  0x0,
  70.   0x8004,  0x0,
  71.   0x4,  0x0,
  72.   0x8044,  0x0,
  73.   0x4,  0x4000,
  74.   0x8004,  0x0,
  75.   0x4,  0x0,
  76.   0x9fff,  0xff00,
  77.   0x4,  0x0,
  78.   0x8004,  0x0,
  79.   0x4,  0x4000,
  80.   0x8084,  0x0,
  81.   0x4,  0x0,
  82.   0x8004,  0x0,
  83.   0x4,  0x0,
  84.   0x8000,  0x0,
  85.   0x0,  0x0,
  86.   0xaaaa,  0xaaa0,
  87. /*  end of plane 0 */
  88.   0x7fff,  0xffe0,
  89.   0xffff,  0xffe0,
  90.   0x7fff,  0xffe0,
  91.   0xfffb,  0xffe0,
  92.   0x7ffb,  0xffe0,
  93.   0xfffb,  0xffe0,
  94.   0x7fbb,  0xffe0,
  95.   0xfffb,  0xbfe0,
  96.   0x7ffb,  0xffe0,
  97.   0xfffb,  0xffe0,
  98.   0x6000,  0xe0,
  99.   0xfffb,  0xffe0,
  100.   0x7ffb,  0xffe0,
  101.   0xfffb,  0xbfe0,
  102.   0x7f7b,  0xffe0,
  103.   0xfffb,  0xffe0,
  104.   0x7ffb,  0xffe0,
  105.   0xfffb,  0xffe0,
  106.   0x7fff,  0xffe0,
  107.   0xffff,  0xffe0,
  108.   0x5555,  0x5540,
  109. /*  end of plane 1 */
  110. };  /* end of test1_data[] */
  111.  
  112. struct Image test1_image =
  113. {
  114.   0, 0,               /* left, top */
  115.   27, 21, 2,     /* width, height, depth */
  116.   &test1_data[0],   /* image data */
  117.   3, 0x0,       /* plane pick, plane on/off */
  118.   NULL              /* next image */
  119. };
  120.  
  121. struct Gadget test0_gadget =
  122. {
  123.   NULL, /* only gadget in list */
  124.   6, 3, 27, 21, /* left, top, width, height */
  125.   GADGIMAGE | GADGHIMAGE,  /* general flags */
  126.   GADGIMMEDIATE | RELVERIFY,  /* activation flags */
  127.   BOOLGADGET,
  128.   (APTR) &test0_image, /* pointer to primary image */
  129.   (APTR) &test1_image, /* pointer to selected image */
  130.   NULL,  /* pointer to IntuiText */
  131.   0L,    /* mutual exclude bit field */
  132.   NULL,  /* no special info for a boolean gadget */
  133.   0,    /* gadget ID */
  134.   NULL  /* no known user data */
  135. };
  136.  
  137. USHORT test2_data[] =
  138. {
  139.   0x8000,  0x0,
  140.   0x0,  0x0,
  141.   0xffff,  0xfe00,
  142.   0x6fff,  0xfe00,
  143.   0xef7f,  0xfe00,
  144.   0x6e7f,  0xfe00,
  145.   0xec0f,  0xfe00,
  146.   0x6e67,  0xfe00,
  147.   0xef73,  0xfe00,
  148.   0x6ff9,  0xfe00,
  149.   0xeffc,  0xfe00,
  150.   0x6ffe,  0xfe00,
  151.   0xe0fe,  0xfe00,
  152.   0x6efe,  0xfe00,
  153.   0xeeff,  0xfe00,
  154.   0x6000,  0x200,
  155.   0xffff,  0xfe00,
  156.   0x7fff,  0xfe00,
  157.   0xaaaa,  0xaa80,
  158. /*  end of plane 0 */
  159.   0x7fff,  0xff80,
  160.   0xffff,  0xff80,
  161.   0x0,  0x180,
  162.   0x9000,  0x180,
  163.   0x1080,  0x180,
  164.   0x9180,  0x180,
  165.   0x13f0,  0x180,
  166.   0x9198,  0x180,
  167.   0x108c,  0x180,
  168.   0x9006,  0x180,
  169.   0x1003,  0x180,
  170.   0x9001,  0x180,
  171.   0x1f01,  0x180,
  172.   0x9101,  0x180,
  173.   0x1100,  0x180,
  174.   0x9fff,  0xfd80,
  175.   0x0,  0x180,
  176.   0x8000,  0x180,
  177.   0x5555,  0x5500,
  178. /*  end of plane 1 */
  179. };  /* end of test2_data[] */
  180.  
  181. struct Image test2_image =
  182. {
  183.   0, 0,               /* left, top */
  184.   25, 19, 2,     /* width, height, depth */
  185.   &test2_data[0],   /* image data */
  186.   3, 0x0,       /* plane pick, plane on/off */
  187.   NULL              /* next image */
  188. };
  189.  
  190. USHORT test3_data[] =
  191. {
  192.   0x8000,  0x0,
  193.   0x0,  0x0,
  194.   0x8000,  0x0,
  195.   0x1000,  0x0,
  196.   0x9080,  0x0,
  197.   0x1180,  0x0,
  198.   0x93f0,  0x0,
  199.   0x1198,  0x0,
  200.   0x908c,  0x0,
  201.   0x1006,  0x0,
  202.   0x9003,  0x0,
  203.   0x1001,  0x0,
  204.   0x9f01,  0x0,
  205.   0x1101,  0x0,
  206.   0x9100,  0x0,
  207.   0x1fff,  0xfc00,
  208.   0x8000,  0x0,
  209.   0x0,  0x0,
  210.   0xaaaa,  0xaa80,
  211. /*  end of plane 0 */
  212.   0x7fff,  0xff80,
  213.   0xffff,  0xff80,
  214.   0x7fff,  0xff80,
  215.   0xefff,  0xff80,
  216.   0x6f7f,  0xff80,
  217.   0xee7f,  0xff80,
  218.   0x6c0f,  0xff80,
  219.   0xee67,  0xff80,
  220.   0x6f73,  0xff80,
  221.   0xeff9,  0xff80,
  222.   0x6ffc,  0xff80,
  223.   0xeffe,  0xff80,
  224.   0x60fe,  0xff80,
  225.   0xeefe,  0xff80,
  226.   0x6eff,  0xff80,
  227.   0xe000,  0x380,
  228.   0x7fff,  0xff80,
  229.   0xffff,  0xff80,
  230.   0x5555,  0x5500,
  231. /*  end of plane 1 */
  232. };  /* end of test3_data[] */
  233.  
  234. struct Image test3_image =
  235. {
  236.   0, 0,               /* left, top */
  237.   25, 19, 2,     /* width, height, depth */
  238.   &test3_data[0],   /* image data */
  239.   3, 0x0,       /* plane pick, plane on/off */
  240.   NULL              /* next image */
  241. };
  242.  
  243. struct Gadget test1_gadget =
  244. {
  245.   &test0_gadget, /* only gadget in list */   /***** Changed this line ***/
  246.   51, 3, 25, 19, /* left, top, width, height */
  247.   GADGIMAGE | GADGHIMAGE,  /* general flags */
  248.   GADGIMMEDIATE | RELVERIFY,  /* activation flags */
  249.   BOOLGADGET,
  250.   (APTR) &test2_image, /* pointer to primary image */
  251.   (APTR) &test3_image, /* pointer to selected image */
  252.   NULL,  /* pointer to IntuiText */
  253.   0L,    /* mutual exclude bit field */
  254.   NULL,  /* no special info for a boolean gadget */
  255.   1,    /* gadget ID */
  256.   NULL  /* no known user data */
  257. };
  258.  
  259. USHORT test4_data[] =
  260. {
  261.   0x8000,  0x0,
  262.   0x0,  0x0,
  263.   0xffff,  0xe000,
  264.   0x6fbf,  0xe000,
  265.   0xefbf,  0xe000,
  266.   0x6fbf,  0xe000,
  267.   0xefbf,  0xe000,
  268.   0x603f,  0xe000,
  269.   0xefbc,  0x2000,
  270.   0x6500,  0x2000,
  271.   0xefbc,  0x2000,
  272.   0x6a80,  0x2000,
  273.   0xefbf,  0xe000,
  274.   0x653f,  0xe000,
  275.   0xefbf,  0xe000,
  276.   0x603f,  0xe000,
  277.   0xffff,  0xe000,
  278.   0x7fff,  0xe000,
  279.   0xffff,  0xe800,
  280.   0x5555,  0x5800,
  281. /*  end of plane 0 */
  282.   0x7fff,  0xf800,
  283.   0xffff,  0xf800,
  284.   0x0,  0x1800,
  285.   0x9040,  0x1800,
  286.   0x1040,  0x1800,
  287.   0x9040,  0x1800,
  288.   0x1040,  0x1800,
  289.   0x9fc0,  0x1800,
  290.   0x1043,  0xd800,
  291.   0x9aff,  0xd800,
  292.   0x1043,  0xd800,
  293.   0x957f,  0xd800,
  294.   0x1040,  0x1800,
  295.   0x9ac0,  0x1800,
  296.   0x1040,  0x1800,
  297.   0x9fc0,  0x1800,
  298.   0x0,  0x1800,
  299.   0x8000,  0x1800,
  300.   0x0,  0x1000,
  301.   0xaaaa,  0xa000,
  302. /*  end of plane 1 */
  303. };  /* end of test4_data[] */
  304.  
  305. struct Image test4_image =
  306. {
  307.   0, 0,               /* left, top */
  308.   21, 20, 2,     /* width, height, depth */
  309.   &test4_data[0],   /* image data */
  310.   3, 0x0,       /* plane pick, plane on/off */
  311.   NULL              /* next image */
  312. };
  313.  
  314. USHORT test5_data[] =
  315. {
  316.   0x8000,  0x0,
  317.   0x0,  0x0,
  318.   0x8000,  0x0,
  319.   0x1040,  0x0,
  320.   0x9040,  0x0,
  321.   0x1040,  0x0,
  322.   0x9040,  0x0,
  323.   0x1fc0,  0x0,
  324.   0x9043,  0xc000,
  325.   0x1aff,  0xc000,
  326.   0x9043,  0xc000,
  327.   0x157f,  0xc000,
  328.   0x9040,  0x0,
  329.   0x1ac0,  0x0,
  330.   0x9040,  0x0,
  331.   0x1fc0,  0x0,
  332.   0x8000,  0x0,
  333.   0x0,  0x0,
  334.   0x8000,  0x800,
  335.   0x5555,  0x5800,
  336. /*  end of plane 0 */
  337.   0x7fff,  0xf800,
  338.   0xffff,  0xf800,
  339.   0x7fff,  0xf800,
  340.   0xefbf,  0xf800,
  341.   0x6fbf,  0xf800,
  342.   0xefbf,  0xf800,
  343.   0x6fbf,  0xf800,
  344.   0xe03f,  0xf800,
  345.   0x6fbc,  0x3800,
  346.   0xe500,  0x3800,
  347.   0x6fbc,  0x3800,
  348.   0xea80,  0x3800,
  349.   0x6fbf,  0xf800,
  350.   0xe53f,  0xf800,
  351.   0x6fbf,  0xf800,
  352.   0xe03f,  0xf800,
  353.   0x7fff,  0xf800,
  354.   0xffff,  0xf800,
  355.   0x7fff,  0xf000,
  356.   0xaaaa,  0xa000,
  357. /*  end of plane 1 */
  358. };  /* end of test5_data[] */
  359.  
  360. struct Image test5_image =
  361. {
  362.   0, 0,               /* left, top */
  363.   21, 20, 2,     /* width, height, depth */
  364.   &test5_data[0],   /* image data */
  365.   3, 0x0,       /* plane pick, plane on/off */
  366.   NULL              /* next image */
  367. };
  368.  
  369. struct Gadget test2_gadget =
  370. {
  371.   &test1_gadget, /* only gadget in list */  /***** Changed this line *****/
  372.   103, 6, 21, 20, /* left, top, width, height */
  373.   GADGIMAGE | GADGHIMAGE,  /* general flags */
  374.   GADGIMMEDIATE | RELVERIFY,  /* activation flags */
  375.   BOOLGADGET,
  376.   (APTR) &test4_image, /* pointer to primary image */
  377.   (APTR) &test5_image, /* pointer to selected image */
  378.   NULL,  /* pointer to IntuiText */
  379.   0L,    /* mutual exclude bit field */
  380.   NULL,  /* no special info for a boolean gadget */
  381.   2,    /* gadget ID */
  382.   NULL  /* no known user data */
  383. };
  384.  
  385. USHORT test6_data[] =
  386. {
  387.   0x8000,  0x0,  0x0,
  388.   0x0,  0x0,  0x0,
  389.   0xffff,  0xffff,  0x0,
  390.   0x7fff,  0xc03f,  0x0,
  391.   0xffff,  0x9fcf,  0x0,
  392.   0x7fff,  0x3ff7,  0x0,
  393.   0xeffe,  0x7ffb,  0x0,
  394.   0x6ffc,  0xfffd,  0x0,
  395.   0xe7f9,  0xfffd,  0x0,
  396.   0x77f3,  0xffff,  0x0,
  397.   0xf3e7,  0xffff,  0x0,
  398.   0x780f,  0xffff,  0x0,
  399.   0xff3f,  0xffff,  0x0,
  400.   0x7fff,  0xffff,  0x0,
  401.   0xffff,  0xffff,  0x0,
  402.   0x7fff,  0xffff,  0x4000,
  403.   0xaaaa,  0xaaaa,  0xc000,
  404. /*  end of plane 0 */
  405.   0x7fff,  0xffff,  0xc000,
  406.   0xffff,  0xffff,  0xc000,
  407.   0x0,  0x0,  0xc000,
  408.   0x8000,  0x3fc0,  0xc000,
  409.   0x0,  0x6030,  0xc000,
  410.   0x8000,  0xc008,  0xc000,
  411.   0x1001,  0x8004,  0xc000,
  412.   0x9003,  0x2,  0xc000,
  413.   0x1806,  0x2,  0xc000,
  414.   0x880c,  0x0,  0xc000,
  415.   0xc18,  0x0,  0xc000,
  416.   0x87f0,  0x0,  0xc000,
  417.   0xc0,  0x0,  0xc000,
  418.   0x8000,  0x0,  0xc000,
  419.   0x0,  0x0,  0xc000,
  420.   0x8000,  0x0,  0x8000,
  421.   0x5555,  0x5555,  0x0,
  422. /*  end of plane 1 */
  423. };  /* end of test6_data[] */
  424.  
  425. struct Image test6_image =
  426. {
  427.   0, 0,               /* left, top */
  428.   34, 17, 2,     /* width, height, depth */
  429.   &test6_data[0],   /* image data */
  430.   3, 0x0,       /* plane pick, plane on/off */
  431.   NULL              /* next image */
  432. };
  433.  
  434. USHORT test7_data[] =
  435. {
  436.   0x8000,  0x0,  0x0,
  437.   0x0,  0x0,  0x0,
  438.   0x8000,  0x0,  0x0,
  439.   0x0,  0x3fc0,  0x0,
  440.   0x8000,  0x6030,  0x0,
  441.   0x0,  0xc008,  0x0,
  442.   0x9001,  0x8004,  0x0,
  443.   0x1003,  0x2,  0x0,
  444.   0x9806,  0x2,  0x0,
  445.   0x80c,  0x0,  0x0,
  446.   0x8c18,  0x0,  0x0,
  447.   0x7f0,  0x0,  0x0,
  448.   0x80c0,  0x0,  0x0,
  449.   0x0,  0x0,  0x0,
  450.   0x8000,  0x0,  0x0,
  451.   0x0,  0x0,  0x4000,
  452.   0xaaaa,  0xaaaa,  0xc000,
  453. /*  end of plane 0 */
  454.   0x7fff,  0xffff,  0xc000,
  455.   0xffff,  0xffff,  0xc000,
  456.   0x7fff,  0xffff,  0xc000,
  457.   0xffff,  0xc03f,  0xc000,
  458.   0x7fff,  0x9fcf,  0xc000,
  459.   0xffff,  0x3ff7,  0xc000,
  460.   0x6ffe,  0x7ffb,  0xc000,
  461.   0xeffc,  0xfffd,  0xc000,
  462.   0x67f9,  0xfffd,  0xc000,
  463.   0xf7f3,  0xffff,  0xc000,
  464.   0x73e7,  0xffff,  0xc000,
  465.   0xf80f,  0xffff,  0xc000,
  466.   0x7f3f,  0xffff,  0xc000,
  467.   0xffff,  0xffff,  0xc000,
  468.   0x7fff,  0xffff,  0xc000,
  469.   0xffff,  0xffff,  0x8000,
  470.   0x5555,  0x5555,  0x0,
  471. /*  end of plane 1 */
  472. };  /* end of test7_data[] */
  473.  
  474. struct Image test7_image =
  475. {
  476.   0, 0,               /* left, top */
  477.   34, 17, 2,     /* width, height, depth */
  478.   &test7_data[0],   /* image data */
  479.   3, 0x0,       /* plane pick, plane on/off */
  480.   NULL              /* next image */
  481. };
  482.  
  483. struct Gadget test3_gadget =
  484. {
  485.   &test2_gadget, /* only gadget in list */  /***** Changed this line *****/
  486.   3, 34, 34, 17, /* left, top, width, height */
  487.   GADGIMAGE | GADGHIMAGE,  /* general flags */
  488.   GADGIMMEDIATE | RELVERIFY,  /* activation flags */
  489.   BOOLGADGET,
  490.   (APTR) &test6_image, /* pointer to primary image */
  491.   (APTR) &test7_image, /* pointer to selected image */
  492.   NULL,  /* pointer to IntuiText */
  493.   0L,    /* mutual exclude bit field */
  494.   NULL,  /* no special info for a boolean gadget */
  495.   3,    /* gadget ID */
  496.   NULL  /* no known user data */
  497. };
  498.  
  499. USHORT test8_data[] =
  500. {
  501.   0x8000,  0x0,
  502.   0x0,  0x0,
  503.   0xffff,  0xffc0,
  504.   0x7fff,  0xffc0,
  505.   0xffff,  0xffc0,
  506.   0x7bff,  0xfbc0,
  507.   0xf3ff,  0xf9c0,
  508.   0x63ff,  0xf8c0,
  509.   0xc000,  0x40,
  510.   0x63ff,  0xf8c0,
  511.   0xf3ff,  0xf9c0,
  512.   0x7bff,  0xfbc0,
  513.   0xffff,  0xffc0,
  514.   0x7fff,  0xffc0,
  515.   0xffff,  0xffc0,
  516.   0x5555,  0x5550,
  517. /*  end of plane 0 */
  518.   0x7fff,  0xfff0,
  519.   0xffff,  0xfff0,
  520.   0x0,  0x30,
  521.   0x8000,  0x30,
  522.   0x0,  0x30,
  523.   0x8400,  0x430,
  524.   0xc00,  0x630,
  525.   0x9c00,  0x730,
  526.   0x3fff,  0xffb0,
  527.   0x9c00,  0x730,
  528.   0xc00,  0x630,
  529.   0x8400,  0x430,
  530.   0x0,  0x30,
  531.   0x8000,  0x30,
  532.   0x0,  0x30,
  533.   0xaaaa,  0xaaa0,
  534. /*  end of plane 1 */
  535. };  /* end of test8_data[] */
  536.  
  537. struct Image test8_image =
  538. {
  539.   0, 0,               /* left, top */
  540.   28, 16, 2,     /* width, height, depth */
  541.   &test8_data[0],   /* image data */
  542.   3, 0x0,       /* plane pick, plane on/off */
  543.   NULL              /* next image */
  544. };
  545.  
  546. USHORT test9_data[] =
  547. {
  548.   0x8000,  0x0,
  549.   0x0,  0x0,
  550.   0x8000,  0x0,
  551.   0x0,  0x0,
  552.   0x8000,  0x0,
  553.   0x400,  0x400,
  554.   0x8c00,  0x600,
  555.   0x1c00,  0x700,
  556.   0xbfff,  0xff80,
  557.   0x1c00,  0x700,
  558.   0x8c00,  0x600,
  559.   0x400,  0x400,
  560.   0x8000,  0x0,
  561.   0x0,  0x0,
  562.   0x8000,  0x0,
  563.   0x5555,  0x5550,
  564. /*  end of plane 0 */
  565.   0x7fff,  0xfff0,
  566.   0xffff,  0xfff0,
  567.   0x7fff,  0xfff0,
  568.   0xffff,  0xfff0,
  569.   0x7fff,  0xfff0,
  570.   0xfbff,  0xfbf0,
  571.   0x73ff,  0xf9f0,
  572.   0xe3ff,  0xf8f0,
  573.   0x4000,  0x70,
  574.   0xe3ff,  0xf8f0,
  575.   0x73ff,  0xf9f0,
  576.   0xfbff,  0xfbf0,
  577.   0x7fff,  0xfff0,
  578.   0xffff,  0xfff0,
  579.   0x7fff,  0xfff0,
  580.   0xaaaa,  0xaaa0,
  581. /*  end of plane 1 */
  582. };  /* end of test9_data[] */
  583.  
  584. struct Image test9_image =
  585. {
  586.   0, 0,               /* left, top */
  587.   28, 16, 2,     /* width, height, depth */
  588.   &test9_data[0],   /* image data */
  589.   3, 0x0,       /* plane pick, plane on/off */
  590.   NULL              /* next image */
  591. };
  592.  
  593. struct Gadget test4_gadget =
  594. {
  595.   &test3_gadget, /* only gadget in list */  /******* Changed this line ****/
  596.   52, 30, 28, 16, /* left, top, width, height */
  597.   GADGIMAGE | GADGHIMAGE,  /* general flags */
  598.   GADGIMMEDIATE | RELVERIFY,  /* activation flags */
  599.   BOOLGADGET,
  600.   (APTR) &test8_image, /* pointer to primary image */
  601.   (APTR) &test9_image, /* pointer to selected image */
  602.   NULL,  /* pointer to IntuiText */
  603.   0L,    /* mutual exclude bit field */
  604.   NULL,  /* no special info for a boolean gadget */
  605.   4,    /* gadget ID */
  606.   NULL  /* no known user data */
  607. };
  608.  
  609. USHORT test10_data[] =
  610. {
  611.   0x8000,  0x0,
  612.   0x0,  0x0,
  613.   0xffff,  0xff80,
  614.   0x7ff7,  0xfe80,
  615.   0xffef,  0xfd80,
  616.   0x7fdf,  0xfb80,
  617.   0xff80,  0x780,
  618.   0x7f7f,  0xef80,
  619.   0xfeaa,  0xdf80,
  620.   0x7dff,  0xbf80,
  621.   0xfb55,  0x7f80,
  622.   0x77fe,  0xff80,
  623.   0xe001,  0xff80,
  624.   0x7fff,  0xff80,
  625.   0xffff,  0xff80,
  626.   0x5555,  0x5520,
  627. /*  end of plane 0 */
  628.   0x7fff,  0xffe0,
  629.   0xffff,  0xffe0,
  630.   0x0,  0x60,
  631.   0x8008,  0x160,
  632.   0x10,  0x260,
  633.   0x8020,  0x460,
  634.   0x7f,  0xf860,
  635.   0x8080,  0x1060,
  636.   0x155,  0x2060,
  637.   0x8200,  0x4060,
  638.   0x4aa,  0x8060,
  639.   0x8801,  0x60,
  640.   0x1ffe,  0x60,
  641.   0x8000,  0x60,
  642.   0x0,  0x60,
  643.   0xaaaa,  0xaac0,
  644. /*  end of plane 1 */
  645. };  /* end of test10_data[] */
  646.  
  647. struct Image test10_image =
  648. {
  649.   0, 0,               /* left, top */
  650.   27, 16, 2,     /* width, height, depth */
  651.   &test10_data[0],   /* image data */
  652.   3, 0x0,       /* plane pick, plane on/off */
  653.   NULL              /* next image */
  654. };
  655.  
  656. USHORT test11_data[] =
  657. {
  658.   0x8000,  0x0,
  659.   0x0,  0x0,
  660.   0x8000,  0x0,
  661.   0x8,  0x100,
  662.   0x8010,  0x200,
  663.   0x20,  0x400,
  664.   0x807f,  0xf800,
  665.   0x80,  0x1000,
  666.   0x8155,  0x2000,
  667.   0x200,  0x4000,
  668.   0x84aa,  0x8000,
  669.   0x801,  0x0,
  670.   0x9ffe,  0x0,
  671.   0x0,  0x0,
  672.   0x8000,  0x0,
  673.   0x5555,  0x5520,
  674. /*  end of plane 0 */
  675.   0x7fff,  0xffe0,
  676.   0xffff,  0xffe0,
  677.   0x7fff,  0xffe0,
  678.   0xfff7,  0xfee0,
  679.   0x7fef,  0xfde0,
  680.   0xffdf,  0xfbe0,
  681.   0x7f80,  0x7e0,
  682.   0xff7f,  0xefe0,
  683.   0x7eaa,  0xdfe0,
  684.   0xfdff,  0xbfe0,
  685.   0x7b55,  0x7fe0,
  686.   0xf7fe,  0xffe0,
  687.   0x6001,  0xffe0,
  688.   0xffff,  0xffe0,
  689.   0x7fff,  0xffe0,
  690.   0xaaaa,  0xaac0,
  691. /*  end of plane 1 */
  692. };  /* end of test11_data[] */
  693.  
  694. struct Image test11_image =
  695. {
  696.   0, 0,               /* left, top */
  697.   27, 16, 2,     /* width, height, depth */
  698.   &test11_data[0],   /* image data */
  699.   3, 0x0,       /* plane pick, plane on/off */
  700.   NULL              /* next image */
  701. };
  702.  
  703. struct Gadget test5_gadget =
  704. {
  705.   &test4_gadget, /* only gadget in list */  /***** Changed this line *****/
  706.   98, 29, 27, 16, /* left, top, width, height */
  707.   GADGIMAGE | GADGHIMAGE,  /* general flags */
  708.   GADGIMMEDIATE | RELVERIFY,  /* activation flags */
  709.   BOOLGADGET,
  710.   (APTR) &test10_image, /* pointer to primary image */
  711.   (APTR) &test11_image, /* pointer to selected image */
  712.   NULL,  /* pointer to IntuiText */
  713.   0L,    /* mutual exclude bit field */
  714.   NULL,  /* no special info for a boolean gadget */
  715.   5,    /* gadget ID */
  716.   NULL  /* no known user data */
  717. };
  718.  
  719. USHORT test12_data[] =
  720. {
  721.   0x8000,  0x0,  0x0,
  722.   0x0,  0x0,  0x0,
  723.   0xffff,  0xffff,  0xffc0,
  724.   0x61fb,  0xffff,  0xfbc0,
  725.   0xccf3,  0xffff,  0xf3c0,
  726.   0x4ff3,  0xffff,  0xf3c0,
  727.   0xe7e0,  0xe189,  0xe0c0,
  728.   0x73f3,  0xfcc4,  0xf3c0,
  729.   0xf9f3,  0xf0cc,  0xf3c0,
  730.   0x7cf3,  0xcccf,  0xf3c0,
  731.   0xccf2,  0xcccf,  0xf2c0,
  732.   0x61f9,  0xe207,  0xf9c0,
  733.   0xffff,  0xffff,  0xffc0,
  734.   0x7fff,  0xffff,  0xffc0,
  735.   0xffff,  0xffff,  0xffc0,
  736.   0x5555,  0x5555,  0x5550,
  737. /*  end of plane 0 */
  738.   0x7fff,  0xffff,  0xfff0,
  739.   0xffff,  0xffff,  0xfff0,
  740.   0x0,  0x0,  0x30,
  741.   0x9e04,  0x0,  0x430,
  742.   0x330c,  0x0,  0xc30,
  743.   0xb00c,  0x0,  0xc30,
  744.   0x181f,  0x1e76,  0x1f30,
  745.   0x8c0c,  0x33b,  0xc30,
  746.   0x60c,  0xf33,  0xc30,
  747.   0x830c,  0x3330,  0xc30,
  748.   0x330d,  0x3330,  0xd30,
  749.   0x9e06,  0x1df8,  0x630,
  750.   0x0,  0x0,  0x30,
  751.   0x8000,  0x0,  0x30,
  752.   0x0,  0x0,  0x30,
  753.   0xaaaa,  0xaaaa,  0xaaa0,
  754. /*  end of plane 1 */
  755. };  /* end of test12_data[] */
  756.  
  757. struct Image test12_image =
  758. {
  759.   0, 0,               /* left, top */
  760.   44, 16, 2,     /* width, height, depth */
  761.   &test12_data[0],   /* image data */
  762.   3, 0x0,       /* plane pick, plane on/off */
  763.   NULL              /* next image */
  764. };
  765.  
  766. USHORT test13_data[] =
  767. {
  768.   0x8000,  0x0,  0x0,
  769.   0x0,  0x0,  0x0,
  770.   0x8000,  0x0,  0x0,
  771.   0x1e04,  0x0,  0x400,
  772.   0xb30c,  0x0,  0xc00,
  773.   0x300c,  0x0,  0xc00,
  774.   0x981f,  0x1e76,  0x1f00,
  775.   0xc0c,  0x33b,  0xc00,
  776.   0x860c,  0xf33,  0xc00,
  777.   0x30c,  0x3330,  0xc00,
  778.   0xb30d,  0x3330,  0xd00,
  779.   0x1e06,  0x1df8,  0x600,
  780.   0x8000,  0x0,  0x0,
  781.   0x0,  0x0,  0x0,
  782.   0x8000,  0x0,  0x0,
  783.   0x5555,  0x5555,  0x5550,
  784. /*  end of plane 0 */
  785.   0x7fff,  0xffff,  0xfff0,
  786.   0xffff,  0xffff,  0xfff0,
  787.   0x7fff,  0xffff,  0xfff0,
  788.   0xe1fb,  0xffff,  0xfbf0,
  789.   0x4cf3,  0xffff,  0xf3f0,
  790.   0xcff3,  0xffff,  0xf3f0,
  791.   0x67e0,  0xe189,  0xe0f0,
  792.   0xf3f3,  0xfcc4,  0xf3f0,
  793.   0x79f3,  0xf0cc,  0xf3f0,
  794.   0xfcf3,  0xcccf,  0xf3f0,
  795.   0x4cf2,  0xcccf,  0xf2f0,
  796.   0xe1f9,  0xe207,  0xf9f0,
  797.   0x7fff,  0xffff,  0xfff0,
  798.   0xffff,  0xffff,  0xfff0,
  799.   0x7fff,  0xffff,  0xfff0,
  800.   0xaaaa,  0xaaaa,  0xaaa0,
  801. /*  end of plane 1 */
  802. };  /* end of test13_data[] */
  803.  
  804. struct Image test13_image =
  805. {
  806.   0, 0,               /* left, top */
  807.   44, 16, 2,     /* width, height, depth */
  808.   &test13_data[0],   /* image data */
  809.   3, 0x0,       /* plane pick, plane on/off */
  810.   NULL              /* next image */
  811. };
  812.  
  813. struct Gadget test6_gadget =
  814. {
  815.   &test5_gadget, /* only gadget in list */  /****** Changed this line ****/
  816.   3, 55, 44, 16, /* left, top, width, height */
  817.   GADGIMAGE | GADGHIMAGE,  /* general flags */
  818.   GADGIMMEDIATE | RELVERIFY,  /* activation flags */
  819.   BOOLGADGET,
  820.   (APTR) &test12_image, /* pointer to primary image */
  821.   (APTR) &test13_image, /* pointer to selected image */
  822.   NULL,  /* pointer to IntuiText */
  823.   0L,    /* mutual exclude bit field */
  824.   NULL,  /* no special info for a boolean gadget */
  825.   6,    /* gadget ID */
  826.   NULL  /* no known user data */
  827. };
  828.  
  829. USHORT test14_data[] =
  830. {
  831.   0x0,  0x0,  0x0,
  832.   0xffff,  0xffff,  0xc000,
  833.   0x70fd,  0xffff,  0xc000,
  834.   0xe679,  0xffff,  0xc000,
  835.   0x67f9,  0xffff,  0xc000,
  836.   0xf3f0,  0x70c8,  0xc000,
  837.   0x79f9,  0xe666,  0x4000,
  838.   0xfcf9,  0xe666,  0x4000,
  839.   0x7e79,  0xe666,  0x4000,
  840.   0xe679,  0x6660,  0xc000,
  841.   0x70fc,  0xf0e7,  0xc000,
  842.   0xffff,  0xffe7,  0xc000,
  843.   0x7fff,  0xffc3,  0xc000,
  844.   0xffff,  0xffff,  0xc000,
  845.   0x7fff,  0xffff,  0xd000,
  846.   0xaaaa,  0xaaaa,  0xb000,
  847. /*  end of plane 0 */
  848.   0xffff,  0xffff,  0xf000,
  849.   0x0,  0x0,  0x3000,
  850.   0x8f02,  0x0,  0x3000,
  851.   0x1986,  0x0,  0x3000,
  852.   0x9806,  0x0,  0x3000,
  853.   0xc0f,  0x8f37,  0x3000,
  854.   0x8606,  0x1999,  0xb000,
  855.   0x306,  0x1999,  0xb000,
  856.   0x8186,  0x1999,  0xb000,
  857.   0x1986,  0x999f,  0x3000,
  858.   0x8f03,  0xf18,  0x3000,
  859.   0x0,  0x18,  0x3000,
  860.   0x8000,  0x3c,  0x3000,
  861.   0x0,  0x0,  0x3000,
  862.   0x8000,  0x0,  0x2000,
  863.   0x5555,  0x5555,  0x4000,
  864. /*  end of plane 1 */
  865. };  /* end of test14_data[] */
  866.  
  867. struct Image test14_image =
  868. {
  869.   0, 0,               /* left, top */
  870.   36, 16, 2,     /* width, height, depth */
  871.   &test14_data[0],   /* image data */
  872.   3, 0x0,       /* plane pick, plane on/off */
  873.   NULL              /* next image */
  874. };
  875.  
  876. USHORT test15_data[] =
  877. {
  878.   0x0,  0x0,  0x0,
  879.   0x8000,  0x0,  0x0,
  880.   0xf02,  0x0,  0x0,
  881.   0x9986,  0x0,  0x0,
  882.   0x1806,  0x0,  0x0,
  883.   0x8c0f,  0x8f37,  0x0,
  884.   0x606,  0x1999,  0x8000,
  885.   0x8306,  0x1999,  0x8000,
  886.   0x186,  0x1999,  0x8000,
  887.   0x9986,  0x999f,  0x0,
  888.   0xf03,  0xf18,  0x0,
  889.   0x8000,  0x18,  0x0,
  890.   0x0,  0x3c,  0x0,
  891.   0x8000,  0x0,  0x0,
  892.   0x0,  0x0,  0x1000,
  893.   0xaaaa,  0xaaaa,  0xb000,
  894. /*  end of plane 0 */
  895.   0xffff,  0xffff,  0xf000,
  896.   0x7fff,  0xffff,  0xf000,
  897.   0xf0fd,  0xffff,  0xf000,
  898.   0x6679,  0xffff,  0xf000,
  899.   0xe7f9,  0xffff,  0xf000,
  900.   0x73f0,  0x70c8,  0xf000,
  901.   0xf9f9,  0xe666,  0x7000,
  902.   0x7cf9,  0xe666,  0x7000,
  903.   0xfe79,  0xe666,  0x7000,
  904.   0x6679,  0x6660,  0xf000,
  905.   0xf0fc,  0xf0e7,  0xf000,
  906.   0x7fff,  0xffe7,  0xf000,
  907.   0xffff,  0xffc3,  0xf000,
  908.   0x7fff,  0xffff,  0xf000,
  909.   0xffff,  0xffff,  0xe000,
  910.   0x5555,  0x5555,  0x4000,
  911. /*  end of plane 1 */
  912. };  /* end of test15_data[] */
  913.  
  914. struct Image test15_image =
  915. {
  916.   0, 0,               /* left, top */
  917.   36, 16, 2,     /* width, height, depth */
  918.   &test15_data[0],   /* image data */
  919.   3, 0x0,       /* plane pick, plane on/off */
  920.   NULL              /* next image */
  921. };
  922.  
  923. struct Gadget test7_gadget =
  924. {
  925.   &test6_gadget, /* only gadget in list */  /******* Changed this line *****/
  926.   96, 56, 36, 16, /* left, top, width, height */
  927.   GADGIMAGE | GADGHIMAGE,  /* general flags */
  928.   GADGIMMEDIATE | RELVERIFY,  /* activation flags */
  929.   BOOLGADGET,
  930.   (APTR) &test14_image, /* pointer to primary image */
  931.   (APTR) &test15_image, /* pointer to selected image */
  932.   NULL,  /* pointer to IntuiText */
  933.   0L,    /* mutual exclude bit field */
  934.   NULL,  /* no special info for a boolean gadget */
  935.   7,    /* gadget ID */
  936.   NULL  /* no known user data */
  937. };
  938.  
  939. struct NewWindow test0_newwindow =
  940. {
  941.   0, 0,  /* left edge, top edge */
  942.   136, 73,  /* width, height */
  943.   -1, -1,  /* detail pen, block pen */
  944.   MOUSEBUTTONS | MOUSEMOVE | GADGETUP | GADGETDOWN |
  945.   CLOSEWINDOW | MENUPICK | VANILLAKEY, /* IDCMP Flags */
  946.   SMART_REFRESH | REPORTMOUSE |
  947.   ACTIVATE | NOCAREREFRESH, /* Window Flags */  /**** Changed this line ***/
  948.   &test7_gadget, /* pointer to first gadget */  /**** Changed this line ***/
  949.   NULL, /* pointer to checkmark Image */
  950.   NULL, /* Window title */                      /**** Changed this line ***/
  951.   NULL, /* pointer to screen to open on */
  952.   NULL, /* pointer to super bitmap */
  953.   20, 20,  /* minimum width, height */
  954.   -1, -1,  /* maximum width, height */
  955.   WBENCHSCREEN  /* workbench screen */
  956. };
  957.  
  958. /*****************************************************************
  959.   This is the end of the output from Vgad.  From this point
  960.   on is a quicky little stub.c code that I use a lot when setting
  961.   up a new program.  You are welcome to use it if you find it
  962.   useful...
  963. ******************************************************************/
  964.  
  965. #include <exec/memory.h>
  966. #include <graphics/view.h>
  967. #include <stdio.h>
  968. #include <functions.h>
  969.  
  970. #define NO_INTUITION   1
  971. #define NO_GRAPHICS    2
  972.  
  973. struct IntuitionBase *IntuitionBase;
  974. struct GfxBase *GfxBase;
  975.  
  976. /************************************************************
  977.   The following routine just opens the libraries
  978. ************************************************************/
  979.  
  980. short OpenLibs()
  981. {
  982.   short flags; /* any libraries that do not open get recorded here */
  983.  
  984.   flags = 0;
  985.   IntuitionBase = (struct IntuitionBase *)
  986.                   OpenLibrary("intuition.library", 0L);
  987.   GfxBase =       (struct GfxBase *)
  988.                   OpenLibrary("graphics.library", 0L);
  989.   if (!IntuitionBase) flags |= NO_INTUITION;
  990.   if (!GfxBase) flags |= NO_GRAPHICS;
  991.   return(flags);
  992. }
  993.  
  994. void CloseLibs(flags)
  995. short flags;
  996. {
  997.   if (!(flags & NO_INTUITION)) CloseLibrary(IntuitionBase);
  998.   if (!(flags & NO_GRAPHICS))  CloseLibrary(GfxBase);
  999. }
  1000.  
  1001. void main(argc, argv)
  1002. short argc;
  1003. char *argv[];
  1004. {
  1005.   short lib_flags, init_flags;
  1006.   struct Window *w;
  1007.  
  1008.   lib_flags  = OpenLibs();
  1009.   if (!lib_flags)
  1010.   {
  1011.     w = OpenWindow(&test0_newwindow);
  1012.     if (w)
  1013.     {
  1014.       SetAPen(w->RPort, 1L);
  1015.       SetDrMd(w->RPort, JAM1);
  1016.       RectFill(w->RPort, 0L, 0L, (long) w->Width - 1, (long) w->Height - 1);
  1017.       RefreshGadgets(w->FirstGadget, w, NULL);
  1018.       Delay(500L);
  1019.       CloseWindow(w);
  1020.     }
  1021.     CloseLibs(lib_flags);
  1022.   }
  1023. }
  1024.