/* Generated with C2C (Cedar To C)*/
/* Copyright (C) 1992 by Xerox Corporation.  All rights reserved. */
/* time: April 21, 1992 12:48:29 pm PDT */
/* C2C version: October 16, 1990 (native) */
/* ref-counting: off */
/* file: X11TilingDemo, module: X11TilingDemo */ 
/* switches: bcfhklnouw */ 
#include <cedar/InstallationSupport.h>
#include <cedar/CedarExtra.h>
static char versionStamp[] = "@(#)mob←version [3584048206,2842105497] X11TilingDemo";
typedef unsigned word, *ptr;
typedef unsigned char byte, *bPt;
typedef unsigned short half, *hPt;
typedef word (*fPt)();
typedef struct {word f0, f1, f2, f3, f4, f5, f6;} W7;
typedef struct {word f0, f1;} W2;
typedef struct {word f0, f1, f2, f3, f4, f5, f6, f7;} W8;
typedef struct {W8 f; W8 r;} W16;
typedef struct {word f0, f1, f2, f3;} W4;
typedef struct {W16 f; W4 r;} W20;
typedef struct {W8 f; word r;} W9;
typedef W9 *W9Pt;
typedef struct {word f0, f1, f2, f3, f4;} W5;
typedef W5 *W5Pt;
typedef W4 *W4Pt;
#define SOURCE(p, l) /* source p, l */
static void NoName←Q336();
static void X11TilingDemo←P0();
static void CreateDemoWidget←P60();
static word CreateTile←P120();
static struct {unsigned f; char r[16];} string1 = {917520, "\216\257\300\363\223\326\161\300\017\164\046\072\104\350\000"};
static struct {unsigned f; char r[4];} string2 = {65537, "\001\000\000"};
static struct {unsigned f; char r[48];} string3 = {2883632, "\260\006\005\146\151\162\163\164\216\257\300\033\115\307\000\300\214\060\055\310\100\244\005\004\162\145\163\164\214\216\257\300\033\115\307\000\300\214\060\055\310\100\244\261\000\000\000"};
static struct {unsigned f; char r[4];} string4 = {131074, "\004\003\000"};
static struct {unsigned f; char r[28];} string5 = {1638428, "Create tiling demo widget\000\000"};
static struct {unsigned f; char r[16];} string6 = {917520, "tiling monster\000"};
static struct {unsigned f; char r[8];} string7 = {262152, "w %g\000\000\000"};
static struct {unsigned f; char r[16];} string8 = {851984, "X11TilingDemo\000\000"};
static struct {unsigned f; char r[16];} string9 = {851984, "\257\300\325\240\074\116\300\251\147\026\231\100\164\000\000"};
static struct {unsigned f; char r[4];} string10 = {196611, "\004| "};
static struct {unsigned f; char r[16];} string11 = {851984, "\257\300\373\225\000\071\300\362\156\307\320\100\150\000\000"};
static struct {unsigned f; char r[16];} string12 = {851984, "\257\300\015\277\004\146\300\034\367\146\045\100\164\000\000"};
static struct {unsigned f; char r[16];} string13 = {851984, "\257\300\145\202\371\143\300\336\312\353\353\100\150\000\000"};
static struct {
   word f0[4]; word f4; word f5[9]; word f14; 
   word f15; word f16; word f17[2]; word f19; 
   word f20; word f21; word f22; word f23; 
   word f24; word f25[2]; word f27; word f28; 
   word f29; word f30; word f31; word f32; 
   word f33; word f34; word f35; word f36; 
   word f37; word f38; word f39[2]; word f41; 
   word f42; word f43[3]; word f46; word f47; 
   word f48; word f49; word f50; word f51; 
   word f52[5]; 
   } globalframe = {
   {0}, 8, {0}, (word) CreateDemoWidget←P60, 
   0, (word) X11TilingDemo←P0, {0}, 2147483648, 
   2147483648, 2147483648, 2147483648, 2147483648, 
   3, {0}, 2147483648, 2147483648, 
   2147483648, 2147483648, 2147483648, 0, 
   2147483648, 2147483648, 2147483648, 2147483648, 
   1, 3, {0}, 4294967295, 
   4294967295, {0}, 2147483648, 2147483648, 
   2147483648, 2147483648, 2147483648, 3, 
   {0}
   };

