Posted to tcl by zipguy at Thu Nov 21 17:47:10 GMT 2013view raw

  1. set _TT(pgm) "TT"
  2. set _TT(pgmName) "$_TT(pgm) - Tkcon test"
  3. set _TT(verMajor) "0"
  4. set _TT(verMinor) "01"
  5. set _TT(minutae) "a"
  6. # -- update checker variables
  7. set _TT(thisVerNumeric) $_TT(verMajor)$_TT(verMinor)
  8. # -- Display Version variables
  9. set _TT(ver) "v$_TT(verMajor).$_TT(verMinor)$_TT(minutae)"
  10. set _TT(pgmNameFull) "$_TT(pgmName) $_TT(ver)"
  11. set _TT(asofdate) "2013/11/21"
  12.  
  13. namespace eval ::tkcon {}
  14.  
  15. # we want to have only the main interpreter
  16. set ::tkcon::OPT(exec) ""
  17.  
  18. source tkcon.tcl
  19. package require tkcon
  20. # set ::tkcon::PRIV(root) .con.tkcon ;# optional---defaults to .tkcon
  21.  
  22. wm title . $_TT(pgmNameFull)
  23.  
  24. set f .a
  25. frame $f
  26. pack $f
  27.  
  28. # set ::tkcon::PRIV(root) .con ;# optional---defaults to .tkcon
  29. label $f.a -width 80
  30. pack $f.a
  31.  
  32. button $f.b -text Console -command { tkcon show }
  33. pack $f.b
  34.  
  35. set f .con
  36. frame $f -bg seashell2
  37. pack $f -side bottom
  38.  
  39. label $f.a -text "this is above where I'd like the console to go" -bg seashell2
  40. pack $f.a -fill both
  41.  
  42.  
  43. # set ::tkcon::PRIV(root) .tkcon ;# optional---defaults to .tkcon
  44. set ::tkcon::PRIV(root) .con.tkcon ;# optional---defaults to .tkcon
  45. # tkcon show
  46. # tkcon gets