swarm-support
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

window error


From: Doug Donalson
Subject: window error
Date: Tue, 24 Mar 1998 02:36:24 -0800

I have tracked down the error to the line of code that sets the X,Y
coordinates of the ZoomRaster.  With all the 2-D displays commented
out my sim runs (with the EZ graphs).  I added one ZoomRaster both with
the standard call "world getXsize" and also with X and Y hard coded
at (int) 11.  In both cases it comes up with the error.  When I comment
the line out, the display appears but is empty.  Here are the included
.h files followed by the code:

in Observer.h

#import <simtoolsgui.h>
#import <simtoolsgui/GUISwarm.h>
#import <analysis.h> // EZGraph
#import "AphytisModelSwarm.h"

id <ZoomRaster> adultAphytisRaster;     // 2d display widget

in Observer.m

#import "AphytisObserverSwarm.h"
#import "AphytisModelSwarm.h"
#import <collections.h>
#import <objectbase.h>
#import <analysis.h>
#import <gui.h>

adultAphytisRaster = [ZoomRaster createBegin: [self getZone]];
  SET_WINDOW_GEOMETRY_RECORD_NAME (adultAphytisRaster);
  adultAphytisRaster = [adultAphytisRaster createEnd];
  [adultAphytisRaster enableDestroyNotification: self
               notificationMethod: @selector
(_adultAphytisRasterDeath_:)];
  [adultAphytisRaster setColormap: colormap];
  [adultAphytisRaster setZoomFactor: 4];
  printf("aaa %d %d \n",[[aphytisModelSwarm getWorld] getSizeX]
,[[aphytisModelSwarm getWorld] getSizeY]);
  getchar();
 // [adultAphytisRaster setWidth: [[aphytisModelSwarm getWorld]
getSizeX] Height: [[aphytisModelSwarm getWorld] getSizeY]];
[adultAphytisRaster setWidth: (int) 11 Height: (int) 11];

  [adultAphytisRaster setWindowTitle: "Adult Aphytis World"];
  [adultAphytisRaster pack];      // draw the window.

Interestingly, the window title prints successfully, otherwise I
would have suspected a missing basic definition of ZoomRaster.
I have scanned through a lot of the new GUI code and have not found
the def for zoom raster, but I'll bet this is enough for Marcus to tell
me what I have done wrong.

Cheers,

   Doug

PS  Damn I hate to stop when I am soooooo close to getting it all up
and running.  The displays (EZ Graph and Probe) look really nice!
As usuall, you guys have done a great job!


                  ==================================
   Swarm-Support is for discussion of the technical details of the day
   to day usage of Swarm.  For list administration needs (esp.
   [un]subscribing), please send a message to <address@hidden>
   with "help" in the body of the message.
                  ==================================


reply via email to

[Prev in Thread] Current Thread [Next in Thread]