protected override void ApplyChange(ChangedNodeInfo changedNodeInfo)
        {
            DocumentNode node = changedNodeInfo.Node;
            FontFamily   oldFontFamily;
            FontFamily   newFontFamily;

            FontEmbedder.CreateFontFamilyChange(this.fontFamilyChangeModel.FontChangeType, this.fontFamilyChangeModel.ProjectFont, changedNodeInfo.Node.Context, out oldFontFamily, out newFontFamily);
            DocumentNode documentNode = (DocumentNode)node.Context.CreateNode(PlatformTypes.FontFamily, (IDocumentNodeValue) new DocumentNodeStringValue(newFontFamily.Source));

            if (node.SiteChildIndex != -1)
            {
                node.Parent.Children[node.SiteChildIndex] = documentNode;
            }
            else
            {
                if (node.SitePropertyKey == null)
                {
                    return;
                }
                node.Parent.Properties[(IPropertyId)node.SitePropertyKey] = documentNode;
            }
        }
예제 #2
0
        protected override void ApplyChange(ChangedNodeInfo changedNodeInfo)
        {
            ChangedStateNameNodeInfo stateNameNodeInfo = (ChangedStateNameNodeInfo)changedNodeInfo;

            stateNameNodeInfo.CompositeNode.SetValue <string>(stateNameNodeInfo.ChangedProperty, this.MultiDocumentReferenceChangeModel.NewReferenceValue);
        }
 protected abstract void ApplyChange(ChangedNodeInfo changedNodeInfo);