Error processing request

Parameters

CONTENT_LENGTH0
REQUEST_METHODGET
REQUEST_URI/revision/XiRCON%2DII?V=129
QUERY_STRINGV=129
CONTENT_TYPE
DOCUMENT_URI/revision/XiRCON-II
DOCUMENT_ROOT/var/www/nikit/nikit/nginx/../docroot
SCGI1
SERVER_PROTOCOLHTTP/1.1
HTTPSon
REMOTE_ADDR172.70.127.169
REMOTE_PORT46158
SERVER_PORT4443
SERVER_NAMEwiki.tcl-lang.org
HTTP_HOSTwiki.tcl-lang.org
HTTP_CONNECTIONKeep-Alive
HTTP_ACCEPT_ENCODINGgzip, br
HTTP_X_FORWARDED_FOR3.12.34.178
HTTP_CF_RAY87ee7f192afde168-ORD
HTTP_X_FORWARDED_PROTOhttps
HTTP_CF_VISITOR{"scheme":"https"}
HTTP_ACCEPT*/*
HTTP_USER_AGENTMozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; [email protected])
HTTP_CF_CONNECTING_IP3.12.34.178
HTTP_CDN_LOOPcloudflare
HTTP_CF_IPCOUNTRYUS

Body


Error

Unknow state transition: LINE -> END

-code

1

-level

0

-errorstack

INNER {returnImm {Unknow state transition: LINE -> END} {}} CALL {my render_wikit XiRCON-II \[DG\]\ is\ authoring\ an\ \[IRC\]\ Client.\ \ It\ is\ a\ work\ in\ progress.\ \ beta\ @\ http://sourceforge.net/project/showfiles.php?group_id=1616&release_id=196759\ .\n----\nThis\ IRC\ client\ is\ a\ faithful\ \[XiRCON\]\ \[http://www.xircon.com\]\ clone\ regarding\ how\ the\ user\ scripting\ operates.\ \ Here\ are\ some\ screenshots:\n\ \ \ *\ Doing\ Japanese:\n\[http://tomasoft.sf.net/in_a_japanese_channel.gif\]\n\ \ \ *\ Doing\ Chinese:\n\[http://tomasoft.sf.net/263.gif\]\n\ \ \ *\ Doing\ Klingon\ (in\ utf-8\ over\ IRC\ and\ back\ using\ the\ CTCP/2\ method\ of\ escaping):\n\[http://tomasoft.sf.net/klingon.gif\]\n\ \ \ *\ Elvish\ (layer\ 1\ ConScript):\n\[http://tomasoft.sourceforge.net/elvish.gif\]\n\ \ \ *\ being\ normal\ (boring):\n\[http://tomasoft.sf.net/in_an_english_channel.gif\]\n----\nThe\ client\ has\ been\ ''painfully''\ designed\ to\ be\ 2\ complimentary\ halves:\n\ \ \ 1.\ The\ back-end\ \ \ :\ \ \ The\ irc_engine\ Tcl\ extension\ DLL\ (100%\ Tcl\ API\ only,\ with\ a\ little\ STL)\ for\ handling\ everything\ that\ is\ not\ seen\ (ie.\ sockets,\ scripts,\ default\ behavior,\ IAL,\ etc..).\n\ \ \ 2.\ The\ UI\ \ \ :\ \ \ Whatever\ UI\ the\ user\ prefers\ according\ to\ the\ command\ control\ API.\ \ It\ could\ done\ in\ Tk,\ an\ implimentation\ in\ curses,\ Win32\ GUI,\ or\ as\ odd\ as\ streaming\ html\ output\ with\ form\ input\ for\ posting.\n----\n'''The\ IRC_Engine\ back-end'''\ --\n\nThe\ irc_engine\ extension\ provides\ a\ single\ \[Incr\ Tcl\]\ class.\ \ The\ UI\ half\ (partialy\ undefined)\ also\ provides\ an\ \[Incr\ Tcl\]\ class.\ \ The\ two\ are\ brought\ together\ using\ inheritence\ like\ so:\n\n======\n\ source\ irc_engine.itcl\n\ \n\ #\ ===============================================================\n\ #\ By\ selecting\ which\ IRC::ui\ class\ is\ sourced,\ we\ can\ switch\n\ #\ to\ what\ UI\ we\ want\ to\ use.\n\ #\ ===============================================================\n\ source\ irc_ui.itcl\n\ \n\ itcl::class\ IRC::connection\ \{\n\ \n\ \ \ \ #\ ===============================================\n\ \ \ \ #\ Bring\ the\ 2\ halves\ together\ using\ inheritence.\n\ \ \ \ #\ ===============================================\n\ \ \ \ inherit\ engine\ ui\n\ \n\ \ \ \ constructor\ \{args\}\ \{\n\ \ \ \ \ \ \ \ eval\ engine::constructor\ \$args\n\ \ \ \ \}\ \{\}\n\ \ \ \ public\ method\ destroy\ \{\}\ \{itcl::delete\ object\ \$this\}\n\ \}\n\ \n\ ###\ Create\ a\ connection\ instance\ with\ a\ couple\ user\ scripts.\n\ set\ a\ \[IRC::connection\ #auto\ someUserScript1.tcl\ someUserScript2.tcl\]\n\ \n\ ###\ Connect\ to\ IRC.\n\ \$a\ connect\ irc.qeast.net\ davygrvy\ DG\ \{yo\ moma!\}\n======\n\nIn\ the\ above,\ \$a\ is\ now\ the\ connection\ object.\ \ All\ behavior\ of\ the\ engine\ is\ located\ in\ a\ script\ file\ called\ default.tcl\ \[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/tomasoft/tomahawk/irc_engine/library/default.tcl?rev=HEAD&content-type=text/vnd.viewcvs-markup\].\ \ The\ behavior\ of\ irc_engine\ can\ be\ scripted\ by\ the\ user\ by\ loading\ scripts\ which\ are\ queried\ for\ event\ hooks\ prior\ to\ doing\ the\ default\ behavior.\ \ I\ do\ have\ a\ generic\ framework\ to\ the\ system,\ but\ only\ Tcl\ is\ supported.\ \ I\ have\ code\ started\ for\ perl,\ python,\ and\ java,\ but\ I'll\ have\ to\ get\ back\ to\ it\ later\ \[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/tomasoft/tomahawk/irc_engine/generic/IRCUserScriptProvider.hpp?rev=HEAD&content-type=text/vnd.viewcvs-markup\].\n\nHere's\ where\ it\ gets\ interesting\ for\ user\ scripts..\ \ Each\ tcl\ user\ script\ is\ run\ in\ its\ own\ interpreter.\ \ It\ maintains\ some\ of\ its\ own\ commands\ such\ as\ \[\[IRC::on\]\],\ but\ aliases\ most\ up\ to\ the\ global\ interp\ (I\ also\ call\ it\ the\ controlling\ or\ UI\ interp).\ \ So\ from\ the\ script,\ a\ call\ to\ ''IRC::echo\ ...''\ will\ alias\ up\ to\ the\ global\ as\ ''connection0\ echo\ ...''\ where\ connection0\ is\ the\ \[Incr\ Tcl\]\ object.\ \ This\ allows\ us\ to\ have\ our\ scripts\ track\ with\ their\ connection\ object.\ \ Where\ this\ gets\ more\ interesting\ is\ that\ from\ this\ aliasing,\ I\ can\ ''assume''\ commands\ that\ will\ be\ in\ the\ top-most\ object\ that\ are\ provided\ by\ the\ UI\ (thanks\ to\ inheritence).\ \ The\ echo\ method\ is\ located\ in\ the\ UI\ half,\ yet\ the\ user\ script\ is\ in\ a\ separate\ interp\ of\ the\ irc_engine\ extension\ half\ and\ always\ linked\ to\ its\ parent\ object.\n\nirc_engine\ uses\ Tcl's\ event\ loop.\ \ This\ diagram\ shows\ some\ of\ the\ code\ paths:\n\n\[http://tomasoft.sf.net/incoming_trail.gif\]\n\nTcl::Socket\ is\ just\ a\ wrapper\ for\ Tcl's\ socket\ API\ stuff.\ \ When\ a\ line\ from\ the\ server\ is\ received,\ it\ is\ parsed\ into\ its\ protocol\ parts\ \[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/tomasoft/tomahawk/irc_engine/generic/IRCParse.hpp?rev=HEAD&content-type=text/vnd.viewcvs-markup\]\ \[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/tomasoft/tomahawk/irc_engine/generic/IRCParse.cpp?rev=HEAD&content-type=text/vnd.viewcvs-markup\]\ and\ is\ the\ container\ for\ the\ parts\ that\ will\ get\ passed\ around\ to\ the\ subsiquent\ modules.\ \ IRCSplitAndQ\ \[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/tomasoft/tomahawk/irc_engine/generic/IRCSplitAndQ.hpp?rev=HEAD&content-type=text/vnd.viewcvs-markup\]\ \[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/tomasoft/tomahawk/irc_engine/generic/IRCSplitAndQ.cpp?rev=HEAD&content-type=text/vnd.viewcvs-markup\]\ is\ responsible\ for\ any\ text\ mappings\ (or\ multiple\ mappings)\ that\ need\ to\ be\ decoded,\ any\ CTCP/2\ encoding\ escapes,\ any\ CTCP\ unquoting,\ any\ mode\ splitting,\ and\ removing/queueing\ of\ all\ embedded\ CTCP\ commands\ prior\ to\ the\ edited\ original\ getting\ posted\ as\ a\ job\ to\ the\ event\ loop.\ \ Phew!\n\n\[http://tomasoft.sf.net/ircevent_trail.gif\]\n\nWhen\ a\ job\ we\ had\ posted\ from\ IRCSplitAndQ\ is\ ready\ to\ be\ serviced\ by\ Tcl,\ our\ Tcl_EventProc\ named\ ''EvalCallback''\ is\ called\ which\ just\ sets\ an\ interp\ lock\ then\ calls\ ''IRCEngine::EvalOneIRCEvent''\ in\ the\ correct\ connection\ object\ \[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/tomasoft/tomahawk/irc_engine/generic/IRCEngine.hpp?rev=HEAD&content-type=text/vnd.viewcvs-markup\]\ \[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/tomasoft/tomahawk/irc_engine/generic/IRCEngine.cpp?rev=HEAD&content-type=text/vnd.viewcvs-markup\].\ \ Within\ the\ Tcl_Event\ structure\ is\ our\ IRCParse\ C++\ object\ all\ prepared\ to\ be\ serviced.\ \ First\ we\ run\ ''PreEvent(line)'',\ so\ certain\ IRC\ events\ such\ as\ 'join'\ can\ be\ set\ into\ the\ channels\ list\ prior\ to\ scripts\ being\ run.\ \ The\ same\ is\ true\ in\ the\ inverse,\ as\ a\ 'part'\ event\ will\ be\ removed\ from\ the\ channels\ list\ from\ ''PostEvent()''.\ \ Space\ is\ left\ here\ for\ the\ inclusion\ of\ an\ ''Internal\ Address\ List''\ when\ I\ get\ around\ to\ it.\n\nNow\ after\ ''PreEvent()''\ is\ run,\ all\ script\ providers\ in\ LIFO\ order\ are\ handed\ the\ IRCParse\ object.\ \ If\ any\ of\ the\ providers\ return\ ''IRCUserScriptProvider::COMPLETED''\ (an\ enum),\ then\ the\ event\ is\ considered\ complete\ and\ all\ processing\ stops.\ \ If\ no\ providers\ claim\ the\ event\ as\ completed,\ then\ the\ default\ script\ will\ process\ it.\ \ If\ the\ default\ script\ doesn't\ handle\ it,\ and\ the\ mode\ for\ the\ connection\ is\ 'debugging'\ rather\ than\ normal,\ it\ will\ be\ displayed\ in\ red\ in\ the\ status\ window\ with\ event\ name\ or\ numeric.\ \ Same\ as:\n\n======\n\ echo\ \"\\006CC\\006***\\006C\\006\ \[event\]\ \[join\ \[lrange\ \[args\]\ 1\ end\]\]\"\ status\n=====\n\nWithout\ the\ debugging\ mode,\ no\ red\ color\ or\ event\ code\ is\ displayed.\ \ Same\ as:\n\n======\n\ echo\ \"***\ \[join\ \[lrange\ \[args\]\ 1\ end\]\]\"\ status\n======\n\n----\n\nHere's\ an\ example\ of\ the\ user\ scripting\ and\ how\ identical\ it\ is\ to\ the\ '''idea'''\ of\ XiRCON.\ \ Old-time\ XiRCON'ers\ will\ notice,\ of\ course,\ the\ new\ use\ of\ namespaces\ and\ the\ msgcat\ package\ for\ handling\ multilingual\ strings.\ \ We\ must\ improve\ on\ XiRCON,\ too.\n\n======\n\ package\ require\ Xircon\ 2.0\n\ \n\ namespace\ eval\ ::IRC\ \{\n\ \ \ \ on\ PRIVMSG\ \{\n\ \ \ \ \ \ \ \ set\ dest\ \[lindex\ \[args\]\ 0\]\n\ \ \ \ \ \ \ \ set\ msg\ \[lindex\ \[args\]\ 1\]\n\n\ \ \ \ \ \ \ \ ###\ ignore\ an\ empty\ one.\n\ \ \ \ \ \ \ \ if\ \{!\[string\ length\ \$msg\]\}\ \{complete\;\ return\}\n\n\ \ \ \ \ \ \ \ if\ \{!\[icomp\ \$dest\ \[my_nick\]\]\}\ \{\n\ \ \ \ \ \ \ \ \ \ \ \ ###\ private\ msg\n\ \ \ \ \ \ \ \ \ \ \ \ echo\ \"\[color\ highlight\]*\[color\ nick\]\[nick\]\[color\ highlight\]*\[color\ private\]\ \$msg\"\ query\ \[nick\]\n\n\ \ \ \ \ \ \ \ \}\ elseif\ \{\[string\ index\ \$dest\ 0\]\ ==\ \"\\\$\"\}\ \{\n\ \ \ \ \ \ \ \ \ \ \ \ ###\ server\ (global)\ message\n\ \ \ \ \ \ \ \ \ \ \ \ echo\ \"\[color\ highlight\]<\[color\ nick\]\[nick\]\[color\ highlight\]>\[color\ default\]\ \$msg\"\ status\n\n\ \ \ \ \ \ \ \ \}\ else\ \{\n\ \ \ \ \ \ \ \ \ \ \ \ echo\ \"\[color\ highlight\]<\[color\ nick\]\[nick\]\[color\ highlight\]>\[color\ default\]\ \$msg\"\ channel\ \$dest\n\n\ \ \ \ \ \ \ \ \}\n\ \ \ \ \ \ \ \ complete\n\ \ \ \ \}\n\ \ \ \ on\ \$RPL_TOPICWHOTIME\ \ \ \ \ \{\n\ \ \ \ \ \ \ \ echo\ \"\[color\ change\]***\ \[mc\ \{Topic\ for\}\]\ \[color\ channel\]\[lindex\ \[args\]\ 1\]\[color\ change\]\ \[mc\ \{was\ set\ by\}\]\ \[color\ nick\]\[lindex\ \[args\]\ 2\]\[color\ change\]\ \[mc\ \{on\}\]\ \[clock\ format\ \[lindex\ \[args\]\ 3\]\]\"\n\ \ \ \ \ \ \ \ complete\n\ \ \ \ \}\n\ \ \ \ on\ \$RPL_UMODEIS\ \ \ \ \ \ \ \ \ \{\n\ \ \ \ \ \ \ \ echo\ \"\[color\ change\]***\ \[mc\ \{Your\ modes\ are\}\]\ \[color\ mode\]\\\"\[join\ \[lrange\ \[args\]\ 1\ end\]\]\\\"\"\ status\n\ \ \ \ \ \ \ \ complete\n\ \ \ \ \}\n\ \}\n======\n\nAs\ in\ XiRCON,\ these\ are\ the\ commands\ available\ to\ an\ event\ hook\ for\ asking\ about\ the\ line\ that\ fired\ the\ event:\n\n\[http://tomasoft.sf.net/ircparser.gif\]\n\nNot\ shown\ is\ '''raw_line'''\ and\ it\ returns\ the\ whole\ thing\ as\ a\ string\ prior\ to\ any\ processing.\ \ '''raw_args'''\ is\ also\ prior\ to\ any\ processing.\ \ All\ return\ strings\ except\ for\ '''args'''\ which\ is\ a\ list\ (and\ is\ very\ processed).\ \ '''raw_line'''\ will\ be\ empty\ for\ any\ embedded\ event\ such\ as\ ''ctcp''\ or\ ''mode+o''.\ \ '''nick'''\ will\ equal\ '''host'''\ for\ a\ server\ message.\n\nUnlike\ XiRCON,\ a\ PRIVMSG\ event\ that\ contains\ a\ CTCP\ in\ its\ entire\ trailing\ param,\ will\ fire\ a\ PRIVMSG\ anyway,\ even\ though\ it\ will\ be\ empty.\ \ It\ may\ seem\ silly\ at\ first,\ but\ the\ original\ '''raw_line'''\ would\ then\ have\ no\ way\ to\ get\ through.\ \ Think\ about\ it\ for\ a\ sec...\ \ It\ was\ a\ PRIVMSG\ that\ came\ in,\ and\ just\ so\ happened\ to\ contain\ within\ it\ a\ CTCP.\ \ It\ doesn't\ make\ sense\ to\ me\ to\ drop\ the\ original\ PRIVMSG.\ \ That\ was\ the\ event.\ \ Same\ is\ true\ for\ a\ NOTICE\ with\ a\ '''ctcp_reply'''.\n----\n'''The\ UI\ Half'''\ --\n\nThe\ first\ major\ feature\ is\ the\ support\ of\ '''ALL'''\ embedded\ text\ attributes\ ever\ known\ to\ mankind\ and\ robots\ alike.\ \ It\ supports\ ircII,\ mIrc,\ ANSI,\ besirc/hydra,\ and\ CTCP/2.\ \ As\ CTCP/2\ is\ the\ most\ in\ features,\ this\ is\ the\ native\ usage\ of\ the\ display.\ \ The\ other\ attribute\ types\ are\ pre-translated\ up\ to\ CTCP/2.\ \ The\ CTCP/2\ parser\ is\ also\ in\ the\ IRC_Engine\ as\ an\ Itcl\ class\ for\ use\ by\ Tk\ applications.\n\nCTCP/2\ embedded\ text\ attributes\ are\ described\ @\ http://www.lag.net/~robey/ctcp\ .\ \ All\ attibutes\ in\ section\ 2\ are\ supported\ ->\ http://www.lag.net/~robey/ctcp/ctcp2.2.txt\ .\ \ One\ extension\ was\ added\ using\ the\ CTCP/2\ method\ for\ extending,\ for\ doing\ the\ tag\ color\ types.\ \ This\ will\ be\ especially\ useful\ for\ a\ UI\ in\ Tk\ and\ allows\ the\ display\ to\ define\ how\ \"normal\",\ \"highlight\",\ etc..\ will\ be\ rendered\ rather\ than\ the\ parser\ filling\ in\ literal\ values.\ \ These\ tag\ colors\ are\ returned\ by\ the\ color\ command\ and\ are\ not\ intended\ for\ transmision\ --\ internal\ use\ only.\ \ Similar\ to\ XiRCON's\ \\aXX\ color\ codes\ where\ X\ is\ a\ hexadecimal\ number.\n\nIt\ should\ be\ noted\ that\ the\ parser\ reads\ it\ all,\ and\ whether\ an\ implimentation\ of\ a\ UI\ does\ actually\ do\ the\ attributes\ is\ a\ bit\ outside\ of\ my\ claims.\ \ For\ example,\ if\ I\ make\ a\ Win32\ console\ text-mode\ UI\ for\ this\ client,\ I\ will\ have\ a\ choice\ of\ only\ 12\ colors.\ \ As\ a\ 24-bit\ depth\ is\ available\ to\ the\ CTCP/2\ color\ attribute,\ the\ 24-bit\ value\ will\ need\ to\ be\ truncated\ for\ that\ display\ type\ (ie.\ 256\ levels\ of\ red\ get\ mashed\ to\ 3\ levels,\ off/on/bright).\n\nI\ should\ slow\ down\ for\ a\ moment\ and\ say\ that\ the\ UI\ is\ more\ of\ an\ API\ than\ an\ actual\ complete\ and\ realized\ implimention.\n\nTo\ better\ describe\ the\ concept\ of\ implementation\ separate\ from\ the\ UI,\ here\ is\ an\ example\ of\ a\ UI\ that\ generates\ HTML\ as\ its\ output\ (a\ little\ DHTML\ with\ CSS)\ \[http://cvs.sourceforge.net/viewcvs.py/tomasoft/tomahawk/irc_ui/library/irc_ui_html.itcl?rev=HEAD&view=auto\].\ \ With\ \[DKF\]'s\ help\ pointing-out\ the\ usefulness\ of\ \[CSS\],\ it\ sure\ helped\ me\ out.\n\nThis\ is\ the\ output\ \[http://tomasoft.sf.net/irc_output.html\]\ of\ this\ UI\ script\ on\ a\ few\ channels\ on\ EfNet\ \[http://www.efnet.org\].\n\nThe\ HTML\ looks\ great.\ \ I\ like\ the\ timestamp\ in\ the\ balloon\ help\ (kinda\ kitch).\ \ I'm\ amazed\ how\ identical\ I\ got\ it\ to\ look\ to\ my\ test\ GUI\ done\ with\ a\ windows'\ richedit\ control.\ \ The\ only\ problem\ I\ see\ is\ the\ handling\ of\ whitespace.\ \ In\ the\ main\ <div>\ rule,\ I\ tried\ setting\ ''white-space:\ pre''\ so\ multiple\ spaces\ aren't\ truncated,\ but\ alas,\ IE6\ is\ not\ doing\ this\ for\ me.\ \ Using\ an\ open-ended\ <pre>\ works,\ but\ wouldn't\ generate\ valid\ HTML\ in\ this\ manner.\ \ This\ must\ be\ a\ bug\ in\ IE6..\n\nYes,\ IE6\ does\ have\ bugs.\ \ ''text-decoration:\ blink''\ is\ also\ not\ supported.\ \ It\ seems\ if\ I\ set\ the\ <!DOCTYPE>\ to\ strict\ mode,\ ''white-space:\ pre''\ will\ start\ working,\ but\ then\ wrapping\ stops.\ \ So\ I\ tried\ &nbsp\;\ to\ replace\ multiple\ spaces\ and\ dropped\ ''white-space:\ pre''\ from\ the\ <div>\ rule.\ That\ finally\ got\ it.\n\n----\n\n'''(5:28\ PM\ 11/13/2003)'''\n\nI\ put\ the\ test\ RichEdit\ terminal\ window\ into\ an\ MDI\ frame\ and\ used\ \[TES\]\ to\ run\ tcl,\ so\ I'm\ getting\ closer\ to\ a\ real\ GUI\ on\ win32.\ \ Mine\ is\ on\ the\ left.\ \ The\ goal\ is\ to\ clone\ the\ one\ on\ the\ right.\ \ None\ of\ the\ menus\ or\ toolbar\ button\ do\ anything\ yet,\ so\ I'm\ using\ tkcon\ to\ control\ the\ windows\ at\ the\ moment.\ \ The\ connect\ dialog\ is\ next\ on\ the\ list.\ \ Conceptually,\ all\ it\ will\ do\ is\ Tcl_Eval(\"\$a\ connect\ ...\")\;\ just\ like\ I'm\ doing\ from\ tkcon.\ \ Sweet,\ eh?\ \ A\ global\ interp\ for\ controlling\ the\ behavior\ of\ the\ app\ is\ truly\ a\ beautiful\ thing.\ \ I\ will\ retain\ this\ wonderful\ concept\ as\ much\ and\ as\ deeply\ as\ I\ can\ for\ all\ aspects\ of\ the\ GUI.\ \ I'll\ even\ store\ settings\ in\ tcl\ variables..\ \ Who\ needs\ C++\ for\ everything?\ \ Just\ make\ a\ shell\ and\ use\ Tcl\ for\ the\ logic..\ \ Oh..\ That's\ right..\ \[JO\]\ states\ this\ in\ \[http://www.tcl.tk/doc/integration.html#Tcl\]\n\n\[http://tomasoft.sf.net/x2_screenshot.gif\]\n\nFWIW,\ The\ Win32\ api\ CreateMDIWindow()\ isn't\ as\ well\ documented\ as\ it\ should\ be.\ \ The\ last\ argument\ is\ for\ any\ create\ params,\ but\ the\ lParam\ for\ WM_CREATE\ is\ NOT\ the\ same\ as\ CreateWindow,\ nor\ is\ it\ a\ MDICREATESTRUCT\ directly\ as\ the\ other\ docs\ say.\ \ It\ took\ me\ a\ while\ to\ figure\ it\ out:\n\n\ LRESULT\ CALLBACK\n\ StatBoxWndProc\ (HWND\ hwnd,\ UINT\ iMsg,\ WPARAM\ wParam,\ LPARAM\ lParam)\n\ \{\n\ \ \ \ MDICREATESTRUCT\ *lpCreateParams\;\n\n\ \ \ \ AllWin32StatBoxThreadedGUI\ *pStatGUI\ =\n\ \ \ \ \ \ \ \ \ \ \ \ reinterpret_cast\ <AllWin32StatBoxThreadedGUI\ *>\n\ \ \ \ \ \ \ \ \ \ \ \ (::GetWindowLongPtr\ (hwnd,\ GWLP_USERDATA))\;\n\n\ \ \ \ switch\ (iMsg)\n\ \ \ \ \{\n\ \ \ \ \ \ \ \ case\ WM_CREATE:\n\ \ \ \ \ \ \ \ \ \ \ \ //\ move\ the\ AllWin32StatBoxThreadedGUI\ class\ pointer\ into\ the\n\ \ \ \ \ \ \ \ \ \ \ \ //\ userdata\ of\ the\ window.\n\ \ \ \ \ \ \ \ \ \ \ \ //\n\ \ \ \ \ \ \ \ \ \ \ \ lpCreateParams\ =\ (MDICREATESTRUCT\ *)((CREATESTRUCT\ *)lParam)->lpCreateParams\;\n\n\ \ \ \ \ \ \ \ \ \ \ \ ::SetWindowLongPtr\ (hwnd,\ GWLP_USERDATA,\n\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ static_cast\ <LONG_PTR>(lpCreateParams->lParam))\;\n\ ....\n\nIt's\ first\ an\ LPCREATESTRUCT\ as\ with\ CreateWindow,\ and\ the\ ->lpCreateParams\ is\ not\ our\ answer\ but\ an\ LPMDICREATESTRUCT,\ then\ we\ get\ ->lParam\ \ from\ that\ for\ the\ answer...\ \ What\ a\ mess.\n----\n\n'''NEW!\ (4:05\ PM\ 11/16/2003)'''\n\nJust\ added\ a\ new\ \[MDI\]\ child\ window\ type\ to\ act\ as\ a\ container\ for\ Tk\ \[http://cvs.sourceforge.net/viewcvs.py/tomasoft/tomahawk/irc_ui/win32/GUI/BlankBoxImps.hpp?rev=HEAD&view=auto\]\ \[http://cvs.sourceforge.net/viewcvs.py/tomasoft/tomahawk/irc_ui/win32/GUI/BlankBoxImps.cpp?rev=HEAD&view=auto\]\ .\ \ The\ container\ protocol\ seems\ to\ be\ missing\ the\ ability\ to\ resize,\ though.\ \ I'll\ leave\ this\ for\ now,\ and\ move\ forward\ instead\ of\ banging\ my\ head\ on\ the\ desk\ trying\ to\ fix\ Tk's\ broken\ container\ protocol.\ \ It's\ fine\ for\ the\ \[Tcl/Tk\ Tclet\ Plugin\]\ as\ it's\ toplevel\ doesn't\ ever\ get\ resized.\n\n\[http://tomasoft.sf.net/x2_tkembed.gif\]\n\nCool\ stuff!!\ :)\n----\n\n(4:25\ PM\ 2/9/2008)\n\nIf\ this\ is\ a\ blog,\ I\ sure\ am\ slow\ to\ ever\ post\ anything.\ \ I\ mainly\ started\ this\ page\ as\ a\ place\ to\ write\ notes\ to\ myself\ essentially\ (pretending\ to\ explain\ to\ others\ my\ weird\ little\ project).\ \ So\ here\ is\ another\ little\ note\ to\ myself..\n\nI\ did\ prove\ that\ my\ back-end\ irc_engine.dll\ could\ run\ on\ tclhttpd\ and\ serve\ live\ IRC\ with\ html\ and\ an\ unending\ server\ connection\ (transfer-coding\ =\ \"chunked\")\ which\ was\ a\ fun\ tclhttpd\ patch\ to\ write.\ \ Although\ my\ main\ computer\ is\ down\ today\ with\ a\ sick\ harddrive\ controller,\ it\ will\ return\ and\ my\ IRC\ gateway\ to\ the\ \[Tcl\ Chatroom\]\ will\ be\ alive\ again:\n\nhttp://www.pobox.com/~davygrvy/chat/tcl\n\nNote\ to\ self:\ insert\ gateway\ script\ into\ X-2\ source\ tree\ so\ it\ doesn't\ get\ lost\ forever.\n\nI\ tried\ to\ put\ together\ a\ Jabber->IRC\ gateway\ also,\ but\ got\ a\ bit\ lost..\ \ I\ might\ pick\ it\ up\ again.\ \ Rather\ than\ how\ ijchain\ does\ it,\ I\ want\ both\ sides\ to\ equal\ represent\ each\ other\ and\ have\ the\ gateway\ create\ Jabber\ users\ for\ those\ on\ IRC,\ and\ create\ IRC\ users\ for\ the\ jabber\ ones\ to\ allow\ for\ a\ transparent\ way\ of\ linking\ both\ sides.\n\n<<categories>>\ Internet\ |\ Application\ |\ Object\ Orientation regexp2} CALL {my render XiRCON-II \[DG\]\ is\ authoring\ an\ \[IRC\]\ Client.\ \ It\ is\ a\ work\ in\ progress.\ \ beta\ @\ http://sourceforge.net/project/showfiles.php?group_id=1616&release_id=196759\ .\n----\nThis\ IRC\ client\ is\ a\ faithful\ \[XiRCON\]\ \[http://www.xircon.com\]\ clone\ regarding\ how\ the\ user\ scripting\ operates.\ \ Here\ are\ some\ screenshots:\n\ \ \ *\ Doing\ Japanese:\n\[http://tomasoft.sf.net/in_a_japanese_channel.gif\]\n\ \ \ *\ Doing\ Chinese:\n\[http://tomasoft.sf.net/263.gif\]\n\ \ \ *\ Doing\ Klingon\ (in\ utf-8\ over\ IRC\ and\ back\ using\ the\ CTCP/2\ method\ of\ escaping):\n\[http://tomasoft.sf.net/klingon.gif\]\n\ \ \ *\ Elvish\ (layer\ 1\ ConScript):\n\[http://tomasoft.sourceforge.net/elvish.gif\]\n\ \ \ *\ being\ normal\ (boring):\n\[http://tomasoft.sf.net/in_an_english_channel.gif\]\n----\nThe\ client\ has\ been\ ''painfully''\ designed\ to\ be\ 2\ complimentary\ halves:\n\ \ \ 1.\ The\ back-end\ \ \ :\ \ \ The\ irc_engine\ Tcl\ extension\ DLL\ (100%\ Tcl\ API\ only,\ with\ a\ little\ STL)\ for\ handling\ everything\ that\ is\ not\ seen\ (ie.\ sockets,\ scripts,\ default\ behavior,\ IAL,\ etc..).\n\ \ \ 2.\ The\ UI\ \ \ :\ \ \ Whatever\ UI\ the\ user\ prefers\ according\ to\ the\ command\ control\ API.\ \ It\ could\ done\ in\ Tk,\ an\ implimentation\ in\ curses,\ Win32\ GUI,\ or\ as\ odd\ as\ streaming\ html\ output\ with\ form\ input\ for\ posting.\n----\n'''The\ IRC_Engine\ back-end'''\ --\n\nThe\ irc_engine\ extension\ provides\ a\ single\ \[Incr\ Tcl\]\ class.\ \ The\ UI\ half\ (partialy\ undefined)\ also\ provides\ an\ \[Incr\ Tcl\]\ class.\ \ The\ two\ are\ brought\ together\ using\ inheritence\ like\ so:\n\n======\n\ source\ irc_engine.itcl\n\ \n\ #\ ===============================================================\n\ #\ By\ selecting\ which\ IRC::ui\ class\ is\ sourced,\ we\ can\ switch\n\ #\ to\ what\ UI\ we\ want\ to\ use.\n\ #\ ===============================================================\n\ source\ irc_ui.itcl\n\ \n\ itcl::class\ IRC::connection\ \{\n\ \n\ \ \ \ #\ ===============================================\n\ \ \ \ #\ Bring\ the\ 2\ halves\ together\ using\ inheritence.\n\ \ \ \ #\ ===============================================\n\ \ \ \ inherit\ engine\ ui\n\ \n\ \ \ \ constructor\ \{args\}\ \{\n\ \ \ \ \ \ \ \ eval\ engine::constructor\ \$args\n\ \ \ \ \}\ \{\}\n\ \ \ \ public\ method\ destroy\ \{\}\ \{itcl::delete\ object\ \$this\}\n\ \}\n\ \n\ ###\ Create\ a\ connection\ instance\ with\ a\ couple\ user\ scripts.\n\ set\ a\ \[IRC::connection\ #auto\ someUserScript1.tcl\ someUserScript2.tcl\]\n\ \n\ ###\ Connect\ to\ IRC.\n\ \$a\ connect\ irc.qeast.net\ davygrvy\ DG\ \{yo\ moma!\}\n======\n\nIn\ the\ above,\ \$a\ is\ now\ the\ connection\ object.\ \ All\ behavior\ of\ the\ engine\ is\ located\ in\ a\ script\ file\ called\ default.tcl\ \[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/tomasoft/tomahawk/irc_engine/library/default.tcl?rev=HEAD&content-type=text/vnd.viewcvs-markup\].\ \ The\ behavior\ of\ irc_engine\ can\ be\ scripted\ by\ the\ user\ by\ loading\ scripts\ which\ are\ queried\ for\ event\ hooks\ prior\ to\ doing\ the\ default\ behavior.\ \ I\ do\ have\ a\ generic\ framework\ to\ the\ system,\ but\ only\ Tcl\ is\ supported.\ \ I\ have\ code\ started\ for\ perl,\ python,\ and\ java,\ but\ I'll\ have\ to\ get\ back\ to\ it\ later\ \[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/tomasoft/tomahawk/irc_engine/generic/IRCUserScriptProvider.hpp?rev=HEAD&content-type=text/vnd.viewcvs-markup\].\n\nHere's\ where\ it\ gets\ interesting\ for\ user\ scripts..\ \ Each\ tcl\ user\ script\ is\ run\ in\ its\ own\ interpreter.\ \ It\ maintains\ some\ of\ its\ own\ commands\ such\ as\ \[\[IRC::on\]\],\ but\ aliases\ most\ up\ to\ the\ global\ interp\ (I\ also\ call\ it\ the\ controlling\ or\ UI\ interp).\ \ So\ from\ the\ script,\ a\ call\ to\ ''IRC::echo\ ...''\ will\ alias\ up\ to\ the\ global\ as\ ''connection0\ echo\ ...''\ where\ connection0\ is\ the\ \[Incr\ Tcl\]\ object.\ \ This\ allows\ us\ to\ have\ our\ scripts\ track\ with\ their\ connection\ object.\ \ Where\ this\ gets\ more\ interesting\ is\ that\ from\ this\ aliasing,\ I\ can\ ''assume''\ commands\ that\ will\ be\ in\ the\ top-most\ object\ that\ are\ provided\ by\ the\ UI\ (thanks\ to\ inheritence).\ \ The\ echo\ method\ is\ located\ in\ the\ UI\ half,\ yet\ the\ user\ script\ is\ in\ a\ separate\ interp\ of\ the\ irc_engine\ extension\ half\ and\ always\ linked\ to\ its\ parent\ object.\n\nirc_engine\ uses\ Tcl's\ event\ loop.\ \ This\ diagram\ shows\ some\ of\ the\ code\ paths:\n\n\[http://tomasoft.sf.net/incoming_trail.gif\]\n\nTcl::Socket\ is\ just\ a\ wrapper\ for\ Tcl's\ socket\ API\ stuff.\ \ When\ a\ line\ from\ the\ server\ is\ received,\ it\ is\ parsed\ into\ its\ protocol\ parts\ \[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/tomasoft/tomahawk/irc_engine/generic/IRCParse.hpp?rev=HEAD&content-type=text/vnd.viewcvs-markup\]\ \[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/tomasoft/tomahawk/irc_engine/generic/IRCParse.cpp?rev=HEAD&content-type=text/vnd.viewcvs-markup\]\ and\ is\ the\ container\ for\ the\ parts\ that\ will\ get\ passed\ around\ to\ the\ subsiquent\ modules.\ \ IRCSplitAndQ\ \[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/tomasoft/tomahawk/irc_engine/generic/IRCSplitAndQ.hpp?rev=HEAD&content-type=text/vnd.viewcvs-markup\]\ \[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/tomasoft/tomahawk/irc_engine/generic/IRCSplitAndQ.cpp?rev=HEAD&content-type=text/vnd.viewcvs-markup\]\ is\ responsible\ for\ any\ text\ mappings\ (or\ multiple\ mappings)\ that\ need\ to\ be\ decoded,\ any\ CTCP/2\ encoding\ escapes,\ any\ CTCP\ unquoting,\ any\ mode\ splitting,\ and\ removing/queueing\ of\ all\ embedded\ CTCP\ commands\ prior\ to\ the\ edited\ original\ getting\ posted\ as\ a\ job\ to\ the\ event\ loop.\ \ Phew!\n\n\[http://tomasoft.sf.net/ircevent_trail.gif\]\n\nWhen\ a\ job\ we\ had\ posted\ from\ IRCSplitAndQ\ is\ ready\ to\ be\ serviced\ by\ Tcl,\ our\ Tcl_EventProc\ named\ ''EvalCallback''\ is\ called\ which\ just\ sets\ an\ interp\ lock\ then\ calls\ ''IRCEngine::EvalOneIRCEvent''\ in\ the\ correct\ connection\ object\ \[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/tomasoft/tomahawk/irc_engine/generic/IRCEngine.hpp?rev=HEAD&content-type=text/vnd.viewcvs-markup\]\ \[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/tomasoft/tomahawk/irc_engine/generic/IRCEngine.cpp?rev=HEAD&content-type=text/vnd.viewcvs-markup\].\ \ Within\ the\ Tcl_Event\ structure\ is\ our\ IRCParse\ C++\ object\ all\ prepared\ to\ be\ serviced.\ \ First\ we\ run\ ''PreEvent(line)'',\ so\ certain\ IRC\ events\ such\ as\ 'join'\ can\ be\ set\ into\ the\ channels\ list\ prior\ to\ scripts\ being\ run.\ \ The\ same\ is\ true\ in\ the\ inverse,\ as\ a\ 'part'\ event\ will\ be\ removed\ from\ the\ channels\ list\ from\ ''PostEvent()''.\ \ Space\ is\ left\ here\ for\ the\ inclusion\ of\ an\ ''Internal\ Address\ List''\ when\ I\ get\ around\ to\ it.\n\nNow\ after\ ''PreEvent()''\ is\ run,\ all\ script\ providers\ in\ LIFO\ order\ are\ handed\ the\ IRCParse\ object.\ \ If\ any\ of\ the\ providers\ return\ ''IRCUserScriptProvider::COMPLETED''\ (an\ enum),\ then\ the\ event\ is\ considered\ complete\ and\ all\ processing\ stops.\ \ If\ no\ providers\ claim\ the\ event\ as\ completed,\ then\ the\ default\ script\ will\ process\ it.\ \ If\ the\ default\ script\ doesn't\ handle\ it,\ and\ the\ mode\ for\ the\ connection\ is\ 'debugging'\ rather\ than\ normal,\ it\ will\ be\ displayed\ in\ red\ in\ the\ status\ window\ with\ event\ name\ or\ numeric.\ \ Same\ as:\n\n======\n\ echo\ \"\\006CC\\006***\\006C\\006\ \[event\]\ \[join\ \[lrange\ \[args\]\ 1\ end\]\]\"\ status\n=====\n\nWithout\ the\ debugging\ mode,\ no\ red\ color\ or\ event\ code\ is\ displayed.\ \ Same\ as:\n\n======\n\ echo\ \"***\ \[join\ \[lrange\ \[args\]\ 1\ end\]\]\"\ status\n======\n\n----\n\nHere's\ an\ example\ of\ the\ user\ scripting\ and\ how\ identical\ it\ is\ to\ the\ '''idea'''\ of\ XiRCON.\ \ Old-time\ XiRCON'ers\ will\ notice,\ of\ course,\ the\ new\ use\ of\ namespaces\ and\ the\ msgcat\ package\ for\ handling\ multilingual\ strings.\ \ We\ must\ improve\ on\ XiRCON,\ too.\n\n======\n\ package\ require\ Xircon\ 2.0\n\ \n\ namespace\ eval\ ::IRC\ \{\n\ \ \ \ on\ PRIVMSG\ \{\n\ \ \ \ \ \ \ \ set\ dest\ \[lindex\ \[args\]\ 0\]\n\ \ \ \ \ \ \ \ set\ msg\ \[lindex\ \[args\]\ 1\]\n\n\ \ \ \ \ \ \ \ ###\ ignore\ an\ empty\ one.\n\ \ \ \ \ \ \ \ if\ \{!\[string\ length\ \$msg\]\}\ \{complete\;\ return\}\n\n\ \ \ \ \ \ \ \ if\ \{!\[icomp\ \$dest\ \[my_nick\]\]\}\ \{\n\ \ \ \ \ \ \ \ \ \ \ \ ###\ private\ msg\n\ \ \ \ \ \ \ \ \ \ \ \ echo\ \"\[color\ highlight\]*\[color\ nick\]\[nick\]\[color\ highlight\]*\[color\ private\]\ \$msg\"\ query\ \[nick\]\n\n\ \ \ \ \ \ \ \ \}\ elseif\ \{\[string\ index\ \$dest\ 0\]\ ==\ \"\\\$\"\}\ \{\n\ \ \ \ \ \ \ \ \ \ \ \ ###\ server\ (global)\ message\n\ \ \ \ \ \ \ \ \ \ \ \ echo\ \"\[color\ highlight\]<\[color\ nick\]\[nick\]\[color\ highlight\]>\[color\ default\]\ \$msg\"\ status\n\n\ \ \ \ \ \ \ \ \}\ else\ \{\n\ \ \ \ \ \ \ \ \ \ \ \ echo\ \"\[color\ highlight\]<\[color\ nick\]\[nick\]\[color\ highlight\]>\[color\ default\]\ \$msg\"\ channel\ \$dest\n\n\ \ \ \ \ \ \ \ \}\n\ \ \ \ \ \ \ \ complete\n\ \ \ \ \}\n\ \ \ \ on\ \$RPL_TOPICWHOTIME\ \ \ \ \ \{\n\ \ \ \ \ \ \ \ echo\ \"\[color\ change\]***\ \[mc\ \{Topic\ for\}\]\ \[color\ channel\]\[lindex\ \[args\]\ 1\]\[color\ change\]\ \[mc\ \{was\ set\ by\}\]\ \[color\ nick\]\[lindex\ \[args\]\ 2\]\[color\ change\]\ \[mc\ \{on\}\]\ \[clock\ format\ \[lindex\ \[args\]\ 3\]\]\"\n\ \ \ \ \ \ \ \ complete\n\ \ \ \ \}\n\ \ \ \ on\ \$RPL_UMODEIS\ \ \ \ \ \ \ \ \ \{\n\ \ \ \ \ \ \ \ echo\ \"\[color\ change\]***\ \[mc\ \{Your\ modes\ are\}\]\ \[color\ mode\]\\\"\[join\ \[lrange\ \[args\]\ 1\ end\]\]\\\"\"\ status\n\ \ \ \ \ \ \ \ complete\n\ \ \ \ \}\n\ \}\n======\n\nAs\ in\ XiRCON,\ these\ are\ the\ commands\ available\ to\ an\ event\ hook\ for\ asking\ about\ the\ line\ that\ fired\ the\ event:\n\n\[http://tomasoft.sf.net/ircparser.gif\]\n\nNot\ shown\ is\ '''raw_line'''\ and\ it\ returns\ the\ whole\ thing\ as\ a\ string\ prior\ to\ any\ processing.\ \ '''raw_args'''\ is\ also\ prior\ to\ any\ processing.\ \ All\ return\ strings\ except\ for\ '''args'''\ which\ is\ a\ list\ (and\ is\ very\ processed).\ \ '''raw_line'''\ will\ be\ empty\ for\ any\ embedded\ event\ such\ as\ ''ctcp''\ or\ ''mode+o''.\ \ '''nick'''\ will\ equal\ '''host'''\ for\ a\ server\ message.\n\nUnlike\ XiRCON,\ a\ PRIVMSG\ event\ that\ contains\ a\ CTCP\ in\ its\ entire\ trailing\ param,\ will\ fire\ a\ PRIVMSG\ anyway,\ even\ though\ it\ will\ be\ empty.\ \ It\ may\ seem\ silly\ at\ first,\ but\ the\ original\ '''raw_line'''\ would\ then\ have\ no\ way\ to\ get\ through.\ \ Think\ about\ it\ for\ a\ sec...\ \ It\ was\ a\ PRIVMSG\ that\ came\ in,\ and\ just\ so\ happened\ to\ contain\ within\ it\ a\ CTCP.\ \ It\ doesn't\ make\ sense\ to\ me\ to\ drop\ the\ original\ PRIVMSG.\ \ That\ was\ the\ event.\ \ Same\ is\ true\ for\ a\ NOTICE\ with\ a\ '''ctcp_reply'''.\n----\n'''The\ UI\ Half'''\ --\n\nThe\ first\ major\ feature\ is\ the\ support\ of\ '''ALL'''\ embedded\ text\ attributes\ ever\ known\ to\ mankind\ and\ robots\ alike.\ \ It\ supports\ ircII,\ mIrc,\ ANSI,\ besirc/hydra,\ and\ CTCP/2.\ \ As\ CTCP/2\ is\ the\ most\ in\ features,\ this\ is\ the\ native\ usage\ of\ the\ display.\ \ The\ other\ attribute\ types\ are\ pre-translated\ up\ to\ CTCP/2.\ \ The\ CTCP/2\ parser\ is\ also\ in\ the\ IRC_Engine\ as\ an\ Itcl\ class\ for\ use\ by\ Tk\ applications.\n\nCTCP/2\ embedded\ text\ attributes\ are\ described\ @\ http://www.lag.net/~robey/ctcp\ .\ \ All\ attibutes\ in\ section\ 2\ are\ supported\ ->\ http://www.lag.net/~robey/ctcp/ctcp2.2.txt\ .\ \ One\ extension\ was\ added\ using\ the\ CTCP/2\ method\ for\ extending,\ for\ doing\ the\ tag\ color\ types.\ \ This\ will\ be\ especially\ useful\ for\ a\ UI\ in\ Tk\ and\ allows\ the\ display\ to\ define\ how\ \"normal\",\ \"highlight\",\ etc..\ will\ be\ rendered\ rather\ than\ the\ parser\ filling\ in\ literal\ values.\ \ These\ tag\ colors\ are\ returned\ by\ the\ color\ command\ and\ are\ not\ intended\ for\ transmision\ --\ internal\ use\ only.\ \ Similar\ to\ XiRCON's\ \\aXX\ color\ codes\ where\ X\ is\ a\ hexadecimal\ number.\n\nIt\ should\ be\ noted\ that\ the\ parser\ reads\ it\ all,\ and\ whether\ an\ implimentation\ of\ a\ UI\ does\ actually\ do\ the\ attributes\ is\ a\ bit\ outside\ of\ my\ claims.\ \ For\ example,\ if\ I\ make\ a\ Win32\ console\ text-mode\ UI\ for\ this\ client,\ I\ will\ have\ a\ choice\ of\ only\ 12\ colors.\ \ As\ a\ 24-bit\ depth\ is\ available\ to\ the\ CTCP/2\ color\ attribute,\ the\ 24-bit\ value\ will\ need\ to\ be\ truncated\ for\ that\ display\ type\ (ie.\ 256\ levels\ of\ red\ get\ mashed\ to\ 3\ levels,\ off/on/bright).\n\nI\ should\ slow\ down\ for\ a\ moment\ and\ say\ that\ the\ UI\ is\ more\ of\ an\ API\ than\ an\ actual\ complete\ and\ realized\ implimention.\n\nTo\ better\ describe\ the\ concept\ of\ implementation\ separate\ from\ the\ UI,\ here\ is\ an\ example\ of\ a\ UI\ that\ generates\ HTML\ as\ its\ output\ (a\ little\ DHTML\ with\ CSS)\ \[http://cvs.sourceforge.net/viewcvs.py/tomasoft/tomahawk/irc_ui/library/irc_ui_html.itcl?rev=HEAD&view=auto\].\ \ With\ \[DKF\]'s\ help\ pointing-out\ the\ usefulness\ of\ \[CSS\],\ it\ sure\ helped\ me\ out.\n\nThis\ is\ the\ output\ \[http://tomasoft.sf.net/irc_output.html\]\ of\ this\ UI\ script\ on\ a\ few\ channels\ on\ EfNet\ \[http://www.efnet.org\].\n\nThe\ HTML\ looks\ great.\ \ I\ like\ the\ timestamp\ in\ the\ balloon\ help\ (kinda\ kitch).\ \ I'm\ amazed\ how\ identical\ I\ got\ it\ to\ look\ to\ my\ test\ GUI\ done\ with\ a\ windows'\ richedit\ control.\ \ The\ only\ problem\ I\ see\ is\ the\ handling\ of\ whitespace.\ \ In\ the\ main\ <div>\ rule,\ I\ tried\ setting\ ''white-space:\ pre''\ so\ multiple\ spaces\ aren't\ truncated,\ but\ alas,\ IE6\ is\ not\ doing\ this\ for\ me.\ \ Using\ an\ open-ended\ <pre>\ works,\ but\ wouldn't\ generate\ valid\ HTML\ in\ this\ manner.\ \ This\ must\ be\ a\ bug\ in\ IE6..\n\nYes,\ IE6\ does\ have\ bugs.\ \ ''text-decoration:\ blink''\ is\ also\ not\ supported.\ \ It\ seems\ if\ I\ set\ the\ <!DOCTYPE>\ to\ strict\ mode,\ ''white-space:\ pre''\ will\ start\ working,\ but\ then\ wrapping\ stops.\ \ So\ I\ tried\ &nbsp\;\ to\ replace\ multiple\ spaces\ and\ dropped\ ''white-space:\ pre''\ from\ the\ <div>\ rule.\ That\ finally\ got\ it.\n\n----\n\n'''(5:28\ PM\ 11/13/2003)'''\n\nI\ put\ the\ test\ RichEdit\ terminal\ window\ into\ an\ MDI\ frame\ and\ used\ \[TES\]\ to\ run\ tcl,\ so\ I'm\ getting\ closer\ to\ a\ real\ GUI\ on\ win32.\ \ Mine\ is\ on\ the\ left.\ \ The\ goal\ is\ to\ clone\ the\ one\ on\ the\ right.\ \ None\ of\ the\ menus\ or\ toolbar\ button\ do\ anything\ yet,\ so\ I'm\ using\ tkcon\ to\ control\ the\ windows\ at\ the\ moment.\ \ The\ connect\ dialog\ is\ next\ on\ the\ list.\ \ Conceptually,\ all\ it\ will\ do\ is\ Tcl_Eval(\"\$a\ connect\ ...\")\;\ just\ like\ I'm\ doing\ from\ tkcon.\ \ Sweet,\ eh?\ \ A\ global\ interp\ for\ controlling\ the\ behavior\ of\ the\ app\ is\ truly\ a\ beautiful\ thing.\ \ I\ will\ retain\ this\ wonderful\ concept\ as\ much\ and\ as\ deeply\ as\ I\ can\ for\ all\ aspects\ of\ the\ GUI.\ \ I'll\ even\ store\ settings\ in\ tcl\ variables..\ \ Who\ needs\ C++\ for\ everything?\ \ Just\ make\ a\ shell\ and\ use\ Tcl\ for\ the\ logic..\ \ Oh..\ That's\ right..\ \[JO\]\ states\ this\ in\ \[http://www.tcl.tk/doc/integration.html#Tcl\]\n\n\[http://tomasoft.sf.net/x2_screenshot.gif\]\n\nFWIW,\ The\ Win32\ api\ CreateMDIWindow()\ isn't\ as\ well\ documented\ as\ it\ should\ be.\ \ The\ last\ argument\ is\ for\ any\ create\ params,\ but\ the\ lParam\ for\ WM_CREATE\ is\ NOT\ the\ same\ as\ CreateWindow,\ nor\ is\ it\ a\ MDICREATESTRUCT\ directly\ as\ the\ other\ docs\ say.\ \ It\ took\ me\ a\ while\ to\ figure\ it\ out:\n\n\ LRESULT\ CALLBACK\n\ StatBoxWndProc\ (HWND\ hwnd,\ UINT\ iMsg,\ WPARAM\ wParam,\ LPARAM\ lParam)\n\ \{\n\ \ \ \ MDICREATESTRUCT\ *lpCreateParams\;\n\n\ \ \ \ AllWin32StatBoxThreadedGUI\ *pStatGUI\ =\n\ \ \ \ \ \ \ \ \ \ \ \ reinterpret_cast\ <AllWin32StatBoxThreadedGUI\ *>\n\ \ \ \ \ \ \ \ \ \ \ \ (::GetWindowLongPtr\ (hwnd,\ GWLP_USERDATA))\;\n\n\ \ \ \ switch\ (iMsg)\n\ \ \ \ \{\n\ \ \ \ \ \ \ \ case\ WM_CREATE:\n\ \ \ \ \ \ \ \ \ \ \ \ //\ move\ the\ AllWin32StatBoxThreadedGUI\ class\ pointer\ into\ the\n\ \ \ \ \ \ \ \ \ \ \ \ //\ userdata\ of\ the\ window.\n\ \ \ \ \ \ \ \ \ \ \ \ //\n\ \ \ \ \ \ \ \ \ \ \ \ lpCreateParams\ =\ (MDICREATESTRUCT\ *)((CREATESTRUCT\ *)lParam)->lpCreateParams\;\n\n\ \ \ \ \ \ \ \ \ \ \ \ ::SetWindowLongPtr\ (hwnd,\ GWLP_USERDATA,\n\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ static_cast\ <LONG_PTR>(lpCreateParams->lParam))\;\n\ ....\n\nIt's\ first\ an\ LPCREATESTRUCT\ as\ with\ CreateWindow,\ and\ the\ ->lpCreateParams\ is\ not\ our\ answer\ but\ an\ LPMDICREATESTRUCT,\ then\ we\ get\ ->lParam\ \ from\ that\ for\ the\ answer...\ \ What\ a\ mess.\n----\n\n'''NEW!\ (4:05\ PM\ 11/16/2003)'''\n\nJust\ added\ a\ new\ \[MDI\]\ child\ window\ type\ to\ act\ as\ a\ container\ for\ Tk\ \[http://cvs.sourceforge.net/viewcvs.py/tomasoft/tomahawk/irc_ui/win32/GUI/BlankBoxImps.hpp?rev=HEAD&view=auto\]\ \[http://cvs.sourceforge.net/viewcvs.py/tomasoft/tomahawk/irc_ui/win32/GUI/BlankBoxImps.cpp?rev=HEAD&view=auto\]\ .\ \ The\ container\ protocol\ seems\ to\ be\ missing\ the\ ability\ to\ resize,\ though.\ \ I'll\ leave\ this\ for\ now,\ and\ move\ forward\ instead\ of\ banging\ my\ head\ on\ the\ desk\ trying\ to\ fix\ Tk's\ broken\ container\ protocol.\ \ It's\ fine\ for\ the\ \[Tcl/Tk\ Tclet\ Plugin\]\ as\ it's\ toplevel\ doesn't\ ever\ get\ resized.\n\n\[http://tomasoft.sf.net/x2_tkembed.gif\]\n\nCool\ stuff!!\ :)\n----\n\n(4:25\ PM\ 2/9/2008)\n\nIf\ this\ is\ a\ blog,\ I\ sure\ am\ slow\ to\ ever\ post\ anything.\ \ I\ mainly\ started\ this\ page\ as\ a\ place\ to\ write\ notes\ to\ myself\ essentially\ (pretending\ to\ explain\ to\ others\ my\ weird\ little\ project).\ \ So\ here\ is\ another\ little\ note\ to\ myself..\n\nI\ did\ prove\ that\ my\ back-end\ irc_engine.dll\ could\ run\ on\ tclhttpd\ and\ serve\ live\ IRC\ with\ html\ and\ an\ unending\ server\ connection\ (transfer-coding\ =\ \"chunked\")\ which\ was\ a\ fun\ tclhttpd\ patch\ to\ write.\ \ Although\ my\ main\ computer\ is\ down\ today\ with\ a\ sick\ harddrive\ controller,\ it\ will\ return\ and\ my\ IRC\ gateway\ to\ the\ \[Tcl\ Chatroom\]\ will\ be\ alive\ again:\n\nhttp://www.pobox.com/~davygrvy/chat/tcl\n\nNote\ to\ self:\ insert\ gateway\ script\ into\ X-2\ source\ tree\ so\ it\ doesn't\ get\ lost\ forever.\n\nI\ tried\ to\ put\ together\ a\ Jabber->IRC\ gateway\ also,\ but\ got\ a\ bit\ lost..\ \ I\ might\ pick\ it\ up\ again.\ \ Rather\ than\ how\ ijchain\ does\ it,\ I\ want\ both\ sides\ to\ equal\ represent\ each\ other\ and\ have\ the\ gateway\ create\ Jabber\ users\ for\ those\ on\ IRC,\ and\ create\ IRC\ users\ for\ the\ jabber\ ones\ to\ allow\ for\ a\ transparent\ way\ of\ linking\ both\ sides.\n\n<<categories>>\ Internet\ |\ Application\ |\ Object\ Orientation} CALL {my revision XiRCON-II} CALL {::oo::Obj5951948 process revision/XiRCON%2DII} CALL {::oo::Obj5951946 process}

-errorcode

NONE

-errorinfo

Unknow state transition: LINE -> END
    while executing
"error $msg"
    (class "::Wiki" method "render_wikit" line 6)
    invoked from within
"my render_$default_markup $N $C $mkup_rendering_engine"
    (class "::Wiki" method "render" line 8)
    invoked from within
"my render $name $C"
    (class "::Wiki" method "revision" line 31)
    invoked from within
"my revision $page"
    (class "::Wiki" method "process" line 56)
    invoked from within
"$server process [string trim $uri /]"

-errorline

4