#Python Notepad using Tkinter A replication of windows notepad using tkinter python GUI library
#!/usr/bin/python3
# -*- coding: utf-8 -*-
# FILE : __main__.py
# RUN : python3 __main__.py
def italic():
text.config(font=('Segio UI',20,'italic'))
def underline():
text.config(font=('Segio UI',20,'underline'))
def ora(self):
ora=time.localtime()
self.text_area.insert(tk.INSERT, ora)
Access: Edit>Insert hour
def line():
line="-"*60
self.text_area.insert(tk.INSERT, line)
Access: Edit>Insert line
import datetime
Create the function date():
def date(self):
data = datetime.date.today()
self.text_area.insert(tk.INSERT, data)
Access: Edit>Insert date
-
Python 3
-
tkinter - Tkinter comes pre-installed with the Python installer binaries for Mac OS X and the Windows platform. So if you install Python from the official binaries for Mac OS X or Windows platform, you are good to go with Tkinter.
For Debian versions of Linux you have to install it manually by using the following commands.
For Python 3,
sudo apt-get install python3-tk
Clone the repository to your local machine using,
~$ git clone https://github.com/Ayan-Kumar-Saha/tkinter-Notepad.git
Run the notepad using,
~$ python3 notepad.py
~$ python notepad.py
- tkinter - A python library for creating GUI-based application.
Ayan Kumar Saha