static void NoName←Q336()
   {
   register ptr gf←c041 =  (ptr) &globalframe;
   word var←c11316;
   (* (( (ptr) gf←c041)+8) ) = (word) XR←GetTypeIndex((word) &string1, 0, (word) &string2);
   (* (( (ptr) gf←c041)+9) ) = (word) XR←GetTypeIndex((word) &string3, 0, (word) &string4);
   (*  (ptr) (( (bPt) gf←c041)+40) ) = (word) XR←GetRefLiteral((* (( (ptr) gf←c041)+8) ), (word) &string5);
   (*  (ptr) (( (bPt) gf←c041)+44) ) = (word) XR←GetRefLiteral((* (( (ptr) gf←c041)+8) ), (word) &string6);
   (*  (ptr) (( (bPt) gf←c041)+48) ) = (word) XR←GetRefLiteral((* (( (ptr) gf←c041)+8) ), (word) &string7);
   (*  (ptr) (( (bPt) gf←c041)+52) ) = (word) XR←GetRefLiteral((* (( (ptr) gf←c041)+8) ), (word) &string8);
   (void) XR←DeclareGlobalFrame((word) "X11TilingDemo", &globalframe, (word) XR←GetTypeIndex((word) &string9, 0, (word) &string10)
      , (word) (( (bPt) gf←c041)+64)/* var←c10516 */ );
   var←c11316 = (word) XR←ImportInterface((word) "Commander", (word) XR←GetTypeIndexS((word) (&string11)), 3);
   (* (( (ptr) gf←c041)+54)/* var←c10868 */  ) = var←c11316;
   (void) XR←ImportProcS(var←c11316, 1310725);
   var←c11316 = (word) XR←ImportInterface((word) "IO", (word) XR←GetTypeIndexS((word) (&string12)), 103);
   (* (( (ptr) gf←c041)+56)/* var←c11092 */  ) = var←c11316;
   (void) XR←ImportProcS(var←c11316, 67910402);
   var←c11316 = (word) XR←ImportInterface((word) "XTkWidgets", (word) XR←GetTypeIndexS((word) (&string13)), 52);
   (* (( (ptr) gf←c041)+55)/* var←c10932 */  ) = var←c11316;
   (void) XR←ImportProcS(var←c11316, 69998595);
   (void) XR←ImportProcS(var←c11316, 69998851);
   (void) XR←ImportProcS(var←c11316, 70786819);
   (void) XR←ImportProcS(var←c11316, 2099460);
   (void) XR←ImportProcS(var←c11316, 526338);
   (void) XR←ImportProcS(var←c11316, 72352268);
   }

static void X11TilingDemo←P0(formal←c017, formal←c016)
   word formal←c017;
   word formal←c016;
   {
   register ptr gf←c11348 =  (ptr) &globalframe;
   /* X11TilingDemo: */ 
SOURCE(45, 891)
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
   /* moved to installation proc */ 
SOURCE(854, 82)
   {
      word pd14;
      pd14 = (* (( (ptr) (* (( (ptr) gf←c11348)+54)/* var←c10868 */  ))+4) );
      (void) ( *( (fPt) ((*  (ptr) pd14 ))))((* (( (ptr) gf←c11348)+13) ), (word) (( (bPt) gf←c11348)+56)/* var←c10484 */ , (* (
            ( (ptr) gf←c11348)+10) ), 0, 1, pd14);
      };
   }

