display.rc
changeset 200 3ec17ba8ef56
parent 195 1cf850844da9
child 205 9f394a370719
--- a/display.rc	Fri Jan 31 11:34:50 1997 +0100
+++ b/display.rc	Sat Feb 01 19:58:34 1997 +0100
@@ -47,19 +47,17 @@
 formats := Image fileFormats.
 rdr := Smalltalk at:#XBMReader ifAbsent:nil.
 rdr notNil ifTrue:[
-    formats at:'.xbm'  put:rdr.
-    formats at:'.bm'   put:rdr.
+    Image addReader:rdr suffix:'xbm'.
+    Image addReader:rdr suffix:'bm'.
 ].
 rdr := Smalltalk at:#TIFFReader ifAbsent:nil.
 rdr notNil ifTrue:[
-    formats at:'.tiff' put:rdr.
-    formats at:'.tif'  put:rdr.
-    formats at:'.TIF'  put:rdr.
+    Image addReader:rdr suffix:'tif'.
+    Image addReader:rdr suffix:'tiff'.
 ].
 rdr := Smalltalk at:#GIFReader ifAbsent:nil.
 rdr notNil ifTrue:[
-    formats at:'.gif'  put:rdr.
-    formats at:'.GIF'  put:rdr.
+    Image addReader:rdr suffix:'gif'.
 ].
 
 "/ still to come ...
@@ -69,8 +67,8 @@
 
 rdr := Smalltalk at:#SunRasterReader ifAbsent:nil.
 rdr notNil ifTrue:[
-    formats at:'.im8'  put:rdr.
-    formats at:'.icon' put:rdr.
+    Image addReader:rdr suffix:'im8'.
+    Image addReader:rdr suffix:'icon'.
 ].
 
 "/ still to come ...
@@ -78,62 +76,57 @@
 
 rdr := Smalltalk at:#WindowsIconReader ifAbsent:nil.
 rdr notNil ifTrue:[
-    formats at:'.bmp'  put:rdr.
-    formats at:'.ico'  put:rdr.
-    formats at:'.BMP'  put:rdr.
-    formats at:'.ICO'  put:rdr.
+    Image addReader:rdr suffix:'bmp'.
+    Image addReader:rdr suffix:'ico'.
 ].
 
 rdr := Smalltalk at:#JPEGReader ifAbsent:nil.
 rdr notNil ifTrue:[
-    formats at:'.JPG'  put:rdr.
-    formats at:'.jpg'  put:rdr.
-    formats at:'.jpeg' put:rdr.
+    Image addReader:rdr suffix:'jpg'.
+    Image addReader:rdr suffix:'jpeg'.
 ].
 
 rdr := Smalltalk at:#PBMReader ifAbsent:nil.
 rdr notNil ifTrue:[
-    formats at:'.ppm'  put:rdr.
-    formats at:'.pbm'  put:rdr.
-    formats at:'.pgm'  put:rdr.
+    Image addReader:rdr suffix:'ppm'.
+    Image addReader:rdr suffix:'pbm'.
+    Image addReader:rdr suffix:'pgm'.
 ].
 
 rdr := Smalltalk at:#ST80FormReader ifAbsent:nil.
 rdr notNil ifTrue:[
-    formats at:'.form' put:rdr.
+    Image addReader:rdr suffix:'form'.
 ].
 
 rdr := Smalltalk at:#FaceReader ifAbsent:nil.
 rdr notNil ifTrue:[
-    formats at:'.face' put:rdr.
+    Image addReader:rdr suffix:'face'.
 ].
 
 rdr := Smalltalk at:#XPMReader ifAbsent:nil.
 rdr notNil ifTrue:[
-    formats at:'.pm'   put:rdr.
-    formats at:'.xpm'  put:rdr.
+    Image addReader:rdr suffix:'xpm'.
+    Image addReader:rdr suffix:'pm'.
 ].
 
 rdr := Smalltalk at:#PCXReader ifAbsent:nil.
 rdr notNil ifTrue:[
-    formats at:'.pcx'  put:rdr.
-    formats at:'.PCX'  put:rdr.
+    Image addReader:rdr suffix:'pcx'.
 ].
 
 rdr := Smalltalk at:#TargaReader ifAbsent:nil.
 rdr notNil ifTrue:[
-    formats at:'.tga'  put:rdr.
-    formats at:'.TGA'  put:rdr.
+    Image addReader:rdr suffix:'tga'.
 ].
 
 rdr := Smalltalk at:#XWDReader ifAbsent:nil.
 rdr notNil ifTrue:[
-    formats at:'.xwd'  put:rdr.
+    Image addReader:rdr suffix:'xwd'.
 ].
 
 rdr := Smalltalk at:#BlitImageReader ifAbsent:nil.
 rdr notNil ifTrue:[
-    formats at:'48x48x1'  put:rdr.
+    Image addReader:rdr suffix:'48x48x1'.
 ]
 !