Gnumed.wxGladeWidgets.wxgHospitalStayEditAreaPnl

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

# Source Code for Module Gnumed.wxGladeWidgets.wxgHospitalStayEditAreaPnl

     1  # -*- coding: UTF-8 -*-
     2  #
     3  # generated by wxGlade
     4  #
     5
     6  import wx
     7
     8  # begin wxGlade: dependencies
     9  import gettext
    10  # end wxGlade
    11
    12  # begin wxGlade: extracode
    13  # end wxGlade
    14
    15
    16 -class wxgHospitalStayEditAreaPnl(wx.Panel):
    17 -        def __init__(self, *args, **kwds):
    18                  # begin wxGlade: wxgHospitalStayEditAreaPnl.__init__
    19                  kwds["style"] = kwds.get("style", 0) | wx.BORDER_NONE | wx.TAB_TRAVERSAL
    20                  wx.Panel.__init__(self, *args, **kwds)
    21                  from Gnumed.wxpython.gmHospitalStayWidgets import cHospitalWardPhraseWheel
    22                  self._PRW_hospital = cHospitalWardPhraseWheel(self, wx.ID_ANY, "")
    23                  from Gnumed.wxpython.gmEMRStructWidgets import cEpisodeSelectionPhraseWheel
    24                  self._PRW_episode = cEpisodeSelectionPhraseWheel(self, wx.ID_ANY, "")
    25                  from Gnumed.wxpython.gmDateTimeInput import cDateInputPhraseWheel
    26                  self._PRW_admission = cDateInputPhraseWheel(self, wx.ID_ANY, "")
    27                  self._PRW_discharge = cDateInputPhraseWheel(self, wx.ID_ANY, "")
    28                  self._TCTRL_comment = wx.TextCtrl(self, wx.ID_ANY, "")
    29
    30                  self.__set_properties()
    31                  self.__do_layout()
    32                  # end wxGlade
    33
    34 -        def __set_properties(self):
    35                  # begin wxGlade: wxgHospitalStayEditAreaPnl.__set_properties
    36                  self._PRW_hospital.SetToolTip(_("Mandatory: Which hospital the patient was admitted to."))
    37                  self._PRW_episode.SetToolTip(_("Mandatory: Select, or enter for creation, the episode (reason, condition) of this hospitalization."))
    38                  self._PRW_admission.SetToolTip(_("Mandatory: When was the patient admitted ?"))
    39                  self._PRW_discharge.SetToolTip(_("Optional: When was the Patient discharged ?"))
    40                  self._TCTRL_comment.SetToolTip(_("Optional: An arbitrary comment on this hospital stay."))
    41                  # end wxGlade
    42
    43 -        def __do_layout(self):
    44                  # begin wxGlade: wxgHospitalStayEditAreaPnl.__do_layout
    45                  _gszr_main = wx.FlexGridSizer(5, 2, 3, 5)
    46                  __lbl_hospital = wx.StaticText(self, wx.ID_ANY, _("Hospital"))
    47                  __lbl_hospital.SetForegroundColour(wx.Colour(255, 0, 0))
    48                  _gszr_main.Add(__lbl_hospital, 0, wx.ALIGN_CENTER_VERTICAL, 0)
    49                  _gszr_main.Add(self._PRW_hospital, 0, wx.ALIGN_CENTER_VERTICAL | wx.EXPAND, 0)
    50                  __lbl_episode = wx.StaticText(self, wx.ID_ANY, _("Episode"))
    51                  __lbl_episode.SetForegroundColour(wx.Colour(255, 0, 0))
    52                  _gszr_main.Add(__lbl_episode, 0, wx.ALIGN_CENTER_VERTICAL, 0)
    53                  _gszr_main.Add(self._PRW_episode, 0, wx.ALIGN_CENTER_VERTICAL | wx.EXPAND, 0)
    54                  __lbl_admission = wx.StaticText(self, wx.ID_ANY, _("Admitted"))
    55                  __lbl_admission.SetForegroundColour(wx.Colour(255, 0, 0))
    56                  _gszr_main.Add(__lbl_admission, 0, wx.ALIGN_CENTER_VERTICAL, 0)
    57                  _gszr_main.Add(self._PRW_admission, 0, wx.ALIGN_CENTER_VERTICAL | wx.EXPAND, 0)
    58                  __lbl_discharge = wx.StaticText(self, wx.ID_ANY, _("Discharged"))
    59                  _gszr_main.Add(__lbl_discharge, 0, wx.ALIGN_CENTER_VERTICAL, 0)
    60                  _gszr_main.Add(self._PRW_discharge, 0, wx.ALIGN_CENTER_VERTICAL | wx.EXPAND, 0)
    61                  __lbl_comment = wx.StaticText(self, wx.ID_ANY, _("Comment"))
    62                  _gszr_main.Add(__lbl_comment, 0, wx.ALIGN_CENTER_VERTICAL, 0)
    63                  _gszr_main.Add(self._TCTRL_comment, 0, wx.ALIGN_CENTER_VERTICAL | wx.EXPAND, 0)
    64                  self.SetSizer(_gszr_main)
    65                  _gszr_main.Fit(self)
    66                  _gszr_main.AddGrowableCol(1)
    67                  self.Layout()
    68                  # end wxGlade
    69
    70  # end of class wxgHospitalStayEditAreaPnl
    71