Gnumed.wxGladeWidgets.wxgMeasurementsByBatteryPnl

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

# Source Code for Module Gnumed.wxGladeWidgets.wxgMeasurementsByBatteryPnl

     1  # -*- coding: UTF-8 -*-
     2  #
     3  # generated by wxGlade
     4  #
     5
     6  import wx
     7  import wx.grid
     8
     9  # begin wxGlade: dependencies
    10  import gettext
    11  # end wxGlade
    12
    13  # begin wxGlade: extracode
    14  # end wxGlade
    15
    16
    17 -class wxgMeasurementsByBatteryPnl(wx.Panel):
    18 -        def __init__(self, *args, **kwds):
    19                  # begin wxGlade: wxgMeasurementsByBatteryPnl.__init__
    20                  kwds["style"] = kwds.get("style", 0) | wx.BORDER_NONE | wx.TAB_TRAVERSAL
    21                  wx.Panel.__init__(self, *args, **kwds)
    22                  from Gnumed.wxpython.gmMeasurementWidgets import cTestPanelPRW
    23                  self._PRW_panel = cTestPanelPRW(self, wx.ID_ANY, "")
    24                  self._TCTRL_panel_comment = wx.TextCtrl(self, wx.ID_ANY, "")
    25                  self._BTN_manage_panels = wx.Button(self, wx.ID_ANY, _("Manage"), style=wx.BU_EXACTFIT)
    26                  from Gnumed.wxpython.gmMeasurementWidgets import cMeasurementsGrid
    27                  self._GRID_results_battery = cMeasurementsGrid(self, wx.ID_ANY, size=(1, 1))
    28
    29                  self.__set_properties()
    30                  self.__do_layout()
    31
    32                  self.Bind(wx.EVT_BUTTON, self._on_manage_panels_button_pressed, self._BTN_manage_panels)
    33                  # end wxGlade
    34
    35 -        def __set_properties(self):
    36                  # begin wxGlade: wxgMeasurementsByBatteryPnl.__set_properties
    37                  self._TCTRL_panel_comment.SetBackgroundColour(wx.SystemSettings.GetColour(wx.SYS_COLOUR_BACKGROUND))
    38                  self._TCTRL_panel_comment.Enable(False)
    39                  self._BTN_manage_panels.SetToolTip(_("Manage test panels."))
    40                  # end wxGlade
    41
    42 -        def __do_layout(self):
    43                  # begin wxGlade: wxgMeasurementsByBatteryPnl.__do_layout
    44                  __szr_main = wx.BoxSizer(wx.VERTICAL)
    45                  __szr_panel_options = wx.BoxSizer(wx.HORIZONTAL)
    46                  __lbl_display = wx.StaticText(self, wx.ID_ANY, _("&Panel:"))
    47                  __szr_panel_options.Add(__lbl_display, 0, wx.ALIGN_CENTER_VERTICAL | wx.RIGHT, 5)
    48                  __szr_panel_options.Add(self._PRW_panel, 2, wx.ALIGN_CENTER_VERTICAL | wx.RIGHT, 10)
    49                  __szr_panel_options.Add(self._TCTRL_panel_comment, 3, wx.ALIGN_CENTER_VERTICAL | wx.RIGHT, 5)
    50                  __szr_panel_options.Add(self._BTN_manage_panels, 0, wx.ALIGN_CENTER_VERTICAL, 5)
    51                  __szr_main.Add(__szr_panel_options, 0, wx.EXPAND | wx.LEFT | wx.RIGHT | wx.TOP, 5)
    52                  __szr_main.Add(self._GRID_results_battery, 1, wx.EXPAND, 5)
    53                  self.SetSizer(__szr_main)
    54                  __szr_main.Fit(self)
    55                  self.Layout()
    56                  # end wxGlade
    57
    58 -        def _on_manage_panels_button_pressed(self, event):  # wxGlade: wxgMeasurementsByBatteryPnl.<event_handler>
    59                  print("Event handler '_on_manage_panels_button_pressed' not implemented!")
    60                  event.Skip()
    61
    62  # end of class wxgMeasurementsByBatteryPnl
    63