[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
mousetrap; tee; globalTkInterp eval: naive-use
From: |
Rick Riolo |
Subject: |
mousetrap; tee; globalTkInterp eval: naive-use |
Date: |
Wed, 25 Oct 1995 17:06:22 -0400 (EDT) |
I have the most of the swarm apps working ok now, and even have
a very simple model of my own going.
Two that were problems before seem to be working:
heatbugs gives me red diffusion, and unhappiness falls.
(I wrote my own rint and linked it in.)
markets graphs are ok now, too: they start out a little
narrow, but if I expand the wframes, the graphs become
perfectly readable.
bondblocks, turmites, axelcult work.
mousetrap still doesn't do anything when I hit go
(except it does become top's top cycle burner, so its
doing something...)
I see the red and black display and two graphs which
run (x) from -10 to 10. but the red/black pattern
doesn't change and nothing get's drawn on the graphs.
(I've waited about 5 mionutes or so.)
What should I be see happening?
----------
One other thing I noticed:
I tried to tee some output from my model to a file,
and it didn't work (i'm just printf-ing to stdout).
the output printf's to screen I start in just fine.
I then tried this for axelcult (it prints a dump
of its agents right at the start, then prints T
every 1000 cycles or so). if I tee it the output
doesn't print on screen or file, either.
Anyone know what's going on?
------------
I also wanted to change the background of my Grid2d/ZoomRaster
display to white (its black by default).
I (naively I'm sure) thought I'd try this:
worldDisplay = [ZoomRaster create: mZone];
[worldDisplay setColormap: colormap];
[worldDisplay setZoomFactor: 8];
[worldDisplay setWidth: WorldXSize Height: WorldYSize];
[worldDisplay pack]; // draw the window
zoomRasterWidgetName = [worldDisplay getWidgetName];
printf( "\n# zoomRasterWidgetName '%s'\n", zoomRasterWidgetName );
[globalTkInterp eval: "%s configure -bg white", zoomRasterWidgetName ];
// next two just for fun...
[globalTkInterp eval: "button .b -text hi -command exit -bg green" ];
[globalTkInterp eval: "pack .b" ];
I got the widget name, and hoped I could just tell the Tkinterp
to change the bg. I get the widget name, but the bkground doesn't change.
I then tried the two last lines you see above just to see what would
happen (this is all in my main.m, in a place analogous to similar codes
in heatbugs, say.) by little green Hi button doesn't appear.
Can anyone tell me why what I am trying is silly?
thanks for ideas/solutions/suggestions.
- r
Rick Riolo address@hidden
Program for Study of Complex Systems (PSCS)
1061 Randall Lab University of Michigan
Ann Arbor MI 48109-1120
http://pscs.physics.lsa.umich.edu/rlr-home.html
- mousetrap; tee; globalTkInterp eval: naive-use,
Rick Riolo <=