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

# Source Code for Module Gnumed.wxGladeWidgets.wxgDatabaseTranslationEAPnl

     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 wxgDatabaseTranslationEAPnl(wx.ScrolledWindow):
    17 -        def __init__(self, *args, **kwds):
    18                  # begin wxGlade: wxgDatabaseTranslationEAPnl.__init__
    19                  kwds["style"] = kwds.get("style", 0) | wx.BORDER_NONE | wx.TAB_TRAVERSAL
    20                  wx.ScrolledWindow.__init__(self, *args, **kwds)
    21                  self._TCTRL_original = wx.TextCtrl(self, wx.ID_ANY, "", style=wx.TE_MULTILINE | wx.TE_READONLY)
    22                  self._TCTRL_translation = wx.TextCtrl(self, wx.ID_ANY, "", style=wx.TE_MULTILINE)
    23                  self._TCTRL_language = wx.TextCtrl(self, wx.ID_ANY, "")
    24
    25                  self.__set_properties()
    26                  self.__do_layout()
    27                  # end wxGlade
    28
    29 -        def __set_properties(self):
    30                  # begin wxGlade: wxgDatabaseTranslationEAPnl.__set_properties
    31                  self.SetScrollRate(10, 10)
    32                  self._TCTRL_original.SetToolTip(_("Original string as found in the database. Usually in English."))
    33                  self._TCTRL_translation.SetToolTip(_("Enter your translation here."))
    34                  self._TCTRL_language.SetToolTip(_("Enter the language code here. You need either the two letter or the four letter ISO code. When entering four letter codes use the format xx_XX, such as de_DE."))
    35                  # end wxGlade
    36
    37 -        def __do_layout(self):
    38                  # begin wxGlade: wxgDatabaseTranslationEAPnl.__do_layout
    39                  _gszr_main = wx.FlexGridSizer(3, 2, 1, 3)
    40                  __lbl_string = wx.StaticText(self, wx.ID_ANY, _("String"))
    41                  _gszr_main.Add(__lbl_string, 0, wx.ALIGN_CENTER_VERTICAL, 0)
    42                  _gszr_main.Add(self._TCTRL_original, 0, wx.ALIGN_CENTER_VERTICAL | wx.EXPAND, 0)
    43                  __lbl_translation = wx.StaticText(self, wx.ID_ANY, _("Translation"))
    44                  _gszr_main.Add(__lbl_translation, 0, wx.ALIGN_CENTER_VERTICAL, 0)
    45                  _gszr_main.Add(self._TCTRL_translation, 0, wx.ALIGN_CENTER_VERTICAL | wx.EXPAND, 0)
    46                  __lbl_language = wx.StaticText(self, wx.ID_ANY, _("Language"))
    47                  _gszr_main.Add(__lbl_language, 0, wx.ALIGN_CENTER_VERTICAL, 0)
    48                  _gszr_main.Add(self._TCTRL_language, 0, wx.ALIGN_CENTER_VERTICAL | wx.EXPAND, 0)
    49                  self.SetSizer(_gszr_main)
    50                  _gszr_main.Fit(self)
    51                  _gszr_main.AddGrowableRow(0)
    52                  _gszr_main.AddGrowableRow(1)
    53                  _gszr_main.AddGrowableCol(1)
    54                  self.Layout()
    55                  # end wxGlade
    56
    57  # end of class wxgDatabaseTranslationEAPnl
    58