static void CreateDemoWidget←P60(formal←c026, cmd←v3724)
   word formal←c026;
   word cmd←v3724;
   {
   W7 var←c11380;
   register ptr gf←c11412 =  (ptr) &globalframe;
   word result←v3768;
   word msg←v3796;
   /* declaration of var←c10900 skipped */ 
   /* declaration of idx←v2712 skipped */ 
   word top←v2768;
   word w←v2796;
   /* CreateDemoWidget: */ 
SOURCE(190, 658)
   {
      word tmpAddr15;
      tmpAddr15 = (word) (( (ptr) &var←c11380)+4)/* var←c10900 */ ;
      (*  (ptr) tmpAddr15 ) = ( ((word)  (fPt) CreateTile←P120) );
      (* (( (ptr) tmpAddr15) + 1) ) = 1;
      };
SOURCE(190, 658)
   result←v3768 = 0;
SOURCE(190, 658)
   msg←v3796 = 0;
SOURCE(234, 12)
   var←c11380.f6/* idx←v2712 */  = 0;
SOURCE(639, 108)
   {
      W20 var←c024;
      (*  (W9Pt) (word) &var←c024 ) = (*  (W9Pt) (( (ptr) gf←c11412)+18)/* var←c10580 */  );
      (* (( (ptr) (word) &var←c024) + 9) ) = 0;
      (* (( (ptr) (word) &var←c024) + 10) ) = (* (( (ptr) gf←c11412)+11) );
      (* (( (ptr) (word) &var←c024) + 11) ) = 0;
      (* (( (ptr) (word) &var←c024) + 12) ) = 0;
      (* (( (ptr) (word) &var←c024) + 13) ) = 0;
      (* (( (ptr) (word) &var←c024) + 14) ) = 0;
      (* (( (ptr) (word) &var←c024) + 15) ) = 0;
      (* (( (ptr) (word) &var←c024) + 16) ) = 0;
      (* (( (ptr) (word) &var←c024) + 17) ) = 1;
      (* (( (ptr) (word) &var←c024) + 18) ) = 1;
      (* (( (ptr) (word) &var←c024) + 19) ) = 1;
      {
         word pd16;
         pd16 = (* (( (ptr) (* (( (ptr) gf←c11412)+55)/* var←c10932 */  ))+6) );
         (* (( (ptr) gf←c11412)+5)/* forDebugging←v2636 */  ) = (word) ( *( (fPt) ((*  (ptr) pd16 ))))((word) (&var←c024), pd16);
         };
      };
   top←v2768 = (* (( (ptr) gf←c11412)+5)/* forDebugging←v2636 */  );
SOURCE(749, 35)
   w←v2796 = (word) CreateTile←P120((* (( (ptr) gf←c11412)+4)/* depth←v2608 */  ), 1, (word) (( (bPt) &var←c11380)+16)/* var←c10900 */ )
   ;
SOURCE(786, 32)
   {
      word pd17;
      pd17 = (* (( (ptr) (* (( (ptr) gf←c11412)+55)/* var←c10932 */  ))+12) );
      (void) ( *( (fPt) ((*  (ptr) pd17 ))))(top←v2768, w←v2796, pd17);
      };
SOURCE(820, 28)
   {
      word pd18;
      pd18 = (* (( (ptr) (* (( (ptr) gf←c11412)+55)/* var←c10932 */  ))+13) );
      (void) ( *( (fPt) ((*  (ptr) pd18 ))))(top←v2768, (*  (W5Pt) (( (ptr) gf←c11412)+27)/* var←c10644 */  ), 0, 1, pd18);
      };
   /* removed tail goto */ 
   (*  (ptr) formal←c026 ) = result←v3768;
   (* (( (ptr) formal←c026)+1) ) = msg←v3796;
   return;
   }

static word CreateTile←P120(i←v2872, h←v2900, formal←c11476)
   word i←v2872;
   word h←v2900;
   word formal←c11476;
   {
   register ptr gf←c11444 =  (ptr) &globalframe;
   word w←v2944;
   formal←c11476 = (formal←c11476 - 16);
   /* CreateTile: */ 
SOURCE(248, 383)
SOURCE(248, 383)
   w←v2944 = 0;
SOURCE(307, 324)
   if (( (int)i←v2872 <=  (int)0)) {
SOURCE(324, 116)
      {
         word var←c10964;
         {
            W2 var←c10996;
            {
               word v←v10436;
               (* (( (ptr) formal←c11476)+6) ) = ((* (( (ptr) formal←c11476)+6) ) + 1);
               v←v10436 = (* (( (ptr) formal←c11476)+6) );
               var←c10996.f0 = 5;
               var←c10996.f1 = v←v10436;
               };
            {
               word pd19;
               pd19 = (* (( (ptr) (* (( (ptr) gf←c11444)+56)/* var←c11092 */  ))+63) );
               var←c10964 = (word) ( *( (fPt) ((*  (ptr) pd19 ))))((* (( (ptr) gf←c11444)+12) ), var←c10996, pd19);
               };
            };
         {
            word pd20;
            pd20 = (* (( (ptr) (* (( (ptr) gf←c11444)+55)/* var←c10932 */  ))+35) );
            w←v2944 = (word) ( *( (fPt) ((*  (ptr) pd20 ))))((*  (W9Pt) (( (ptr) gf←c11444)+32)/* var←c10708 */  ), var←c10964, (*  (W4Pt) (
                  ( (ptr) gf←c11444)+41)/* var←c10772 */  ), pd20);
            };
         };
      }
   else {
SOURCE(449, 184)
      {
         word w1←v2972;
         word w2←v3000;
SOURCE(451, 32)
         w1←v2972 = (word) CreateTile←P120((i←v2872 - 1), (0 == h←v2900), (word) (( (bPt) formal←c11476)+16));
SOURCE(485, 32)
         w2←v3000 = (word) CreateTile←P120((i←v2872 - 1), (0 == h←v2900), (word) (( (bPt) formal←c11476)+16));
SOURCE(519, 112)
         if ((0 != h←v2900)) {
SOURCE(529, 54)
            {
               word var←c11124;
               {
                  word var←c11156;
                  word var←c11188;
                  var←c11156 = XR←NewObject(8, (* (( (ptr) gf←c11444)+9) ));
                  var←c11188 = var←c11156;
                  (*  (ptr) var←c11188 ) = w1←v2972;
                  (* (( (ptr) var←c11188)+1) ) = XR←NewObject(8, (* (( (ptr) gf←c11444)+9) ));
                  var←c11188 = (* (( (ptr) var←c11188)+1) );
                  (*  (ptr) var←c11188 ) = w2←v3000;
                  var←c11124 = var←c11156;
                  };
               {
                  word pd21;
                  pd21 = (* (( (ptr) (* (( (ptr) gf←c11444)+55)/* var←c10932 */  ))+29) );
                  w←v2944 = (word) ( *( (fPt) ((*  (ptr) pd21 ))))((*  (W9Pt) (( (ptr) gf←c11444)+45)/* var←c10836 */  ), var←c11124, 0, pd21)
                  ;
                  };
               };
            }
         else {
SOURCE(583, 48)
            {
               word var←c11220;
               {
                  word var←c11252;
                  word var←c11284;
                  var←c11252 = XR←NewObject(8, (* (( (ptr) gf←c11444)+9) ));
                  var←c11284 = var←c11252;
                  (*  (ptr) var←c11284 ) = w1←v2972;
                  (* (( (ptr) var←c11284)+1) ) = XR←NewObject(8, (* (( (ptr) gf←c11444)+9) ));
                  var←c11284 = (* (( (ptr) var←c11284)+1) );
                  (*  (ptr) var←c11284 ) = w2←v3000;
                  var←c11220 = var←c11252;
                  };
               {
                  word pd22;
                  pd22 = (* (( (ptr) (* (( (ptr) gf←c11444)+55)/* var←c10932 */  ))+28) );
                  w←v2944 = (word) ( *( (fPt) ((*  (ptr) pd22 ))))((*  (W9Pt) (( (ptr) gf←c11444)+45)/* var←c10836 */  ), var←c11220, 0, pd22)
                  ;
                  };
               };
            };
         };
      };
SOURCE(248, 383)
   return(w←v2944);
   }

/* file: X11TilingDemo, module: X11TilingDemo, compiled at: April 21, 1992 12:48:23 pm PDT */ 
extern void XR←install←X11TilingDemo() {
   NoName←Q336();
   }
extern void XR←run←X11TilingDemo() { XR←Start(&globalframe); }