1010####################################
1111#build configure
1212
13- ver = "0.31-canary -full"
13+ ver = "0.32-build -full"
1414
1515libs_warning = "1"
1616#1 is ture 0 is false.
2929#xxxxxxxxxxxxxx
3030####################################
3131#BINPython function and variable START
32- def binpython_ver ():
33- print (ver )
32+ class binpythoninfo :
33+ def ver ():
34+ print (ver )
3435
35- def binpython_buildversion ():
36- print (buildversion )
36+ def buildversion ():
37+ print (buildversion )
3738
38- def binpython_libs_warning ():
39- print (libs_warning )
39+ def libs_warning ():
40+ print (libs_warning )
4041
41- def binpython_releases_ver ():
42- print (releases_ver )
42+ def releases_ver ():
43+ print (releases_ver )
4344
44- def binpython_build_importlibs ():
45- print (importlibs )
45+ def build_importlibs ():
46+ print (importlibs )
4647#get system info(windows or linux ...)
4748import platform
4849sys = platform .system ()
4950#if system is windows, then enable setwindowtitle() function
5051if sys == "Windows" :
51- def setwindowtitle (titlename ):
52- import ctypes
53- ctypes .windll .kernel32 .SetConsoleTitleW (titlename )
52+ class binpythonwin :
53+ def setwindowtitle (titlename ):
54+ import ctypes
55+ ctypes .windll .kernel32 .SetConsoleTitleW (titlename )
5456#print binpython all configure function
5557def binpythonallconf ():
5658 print ("ver: " + ver + " buildversion: " + buildversion + " libs_warning settings:" + libs_warning + " releases full version: " + releases_ver + " custom library that has been build: " + importlibs )
@@ -525,7 +527,7 @@ def main():
525527 sys .exit ()
526528#helloworld
527529 if examplenum == "5" :
528- setwindowtitle ("Hi, Welcome to BINPython" )
530+ binpythonwin . setwindowtitle ("Hi, Welcome to BINPython" )
529531 name = input ("hi...What's your name:" )
530532 print ("hi," + name )
531533 sys .exit ()
@@ -540,11 +542,11 @@ def examplerequests():
540542 if examplenum == "7" :
541543 print ("BINPython() function example" )
542544 import time
543- binpython_ver ()
544- binpython_buildversion ()
545- binpython_libs_warning ()
546- binpython_build_importlibs ()
547- setwindowtitle ("Title name(str)" )
545+ binpythoninfo . ver ()
546+ binpythoninfo . buildversion ()
547+ binpythoninfo . libs_warning ()
548+ binpythoninfo . build_importlibs ()
549+ binpythonwin . setwindowtitle ("Title name(str)" )
548550 binpythonallconf ()
549551 time .sleep (5 )
550552 #main shell
@@ -583,31 +585,32 @@ def TestPlatform():
583585 pass
584586#binpython custom function plugin
585587#plugin start
586- plugin_name = ''
587- def binpython_plugin_name (key ):
588- global plugin_name
589- plugin_name = key
590- #print(plugin_name)
591- plugin_anthor = ''
592- def binpython_plugin_anthor (key ):
593- global plugin_anthor
594- plugin_anthor = key
595- #description
596- plugin_description = ''
597- def binpython_plugin_description (key ):
598- global plugin_description
599- plugin_description = key
600- def binpython_plugin_showinfo ():
601- print ("BINPython Plugin Info:" )
602- print ("Plugin Name: " + plugin_name )
603- print ("Plugin Anthor: " + plugin_anthor )
604- print ("Plugin description: " + plugin_description )
588+ class binpythonplugin :
589+ plugin_name = ''
590+ def name (key ):
591+ global plugin_name
592+ plugin_name = key
593+ #print(plugin_name)
594+ plugin_anthor = ''
595+ def anthor (key ):
596+ global plugin_anthor
597+ plugin_anthor = key
598+ #description
599+ plugin_description = ''
600+ def description (key ):
601+ global plugin_description
602+ plugin_description = key
603+ def showinfo ():
604+ print ("BINPython Plugin Info:" )
605+ print ("Plugin Name: " + plugin_name )
606+ print ("Plugin Anthor: " + plugin_anthor )
607+ print ("Plugin description: " + plugin_description )
605608
606609
607- plugin_loadmain = ''
608- def binpython_plugin_loadmain (key ):
609- global plugin_loadmain
610- plugin_loadmain = key
610+ plugin_loadmain = ''
611+ def binpython_plugin_loadmain (key ):
612+ global plugin_loadmain
613+ plugin_loadmain = key
611614#binpython_plugin_loadmain("function.py")
612615try :
613616 f = open ("binpython_plugin/pluginconfig.binpython" ,encoding = "utf-8" )
0 commit comments