def __init__(self,data, parent=None): super(filename_ui, self).__init__(parent=parent) self.fui = filenameui.Ui_filename() self.fui.setupUi(self) self.data = data self.cov = cov.ShaderConvert() self.setWindowTitle('File Name') self.button()
def __init__(self, parent=None): super(MainApp, self).__init__(parent=parent) self.ui = ui.Ui_ShaderConvertor() self.editor_win = None self.ui.setupUi(self) self.cov = cov.ShaderConvert() self.setup_defaults() self.button()
def do_POST(self): print('begin') self.gitpull(GitSrcPath) self.stopHugo() convert = Convertor.Convertor() convert.excute(GitSrcPath, TargetPath) self.startHugo() print("finished") self.wfile.write(b"msg finished")
def convert_func(entry, state): str = '' if state == 'Dec': if (entry.isnumeric()) == True: dec = entry bin = conv.decToBin(entry) hex = conv.binToHex(bin) else: wrongIn() return elif state == 'Hex': if checkEntryHex(entry) == True: hex = entry.upper() bin = conv.hexToBin(entry) dec = conv.binToDec(bin) else: return elif state == 'Bin': if checkEntryBin(entry) == True: bin = entry dec = conv.binToDec(entry) hex = conv.binToHex(entry) else: return str = "Binary: %s\nDecimal: %s\nHexadecimal: %s\n" % (bin, dec, hex) print(str) label['text'] = str
def __init__(self, current,parent=None): super(Editor, self).__init__(parent=parent) self.current = current self.cov_info = [] self.cov_info_2 = [] self.info_1_item = [] self.info_2_item = [] self.font = QtGui.QFont() self.eui = editui.Ui_Editor() self.cov = cov.ShaderConvert() self.eui.setupUi(self) self.setup_defaults() self.button() if self.current != '--Create Preset--': self.load_config()
#exmple of module import Convertor #this is the one mehtod to import the modules(files ) from Convertor import lbs_to_kg #this is the second method to import the modules print(lbs_to_kg(100)) print(Convertor.kg_to_lbs(70))
def setUp(self): self.folderManager = Convertor.FolderManager()
from flask.ext.restful import Resource
def setUp(self): self.convert = Convertor.Convertor()