Package Gnumed :: Package wxGladeWidgets :: Module wxgSoapPluginPnl
[frames] | no frames]

Source Code for Module Gnumed.wxGladeWidgets.wxgSoapPluginPnl

  1  #!/usr/bin/env python 
  2  # -*- coding: utf8 -*- 
  3  # generated by wxGlade 0.6.3 from "/home/ncq/Projekte/gm-cvs/branches/HEAD/gnumed/gnumed/client/wxg/wxgSoapPluginPnl.wxg" 
  4   
  5  import wx 
  6   
  7  # begin wxGlade: extracode 
  8  # end wxGlade 
  9   
 10   
 11   
12 -class cSoapNoteInputNotebook(wx.Notebook):
13 - def __init__(self, *args, **kwds):
14 # begin wxGlade: cSoapNoteInputNotebook.__init__ 15 kwds["style"] = 0 16 wx.Notebook.__init__(self, *args, **kwds) 17 self.notebook_1_pane_1 = wx.Panel(self, -1) 18 19 self.__set_properties() 20 self.__do_layout()
21 # end wxGlade 22
23 - def __set_properties(self):
24 # begin wxGlade: cSoapNoteInputNotebook.__set_properties 25 self.AddPage(self.notebook_1_pane_1, _("tab1"))
26 # end wxGlade 27
28 - def __do_layout(self):
29 # begin wxGlade: cSoapNoteInputNotebook.__do_layout 30 pass
31 # end wxGlade 32 33 # end of class cSoapNoteInputNotebook 34 35
36 -class wxgSoapPluginPnl(wx.ScrolledWindow):
37 - def __init__(self, *args, **kwds):
38 39 from Gnumed.wxpython.gmNarrativeWidgets import cSoapNoteInputNotebook 40 from Gnumed.wxpython.gmNarrativeWidgets import cVisualSoapPnl 41 from Gnumed.wxpython.gmDateTimeInput import cFuzzyTimestampInput 42 from Gnumed.wxpython.gmEMRStructWidgets import cEncounterTypePhraseWheel 43 from Gnumed.wxpython import gmListWidgets 44 45 # begin wxGlade: wxgSoapPluginPnl.__init__ 46 kwds["style"] = wx.NO_BORDER|wx.TAB_TRAVERSAL 47 wx.Panel.__init__(self, *args, **kwds) 48 self._splitter_main = wx.SplitterWindow(self, -1, style=wx.SP_3D|wx.SP_BORDER|wx.SP_PERMIT_UNSPLIT) 49 self.__splitter_main_right_pnl = wx.Panel(self._splitter_main, -1, style=wx.NO_BORDER) 50 self._splitter_right = wx.SplitterWindow(self.__splitter_main_right_pnl, -1, style=wx.SP_3D|wx.SP_BORDER|wx.SP_PERMIT_UNSPLIT) 51 self.__splitter_right_bottom_pnl = wx.Panel(self._splitter_right, -1, style=wx.NO_BORDER) 52 self.__splitter_right_top_pnl = wx.Panel(self._splitter_right, -1, style=wx.NO_BORDER) 53 self.__splitter_main_left_pnl = wx.Panel(self._splitter_main, -1, style=wx.NO_BORDER) 54 self._splitter_left = wx.SplitterWindow(self.__splitter_main_left_pnl, -1, style=wx.SP_3D|wx.SP_BORDER|wx.SP_PERMIT_UNSPLIT) 55 self.__splitter_left_bottom_pnl = wx.Panel(self._splitter_left, -1, style=wx.NO_BORDER) 56 self.__splitter_left_top_pnl = wx.Panel(self._splitter_left, -1, style=wx.NO_BORDER) 57 self._SZR_recent_notes_staticbox = wx.StaticBox(self.__splitter_left_bottom_pnl, -1, _("Most recent notes on above problem")) 58 self.__szr_top_right_staticbox = wx.StaticBox(self.__splitter_right_top_pnl, -1, _("New notelets in current encounter")) 59 self.__szr_bottom_right_staticbox = wx.StaticBox(self.__splitter_right_bottom_pnl, -1, _("Tips and hints")) 60 self._SZR_problem_list_staticbox = wx.StaticBox(self.__splitter_left_top_pnl, -1, _("Active problems")) 61 self._CHBOX_show_closed_episodes = wx.CheckBox(self.__splitter_left_top_pnl, -1, _("Closed episodes")) 62 self._CHBOX_irrelevant_issues = wx.CheckBox(self.__splitter_left_top_pnl, -1, _("Non-relevant issues")) 63 self._LCTRL_active_problems = gmListWidgets.cReportListCtrl(self.__splitter_left_top_pnl, -1, style=wx.LC_REPORT|wx.NO_BORDER) 64 self._TCTRL_recent_notes = wx.TextCtrl(self.__splitter_left_bottom_pnl, -1, _("In this area GNUmed will place the notes of the\nprevious encounter as well as notes by other\nstaff for the current encounter.\n\nNote that this may change depending on which\nactive problem is selected in the editor below."), style=wx.TE_MULTILINE|wx.TE_READONLY|wx.TE_WORDWRAP|wx.NO_BORDER) 65 self._PRW_encounter_type = cEncounterTypePhraseWheel(self.__splitter_right_top_pnl, -1, "", style=wx.NO_BORDER) 66 self._PRW_encounter_start = cFuzzyTimestampInput(self.__splitter_right_top_pnl, -1, "", style=wx.NO_BORDER) 67 self._PRW_encounter_end = cFuzzyTimestampInput(self.__splitter_right_top_pnl, -1, "", style=wx.NO_BORDER) 68 self._TCTRL_rfe = wx.TextCtrl(self.__splitter_right_top_pnl, -1, "", style=wx.NO_BORDER) 69 self._NB_soap_editors = cSoapNoteInputNotebook(self.__splitter_right_top_pnl, -1) 70 self._TCTRL_aoe = wx.TextCtrl(self.__splitter_right_top_pnl, -1, "", style=wx.NO_BORDER) 71 self._BTN_new_editor = wx.Button(self.__splitter_right_top_pnl, -1, _("&New"), style=wx.BU_EXACTFIT) 72 self._BTN_clear_editor = wx.Button(self.__splitter_right_top_pnl, -1, _("&Clear"), style=wx.BU_EXACTFIT) 73 self._BTN_discard_editor = wx.Button(self.__splitter_right_top_pnl, -1, _("&Discard"), style=wx.BU_EXACTFIT) 74 self._BTN_save_note = wx.Button(self.__splitter_right_top_pnl, -1, _("&Save"), style=wx.BU_EXACTFIT) 75 self._BTN_image = wx.Button(self.__splitter_right_top_pnl, -1, _("&Image"), style=wx.BU_EXACTFIT) 76 self._BTN_new_encounter = wx.Button(self.__splitter_right_top_pnl, -1, _("New"), style=wx.BU_EXACTFIT) 77 self._BTN_save_encounter = wx.Button(self.__splitter_right_top_pnl, -1, _("Save"), style=wx.BU_EXACTFIT) 78 self._BTN_save_all = wx.Button(self.__splitter_right_top_pnl, -1, _("Save &all"), style=wx.BU_EXACTFIT) 79 self._lbl_hints = wx.StaticText(self.__splitter_right_bottom_pnl, -1, _("In this area GNUmed will place hints and tips\nrelated to the current progress note and patient.\n\nThose hints will be derived from a variety of\nsources such as classifications (ICD, ...), expert\nsystems (EGADDS), online resources (Google\nand friends), drug databases, etc.\n\nEventually, those hints will be active in that you\ncan click on them and be taken to the relevant\ninformation/an appropriate action be performed.")) 80 81 self.__set_properties() 82 self.__do_layout() 83 84 self.Bind(wx.EVT_CHECKBOX, self._on_show_closed_episodes_checked, self._CHBOX_show_closed_episodes) 85 self.Bind(wx.EVT_CHECKBOX, self._on_irrelevant_issues_checked, self._CHBOX_irrelevant_issues) 86 self.Bind(wx.EVT_LIST_ITEM_SELECTED, self._on_problem_selected, self._LCTRL_active_problems) 87 self.Bind(wx.EVT_LIST_ITEM_ACTIVATED, self._on_problem_activated, self._LCTRL_active_problems) 88 self.Bind(wx.EVT_LIST_ITEM_FOCUSED, self._on_problem_focused, self._LCTRL_active_problems) 89 self.Bind(wx.EVT_BUTTON, self._on_new_editor_button_pressed, self._BTN_new_editor) 90 self.Bind(wx.EVT_BUTTON, self._on_clear_editor_button_pressed, self._BTN_clear_editor) 91 self.Bind(wx.EVT_BUTTON, self._on_discard_editor_button_pressed, self._BTN_discard_editor) 92 self.Bind(wx.EVT_BUTTON, self._on_save_note_button_pressed, self._BTN_save_note) 93 self.Bind(wx.EVT_BUTTON, self._on_image_button_pressed, self._BTN_image) 94 self.Bind(wx.EVT_BUTTON, self._on_new_encounter_button_pressed, self._BTN_new_encounter) 95 self.Bind(wx.EVT_BUTTON, self._on_save_encounter_button_pressed, self._BTN_save_encounter) 96 self.Bind(wx.EVT_BUTTON, self._on_save_all_button_pressed, self._BTN_save_all)
97 # end wxGlade 98
99 - def __set_properties(self):
100 # begin wxGlade: wxgSoapPluginPnl.__set_properties 101 self._CHBOX_show_closed_episodes.SetToolTipString(_("Show closed episodes as pseudo-problems ?")) 102 self._CHBOX_irrelevant_issues.SetToolTipString(_("Show issues marked clinically NOT relevant.")) 103 self._LCTRL_active_problems.SetToolTipString(_("This shows the list of active problems, They include open episodes as well as active health issues.")) 104 self._TCTRL_recent_notes.SetBackgroundColour(wx.SystemSettings_GetColour(wx.SYS_COLOUR_3DFACE)) 105 self._PRW_encounter_type.SetToolTipString(_("Select the type of encounter.")) 106 self._PRW_encounter_start.SetToolTipString(_("Date and time when the current (!) encounter started.")) 107 self._PRW_encounter_end.SetToolTipString(_("Date and time when the current (!) encounter ends.")) 108 self._TCTRL_rfe.SetToolTipString(_("This documents why the encounter takes place.\n\nIt may be due to a patient request or it may be prompted by other reasons. Often initially collected at the front desk and put into a waiting list comment. May turn out to just be a proxy request for why the patient really is here.\n\nAlso known as the Reason For Encounter/Visit (RFE).")) 109 self._TCTRL_aoe.SetToolTipString(_("This summarizes the outcome/assessment of the consultation from the doctors point of view. Note that this summary spans all the problems discussed during this encounter.")) 110 self._BTN_new_editor.SetToolTipString(_("Open a new progress note editor.\n\nThere is a configuration item on whether to allow several new-episode editors at once.")) 111 self._BTN_clear_editor.SetToolTipString(_("Clear the editor for the displayed progress note.")) 112 self._BTN_discard_editor.SetToolTipString(_("Discard the editor for the displayed progress note.")) 113 self._BTN_save_note.SetToolTipString(_("Save the currently displayed progress note.")) 114 self._BTN_image.SetToolTipString(_("Add a visual progress note for this episode.")) 115 self._BTN_new_encounter.SetToolTipString(_("Start a new encounter. If there are any changes to the current encounter you will be asked whether to save them.")) 116 self._BTN_save_encounter.SetToolTipString(_("Save the encounter details.")) 117 self._BTN_save_all.SetToolTipString(_("Save encounter details and all progress notes."))
118 # end wxGlade 119
120 - def __do_layout(self):
121 # begin wxGlade: wxgSoapPluginPnl.__do_layout 122 __szr_main = wx.BoxSizer(wx.HORIZONTAL) 123 __szr_right = wx.BoxSizer(wx.VERTICAL) 124 __szr_bottom_right = wx.StaticBoxSizer(self.__szr_bottom_right_staticbox, wx.VERTICAL) 125 __szr_top_right = wx.StaticBoxSizer(self.__szr_top_right_staticbox, wx.VERTICAL) 126 __szr_buttons = wx.BoxSizer(wx.HORIZONTAL) 127 __szr_aoe = wx.BoxSizer(wx.HORIZONTAL) 128 __gszr_encounter_details = wx.FlexGridSizer(2, 2, 2, 5) 129 __szr_encounter_details = wx.BoxSizer(wx.HORIZONTAL) 130 __szr_left = wx.BoxSizer(wx.HORIZONTAL) 131 _SZR_recent_notes = wx.StaticBoxSizer(self._SZR_recent_notes_staticbox, wx.VERTICAL) 132 _SZR_problem_list = wx.StaticBoxSizer(self._SZR_problem_list_staticbox, wx.VERTICAL) 133 __szr_problem_filter = wx.BoxSizer(wx.HORIZONTAL) 134 __lbl_problem_filter = wx.StaticText(self.__splitter_left_top_pnl, -1, _("Include:")) 135 __szr_problem_filter.Add(__lbl_problem_filter, 0, wx.RIGHT|wx.ALIGN_CENTER_VERTICAL, 10) 136 __szr_problem_filter.Add(self._CHBOX_show_closed_episodes, 0, wx.RIGHT|wx.ALIGN_CENTER_VERTICAL, 5) 137 __szr_problem_filter.Add(self._CHBOX_irrelevant_issues, 0, wx.ALIGN_CENTER_VERTICAL, 0) 138 __szr_problem_filter.Add((20, 20), 1, wx.EXPAND|wx.ALIGN_CENTER_VERTICAL, 0) 139 _SZR_problem_list.Add(__szr_problem_filter, 0, wx.EXPAND, 0) 140 _SZR_problem_list.Add(self._LCTRL_active_problems, 1, wx.EXPAND, 0) 141 self.__splitter_left_top_pnl.SetSizer(_SZR_problem_list) 142 _SZR_recent_notes.Add(self._TCTRL_recent_notes, 1, wx.EXPAND, 0) 143 self.__splitter_left_bottom_pnl.SetSizer(_SZR_recent_notes) 144 self._splitter_left.SplitHorizontally(self.__splitter_left_top_pnl, self.__splitter_left_bottom_pnl) 145 __szr_left.Add(self._splitter_left, 1, wx.EXPAND, 0) 146 self.__splitter_main_left_pnl.SetSizer(__szr_left) 147 __lbl_encounter_details = wx.StaticText(self.__splitter_right_top_pnl, -1, _("Encounter")) 148 __gszr_encounter_details.Add(__lbl_encounter_details, 0, wx.ALIGN_CENTER_VERTICAL, 0) 149 __szr_encounter_details.Add(self._PRW_encounter_type, 1, wx.RIGHT|wx.EXPAND|wx.ALIGN_CENTER_VERTICAL, 10) 150 __szr_encounter_details.Add(self._PRW_encounter_start, 1, wx.RIGHT|wx.EXPAND|wx.ALIGN_CENTER_VERTICAL, 5) 151 __lbl_until = wx.StaticText(self.__splitter_right_top_pnl, -1, _("until")) 152 __szr_encounter_details.Add(__lbl_until, 0, wx.RIGHT|wx.ALIGN_CENTER_VERTICAL, 5) 153 __szr_encounter_details.Add(self._PRW_encounter_end, 1, wx.EXPAND|wx.ALIGN_CENTER_VERTICAL, 5) 154 __gszr_encounter_details.Add(__szr_encounter_details, 1, wx.EXPAND, 0) 155 __lbl_rfe = wx.StaticText(self.__splitter_right_top_pnl, -1, _("Purpose ...")) 156 __gszr_encounter_details.Add(__lbl_rfe, 0, wx.ALIGN_CENTER_VERTICAL, 0) 157 __gszr_encounter_details.Add(self._TCTRL_rfe, 1, wx.EXPAND|wx.ALIGN_CENTER_VERTICAL, 0) 158 __gszr_encounter_details.AddGrowableCol(1) 159 __szr_top_right.Add(__gszr_encounter_details, 0, wx.RIGHT|wx.TOP|wx.EXPAND, 3) 160 __szr_top_right.Add(self._NB_soap_editors, 4, wx.EXPAND, 3) 161 __lbl_aoe = wx.StaticText(self.__splitter_right_top_pnl, -1, _("... summary")) 162 __szr_aoe.Add(__lbl_aoe, 0, wx.RIGHT|wx.ALIGN_CENTER_VERTICAL, 5) 163 __szr_aoe.Add(self._TCTRL_aoe, 1, wx.TOP|wx.BOTTOM|wx.EXPAND|wx.ALIGN_CENTER_VERTICAL, 5) 164 __szr_top_right.Add(__szr_aoe, 0, wx.RIGHT|wx.TOP|wx.EXPAND, 3) 165 __lbl_editor = wx.StaticText(self.__splitter_right_top_pnl, -1, _("Notelet:")) 166 __szr_buttons.Add(__lbl_editor, 0, wx.RIGHT|wx.ALIGN_CENTER_VERTICAL, 5) 167 __szr_buttons.Add(self._BTN_new_editor, 0, wx.RIGHT|wx.EXPAND, 3) 168 __szr_buttons.Add(self._BTN_clear_editor, 0, wx.RIGHT|wx.EXPAND, 3) 169 __szr_buttons.Add(self._BTN_discard_editor, 0, wx.RIGHT|wx.EXPAND, 3) 170 __szr_buttons.Add(self._BTN_save_note, 0, wx.RIGHT|wx.EXPAND, 3) 171 __szr_buttons.Add(self._BTN_image, 0, wx.EXPAND, 0) 172 __szr_buttons.Add((1, 1), 1, wx.EXPAND, 0) 173 __lbl_encounter = wx.StaticText(self.__splitter_right_top_pnl, -1, _("Encounter:")) 174 __szr_buttons.Add(__lbl_encounter, 0, wx.RIGHT|wx.ALIGN_CENTER_VERTICAL, 5) 175 __szr_buttons.Add(self._BTN_new_encounter, 0, wx.RIGHT|wx.EXPAND, 3) 176 __szr_buttons.Add(self._BTN_save_encounter, 0, wx.EXPAND, 3) 177 __szr_buttons.Add((1, 1), 1, wx.EXPAND, 0) 178 __szr_buttons.Add(self._BTN_save_all, 0, wx.EXPAND, 5) 179 __szr_top_right.Add(__szr_buttons, 0, wx.RIGHT|wx.TOP|wx.EXPAND, 3) 180 self.__splitter_right_top_pnl.SetSizer(__szr_top_right) 181 __szr_bottom_right.Add(self._lbl_hints, 0, wx.EXPAND, 0) 182 self.__splitter_right_bottom_pnl.SetSizer(__szr_bottom_right) 183 self._splitter_right.SplitHorizontally(self.__splitter_right_top_pnl, self.__splitter_right_bottom_pnl) 184 __szr_right.Add(self._splitter_right, 1, wx.EXPAND, 0) 185 self.__splitter_main_right_pnl.SetSizer(__szr_right) 186 self._splitter_main.SplitVertically(self.__splitter_main_left_pnl, self.__splitter_main_right_pnl) 187 __szr_main.Add(self._splitter_main, 1, wx.EXPAND, 0) 188 self.SetSizer(__szr_main) 189 __szr_main.Fit(self)
190 # end wxGlade 191
192 - def _on_save_all_button_pressed(self, event): # wxGlade: wxgSoapPluginPnl.<event_handler>
193 print "Event handler `_on_save_all_button_pressed' not implemented!" 194 event.Skip()
195
196 - def _on_save_encounter_button_pressed(self, event): # wxGlade: wxgSoapPluginPnl.<event_handler>
197 print "Event handler `_on_save_encounter_button_pressed' not implemented!" 198 event.Skip() 199
200 - def _on_save_note_button_pressed(self, event): # wxGlade: wxgSoapPluginPnl.<event_handler>
201 print "Event handler `_on_save_note_button_pressed' not implemented!" 202 event.Skip() 203
204 - def _on_new_editor_button_pressed(self, event): # wxGlade: wxgSoapPluginPnl.<event_handler>
205 print "Event handler `_on_new_editor_button_pressed' not implemented!" 206 event.Skip() 207
208 - def _on_clear_editor_button_pressed(self, event): # wxGlade: wxgSoapPluginPnl.<event_handler>
209 print "Event handler `_on_clear_editor_button_pressed' not implemented!" 210 event.Skip() 211
212 - def _on_discard_editor_button_pressed(self, event): # wxGlade: wxgSoapPluginPnl.<event_handler>
213 print "Event handler `_on_discard_editor_button_pressed' not implemented!" 214 event.Skip() 215
216 - def _on_problem_activated(self, event): # wxGlade: wxgSoapPluginPnl.<event_handler>
217 print "Event handler `_on_problem_activated' not implemented" 218 event.Skip() 219
220 - def _on_new_encounter_button_pressed(self, event): # wxGlade: wxgSoapPluginPnl.<event_handler>
221 print "Event handler `_on_new_encounter_button_pressed' not implemented" 222 event.Skip() 223
224 - def _on_problem_selected(self, event): # wxGlade: wxgSoapPluginPnl.<event_handler>
225 print "Event handler `_on_problem_selected' not implemented" 226 event.Skip() 227
228 - def _on_problem_focused(self, event): # wxGlade: wxgSoapPluginPnl.<event_handler>
229 print "Event handler `_on_problem_focused' not implemented" 230 event.Skip() 231
232 - def _on_show_closed_episodes_checked(self, event): # wxGlade: wxgSoapPluginPnl.<event_handler>
233 print "Event handler `_on_show_closed_episodes_checked' not implemented" 234 event.Skip() 235
236 - def _on_irrelevant_issues_checked(self, event): # wxGlade: wxgSoapPluginPnl.<event_handler>
237 print "Event handler `_on_irrelevant_issues_checked' not implemented" 238 event.Skip() 239
240 - def _on_image_button_pressed(self, event): # wxGlade: wxgSoapPluginPnl.<event_handler>
241 print "Event handler `_on_image_button_pressed' not implemented" 242 event.Skip() 243 244 # end of class wxgSoapPluginPnl 245