From 0b7971da5dcae970ce150cab4622f190407646ec Mon Sep 17 00:00:00 2001 From: hobbs Date: Mon, 30 May 2005 23:41:00 +0000 Subject: * library/console.tcl (::tk::ConsoleInit): print out first prompt and swallow the extra "% " that comes once from Tcl on Windows. FossilOrigin-Name: 0dd38a012e3cdcff47757caf41b5444efb7d5e4d --- ChangeLog | 5 +++++ library/console.tcl | 8 +++++++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 6e7996c..3b9cec8 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2005-05-30 Jeff Hobbs + + * library/console.tcl (::tk::ConsoleInit): print out first prompt + and swallow the extra "% " that comes once from Tcl on Windows. + 2005-05-29 Daniel Steffen * macosx/tkMacOSXFont.c: use Tcl_Panic instead of panic. diff --git a/library/console.tcl b/library/console.tcl index 1d0ff03..1462175 100644 --- a/library/console.tcl +++ b/library/console.tcl @@ -4,7 +4,7 @@ # can be used by non-unix systems that do not have built-in support # for shells. # -# RCS: @(#) $Id: console.tcl,v 1.26 2004/11/17 22:16:44 hobbs Exp $ +# RCS: @(#) $Id: console.tcl,v 1.27 2005/05/30 23:41:01 hobbs Exp $ # # Copyright (c) 1995-1997 Sun Microsystems, Inc. # Copyright (c) 1998-2000 Ajuba Solutions. @@ -136,6 +136,12 @@ proc ::tk::ConsoleInit {} { tk::TextSetCursor $con end $con mark set promptEnd insert $con mark gravity promptEnd left + + ConsolePrompt + if {$tcl_platform(platform) eq "windows"} { + # Subtle work-around to erase the '% ' that tclMain.c prints out + after idle [list $con delete 1.0 output] + } } # ::tk::ConsoleSource -- -- cgit v0.12