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

# Source Code for Module Gnumed.wxGladeWidgets.wxgEncounterTypeEditAreaPnl

     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 wxgEncounterTypeEditAreaPnl(wx.ScrolledWindow):
    17 -        def __init__(self, *args, **kwds):
    18                  # begin wxGlade: wxgEncounterTypeEditAreaPnl.__init__
    19                  kwds["style"] = kwds.get("style", 0) | wx.BORDER_NONE | wx.TAB_TRAVERSAL
    20                  wx.ScrolledWindow.__init__(self, *args, **kwds)
    21                  self._TCTRL_l10n_name = wx.TextCtrl(self, wx.ID_ANY, "")
    22                  self._TCTRL_name = wx.TextCtrl(self, wx.ID_ANY, "")
    23
    24                  self.__set_properties()
    25                  self.__do_layout()
    26                  # end wxGlade
    27
    28 -        def __set_properties(self):
    29                  # begin wxGlade: wxgEncounterTypeEditAreaPnl.__set_properties
    30                  self.SetScrollRate(10, 10)
    31                  self._TCTRL_l10n_name.SetToolTip(_("Required: A name for this encounter type in your local language."))
    32                  self._TCTRL_name.SetToolTip(_("Optional: A system-wide description for this encounter type. If you leave this empty the local name will be used.\n\nIt is useful to choose an English term but that is not mandatory. One advantage to using a system-wide type description is that different people can have the system description translated into their language and still use the same encounter type."))
    33                  self._TCTRL_name.Enable(False)
    34                  # end wxGlade
    35
    36 -        def __do_layout(self):
    37                  # begin wxGlade: wxgEncounterTypeEditAreaPnl.__do_layout
    38                  _gszr_main = wx.FlexGridSizer(2, 2, 1, 3)
    39                  __lbl_l10n_name = wx.StaticText(self, wx.ID_ANY, _("Local name"))
    40                  __lbl_l10n_name.SetForegroundColour(wx.Colour(255, 0, 0))
    41                  _gszr_main.Add(__lbl_l10n_name, 0, wx.ALIGN_CENTER_VERTICAL, 0)
    42                  _gszr_main.Add(self._TCTRL_l10n_name, 0, wx.ALIGN_CENTER_VERTICAL | wx.EXPAND, 0)
    43                  __lbl_name = wx.StaticText(self, wx.ID_ANY, _("Encounter type"))
    44                  _gszr_main.Add(__lbl_name, 0, wx.ALIGN_CENTER_VERTICAL, 0)
    45                  _gszr_main.Add(self._TCTRL_name, 0, wx.ALIGN_CENTER_VERTICAL | wx.EXPAND, 0)
    46                  self.SetSizer(_gszr_main)
    47                  _gszr_main.Fit(self)
    48                  _gszr_main.AddGrowableCol(1)
    49                  self.Layout()
    50                  # end wxGlade
    51
    52  # end of class wxgEncounterTypeEditAreaPnl
    53