demos\medical\application.sdf
  1 Application {
  2   name: "Medical Demo"
  3   /**
  4    * Customize some environment-wide UI properties that will be set into the UIManager.
  5    * Using an inline URL in-lieu of and external file
  6    */
  7   lookAndFeelPropertiesURL:<<
  8     defaultBackground=ColorShade|#DCE0DC [os="windows]
  9     defaultBackground=ColorShade|#E8E8E8 [os="os x,linux"]
 10     Sage.control=Color|defaultBackground
 11 
 12     TitledBorder.titleColor=Color|#404040
 13     TitledBorder.font=Font|{style: bold}
 14     abnormal=Color|#800000
 15 
 16     rowHilite=Color|defaultBackground+10 [os="windows]
 17     rowHilite=Color|defaultBackground+6 [os="os x,linux"]
 18     infobarColor=Color|defaultBackground+10,defaultBackground-10 [os="linux,windows"]
 19     infobarColor=Color|#bcbcbc,#cccccc [os="os x"]
 20 
 21     >> [ inline="true" ]
 22 
 23   /**
 24    * Define some application level icons that can
 25    * be accessed via window.getIcon(iconName). The 'lib' URL
 26    * identifies the icons as residing is some jar in the class path
 27    */
 28   resourceIconsURL:<<
 29     icon_female=lib:images/female.png
 30     icon_male=lib:images/male.png
 31     icon_note_write=lib:images/note-write.png
 32     icon_note_edit=lib:images/note-edit.png
 33     icon_bookmark=lib:images/bookmark.png
 34     icon_index=lib:images/index.png
 35     icon_calendar_day=lib:images/calendar_day.png
 36     icon_calendar_week=lib:images/calendar_week.png
 37     icon_history=lib:images/history.png
 38     icon_patients=lib:images/patients.png
 39     icon_patient=lib:images/patient.png
 40     icon_summary=lib:images/patient.png
 41     icon_orders=lib:images/patient.png
 42     icon_lab_results=lib:images/patient.png
 43     icon_documents=lib:images/patient.png
 44     icon_problems=lib:images/patient.png
 45     icon_adt=lib:images/patient.png
 46     icon_notes=lib:images/patient.png
 47     icon_reports=lib:images/patient.png
 48     icon_consults=lib:images/patient.png
 49     icon_pen=lib:images/pen.png
 50     icon_filtered=lib:images/filtered.png
 51     icon_acrobat=lib:images/acrobat.png
 52     >> [ inline="true" ]
 53 
 54   /**
 55    * Specify supplemental jars that will be downloaded at runtime.
 56    * The only jar is the one that contains this application’s icons
 57    */
 58   supplementalJars {
 59     "../jars/medical-images.jar"
 60   }
 61 
 62   /**
 63    * Define a set of reusable actions that can be used on menus or buttons
 64    * or invoked programmatically
 65    */
 66   actionItemsURL: << Set {
 67     {
 68       name: "action_find_patient"
 69       value: "Find Patient"
 70       icon: "resource:Sage.icon.search"
 71       actionLink {
 72         url: "patient_lookup_window.sdf"
 73         target: _new_window [ windowType="dialog", title="Find Patient", modal="true" ]
 74       }
 75     }
 76   }
 77   >> [inline=true]
 78 
 79    attributesURL: << Set{
 80       {
 81         name: "patient.name"
 82         value: "Banks, Tyra"
 83       }
 84     }
 85     >> [inline=true]
 86 
 87   /**
 88    * Define a set of application attributes that can be accessed
 89    * via window.getAttribute(@attributeName)
 90    */
 91 
 92   overlapAutoToolTips: true
 93   ignoreFormatExceptions: true
 94   allTextFieldsDraggable: true
 95 
 96   /**
 97    * A custom painter for list type selections
 98    */
 99   selectionPainter {
100     bgColor: "white@50,textHighlight@25"
101     borders {
102       line [ color="textHighlight"]
103     }
104   } [ foreground="textText" ]
105 
106   /**
107    * A custom painter for list type selections
108    * when the widget looses focus
109    */
110   lostFocusSelectionPainter {
111     bgColor: "white@50,controlShadow@10"
112     borders {
113       line [ color="controlShadow"]
114     }
115   } [ foreground="textText" ]
116 
117   /**
118    * A custom painter for tooltips
119    */
120   tooltipPainter {
121     bgColor: "white,gray"
122   } [ foreground="textText" ]
123 
124   /**
125    * Define the main window for the application
126    */
127   mainWindow {
128     templateURL: "template.sdf" [ cache="true" ] //application level template to use to under-skin widgets
129     title: "Sage - Medical App Demo"
130     icon: "lib:images/medical.png"
131     bounds {
132       x: "-1"
133       y: "-1"
134       width: "560dlu"
135       height: "500dlu"
136     }
137     font {
138       size: 13
139     }
140     menuBar {
141       dataURL: "menu.sdf"
142     }
143     statusBar {
144       bgColor: "infobarColor"
145     } [onConfigure="if(sage.isMac()){widget.addAsWindowDragger(window)}"]
146 
147     /**
148      * Define a viewer for the content area of the window
149      */
150     viewer {
151       GridPane {
152         rows: 2
153         rowSpacing: 0
154         regions {
155           {
156             x: "0"
157             y: "0"
158             name: "patient_info"
159             bgColor: "infobarColor"
160             verticalFill: preferred
161             dataURL: "infobar.sdf"
162             collapsibleInfo {
163               title: "Patient Information"
164               opaqueTitleBar: false
165             }
166           }
167           {
168             x: "0"
169             y: "1"
170             verticalFill: maximum
171             viewer {
172               DocumentTabPane {
173                 name: "applicationTabs"
174                 borders {
175                   none
176                 }
177                 popupMenu {
178                   {
179                     name: "Sage.action.reload"
180                   }
181                 }
182                 tabPosition: bottom
183                 closeButton: none
184                 tabStyle: office2003
185                 tabBgColor: "defaultBackground-10,defaultBackground+10"
186                 selectedTabBgColor: "defaultBackground-20,defaultBackground"
187                 selectedIndex: 0
188                 tabs {
189                   {
190                     name: "summary"
191                     dataURL: "summary.sdf"
192                     title: "Summary"
193                   }
194                   {
195                     name: "problems"
196                     dataURL: "problems.sdf"
197                     title: "Problems"
198                   }
199                   {
200                     name: "orders"
201                     dataURL: "orders.sdf"
202                     title: "Orders"
203                   }
204                   {
205                     name: "labs"
206                     dataURL: "labs.sdf"
207                     title: "Lab Results"
208                   }
209                   {
210                     name: "documents"
211                     dataURL: "documents.sdf"
212                     title: "Documents"
213                   }
214                   {
215                     name: "adt"
216                     title: "Admissions/Discharges"
217                     enabled: false
218                   }
219                   {
220                     name: "reports"
221                     dataURL: "reports.sdf"
222                     title: "Reports"
223                   }
224                   {
225                     name: "expenses"
226                     dataURL: "expenses.sdf"
227                     title: "Expenses"
228                   }
229                 }
230               }
231             }
232           }
233         }
234       }
235     }
236   }
237 }
238 
239