ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> Tclplugin-core
Tclplugin-core
Re: [Tclplugin-core] can not input text/entry widget.
by Taguchi Takeshi other posts by this author
Nov 25 2003 7:29AM messages near this date
Re: [Tclplugin-core] using policy javascript | RE: [Tclplugin-core] can not input text/entry widget.
Sorry, Jeff.

I'm using apache rivet. so *.tcl file is evaluated as rivet
acript firstly.
Rivet is a "Tcl" interp. so any Tk command get errors.

I've modify my apache httpd.conf file. then this probrem was
resolved.

By the way, I think current tclplugin assume all tclet is
 wrriten using UTF-8 encoding.
This means, in the web page which is writen euc-jp encoding,
SCRIPT itself must use UTF-8 encoding.
Euc-jp encoded file can not contain any UTF-8 string.

I think tclet encoding may be able to set by tclet author.
such as:
   <embed type="x-application/tcl"
	  src="./sample-tclet.tcl"
	  charset="euc-jp" ...> 

So I've made a patch.

BEGIN> --8<CUT HERE>8---
--- library/browser.tcl~	Tue Dec 24 08:05:53 2002
+++ library/browser.tcl	Tue Nov 25 13:53:13 2003
@@ -690,6 +690,14 @@
 	    return
 	}
 
+	# convert from external encoding to utf-8 using charset arg..
+	if {[interp eval $name [list info exists embed_args(charset)]] && +		[lsearch [encoding na
mes] +		     [set encoding [interp eval $name +					[list set embed_args(charset)]]]] >  -1} 
{
+	    set chunk [encoding convertfrom $encoding $chunk]
+	}
+
 	IAppend $name stream,$stream,data $chunk
 	log $name "stored data for $stream in stream,$stream,data attr"
END> ---8<CUT HERE>8--- 

Thanks.
--
T.Taguchi.




-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
_______________________________________________
Tclplugin-core mailing list
Tclplugin-core@[...].net
https://lists.sourceforge.net/lists/listinfo/tclplugin-core
Thread:
Taguchi Takeshi
Jeff Hobbs

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved