예제 #1
0
 def i18n(self, actions=None):
     if not self.tabber.active_editor:
         return
     if not actions:
         actions = self.tabber.active_editor.actions()
     for action in actions:
         if not action.isSeparator():
             action.setText(pyqode_i18n.tr(action.text()))
         if action.menu():
             self.i18n(action.menu().actions())
예제 #2
0
파일: uPyIDE.py 프로젝트: pocean2001/uPyIDE
 def i18n(self, actions=None):
     if not self.tabber.active_editor:
         return
     if not actions:
         actions = self.tabber.active_editor.actions()
     for action in actions:
         if not action.isSeparator():
             action.setText(pyqode_i18n.tr(action.text()))
         if action.menu():
             self.i18n(action.menu().actions())
예제 #3
0
def i18n(s):
    return pyqode_i18n.tr(s)
예제 #4
0
파일: myDef.py 프로젝트: pocean2001/uPyIDE
def i18n(s):
    lang, encode = locale.getdefaultlocale()
    return pyqode_i18n.tr(s, lang=lang)