Delrius Euphoria
Delrius Euphoria

Reputation: 15088

Animated cursor in tkinter python

Is it possible to use animated cursors in tkinter window like using custom cursor with widgets. To use custom ani cursors on root window of tkinter file

Thanks in advance :D

Upvotes: 0

Views: 2699

Answers (1)

milanbalazs
milanbalazs

Reputation: 5319

You can do it. Almost all widgets have cursor parameter so you can change the cursor of widgets separately.

Code:

import tkinter as tk

root = tk.Tk()
root.geometry("500x500")
root.configure(cursor="heart")  # Default cursor on main window.

B1 = tk.Button(root, text="circle_cursor", cursor="circle")  # Cursor on Button widget
B1.pack()

root.mainloop()

Possible cursors:

Cursors

Upvotes: 2

Related Questions