Re: Urgent ! place the Console Window inside the GUI



p.senthilkumaran@xxxxxxxxxxxxxx wrote:
> Hi Friends,
>
> I am developing GUI application in tcltk, i want the console window to
> be a part of my GUI,
> when we give "console show" the console window will be displaying
> behind the application,
> but i want it to be placed inside the GUI, as a part of the GUI, like
> debug window in vc++,
>
> i am waiting for the reply, if it is not too much of trouble to u, as
> this is the urgent one.
>
> thanks in advance
>

Does it HAVE TO BE the console? Or do you just want a tcl "command
line"?
For a command line, I usually use the following for debugging:

pack [text .con -yscrollcommand {.con.s set}] -fill both
pack [scrollbar .con.s -command {.con yview}] -fill y -side right
..con insert end ">"

bind .con <Key-Return> {
set command [.con get "end -1 lines" "end -1 char"]
set command [string trimleft $command "> "]
.con insert end [eval $command]
}

bind .con <KeyRelease-Return> {
.con insert end ">"
.con yview moveto 1
}

Of course, it can be more sophisticated such as displaying error
messages with bgerror and preventing you from deleting the prompt ">".
The above is just a simple stripped-down example.

.



Relevant Pages

  • RE: Console::Writeline()
    ... I suspect you are calling Console::Writelinein a GUI MFC application. ... Win32 GUI system will not spawn any console window for Console::Writeline, ... Microsoft Online Community Support ... where an initial response from the community or a Microsoft Support ...
    (microsoft.public.dotnet.languages.vc)
  • Re: Command Line Interface
    ... > Netbean's 'console window' which it uses for user input and output. ... > understand the problem is tho that Java is a interpretted language and I ... > GUI for them I wanted to impliment a streamed command line mode to edit them ... > in the apps GUI' instead of having to provide dialogs for all of them. ...
    (microsoft.public.vc.mfc)
  • Re: TIP #199: Specification of Alternatives to .wishrc/.tclshrc
    ... I figure that if I've already paid the price ... > for the GUI, I can easily drop in TkCon as ... > console window. ...
    (comp.lang.tcl)
  • Re: Communicate with Console window
    ... then the GUI can send command to console window and get result ... > Anyone who can give me suggestion or idea will be highly appreciated. ...
    (microsoft.public.win32.programmer.kernel)
  • Urgent ! place the Console Window inside the GUI
    ... I am developing GUI application in tcltk, i want the console window to ...
    (comp.lang.tcl)