[Date Prev][Date Next][Thread Prev][Thread Next][Thread Index]

RE: [XaraXtreme-dev] Current/default font



> > Martin Wuerthner wrote:
> >> But if we do not always do it, why do it at all? Just to avoid a
> >> single font attribute that contains the name of a font that is not
> >> installed? We will have lots of them in the tree anyway simply by
> >> loading a document containing fonts that are not installed. We do
not
> >> do "hard" font substition, just "soft" font substitution, i.e., the
> >> text remains in the unknown font but when it is displayed the
default
> >> font is used instead.
> >
> > I had been presuming the implementation time of either option would
> > be the same.
> >
> > IE (in PsuedoCode)
> >    FixFontAttributeIfUnusedAndUninstalled(CurrentAttribute);
> > becomes
> >    FixFontAttributeIfUnusedAndUninstalled(CurrentAttribute);
> >    FixFontAttributeIfUnusedAndUninstalled(DefaultAttribute);
> >
> > Somewhere during the long discussion at GP it became obvious we
needed
> > to fix both. I now can't remember why. Anyone else? But if the
> > implementation time is the same, why not, now we know it's harmless?
> 
> Because there are good reasons for changing the current font but I
> cannot see any reason for changing the default font attribute. The
> default font attribute nodes are just the in-memory manifestations of
> the implicit, fixed default attributes that are part of the file
> format. The default font attribute has been defined to be Times New
> Roman - some choice had to be made.
> 
> Yes, we can change the default attribute *node* in some specific
> cases. But why would we want to do it in the first place? And if there
> really is a good reason for doing it, then are we not going to be in
> trouble when we cannot do it? Or, the other way round, if we are happy
> without doing it when the circumstances do not allow, we might just as
> well never do it.
> 
> So far, the only reason given for doing it was that there should be no
> font attibutes in the tree for fonts that are not installed. As I
> wrote above, we have lots of them anyway (for all fonts found in
> loaded documents that do not happen to be installed), so why bother?

I'd like to get this change in for 0.7. I think we've spent enough time
discussing it now. It's the current font change that's the most
important but I think it's also safe to change the default font too. 

So Martin, can you do this please? If for some reason it's more work to
change the default font as well as the current font, then just change
the current font please. Otherwise change both.

Thanks

Neil