Python-based browser plugins?

Stuart D. Gathman stuart at bmsi.com
Thu Oct 31 08:05:07 EST 2002


On Thu, 31 Oct 2002 01:46:38 -0500, Terry Hancock wrote:


> Actually it was the "open spec" part that my source claimed was not the
> case -- i.e. that Sun took the legal position that their spec was
> covered by the "Sun Community Source License" and that software based on
> it was therefore covered (making the SCSL essentially a non-disclosure
> agreement -- you can only read it if you promise not to implement it, or
> that implementations of it would be owned by Sun).

I haven't heard about this.  I'd better check it out before worrying about
getting all our machine upgraded to Java 2 . . .

> Anyway, though -- returning to topic, is a C Python solution unviable?
> Your defending the Java/Jython option suggests maybe you think so (and
> that was what I thought before).  I guess I already know the answer here
> -- but I was wondering if the challenge would pique anyone's interest,
> as it would be interesting to be proved wrong. :-)

Here are some ways that C Python could be made to work in standard
browsers cross platform:

1) Write a netscape plugin ala Flash for all the platforms that provides
Python scripted GUI windows.  (Probably too much work for your project,
unless someone has already done this.)

2) Write a Java applet that loads C Python and communicates with it via a
Socket to support GUI windows.  The Python code sends commands over the
socket to the Java code telling it to open a window, draw a box, etc. The
Java code sends UI events over the socket to the Python code.

Having implemented a system like (2) for a Text mode implementation of
AWT, I can say it would be doable in a month or two.  The technique is
amenable to the cummulative approach of Extreme Programming.  Initially,
support only a bare minimum of commands and events, stop when its complete
enough for your application, open source it so others can add to it.
Everything would be pure Java and pure Python - so no nasty native
debugging.

TUI AWT	  http://www.bmsi.com/tuipeer/

-- 
	      Stuart D. Gathman <stuart at bmsi.com>
Business Management Systems Inc.  Phone: 703 591-0911 Fax: 703 591-6154
"Confutatis maledictis, flamis acribus addictis" - background song for
a Microsoft sponsored "Where do you want to go from here?" commercial.



More information about the Python-list mailing list