[Dev] Zaobao comments
Alec Flett
alecf at osafoundation.org
Fri Feb 25 16:58:10 PST 2005
Hey ted - I think I can answer many of your questions...and these are
all good things for me to address in the ZaoBaoTutorial.
Ted Leung wrote:
> The main parcel.xml has lots of items in it -- like 3 or even 4 items
> for each ContentDetailItem. Some of those items are reusable, and
> might eventually migrate into the framework, but it seems like a lot.
> It might be worthwhile to have some custom syntax for
> ContentDetailItem that would allow us to build some of these common
> situations more quickly -- a lot of the items are StaticTextItems, for
> example.
>
I agree. This is one of my pet peeves about the parcel.xml framework,
and something I've been talking with Grant about for a week or two. See
http://bugzilla.osafoundation.org/show_bug.cgi?id=1013
In general, the parcel.xml syntax is way to verbose for building a UI,
and most UI developers will be horrified with our current syntax. I
think if we can get a few things changed in parcel.xml, like this bug,
then we'll make huge strides towards simplifying UI creation.
> When you "install" Zaobao, you get a new menu entry under File->New
> Item, to create a new ZaoBao channel. This is the only menu
> introduction that I saw. I'm assuming that this happened because
> RSSChannel is a subkind of ItemCollection? It's a little bit of a
> mystery to me as to how that menu item got there. In general, I'm
> unclear as to how a parcel would introduce menu items and wire them up.
We don't have such a mechanism for stuff to "insert" itself into the
menus, unless there is already some UI visible in the current view. its
a bit of a chicken and egg problem, really. So for 0.5, its hard coded
in. Since hooking it up originally I have a much better understanding of
CPIA and shouldn't have any problem getting something hooked up for
0.6.. not that it helps us for PyCon though.
>
> When we create a Zaobao channel, we create an itemcolletion for it.
> What would we do if we wanted all RSSItems to go into a single
> ItemCollection (RSSChannel or not)? If we did that, it looks to me
> like we can't easily take an RSSItem and find its RSSChannel
> (bidirectional ref on items would help here).
>
What I want to do now (now that I understand queries a bit more) is hook
up a query to the ItemCollection in the sidebar - something like for i
in RSSItem where i.channel = <channel> -
even now we could pretty easily hook up a single ItemCollection which
shows all news items.
We had bidirectional refs before I hooked up general item collections
there. I thought I had re-hooked up RSSItem.channel, but maybe I
overlooked it? It wouldn't be hard to add back.
Its quite possible that I'll be able to hook up bidirectional refs again
when john finishes with his ItemCollection changes.
> I see that we are rendering the body of an RSSItem using
> osaf.framework.blocks.detail.Detail.HTMLDetailArea. Is the widget
> behind this Mozilla based or something else?
>
nope, wxWidgets has its own HTML widget...
> I know this is out of scope for 0.5, but I'm curious about the plan
> for allowing a custom summary table item/view. I can imagine a
> summary view that also shows a few lines of the RSSItem body, for
> example.
Certainly a possibility. I've talked a little with John about the idea
of hooking up meta data to an ItemCollection in the sidebar, that the
delegates could use to determine how to display the ItemCollection. (As
John would say "Its easy, its just a matter of figuring out *where* to
hook it up")
Alec
More information about the Dev
mailing list