searchentry widget

Tcl/Tk widget that extends ttk::entry with a built-in search icon, supporting hover and pressed states, and optional click actions. Icon automatically scales based on tk scaling. Clicking the icon with mouse button 1 or pressing the Return key generates the virtual event <<searchPressed>>.

Source at https://github.com/ch32n/searchentry

searchentry.png

Example

package require Tk
package require searchentry

# Create entry widget
ttk::searchentry .search
grid .search -row 0 -column 0 -padx 10 -pady 10
bind .search <<searchPressed>> {puts "search pressed on %W"}