initial checkin
authorcg
Thu, 29 Jan 1998 14:44:16 +0000
changeset 287 73065896fbb4
parent 286 da220fe69de3
child 288 d71bacb73ff7
initial checkin
JavaAppletComponentSpec.st
UIGalleryJavaEntry.st
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/JavaAppletComponentSpec.st	Thu Jan 29 14:44:16 1998 +0000
@@ -0,0 +1,312 @@
+ArbitraryComponentSpec subclass:#JavaAppletComponentSpec
+	instanceVariableNames:'codeURL codeBaseURL documentURL archiveURL parameterDictionary
+		level'
+	classVariableNames:''
+	poolDictionaries:''
+	category:'Java-Views-Support'
+!
+
+
+!JavaAppletComponentSpec class methodsFor:'interface specs'!
+
+addBindingsTo:env for:inst channel:aChannel 
+
+    super addBindingsTo:env for:inst channel:aChannel.
+
+    self 
+        adaptApects:
+                    #(  
+                        hasBorder
+                     )
+        to:env 
+        for:inst 
+        channel:aChannel.
+
+    self 
+        adaptApects:#(
+                        component
+                     )
+        to:env 
+        for:inst 
+        channel:aChannel
+        converter:#symbolOrNil
+
+    "Modified: / 26.10.1997 / 03:21:32 / cg"
+    "Created: / 29.1.1998 / 14:17:39 / cg"
+!
+
+basicsEditSpec
+    "this window spec was automatically generated by the ST/X UIPainter"
+
+    "do not manually edit this - the painter/builder may not be able to
+     handle the specification if its corrupted."
+
+    "
+     UIPainter new openOnClass:JavaAppletComponentSpec andSelector:#basicsEditSpec
+     JavaAppletComponentSpec new openInterface:#basicsEditSpec
+    "
+
+    <resource: #canvas>
+
+    ^
+     
+       #(#FullSpec
+          #'window:' 
+           #(#WindowSpec
+              #'name:' 'ArbitraryComponent Basic'
+              #'layout:' #(#LayoutFrame 68 0 70 0 374 0 360 0)
+              #'label:' 'ArbitraryComponent Basic'
+              #'min:' #(#Point 10 10)
+              #'max:' #(#Point 1280 1024)
+              #'bounds:' #(#Rectangle 68 70 375 361)
+              #'usePreferredExtent:' false
+          )
+          #'component:' 
+           #(#SpecCollection
+              #'collection:' 
+               #(
+                 #(#LabelSpec
+                    #'name:' 'idLabel'
+                    #'layout:' #(#AlignmentOrigin 72 0 30 0 1 0.5)
+                    #'label:' 'ID:'
+                    #'resizeForLabel:' true
+                )
+                 #(#InputFieldSpec
+                    #'name:' 'idField'
+                    #'layout:' #(#LayoutFrame 75 0 20 0 -2 1 45 0)
+                    #'activeHelpKey:' #id
+                    #'model:' #name
+                )
+                 #(#LabelSpec
+                    #'name:' 'codeURLLabel'
+                    #'layout:' #(#AlignmentOrigin 85 0 106 0 1 0.5)
+                    #'label:' 'Code:'
+                    #'resizeForLabel:' true
+                )
+                 #(#InputFieldSpec
+                    #'name:' 'viewField'
+                    #'layout:' #(#LayoutFrame 87 0 95 0 -2 1 120 0)
+                    #'activeHelpKey:' #arbitraryView
+                    #'model:' #component
+                )
+                 #(#LabelSpec
+                    #'name:' 'codeBaseLabel'
+                    #'layout:' #(#AlignmentOrigin 85 0 135 0 1 0.5)
+                    #'label:' 'CodeBase:'
+                    #'adjust:' #right
+                    #'resizeForLabel:' true
+                )
+                 #(#InputFieldSpec
+                    #'name:' 'modelField'
+                    #'layout:' #(#LayoutFrame 87 0 124 0 -2 1.0 149 0)
+                    #'activeHelpKey:' #selectionHolder
+                    #'model:' #model
+                )
+                 #(#LabelSpec
+                    #'name:' 'archiveLabel'
+                    #'layout:' #(#AlignmentOrigin 85 0 164 0 1 0.5)
+                    #'label:' 'Archive:'
+                    #'adjust:' #right
+                    #'resizeForLabel:' true
+                )
+                 #(#InputFieldSpec
+                    #'name:' 'inputField1'
+                    #'layout:' #(#LayoutFrame 87 0 153 0 -2 1.0 178 0)
+                    #'activeHelpKey:' #selectionHolder
+                    #'model:' #model
+                )
+                 #(#LabelSpec
+                    #'name:' 'label1'
+                    #'layout:' #(#LayoutFrame 2 0 67 0 198 0 89 0)
+                    #'label:' 'URLS:'
+                    #'adjust:' #left
+                )
+              )
+          )
+      )
+
+    "Modified: / 29.1.1998 / 14:33:27 / cg"
+!
+
+detailsEditSpec
+    "this window spec was automatically generated by the ST/X UIPainter"
+
+    "do not manually edit this - the painter/builder may not be able to
+     handle the specification if its corrupted."
+
+    "
+     UIPainter new openOnClass:JavaAppletComponentSpec andSelector:#detailsEditSpec
+     JavaAppletComponentSpec new openInterface:#detailsEditSpec
+    "
+
+    <resource: #canvas>
+
+    ^
+
+       #(#FullSpec
+          #'window:' 
+           #(#WindowSpec
+              #'name:' 'ArbitraryComponent Detail'
+              #'layout:' #(#LayoutFrame 197 0 172 0 472 0 444 0)
+              #'label:' 'ArbitraryComponent Detail'
+              #'min:' #(#Point 10 10)
+              #'max:' #(#Point 1160 870)
+              #'bounds:' #(#Rectangle 197 172 473 445)
+          )
+          #'component:' 
+           #(#SpecCollection
+              #'collection:' 
+               #(
+                 #(#CheckBoxSpec
+                    #'name:' 'hasBorder'
+                    #'layout:' #(#LayoutOrigin 20 0 50 0)
+                    #'tabable:' true
+                    #'model:' #hasBorder
+                    #'activeHelpKey:' #hasBorder
+                    #'label:' 'Bordered'
+                )
+                 #(#UISubSpecification
+                    #'name:' 'detailsInitSubSpec'
+                    #'layout:' #(#LayoutFrame 0 0.0 182 0 0 1.0 264 0)
+                    #'minorKey:' #detailsInitSubSpec
+                )
+              )
+          )
+      )
+
+    "Created: / 29.1.1998 / 14:17:29 / cg"
+    "Modified: / 29.1.1998 / 14:28:46 / cg"
+!
+
+icon
+    "ImageEditor openOnClass:self andSelector:#icon"
+
+    <resource: #image>
+    ^(Depth4Image new) width: 18; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(#[0 0 0 0 0 0 0 0 0 1 17 17 17 17 17 17 17 48 1 0 0 0 0 0 0 0 32 1 2 34 34 34 34 34 48 32 1 2 51 51 51 51 51 16 32 1 2 48 0 0 0 3 16 32 1 2 48 34 34 35 3 16 32 1 2 48 40 136 129 3 16 32 1 2 48 40 136 129 3 16 32 1 2 48 49 17 17 3 16 32 1 2 48 0 0 0 3 16 32 1 2 51 51 51 51 51 16 32 1 3 17 17 17 17 17 16 32 1 0 0 0 0 0 0 0 32 3 34 34 34 34 34 34 34 32 0 0 0 0 0 0 0 0 0]) ; colorMap:((OrderedCollection new add:(Color black); add:(Color white); add:(Color grey:49.9962); add:(Color grey:66.9978); add:(Color red:100.0 green:0.0 blue:0.0); add:(Color red:0.0 green:100.0 blue:0.0); add:(Color red:0.0 green:0.0 blue:100.0); add:(Color red:0.0 green:100.0 blue:100.0); add:(Color red:100.0 green:100.0 blue:0.0); add:(Color red:100.0 green:0.0 blue:100.0); add:(Color red:49.9992 green:0.0 blue:0.0); add:(Color red:0.0 green:49.9992 blue:0.0); add:(Color red:0.0 green:0.0 blue:49.9992); add:(Color red:0.0 green:49.9992 blue:49.9992); add:(Color red:49.9992 green:49.9992 blue:0.0); add:(Color red:49.9992 green:0.0 blue:49.9992); yourself)); mask:((Depth1Image new) width: 18; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(#[127 255 128 255 255 192 255 255 192 255 255 192 255 255 192 255 255 192 255 255 192 255 255 192 255 255 192 255 255 192 255 255 192 255 255 192 255 255 192 255 255 192 255 255 192 127 255 128]) ; yourself); yourself
+
+    "Created: / 29.1.1998 / 14:17:49 / cg"
+!
+
+slices
+    ^#(
+            (Basics  basicsEditSpec)
+            (Details detailsEditSpec) 
+      )
+
+    "Created: / 29.1.1998 / 14:17:34 / cg"
+! !
+
+!JavaAppletComponentSpec methodsFor:'accessing'!
+
+archiveURL
+    "return the value of the instance variable 'archiveURL' (automatically generated)"
+
+    ^ archiveURL
+
+    "Created: / 29.1.1998 / 14:15:47 / cg"
+!
+
+archiveURL:something
+    "set the value of the instance variable 'archiveURL' (automatically generated)"
+
+    archiveURL := something.
+
+    "Created: / 29.1.1998 / 14:15:47 / cg"
+!
+
+codeBaseURL
+    "return the value of the instance variable 'codeBaseURL' (automatically generated)"
+
+    ^ codeBaseURL
+
+    "Created: / 29.1.1998 / 14:15:43 / cg"
+!
+
+codeBaseURL:something
+    "set the value of the instance variable 'codeBaseURL' (automatically generated)"
+
+    codeBaseURL := something.
+
+    "Created: / 29.1.1998 / 14:15:43 / cg"
+!
+
+codeURL
+    "return the value of the instance variable 'codeURL' (automatically generated)"
+
+    ^ codeURL
+
+    "Created: / 29.1.1998 / 14:15:41 / cg"
+!
+
+codeURL:something
+    "set the value of the instance variable 'codeURL' (automatically generated)"
+
+    codeURL := something.
+
+    "Created: / 29.1.1998 / 14:15:41 / cg"
+!
+
+documentURL
+    "return the value of the instance variable 'documentURL' (automatically generated)"
+
+    ^ documentURL
+
+    "Created: / 29.1.1998 / 14:15:45 / cg"
+!
+
+documentURL:something
+    "set the value of the instance variable 'documentURL' (automatically generated)"
+
+    documentURL := something.
+
+    "Created: / 29.1.1998 / 14:15:45 / cg"
+!
+
+parameterDictionary
+    "return the value of the instance variable 'parameterDictionary' (automatically generated)"
+
+    ^ parameterDictionary
+
+    "Created: / 29.1.1998 / 14:15:48 / cg"
+!
+
+parameterDictionary:something
+    "set the value of the instance variable 'parameterDictionary' (automatically generated)"
+
+    parameterDictionary := something.
+
+    "Created: / 29.1.1998 / 14:15:49 / cg"
+! !
+
+!JavaAppletComponentSpec methodsFor:'building'!
+
+setAttributesIn:anAppletView with:aBuilder
+    super setAttributesIn:anAppletView with:aBuilder.
+
+    codeURL notNil ifTrue:[
+        anAppletView codeURL:codeURL
+    ].    
+    codeBaseURL notNil ifTrue:[
+        anAppletView codeBaseURL:codeBaseURL
+    ].    
+    documentURL notNil ifTrue:[
+        anAppletView documentURL:documentURL
+    ].    
+    archiveURL notNil ifTrue:[
+        anAppletView archiveURL:archiveURL
+    ].
+
+    "Created: / 29.1.1998 / 15:17:38 / cg"
+!
+
+viewClass
+    ^ JavaEmbeddedFrameView
+
+    "Modified: / 29.1.1998 / 15:07:00 / cg"
+! !
+
+!JavaAppletComponentSpec class methodsFor:'documentation'!
+
+version
+    ^ '$Header: /home/jv/Projects/SmalltalkX/repositories/cvs/stx/libjava/JavaAppletComponentSpec.st,v 1.1 1998/01/29 14:43:54 cg Exp $'
+! !
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/UIGalleryJavaEntry.st	Thu Jan 29 14:44:16 1998 +0000
@@ -0,0 +1,105 @@
+Object subclass:#UIGalleryJavaEntry
+	instanceVariableNames:''
+	classVariableNames:''
+	poolDictionaries:''
+	category:'Java-Views-Support'
+!
+
+!UIGalleryJavaEntry class methodsFor:'documentation'!
+
+documentation
+"
+    this class provides a UIGallery entry for the new Java applet
+    components. When loaded, it installs itself automatically in
+    the user-defined section (see the class-initialize-method).
+
+    [author:]
+        Claus Gittinger
+"
+
+! !
+
+!UIGalleryJavaEntry class methodsFor:'class initialization'!
+
+initialize
+    "add an entry for my new components to the UIPainters 
+     userDef gallery"
+
+    UISelectionPanel userClass
+        addUserSpecHolder:[self javaComponentsSpec]
+        label:'Java'
+
+    "
+     self initialize
+    "
+
+    "Created: / 29.1.1998 / 14:22:02 / cg"
+    "Modified: / 29.1.1998 / 14:40:06 / cg"
+!
+
+removeFromSystem
+    "remove myself - this implies deinstallation from the UIGallery"
+
+    UISelectionPanel userClass removeUserSpecWithLabel:'Java'.
+    ^ super removeFromSystem.
+
+    "Modified: / 5.12.1997 / 15:13:09 / cg"
+    "Created: / 29.1.1998 / 14:21:54 / cg"
+! !
+
+!UIGalleryJavaEntry class methodsFor:'uigallery specs'!
+
+javaComponentsSpec
+    "this window spec was automatically generated by the ST/X UIPainter"
+
+    "do not manually edit this - the painter/builder may not be able to
+     handle the specification if its corrupted."
+
+    "
+     UIPainter new openOnClass:UIGalleryJavaEntry andSelector:#javaComponentsSpec
+     UIGalleryJavaEntry new openInterface:#javaComponentsSpec
+    "
+
+    <resource: #canvas>
+
+    ^
+     
+       #(#FullSpec
+          #'window:' 
+           #(#WindowSpec
+              #'name:' 'Java Applet Components'
+              #'layout:' #(#LayoutFrame 216 0 173 0 523 0 387 0)
+              #'label:' 'Java Applet Components'
+              #'min:' #(#Point 10 10)
+              #'max:' #(#Point 1024 768)
+              #'bounds:' #(#Rectangle 216 173 524 388)
+              #'usePreferredExtent:' false
+          )
+          #'component:' 
+           #(#SpecCollection
+              #'collection:' 
+               #(
+                 #(#JavaAppletComponentSpec
+                    #'name:' 'applet'
+                    #'layout:' #(#LayoutFrame 10 0 18 0 160 0 160 0)
+                    #'level:' -1
+                )
+                 #(#LabelSpec
+                    #'name:' 'label1'
+                    #'layout:' #(#LayoutFrame 11 0 168 0 162 0 190 0)
+                    #'label:' 'Applet'
+                    #'canUIDrag:' false
+                )
+              )
+          )
+      )
+
+    "Modified: / 29.1.1998 / 14:42:39 / cg"
+! !
+
+!UIGalleryJavaEntry class methodsFor:'documentation'!
+
+version
+    ^ '$Header: /home/jv/Projects/SmalltalkX/repositories/cvs/stx/libjava/UIGalleryJavaEntry.st,v 1.1 1998/01/29 14:44:16 cg Exp $'
+! !
+UIGalleryJavaEntry initialize!