From: Tomas Frydrych (tomasfrydrych_at_yahoo.co.uk)
Date: Fri Apr 16 2004 - 17:40:37 EDT
Just a correction; the functions that do the all the hard work
interpreting the revisions attribute are fl_ContainerLayout::getAP()
and getSpanAP(). These in turn call fl_Layout::getAttrProp() and
getSpanAttrProp(), which, however, need more input parameters because
fl_Layout does not have access to the view and the translation of the
revisions attribute is dependent on view-specific settings.
Tomas
> > Hi Martin,
> >
> >> The problem was that only the revision attributes, not the properties
> >> themselves were being being broadcast tot he fl_*Layouts.
> >
> > I only had a chance to have a quick look at the changes in Bonsai,
> > but I do not think this will work: when in revisions mode all changes
> > of attributes and properties must be made translated solely into the
> > revision attribute, i.e., setProps("font-face:Arial") has to
> > translate into
> >
> > "revisions=!1{}{font-face:Arial}"
> >
> > not into
> >
> > "revisions=!1{}{font-face:Arial} props=font-face:Arial"
> >
> > the latter is what I got the impression your changes do. If we change
> > the actual props and attributes, we will not be able revert to the
> > previous state.
> >
>
> Yes you're right. This is exactly what they do.
>
> > The attributes and props contained in the revisions attribute get
> > overlayed over any base props and attrs when the layout accesses its
> > props and attributes; this done through
> > PD_Document::explodeRevisions() and is taken care of automatically by
> > fl_Layout::getAP() and getSpanAP(). Access to all props and
> > attributes by the layouts has to be made through these two functions;
> > what the layouts must not do is to obtain their AP index, retrieve
> > the AP by that index and then evaluate props and attrs of that AP.
> >
>
> I'll look into these methods. The change to use them should be pretty easy.
>
> Cheers
>
> Martin
>
> > Tomas
> >
This archive was generated by hypermail 2.1.4 : Fri Apr 16 2004 - 18:22:05 EDT