2006-01-14T00:05:58  <xorAxAx> [PERIODIC ANNOUNCEMENT] Logs can be found on http://moinmoin.wikiwikiweb.de/MoinMoinChat/Logs/moin-dev
2006-01-14T09:25:02  <xorAxAx> nice time machine: http://triplea.sourceforge.net/mywiki/TripleA?action=info&hitcounts=1
2006-01-14T10:06:38  <ThomasWaldmann> no accesses in 1905
2006-01-14T12:33:23  <DasSheep> sorry, can't grasp the distinction
2006-01-14T12:33:43  <DasSheep> between what belongs here and what's supposed to go to #moin
2006-01-14T12:34:10  * ThomasWaldmann ever forgets :)
2006-01-14T12:34:32  <ThomasWaldmann> development topics are here, #moin is rather user support
2006-01-14T12:34:53  <DasSheep> ok
2006-01-14T12:35:20  <DasSheep> ok, the match object has those start(group) and end(group) methods
2006-01-14T12:35:26  <ThomasWaldmann> duck!
2006-01-14T12:35:29  <ThomasWaldmann> (11:53) <  DasSheep> maybe this could be useful? http://helios.wmid.amu.edu.pl/~sheep/cgi-bin/index.cgi/New_MoinMoin_parser
2006-01-14T12:35:32  <ThomasWaldmann> (11:53) <  DasSheep> tried to re-make the parser for MoinMoin's default markup
2006-01-14T12:35:34  <ThomasWaldmann> (11:54) <  DasSheep> not everything works perfectly yet
2006-01-14T12:35:48  <ThomasWaldmann> (11:54) <  DasSheep> and parts are just copied from the old parser (i.e. table arguments parsing)
2006-01-14T12:35:51  <ThomasWaldmann> (11:54) < ThomasWal> that theme looks funny
2006-01-14T12:35:54  <ThomasWaldmann> (11:55) <  DasSheep> ThomasWaldmann: I just tried to match it to my home page
2006-01-14T12:35:57  <ThomasWaldmann> (11:55) <  DasSheep> kind of minimallistic
2006-01-14T12:35:59  <ThomasWaldmann> (11:56) <  DasSheep> I added the ["free link" free description] link pattern
2006-01-14T12:36:02  <ThomasWaldmann> (11:57) < ThomasWal> btw, dont name everything Sheep* if you want to get it into main some time :)
2006-01-14T12:36:05  <ThomasWaldmann> (11:57) < ThomasWal> although it is funny, most people wont understand it out of context and just will be confused
2006-01-14T12:36:08  <ThomasWaldmann> (11:58) <  DasSheep> good point
2006-01-14T12:36:10  <ThomasWaldmann> (11:58) <  DasSheep> well, emitter can be called just Emitter, but the Parser was already taked
2006-01-14T12:36:13  <ThomasWaldmann> (11:58) <  DasSheep> taken
2006-01-14T12:36:16  <ThomasWaldmann> (11:59) <  DasSheep> maybe Parser_ ?
2006-01-14T12:36:18  <ThomasWaldmann> (11:59) <  DasSheep> or TheParser
2006-01-14T12:36:21  <ThomasWaldmann> (12:00) < ThomasWal> whatever :)
2006-01-14T12:36:23  <ThomasWaldmann> (12:00) < ThomasWal> btw, emitting has to be done at the very end, when the whole document has been transformed into a DOM tree
2006-01-14T12:36:26  <ThomasWaldmann> (12:01) <  DasSheep> luckily there's only one place where those names are used
2006-01-14T12:36:29  <ThomasWaldmann> (12:01) <  DasSheep> ThomasWaldmann: that's how it's done
2006-01-14T12:36:31  <ThomasWaldmann> (12:01) < ThomasWal> this is important for TOC, Headlines, Include and more
2006-01-14T12:36:34  <ThomasWaldmann> (12:02) <  DasSheep> document = SheepParser(self.raw, self.request).parse(); result = SheepEmitter(document, formatter, self.request).emit();
2006-01-14T12:36:37  <ThomasWaldmann>                      self.request.write(result)
2006-01-14T12:36:39  <ThomasWaldmann> (12:02) <  DasSheep> document is the tree
2006-01-14T12:36:42  <ThomasWaldmann> (12:02) < ThomasWal> that is maybe not enough
2006-01-14T12:36:44  <ThomasWaldmann> (12:03) <  DasSheep> the parsers and macros are called in emitter, though
2006-01-14T12:36:47  <ThomasWaldmann> (12:03) < ThomasWal> imagine the parser only getting some {{{!SheepParser .... }}} fragment
2006-01-14T12:36:50  <ThomasWaldmann> (12:03) < ThomasWal> then the return value should be a domtree
2006-01-14T12:36:52  <ThomasWaldmann> (12:04) < ThomasWal> that will be a subtree of a bigger domtree
2006-01-14T12:36:55  <ThomasWaldmann> (12:04) <  DasSheep> well, it will work as long as yu allow "document" nodes to be children of other nodes
2006-01-14T12:37:00  <ThomasWaldmann> (12:05) <  DasSheep> in fact, the Document object isn't really nedded, you just need the root DocNode
2006-01-14T12:37:03  <ThomasWaldmann> (12:06) < ThomasWal> maybe we should remember in the document node which kind of document (parsername) it was
2006-01-14T12:37:07  <ThomasWaldmann> (12:06) <  DasSheep> ThomasWaldmann: yes, that's a very good idea
2006-01-14T12:37:09  <ThomasWaldmann> (12:06) <  DasSheep> easy to add as an attribute of that node
2006-01-14T12:37:12  <ThomasWaldmann> (12:07) < ThomasWal> may try to implement include operation
2006-01-14T12:37:14  <ThomasWaldmann> (12:07) <  DasSheep> but that'd only work with this parser and my SimpleParser
2006-01-14T12:37:17  <ThomasWaldmann> (12:07) < ThomasWal> if your stuff manages to get include, TOC and headline levels right, we will be a big step ahead of now
2006-01-14T12:37:20  <ThomasWaldmann> (12:07) < ThomasWal> and footnotes
2006-01-14T12:37:22  <ThomasWaldmann> (12:08) < ThomasWal> also keep section editing in mind
2006-01-14T12:37:25  <ThomasWaldmann> (12:10) < ThomasWal> and caching should be possible using a generic dom object, which can be included in every other context
2006-01-14T12:37:28  <ThomasWaldmann> (12:10) *** ThomasWaldmann thinks its great you have time to realize some of our long term ideas
2006-01-14T12:37:31  <ThomasWaldmann> (12:11) < ThomasWal> part of that idea is to generalize Include operation
2006-01-14T12:37:33  <ThomasWaldmann> (12:12) < ThomasWal> so you can include (== inline) every mime-type that has a parser
2006-01-14T12:37:36  <ThomasWaldmann> (12:14) < ThomasWal> xorAxAx and me had some discussions about that in Sharm, maybe he remembers better and can provide some additional input
2006-01-14T12:37:39  <ThomasWaldmann> (12:14) < ThomasWal> in the end, it should end up on some wiki page (search for it, there should be some vague ideas already)
2006-01-14T12:37:43  <ThomasWaldmann> (12:17) <  DasSheep> yeah, I looked at it a little already
2006-01-14T12:37:45  <ThomasWaldmann> (12:17) < ThomasWal> another question is if we need that emitter PER PARSER
2006-01-14T12:37:47  <ThomasWaldmann> (12:17) < ThomasWal> or just a single DOM emitter
2006-01-14T12:37:50  <ThomasWaldmann> (12:17) <  DasSheep> ThomasWaldmann: I'm already planning to move it into a separate module
2006-01-14T12:37:53  <ThomasWaldmann> (12:18) < ThomasWal> of course it should output xhtml at the end
2006-01-14T12:37:56  <ThomasWaldmann> (12:19) <  DasSheep> er, shouldn't it just use a formatter? or have several emitters, instead of formatters?
2006-01-14T12:37:59  <ThomasWaldmann> (12:20) < ThomasWal> the current parser/formatter has some trouble doing correct html output
2006-01-14T12:38:02  <ThomasWaldmann> (12:20) < ThomasWal> that should be solved when doing it from scratch
2006-01-14T12:38:04  <ThomasWaldmann> (12:21) < ThomasWal> this will fix some GUI editor and converter problems, too
2006-01-14T12:38:07  <ThomasWaldmann> (12:21) <  DasSheep> well, the emitter usually just does: return ''.join([ open_tag, emit_children, close_tag ])
2006-01-14T12:38:10  <ThomasWaldmann> (12:21) < ThomasWal> just look at html of some nested lists
2006-01-14T12:38:12  <ThomasWaldmann> (12:22) <  DasSheep> so far the validator only complained about the "type" attribute
2006-01-14T12:38:15  <ThomasWaldmann> (12:24) < ThomasWal> maybe we need a BaseEmitter class subclassed in <parsername>Emitter
2006-01-14T12:38:18  <ThomasWaldmann> (12:24) <  DasSheep> there's one problem I can't see a solution for
2006-01-14T12:38:21  <ThomasWaldmann> (12:25) <  DasSheep> tying the nodes with the markup the yare generated from
2006-01-14T12:38:23  <ThomasWaldmann> (12:25) <  DasSheep> it would be nice if you could say: this node was produced by this part of source text
2006-01-14T12:38:26  <ThomasWaldmann> (12:25) <  DasSheep> and vice versa
2006-01-14T12:38:29  <ThomasWaldmann> (12:26) <  DasSheep> I could probably do it with careful design of groups in regexes and exploiting the match objects
2006-01-14T12:38:32  <ThomasWaldmann> (12:27) < ThomasWal> do we need this in finer level than section content level?
2006-01-14T12:38:35  <ThomasWaldmann> (12:27) <  DasSheep> ThomasWaldmann: you need lines for the diffs
2006-01-14T12:38:37  <ThomasWaldmann> (12:27) <  DasSheep> ThomasWaldmann: it would be very pretty if you could highlight the diffs directly in the generated html :D
2006-01-14T12:38:40  <ThomasWaldmann> (12:28) < ThomasWal> some stuff you dont see in the rendered page
2006-01-14T12:38:43  <ThomasWaldmann> (12:28) <  DasSheep> that's why you'd still need the regular diff
2006-01-14T12:38:45  <ThomasWaldmann> (12:28) < ThomasWal> but we need those line anchors
2006-01-14T12:38:48  <ThomasWaldmann> (12:29) <  DasSheep> with some js you could meybe even do "edit selection" ;)
2006-01-14T12:38:51  <ThomasWaldmann> (12:30) <  DasSheep> of course rounded to the DOM node boundary
2006-01-14T12:38:56  <ThomasWaldmann> ok, just for being logged :) unduck now.
2006-01-14T12:39:03  <DasSheep> :)
2006-01-14T12:40:13  <DasSheep> ok, to the point, with the match's start() and end() (or span() ), with careful design for regex groups (at least one group for a node), you could record the starting and ending points of nodes
2006-01-14T12:41:02  <ThomasWaldmann> btw, please strictly conform to PEP8
2006-01-14T12:41:13  <DasSheep> the style guide?
2006-01-14T12:41:17  <ThomasWaldmann> yes
2006-01-14T12:41:39  * DasSheep doesn't get the line-breaking rules
2006-01-14T12:41:51  <DasSheep> it only says "the emacs gets it right"
2006-01-14T12:41:56  * DasSheep uses vim
2006-01-14T12:42:04  <ThomasWaldmann> esp. distributiong of spaces
2006-01-14T12:42:37  <ThomasWaldmann>   55             '<%s>=%s\n'%(node.kind,repr(node.content)),
2006-01-14T12:43:11  <DasSheep> should be '<%s>=%s\n' % (node.kind, repr(node.content)),
2006-01-14T12:43:11  <ThomasWaldmann> > 55             '<%s>=%s\n' % (node.kind, repr(node.content)),
2006-01-14T12:43:13  <DasSheep> right?
2006-01-14T12:43:18  <ThomasWaldmann> :)
2006-01-14T12:43:49  <DasSheep> well, that part is temporary "scratch it" debug code... ;)
2006-01-14T12:44:06  <DasSheep> in fact, I think I'll get rid of the Document class
2006-01-14T12:44:12  <DasSheep> it doesn't do anything
2006-01-14T12:47:14  <ThomasWaldmann> for the DOM objects, the question is if we shouldnt use some already done DOM code
2006-01-14T12:47:44  <ThomasWaldmann> or stuff like elementtree lib
2006-01-14T12:48:01  <ThomasWaldmann>  830                 self.processor_is_parser = 1
2006-01-14T12:48:32  <ThomasWaldmann>  = True # I know, there is still lots of 0/1 in moin, but we should get rid of it in new code
2006-01-14T12:49:40  <DasSheep> ThomasWaldmann: that is a part copied from wiki.py
2006-01-14T12:49:47  <ThomasWaldmann> hehe
2006-01-14T12:50:36  <DasSheep> I copied two methods -- the SetProcessor and the getTableAttrs
2006-01-14T12:50:49  <DasSheep> couldn't get them right by myself
2006-01-14T12:51:05  <DasSheep> too complicated
2006-01-14T12:51:52  <DasSheep> hmmm... if I separate emitter into a standalone module, where should I put it?
2006-01-14T12:52:08  <DasSheep> I don't want to touch the MoinMoin directory
2006-01-14T12:52:36  <DasSheep> maybe put it where the wikiconfig.py is?
2006-01-14T12:53:23  <ThomasWaldmann> we need some kind of moin-internal "DOM", so that we can do includes better, generate correct TOCs and Footnotes, generate valid xhtml - consider (c)elementtree or XIST and certainly Amara (Intro), too.
2006-01-14T12:53:32  <ThomasWaldmann> see http://moinmoin.wikiwikiweb.de/MoinMoinTodo/Release_2.0
2006-01-14T12:54:07  <DasSheep> ThomasWaldmann: yes, but I don't know the api to XIST -- I already looked at it
2006-01-14T12:54:26  <DasSheep> thought I'll write something that works first
2006-01-14T12:54:42  <DasSheep> and then maybe try to refactro it to use XIST
2006-01-14T12:54:59  <ThomasWaldmann> you can put modules anywhere into your python path. maybe needs some different import statements later, but should be no problem.
2006-01-14T12:55:35  <DasSheep> ok
2006-01-14T13:50:23  * ThomasWaldmann looks at http://effbot.org/zone/pythondoc-elementtree-ElementTree.htm
2006-01-14T13:58:05  <DasSheep> very similar to DocNode
2006-01-14T13:58:15  <DasSheep> but DocNode also has .parent
2006-01-14T14:00:28  * ThomasWaldmann wonders about text and tail attr
2006-01-14T14:01:07  <DasSheep> ThomasWaldmann: well, I use the "content" attribute for the leaf nodes
2006-01-14T14:01:27  <DasSheep> the "text", "image", "link" and "preformatted" nodes
2006-01-14T14:01:41  <ThomasWaldmann> so if i have <p> bla <b> blubb </b> more bla</p>
2006-01-14T14:01:56  <DasSheep> it's:
2006-01-14T14:02:00  <ThomasWaldmann> "more bla" will be in .tail of the bold element?
2006-01-14T14:02:08  <DasSheep> no
2006-01-14T14:02:19  <DasSheep> my parser would have it like this:
2006-01-14T14:02:23  <DasSheep> paragraph
2006-01-14T14:02:35  <DasSheep> +-- text " bla "
2006-01-14T14:02:41  <DasSheep> +-- bold
2006-01-14T14:02:56  <DasSheep>     +-- text " blubb "
2006-01-14T14:03:10  <DasSheep> +-- text " more bla"
2006-01-14T14:03:31  <ThomasWaldmann> looks more natural
2006-01-14T14:03:40  <ThomasWaldmann> but elementtree does it different
2006-01-14T14:03:46  <DasSheep> only the leaf nodes can contain text
2006-01-14T14:05:09  <DasSheep> how would it handle <p> some text <b> bold text </b> more text <i> italic text </i> finish </p> ?
2006-01-14T14:05:30  <ThomasWaldmann> i think like:
2006-01-14T14:05:39  <ThomasWaldmann> p
2006-01-14T14:05:50  <ThomasWaldmann> +--- text = " some text "
2006-01-14T14:05:58  <ThomasWaldmann> +--- b
2006-01-14T14:06:13  <ThomasWaldmann>      +--- text = " bold text "
2006-01-14T14:06:29  <ThomasWaldmann>      +--- tail = " more text "
2006-01-14T14:06:34  <ThomasWaldmann> +--- i
2006-01-14T14:06:45  <ThomasWaldmann>      +--- text = " italic text "
2006-01-14T14:06:54  <ThomasWaldmann>      +--- tail = " finish "
2006-01-14T14:07:04  <DasSheep> weird :/
2006-01-14T14:07:26  <ThomasWaldmann> strange that it got accepted like this for py 2.5
2006-01-14T14:07:28  <DasSheep> I mean, doesn't reflect the structure of the document
2006-01-14T14:12:02  <ThomasWaldmann> "ElementTree is good for some stuff but I\u2019ve found it awkward for some types of data manipulation with it\u2019s tag tail data."
2006-01-14T14:12:53  <DasSheep> :)
2006-01-14T14:16:04  <ThomasWaldmann> hmm, i think one just has to wrap "valuable" text into some text node
2006-01-14T14:16:55  <ThomasWaldmann> then there won't be any worthy stuff in tail nodes
2006-01-14T14:17:13  <DasSheep> yes
2006-01-14T14:17:21  <DasSheep> if it only had the .parent :)
2006-01-14T14:17:33  <DasSheep> then it would be basically equivalent to DocNode
2006-01-14T14:21:57  <ThomasWaldmann> i wonder if we really do our own implementation and why it misses such stuff and why they consider moving it to the stdlib nevertheless
2006-01-14T14:22:05  <ThomasWaldmann> can you contact him and find out?
2006-01-14T14:22:41  <DasSheep> :)
2006-01-14T14:23:00  <DasSheep> THIS goes to stdlib ??? Oo)
2006-01-14T14:25:08  <DasSheep> apart from XML parser/emitter it doesn't contain much meaningful code...
2006-01-14T14:27:53  <DasSheep> and we want a parser with dtd support
2006-01-14T14:30:36  <ThomasWaldmann> using some sane stdlib code would be nice (no dependency, no own code to maintain)
2006-01-14T14:31:02  <DasSheep> well, the DocNode code is 5 lines long :)
2006-01-14T14:31:21  <DasSheep> not counting the emitter, of course
2006-01-14T14:31:33  <ThomasWaldmann> i doubt you can compare it with elementtree :)
2006-01-14T14:31:44  <ThomasWaldmann> and they have a C implementation
2006-01-14T14:33:09  <DasSheep> I think I'll stay with the temporary solution until we are sure what to use
2006-01-14T14:34:05  <DasSheep> is there a "standard" XML parser in python, with DTD support?
2006-01-14T14:35:32  * DasSheep looks at XIST
2006-01-14T14:36:51  <DasSheep> maybe we could use xmplproc's output format directly?
2006-01-14T14:38:04  <DasSheep> http://pyxml.sourceforge.net/topics/howto/section-DOM.html
2006-01-14T14:39:09  <DasSheep> well, I can use a stack instead of .parent links
2006-01-14T14:39:53  * ThomasWaldmann has not much clue about xml processing
2006-01-14T14:40:49  <DasSheep> I think the pyxml's DOM is much more mature
2006-01-14T14:40:58  <DasSheep> is pyxml in stdlib?
2006-01-14T14:41:41  <DasSheep> :/
2006-01-14T14:41:42  <DasSheep> nope
2006-01-14T14:44:01  <DasSheep> http://python.org/doc/2.4.2/lib/module-xml.dom.minidom.html
2006-01-14T14:44:03  <DasSheep> hmmm
2006-01-14T14:56:06  <ThomasWaldmann> http://www-128.ibm.com/developerworks/library/x-matters28/  <-- looks here before using minidom X)
2006-01-14T15:04:03  * DasSheep looks
2006-01-14T15:05:20  <DasSheep> "the deprecated xmllib"
2006-01-14T15:05:24  <DasSheep> :(
2006-01-14T15:07:44  <DasSheep> do you care about moin's memory requirements as much as its speed?
2006-01-14T15:09:15  <DasSheep> the way he does the tests is funny
2006-01-14T15:09:27  <DasSheep> I estimated memory usage by watching the output of top in another window;
2006-01-14T15:10:11  <DasSheep> If I said this on any of my classes, I'd fail immediately :)
2006-01-14T15:15:33  * DasSheep found the .parent in SubElement :)
2006-01-14T15:18:16  <DasSheep> ThomasWaldmann: still, it's going in for python 2.5, hwat about older pythons?
2006-01-14T15:18:17  <ThomasWaldmann> I care more for speed than for memory requirements
2006-01-14T15:18:30  <DasSheep> lots of people still use 2.3
2006-01-14T15:18:35  <ThomasWaldmann> but if it is slow AND big, it is maybe no good
2006-01-14T15:19:18  * DasSheep looks for an rpm package
2006-01-14T15:19:44  <ThomasWaldmann> otoh it depends on our caching
2006-01-14T15:20:12  <ThomasWaldmann> if the slow stuff happens once before caching and cache has high hit rate, it doesnt matter
2006-01-14T15:20:37  <DasSheep> is there a DTD or a sketch of DTD for the WikiDOM ?
2006-01-14T15:21:20  <ThomasWaldmann> i think I read some stuff, but dont remember where. and it wasn't for moin.
2006-01-14T15:22:18  <DasSheep> ok, then maybe I'll try to make a first draft :)
2006-01-14T15:23:54  <ThomasWaldmann> i think processing one item should be parser -> domtree -> cache
2006-01-14T15:24:46  <ThomasWaldmann> then some emitter of the top item uses all item / subitem caches and "render" using text_python formatter -> cache
2006-01-14T15:25:26  <ThomasWaldmann> on item request, the cache object is executed and spills out html
2006-01-14T15:26:18  <DasSheep> item is a "top-level" node for a page, right?
2006-01-14T15:26:30  <ThomasWaldmann> so the wiki parser can be slow as it has to be done only once after editing that page
2006-01-14T15:27:04  <ThomasWaldmann> the emitter should be fast, as it will run when some subitem or dependency changes
2006-01-14T15:27:13  <DasSheep> is "item" a good name for it?
2006-01-14T15:27:30  <ThomasWaldmann> item is 2.0, page is 1.x speak
2006-01-14T15:27:45  <DasSheep> ok, so it's "item"
2006-01-14T15:28:04  * DasSheep hopes it doesn't get confused with list items
2006-01-14T15:30:26  <ThomasWaldmann> aka mimetype item, wiki item...
2006-01-14T15:31:01  <ThomasWaldmann> == parent class of a text/x-moin-wiki "page" item
2006-01-14T15:31:05  <DasSheep> "document" ?
2006-01-14T15:31:55  <ThomasWaldmann> i would rather take that name for the dom stuff
2006-01-14T15:32:11  <ThomasWaldmann> and the final document can include multiple items
2006-01-14T15:32:33  <DasSheep> and item can contain items...
2006-01-14T15:32:45  <DasSheep> mime/mulitpart :)
2006-01-14T15:32:52  <ThomasWaldmann> bah
2006-01-14T15:33:47  <ThomasWaldmann> i really thought about doing it like email, but it is just too awkward
2006-01-14T15:37:56  <DasSheep> maybe there should be different item tags for different items?
2006-01-14T15:38:21  <DasSheep> like, <item_image> and <item_page>, etc.
2006-01-14T15:38:39  <DasSheep> so that you can allow/forbid different children tags for them in the DTD
2006-01-14T15:39:38  <ThomasWaldmann> each item will have a mimetype
2006-01-14T15:40:12  <DasSheep> yes, but that's an attribute
2006-01-14T15:40:18  <ThomasWaldmann> which will determine the "parser" being used for it
2006-01-14T15:40:35  <DasSheep> I can't easily control the allowed children of a tag in dtd based on the attribute
2006-01-14T15:41:11  <DasSheep> you can still have <item_image type="image/png"> and <item_image type="text/xml+svg">
2006-01-14T15:41:51  <DasSheep> eh, bad idea probably
2006-01-14T15:41:57  <DasSheep> :/
2006-01-14T15:42:19  <DasSheep> I don't know XML and DTD stuff well enough to tackle this, I guess
2006-01-14T15:42:25  <ThomasWaldmann> what's includeable at some place might primarily depend on the installed parsers
2006-01-14T15:43:01  <DasSheep> ThomasWaldmann: you want to have a formal dtd defined as restrictive, as it gets, so that you've got some free error checking
2006-01-14T15:43:08  <DasSheep> and no surprises
2006-01-14T15:43:19  <ThomasWaldmann> if there is some parser for word documents transforming them into internal dom trees, we can include word documents inlines
2006-01-14T15:43:41  <DasSheep> there's OpenDocument :)
2006-01-14T15:43:50  <ThomasWaldmann> i have no idea about dtd usage
2006-01-14T15:44:29  <ThomasWaldmann> (and it was just a curious and rather far fetched example)
2006-01-14T15:45:30  <ThomasWaldmann> the parser for an image might just return <image>http://wikiserver/item?action=raw</image>
2006-01-14T15:45:33  * DasSheep reads DOM technical spec
2006-01-14T15:46:12  <DasSheep> ThomasWaldmann: but it should be able to return <data encoding="base64" compression="gzip">J^$#*@b#</data>
2006-01-14T15:46:23  <ThomasWaldmann> or rather <image href="http://wikiserver/item?action=raw"/>
2006-01-14T15:46:48  <ThomasWaldmann> why?
2006-01-14T15:46:50  <DasSheep> ThomasWaldmann: that'd invalidate the cache if you moved your wiki
2006-01-14T15:47:11  <DasSheep> rather "item://" or something
2006-01-14T15:47:22  <ThomasWaldmann> yeah, ok
2006-01-14T15:48:22  <ThomasWaldmann> and the dom_html formatter for image then has to do the http://... stuff
2006-01-14T15:49:26  <DasSheep> http://www.w3.org/TR/DOM-Level-2-HTML/html.html <-- a sample :)
2006-01-14T15:56:08  <DasSheep> something like this? http://moinmoin.wikiwikiweb.de/MoinMoinDOM
2006-01-14T16:01:05  * DasSheep gives it a rest
2006-01-14T16:01:16  <DasSheep> I'll think about it tomorrow :)
2006-01-14T16:01:27  <DasSheep> Like Scarlet
2006-01-14T16:02:05  <ThomasWaldmann> re (power was out and I moved :)
2006-01-14T16:03:00  <ThomasWaldmann> Fabi: we were just talking about an internal DOM
2006-01-14T16:05:40  <ThomasWaldmann> DasSheep: maybe we should not even have <image>, but just <include href="item:otheritem"/>
2006-01-14T16:06:26  <DasSheep> or even <item src="...">
2006-01-14T16:06:40  <DasSheep> or href
2006-01-14T16:06:42  <ThomasWaldmann> at least for images stored as wiki items.
2006-01-14T16:06:57  <ThomasWaldmann> at least for everything stored as wiki item.
2006-01-14T16:07:10  <DasSheep> ThomasWaldmann: but will Alt be stored with the image?
2006-01-14T16:07:26  <DasSheep> .oO(Probably a good idea)
2006-01-14T16:07:27  <ThomasWaldmann> we maybe need <image>, too, for external stuff
2006-01-14T16:07:39  <ThomasWaldmann> every item has metadata
2006-01-14T16:07:51  <ThomasWaldmann> and the parser for the item should know what to do with it
2006-01-14T16:08:40  <DasSheep> so you'd have <item href="..."> and <ext_item href="..." type="..." alt="..." ...> ?
2006-01-14T16:08:53  <ThomasWaldmann> Fabi: what do you think of elementtree, esp. its "tail" attr?
2006-01-14T16:10:06  <ThomasWaldmann> DasSheep: if you feel really bored some day, could you make a new "new" icon, that is easier to target on RC item column
2006-01-14T16:10:35  <ThomasWaldmann> (== a bit more broad, like deleted / updated)
2006-01-14T16:10:37  <DasSheep> ThomasWaldmann: I'm just using the 'edit' icon in my theme for that :)
2006-01-14T16:10:54  <ThomasWaldmann> url?
2006-01-14T16:11:10  <DasSheep> http://helios.wmid.amu.edu.pl/~sheep/cgi-bin/
2006-01-14T16:11:37  <DasSheep> feel free to create a new page
2006-01-14T16:12:38  <ThomasWaldmann> i dont see an icon at all
2006-01-14T16:13:00  <DasSheep> :/
2006-01-14T16:13:19  <Fabi> elementtree?
2006-01-14T16:13:45  <DasSheep> 'new':        (_("[NEW]"),               "moin-edit.gif",    24, 24),
2006-01-14T16:14:04  <ThomasWaldmann> Fabi: http://effbot.org/zone/element-index.htm (and in py 2.5 as i read somewhere)
2006-01-14T16:15:37  <DasSheep> ThomasWaldmann: strange, it doesn't show at all :/
2006-01-14T16:16:12  <DasSheep> ThomasWaldmann: but it doesn't show on moinmoin.wikiwikiweb.de either
2006-01-14T16:16:18  <DasSheep> bug in 1.5.0 ?
2006-01-14T16:16:31  <Fabi> *reading*
2006-01-14T16:20:37  <Fabi> where is the difference to xml.dom.minidom?
2006-01-14T16:21:09  <ThomasWaldmann> faster and using less memory
2006-01-14T16:21:48  <Fabi> ok
2006-01-14T16:22:12  <Fabi> so simply change 5 LOCs in dom_xml.py and you got a working formatter
2006-01-14T16:22:34  <DasSheep> :)
2006-01-14T16:22:39  <Fabi> (may be needs some moretesting before it can get a vital core component)
2006-01-14T16:23:06  <dreimark>   (_("[NEW]"),  depends on bookmark no bookmark no new icon
2006-01-14T16:24:27  <ThomasWaldmann> dreimark: oh. you're right :)
2006-01-14T16:25:12  <DasSheep> lol
2006-01-14T16:25:25  <dreimark> no user no bookmark no new ;-)
2006-01-14T16:26:59  <ThomasWaldmann> DasSheep: those icons are better targetable, but don't match the needs of modern theme
2006-01-14T16:27:45  <DasSheep> ThomasWaldmann: what are those needs?
2006-01-14T16:29:16  <ThomasWaldmann> as you see, our minimum line height is much lower than yours (and that should stay that way)
2006-01-14T16:29:44  <ThomasWaldmann> so the easiest fix would be to just make the "yellow" a bit broader
2006-01-14T16:30:48  <ThomasWaldmann> if you insist on redoing them all (:-), we could add maybe 2..4 pixels of height, but keep the same style
2006-01-14T16:32:21  <DasSheep> ThomasWaldmann: see the ones in alternate_icons on MoinMoin:ThemeMarket/ThemeResources ?
2006-01-14T16:34:05  <ThomasWaldmann> DasSheep: those are the same you use on your wiki, but they don't fit modern theme
2006-01-14T16:34:39  <DasSheep> ThomasWaldmann: not those, those in alt_icons.tar.gz
2006-01-14T16:35:04  <DasSheep> ThomasWaldmann: these are all the same size as originals
2006-01-14T16:35:07  <DasSheep> ThomasWaldmann: only remade
2006-01-14T16:36:07  <DasSheep> I even ramde the mascot :)
2006-01-14T16:36:12  <DasSheep> remade
2006-01-14T16:37:31  <ThomasWaldmann> that dude will hate you
2006-01-14T16:38:53  <DasSheep> not that it's any better
2006-01-14T16:39:13  <DasSheep> at least the icons don;t require translation
2006-01-14T16:39:57  <ThomasWaldmann> gimp * is no good for viewing that stuff
2006-01-14T16:40:05  <DasSheep> :)
2006-01-14T16:40:13  <DasSheep> true
2006-01-14T16:40:21  <ThomasWaldmann> do you have some canvassing script?
2006-01-14T16:40:31  <DasSheep> what script?
2006-01-14T16:40:54  <ThomasWaldmann> that puts everything on a white or black canvass to make it easier to view
2006-01-14T16:41:11  <DasSheep> no, but I can try one trick :)
2006-01-14T16:43:57  <DasSheep> grrrr
2006-01-14T16:43:58  <DasSheep> Attachment 'icons.zip' could not be unzipped because the resulting files would be too many (7 missing).
2006-01-14T16:48:30  <dreimark> I could add a Gallery page if wanted
2006-01-14T16:48:47  <dreimark> DasSheep:unzip_attachments_count = 250
2006-01-14T16:53:13  <DasSheep> strange
2006-01-14T16:53:48  <DasSheep> for some reason, unzipping the archive produced 50 identical files
2006-01-14T16:54:10  <DasSheep> http://helios.wmid.amu.edu.pl/~sheep/cgi-bin/index.cgi/Alternate_Moin_icons
2006-01-14T16:54:26  <DasSheep> they werent identical when I was zipping them :/
2006-01-14T16:54:31  <dreimark> DasSheep:needs patch-377
2006-01-14T16:55:03  <dreimark> Repaired zipping, a very small typo broke it.
2006-01-14T16:55:26  <DasSheep> _^_
2006-01-14T16:56:22  <DasSheep> dreimark: where do I get it?\
2006-01-14T16:57:41  <dreimark> tla update or MoinMoinDownload  http://arch.thinkmo.de/cgi-bin/archzoom.cgi/arch%40arch.thinkmo.de--2003-archives/moin--main--1.5
2006-01-14T16:58:06  <ThomasWaldmann> -                for (oirgname, finalname) in namelist.iteritems():
2006-01-14T16:58:09  <ThomasWaldmann> +                for (origname, finalname) in namelist.iteritems():
2006-01-14T16:58:13  <ThomasWaldmann> in AttachFile.py
2006-01-14T16:58:48  * DasSheep gets up from under the table
2006-01-14T16:58:56  <DasSheep> ThomasWaldmann: thanks
2006-01-14T17:00:09  <DasSheep> dreimark: now how do I delete the identical files?
2006-01-14T17:01:03  <dreimark> best is to rename the page to a prefix e.g. DeleteThisPage and kill it on the server
2006-01-14T17:05:13  <DasSheep> ok
2006-01-14T17:05:19  <DasSheep> http://helios.wmid.amu.edu.pl/~sheep/cgi-bin/index.cgi/Alternate_Moin_icons
2006-01-14T17:05:29  <DasSheep> :D
2006-01-14T17:05:33  <DasSheep> ta-da!
2006-01-14T17:15:47  <DasSheep> I can resize the "new" icon and add an arrow like the "update" and "deleted" icons have
2006-01-14T17:18:42  <dreimark> I've added a flash file to http://moinmoin.wikiwikiweb.de/ThemeMarket/ThemeResources?action=AttachFile&do=get&target=alt_icons.swf
2006-01-14T17:19:45  <xorAxAx> ah, i have finally catched up
2006-01-14T17:19:51  <DasSheep> dreimark: transparency is wrong...
2006-01-14T17:20:09  <dreimark> I know on black
2006-01-14T17:20:10  <xorAxAx> ThomasWaldmann: std lib has quite much code which deals with the basic (xml) problems
2006-01-14T17:20:23  <xorAxAx> and, 4suite is quite big --> you can write a lot of code in this area
2006-01-14T17:20:34  <xorAxAx> the main problem is not creating trees, that pretty simple
2006-01-14T17:20:41  <xorAxAx> the main problem is transformation
2006-01-14T17:21:25  <xorAxAx> and we need some thoughts about interaction of plugins with the current tree
2006-01-14T17:22:00  <xorAxAx> "how would a footnote macro modify the tree", "which post-transformations does it depend on" etc.
2006-01-14T17:22:33  <xorAxAx> IIRC thomas and I talked about the problem of knowing which transformation to do at which point
2006-01-14T17:22:47  <xorAxAx> i.e. when to resolve include nodes, render TOCs etc.
2006-01-14T17:23:23  <xorAxAx> the solution needs to be open for plugins of course ... the first thing that came to my mind was a priority queue
2006-01-14T17:23:28  <DasSheep> xorAxAx: it's hard to discuss this kinds of things without prototypes
2006-01-14T17:23:33  <xorAxAx> but how to construct the priority?
2006-01-14T17:23:49  <xorAxAx> DasSheep: i dont think so
2006-01-14T17:24:19  <xorAxAx> DasSheep: ok, maybe a prototype is sensible to explore the problem
2006-01-14T17:24:28  <xorAxAx> but there are so many related solutions around
2006-01-14T17:24:48  <xorAxAx> prototypes are sensible if you are inventing something new :)
2006-01-14T17:25:30  <xorAxAx> so - thinking about a "DTD" should be done quite early
2006-01-14T17:25:39  <DasSheep> xorAxAx: I assume you don't want the old plugins to work with moin 2.0 ?
2006-01-14T17:25:44  <xorAxAx> we dont need to formally write it down IMHO, just a few thoughts are enough
2006-01-14T17:26:20  <xorAxAx> DasSheep: why? writing an adapter should be very simple. but the bigger problem is that all other kinds of methods will have different names
2006-01-14T17:26:59  <xorAxAx> or are you talking about basic design issues like "do we still a formatter plugin class"?
2006-01-14T17:27:28  <xorAxAx> a formatter could be just a transformator that takes a tree and outputs chunks of strings
2006-01-14T17:27:51  <DasSheep> ok
2006-01-14T17:28:01  <xorAxAx> s/do we/will we/
2006-01-14T17:28:15  <DasSheep> then call me when you decide on how you want to do it ;)
2006-01-14T17:28:25  <xorAxAx> IMHO this system should be developed separately from any "moin 2.0"
2006-01-14T17:28:45  <xorAxAx> because it doesnt really depend on other parts of moin
2006-01-14T17:28:57  <DasSheep> ThomasWaldmann: is this icon ok for "new" ? http://helios.wmid.amu.edu.pl/~sheep/cgi-bin/index.cgi/Alternate%20Moin%20icons?action=AttachFile&do=get&target=0-moin-new.png
2006-01-14T17:29:12  <xorAxAx> and moin 2.0 needs to be put into a usable state till anybody can work on it again
2006-01-14T17:29:18  <dreimark> DasSheep: swf on white looks better
2006-01-14T17:29:27  <DasSheep> :)
2006-01-14T17:29:49  <xorAxAx> DasSheep: i think we need to sketch a few ideas and explore possibilities
2006-01-14T17:30:02  <xorAxAx> and build prototypes, if you like to do
2006-01-14T17:30:13  <DasSheep> dreimark: it still has the transparency wrong, though :)
2006-01-14T17:30:32  <DasSheep> maybe I should provide gif images instead
2006-01-14T17:30:50  <DasSheep> they seem to be more widely supported
2006-01-14T17:31:47  <xorAxAx> pngs with 256 colors are ok too
2006-01-14T17:32:33  <DasSheep> I tried to make them all indexed, but not always remebered to convert before saving them
2006-01-14T17:33:13  <DasSheep> xorAxAx: another question -- should I try to use elementtree in my parsers/emitter ?
2006-01-14T17:33:26  <dreimark> DasSheep:no depends on me I have to learn more on flash
2006-01-14T17:33:44  <xorAxAx> DasSheep: i am not sure if that solves any problems or creates new ideas currently besides you getting the impression of its strengths
2006-01-14T17:33:50  <DasSheep> dreimark: that flash takes 99% CPU :)
2006-01-14T17:33:57  <dreimark> ?
2006-01-14T17:33:57  <xorAxAx> DasSheep: i think a DOM and an idea of a processing model would be more valuable
2006-01-14T17:34:08  <xorAxAx> (and a small "prototype")
2006-01-14T17:34:17  <DasSheep> xorAxAx: but for that we need dtd first
2006-01-14T17:34:38  <xorAxAx> at least a vague idea of it, yeah
2006-01-14T17:34:51  <xorAxAx> but i dont see the problem, we dont need to put much time into writing a formal one
2006-01-14T17:35:01  <DasSheep> well, the tree-building and tree->html code can be easily modified
2006-01-14T17:35:19  <dreimark> DasSheep:gflashplayer needs 25% this is much to much for this file
2006-01-14T17:39:14  <xorAxAx> DasSheep: the difference between here and #moin is quite easy: everything that doesnt affect the code that is shipped in tgz doesnt go here :)
2006-01-14T18:01:31  <ThomasWaldmann> re (sorry: work/phone)

MoinMoin: MoinMoinChat/Logs/moin-dev/2006-01-14 (last edited 2007-10-29 19:14:11 by localhost)