1
0

Hello.py 6.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124
  1. from multiprocessing import Process
  2. def painting_board():
  3. from CGB import Draw
  4. Draw()
  5. def Draw():
  6. global top,HTB
  7. HTB = Process(target=painting_board)
  8. HTB.start()
  9. def Data_Science():
  10. from Data_Science import Machine_learning
  11. Machine_learning()
  12. def SJKX():
  13. global top,SJ
  14. SJ = Process(target=Data_Science)
  15. SJ.start()
  16. def Function_mapping():
  17. from HSCH import Func_Control
  18. Func_Control()
  19. def Hsch():
  20. global top,CH
  21. CH = Process(target=Function_mapping)
  22. CH.start()
  23. def Function_factory():
  24. from HSCH import Advanced_Control
  25. Advanced_Control()
  26. def HSGC():
  27. global top,HsGC
  28. HsGC = Process(target=Function_factory)
  29. HsGC.start()
  30. def Algebraic_factory():
  31. from DSGC import Alg
  32. Alg()
  33. def Dsgc():
  34. global top,DsGC
  35. DsGC = Process(target=Algebraic_factory)
  36. DsGC.start()
  37. def Machine_Learning():
  38. from Machine_learning_analysis import Main
  39. Main()
  40. def MLA():
  41. global top, DsGC
  42. Mla = Process(target=Machine_Learning())
  43. Mla.start()
  44. def Main():
  45. global top
  46. import tkinter
  47. import tkinter.font as tkFont
  48. from PIL import ImageTk, Image
  49. from New_TK import DragWindow
  50. print('加载完毕')
  51. top = DragWindow(alpha=0.97,width=1200,height=800)
  52. ft = tkFont.Font(family='Comic Sans MS', size=20, weight=tkFont.BOLD)
  53. ft1 = tkFont.Font(family='Comic Sans MS', size=16, weight=tkFont.BOLD)
  54. ft2 = tkFont.Font(family='Comic Sans MS', size=10)
  55. ft3 = tkFont.Font(family='Comic Sans MS', size=50, weight=tkFont.BOLD)
  56. top.title('')
  57. top.resizable(width=False, height=False)
  58. top.geometry(f'1200x800+30+30')
  59. #渲染白色
  60. F1 = tkinter.Frame(top, width=1200, height=800, bg='#FFFFFF')
  61. F1.pack()
  62. #图片
  63. canvas = tkinter.Canvas(F1,bd=0, width=1000, height=800,highlightthickness=0)
  64. photo = ImageTk.PhotoImage(Image.open('Pic/Night2.jpg'))
  65. canvas.create_image(500, 400, image=photo)
  66. canvas.grid(column=1, row=0,sticky=tkinter.S + tkinter.N,rowspan =20)
  67. abg = '#F0FFFF'
  68. bg = '#FFFFFF'
  69. bc = 'tcross'
  70. #标题
  71. tkinter.Label(F1, text='CoTan~NOTE', width=20,bg='#FFFFFF', font=ft).grid(column=0, row=0,sticky=tkinter.N) # 设置说明
  72. tkinter.Label(F1, text='私人笔记',bg=abg,font=ft1).grid(column=0, row=1,sticky=tkinter.W + tkinter.E)
  73. tkinter.Button(F1,text='Markdown笔记',cursor=bc,height=2,font=ft2,bg=bg,activebackground=abg,bd=0,justify=tkinter.LEFT).grid(column =0,row = 2,sticky=tkinter.N + tkinter.E + tkinter.W)
  74. tkinter.Button(F1, text='画图板',cursor=bc,command=Draw, height=2, font=ft2, bg=bg,activebackground=abg, bd=0, justify=tkinter.LEFT).grid(column=0, row=3,sticky=tkinter.N + tkinter.E + tkinter.W)
  75. tkinter.Button(F1, text='爬虫系统',cursor=bc, height=1, font=ft2, bg=bg,activebackground=abg, bd=0, justify=tkinter.LEFT).grid(column=0, row=4,sticky=tkinter.N + tkinter.E + tkinter.W)
  76. tkinter.Button(F1, text='我的寄忆',cursor=bc, height=1, font=ft2, bg=bg,activebackground=abg, bd=0, justify=tkinter.LEFT).grid(column=0, row=5,sticky=tkinter.N + tkinter.E + tkinter.W)
  77. abg = '#FFFAFA'
  78. tkinter.Label(F1, text='数学系统', bg=abg, font=ft1).grid(column=0, row=6,sticky=tkinter.W + tkinter.E)
  79. tkinter.Button(F1,text='函数测绘',cursor=bc,command=Hsch,height=2,font=ft2,bg=bg,activebackground=abg,bd=0,justify=tkinter.LEFT).grid(column =0,row = 7,sticky=tkinter.N + tkinter.E + tkinter.W)
  80. tkinter.Button(F1, text='函数工厂',cursor=bc,command=HSGC, height=2, font=ft2, bg=bg,activebackground=abg, bd=0, justify=tkinter.LEFT).grid(column=0, row=8,sticky=tkinter.N + tkinter.E + tkinter.W)
  81. tkinter.Button(F1, text='代数工厂',cursor=bc,command=Dsgc, height=2, font=ft2, bg=bg,activebackground=abg, bd=0, justify=tkinter.LEFT).grid(column=0, row=9,sticky=tkinter.N + tkinter.E + tkinter.W)
  82. tkinter.Button(F1, text='数据科学',cursor=bc,command=SJKX, height=1, font=ft2, bg=bg,activebackground=abg, bd=0, justify=tkinter.LEFT).grid(column=0, row=10,sticky=tkinter.N + tkinter.E + tkinter.W)
  83. tkinter.Button(F1, text='机器学习',cursor=bc,command=MLA, height=1, font=ft2, bg=bg,activebackground=abg, bd=0, justify=tkinter.LEFT).grid(column=0, row=11,sticky=tkinter.N + tkinter.E + tkinter.W)
  84. abg='#F5FFFA'
  85. tkinter.Label(F1, text='物化系统', bg=abg, font=ft1).grid(column=0, row=12, sticky=tkinter.W + tkinter.E)
  86. tkinter.Button(F1, text='平面物体分析',cursor=bc, height=2, font=ft2, bg=bg,activebackground=abg, bd=0, justify=tkinter.LEFT).grid(column=0, row=13,
  87. sticky=tkinter.N + tkinter.E + tkinter.W)
  88. tkinter.Button(F1, text='平面受力分析',cursor=bc, height=2, font=ft2, bg=bg,activebackground=abg, bd=0, justify=tkinter.LEFT).grid(column=0, row=14,
  89. sticky=tkinter.N + tkinter.E + tkinter.W)
  90. tkinter.Button(F1, text='实验数据拟合',cursor=bc, height=1, font=ft2, bg=bg,activebackground=abg, bd=0, justify=tkinter.LEFT).grid(column=0,
  91. row=15,
  92. sticky=tkinter.N + tkinter.E + tkinter.W)
  93. tkinter.Button(F1, text='化学反应预测',cursor=bc, height=1, font=ft2, bg=bg,activebackground=abg, bd=0, justify=tkinter.LEFT).grid(column=0,
  94. row=16,
  95. sticky=tkinter.N + tkinter.E + tkinter.W)
  96. abg = '#F8F8FF'
  97. tkinter.Label(F1, text='其他工具', bg=abg, font=ft1).grid(column=0, row=17, sticky=tkinter.W + tkinter.E)
  98. tkinter.Button(F1, text='系统扩展',cursor=bc, height=1, font=ft2, bg=bg,activebackground=abg, bd=0, justify=tkinter.LEFT).grid(column=0, row=18,
  99. sticky=tkinter.N + tkinter.E + tkinter.W)
  100. tkinter.Button(F1, text='Tensorflew深度学习',cursor=bc, height=1, font=ft2, bg=bg,activebackground=abg, bd=0, justify=tkinter.LEFT).grid(column=0, row=19,
  101. sticky=tkinter.N + tkinter.E + tkinter.W)
  102. tkinter.Label(F1, text='', bg='#FFFFFF', font=ft1,height=5).grid(column=0, row=20, sticky=tkinter.W + tkinter.E)
  103. canvas.create_text(500,750,text='CoTan~别来无恙',font=ft3,fill='#FFFFE0')
  104. top.mainloop()
  105. if __name__ == "__main__":
  106. Main()