User Map - [was Re: link of the day]

Lic. Edgar J. De Cleene edgardec2001 at yahoo.com.ar
Fri Jul 25 12:53:55 UTC 2003


On 24/07/03 16:16, "Gary Fisher" <gafisher at sprynet.com> wrote:

> http://www.chrisburkert.de/index.php?node_id=50 comes pretty close.
> 
> Gary
> 
> 
> ----- Original Message -----
> From: "Simon Michael" <simon at joyful.com>
> To: <squeak-dev at lists.squeakfoundation.org>
> Sent: Thursday, July 24, 2003 12:44 PM
> Subject: link of the day
> 
> 
>> The World as Blog - http://www.brainoff.com/geoblog/ (flash)
>> 
>> I think we need a squeak version. :)
>> 
>> 
I have the following to share with whose like this.
I take data of site and edit for work.
I can't share the map or morph by size restrictions of this list.

Enjoy or hate. 
Edgar

edgar

-------------- next part --------------
ImageMorph subclass: #SqueakersLocations
	instanceVariableNames: 'ceroLat ceroLong externalData '
	classVariableNames: ''
	poolDictionaries: ''
	category: 'FellowshipOfSqueak'!

!SqueakersLocations methodsFor: 'initialization' stamp: 'edc 7/25/2003 06:40'!
initialize
	super initialize.
	self
		image: (Form fromFileNamed: 'SqueakAroundTheWorld.gif').
	self openInWorld.
self readExternal! !

!SqueakersLocations methodsFor: 'initialization' stamp: 'edc 7/25/2003 09:40'!
readExternal
	| inputStream newLine parseLine latitud longitud y x e t signo |
	inputStream _ FileStream fileNamed: 'squeakAroundTheWorld.txt'.
	[inputStream atEnd]
		whileFalse: [
newLine _ inputStream nextLine.
	
	parseLine _ newLine findTokens: ' '.
	ceroLat _ self height / 2.
	ceroLong _ self width / 2.
	latitud _ parseLine first asInteger.
	longitud _ parseLine second asInteger.
t _ ' '.
3 to: 
(parseLine size) do: [ :index | t _ t ,(parseLine at: index) ,  ' '].
	y _ ceroLat / 90 * latitud.
signo _ ((parseLine first) at: 1) .
signo = $- ifFalse: [y _ceroLat -y]
ifTrue:[y _ceroLat +y].
	x _ ceroLong / 180 * longitud.
signo _ ((parseLine second) at: 1) .
signo = $- ifTrue: [x _ ceroLong - x]
ifFalse:[x _ ceroLong + x ].

	e _ EllipseMorph new.
e extent: 7 @ 7; center: x @ y.
e setBalloonText: t.
	e openInWorld.
self halt
].

