Re: How to integrate tcl with VC++

From: David Gravereaux (davygrvy_at_pobox.com)
Date: 11/28/03


Date: Fri, 28 Nov 2003 01:21:26 -0800

yubing_jin@263.net (Michael Jin) wrote:

>David Gravereaux <davygrvy@pobox.com> wrote in message news:<0dkbsvc3mnjag6eob028usegb6b76i3r0q@4ax.com>...
>> >I compiled the simple1,when I running the program,
>> >an error window appears. it includes" This application requires tcl8.1
>> >or greater", I've already add c:\tcl\include;c:\tcl\include\X11 to the
>> >include files directory and c:\tcl\lib\ to the library directory, I
>> >wonder if I need change other settings to my VC++6.0 environment?
>>
>> a registry misunderstanding with ActiveTcl. here's the fix:
>>
>> package require Tcl 8.3 ;# at least 8.3
>> package require registry
>>
>> set key "HKEY_LOCAL_MACHINE\\Software\\Scriptics\\Tcl\\$tcl_version"
>>
>> if {[catch {registry get $key Root}]} {
>> puts stderr "not found... creating compatibility key..."
>> registry set $key Root \
>> [file native [file dirname [file dirname [info name]]]] \
>> sz
>> }
>
> sorry,here I have another question.
> when I compile the multipad.cpp, an error shows "LINK : fatal error
>LNK1104: cannot open file "mfc42ud.lib"", I searched my computer,but
>can't find this file. what's wrong with it?

Don't build for unicode.

> When I call tcl script in a MFC-based application, the application
>stopped without any messages. Is it caused by the event loop
>contradictory?

Don't call Tcl_EvalFile directly. Send it a job instead. Tcl_EvalFile
doesn't return until it is done running the script. By placing the work
into Tcl's thread, which is what TES does, the GUI will not freeze.

>I have tried a console appication,it works well.
> As I said above,I want to program the GUI with MFC,but it seems that
>the MFC
>is hard to cooperate with tcl?
> thank you for your concern.

-- 
David Gravereaux <davygrvy@NOSPAM.pobox.com>
[species: human; planet: earth,milkyway(western spiral arm),alpha sector]
http://thomas.loc.gov/cgi-bin/bdquery/z?d108:S.877:
S.877 passed, get ready for the SPAM onslaught like never seen before...
Opt-Out places the burden on the receiver. Opt-In is the future.


Relevant Pages

  • Re: static or not?
    ... Well, I'm not sure what you mean by a, "Driver," class, so I'll take a ... Driver was not accessible outside its package. ... GUI, the implementation of many classes within that package might be ... could all register their View interface in the Registry. ...
    (comp.lang.java.help)
  • Re: No sound...?
    ... major pain to use that sort of thing. ... TeX proper helps a lot with that. ... Admittedly, neither are exactly GUI ... My rmpage package needs re-writing ...
    (uk.comp.sys.mac)
  • U++ 4193 released
    ... "Framebuffer" package uses Rainbow to implement GUI for trivial RGBA ... Layout files are now syntax highlighted, ... plugin/tif is upgraded to version 1.43. ...
    (comp.os.linux.development.apps)
  • Re: From console to GUI
    ... Thanks to the package management, ... GUI application. ... If you really depend on a windows application, ... I have been poking around a little bit to now move my laptop to debian; ...
    (Debian-User)
  • Re: Dolphin on Wine - starting to look good
    ... GUI, viral DRM stupidity, software and hardware incompatibility, annoying ... Understood that Dolphin is innocent, but it is also tied to Windows. ... I am fairly certain I would be running all Linux servers at this point were it not for that fact. ... Unicode by default, i.e. all strings are Unicode strings, all GUI ...
    (comp.lang.smalltalk.dolphin)