Advertisement
hakonhagland

overrideredirect

Dec 30th, 2020
1,262
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #! /usr/bin/env tclsh
  2.  
  3. package require Tk
  4. wm title . Hello
  5. wm overrideredirect . true
  6. canvas  .cv -width 410 -height 200  -bg white
  7. .cv create rect 0 0 360 100 -outline #c0c0c0 -fill #ffec73 -tag theRect
  8. pack .cv
  9. bind .cv <Enter> {
  10.     .cv itemconfigure theRect -outline #e0e0e0 -fill #0000ff
  11. }
  12. bind .cv <Leave> {
  13.     .cv itemconfigure theRect -outline #c0c0c0 -fill #ffec73
  14. }
  15. label .t -text "Hello world" -bg red -font {Helvetica -40 bold}
  16. pack .t
  17.  
Advertisement
RAW Paste Data Copied
Advertisement