inputStream close! !
-------------- next part --------------
 39.04.56       -94.35.20       Kansas City                 
 39.36          -120.18         Truckee                     
 47.6           -122.32         Seattle                     
 45.60          -122.60         Portland                    
 32.71          -117.12         San Diego                   
 33.05          -118.23         Los Angeles                 
 37.75          -122.68         San Francisco               
 33.43          -112.02         Phoenix                     
 40.02.06       -105.14.35      Boulder                     
 39.75          -104.87         Denver                      
 29.97          -95.35          Houston                     
 30.30          -97.70          Austin                      
 33.30.40       -96.23.41       Whitewright                 
 41.90          -87.65          Chicago                     
 40.6           -89.5           Morton                      
 40.03          -88.28          Champaign/Urbana            
 38.05          -85.00          Lexington                   
 36.97          -86.43          Bowling Gren                
 42.08.40       -83.68.34       Milan                       
 42.42          -83.02          Detroit                     
 42.58.20       -85.55.27       Pearline                    
 44.53          -93.13          Minneapolis & Saint Paul    
 46.83          -92.18          Duluth                      
 39.10          -84.43          Cincinnati                  
 41.52          -81.68          Cleveland                   
 40.07.16       -82.55.03       Westerville                 
 38.52.43       -77.06.07       Arlington                   
 38.95          -77.46          Washington DC               
 35.58.50       -78.54.54       Durham                      
 32.1           -89.5           Raleigh                     
 33.34.06       -83.21.49       Buckhead                    
 42.29.26       -71.16.36                                   
 40.40.11       -73.56.38       New York City               
 33.57          -86.75          Birmingham                  
 33.65          -84.42          Atlanta                     
 33.6           -83.5           Madison                     
 49.22          -123.10         Vancouver                   
 45.05          -64.22          Wolfville                   
 45.41          -75.71          Ottawa                      
 43.27          -80.29          Waterloo                    
 43.40          -79.22          Toronto                     
 48.37          -123.24         Victoria
 45.30          -73.34.48       Montreal                    
 43             -81.15          London
 53.30          -113.30         Edmonton                    
 -34.35         -58.29          Buenos Aires
 -35            -61             Los Toldos                  
 -34.55.53      -57.56.56       La Plata
 -31.37.60      -60.42.00       Santa Fe
 -32.57.04      -60.39.59       Rosario
 -27.35         -48.34          Florianopolis               
 -15.78         -47.95          Brasilia
 -25.25         -49.17          Curitiba                    
 -22.02         -47.55          Sao Carlos                  
 48.20          16.36           Vienna                      
 50.10          14.43           Prague
 48.87          2.33            Paris                       
 48.48          2.08            Versailles                  
 43.42          7.21            Nice                        
 52.31          13.20           Berlin                      
 50.50          12.55           Chemnitz                    
 52.07          11.38           Magdeburg                   
 50.46          6.06            Aachen                      
 50.75          7.07            Bonn                        
 51.30          7.29            Dortmund                    
 51.43          7               Essen                       
 50.93          6.95            Kšln                        
 51.6           6.6             Wesel                       
 48.08          11.54           MŸnchen                     
 50.58.30       10.57.29        Gotha                       
 50.41          10.55           Ilmenau                     
 49.14          6.59            SaarbrŸcken                 
 49.52          7.51            Bad Kreuznach               
 49             8.22            Karlsruhe                   
 47.39          9.10            Konstanz                    
 48.49          9.08            Stuttgart                   
 54.19          10.08           Kiel                        
 53.43          10              Norderstedt                 
 53.33          -6.25           Dublin
 54.57          -7.44           Letterkenny                 
 52.48          -8.27           Killaloe                    
 45.27          9.10            Milan                       
 54.54          23.54           Kaunas                      
 51.55          4.29            Rotterdam                   
 53.24          6.37            Usquert                     
 52             6               Eerbeek                     
 52.07          4.58            Utrecht                     
 48.7           21.27           Kosice                      
 48.2           17.2            Bratislava                  
 40.42          -3.72           Madrid                      
 59.33          18.08           Stockholm                   
 59.55          17.38           Uppsala                     
 46.2           6.2             Geneve                      
 46.95          7.43            Bern                        
 47.21          8.31            Zuerich                     
 51.33.18       -0.13.48        London                      
 53.48          -2.23           Manchester                  
 50.83          -0.14           Brighton                    
 52.63          -1.13           Leicester                   
 52.03.33       -0.7            Milton Keynes               
 57.12.25       -2.12.32        Aberdeen                    
 48             37.00.48        Donetsk
 35.75          139.50          Tokyo                       
 35.61          140.11          Chiba                       
 34.68          135.50          Osaka                       
 43.06          141.34          Sapporo                     
 37.53          127.00          Seoul                       
32.01.01       34.52.59        Tel Aviv                    
 1.28           103.85          Singapore
 -35.30         149.13          Canberra                    
 -33.92         151.17          Sydney                      
 -37.75         144.97          Melbourne                   
 -27.21         153.10          Brisbane                    
 -41.25         147.07          Launceston                  
 -34            19              Cape Town                   
 -43.32         172.38          Christchurch                


More information about the Squeak-dev mailing list