├── Ascii ├── Output.txt ├── ascii.py ├── leo.jpg └── output.png ├── Audio monitor ├── LICENSE.rc ├── README.md ├── SWHear.py ├── demo.gif ├── go.py ├── ui_convert.py ├── ui_main.py └── ui_main.ui ├── Autographer ├── pyQtGraph-example.py ├── readme.md └── screenshot.PNG ├── Cosine Scroll autographer ├── LICENSE.md ├── README.md ├── demo2.gif ├── go.bat ├── go.py ├── ui_convert.py ├── ui_main.py └── ui_main.ui ├── Covid dashboard gifs ├── Confirmed.gif ├── Deaths.gif └── Recovered.gif ├── Indian Flag ├── Jai Hind.mp4 └── indian.py ├── Indian Map └── Indian_map.py ├── QR └── QRmaker.py ├── README.md ├── Scientific Calculator ├── Calc.py ├── Calc.spec ├── Calculator_37533.ico ├── __pycache__ │ └── Calc.cpython-39.pyc ├── build │ └── Calc │ │ ├── Analysis-00.toc │ │ ├── Calc.exe.manifest │ │ ├── EXE-00.toc │ │ ├── PKG-00.pkg │ │ ├── PKG-00.toc │ │ ├── PYZ-00.pyz │ │ ├── PYZ-00.toc │ │ ├── Tree-00.toc │ │ ├── Tree-01.toc │ │ ├── Tree-02.toc │ │ ├── base_library.zip │ │ ├── warn-Calc.txt │ │ └── xref-Calc.html ├── calc-ss.jpg ├── dist │ └── Calc.exe └── scientific calculator.py ├── ScreenRecord ├── screen.jpg └── screen_rec.py ├── Sine Scroll autograph ├── LICENSE.md ├── README.md ├── demo.gif ├── go.bat ├── go.py ├── matplotlibwidget.py ├── ui_convert.py ├── ui_main.py └── ui_main.ui ├── Snake Game ├── dist │ └── snakes.exe ├── snakes.py └── snakes.spec ├── Text editor ├── icon.ico ├── icons2 │ ├── align_center.png │ ├── align_left.png │ ├── align_right.png │ ├── bold.png │ ├── clear_all.png │ ├── copy.png │ ├── cut.png │ ├── dark.png │ ├── exit.png │ ├── find.png │ ├── font_color.png │ ├── italic.png │ ├── light_default.png │ ├── light_plus.png │ ├── monokai.png │ ├── new.png │ ├── night_blue.png │ ├── open.png │ ├── paste.png │ ├── red.png │ ├── save.png │ ├── save_as.png │ ├── status_bar.png │ ├── tool_bar.png │ └── underline.png └── tx.py ├── YinYang ├── YinYang.mp4 └── yinyang.py └── darkmode ├── Night Mode.py ├── switch-off.png └── switch-on.png /Ascii/Output.txt: -------------------------------------------------------------------------------- 1 | <~+(+_<_]<~+><>>>!+i~!i!!lIll:ll;,""I;":"::,;iIIll!Ili;IIi!!IllI;l;;!!!i!i!?i~!_>+~~_i~~++_-~+li:II>;lIllII;,,;::^;::II,,i:;IIiIIili;!l!!ilIililI;I!!i> 3 | _-i+<~~_1>>+~+->ilII;Illi!IlI!i!!!;+!>!iIl,,^;:!!!!li 4 | >~~<~>_}]-~l<~i>l>Iil>~~++i+>Ii>+!l<^^^^;:,+l,lI!>!!l!>il!>i>-i!~:I;l;;IIr,:,",I 5 | >iI?-]]?+i+__<>~li>-iil~!>!>ii:l>I::;,",:;Il 6 | >ii!+:I]1[][~>~>i!i{}}]i??~-~~>l~_i!!IilI:I>lilii>I^I:,;l!; 7 | <>i!i~-?{]}_]~?!l++|}]+-?]]<~_]-+!><~>!l;l!!!!l~l~i!~IlIIII~I;I`";liII"; 8 | ]_+i><<<~<+lIl+~?><;I::I 9 | 11[}}1{}~i~l!+[-?<]]](((t[[{~|tz?>Ili,i!~>~-_?[++-])]?)<+l+i!,:Il!I:~i;ilI 10 | /()\}1)+~l!-?_[-[+--[}(][}~-ii1[-_~!Il!il~]_]11)?!?]!~?_<+-]:>ll,^,"i 11 | ()[][<~ll>+]_+~+ii~?-+]~{-+-(_->~i--i>-t+?~-!~~:,:;;!;,,,:",:: 12 | \}]~[~[]_]+-i~+]!iiI]>"'^^`,/~l<__+[)!!!~?+1~!!+i`~I,:.^',;:~>~!->:;,,",",^:,^,i 13 | {]}{{{[_?--[}(}?~~1|_vn^1)(-^rj[-)1t{?i,i~<-[|t(nfvUJf}lr_[[)\x//)(}}-+l>?l:cr\)>)\_~i:,^"^""^::,Il!II~I:: 17 | ff\\)(?})?_<;,"I>>?1r)f\nzUx}+i]1|)/}jj]1{|)__i+_-!":,```,:I~IIi>i>>>;II 18 | ([)1>1}(]-?+_i~l?>>)+}[f}(]~?![X[?()1t-]f}-~(~j|l~_+~lI+l:iI:^","^";,":!I!iII,;: 19 | +}([(+(-[?+)
  • <(]+/t(]>{)_)x~!\]{}}1({1}-[-l~-/!]-?-~_l>II:`",`"I:!I:l;III!>Il 20 | })))}1[[-?-}+!-)|\}~<}]i)\_{n>>i??[Xj|)|t\}?[~!I({,l,","!Il!Il;>;lIII! 21 | {u1\(+{)-]}{~<-j|]]]~]+)i){z|~-1-ffr/?un]/cx){-}i_-i,"!",,ll,lI':^I;;";::,Ijil!i 22 | ftf/f)1}?[[)?-<+}[+-i?<[_f+]\\|/jvCzUcxrnUrjCr+-)I<~ll:;;^;Ill:`:,::";,,;;,I;l,: 23 | |r\tj(\1)||)11-?)-_)}?1<\-|\z1xxCO0JZmYUCrqUJJr|}{>l^^`?`]-+>!lil!i<:I:,l,I,i-:"!I,;::,, 25 | nxcrx)tt||){j(tt}-}+1?[!?_[fLCI,`''[]}-[[-`^`'^>\}>?i>;;-I:IIl;llI,I:lil>:l!: 26 | CUvUYffr|/(_1\)j)|++t)->}|?{|vpJJ?:::~l_i.""~\Yu))?[+~>:[-:l"^I::t;II,j^^:;l,::: 27 | XcOuz|trtt[{)ff|()]-[jvYXzuvcxnm*W*l,>:lI`nOmCttz[?-{{}l~",;:l!Iil<;lI:":::^:;,I 28 | UczjXXx|f1||)|1|}({-lxvnn}+?/-n(rrcam^`"Opf||n;?~-?/nu{[{,:I::::I!!lII":^^`^,`:, 29 | cfxrnrxf(|f(|rt\/]1[|vuvc|t1\COLaMMha8|#dCW*Lmz\1|{//\r~[I>i;"!lIi>l,:`"",^"`^,, 30 | u)\|tUxt]x\t\1|]_}J++|fn}\n]t\XO0Mqh*M;M&ahwanX|J}(}-[)z>>:+lii",[l;I;,":"^`^^"" 31 | zn1{|nrff\fjtY(1?>!z~Il;[;^^I': 32 | vj|1{fjcYfz(rj\|(~+r:_|()XrfnuXQoqO>'`,^'>O#oCCf)?>~l!};`:_>:^Ii>!1r][?//z{~`,I?"l;:;""]YUz1?i>II;"-",:!<;lil!!>i_iiIl!,I:I 34 | UuurtnLuzjx/|t1({_l>-<~>i;,^:`:?cXXrt[1f>f~f_+.;:+;^`::::"`i:!I;!l>>l>!>+>1Iil"l 35 | JCvrzfx\frt\|\[1]_i>iIi!l10Zkd*bmJtrzXc|LczXf:``::^i!:,"I,"!l;!)!~+i;!+i:III! 36 | CQuXUujxff(\|)t)_~+_l>i_!l~xQwmZq#ObwxwYOhULXuYju<:I:;::II~,:;!;;>i+_[~>~>>lI!,^ 37 | zUJYvzufj11j\(t]+[]++il~->jrLzZOq00kcJCnt0UYmOt)/t?il;,^^::I:U!II+!!->]I~;l}ll"l 38 | x/vUUcfxuU]???}1]+-+->?}?[cj]vuUCJCCr\r?fJunYY}};+l!!!I+::ll:,!;!++>~;(?+!;;::II 39 | jnYujYxjfft1??1\|{++!<-??|uxxCC|}QU((f|)Zjvrz1\+l,;;:;l!::lI;i!>!!!i~!{-i!_?{/)}|jff\Cf(Y\ur]|~t_<+il,,l,I",:::;ii+illi>_?1+i>!l!l1 41 | vrrtr1t/Y-tc|)1t[?}[_++>-}[+1?-?+]i<+_+>i~+>?]<~?Ii_IlIi,,;Il`;,;:I:Il;;ll!I;ii 43 | j/r(|[})t1})t}}f+-+~<lI+;<>:lI"lI_~i!:i;l:I"`,,`,;;,:IiI>IIl::ilIII!l;Il: 44 | )/(r\{)[]-?[-[]>}-++iI!ll>!i:;Il;:!^:>;;!i:lI^,,:,!"""::;;:I1Ii;,I",:!I:II,+>>Il 45 | -------------------------------------------------------------------------------- /Ascii/ascii.py: -------------------------------------------------------------------------------- 1 | from PIL import Image, ImageDraw, ImageFont 2 | 3 | import math 4 | 5 | chars = "$@B%8&WM#*oahkbdpqwmZO0QLCJUYXzcvunxrjft/\\|()1{}[]?-_+~<>i!lI;:,\"^`'. "[::-1] 6 | # chars = "#Wo- "[::-1] 7 | charArray = list(chars) 8 | charLength = len(charArray) 9 | interval = charLength/256 10 | 11 | scaleFactor = 0.1 12 | 13 | oneCharWidth = 10 14 | oneCharHeight = 18 15 | 16 | def getChar(inputInt): 17 | return charArray[math.floor(inputInt*interval)] 18 | 19 | text_file = open("Output.txt", "w") 20 | 21 | im = Image.open("leo.jpg") 22 | 23 | fnt = ImageFont.truetype('C:\\Windows\\Fonts\\lucon.ttf', 15) 24 | 25 | width, height = im.size 26 | im = im.resize((int(scaleFactor*width), int(scaleFactor*height*(oneCharWidth/oneCharHeight))), Image.NEAREST) 27 | width, height = im.size 28 | pix = im.load() 29 | 30 | outputImage = Image.new('RGB', (oneCharWidth * width, oneCharHeight * height), color = (0, 0, 0)) 31 | d = ImageDraw.Draw(outputImage) 32 | 33 | for i in range(height): 34 | for j in range(width): 35 | r, g, b = pix[j, i] 36 | h = int(r/3 + g/3 + b/3) 37 | pix[j, i] = (h, h, h) 38 | text_file.write(getChar(h)) 39 | d.text((j*oneCharWidth, i*oneCharHeight), getChar(h), font = fnt, fill = (r, g, b)) 40 | 41 | text_file.write('\n') 42 | 43 | outputImage.save('output.png') 44 | -------------------------------------------------------------------------------- /Ascii/leo.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Ascii/leo.jpg -------------------------------------------------------------------------------- /Ascii/output.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Ascii/output.png -------------------------------------------------------------------------------- /Audio monitor/LICENSE.rc: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2016 Scott W Harden 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. -------------------------------------------------------------------------------- /Audio monitor/README.md: -------------------------------------------------------------------------------- 1 | 2 | # qt audio monitor 3 | 4 | PROJECT PAGE: http://www.swharden.com/wp/2016-07-31-real-time-audio-monitor-with-pyqt/ 5 | 6 | This is a minimal-case example how to get continuous PCM data from the sound card. A preliminary SWHEar class is included which can self-detect likely input devices. To manually define an input device, set it when SWHEar() is called. In most cases it will work right out of the box. If you're playing music and no microphone is detected, it will use the sound mapper and graph the audio being played. 7 | 8 | Youtube demo: https://youtu.be/lDS9rI0o6mM 9 | 10 | ![demo](demo.gif) 11 | 12 | ### Setup 13 | * pyaudio (which requires [portaudio](http://portaudio.com/)) comes ready to use if you install Anaconda 14 | * I did have to `conda install pyqtgraph pyaudio` 15 | 16 | ### Input overflow error? 17 | If you experience _[Errno -9981] Input overflowed_ errors, consider modifying [this line](https://github.com/swharden/Python-GUI-examples/blob/master/2016-07-37_qt_audio_monitor/SWHear.py#L119) and change: 18 | ```python 19 | self.stream.read(self.chunk) 20 | ``` 21 | to: 22 | ```python 23 | self.stream.read(self.chunk, exception_on_overflow=False) 24 | ``` 25 | -------------------------------------------------------------------------------- /Audio monitor/SWHear.py: -------------------------------------------------------------------------------- 1 | """ 2 | this is a stripped down version of the SWHear class. 3 | It's designed to hold only a single audio sample in memory. 4 | check my githib for a more complete version: 5 | http://github.com/swharden 6 | """ 7 | 8 | import pyaudio 9 | import time 10 | import numpy as np 11 | import threading 12 | 13 | def getFFT(data,rate): 14 | """Given some data and rate, returns FFTfreq and FFT (half).""" 15 | data=data*np.hamming(len(data)) 16 | fft=np.fft.fft(data) 17 | fft=np.abs(fft) 18 | #fft=10*np.log10(fft) 19 | freq=np.fft.fftfreq(len(fft),1.0/rate) 20 | return freq[:int(len(freq)/2)],fft[:int(len(fft)/2)] 21 | 22 | class SWHear(): 23 | """ 24 | The SWHear class is provides access to continuously recorded 25 | (and mathematically processed) microphone data. 26 | 27 | Arguments: 28 | 29 | device - the number of the sound card input to use. Leave blank 30 | to automatically detect one. 31 | 32 | rate - sample rate to use. Defaults to something supported. 33 | 34 | updatesPerSecond - how fast to record new data. Note that smaller 35 | numbers allow more data to be accessed and therefore high 36 | frequencies to be analyzed if using a FFT later 37 | """ 38 | 39 | def __init__(self,device=None,rate=None,updatesPerSecond=10): 40 | self.p=pyaudio.PyAudio() 41 | self.chunk=4096 # gets replaced automatically 42 | self.updatesPerSecond=updatesPerSecond 43 | self.chunksRead=0 44 | self.device=device 45 | self.rate=rate 46 | 47 | ### SYSTEM TESTS 48 | 49 | def valid_low_rate(self,device): 50 | """set the rate to the lowest supported audio rate.""" 51 | for testrate in [44100]: 52 | if self.valid_test(device,testrate): 53 | return testrate 54 | print("SOMETHING'S WRONG! I can't figure out how to use DEV",device) 55 | return None 56 | 57 | def valid_test(self,device,rate=44100): 58 | """given a device ID and a rate, return TRUE/False if it's valid.""" 59 | try: 60 | self.info=self.p.get_device_info_by_index(device) 61 | if not self.info["maxInputChannels"]>0: 62 | return False 63 | stream=self.p.open(format=pyaudio.paInt16,channels=1, 64 | input_device_index=device,frames_per_buffer=self.chunk, 65 | rate=int(self.info["defaultSampleRate"]),input=True) 66 | stream.close() 67 | return True 68 | except: 69 | return False 70 | 71 | def valid_input_devices(self): 72 | """ 73 | See which devices can be opened for microphone input. 74 | call this when no PyAudio object is loaded. 75 | """ 76 | mics=[] 77 | for device in range(self.p.get_device_count()): 78 | if self.valid_test(device): 79 | mics.append(device) 80 | if len(mics)==0: 81 | print("no microphone devices found!") 82 | else: 83 | print("found %d microphone devices: %s"%(len(mics),mics)) 84 | return mics 85 | 86 | ### SETUP AND SHUTDOWN 87 | 88 | def initiate(self): 89 | """run this after changing settings (like rate) before recording""" 90 | if self.device is None: 91 | self.device=self.valid_input_devices()[0] #pick the first one 92 | if self.rate is None: 93 | self.rate=self.valid_low_rate(self.device) 94 | self.chunk = int(self.rate/self.updatesPerSecond) # hold one tenth of a second in memory 95 | if not self.valid_test(self.device,self.rate): 96 | print("guessing a valid microphone device/rate...") 97 | self.device=self.valid_input_devices()[0] #pick the first one 98 | self.rate=self.valid_low_rate(self.device) 99 | self.datax=np.arange(self.chunk)/float(self.rate) 100 | msg='recording from "%s" '%self.info["name"] 101 | msg+='(device %d) '%self.device 102 | msg+='at %d Hz'%self.rate 103 | print(msg) 104 | 105 | def close(self): 106 | """gently detach from things.""" 107 | print(" -- sending stream termination command...") 108 | self.keepRecording=False #the threads should self-close 109 | while(self.t.isAlive()): #wait for all threads to close 110 | time.sleep(.1) 111 | self.stream.stop_stream() 112 | self.p.terminate() 113 | 114 | ### STREAM HANDLING 115 | 116 | def stream_readchunk(self): 117 | """reads some audio and re-launches itself""" 118 | try: 119 | self.data = np.fromstring(self.stream.read(self.chunk),dtype=np.int16) 120 | self.fftx, self.fft = getFFT(self.data,self.rate) 121 | 122 | except Exception as E: 123 | print(" -- exception! terminating...") 124 | print(E,"\n"*5) 125 | self.keepRecording=False 126 | if self.keepRecording: 127 | self.stream_thread_new() 128 | else: 129 | self.stream.close() 130 | self.p.terminate() 131 | print(" -- stream STOPPED") 132 | self.chunksRead+=1 133 | 134 | def stream_thread_new(self): 135 | self.t=threading.Thread(target=self.stream_readchunk) 136 | self.t.start() 137 | 138 | def stream_start(self): 139 | """adds data to self.data until termination signal""" 140 | self.initiate() 141 | print(" -- starting stream") 142 | self.keepRecording=True # set this to False later to terminate stream 143 | self.data=None # will fill up with threaded recording data 144 | self.fft=None 145 | self.dataFiltered=None #same 146 | self.stream=self.p.open(format=pyaudio.paInt16,channels=1, 147 | rate=self.rate,input=True,frames_per_buffer=self.chunk) 148 | self.stream_thread_new() 149 | 150 | if __name__=="__main__": 151 | ear=SWHear(updatesPerSecond=10) # optinoally set sample rate here 152 | ear.stream_start() #goes forever 153 | lastRead=ear.chunksRead 154 | while True: 155 | while lastRead==ear.chunksRead: 156 | time.sleep(.01) 157 | print(ear.chunksRead,len(ear.data)) 158 | lastRead=ear.chunksRead 159 | print("DONE") 160 | -------------------------------------------------------------------------------- /Audio monitor/demo.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Audio monitor/demo.gif -------------------------------------------------------------------------------- /Audio monitor/go.py: -------------------------------------------------------------------------------- 1 | from PyQt5 import QtGui,QtCore 2 | 3 | import sys 4 | import ui_main 5 | import numpy as np 6 | import pyqtgraph 7 | import SWHear 8 | 9 | class ExampleApp(QtGui.QMainWindow, ui_main.Ui_MainWindow): 10 | def __init__(self, parent=None): 11 | pyqtgraph.setConfigOption('background', 'w') #before loading widget 12 | super(ExampleApp, self).__init__(parent) 13 | self.setupUi(self) 14 | self.grFFT.plotItem.showGrid(True, True, 0.7) 15 | self.grPCM.plotItem.showGrid(True, True, 0.7) 16 | self.maxFFT=0 17 | self.maxPCM=0 18 | self.ear = SWHear.SWHear(rate=44100,updatesPerSecond=20) 19 | self.ear.stream_start() 20 | 21 | def update(self): 22 | if not self.ear.data is None and not self.ear.fft is None: 23 | pcmMax=np.max(np.abs(self.ear.data)) 24 | if pcmMax>self.maxPCM: 25 | self.maxPCM=pcmMax 26 | self.grPCM.plotItem.setRange(yRange=[-pcmMax,pcmMax]) 27 | if np.max(self.ear.fft)>self.maxFFT: 28 | self.maxFFT=np.max(np.abs(self.ear.fft)) 29 | #self.grFFT.plotItem.setRange(yRange=[0,self.maxFFT]) 30 | self.grFFT.plotItem.setRange(yRange=[0,1]) 31 | self.pbLevel.setValue(1000*pcmMax/self.maxPCM) 32 | pen=pyqtgraph.mkPen(color='b') 33 | self.grPCM.plot(self.ear.datax,self.ear.data,pen=pen,clear=True) 34 | pen=pyqtgraph.mkPen(color='r') 35 | self.grFFT.plot(self.ear.fftx,self.ear.fft/self.maxFFT,pen=pen,clear=True) 36 | QtCore.QTimer.singleShot(1, self.update) # QUICKLY repeat 37 | 38 | if __name__=="__main__": 39 | app = QtGui.QApplication(sys.argv) 40 | form = ExampleApp() 41 | form.show() 42 | form.update() #start with something 43 | app.exec_() 44 | print("DONE") 45 | -------------------------------------------------------------------------------- /Audio monitor/ui_convert.py: -------------------------------------------------------------------------------- 1 | from PyQt5 import uic 2 | import glob 3 | for fname in glob.glob("*.ui"): 4 | print("converting",fname) 5 | fin = open(fname,'r') 6 | fout = open(fname.replace(".ui",".py"),'w') 7 | uic.compileUi(fin,fout,execute=False) 8 | fin.close() 9 | fout.close() 10 | -------------------------------------------------------------------------------- /Audio monitor/ui_main.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | # Form implementation generated from reading ui file 'ui_main.ui' 4 | # 5 | # Created by: PyQt4 UI code generator 4.11.4 6 | # 7 | # WARNING! All changes made in this file will be lost! 8 | 9 | from PyQt5 import QtCore, QtGui 10 | 11 | try: 12 | _fromUtf8 = QtCore.QString.fromUtf8 13 | except AttributeError: 14 | def _fromUtf8(s): 15 | return s 16 | 17 | try: 18 | _encoding = QtGui.QApplication.UnicodeUTF8 19 | def _translate(context, text, disambig): 20 | return QtGui.QApplication.translate(context, text, disambig, _encoding) 21 | except AttributeError: 22 | def _translate(context, text, disambig): 23 | return QtGui.QApplication.translate(context, text, disambig) 24 | 25 | class Ui_MainWindow(object): 26 | def setupUi(self, MainWindow): 27 | MainWindow.setObjectName(_fromUtf8("MainWindow")) 28 | MainWindow.resize(993, 692) 29 | self.centralwidget = QtGui.QWidget(MainWindow) 30 | self.centralwidget.setObjectName(_fromUtf8("centralwidget")) 31 | self.horizontalLayout = QtGui.QHBoxLayout(self.centralwidget) 32 | self.horizontalLayout.setObjectName(_fromUtf8("horizontalLayout")) 33 | self.pbLevel = QtGui.QProgressBar(self.centralwidget) 34 | self.pbLevel.setMaximum(1000) 35 | self.pbLevel.setProperty("value", 123) 36 | self.pbLevel.setTextVisible(False) 37 | self.pbLevel.setOrientation(QtCore.Qt.Vertical) 38 | self.pbLevel.setObjectName(_fromUtf8("pbLevel")) 39 | self.horizontalLayout.addWidget(self.pbLevel) 40 | self.frame = QtGui.QFrame(self.centralwidget) 41 | self.frame.setFrameShape(QtGui.QFrame.NoFrame) 42 | self.frame.setFrameShadow(QtGui.QFrame.Plain) 43 | self.frame.setObjectName(_fromUtf8("frame")) 44 | self.verticalLayout = QtGui.QVBoxLayout(self.frame) 45 | self.verticalLayout.setContentsMargins(0,0,0,0) 46 | self.verticalLayout.setObjectName(_fromUtf8("verticalLayout")) 47 | self.label = QtGui.QLabel(self.frame) 48 | self.label.setObjectName(_fromUtf8("label")) 49 | self.verticalLayout.addWidget(self.label) 50 | self.grFFT = PlotWidget(self.frame) 51 | self.grFFT.setObjectName(_fromUtf8("grFFT")) 52 | self.verticalLayout.addWidget(self.grFFT) 53 | self.label_2 = QtGui.QLabel(self.frame) 54 | self.label_2.setObjectName(_fromUtf8("label_2")) 55 | self.verticalLayout.addWidget(self.label_2) 56 | self.grPCM = PlotWidget(self.frame) 57 | self.grPCM.setObjectName(_fromUtf8("grPCM")) 58 | self.verticalLayout.addWidget(self.grPCM) 59 | self.horizontalLayout.addWidget(self.frame) 60 | MainWindow.setCentralWidget(self.centralwidget) 61 | 62 | self.retranslateUi(MainWindow) 63 | QtCore.QMetaObject.connectSlotsByName(MainWindow) 64 | 65 | def retranslateUi(self, MainWindow): 66 | MainWindow.setWindowTitle(_translate("MainWindow", "MainWindow", None)) 67 | self.label.setText(_translate("MainWindow", "frequency data (FFT):", None)) 68 | self.label_2.setText(_translate("MainWindow", "raw data (PCM):", None)) 69 | 70 | from pyqtgraph import PlotWidget 71 | -------------------------------------------------------------------------------- /Audio monitor/ui_main.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | MainWindow 4 | 5 | 6 | 7 | 0 8 | 0 9 | 993 10 | 692 11 | 12 | 13 | 14 | MainWindow 15 | 16 | 17 | 18 | 19 | 20 | 21 | 1000 22 | 23 | 24 | 123 25 | 26 | 27 | false 28 | 29 | 30 | Qt::Vertical 31 | 32 | 33 | 34 | 35 | 36 | 37 | QFrame::NoFrame 38 | 39 | 40 | QFrame::Plain 41 | 42 | 43 | 44 | 0 45 | 46 | 47 | 48 | 49 | frequency data (FFT): 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | raw data (PCM): 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | PlotWidget 75 | QGraphicsView 76 |
    pyqtgraph
    77 |
    78 |
    79 | 80 | 81 |
    82 | -------------------------------------------------------------------------------- /Autographer/pyQtGraph-example.py: -------------------------------------------------------------------------------- 1 | """ 2 | Minimal-case example how to launch a standalone, interactive, pyqtgraph 3 | 4 | First install pyqtgraph with: 5 | pip install --upgrade pyqtgraph 6 | """ 7 | import pyqtgraph as pg 8 | import pyqtgraph.exporters 9 | import numpy as np 10 | 11 | # set the styling of pyqtgraph 12 | pg.setConfigOption('background', 'w') 13 | pg.setConfigOption('foreground', 'k') 14 | 15 | # create some data 16 | pointCount = 1000 17 | xs = np.arange(pointCount)/pointCount*np.pi*2*5 18 | ys = np.sin(xs) 19 | 20 | # add noise 21 | ys += np.random.random_sample(len(ys))/10 22 | 23 | # create plot 24 | plt = pg.plot(xs, ys, title="Example PyQtGraph", pen='r') 25 | plt.showGrid(x=True,y=True) 26 | 27 | ## Start Qt event loop. 28 | if __name__ == '__main__': 29 | import sys 30 | if sys.flags.interactive != 1 or not hasattr(pg.QtCore, 'PYQT_VERSION'): 31 | pg.QtGui.QApplication.exec_() -------------------------------------------------------------------------------- /Autographer/readme.md: -------------------------------------------------------------------------------- 1 | This project demonstrates how to use the standalone `pyqtgraph` library (http://www.pyqtgraph.org/) with Python 3 to launch an interactive plot with a set of X/Y data. 2 | 3 | Unlike other projects in this repository, this one doesn't require the user to set up a GUI (like a GTK/Glade-centric projects do). This is a great alternative to [matplotlib](https://matplotlib.org/) when the goal is to rapidly display and manipulate high density data. 4 | 5 | ## Installation 6 | ``` 7 | pip install --upgrade pyqtgraph 8 | ``` 9 | 10 | ## Example Code 11 | 12 | ```python 13 | import pyqtgraph as pg 14 | import pyqtgraph.exporters 15 | import numpy as np 16 | 17 | # set the styling of pyqtgraph 18 | pg.setConfigOption('background', 'w') 19 | pg.setConfigOption('foreground', 'k') 20 | 21 | # create some data 22 | pointCount = 1000 23 | xs = np.arange(pointCount)/pointCount*np.pi*2*5 24 | ys = np.sin(xs) 25 | 26 | # add noise 27 | ys += np.random.random_sample(len(ys))/10 28 | 29 | # create plot 30 | plt = pg.plot(xs, ys, title="Example PyQtGraph", pen='r') 31 | plt.showGrid(x=True,y=True) 32 | 33 | ## Start Qt event loop. 34 | if __name__ == '__main__': 35 | import sys 36 | if sys.flags.interactive != 1 or not hasattr(pg.QtCore, 'PYQT_VERSION'): 37 | pg.QtGui.QApplication.exec_() 38 | ``` 39 | 40 | ## Screenshot 41 | ![](screenshot.PNG) -------------------------------------------------------------------------------- /Autographer/screenshot.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Autographer/screenshot.PNG -------------------------------------------------------------------------------- /Cosine Scroll autographer/LICENSE.md: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) [2016] [Scott W Harden] 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. -------------------------------------------------------------------------------- /Cosine Scroll autographer/README.md: -------------------------------------------------------------------------------- 1 | # PyQtGraph GraphWidget demo 2 | This was tested to be ~40x faster than a similar matplotlib graph 3 | 4 | PROJECT PAGE: http://www.swharden.com/wp/2016-07-31-live-data-in-pyqt4-with-plotwidget/ 5 | 6 | This is a minimal-case example how to get a PyQt4 GUI (designed with QT Designer) to display a 7 | pyqtgraph PlotWidget and update it automatically. This was tested with the WinPython 3.x distribution, 8 | but should be cross platform. Read the parent readme for full project details. 9 | 10 | * edit the ui_main.ui with "Qt Designer" 11 | * run ui_convert.py to turn ui_main.ui into ui_main.py 12 | * run go.py to launch the program (pulling UI from ui_main.py) 13 | * if the "keep updating" box is checked and the add buttin is hit, it does more and more! 14 | 15 | ![demo](demo2.gif) 16 | -------------------------------------------------------------------------------- /Cosine Scroll autographer/demo2.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Cosine Scroll autographer/demo2.gif -------------------------------------------------------------------------------- /Cosine Scroll autographer/go.bat: -------------------------------------------------------------------------------- 1 | python go.py 2 | pause -------------------------------------------------------------------------------- /Cosine Scroll autographer/go.py: -------------------------------------------------------------------------------- 1 | from PyQt4 import QtGui,QtCore 2 | import sys 3 | import ui_main 4 | import numpy as np 5 | import pylab 6 | import time 7 | import pyqtgraph 8 | 9 | class ExampleApp(QtGui.QMainWindow, ui_main.Ui_MainWindow): 10 | def __init__(self, parent=None): 11 | pyqtgraph.setConfigOption('background', 'w') #before loading widget 12 | super(ExampleApp, self).__init__(parent) 13 | self.setupUi(self) 14 | self.btnAdd.clicked.connect(self.update) 15 | self.grPlot.plotItem.showGrid(True, True, 0.7) 16 | 17 | def update(self): 18 | t1=time.clock() 19 | points=100 #number of data points 20 | X=np.arange(points) 21 | Y=np.sin(np.arange(points)/points*3*np.pi+time.time()) 22 | C=pyqtgraph.hsvColor(time.time()/5%1,alpha=.5) 23 | pen=pyqtgraph.mkPen(color=C,width=10) 24 | self.grPlot.plot(X,Y,pen=pen,clear=True) 25 | print("update took %.02f ms"%((time.clock()-t1)*1000)) 26 | if self.chkMore.isChecked(): 27 | QtCore.QTimer.singleShot(1, self.update) # QUICKLY repeat 28 | 29 | if __name__=="__main__": 30 | app = QtGui.QApplication(sys.argv) 31 | form = ExampleApp() 32 | form.show() 33 | form.update() #start with something 34 | app.exec_() 35 | print("DONE") -------------------------------------------------------------------------------- /Cosine Scroll autographer/ui_convert.py: -------------------------------------------------------------------------------- 1 | from PyQt4 import uic 2 | import glob 3 | for fname in glob.glob("*.ui"): 4 | print("converting",fname) 5 | fin = open(fname,'r') 6 | fout = open(fname.replace(".ui",".py"),'w') 7 | uic.compileUi(fin,fout,execute=False) 8 | fin.close() 9 | fout.close() 10 | -------------------------------------------------------------------------------- /Cosine Scroll autographer/ui_main.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | # Form implementation generated from reading ui file 'ui_main.ui' 4 | # 5 | # Created by: PyQt4 UI code generator 4.11.4 6 | # 7 | # WARNING! All changes made in this file will be lost! 8 | 9 | from PyQt4 import QtCore, QtGui 10 | 11 | try: 12 | _fromUtf8 = QtCore.QString.fromUtf8 13 | except AttributeError: 14 | def _fromUtf8(s): 15 | return s 16 | 17 | try: 18 | _encoding = QtGui.QApplication.UnicodeUTF8 19 | def _translate(context, text, disambig): 20 | return QtGui.QApplication.translate(context, text, disambig, _encoding) 21 | except AttributeError: 22 | def _translate(context, text, disambig): 23 | return QtGui.QApplication.translate(context, text, disambig) 24 | 25 | class Ui_MainWindow(object): 26 | def setupUi(self, MainWindow): 27 | MainWindow.setObjectName(_fromUtf8("MainWindow")) 28 | MainWindow.resize(820, 650) 29 | MainWindow.setAutoFillBackground(False) 30 | MainWindow.setDocumentMode(False) 31 | self.centralwidget = QtGui.QWidget(MainWindow) 32 | self.centralwidget.setObjectName(_fromUtf8("centralwidget")) 33 | self.verticalLayout = QtGui.QVBoxLayout(self.centralwidget) 34 | self.verticalLayout.setObjectName(_fromUtf8("verticalLayout")) 35 | self.horizontalLayout = QtGui.QHBoxLayout() 36 | self.horizontalLayout.setContentsMargins(-1, -1, 0, 0) 37 | self.horizontalLayout.setSpacing(10) 38 | self.horizontalLayout.setObjectName(_fromUtf8("horizontalLayout")) 39 | self.btnAdd = QtGui.QPushButton(self.centralwidget) 40 | self.btnAdd.setObjectName(_fromUtf8("btnAdd")) 41 | self.horizontalLayout.addWidget(self.btnAdd) 42 | self.chkMore = QtGui.QCheckBox(self.centralwidget) 43 | self.chkMore.setObjectName(_fromUtf8("chkMore")) 44 | self.horizontalLayout.addWidget(self.chkMore) 45 | self.verticalLayout.addLayout(self.horizontalLayout) 46 | self.grPlot = PlotWidget(self.centralwidget) 47 | self.grPlot.setObjectName(_fromUtf8("grPlot")) 48 | self.verticalLayout.addWidget(self.grPlot) 49 | MainWindow.setCentralWidget(self.centralwidget) 50 | self.statusbar = QtGui.QStatusBar(MainWindow) 51 | self.statusbar.setObjectName(_fromUtf8("statusbar")) 52 | MainWindow.setStatusBar(self.statusbar) 53 | 54 | self.retranslateUi(MainWindow) 55 | QtCore.QMetaObject.connectSlotsByName(MainWindow) 56 | 57 | def retranslateUi(self, MainWindow): 58 | MainWindow.setWindowTitle(_translate("MainWindow", "MainWindow", None)) 59 | self.btnAdd.setText(_translate("MainWindow", "update sine wave", None)) 60 | self.chkMore.setText(_translate("MainWindow", "keep updating", None)) 61 | 62 | from pyqtgraph import PlotWidget 63 | -------------------------------------------------------------------------------- /Cosine Scroll autographer/ui_main.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | MainWindow 4 | 5 | 6 | 7 | 0 8 | 0 9 | 820 10 | 650 11 | 12 | 13 | 14 | MainWindow 15 | 16 | 17 | false 18 | 19 | 20 | false 21 | 22 | 23 | 24 | 25 | 26 | 27 | 10 28 | 29 | 30 | 0 31 | 32 | 33 | 0 34 | 35 | 36 | 37 | 38 | update sine wave 39 | 40 | 41 | 42 | 43 | 44 | 45 | keep updating 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | PlotWidget 61 | QGraphicsView 62 |
    pyqtgraph
    63 |
    64 |
    65 | 66 | 67 |
    68 | -------------------------------------------------------------------------------- /Covid dashboard gifs/Confirmed.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Covid dashboard gifs/Confirmed.gif -------------------------------------------------------------------------------- /Covid dashboard gifs/Deaths.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Covid dashboard gifs/Deaths.gif -------------------------------------------------------------------------------- /Covid dashboard gifs/Recovered.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Covid dashboard gifs/Recovered.gif -------------------------------------------------------------------------------- /Indian Flag/Jai Hind.mp4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Indian Flag/Jai Hind.mp4 -------------------------------------------------------------------------------- /Indian Flag/indian.py: -------------------------------------------------------------------------------- 1 | import turtle 2 | 3 | flag = turtle.Turtle() 4 | 5 | flag.speed(4) 6 | flag.pensize(5) 7 | flag.color('#054187') 8 | def draw(x,y): 9 | flag.penup() 10 | flag.goto(x,y) 11 | flag.pendown() 12 | 13 | 14 | 15 | for i in range(24): 16 | flag.forward(60) 17 | flag.backward(60) 18 | flag.left(15) 19 | 20 | draw(0, -60) 21 | flag.circle(60, 360) 22 | 23 | 24 | 25 | flag.color('green') 26 | draw(0,-70) 27 | flag.begin_fill() 28 | flag.forward(350) 29 | flag.backward(700) 30 | flag.right(90) 31 | flag.forward(200) 32 | flag.left(90) 33 | flag.forward(700) 34 | flag.left(90) 35 | flag.forward(200) 36 | flag.left(90) 37 | flag.end_fill() 38 | 39 | flag.color('orange') 40 | draw(-350,70) 41 | flag.begin_fill() 42 | flag.right(180) 43 | flag.forward(700) 44 | flag.left(90) 45 | flag.forward(200) 46 | flag.left(90) 47 | flag.forward(700) 48 | flag.left(90) 49 | flag.forward(200) 50 | flag.end_fill() 51 | 52 | turtle.done() -------------------------------------------------------------------------------- /Indian Map/Indian_map.py: -------------------------------------------------------------------------------- 1 | a = 10 2 | b = 0 3 | c = 10 4 | 5 | s = ("TFy!QJu ROo TNn(ROo)SLq SLq ULo+UHs" 6 | " UJq TNn*RPn/QPbEWS_JSWQAIJO^NBELPe" 7 | "HBFHT}TnALVlBLOFAkHFOuFETpHCStHAUFA" 8 | "gcEAelclcn^r^r\\tZvYxXyT|S~Pn SPm S" 9 | "On TNn ULo0ULo#ULo-WHq!WFs XDt!") 10 | 11 | a = ord(s[b]) 12 | 13 | while a != 0: 14 | if b < 170: 15 | a = ord(s[b]) 16 | b += 1 17 | 18 | while a > 64: 19 | a -= 1 20 | c += 1 21 | 22 | if c == 90: 23 | c = c // 9 24 | print(end = chr(c)) 25 | else: 26 | print(chr(33 ^ (b & 0X01)), end = '') 27 | 28 | else: 29 | break 30 | 31 | 32 | # Indian Map using Python ---- Made by Mainak Chaudhuri -------------------------------------------------------------------------------- /QR/QRmaker.py: -------------------------------------------------------------------------------- 1 | import qrcode 2 | import image 3 | qr = qrcode.QRCode( 4 | version = 15, 5 | box_size = 10, 6 | border = 5 7 | ) 8 | 9 | data = "https://akshunnpro.netlify.app/" 10 | 11 | qr.add_data(data) 12 | qr.make(fit=True) 13 | img = qr.make_image(fill="black", back_color="white") 14 | img.save("test.png") 15 | 16 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 | # PyProjects 3 | 4 | 5 | These are a collection of some cool games in Python, which you may show up as some funky Python projects. 6 | 7 | ## Made with 💜 by Mainak Chaudhuri 8 | 9 | 10 | 11 | 12 |
    13 | 14 | ## Screenshots and Walk-through: 15 | 16 | 1. Indian Flag 17 | 18 | ![1](https://user-images.githubusercontent.com/64016811/117139251-a7317480-adc9-11eb-8d2d-97de6e034c87.gif) 19 | 20 | 21 | 2. Indian Map 22 | 23 | 24 | ![2](https://user-images.githubusercontent.com/64016811/117139587-0c856580-adca-11eb-931e-57a5b06a77e3.gif) 25 | 26 | 27 | 3. Image to ASCII Converter 28 | 29 | ![3](https://user-images.githubusercontent.com/64016811/117139763-3e96c780-adca-11eb-9e66-054df466b530.png) 30 | 31 | 32 | 4. Snakes Game 33 | 34 | ![4](https://user-images.githubusercontent.com/64016811/117139783-43f41200-adca-11eb-97f2-65b2ac58d025.jpg) 35 | 36 | 37 | 5. RICO : Screen Recorder 38 | 39 | ![5](https://user-images.githubusercontent.com/64016811/117139794-48b8c600-adca-11eb-98d2-b2520032f618.jpg) 40 | 41 | 42 | 6. Sceintific Calculator 43 | 44 | ![6](https://user-images.githubusercontent.com/64016811/117139817-4ce4e380-adca-11eb-9e63-17073e1ab431.jpg) 45 | 46 | 47 | 7. Auto-grapher 48 | 49 | ![7](https://user-images.githubusercontent.com/64016811/117139834-52422e00-adca-11eb-9108-c7c4097fa8e4.gif) 50 | 51 | 52 | 8. Sound Visualizer 53 | 54 | ![8](https://user-images.githubusercontent.com/64016811/117139844-566e4b80-adca-11eb-8a01-c4de1e94b878.gif) 55 | 56 | 57 | 9. Yin-Yang 58 | 59 | ![YinYang](https://user-images.githubusercontent.com/64016811/115610874-1063b300-a307-11eb-8df4-3cae82682a74.gif) 60 | 61 | 10. Text Editor 62 | 63 | ![rr](https://user-images.githubusercontent.com/64016811/116501903-ada68480-a8cf-11eb-8d05-cc62c44c23b9.jpg) 64 | 65 | 66 |
    67 | -------------------------------------------------------------------------------- /Scientific Calculator/Calc.py: -------------------------------------------------------------------------------- 1 | import tkinter as tk 2 | from math import * 3 | 4 | convert_constant = 1 5 | inverse_convert_constant = 1 6 | 7 | btn_params = { 8 | 'padx': 16, 9 | 'pady': 1, 10 | 'bd': 4, 11 | 'fg': '#F0F8FF', 12 | 'bg': 'gray12', 13 | 'font': ('arial', 18), 14 | 'width': 2, 15 | 'height': 2, 16 | 'relief': 'flat', 17 | 'activebackground': 'gray12' 18 | } 19 | 20 | 21 | def fsin(arg): 22 | return sin(arg * convert_constant) 23 | 24 | 25 | def fcos(arg): 26 | return cos(arg * convert_constant) 27 | 28 | 29 | def ftan(arg): 30 | return tan(arg * convert_constant) 31 | 32 | 33 | def arcsin(arg): 34 | return inverse_convert_constant * (asin(arg)) 35 | 36 | 37 | def arccos(arg): 38 | return inverse_convert_constant * (acos(arg)) 39 | 40 | 41 | def arctan(arg): 42 | return inverse_convert_constant * (atan(arg)) 43 | 44 | 45 | class Calculator: 46 | def __init__(self, master): 47 | self.expression = "" 48 | self.recall = "" 49 | self.sum_up = "" 50 | self.text_input = tk.StringVar() 51 | self.master = master 52 | top_frame = tk.Frame(master, width=650, height=20, bd=4, relief='flat', bg='gray4') 53 | top_frame.pack(side=tk.TOP) 54 | bottom_frame = tk.Frame(master, width=650, height=470, bd=2, relief='flat', bg='gray4') 55 | bottom_frame.pack(side=tk.BOTTOM) 56 | txt_display = tk.Entry(top_frame, font=('arial', 36), relief='flat', 57 | bg='#222222', fg='#FFFFFF', textvariable=self.text_input, width=60, bd=4, justify='right') 58 | txt_display.pack() 59 | 60 | self.btn_left_brack = tk.Button(bottom_frame, **btn_params, text="(", command=lambda: self.btn_click('(')) 61 | self.btn_left_brack.grid(row=0, column=0) 62 | self.btn_right_brack = tk.Button(bottom_frame, **btn_params, text=")", command=lambda: self.btn_click(')')) 63 | self.btn_right_brack.grid(row=0, column=1) 64 | self.btn_MC = tk.Button(bottom_frame, **btn_params, text="mc", command=self.memory_clear) 65 | self.btn_MC.grid(row=0, column=2) 66 | self.btn_M_plus = tk.Button(bottom_frame, **btn_params, text="m+", command=self.memory_add) 67 | self.btn_M_plus.grid(row=0, column=3) 68 | self.btn_M_plus = tk.Button(bottom_frame, **btn_params, text="m-", command=self.memory_add) 69 | self.btn_M_plus.grid(row=0, column=4) 70 | self.btn_MR = tk.Button(bottom_frame, **btn_params, text="mr", command=self.memory_recall) 71 | self.btn_MR.grid(row=0, column=5) 72 | self.btn_clear = tk.Button(bottom_frame, **btn_params, text="AC", command=self.btn_clear_all) 73 | self.btn_clear.configure(activebackground="#A5A5A5", bg='#A5A5A5', foreground='black') 74 | self.btn_clear.grid(row=0, column=6) 75 | self.btn_change_sign = tk.Button(bottom_frame, **btn_params, text="+/-", command=self.change_signs) 76 | self.btn_change_sign.configure(activebackground="#A5A5A5", bg='#A5A5A5', foreground='black') 77 | self.btn_change_sign.grid(row=0, column=7) 78 | self.btn_change_sign = tk.Button(bottom_frame, **btn_params, text="%", command=self.change_signs) 79 | self.btn_change_sign.configure(activebackground="#A5A5A5", bg='#A5A5A5', foreground='black') 80 | self.btn_change_sign.grid(row=0, column=8) 81 | self.btn_div = tk.Button(bottom_frame, **btn_params, text="÷", command=lambda: self.btn_click('/')) 82 | self.btn_div.configure(activebackground="#FB9F10", bg='#FB9F10', foreground='#FFFFFF') 83 | self.btn_div.grid(row=0, column=9) 84 | self.btn_clear = tk.Button(bottom_frame, **btn_params, text="2nd", command=self.btn_clear_all) 85 | self.btn_clear.grid(row=1, column=0) 86 | self.cube = tk.Button(bottom_frame, **btn_params, text=u"x\u00B2", command=lambda: self.btn_click('**2')) 87 | self.cube.grid(row=1, column=1) 88 | self.cube = tk.Button(bottom_frame, **btn_params, text=u"x\u00B3", command=lambda: self.btn_click('**3')) 89 | self.cube.grid(row=1, column=2) 90 | self.btn_power = tk.Button(bottom_frame, **btn_params, text="x^y", command=lambda: self.btn_click('**')) 91 | self.btn_power.grid(row=1, column=3) 92 | self.btn_power = tk.Button(bottom_frame, **btn_params, text="e^x", command=lambda: self.btn_click('**')) 93 | self.btn_power.grid(row=1, column=4) 94 | self.btn_power = tk.Button(bottom_frame, **btn_params, text="10^x", command=lambda: self.btn_click('**')) 95 | self.btn_power.grid(row=1, column=5) 96 | self.btn_7 = tk.Button(bottom_frame, **btn_params, text="7", command=lambda: self.btn_click(7)) 97 | self.btn_7.configure(activebackground="#343434", bg='#343434') 98 | self.btn_7.grid(row=1, column=6) 99 | self.btn_8 = tk.Button(bottom_frame, **btn_params, text="8", command=lambda: self.btn_click(8)) 100 | self.btn_8.configure(activebackground="#343434", bg='#343434') 101 | self.btn_8.grid(row=1, column=7) 102 | self.btn_9 = tk.Button(bottom_frame, **btn_params, text="9", command=lambda: self.btn_click(9)) 103 | self.btn_9.configure(activebackground="#343434", bg='#343434') 104 | self.btn_9.grid(row=1, column=8) 105 | self.btn_mult = tk.Button(bottom_frame, **btn_params, text="x", command=lambda: self.btn_click('*')) 106 | self.btn_mult.configure(activebackground="#FB9F10", bg='#FB9F10', foreground='#FFFFFF') 107 | self.btn_mult.grid(row=1, column=9) 108 | self.btn_power = tk.Button(bottom_frame, **btn_params, text="1/x", command=lambda: self.btn_click('1/x')) 109 | self.btn_power.grid(row=2, column=0) 110 | self.btn_Deg = tk.Button(bottom_frame, **btn_params, text="Deg", command=self.convert_deg) 111 | self.btn_Deg.grid(row=2, column=1) 112 | self.btn_ln = tk.Button(bottom_frame, **btn_params, text="ln", command=lambda: self.btn_click('log1p(')) 113 | self.btn_ln.grid(row=2, column=2) 114 | self.btn_sqrt = tk.Button(bottom_frame, **btn_params, text="sqrt", command=lambda: self.btn_click('sqrt(')) 115 | self.btn_sqrt.grid(row=2, column=3) 116 | self.btn_abs = tk.Button(bottom_frame, **btn_params, text="abs", command=lambda: self.btn_click('abs' + '(')) 117 | self.btn_abs.grid(row=2, column=4) 118 | self.btn_log = tk.Button(bottom_frame, **btn_params, text="log", command=lambda: self.btn_click('log(')) 119 | self.btn_log.grid(row=2, column=5) 120 | self.btn_4 = tk.Button(bottom_frame, **btn_params, text="4", command=lambda: self.btn_click(4)) 121 | self.btn_4.configure(activebackground="#343434", bg='#343434') 122 | self.btn_4.grid(row=2, column=6) 123 | self.btn_5 = tk.Button(bottom_frame, **btn_params, text="5", command=lambda: self.btn_click(5)) 124 | self.btn_5.configure(activebackground="#343434", bg='#343434') 125 | self.btn_5.grid(row=2, column=7) 126 | self.btn_6 = tk.Button(bottom_frame, **btn_params, text="6", command=lambda: self.btn_click(6)) 127 | self.btn_6.configure(activebackground="#343434", bg='#343434') 128 | self.btn_6.grid(row=2, column=8) 129 | self.btnSub = tk.Button(bottom_frame, **btn_params, text="-", command=lambda: self.btn_click('-')) 130 | self.btnSub.configure(activebackground="#FB9F10", bg='#FB9F10', foreground='#FFFFFF') 131 | self.btnSub.grid(row=2, column=9) 132 | self.btn_fact = tk.Button(bottom_frame, **btn_params, text="x!", command=lambda: self.btn_click('factorial(')) 133 | self.btn_fact.grid(row=3, column=0) 134 | self.btn_sin = tk.Button(bottom_frame, **btn_params, text="sin", command=lambda: self.btn_click('fsin(')) 135 | self.btn_sin.grid(row=3, column=1) 136 | self.btn_cos = tk.Button(bottom_frame, **btn_params, text="cos", command=lambda: self.btn_click('fcos(')) 137 | self.btn_cos.grid(row=3, column=2) 138 | self.btn_tan = tk.Button(bottom_frame, **btn_params, text="tan", command=lambda: self.btn_click('ftan(')) 139 | self.btn_tan.grid(row=3, column=3) 140 | self.btn_power = tk.Button(bottom_frame, **btn_params, text="e", command=lambda: self.btn_click('**')) 141 | self.btn_power.grid(row=3, column=4) 142 | self.btn_power = tk.Button(bottom_frame, **btn_params, text="EE", command=lambda: self.btn_click('**')) 143 | self.btn_power.grid(row=3, column=5) 144 | self.btn_1 = tk.Button(bottom_frame, **btn_params, text="1", command=lambda: self.btn_click(1)) 145 | self.btn_1.configure(activebackground="#343434", bg='#343434') 146 | self.btn_1.grid(row=3, column=6) 147 | self.btn_2 = tk.Button(bottom_frame, **btn_params, text="2", command=lambda: self.btn_click(2)) 148 | self.btn_2.configure(activebackground="#343434", bg='#343434') 149 | self.btn_2.grid(row=3, column=7) 150 | self.btn_3 = tk.Button(bottom_frame, **btn_params, text="3", command=lambda: self.btn_click(3)) 151 | self.btn_3.configure(activebackground="#343434", bg='#343434') 152 | self.btn_3.grid(row=3, column=8) 153 | self.btn_add = tk.Button(bottom_frame, **btn_params, text="+", command=lambda: self.btn_click('+')) 154 | self.btn_add.configure(activebackground="#FB9F10", bg='#FB9F10', foreground='#FFFFFF') 155 | self.btn_add.grid(row=3, column=9) 156 | self.btn_Rad = tk.Button(bottom_frame, **btn_params, text="Rad", command=self.convert_rad) 157 | self.btn_Rad.grid(row=4, column=0) 158 | self.btn_sin_inverse = tk.Button(bottom_frame, **btn_params, text=u"sin-\u00B9", command=lambda: self.btn_click('arcsin(')) 159 | self.btn_sin_inverse.grid(row=4, column=1) 160 | self.btn_cos_inverse = tk.Button(bottom_frame, **btn_params, text=u"cos-\u00B9", command=lambda: self.btn_click('arccos(')) 161 | self.btn_cos_inverse.grid(row=4, column=2) 162 | self.btn_tan_inverse = tk.Button(bottom_frame, **btn_params, text=u"tan-\u00B9", command=lambda: self.btn_click('arctan(')) 163 | self.btn_tan_inverse.grid(row=4, column=3) 164 | self.btn_pi = tk.Button(bottom_frame, **btn_params, text="π", command=lambda: self.btn_click('pi')) 165 | self.btn_pi.grid(row=4, column=4) 166 | self.btn_del = tk.Button(bottom_frame, **btn_params, text="Rand", command=self.btn_clear1) 167 | self.btn_del.grid(row=4, column=5) 168 | self.btn_0 = tk.Button(bottom_frame, **btn_params, text="0", command=lambda: self.btn_click(0)) 169 | self.btn_0.configure(activebackground="#343434", bg='#343434') 170 | self.btn_0.grid(row=4, column=6) 171 | self.btn_0 = tk.Button(bottom_frame, **btn_params, text=" ", command=lambda: self.btn_click(0)) 172 | self.btn_0.configure(activebackground="#343434", bg='#343434') 173 | self.btn_0.grid(row=4, column=7) 174 | self.btn_dec = tk.Button(bottom_frame, **btn_params, text=".", command=lambda: self.btn_click('.')) 175 | self.btn_dec.configure(activebackground="#343434", bg='#343434') 176 | self.btn_dec.grid(row=4, column=8) 177 | self.btn_eq = tk.Button(bottom_frame, **btn_params, text="=", command=self.btn_equal) 178 | self.btn_eq.configure(activebackground="#FB9F10", bg='#FB9F10', foreground='#FFFFFF') 179 | self.btn_eq.grid(row=4, column=9) 180 | 181 | def btn_click(self, expression_val): 182 | if len(self.expression) >= 23: 183 | self.expression = self.expression 184 | self.text_input.set(self.expression) 185 | else: 186 | self.expression = self.expression + str(expression_val) 187 | self.text_input.set(self.expression) 188 | 189 | def btn_clear1(self): 190 | self.expression = self.expression[:-1] 191 | self.text_input.set(self.expression) 192 | 193 | def change_signs(self): 194 | self.expression = self.expression + '-' 195 | self.text_input.set(self.expression) 196 | 197 | def memory_clear(self): 198 | self.recall = "" 199 | 200 | def memory_add(self): 201 | self.recall = self.recall + '+' + self.expression 202 | 203 | def answer(self): 204 | self.answer = self.sum_up 205 | self.expression = self.expression + self.answer 206 | self.text_input.set(self.expression) 207 | 208 | def memory_recall(self): 209 | if self.expression == "": 210 | self.text_input.set('0' + self.expression + self.recall) 211 | else: 212 | self.text_input.set(self.expression + self.recall) 213 | 214 | def convert_deg(self): 215 | global convert_constant 216 | global inverse_convert_constant 217 | convert_constant = pi / 180 218 | inverse_convert_constant = 180 / pi 219 | self.btn_Rad["foreground"] = 'white' 220 | self.btn_Deg["foreground"] = 'orange' 221 | 222 | def convert_rad(self): 223 | global convert_constant 224 | global inverse_convert_constant 225 | convert_constant = 1 226 | inverse_convert_constant = 1 227 | self.btn_Rad["foreground"] = 'orange' 228 | self.btn_Deg["foreground"] = 'white' 229 | 230 | def btn_clear_all(self): 231 | self.expression = "" 232 | self.text_input.set("") 233 | 234 | def btn_equal(self): 235 | self.sum_up = str(eval(self.expression)) 236 | self.text_input.set(self.sum_up) 237 | self.expression = self.sum_up 238 | 239 | 240 | root = tk.Tk() 241 | b = Calculator(root) 242 | root.title("Scientific Calculator by Mainak") 243 | root.iconbitmap('Calculator_37533.ico') 244 | root.geometry("723x465+50+50") 245 | root.resizable(False, False) 246 | root.mainloop() -------------------------------------------------------------------------------- /Scientific Calculator/Calc.spec: -------------------------------------------------------------------------------- 1 | # -*- mode: python ; coding: utf-8 -*- 2 | 3 | 4 | block_cipher = None 5 | 6 | 7 | a = Analysis(['Calc.py'], 8 | pathex=['C:\\Users\\maina\\Desktop\\Internships and Publications\\PyProj\\GUI Calc'], 9 | binaries=[], 10 | datas=[], 11 | hiddenimports=[], 12 | hookspath=[], 13 | hooksconfig={}, 14 | runtime_hooks=[], 15 | excludes=[], 16 | win_no_prefer_redirects=False, 17 | win_private_assemblies=False, 18 | cipher=block_cipher, 19 | noarchive=False) 20 | pyz = PYZ(a.pure, a.zipped_data, 21 | cipher=block_cipher) 22 | 23 | exe = EXE(pyz, 24 | a.scripts, 25 | a.binaries, 26 | a.zipfiles, 27 | a.datas, 28 | [], 29 | name='Calc', 30 | debug=False, 31 | bootloader_ignore_signals=False, 32 | strip=False, 33 | upx=True, 34 | upx_exclude=[], 35 | runtime_tmpdir=None, 36 | console=False, 37 | disable_windowed_traceback=False, 38 | target_arch=None, 39 | codesign_identity=None, 40 | entitlements_file=None ) 41 | -------------------------------------------------------------------------------- /Scientific Calculator/Calculator_37533.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Scientific Calculator/Calculator_37533.ico -------------------------------------------------------------------------------- /Scientific Calculator/__pycache__/Calc.cpython-39.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Scientific Calculator/__pycache__/Calc.cpython-39.pyc -------------------------------------------------------------------------------- /Scientific Calculator/build/Calc/Calc.exe.manifest: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | true 29 | 30 | 31 | -------------------------------------------------------------------------------- /Scientific Calculator/build/Calc/PKG-00.pkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Scientific Calculator/build/Calc/PKG-00.pkg -------------------------------------------------------------------------------- /Scientific Calculator/build/Calc/PYZ-00.pyz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Scientific Calculator/build/Calc/PYZ-00.pyz -------------------------------------------------------------------------------- /Scientific Calculator/build/Calc/PYZ-00.toc: -------------------------------------------------------------------------------- 1 | ('C:\\Users\\maina\\Desktop\\Internships and Publications\\PyProj\\GUI ' 2 | 'Calc\\build\\Calc\\PYZ-00.pyz', 3 | [('os', 4 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\os.py', 5 | 'PYMODULE'), 6 | ('subprocess', 7 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\subprocess.py', 8 | 'PYMODULE'), 9 | ('selectors', 10 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\selectors.py', 11 | 'PYMODULE'), 12 | ('contextlib', 13 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\contextlib.py', 14 | 'PYMODULE'), 15 | ('threading', 16 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\threading.py', 17 | 'PYMODULE'), 18 | ('_threading_local', 19 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\_threading_local.py', 20 | 'PYMODULE'), 21 | ('signal', 22 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\signal.py', 23 | 'PYMODULE'), 24 | ('_strptime', 25 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\_strptime.py', 26 | 'PYMODULE'), 27 | ('datetime', 28 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\datetime.py', 29 | 'PYMODULE'), 30 | ('calendar', 31 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\calendar.py', 32 | 'PYMODULE'), 33 | ('argparse', 34 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\argparse.py', 35 | 'PYMODULE'), 36 | ('textwrap', 37 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\textwrap.py', 38 | 'PYMODULE'), 39 | ('shutil', 40 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\shutil.py', 41 | 'PYMODULE'), 42 | ('zipfile', 43 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\zipfile.py', 44 | 'PYMODULE'), 45 | ('py_compile', 46 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\py_compile.py', 47 | 'PYMODULE'), 48 | ('importlib.machinery', 49 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\importlib\\machinery.py', 50 | 'PYMODULE'), 51 | ('importlib', 52 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\importlib\\__init__.py', 53 | 'PYMODULE'), 54 | ('importlib.abc', 55 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\importlib\\abc.py', 56 | 'PYMODULE'), 57 | ('typing', 58 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\typing.py', 59 | 'PYMODULE'), 60 | ('importlib._bootstrap', 61 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\importlib\\_bootstrap.py', 62 | 'PYMODULE'), 63 | ('importlib._bootstrap_external', 64 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\importlib\\_bootstrap_external.py', 65 | 'PYMODULE'), 66 | ('importlib.metadata', 67 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\importlib\\metadata.py', 68 | 'PYMODULE'), 69 | ('configparser', 70 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\configparser.py', 71 | 'PYMODULE'), 72 | ('pathlib', 73 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\pathlib.py', 74 | 'PYMODULE'), 75 | ('urllib.parse', 76 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\urllib\\parse.py', 77 | 'PYMODULE'), 78 | ('urllib', 79 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\urllib\\__init__.py', 80 | 'PYMODULE'), 81 | ('email', 82 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\__init__.py', 83 | 'PYMODULE'), 84 | ('email.parser', 85 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\parser.py', 86 | 'PYMODULE'), 87 | ('email._policybase', 88 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\_policybase.py', 89 | 'PYMODULE'), 90 | ('email.utils', 91 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\utils.py', 92 | 'PYMODULE'), 93 | ('email._parseaddr', 94 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\_parseaddr.py', 95 | 'PYMODULE'), 96 | ('socket', 97 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\socket.py', 98 | 'PYMODULE'), 99 | ('random', 100 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\random.py', 101 | 'PYMODULE'), 102 | ('statistics', 103 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\statistics.py', 104 | 'PYMODULE'), 105 | ('decimal', 106 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\decimal.py', 107 | 'PYMODULE'), 108 | ('_pydecimal', 109 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\_pydecimal.py', 110 | 'PYMODULE'), 111 | ('contextvars', 112 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\contextvars.py', 113 | 'PYMODULE'), 114 | ('fractions', 115 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\fractions.py', 116 | 'PYMODULE'), 117 | ('numbers', 118 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\numbers.py', 119 | 'PYMODULE'), 120 | ('hashlib', 121 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\hashlib.py', 122 | 'PYMODULE'), 123 | ('logging', 124 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\logging\\__init__.py', 125 | 'PYMODULE'), 126 | ('pickle', 127 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\pickle.py', 128 | 'PYMODULE'), 129 | ('pprint', 130 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\pprint.py', 131 | 'PYMODULE'), 132 | ('doctest', 133 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\doctest.py', 134 | 'PYMODULE'), 135 | ('unittest', 136 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\unittest\\__init__.py', 137 | 'PYMODULE'), 138 | ('unittest.async_case', 139 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\unittest\\async_case.py', 140 | 'PYMODULE'), 141 | ('asyncio', 142 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\__init__.py', 143 | 'PYMODULE'), 144 | ('asyncio.unix_events', 145 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\unix_events.py', 146 | 'PYMODULE'), 147 | ('asyncio.log', 148 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\log.py', 149 | 'PYMODULE'), 150 | ('asyncio.windows_events', 151 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\windows_events.py', 152 | 'PYMODULE'), 153 | ('asyncio.windows_utils', 154 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\windows_utils.py', 155 | 'PYMODULE'), 156 | ('tempfile', 157 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\tempfile.py', 158 | 'PYMODULE'), 159 | ('asyncio.selector_events', 160 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\selector_events.py', 161 | 'PYMODULE'), 162 | ('ssl', 163 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\ssl.py', 164 | 'PYMODULE'), 165 | ('base64', 166 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\base64.py', 167 | 'PYMODULE'), 168 | ('getopt', 169 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\getopt.py', 170 | 'PYMODULE'), 171 | ('asyncio.proactor_events', 172 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\proactor_events.py', 173 | 'PYMODULE'), 174 | ('asyncio.base_subprocess', 175 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\base_subprocess.py', 176 | 'PYMODULE'), 177 | ('asyncio.threads', 178 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\threads.py', 179 | 'PYMODULE'), 180 | ('asyncio.subprocess', 181 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\subprocess.py', 182 | 'PYMODULE'), 183 | ('asyncio.streams', 184 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\streams.py', 185 | 'PYMODULE'), 186 | ('asyncio.queues', 187 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\queues.py', 188 | 'PYMODULE'), 189 | ('asyncio.runners', 190 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\runners.py', 191 | 'PYMODULE'), 192 | ('asyncio.events', 193 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\events.py', 194 | 'PYMODULE'), 195 | ('asyncio.base_events', 196 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\base_events.py', 197 | 'PYMODULE'), 198 | ('concurrent.futures', 199 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\concurrent\\futures\\__init__.py', 200 | 'PYMODULE'), 201 | ('concurrent.futures.thread', 202 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\concurrent\\futures\\thread.py', 203 | 'PYMODULE'), 204 | ('queue', 205 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\queue.py', 206 | 'PYMODULE'), 207 | ('concurrent.futures.process', 208 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\concurrent\\futures\\process.py', 209 | 'PYMODULE'), 210 | ('multiprocessing.queues', 211 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\queues.py', 212 | 'PYMODULE'), 213 | ('multiprocessing.synchronize', 214 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\synchronize.py', 215 | 'PYMODULE'), 216 | ('multiprocessing.heap', 217 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\heap.py', 218 | 'PYMODULE'), 219 | ('multiprocessing.resource_tracker', 220 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\resource_tracker.py', 221 | 'PYMODULE'), 222 | ('multiprocessing.spawn', 223 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\spawn.py', 224 | 'PYMODULE'), 225 | ('runpy', 226 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\runpy.py', 227 | 'PYMODULE'), 228 | ('pkgutil', 229 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\pkgutil.py', 230 | 'PYMODULE'), 231 | ('zipimport', 232 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\zipimport.py', 233 | 'PYMODULE'), 234 | ('multiprocessing.process', 235 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\process.py', 236 | 'PYMODULE'), 237 | ('multiprocessing.util', 238 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\util.py', 239 | 'PYMODULE'), 240 | ('multiprocessing.forkserver', 241 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\forkserver.py', 242 | 'PYMODULE'), 243 | ('multiprocessing.context', 244 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\context.py', 245 | 'PYMODULE'), 246 | ('multiprocessing.popen_spawn_win32', 247 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\popen_spawn_win32.py', 248 | 'PYMODULE'), 249 | ('multiprocessing.popen_forkserver', 250 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\popen_forkserver.py', 251 | 'PYMODULE'), 252 | ('multiprocessing.popen_spawn_posix', 253 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\popen_spawn_posix.py', 254 | 'PYMODULE'), 255 | ('multiprocessing.popen_fork', 256 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\popen_fork.py', 257 | 'PYMODULE'), 258 | ('multiprocessing.sharedctypes', 259 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\sharedctypes.py', 260 | 'PYMODULE'), 261 | ('ctypes', 262 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\ctypes\\__init__.py', 263 | 'PYMODULE'), 264 | ('ctypes._endian', 265 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\ctypes\\_endian.py', 266 | 'PYMODULE'), 267 | ('multiprocessing.pool', 268 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\pool.py', 269 | 'PYMODULE'), 270 | ('multiprocessing.dummy', 271 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\dummy\\__init__.py', 272 | 'PYMODULE'), 273 | ('multiprocessing.dummy.connection', 274 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\dummy\\connection.py', 275 | 'PYMODULE'), 276 | ('multiprocessing.managers', 277 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\managers.py', 278 | 'PYMODULE'), 279 | ('multiprocessing.shared_memory', 280 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\shared_memory.py', 281 | 'PYMODULE'), 282 | ('secrets', 283 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\secrets.py', 284 | 'PYMODULE'), 285 | ('hmac', 286 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\hmac.py', 287 | 'PYMODULE'), 288 | ('multiprocessing.reduction', 289 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\reduction.py', 290 | 'PYMODULE'), 291 | ('multiprocessing.resource_sharer', 292 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\resource_sharer.py', 293 | 'PYMODULE'), 294 | ('multiprocessing.connection', 295 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\connection.py', 296 | 'PYMODULE'), 297 | ('xmlrpc.client', 298 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\xmlrpc\\client.py', 299 | 'PYMODULE'), 300 | ('xmlrpc', 301 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\xmlrpc\\__init__.py', 302 | 'PYMODULE'), 303 | ('gzip', 304 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\gzip.py', 305 | 'PYMODULE'), 306 | ('_compression', 307 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\_compression.py', 308 | 'PYMODULE'), 309 | ('xml.parsers.expat', 310 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\xml\\parsers\\expat.py', 311 | 'PYMODULE'), 312 | ('xml.parsers', 313 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\xml\\parsers\\__init__.py', 314 | 'PYMODULE'), 315 | ('xml', 316 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\xml\\__init__.py', 317 | 'PYMODULE'), 318 | ('xml.sax.expatreader', 319 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\xml\\sax\\expatreader.py', 320 | 'PYMODULE'), 321 | ('xml.sax.saxutils', 322 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\xml\\sax\\saxutils.py', 323 | 'PYMODULE'), 324 | ('urllib.request', 325 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\urllib\\request.py', 326 | 'PYMODULE'), 327 | ('getpass', 328 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\getpass.py', 329 | 'PYMODULE'), 330 | ('nturl2path', 331 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\nturl2path.py', 332 | 'PYMODULE'), 333 | ('ftplib', 334 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\ftplib.py', 335 | 'PYMODULE'), 336 | ('netrc', 337 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\netrc.py', 338 | 'PYMODULE'), 339 | ('shlex', 340 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\shlex.py', 341 | 'PYMODULE'), 342 | ('mimetypes', 343 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\mimetypes.py', 344 | 'PYMODULE'), 345 | ('http.cookiejar', 346 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\http\\cookiejar.py', 347 | 'PYMODULE'), 348 | ('http', 349 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\http\\__init__.py', 350 | 'PYMODULE'), 351 | ('urllib.response', 352 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\urllib\\response.py', 353 | 'PYMODULE'), 354 | ('urllib.error', 355 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\urllib\\error.py', 356 | 'PYMODULE'), 357 | ('xml.sax', 358 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\xml\\sax\\__init__.py', 359 | 'PYMODULE'), 360 | ('xml.sax.handler', 361 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\xml\\sax\\handler.py', 362 | 'PYMODULE'), 363 | ('xml.sax._exceptions', 364 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\xml\\sax\\_exceptions.py', 365 | 'PYMODULE'), 366 | ('xml.sax.xmlreader', 367 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\xml\\sax\\xmlreader.py', 368 | 'PYMODULE'), 369 | ('http.client', 370 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\http\\client.py', 371 | 'PYMODULE'), 372 | ('email.message', 373 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\message.py', 374 | 'PYMODULE'), 375 | ('email.policy', 376 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\policy.py', 377 | 'PYMODULE'), 378 | ('email.contentmanager', 379 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\contentmanager.py', 380 | 'PYMODULE'), 381 | ('email.quoprimime', 382 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\quoprimime.py', 383 | 'PYMODULE'), 384 | ('email.headerregistry', 385 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\headerregistry.py', 386 | 'PYMODULE'), 387 | ('email.iterators', 388 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\iterators.py', 389 | 'PYMODULE'), 390 | ('email.generator', 391 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\generator.py', 392 | 'PYMODULE'), 393 | ('email._encoded_words', 394 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\_encoded_words.py', 395 | 'PYMODULE'), 396 | ('quopri', 397 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\quopri.py', 398 | 'PYMODULE'), 399 | ('uu', 400 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\uu.py', 401 | 'PYMODULE'), 402 | ('optparse', 403 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\optparse.py', 404 | 'PYMODULE'), 405 | ('multiprocessing', 406 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\multiprocessing\\__init__.py', 407 | 'PYMODULE'), 408 | ('concurrent.futures._base', 409 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\concurrent\\futures\\_base.py', 410 | 'PYMODULE'), 411 | ('concurrent', 412 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\concurrent\\__init__.py', 413 | 'PYMODULE'), 414 | ('asyncio.trsock', 415 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\trsock.py', 416 | 'PYMODULE'), 417 | ('asyncio.staggered', 418 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\staggered.py', 419 | 'PYMODULE'), 420 | ('asyncio.tasks', 421 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\tasks.py', 422 | 'PYMODULE'), 423 | ('asyncio.base_tasks', 424 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\base_tasks.py', 425 | 'PYMODULE'), 426 | ('asyncio.locks', 427 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\locks.py', 428 | 'PYMODULE'), 429 | ('asyncio.sslproto', 430 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\sslproto.py', 431 | 'PYMODULE'), 432 | ('asyncio.transports', 433 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\transports.py', 434 | 'PYMODULE'), 435 | ('asyncio.protocols', 436 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\protocols.py', 437 | 'PYMODULE'), 438 | ('asyncio.futures', 439 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\futures.py', 440 | 'PYMODULE'), 441 | ('asyncio.exceptions', 442 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\exceptions.py', 443 | 'PYMODULE'), 444 | ('asyncio.coroutines', 445 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\coroutines.py', 446 | 'PYMODULE'), 447 | ('asyncio.base_futures', 448 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\base_futures.py', 449 | 'PYMODULE'), 450 | ('asyncio.format_helpers', 451 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\format_helpers.py', 452 | 'PYMODULE'), 453 | ('asyncio.constants', 454 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\asyncio\\constants.py', 455 | 'PYMODULE'), 456 | ('unittest.signals', 457 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\unittest\\signals.py', 458 | 'PYMODULE'), 459 | ('unittest.main', 460 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\unittest\\main.py', 461 | 'PYMODULE'), 462 | ('unittest.runner', 463 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\unittest\\runner.py', 464 | 'PYMODULE'), 465 | ('unittest.loader', 466 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\unittest\\loader.py', 467 | 'PYMODULE'), 468 | ('unittest.suite', 469 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\unittest\\suite.py', 470 | 'PYMODULE'), 471 | ('unittest.case', 472 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\unittest\\case.py', 473 | 'PYMODULE'), 474 | ('unittest._log', 475 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\unittest\\_log.py', 476 | 'PYMODULE'), 477 | ('unittest.result', 478 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\unittest\\result.py', 479 | 'PYMODULE'), 480 | ('unittest.util', 481 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\unittest\\util.py', 482 | 'PYMODULE'), 483 | ('pdb', 484 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\pdb.py', 485 | 'PYMODULE'), 486 | ('pydoc', 487 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\pydoc.py', 488 | 'PYMODULE'), 489 | ('webbrowser', 490 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\webbrowser.py', 491 | 'PYMODULE'), 492 | ('http.server', 493 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\http\\server.py', 494 | 'PYMODULE'), 495 | ('socketserver', 496 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\socketserver.py', 497 | 'PYMODULE'), 498 | ('html', 499 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\html\\__init__.py', 500 | 'PYMODULE'), 501 | ('html.entities', 502 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\html\\entities.py', 503 | 'PYMODULE'), 504 | ('pydoc_data.topics', 505 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\pydoc_data\\topics.py', 506 | 'PYMODULE'), 507 | ('pydoc_data', 508 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\pydoc_data\\__init__.py', 509 | 'PYMODULE'), 510 | ('tty', 511 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\tty.py', 512 | 'PYMODULE'), 513 | ('sysconfig', 514 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\sysconfig.py', 515 | 'PYMODULE'), 516 | ('_aix_support', 517 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\_aix_support.py', 518 | 'PYMODULE'), 519 | ('_bootsubprocess', 520 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\_bootsubprocess.py', 521 | 'PYMODULE'), 522 | ('_osx_support', 523 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\_osx_support.py', 524 | 'PYMODULE'), 525 | ('distutils.log', 526 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\distutils\\log.py', 527 | 'PYMODULE'), 528 | ('distutils', 529 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\distutils\\__init__.py', 530 | 'PYMODULE'), 531 | ('distutils.ccompiler', 532 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\distutils\\ccompiler.py', 533 | 'PYMODULE'), 534 | ('distutils.fancy_getopt', 535 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\distutils\\fancy_getopt.py', 536 | 'PYMODULE'), 537 | ('distutils.debug', 538 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\distutils\\debug.py', 539 | 'PYMODULE'), 540 | ('distutils.util', 541 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\distutils\\util.py', 542 | 'PYMODULE'), 543 | ('distutils.filelist', 544 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\distutils\\filelist.py', 545 | 'PYMODULE'), 546 | ('distutils.dep_util', 547 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\distutils\\dep_util.py', 548 | 'PYMODULE'), 549 | ('distutils.dir_util', 550 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\distutils\\dir_util.py', 551 | 'PYMODULE'), 552 | ('distutils.file_util', 553 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\distutils\\file_util.py', 554 | 'PYMODULE'), 555 | ('distutils.spawn', 556 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\distutils\\spawn.py', 557 | 'PYMODULE'), 558 | ('distutils.errors', 559 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\distutils\\errors.py', 560 | 'PYMODULE'), 561 | ('distutils.sysconfig', 562 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\distutils\\sysconfig.py', 563 | 'PYMODULE'), 564 | ('distutils.text_file', 565 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\distutils\\text_file.py', 566 | 'PYMODULE'), 567 | ('platform', 568 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\platform.py', 569 | 'PYMODULE'), 570 | ('plistlib', 571 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\plistlib.py', 572 | 'PYMODULE'), 573 | ('glob', 574 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\glob.py', 575 | 'PYMODULE'), 576 | ('code', 577 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\code.py', 578 | 'PYMODULE'), 579 | ('codeop', 580 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\codeop.py', 581 | 'PYMODULE'), 582 | ('dis', 583 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\dis.py', 584 | 'PYMODULE'), 585 | ('opcode', 586 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\opcode.py', 587 | 'PYMODULE'), 588 | ('bdb', 589 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\bdb.py', 590 | 'PYMODULE'), 591 | ('cmd', 592 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\cmd.py', 593 | 'PYMODULE'), 594 | ('inspect', 595 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\inspect.py', 596 | 'PYMODULE'), 597 | ('token', 598 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\token.py', 599 | 'PYMODULE'), 600 | ('ast', 601 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\ast.py', 602 | 'PYMODULE'), 603 | ('difflib', 604 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\difflib.py', 605 | 'PYMODULE'), 606 | ('__future__', 607 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\__future__.py', 608 | 'PYMODULE'), 609 | ('_compat_pickle', 610 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\_compat_pickle.py', 611 | 'PYMODULE'), 612 | ('string', 613 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\string.py', 614 | 'PYMODULE'), 615 | ('bisect', 616 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\bisect.py', 617 | 'PYMODULE'), 618 | ('email.feedparser', 619 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\feedparser.py', 620 | 'PYMODULE'), 621 | ('email._header_value_parser', 622 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\_header_value_parser.py', 623 | 'PYMODULE'), 624 | ('email.header', 625 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\header.py', 626 | 'PYMODULE'), 627 | ('email.base64mime', 628 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\base64mime.py', 629 | 'PYMODULE'), 630 | ('email.charset', 631 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\charset.py', 632 | 'PYMODULE'), 633 | ('email.encoders', 634 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\encoders.py', 635 | 'PYMODULE'), 636 | ('email.errors', 637 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\email\\errors.py', 638 | 'PYMODULE'), 639 | ('csv', 640 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\csv.py', 641 | 'PYMODULE'), 642 | ('tokenize', 643 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\tokenize.py', 644 | 'PYMODULE'), 645 | ('struct', 646 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\struct.py', 647 | 'PYMODULE'), 648 | ('importlib.util', 649 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\importlib\\util.py', 650 | 'PYMODULE'), 651 | ('tarfile', 652 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\tarfile.py', 653 | 'PYMODULE'), 654 | ('lzma', 655 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\lzma.py', 656 | 'PYMODULE'), 657 | ('bz2', 658 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\bz2.py', 659 | 'PYMODULE'), 660 | ('fnmatch', 661 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\fnmatch.py', 662 | 'PYMODULE'), 663 | ('copy', 664 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\copy.py', 665 | 'PYMODULE'), 666 | ('gettext', 667 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\gettext.py', 668 | 'PYMODULE'), 669 | ('ntpath', 670 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\ntpath.py', 671 | 'PYMODULE'), 672 | ('genericpath', 673 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\genericpath.py', 674 | 'PYMODULE'), 675 | ('posixpath', 676 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\posixpath.py', 677 | 'PYMODULE'), 678 | ('stat', 679 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\stat.py', 680 | 'PYMODULE'), 681 | ('stringprep', 682 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\stringprep.py', 683 | 'PYMODULE'), 684 | ('_py_abc', 685 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\_py_abc.py', 686 | 'PYMODULE'), 687 | ('tracemalloc', 688 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\tracemalloc.py', 689 | 'PYMODULE'), 690 | ('tkinter', 691 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\tkinter\\__init__.py', 692 | 'PYMODULE'), 693 | ('tkinter.constants', 694 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\lib\\tkinter\\constants.py', 695 | 'PYMODULE')]) 696 | -------------------------------------------------------------------------------- /Scientific Calculator/build/Calc/Tree-01.toc: -------------------------------------------------------------------------------- 1 | ('c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6', 2 | 'tk', 3 | ['demos', '*.lib', 'tkConfig.sh'], 4 | 'DATA', 5 | [('tk\\bgerror.tcl', 6 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\bgerror.tcl', 7 | 'DATA'), 8 | ('tk\\button.tcl', 9 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\button.tcl', 10 | 'DATA'), 11 | ('tk\\choosedir.tcl', 12 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\choosedir.tcl', 13 | 'DATA'), 14 | ('tk\\clrpick.tcl', 15 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\clrpick.tcl', 16 | 'DATA'), 17 | ('tk\\comdlg.tcl', 18 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\comdlg.tcl', 19 | 'DATA'), 20 | ('tk\\console.tcl', 21 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\console.tcl', 22 | 'DATA'), 23 | ('tk\\dialog.tcl', 24 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\dialog.tcl', 25 | 'DATA'), 26 | ('tk\\entry.tcl', 27 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\entry.tcl', 28 | 'DATA'), 29 | ('tk\\focus.tcl', 30 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\focus.tcl', 31 | 'DATA'), 32 | ('tk\\fontchooser.tcl', 33 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\fontchooser.tcl', 34 | 'DATA'), 35 | ('tk\\iconlist.tcl', 36 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\iconlist.tcl', 37 | 'DATA'), 38 | ('tk\\icons.tcl', 39 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\icons.tcl', 40 | 'DATA'), 41 | ('tk\\license.terms', 42 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\license.terms', 43 | 'DATA'), 44 | ('tk\\listbox.tcl', 45 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\listbox.tcl', 46 | 'DATA'), 47 | ('tk\\megawidget.tcl', 48 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\megawidget.tcl', 49 | 'DATA'), 50 | ('tk\\menu.tcl', 51 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\menu.tcl', 52 | 'DATA'), 53 | ('tk\\mkpsenc.tcl', 54 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\mkpsenc.tcl', 55 | 'DATA'), 56 | ('tk\\msgbox.tcl', 57 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\msgbox.tcl', 58 | 'DATA'), 59 | ('tk\\obsolete.tcl', 60 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\obsolete.tcl', 61 | 'DATA'), 62 | ('tk\\optMenu.tcl', 63 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\optMenu.tcl', 64 | 'DATA'), 65 | ('tk\\palette.tcl', 66 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\palette.tcl', 67 | 'DATA'), 68 | ('tk\\panedwindow.tcl', 69 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\panedwindow.tcl', 70 | 'DATA'), 71 | ('tk\\pkgIndex.tcl', 72 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\pkgIndex.tcl', 73 | 'DATA'), 74 | ('tk\\safetk.tcl', 75 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\safetk.tcl', 76 | 'DATA'), 77 | ('tk\\scale.tcl', 78 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\scale.tcl', 79 | 'DATA'), 80 | ('tk\\scrlbar.tcl', 81 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\scrlbar.tcl', 82 | 'DATA'), 83 | ('tk\\spinbox.tcl', 84 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\spinbox.tcl', 85 | 'DATA'), 86 | ('tk\\tclIndex', 87 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\tclIndex', 88 | 'DATA'), 89 | ('tk\\tearoff.tcl', 90 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\tearoff.tcl', 91 | 'DATA'), 92 | ('tk\\text.tcl', 93 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\text.tcl', 94 | 'DATA'), 95 | ('tk\\tk.tcl', 96 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\tk.tcl', 97 | 'DATA'), 98 | ('tk\\tkfbox.tcl', 99 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\tkfbox.tcl', 100 | 'DATA'), 101 | ('tk\\unsupported.tcl', 102 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\unsupported.tcl', 103 | 'DATA'), 104 | ('tk\\xmfbox.tcl', 105 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\xmfbox.tcl', 106 | 'DATA'), 107 | ('tk\\ttk\\altTheme.tcl', 108 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\altTheme.tcl', 109 | 'DATA'), 110 | ('tk\\ttk\\aquaTheme.tcl', 111 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\aquaTheme.tcl', 112 | 'DATA'), 113 | ('tk\\ttk\\button.tcl', 114 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\button.tcl', 115 | 'DATA'), 116 | ('tk\\ttk\\clamTheme.tcl', 117 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\clamTheme.tcl', 118 | 'DATA'), 119 | ('tk\\ttk\\classicTheme.tcl', 120 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\classicTheme.tcl', 121 | 'DATA'), 122 | ('tk\\ttk\\combobox.tcl', 123 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\combobox.tcl', 124 | 'DATA'), 125 | ('tk\\ttk\\cursors.tcl', 126 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\cursors.tcl', 127 | 'DATA'), 128 | ('tk\\ttk\\defaults.tcl', 129 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\defaults.tcl', 130 | 'DATA'), 131 | ('tk\\ttk\\entry.tcl', 132 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\entry.tcl', 133 | 'DATA'), 134 | ('tk\\ttk\\fonts.tcl', 135 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\fonts.tcl', 136 | 'DATA'), 137 | ('tk\\ttk\\menubutton.tcl', 138 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\menubutton.tcl', 139 | 'DATA'), 140 | ('tk\\ttk\\notebook.tcl', 141 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\notebook.tcl', 142 | 'DATA'), 143 | ('tk\\ttk\\panedwindow.tcl', 144 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\panedwindow.tcl', 145 | 'DATA'), 146 | ('tk\\ttk\\progress.tcl', 147 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\progress.tcl', 148 | 'DATA'), 149 | ('tk\\ttk\\scale.tcl', 150 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\scale.tcl', 151 | 'DATA'), 152 | ('tk\\ttk\\scrollbar.tcl', 153 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\scrollbar.tcl', 154 | 'DATA'), 155 | ('tk\\ttk\\sizegrip.tcl', 156 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\sizegrip.tcl', 157 | 'DATA'), 158 | ('tk\\ttk\\spinbox.tcl', 159 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\spinbox.tcl', 160 | 'DATA'), 161 | ('tk\\ttk\\treeview.tcl', 162 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\treeview.tcl', 163 | 'DATA'), 164 | ('tk\\ttk\\ttk.tcl', 165 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\ttk.tcl', 166 | 'DATA'), 167 | ('tk\\ttk\\utils.tcl', 168 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\utils.tcl', 169 | 'DATA'), 170 | ('tk\\ttk\\vistaTheme.tcl', 171 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\vistaTheme.tcl', 172 | 'DATA'), 173 | ('tk\\ttk\\winTheme.tcl', 174 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\winTheme.tcl', 175 | 'DATA'), 176 | ('tk\\ttk\\xpTheme.tcl', 177 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\ttk\\xpTheme.tcl', 178 | 'DATA'), 179 | ('tk\\msgs\\cs.msg', 180 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\msgs\\cs.msg', 181 | 'DATA'), 182 | ('tk\\msgs\\da.msg', 183 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\msgs\\da.msg', 184 | 'DATA'), 185 | ('tk\\msgs\\de.msg', 186 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\msgs\\de.msg', 187 | 'DATA'), 188 | ('tk\\msgs\\el.msg', 189 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\msgs\\el.msg', 190 | 'DATA'), 191 | ('tk\\msgs\\en.msg', 192 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\msgs\\en.msg', 193 | 'DATA'), 194 | ('tk\\msgs\\en_gb.msg', 195 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\msgs\\en_gb.msg', 196 | 'DATA'), 197 | ('tk\\msgs\\eo.msg', 198 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\msgs\\eo.msg', 199 | 'DATA'), 200 | ('tk\\msgs\\es.msg', 201 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\msgs\\es.msg', 202 | 'DATA'), 203 | ('tk\\msgs\\fr.msg', 204 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\msgs\\fr.msg', 205 | 'DATA'), 206 | ('tk\\msgs\\hu.msg', 207 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\msgs\\hu.msg', 208 | 'DATA'), 209 | ('tk\\msgs\\it.msg', 210 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\msgs\\it.msg', 211 | 'DATA'), 212 | ('tk\\msgs\\nl.msg', 213 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\msgs\\nl.msg', 214 | 'DATA'), 215 | ('tk\\msgs\\pl.msg', 216 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\msgs\\pl.msg', 217 | 'DATA'), 218 | ('tk\\msgs\\pt.msg', 219 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\msgs\\pt.msg', 220 | 'DATA'), 221 | ('tk\\msgs\\ru.msg', 222 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\msgs\\ru.msg', 223 | 'DATA'), 224 | ('tk\\msgs\\sv.msg', 225 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\msgs\\sv.msg', 226 | 'DATA'), 227 | ('tk\\images\\logo.eps', 228 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\images\\logo.eps', 229 | 'DATA'), 230 | ('tk\\images\\logo100.gif', 231 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\images\\logo100.gif', 232 | 'DATA'), 233 | ('tk\\images\\logo64.gif', 234 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\images\\logo64.gif', 235 | 'DATA'), 236 | ('tk\\images\\logoLarge.gif', 237 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\images\\logoLarge.gif', 238 | 'DATA'), 239 | ('tk\\images\\logoMed.gif', 240 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\images\\logoMed.gif', 241 | 'DATA'), 242 | ('tk\\images\\pwrdLogo.eps', 243 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\images\\pwrdLogo.eps', 244 | 'DATA'), 245 | ('tk\\images\\pwrdLogo100.gif', 246 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\images\\pwrdLogo100.gif', 247 | 'DATA'), 248 | ('tk\\images\\pwrdLogo150.gif', 249 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\images\\pwrdLogo150.gif', 250 | 'DATA'), 251 | ('tk\\images\\pwrdLogo175.gif', 252 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\images\\pwrdLogo175.gif', 253 | 'DATA'), 254 | ('tk\\images\\pwrdLogo200.gif', 255 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\images\\pwrdLogo200.gif', 256 | 'DATA'), 257 | ('tk\\images\\pwrdLogo75.gif', 258 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\images\\pwrdLogo75.gif', 259 | 'DATA'), 260 | ('tk\\images\\README', 261 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\images\\README', 262 | 'DATA'), 263 | ('tk\\images\\tai-ku.gif', 264 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tk8.6\\images\\tai-ku.gif', 265 | 'DATA')]) 266 | -------------------------------------------------------------------------------- /Scientific Calculator/build/Calc/Tree-02.toc: -------------------------------------------------------------------------------- 1 | ('c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tcl8.6\\..\\tcl8', 2 | 'tcl8', 3 | [], 4 | 'DATA', 5 | [('tcl8\\8.6\\http-2.9.0.tm', 6 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tcl8.6\\..\\tcl8\\8.6\\http-2.9.0.tm', 7 | 'DATA'), 8 | ('tcl8\\8.5\\msgcat-1.6.1.tm', 9 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tcl8.6\\..\\tcl8\\8.5\\msgcat-1.6.1.tm', 10 | 'DATA'), 11 | ('tcl8\\8.5\\tcltest-2.5.0.tm', 12 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tcl8.6\\..\\tcl8\\8.5\\tcltest-2.5.0.tm', 13 | 'DATA'), 14 | ('tcl8\\8.4\\platform-1.0.14.tm', 15 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tcl8.6\\..\\tcl8\\8.4\\platform-1.0.14.tm', 16 | 'DATA'), 17 | ('tcl8\\8.4\\platform\\shell-1.1.4.tm', 18 | 'c:\\users\\maina\\appdata\\local\\programs\\python\\python39\\tcl\\tcl8.6\\..\\tcl8\\8.4\\platform\\shell-1.1.4.tm', 19 | 'DATA')]) 20 | -------------------------------------------------------------------------------- /Scientific Calculator/build/Calc/base_library.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Scientific Calculator/build/Calc/base_library.zip -------------------------------------------------------------------------------- /Scientific Calculator/build/Calc/warn-Calc.txt: -------------------------------------------------------------------------------- 1 | 2 | This file lists modules PyInstaller was not able to find. This does not 3 | necessarily mean this module is required for running you program. Python and 4 | Python 3rd-party packages include a lot of conditional or optional modules. For 5 | example the module 'ntpath' only exists on Windows, whereas the module 6 | 'posixpath' only exists on Posix systems. 7 | 8 | Types if import: 9 | * top-level: imported at the top-level - look at these first 10 | * conditional: imported within an if-statement 11 | * delayed: imported from within a function 12 | * optional: imported within a try-except-statement 13 | 14 | IMPORTANT: Do NOT post this list to the issue-tracker. Use it as a basis for 15 | yourself tracking down the missing module. Thanks! 16 | 17 | missing module named _posixsubprocess - imported by multiprocessing.util (delayed), subprocess (optional) 18 | missing module named grp - imported by shutil (optional), tarfile (optional), pathlib (delayed, optional), subprocess (optional) 19 | missing module named pwd - imported by posixpath (delayed, conditional), shutil (optional), tarfile (optional), pathlib (delayed, conditional, optional), http.server (delayed, optional), webbrowser (delayed), netrc (delayed, conditional), getpass (delayed), distutils.util (delayed, conditional, optional), subprocess (optional) 20 | missing module named _frozen_importlib_external - imported by importlib._bootstrap (delayed), importlib (optional), importlib.abc (optional), zipimport (top-level) 21 | excluded module named _frozen_importlib - imported by importlib (optional), importlib.abc (optional), zipimport (top-level) 22 | missing module named pep517 - imported by importlib.metadata (delayed) 23 | missing module named _posixshmem - imported by multiprocessing.resource_tracker (conditional), multiprocessing.shared_memory (conditional) 24 | missing module named multiprocessing.set_start_method - imported by multiprocessing (top-level), multiprocessing.spawn (top-level) 25 | missing module named multiprocessing.get_start_method - imported by multiprocessing (top-level), multiprocessing.spawn (top-level) 26 | missing module named multiprocessing.get_context - imported by multiprocessing (top-level), multiprocessing.pool (top-level), multiprocessing.managers (top-level), multiprocessing.sharedctypes (top-level) 27 | missing module named multiprocessing.TimeoutError - imported by multiprocessing (top-level), multiprocessing.pool (top-level) 28 | missing module named _scproxy - imported by urllib.request (conditional) 29 | missing module named termios - imported by tty (top-level), getpass (optional) 30 | missing module named 'org.python' - imported by copy (optional), xml.sax (delayed, conditional) 31 | missing module named 'java.lang' - imported by platform (delayed, optional), xml.sax._exceptions (conditional) 32 | missing module named multiprocessing.BufferTooShort - imported by multiprocessing (top-level), multiprocessing.connection (top-level) 33 | missing module named multiprocessing.AuthenticationError - imported by multiprocessing (top-level), multiprocessing.connection (top-level) 34 | missing module named asyncio.DefaultEventLoopPolicy - imported by asyncio (delayed, conditional), asyncio.events (delayed, conditional) 35 | missing module named vms_lib - imported by platform (delayed, optional) 36 | missing module named java - imported by platform (delayed) 37 | missing module named _winreg - imported by platform (delayed, optional) 38 | missing module named readline - imported by cmd (delayed, conditional, optional), code (delayed, conditional, optional), pdb (delayed, optional) 39 | missing module named org - imported by pickle (optional) 40 | missing module named posix - imported by os (conditional, optional), shutil (conditional), importlib._bootstrap_external (conditional) 41 | missing module named resource - imported by posix (top-level), test.support (delayed, conditional, optional) 42 | missing module named pyimod03_importers - imported by C:\Users\maina\AppData\Local\Programs\Python\Python39\Lib\site-packages\PyInstaller\hooks\rthooks\pyi_rth_pkgutil.py (top-level) 43 | -------------------------------------------------------------------------------- /Scientific Calculator/calc-ss.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Scientific Calculator/calc-ss.jpg -------------------------------------------------------------------------------- /Scientific Calculator/dist/Calc.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Scientific Calculator/dist/Calc.exe -------------------------------------------------------------------------------- /Scientific Calculator/scientific calculator.py: -------------------------------------------------------------------------------- 1 | import tkinter as tk 2 | from math import * 3 | 4 | convert_constant = 1 5 | inverse_convert_constant = 1 6 | 7 | btn_params = { 8 | 'padx': 16, 9 | 'pady': 1, 10 | 'bd': 4, 11 | 'fg': '#F0F8FF', 12 | 'bg': 'gray12', 13 | 'font': ('arial', 18), 14 | 'width': 2, 15 | 'height': 2, 16 | 'relief': 'flat', 17 | 'activebackground': 'gray12' 18 | } 19 | 20 | 21 | def fsin(arg): 22 | return sin(arg * convert_constant) 23 | 24 | 25 | def fcos(arg): 26 | return cos(arg * convert_constant) 27 | 28 | 29 | def ftan(arg): 30 | return tan(arg * convert_constant) 31 | 32 | 33 | def arcsin(arg): 34 | return inverse_convert_constant * (asin(arg)) 35 | 36 | 37 | def arccos(arg): 38 | return inverse_convert_constant * (acos(arg)) 39 | 40 | 41 | def arctan(arg): 42 | return inverse_convert_constant * (atan(arg)) 43 | 44 | 45 | class Calculator: 46 | def __init__(self, master): 47 | self.expression = "" 48 | self.recall = "" 49 | self.sum_up = "" 50 | self.text_input = tk.StringVar() 51 | self.master = master 52 | top_frame = tk.Frame(master, width=650, height=20, bd=4, relief='flat', bg='gray4') 53 | top_frame.pack(side=tk.TOP) 54 | bottom_frame = tk.Frame(master, width=650, height=470, bd=2, relief='flat', bg='gray4') 55 | bottom_frame.pack(side=tk.BOTTOM) 56 | txt_display = tk.Entry(top_frame, font=('arial', 36), relief='flat', 57 | bg='#222222', fg='#FFFFFF', textvariable=self.text_input, width=60, bd=4, justify='right') 58 | txt_display.pack() 59 | 60 | self.btn_left_brack = tk.Button(bottom_frame, **btn_params, text="(", command=lambda: self.btn_click('(')) 61 | self.btn_left_brack.grid(row=0, column=0) 62 | self.btn_right_brack = tk.Button(bottom_frame, **btn_params, text=")", command=lambda: self.btn_click(')')) 63 | self.btn_right_brack.grid(row=0, column=1) 64 | self.btn_MC = tk.Button(bottom_frame, **btn_params, text="mc", command=self.memory_clear) 65 | self.btn_MC.grid(row=0, column=2) 66 | self.btn_M_plus = tk.Button(bottom_frame, **btn_params, text="m+", command=self.memory_add) 67 | self.btn_M_plus.grid(row=0, column=3) 68 | self.btn_M_plus = tk.Button(bottom_frame, **btn_params, text="m-", command=self.memory_add) 69 | self.btn_M_plus.grid(row=0, column=4) 70 | self.btn_MR = tk.Button(bottom_frame, **btn_params, text="mr", command=self.memory_recall) 71 | self.btn_MR.grid(row=0, column=5) 72 | self.btn_clear = tk.Button(bottom_frame, **btn_params, text="AC", command=self.btn_clear_all) 73 | self.btn_clear.configure(activebackground="#A5A5A5", bg='#A5A5A5', foreground='black') 74 | self.btn_clear.grid(row=0, column=6) 75 | self.btn_change_sign = tk.Button(bottom_frame, **btn_params, text="+/-", command=self.change_signs) 76 | self.btn_change_sign.configure(activebackground="#A5A5A5", bg='#A5A5A5', foreground='black') 77 | self.btn_change_sign.grid(row=0, column=7) 78 | self.btn_change_sign = tk.Button(bottom_frame, **btn_params, text="%", command=self.change_signs) 79 | self.btn_change_sign.configure(activebackground="#A5A5A5", bg='#A5A5A5', foreground='black') 80 | self.btn_change_sign.grid(row=0, column=8) 81 | self.btn_div = tk.Button(bottom_frame, **btn_params, text="÷", command=lambda: self.btn_click('/')) 82 | self.btn_div.configure(activebackground="#FB9F10", bg='#FB9F10', foreground='#FFFFFF') 83 | self.btn_div.grid(row=0, column=9) 84 | self.btn_clear = tk.Button(bottom_frame, **btn_params, text="2nd", command=self.btn_clear_all) 85 | self.btn_clear.grid(row=1, column=0) 86 | self.cube = tk.Button(bottom_frame, **btn_params, text=u"x\u00B2", command=lambda: self.btn_click('**2')) 87 | self.cube.grid(row=1, column=1) 88 | self.cube = tk.Button(bottom_frame, **btn_params, text=u"x\u00B3", command=lambda: self.btn_click('**3')) 89 | self.cube.grid(row=1, column=2) 90 | self.btn_power = tk.Button(bottom_frame, **btn_params, text="x^y", command=lambda: self.btn_click('**')) 91 | self.btn_power.grid(row=1, column=3) 92 | self.btn_power = tk.Button(bottom_frame, **btn_params, text="e^x", command=lambda: self.btn_click('**')) 93 | self.btn_power.grid(row=1, column=4) 94 | self.btn_power = tk.Button(bottom_frame, **btn_params, text="10^x", command=lambda: self.btn_click('**')) 95 | self.btn_power.grid(row=1, column=5) 96 | self.btn_7 = tk.Button(bottom_frame, **btn_params, text="7", command=lambda: self.btn_click(7)) 97 | self.btn_7.configure(activebackground="#343434", bg='#343434') 98 | self.btn_7.grid(row=1, column=6) 99 | self.btn_8 = tk.Button(bottom_frame, **btn_params, text="8", command=lambda: self.btn_click(8)) 100 | self.btn_8.configure(activebackground="#343434", bg='#343434') 101 | self.btn_8.grid(row=1, column=7) 102 | self.btn_9 = tk.Button(bottom_frame, **btn_params, text="9", command=lambda: self.btn_click(9)) 103 | self.btn_9.configure(activebackground="#343434", bg='#343434') 104 | self.btn_9.grid(row=1, column=8) 105 | self.btn_mult = tk.Button(bottom_frame, **btn_params, text="x", command=lambda: self.btn_click('*')) 106 | self.btn_mult.configure(activebackground="#FB9F10", bg='#FB9F10', foreground='#FFFFFF') 107 | self.btn_mult.grid(row=1, column=9) 108 | self.btn_power = tk.Button(bottom_frame, **btn_params, text="1/x", command=lambda: self.btn_click('1/x')) 109 | self.btn_power.grid(row=2, column=0) 110 | self.btn_Deg = tk.Button(bottom_frame, **btn_params, text="Deg", command=self.convert_deg) 111 | self.btn_Deg.grid(row=2, column=1) 112 | self.btn_ln = tk.Button(bottom_frame, **btn_params, text="ln", command=lambda: self.btn_click('log1p(')) 113 | self.btn_ln.grid(row=2, column=2) 114 | self.btn_sqrt = tk.Button(bottom_frame, **btn_params, text="sqrt", command=lambda: self.btn_click('sqrt(')) 115 | self.btn_sqrt.grid(row=2, column=3) 116 | self.btn_abs = tk.Button(bottom_frame, **btn_params, text="abs", command=lambda: self.btn_click('abs' + '(')) 117 | self.btn_abs.grid(row=2, column=4) 118 | self.btn_log = tk.Button(bottom_frame, **btn_params, text="log", command=lambda: self.btn_click('log(')) 119 | self.btn_log.grid(row=2, column=5) 120 | self.btn_4 = tk.Button(bottom_frame, **btn_params, text="4", command=lambda: self.btn_click(4)) 121 | self.btn_4.configure(activebackground="#343434", bg='#343434') 122 | self.btn_4.grid(row=2, column=6) 123 | self.btn_5 = tk.Button(bottom_frame, **btn_params, text="5", command=lambda: self.btn_click(5)) 124 | self.btn_5.configure(activebackground="#343434", bg='#343434') 125 | self.btn_5.grid(row=2, column=7) 126 | self.btn_6 = tk.Button(bottom_frame, **btn_params, text="6", command=lambda: self.btn_click(6)) 127 | self.btn_6.configure(activebackground="#343434", bg='#343434') 128 | self.btn_6.grid(row=2, column=8) 129 | self.btnSub = tk.Button(bottom_frame, **btn_params, text="-", command=lambda: self.btn_click('-')) 130 | self.btnSub.configure(activebackground="#FB9F10", bg='#FB9F10', foreground='#FFFFFF') 131 | self.btnSub.grid(row=2, column=9) 132 | self.btn_fact = tk.Button(bottom_frame, **btn_params, text="x!", command=lambda: self.btn_click('factorial(')) 133 | self.btn_fact.grid(row=3, column=0) 134 | self.btn_sin = tk.Button(bottom_frame, **btn_params, text="sin", command=lambda: self.btn_click('fsin(')) 135 | self.btn_sin.grid(row=3, column=1) 136 | self.btn_cos = tk.Button(bottom_frame, **btn_params, text="cos", command=lambda: self.btn_click('fcos(')) 137 | self.btn_cos.grid(row=3, column=2) 138 | self.btn_tan = tk.Button(bottom_frame, **btn_params, text="tan", command=lambda: self.btn_click('ftan(')) 139 | self.btn_tan.grid(row=3, column=3) 140 | self.btn_power = tk.Button(bottom_frame, **btn_params, text="e", command=lambda: self.btn_click('**')) 141 | self.btn_power.grid(row=3, column=4) 142 | self.btn_power = tk.Button(bottom_frame, **btn_params, text="EE", command=lambda: self.btn_click('**')) 143 | self.btn_power.grid(row=3, column=5) 144 | self.btn_1 = tk.Button(bottom_frame, **btn_params, text="1", command=lambda: self.btn_click(1)) 145 | self.btn_1.configure(activebackground="#343434", bg='#343434') 146 | self.btn_1.grid(row=3, column=6) 147 | self.btn_2 = tk.Button(bottom_frame, **btn_params, text="2", command=lambda: self.btn_click(2)) 148 | self.btn_2.configure(activebackground="#343434", bg='#343434') 149 | self.btn_2.grid(row=3, column=7) 150 | self.btn_3 = tk.Button(bottom_frame, **btn_params, text="3", command=lambda: self.btn_click(3)) 151 | self.btn_3.configure(activebackground="#343434", bg='#343434') 152 | self.btn_3.grid(row=3, column=8) 153 | self.btn_add = tk.Button(bottom_frame, **btn_params, text="+", command=lambda: self.btn_click('+')) 154 | self.btn_add.configure(activebackground="#FB9F10", bg='#FB9F10', foreground='#FFFFFF') 155 | self.btn_add.grid(row=3, column=9) 156 | self.btn_Rad = tk.Button(bottom_frame, **btn_params, text="Rad", command=self.convert_rad) 157 | self.btn_Rad.grid(row=4, column=0) 158 | self.btn_sin_inverse = tk.Button(bottom_frame, **btn_params, text=u"sin-\u00B9", command=lambda: self.btn_click('arcsin(')) 159 | self.btn_sin_inverse.grid(row=4, column=1) 160 | self.btn_cos_inverse = tk.Button(bottom_frame, **btn_params, text=u"cos-\u00B9", command=lambda: self.btn_click('arccos(')) 161 | self.btn_cos_inverse.grid(row=4, column=2) 162 | self.btn_tan_inverse = tk.Button(bottom_frame, **btn_params, text=u"tan-\u00B9", command=lambda: self.btn_click('arctan(')) 163 | self.btn_tan_inverse.grid(row=4, column=3) 164 | self.btn_pi = tk.Button(bottom_frame, **btn_params, text="π", command=lambda: self.btn_click('pi')) 165 | self.btn_pi.grid(row=4, column=4) 166 | self.btn_del = tk.Button(bottom_frame, **btn_params, text="Rand", command=self.btn_clear1) 167 | self.btn_del.grid(row=4, column=5) 168 | self.btn_0 = tk.Button(bottom_frame, **btn_params, text="0", command=lambda: self.btn_click(0)) 169 | self.btn_0.configure(activebackground="#343434", bg='#343434') 170 | self.btn_0.grid(row=4, column=6) 171 | self.btn_0 = tk.Button(bottom_frame, **btn_params, text=" ", command=lambda: self.btn_click(0)) 172 | self.btn_0.configure(activebackground="#343434", bg='#343434') 173 | self.btn_0.grid(row=4, column=7) 174 | self.btn_dec = tk.Button(bottom_frame, **btn_params, text=".", command=lambda: self.btn_click('.')) 175 | self.btn_dec.configure(activebackground="#343434", bg='#343434') 176 | self.btn_dec.grid(row=4, column=8) 177 | self.btn_eq = tk.Button(bottom_frame, **btn_params, text="=", command=self.btn_equal) 178 | self.btn_eq.configure(activebackground="#FB9F10", bg='#FB9F10', foreground='#FFFFFF') 179 | self.btn_eq.grid(row=4, column=9) 180 | 181 | def btn_click(self, expression_val): 182 | if len(self.expression) >= 23: 183 | self.expression = self.expression 184 | self.text_input.set(self.expression) 185 | else: 186 | self.expression = self.expression + str(expression_val) 187 | self.text_input.set(self.expression) 188 | 189 | def btn_clear1(self): 190 | self.expression = self.expression[:-1] 191 | self.text_input.set(self.expression) 192 | 193 | def change_signs(self): 194 | self.expression = self.expression + '-' 195 | self.text_input.set(self.expression) 196 | 197 | def memory_clear(self): 198 | self.recall = "" 199 | 200 | def memory_add(self): 201 | self.recall = self.recall + '+' + self.expression 202 | 203 | def answer(self): 204 | self.answer = self.sum_up 205 | self.expression = self.expression + self.answer 206 | self.text_input.set(self.expression) 207 | 208 | def memory_recall(self): 209 | if self.expression == "": 210 | self.text_input.set('0' + self.expression + self.recall) 211 | else: 212 | self.text_input.set(self.expression + self.recall) 213 | 214 | def convert_deg(self): 215 | global convert_constant 216 | global inverse_convert_constant 217 | convert_constant = pi / 180 218 | inverse_convert_constant = 180 / pi 219 | self.btn_Rad["foreground"] = 'white' 220 | self.btn_Deg["foreground"] = 'orange' 221 | 222 | def convert_rad(self): 223 | global convert_constant 224 | global inverse_convert_constant 225 | convert_constant = 1 226 | inverse_convert_constant = 1 227 | self.btn_Rad["foreground"] = 'orange' 228 | self.btn_Deg["foreground"] = 'white' 229 | 230 | def btn_clear_all(self): 231 | self.expression = "" 232 | self.text_input.set("") 233 | 234 | def btn_equal(self): 235 | self.sum_up = str(eval(self.expression)) 236 | self.text_input.set(self.sum_up) 237 | self.expression = self.sum_up 238 | 239 | 240 | root = tk.Tk() 241 | b = Calculator(root) 242 | root.title("Scientific Calculator by Mainak") 243 | root.iconbitmap('Calculator_37533.ico') 244 | root.geometry("723x465+50+50") 245 | root.resizable(False, False) 246 | root.mainloop() -------------------------------------------------------------------------------- /ScreenRecord/screen.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/ScreenRecord/screen.jpg -------------------------------------------------------------------------------- /ScreenRecord/screen_rec.py: -------------------------------------------------------------------------------- 1 | import cv2 2 | import numpy as np 3 | import pyautogui 4 | 5 | screen_size = (1920,1080) 6 | fourcc = cv2.VideoWriter_fourcc(*"XVID") 7 | out = cv2.VideoWriter("output.avi",fourcc,10.0,(screen_size)) 8 | 9 | while True: 10 | img = pyautogui.screenshot() 11 | frame = np.array(img) 12 | frame = cv2.cvtColor(frame,cv2.COLOR_BGR2RGB) 13 | out.write(frame) 14 | cv2.imshow("show",frame) 15 | if cv2.waitKey(1)==ord("q"): 16 | break -------------------------------------------------------------------------------- /Sine Scroll autograph/LICENSE.md: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) [2016] [Scott W Harden] 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. -------------------------------------------------------------------------------- /Sine Scroll autograph/README.md: -------------------------------------------------------------------------------- 1 | # Matplotlib MatplotlibWidget demo 2 | This was tested to be ~40x SLOWER than a similar pyqtgraph graph 3 | 4 | PROJECT PAGE: http://www.swharden.com/wp/2016-07-30-live-data-in-pyqt4-with-matplotlibwidget/ 5 | 6 | This is a minimal-case example how to get a PyQt4 GUI (designed with QT Designer) to display a matploblit widget and update it automatically. This was tested with the WinPython 3.x distribution, but should be cross platform. Read the parent readme for full project details. 7 | 8 | * edit the ui_main.ui with "Qt Designer" 9 | * run ui_convert.py to turn ui_main.ui into ui_main.py 10 | * run go.py to launch the program (pulling UI from ui_main.py) 11 | * if the "keep updating" box is checked and the add buttin is hit, it does more and more! 12 | 13 | ![demo](demo.gif) 14 | 15 | ### Misc notes 16 | If you get `ImportError: No module named 'matplotlibwidget'`, ensure you are in the same folder as `matplotlibwidget.py` which is now provided with this example. -------------------------------------------------------------------------------- /Sine Scroll autograph/demo.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Sine Scroll autograph/demo.gif -------------------------------------------------------------------------------- /Sine Scroll autograph/go.bat: -------------------------------------------------------------------------------- 1 | python go.py 2 | pause -------------------------------------------------------------------------------- /Sine Scroll autograph/go.py: -------------------------------------------------------------------------------- 1 | from PyQt4 import QtGui,QtCore 2 | import sys 3 | import ui_main 4 | import numpy as np 5 | import pylab 6 | import time 7 | 8 | class ExampleApp(QtGui.QMainWindow, ui_main.Ui_MainWindow): 9 | def __init__(self, parent=None): 10 | super(ExampleApp, self).__init__(parent) 11 | self.setupUi(self) 12 | self.btnAdd.clicked.connect(self.update) 13 | self.matplotlibwidget.axes.hold(False) #clear on plot() 14 | 15 | def update(self): 16 | t1=time.time() 17 | points=100 #number of data points 18 | X=np.arange(points) 19 | Y=np.sin(np.arange(points)/points*3*np.pi+time.time()) 20 | C=pylab.cm.jet(time.time()%10/10) # random color 21 | self.matplotlibwidget.axes.plot(X,Y,ms=100,color=C,lw=10,alpha=.8) 22 | self.matplotlibwidget.axes.grid() 23 | self.matplotlibwidget.axes.get_figure().tight_layout() # fill space 24 | self.matplotlibwidget.draw() # required to update the window 25 | print("update took %.02f ms"%((time.time()-t1)*1000)) 26 | if self.chkMore.isChecked(): 27 | QtCore.QTimer.singleShot(10, self.update) # QUICKLY repeat 28 | 29 | if __name__=="__main__": 30 | app = QtGui.QApplication(sys.argv) 31 | form = ExampleApp() 32 | form.show() 33 | form.update() #start with something 34 | app.exec_() 35 | print("DONE") -------------------------------------------------------------------------------- /Sine Scroll autograph/matplotlibwidget.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | # 3 | # Copyright © 2009 Pierre Raybaut 4 | # Licensed under the terms of the MIT License 5 | 6 | """ 7 | MatplotlibWidget 8 | ================ 9 | 10 | Example of matplotlib widget for PyQt4 11 | 12 | Copyright © 2009 Pierre Raybaut 13 | This software is licensed under the terms of the MIT License 14 | 15 | Derived from 'embedding_in_pyqt4.py': 16 | Copyright © 2005 Florent Rougon, 2006 Darren Dale 17 | """ 18 | 19 | __version__ = "1.0.0" 20 | 21 | from PyQt4.QtGui import QSizePolicy 22 | from PyQt4.QtCore import QSize 23 | 24 | from matplotlib.backends.backend_qt4agg import FigureCanvasQTAgg as Canvas 25 | from matplotlib.figure import Figure 26 | 27 | from matplotlib import rcParams 28 | rcParams['font.size'] = 9 29 | 30 | 31 | class MatplotlibWidget(Canvas): 32 | """ 33 | MatplotlibWidget inherits PyQt4.QtGui.QWidget 34 | and matplotlib.backend_bases.FigureCanvasBase 35 | 36 | Options: option_name (default_value) 37 | ------- 38 | parent (None): parent widget 39 | title (''): figure title 40 | xlabel (''): X-axis label 41 | ylabel (''): Y-axis label 42 | xlim (None): X-axis limits ([min, max]) 43 | ylim (None): Y-axis limits ([min, max]) 44 | xscale ('linear'): X-axis scale 45 | yscale ('linear'): Y-axis scale 46 | width (4): width in inches 47 | height (3): height in inches 48 | dpi (100): resolution in dpi 49 | hold (False): if False, figure will be cleared each time plot is called 50 | 51 | Widget attributes: 52 | ----------------- 53 | figure: instance of matplotlib.figure.Figure 54 | axes: figure axes 55 | 56 | Example: 57 | ------- 58 | self.widget = MatplotlibWidget(self, yscale='log', hold=True) 59 | from numpy import linspace 60 | x = linspace(-10, 10) 61 | self.widget.axes.plot(x, x**2) 62 | self.wdiget.axes.plot(x, x**3) 63 | """ 64 | def __init__(self, parent=None, title='', xlabel='', ylabel='', 65 | xlim=None, ylim=None, xscale='linear', yscale='linear', 66 | width=4, height=3, dpi=100, hold=False): 67 | self.figure = Figure(figsize=(width, height), dpi=dpi) 68 | self.axes = self.figure.add_subplot(111) 69 | self.axes.set_title(title) 70 | self.axes.set_xlabel(xlabel) 71 | self.axes.set_ylabel(ylabel) 72 | if xscale is not None: 73 | self.axes.set_xscale(xscale) 74 | if yscale is not None: 75 | self.axes.set_yscale(yscale) 76 | if xlim is not None: 77 | self.axes.set_xlim(*xlim) 78 | if ylim is not None: 79 | self.axes.set_ylim(*ylim) 80 | self.axes.hold(hold) 81 | 82 | Canvas.__init__(self, self.figure) 83 | self.setParent(parent) 84 | 85 | Canvas.setSizePolicy(self, QSizePolicy.Expanding, QSizePolicy.Expanding) 86 | Canvas.updateGeometry(self) 87 | 88 | def sizeHint(self): 89 | w, h = self.get_width_height() 90 | return QSize(w, h) 91 | 92 | def minimumSizeHint(self): 93 | return QSize(10, 10) 94 | 95 | 96 | 97 | #=============================================================================== 98 | # Example 99 | #=============================================================================== 100 | if __name__ == '__main__': 101 | import sys 102 | from PyQt4.QtGui import QMainWindow, QApplication 103 | from numpy import linspace 104 | 105 | class ApplicationWindow(QMainWindow): 106 | def __init__(self): 107 | QMainWindow.__init__(self) 108 | self.mplwidget = MatplotlibWidget(self, title='Example', 109 | xlabel='Linear scale', 110 | ylabel='Log scale', 111 | hold=True, yscale='log') 112 | self.mplwidget.setFocus() 113 | self.setCentralWidget(self.mplwidget) 114 | self.plot(self.mplwidget.axes) 115 | 116 | def plot(self, axes): 117 | x = linspace(-10, 10) 118 | axes.plot(x, x**2) 119 | axes.plot(x, x**3) 120 | 121 | app = QApplication(sys.argv) 122 | win = ApplicationWindow() 123 | win.show() 124 | sys.exit(app.exec_()) 125 | -------------------------------------------------------------------------------- /Sine Scroll autograph/ui_convert.py: -------------------------------------------------------------------------------- 1 | from PyQt4 import uic 2 | import glob 3 | for fname in glob.glob("*.ui"): 4 | print("converting",fname) 5 | fin = open(fname,'r') 6 | fout = open(fname.replace(".ui",".py"),'w') 7 | uic.compileUi(fin,fout,execute=False) 8 | fin.close() 9 | fout.close() 10 | -------------------------------------------------------------------------------- /Sine Scroll autograph/ui_main.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | # Form implementation generated from reading ui file 'ui_main.ui' 4 | # 5 | # Created by: PyQt4 UI code generator 4.11.4 6 | # 7 | # WARNING! All changes made in this file will be lost! 8 | 9 | from PyQt4 import QtCore, QtGui 10 | 11 | try: 12 | _fromUtf8 = QtCore.QString.fromUtf8 13 | except AttributeError: 14 | def _fromUtf8(s): 15 | return s 16 | 17 | try: 18 | _encoding = QtGui.QApplication.UnicodeUTF8 19 | def _translate(context, text, disambig): 20 | return QtGui.QApplication.translate(context, text, disambig, _encoding) 21 | except AttributeError: 22 | def _translate(context, text, disambig): 23 | return QtGui.QApplication.translate(context, text, disambig) 24 | 25 | class Ui_MainWindow(object): 26 | def setupUi(self, MainWindow): 27 | MainWindow.setObjectName(_fromUtf8("MainWindow")) 28 | MainWindow.resize(820, 650) 29 | MainWindow.setAutoFillBackground(False) 30 | MainWindow.setDocumentMode(False) 31 | self.centralwidget = QtGui.QWidget(MainWindow) 32 | self.centralwidget.setObjectName(_fromUtf8("centralwidget")) 33 | self.verticalLayout = QtGui.QVBoxLayout(self.centralwidget) 34 | self.verticalLayout.setObjectName(_fromUtf8("verticalLayout")) 35 | self.horizontalLayout = QtGui.QHBoxLayout() 36 | self.horizontalLayout.setContentsMargins(-1, -1, 0, 0) 37 | self.horizontalLayout.setSpacing(10) 38 | self.horizontalLayout.setObjectName(_fromUtf8("horizontalLayout")) 39 | self.btnAdd = QtGui.QPushButton(self.centralwidget) 40 | self.btnAdd.setObjectName(_fromUtf8("btnAdd")) 41 | self.horizontalLayout.addWidget(self.btnAdd) 42 | self.chkMore = QtGui.QCheckBox(self.centralwidget) 43 | self.chkMore.setObjectName(_fromUtf8("chkMore")) 44 | self.horizontalLayout.addWidget(self.chkMore) 45 | self.verticalLayout.addLayout(self.horizontalLayout) 46 | self.matplotlibwidget = MatplotlibWidget(self.centralwidget) 47 | self.matplotlibwidget.setObjectName(_fromUtf8("matplotlibwidget")) 48 | self.verticalLayout.addWidget(self.matplotlibwidget) 49 | MainWindow.setCentralWidget(self.centralwidget) 50 | self.statusbar = QtGui.QStatusBar(MainWindow) 51 | self.statusbar.setObjectName(_fromUtf8("statusbar")) 52 | MainWindow.setStatusBar(self.statusbar) 53 | 54 | self.retranslateUi(MainWindow) 55 | QtCore.QMetaObject.connectSlotsByName(MainWindow) 56 | 57 | def retranslateUi(self, MainWindow): 58 | MainWindow.setWindowTitle(_translate("MainWindow", "MainWindow", None)) 59 | self.btnAdd.setText(_translate("MainWindow", "update sine wave", None)) 60 | self.chkMore.setText(_translate("MainWindow", "keep updating", None)) 61 | 62 | from matplotlibwidget import MatplotlibWidget 63 | -------------------------------------------------------------------------------- /Sine Scroll autograph/ui_main.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | MainWindow 4 | 5 | 6 | 7 | 0 8 | 0 9 | 820 10 | 650 11 | 12 | 13 | 14 | MainWindow 15 | 16 | 17 | false 18 | 19 | 20 | false 21 | 22 | 23 | 24 | 25 | 26 | 27 | 10 28 | 29 | 30 | 0 31 | 32 | 33 | 0 34 | 35 | 36 | 37 | 38 | update sine wave 39 | 40 | 41 | 42 | 43 | 44 | 45 | keep updating 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | MatplotlibWidget 61 | QWidget 62 |
    matplotlibwidget
    63 |
    64 |
    65 | 66 | 67 |
    68 | -------------------------------------------------------------------------------- /Snake Game/dist/snakes.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Snake Game/dist/snakes.exe -------------------------------------------------------------------------------- /Snake Game/snakes.py: -------------------------------------------------------------------------------- 1 | import turtle 2 | import time 3 | import random 4 | 5 | delay = 0.1 6 | 7 | # Score 8 | score = 0 9 | high_score = 0 10 | 11 | # Set up the screen 12 | wn = turtle.Screen() 13 | wn.title("Bewafa Nageen --- by Mainak") 14 | wn.bgcolor("black") 15 | wn.setup(width=600, height=600) 16 | wn.tracer(0) # Turns off the screen updates 17 | 18 | # Snake head 19 | head = turtle.Turtle() 20 | head.speed(0) 21 | head.shape("square") 22 | head.color("white") 23 | head.penup() 24 | head.goto(0,0) 25 | head.direction = "stop" 26 | 27 | # Snake food 28 | food = turtle.Turtle() 29 | food.speed(0) 30 | food.shape("circle") 31 | food.color("red") 32 | food.penup() 33 | food.goto(0,100) 34 | 35 | segments = [] 36 | 37 | # Pen 38 | pen = turtle.Turtle() 39 | pen.speed(0) 40 | pen.shape("square") 41 | pen.color("green") 42 | pen.penup() 43 | pen.hideturtle() 44 | pen.goto(0, 260) 45 | pen.write("Score: 0 High Score: 0", align="center", font=("Courier", 24, "normal")) 46 | 47 | # Functions 48 | def go_up(): 49 | if head.direction != "down": 50 | head.direction = "up" 51 | 52 | def go_down(): 53 | if head.direction != "up": 54 | head.direction = "down" 55 | 56 | def go_left(): 57 | if head.direction != "right": 58 | head.direction = "left" 59 | 60 | def go_right(): 61 | if head.direction != "left": 62 | head.direction = "right" 63 | 64 | def move(): 65 | if head.direction == "up": 66 | y = head.ycor() 67 | head.sety(y + 20) 68 | 69 | if head.direction == "down": 70 | y = head.ycor() 71 | head.sety(y - 20) 72 | 73 | if head.direction == "left": 74 | x = head.xcor() 75 | head.setx(x - 20) 76 | 77 | if head.direction == "right": 78 | x = head.xcor() 79 | head.setx(x + 20) 80 | 81 | # Keyboard bindings 82 | wn.listen() 83 | wn.onkeypress(go_up, "w") 84 | wn.onkeypress(go_down, "s") 85 | wn.onkeypress(go_left, "a") 86 | wn.onkeypress(go_right, "d") 87 | 88 | # Main game loop 89 | while True: 90 | wn.update() 91 | 92 | # Check for a collision with the border 93 | if head.xcor()>290 or head.xcor()<-290 or head.ycor()>290 or head.ycor()<-290: 94 | time.sleep(1) 95 | head.goto(0,0) 96 | head.direction = "stop" 97 | 98 | # Hide the segments 99 | for segment in segments: 100 | segment.goto(1000, 1000) 101 | 102 | # Clear the segments list 103 | segments.clear() 104 | 105 | # Reset the score 106 | score = 0 107 | 108 | # Reset the delay 109 | delay = 0.1 110 | 111 | pen.clear() 112 | pen.write("Score: {} High Score: {}".format(score, high_score), align="center", font=("Courier", 24, "normal")) 113 | 114 | 115 | # Check for a collision with the food 116 | if head.distance(food) < 20: 117 | # Move the food to a random spot 118 | x = random.randint(-290, 290) 119 | y = random.randint(-290, 290) 120 | food.goto(x,y) 121 | 122 | # Add a segment 123 | new_segment = turtle.Turtle() 124 | new_segment.speed(0) 125 | new_segment.shape("square") 126 | new_segment.color("grey") 127 | new_segment.penup() 128 | segments.append(new_segment) 129 | 130 | # Shorten the delay 131 | delay -= 0.001 132 | 133 | # Increase the score 134 | score += 10 135 | 136 | if score > high_score: 137 | high_score = score 138 | 139 | pen.clear() 140 | pen.write("Score: {} High Score: {}".format(score, high_score), align="center", font=("Courier", 24, "normal")) 141 | 142 | # Move the end segments first in reverse order 143 | for index in range(len(segments)-1, 0, -1): 144 | x = segments[index-1].xcor() 145 | y = segments[index-1].ycor() 146 | segments[index].goto(x, y) 147 | 148 | # Move segment 0 to where the head is 149 | if len(segments) > 0: 150 | x = head.xcor() 151 | y = head.ycor() 152 | segments[0].goto(x,y) 153 | 154 | move() 155 | 156 | # Check for head collision with the body segments 157 | for segment in segments: 158 | if segment.distance(head) < 20: 159 | time.sleep(1) 160 | head.goto(0,0) 161 | head.direction = "stop" 162 | 163 | # Hide the segments 164 | for segment in segments: 165 | segment.goto(1000, 1000) 166 | 167 | # Clear the segments list 168 | segments.clear() 169 | 170 | # Reset the score 171 | score = 0 172 | 173 | # Reset the delay 174 | delay = 0.1 175 | 176 | # Update the score display 177 | pen.clear() 178 | pen.write("Score: {} High Score: {}".format(score, high_score), align="center", font=("Courier", 24, "normal")) 179 | 180 | time.sleep(delay) 181 | 182 | wn.mainloop() 183 | -------------------------------------------------------------------------------- /Snake Game/snakes.spec: -------------------------------------------------------------------------------- 1 | # -*- mode: python ; coding: utf-8 -*- 2 | 3 | block_cipher = None 4 | 5 | 6 | a = Analysis(['snakes.py'], 7 | pathex=['C:\\Users\\maina\\Desktop\\Projects\\Pygames\\Snakes'], 8 | binaries=[], 9 | datas=[], 10 | hiddenimports=[], 11 | hookspath=[], 12 | runtime_hooks=[], 13 | excludes=[], 14 | win_no_prefer_redirects=False, 15 | win_private_assemblies=False, 16 | cipher=block_cipher, 17 | noarchive=False) 18 | pyz = PYZ(a.pure, a.zipped_data, 19 | cipher=block_cipher) 20 | exe = EXE(pyz, 21 | a.scripts, 22 | a.binaries, 23 | a.zipfiles, 24 | a.datas, 25 | [], 26 | name='snakes', 27 | debug=False, 28 | bootloader_ignore_signals=False, 29 | strip=False, 30 | upx=True, 31 | upx_exclude=[], 32 | runtime_tmpdir=None, 33 | console=False ) 34 | -------------------------------------------------------------------------------- /Text editor/icon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icon.ico -------------------------------------------------------------------------------- /Text editor/icons2/align_center.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/align_center.png -------------------------------------------------------------------------------- /Text editor/icons2/align_left.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/align_left.png -------------------------------------------------------------------------------- /Text editor/icons2/align_right.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/align_right.png -------------------------------------------------------------------------------- /Text editor/icons2/bold.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/bold.png -------------------------------------------------------------------------------- /Text editor/icons2/clear_all.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/clear_all.png -------------------------------------------------------------------------------- /Text editor/icons2/copy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/copy.png -------------------------------------------------------------------------------- /Text editor/icons2/cut.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/cut.png -------------------------------------------------------------------------------- /Text editor/icons2/dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/dark.png -------------------------------------------------------------------------------- /Text editor/icons2/exit.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/exit.png -------------------------------------------------------------------------------- /Text editor/icons2/find.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/find.png -------------------------------------------------------------------------------- /Text editor/icons2/font_color.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/font_color.png -------------------------------------------------------------------------------- /Text editor/icons2/italic.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/italic.png -------------------------------------------------------------------------------- /Text editor/icons2/light_default.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/light_default.png -------------------------------------------------------------------------------- /Text editor/icons2/light_plus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/light_plus.png -------------------------------------------------------------------------------- /Text editor/icons2/monokai.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/monokai.png -------------------------------------------------------------------------------- /Text editor/icons2/new.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/new.png -------------------------------------------------------------------------------- /Text editor/icons2/night_blue.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/night_blue.png -------------------------------------------------------------------------------- /Text editor/icons2/open.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/open.png -------------------------------------------------------------------------------- /Text editor/icons2/paste.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/paste.png -------------------------------------------------------------------------------- /Text editor/icons2/red.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/red.png -------------------------------------------------------------------------------- /Text editor/icons2/save.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/save.png -------------------------------------------------------------------------------- /Text editor/icons2/save_as.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/save_as.png -------------------------------------------------------------------------------- /Text editor/icons2/status_bar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/status_bar.png -------------------------------------------------------------------------------- /Text editor/icons2/tool_bar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/tool_bar.png -------------------------------------------------------------------------------- /Text editor/icons2/underline.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/Text editor/icons2/underline.png -------------------------------------------------------------------------------- /Text editor/tx.py: -------------------------------------------------------------------------------- 1 | import tkinter as tk 2 | from tkinter import ttk 3 | from tkinter import font, colorchooser, filedialog, messagebox 4 | import os 5 | 6 | main_application = tk.Tk() 7 | main_application.geometry('1300x800') 8 | main_application.title('SCRIBBLER Text Editor --- Made by Mainak') 9 | main_application.wm_iconbitmap('icon.ico') 10 | 11 | 12 | main_menu = tk.Menu() 13 | #file icons 14 | new_icon = tk.PhotoImage(file='icons2/new.png') 15 | open_icon = tk.PhotoImage(file='icons2/open.png') 16 | save_icon = tk.PhotoImage(file='icons2/save.png') 17 | save_as_icon = tk.PhotoImage(file='icons2/save_as.png') 18 | exit_icon = tk.PhotoImage(file='icons2/exit.png') 19 | 20 | file = tk.Menu(main_menu, tearoff=False) 21 | 22 | 23 | 24 | #####edit 25 | #edit icons 26 | copy_icon = tk.PhotoImage(file='icons2/copy.png') 27 | paste_icon = tk.PhotoImage(file='icons2/paste.png') 28 | cut_icon = tk.PhotoImage(file='icons2/cut.png') 29 | clear_all_icon = tk.PhotoImage(file='icons2/clear_all.png') 30 | find_icon = tk.PhotoImage(file='icons2/find.png') 31 | 32 | edit = tk.Menu(main_menu, tearoff=False) 33 | 34 | 35 | ######## view icons 36 | tool_bar_icon = tk.PhotoImage(file='icons2/tool_bar.png') 37 | status_bar_icon = tk.PhotoImage(file='icons2/status_bar.png') 38 | view = tk.Menu(main_menu, tearoff=False) 39 | 40 | 41 | ######## color theme 42 | light_default_icon = tk.PhotoImage(file='icons2/light_default.png') 43 | light_plus_icon = tk.PhotoImage(file='icons2/light_plus.png') 44 | dark_icon = tk.PhotoImage(file='icons2/dark.png') 45 | red_icon = tk.PhotoImage(file='icons2/red.png') 46 | monokai_icon = tk.PhotoImage(file='icons2/monokai.png') 47 | night_blue_icon = tk.PhotoImage(file='icons2/night_blue.png') 48 | color_theme = tk.Menu(main_menu, tearoff=False) 49 | 50 | theme_choice = tk.StringVar() 51 | color_icons = (light_default_icon, light_plus_icon, dark_icon, red_icon, monokai_icon, night_blue_icon) 52 | 53 | color_dict = { 54 | 'Light Default ' : ('#000000', '#ffffff'), 55 | 'Light Plus' : ('#474747', '#e0e0e0'), 56 | 'Dark' : ('#c4c4c4', '#2d2d2d'), 57 | 'Red' : ('#2d2d2d', '#ffe8e8'), 58 | 'Monokai' : ('#d3b774', '#474747'), 59 | 'Night Blue' :('#ededed', '#6b9dc2') 60 | } 61 | 62 | 63 | # cascade 64 | main_menu.add_cascade(label='File', menu=file) 65 | main_menu.add_cascade(label='Edit', menu=edit) 66 | main_menu.add_cascade(label='View', menu=view) 67 | main_menu.add_cascade(label='Color Theme', menu=color_theme) 68 | 69 | 70 | 71 | 72 | 73 | tool_bar = ttk.Label(main_application) 74 | tool_bar.pack(side=tk.TOP, fill=tk.X) 75 | 76 | ## font box 77 | font_tuple = tk.font.families() 78 | font_family = tk.StringVar() 79 | font_box = ttk.Combobox(tool_bar, width=30, textvariable=font_family, state='readonly') 80 | font_box['values'] = font_tuple 81 | font_box.current(font_tuple.index('Arial')) 82 | font_box.grid(row=0, column=0, padx=5) 83 | 84 | 85 | ## size box 86 | size_var = tk.IntVar() 87 | font_size = ttk.Combobox(tool_bar, width=14, textvariable = size_var, state='readonly') 88 | font_size['values'] = tuple(range(8,81)) 89 | font_size.current(4) 90 | font_size.grid(row=0, column=1, padx=5) 91 | 92 | ## bold button 93 | bold_icon = tk.PhotoImage(file='icons2/bold.png') 94 | bold_btn = ttk.Button(tool_bar, image=bold_icon) 95 | bold_btn.grid(row=0, column=2, padx=5) 96 | 97 | ## italic button 98 | italic_icon = tk.PhotoImage(file='icons2/italic.png') 99 | italic_btn = ttk.Button(tool_bar, image=italic_icon) 100 | italic_btn.grid(row=0, column=3, padx=5) 101 | 102 | ## underline button 103 | underline_icon = tk.PhotoImage(file='icons2/underline.png') 104 | underline_btn = ttk.Button(tool_bar, image = underline_icon) 105 | underline_btn.grid(row = 0, column=4, padx=5) 106 | 107 | ## font color button 108 | font_color_icon = tk.PhotoImage(file='icons2/font_color.png') 109 | font_color_btn = ttk.Button(tool_bar, image=font_color_icon) 110 | font_color_btn.grid(row=0, column=5,padx=5) 111 | 112 | ## align left 113 | align_left_icon = tk.PhotoImage(file='icons2/align_left.png') 114 | align_left_btn = ttk.Button(tool_bar, image=align_left_icon) 115 | align_left_btn.grid(row=0, column=6, padx=5) 116 | 117 | ## align center 118 | align_center_icon = tk.PhotoImage(file='icons2/align_center.png') 119 | align_center_btn = ttk.Button(tool_bar, image=align_center_icon) 120 | align_center_btn.grid(row=0, column=7, padx=5) 121 | 122 | ## align right 123 | align_right_icon = tk.PhotoImage(file='icons2/align_right.png') 124 | align_right_btn = ttk.Button(tool_bar, image=align_right_icon) 125 | align_right_btn.grid(row=0, column=8, padx=5) 126 | 127 | # -------------------------------------&&&&&&&& End toolbar &&&&&&&&&&& ---------------------------------- 128 | 129 | ############################################## text editor ################################################### 130 | 131 | text_editor = tk.Text(main_application) 132 | text_editor.config(wrap='word', relief=tk.FLAT) 133 | 134 | scroll_bar = tk.Scrollbar(main_application) 135 | text_editor.focus_set() 136 | scroll_bar.pack(side=tk.RIGHT, fill=tk.Y) 137 | text_editor.pack(fill=tk.BOTH, expand=True) 138 | scroll_bar.config(command=text_editor.yview) 139 | text_editor.config(yscrollcommand=scroll_bar.set) 140 | 141 | # font family and font size functionality 142 | current_font_family = 'Arial' 143 | current_font_size = 12 144 | 145 | def change_font(event=None): 146 | global current_font_family 147 | current_font_family = font_family.get() 148 | text_editor.configure(font=(current_font_family, current_font_size)) 149 | 150 | def change_fontsize(event=None): 151 | global current_font_size 152 | current_font_size = size_var.get() 153 | text_editor.configure(font=(current_font_family, current_font_size)) 154 | 155 | 156 | font_box.bind("<>", change_font) 157 | font_size.bind("<>", change_fontsize) 158 | 159 | ######## buttons functionality 160 | 161 | # bold button functionality 162 | def change_bold(): 163 | text_property = tk.font.Font(font=text_editor['font']) 164 | if text_property.actual()['weight'] == 'normal': 165 | text_editor.configure(font=(current_font_family, current_font_size, 'bold')) 166 | if text_property.actual()['weight'] == 'bold': 167 | text_editor.configure(font=(current_font_family, current_font_size, 'normal')) 168 | 169 | bold_btn.configure(command=change_bold) 170 | 171 | 172 | # italic functionlaity 173 | def change_italic(): 174 | text_property = tk.font.Font(font=text_editor['font']) 175 | if text_property.actual()['slant'] == 'roman': 176 | text_editor.configure(font=(current_font_family, current_font_size, 'italic')) 177 | if text_property.actual()['slant'] == 'italic': 178 | text_editor.configure(font=(current_font_family, current_font_size, 'normal')) 179 | 180 | italic_btn.configure(command=change_italic) 181 | 182 | # underline functionality 183 | def change_underline(): 184 | text_property = tk.font.Font(font=text_editor['font']) 185 | if text_property.actual()['underline'] == 0: 186 | text_editor.configure(font=(current_font_family, current_font_size, 'underline')) 187 | if text_property.actual()['underline'] == 1: 188 | text_editor.configure(font=(current_font_family, current_font_size, 'normal')) 189 | 190 | underline_btn.configure(command=change_underline) 191 | 192 | 193 | ## font color functionality 194 | def change_font_color(): 195 | color_var = tk.colorchooser.askcolor() 196 | text_editor.configure(fg=color_var[1]) 197 | 198 | 199 | font_color_btn.configure(command=change_font_color) 200 | 201 | ### align functionality 202 | 203 | def align_left(): 204 | text_content = text_editor.get(1.0, 'end') 205 | text_editor.tag_config('left', justify=tk.LEFT) 206 | text_editor.delete(1.0, tk.END) 207 | text_editor.insert(tk.INSERT, text_content, 'left') 208 | 209 | align_left_btn.configure(command=align_left) 210 | 211 | ## center 212 | def align_center(): 213 | text_content = text_editor.get(1.0, 'end') 214 | text_editor.tag_config('center', justify=tk.CENTER) 215 | text_editor.delete(1.0, tk.END) 216 | text_editor.insert(tk.INSERT, text_content, 'center') 217 | 218 | align_center_btn.configure(command=align_center) 219 | 220 | ## right 221 | def align_right(): 222 | text_content = text_editor.get(1.0, 'end') 223 | text_editor.tag_config('right', justify=tk.RIGHT) 224 | text_editor.delete(1.0, tk.END) 225 | text_editor.insert(tk.INSERT, text_content, 'right') 226 | 227 | align_right_btn.configure(command=align_right) 228 | 229 | 230 | 231 | 232 | 233 | text_editor.configure(font=('Arial', 12)) 234 | # -------------------------------------&&&&&&&& End text editor &&&&&&&&&&& ---------------------------------- 235 | 236 | 237 | ############################################## status bar ################################################### 238 | 239 | status_bar = ttk.Label(main_application, text = 'Status Bar') 240 | status_bar.pack(side=tk.BOTTOM) 241 | 242 | text_changed = False 243 | def changed(event=None): 244 | global text_changed 245 | if text_editor.edit_modified(): 246 | text_changed = True 247 | words = len(text_editor.get(1.0, 'end-1c').split()) 248 | characters = len(text_editor.get(1.0, 'end-1c')) 249 | status_bar.config(text=f'Characters : {characters} Words : {words}') 250 | text_editor.edit_modified(False) 251 | 252 | text_editor.bind('<>', changed) 253 | 254 | 255 | # -------------------------------------&&&&&&&& End status bar &&&&&&&&&&& ---------------------------------- 256 | 257 | 258 | ############################################## main menu functinality ################################################### 259 | 260 | ## variable 261 | url = '' 262 | 263 | ## new functionality 264 | def new_file(event=None): 265 | global url 266 | url = '' 267 | text_editor.delete(1.0, tk.END) 268 | 269 | ## file commands 270 | file.add_command(label='New', image=new_icon, compound=tk.LEFT, accelerator='Ctrl+N', command=new_file) 271 | 272 | ## open functionality 273 | 274 | def open_file(event=None): 275 | global url 276 | url = filedialog.askopenfilename(initialdir=os.getcwd(), title='Select File', filetypes=(('Text File', '*.txt'), ('All files', '*.*'))) 277 | try: 278 | with open(url, 'r') as fr: 279 | text_editor.delete(1.0, tk.END) 280 | text_editor.insert(1.0, fr.read()) 281 | except FileNotFoundError: 282 | return 283 | except: 284 | return 285 | main_application.title(os.path.basename(url)) 286 | 287 | file.add_command(label='Open', image=open_icon, compound=tk.LEFT, accelerator='Ctrl+O', command=open_file) 288 | 289 | ## save file 290 | 291 | def save_file(event=None): 292 | global url 293 | try: 294 | if url: 295 | content = str(text_editor.get(1.0, tk.END)) 296 | with open(url, 'w', encoding='utf-8') as fw: 297 | fw.write(content) 298 | else: 299 | url = filedialog.asksaveasfile(mode = 'w', defaultextension='.txt', filetypes=(('Text File', '*.txt'), ('All files', '*.*'))) 300 | content2 = text_editor.get(1.0, tk.END) 301 | url.write(content2) 302 | url.close() 303 | except: 304 | return 305 | 306 | file.add_command(label='Save', image=save_icon, compound=tk.LEFT, accelerator='Ctrl+S', command = save_file) 307 | 308 | 309 | ## save as functionality 310 | def save_as(event=None): 311 | global url 312 | try: 313 | content = text_editor.get(1.0, tk.END) 314 | url = filedialog.asksaveasfile(mode = 'w', defaultextension='.txt', filetypes=(('Text File', '*.txt'), ('All files', '*.*'))) 315 | url.write(content) 316 | url.close() 317 | except: 318 | return 319 | 320 | 321 | file.add_command(label='Save As', image=new_icon, compound=tk.LEFT, accelerator='Ctrl+Alt+S', command=save_as) 322 | 323 | ## exit functionality 324 | 325 | def exit_func(event=None): 326 | global url, text_changed 327 | try: 328 | if text_changed: 329 | mbox = messagebox.askyesnocancel('Warning', 'Do you want to save the file ?') 330 | if mbox is True: 331 | if url: 332 | content = text_editor.get(1.0, tk.END) 333 | with open(url, 'w', encoding='utf-8') as fw: 334 | fw.write(content) 335 | main_application.destroy() 336 | else: 337 | content2 = str(text_editor.get(1.0, tk.END)) 338 | url = filedialog.asksaveasfile(mode = 'w', defaultextension='.txt', filetypes=(('Text File', '*.txt'), ('All files', '*.*'))) 339 | url.write(content2) 340 | url.close() 341 | main_application.destroy() 342 | elif mbox is False: 343 | main_application.destroy() 344 | else: 345 | main_application.destroy() 346 | except: 347 | return 348 | file.add_command(label='Exit', image=exit_icon, compound=tk.LEFT, accelerator='Ctrl+Q', command=exit_func) 349 | 350 | 351 | ############ find functionality 352 | 353 | def find_func(event=None): 354 | 355 | def find(): 356 | word = find_input.get() 357 | text_editor.tag_remove('match', '1.0', tk.END) 358 | matches = 0 359 | if word: 360 | start_pos = '1.0' 361 | while True: 362 | start_pos = text_editor.search(word, start_pos, stopindex=tk.END) 363 | if not start_pos: 364 | break 365 | end_pos = f'{start_pos}+{len(word)}c' 366 | text_editor.tag_add('match', start_pos, end_pos) 367 | matches += 1 368 | start_pos = end_pos 369 | text_editor.tag_config('match', foreground='red', background='yellow') 370 | 371 | def replace(): 372 | word = find_input.get() 373 | replace_text = replace_input.get() 374 | content = text_editor.get(1.0, tk.END) 375 | new_content = content.replace(word, replace_text) 376 | text_editor.delete(1.0, tk.END) 377 | text_editor.insert(1.0, new_content) 378 | 379 | find_dialogue = tk.Toplevel() 380 | find_dialogue.geometry('450x250+500+200') 381 | find_dialogue.title('Find') 382 | find_dialogue.resizable(0,0) 383 | 384 | ## frame 385 | find_frame = ttk.LabelFrame(find_dialogue, text='Find/Replace') 386 | find_frame.pack(pady=20) 387 | 388 | ## labels 389 | text_find_label = ttk.Label(find_frame, text='Find : ') 390 | text_replace_label = ttk.Label(find_frame, text= 'Replace') 391 | 392 | ## entry 393 | find_input = ttk.Entry(find_frame, width=30) 394 | replace_input = ttk.Entry(find_frame, width=30) 395 | 396 | ## button 397 | find_button = ttk.Button(find_frame, text='Find', command=find) 398 | replace_button = ttk.Button(find_frame, text= 'Replace', command=replace) 399 | 400 | ## label grid 401 | text_find_label.grid(row=0, column=0, padx=4, pady=4) 402 | text_replace_label.grid(row=1, column=0, padx=4, pady=4) 403 | 404 | ## entry grid 405 | find_input.grid(row=0, column=1, padx=4, pady=4) 406 | replace_input.grid(row=1, column=1, padx=4, pady=4) 407 | 408 | ## button grid 409 | find_button.grid(row=2, column=0, padx=8, pady=4) 410 | replace_button.grid(row=2, column=1, padx=8, pady=4) 411 | 412 | find_dialogue.mainloop() 413 | 414 | ## edit commands 415 | edit.add_command(label='Copy', image=copy_icon, compound=tk.LEFT, accelerator='Ctrl+C', command=lambda:text_editor.event_generate("")) 416 | edit.add_command(label='Paste', image=paste_icon, compound=tk.LEFT, accelerator='Ctrl+V', command=lambda:text_editor.event_generate("")) 417 | edit.add_command(label='Cut', image=cut_icon, compound=tk.LEFT, accelerator='Ctrl+X', command=lambda:text_editor.event_generate("")) 418 | edit.add_command(label='Clear All', image=clear_all_icon, compound=tk.LEFT, accelerator='Ctrl+Alt+X', command= lambda:text_editor.delete(1.0, tk.END)) 419 | edit.add_command(label='Find', image=find_icon, compound=tk.LEFT, accelerator='Ctrl+F', command = find_func) 420 | 421 | ## view check button 422 | 423 | show_statusbar = tk.BooleanVar() 424 | show_statusbar.set(True) 425 | show_toolbar = tk.BooleanVar() 426 | show_toolbar.set(True) 427 | 428 | def hide_toolbar(): 429 | global show_toolbar 430 | if show_toolbar: 431 | tool_bar.pack_forget() 432 | show_toolbar = False 433 | else : 434 | text_editor.pack_forget() 435 | status_bar.pack_forget() 436 | tool_bar.pack(side=tk.TOP, fill=tk.X) 437 | text_editor.pack(fill=tk.BOTH, expand=True) 438 | status_bar.pack(side=tk.BOTTOM) 439 | show_toolbar = True 440 | 441 | 442 | def hide_statusbar(): 443 | global show_statusbar 444 | if show_statusbar: 445 | status_bar.pack_forget() 446 | show_statusbar = False 447 | else : 448 | status_bar.pack(side=tk.BOTTOM) 449 | show_statusbar = True 450 | 451 | 452 | view.add_checkbutton(label='Tool Bar',onvalue=True, offvalue=0,variable = show_toolbar, image=tool_bar_icon, compound=tk.LEFT, command=hide_toolbar) 453 | view.add_checkbutton(label='Status Bar',onvalue=1, offvalue=False,variable = show_statusbar, image=status_bar_icon, compound=tk.LEFT, command=hide_statusbar) 454 | 455 | 456 | ## color theme 457 | def change_theme(): 458 | chosen_theme = theme_choice.get() 459 | color_tuple = color_dict.get(chosen_theme) 460 | fg_color, bg_color = color_tuple[0], color_tuple[1] 461 | text_editor.config(background=bg_color, fg=fg_color) 462 | count = 0 463 | for i in color_dict: 464 | color_theme.add_radiobutton(label = i, image=color_icons[count], variable=theme_choice, compound=tk.LEFT, command=change_theme) 465 | count += 1 466 | 467 | 468 | 469 | # -------------------------------------&&&&&&&& End main menu functinality&&&&&&&&&&& ---------------------------------- 470 | 471 | main_application.config(menu=main_menu) 472 | 473 | #### bind shortcut keys 474 | main_application.bind("", new_file) 475 | main_application.bind("", open_file) 476 | main_application.bind("", save_file) 477 | main_application.bind("", save_as) 478 | main_application.bind("", exit_func) 479 | main_application.bind("", find_func) 480 | 481 | 482 | main_application.mainloop() 483 | -------------------------------------------------------------------------------- /YinYang/YinYang.mp4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/YinYang/YinYang.mp4 -------------------------------------------------------------------------------- /YinYang/yinyang.py: -------------------------------------------------------------------------------- 1 | # Made by MAINAK 2 | 3 | from turtle import * 4 | 5 | def yinyang(clr1,clr2): 6 | width(2) 7 | color("black",clr1) 8 | begin_fill() 9 | circle(150.,180) 10 | circle(300,180) 11 | left(180) 12 | circle(-150.,180) 13 | end_fill() 14 | left(90) 15 | up() 16 | forward(300*0.35) 17 | right(90) 18 | down() 19 | color(clr1,clr2) 20 | begin_fill() 21 | circle(300*0.20) 22 | end_fill() 23 | left(90) 24 | up() 25 | backward(300*0.35) 26 | down() 27 | left(90) 28 | 29 | reset() 30 | yinyang("black","white") 31 | yinyang("white","black") 32 | mainloop() 33 | 34 | -------------------------------------------------------------------------------- /darkmode/Night Mode.py: -------------------------------------------------------------------------------- 1 | import tkinter as tk 2 | from tkinter import PhotoImage 3 | 4 | # setting root window: 5 | root = tk.Tk() 6 | root.title("Night Mode") 7 | root.config(bg="#CECCBE") 8 | root.geometry("800x400") 9 | 10 | # setting switch state: 11 | btnState = False 12 | 13 | # setting switch function: 14 | def switch(): 15 | global btnState 16 | if btnState: 17 | btn.config(image=offImg, bg="#CECCBE", activebackground="#CECCBE") 18 | root.config(bg="#CECCBE") 19 | txt.config(text="Dark Mode: OFF", bg="#CECCBE") 20 | btnState = False 21 | else: 22 | btn.config(image=onImg, bg="#2B2B2B", activebackground="#2B2B2B") 23 | root.config(bg="#2B2B2B") 24 | txt.config(text="Dark Mode: ON", bg="#2B2B2B") 25 | btnState = True 26 | 27 | # loading the switch images: 28 | onImg = PhotoImage(file=r"switch-on.png") 29 | offImg = PhotoImage(file=r"switch-off.png") 30 | 31 | # Night mode label: 32 | txt = tk.Label(root, text="Dark Mode: OFF", font="FixedSys 17", bg="#CECCBE", fg="green") 33 | txt.place(relx=0.5, rely=0.35, anchor="center") 34 | 35 | # switch widget: 36 | btn = tk.Button(root, text="OFF", borderwidth=0, command=switch, bg="#CECCBE", activebackground="#CECCBE") 37 | btn.place(relx=0.5, rely=0.5, anchor="center") 38 | btn.config(image=offImg) 39 | 40 | # window in mainloop: 41 | root.mainloop() 42 | -------------------------------------------------------------------------------- /darkmode/switch-off.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/darkmode/switch-off.png -------------------------------------------------------------------------------- /darkmode/switch-on.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MainakRepositor/PyProjects/e88b26fabf56bfe1b0d917ef4913f75d911a5df7/darkmode/switch-on.png --------------------------------------------------------------------------------