문제

I have a text widget with dark background and I can't see the cursor's position. Is there any way to change the (blinking) text cursor's color?

도움이 되었습니까?

해결책

You can change the insertbackground option of the text widget to whatever you want.

다른 팁

Option for text cursor color in Tk is -insertbackground.

textWidget.config(insertbackground=...)

For python version 3

import tkinter as tk

textfield = tk.Entry(root)
textfield.configure(bg="#1C6C0B", insertbackground='white')
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top