Example #1
0
        public void ResolveReferences(Class374 modelBuilder, DxfTableStyle tableStyle)
        {
            DxfCellStyleMap dxfCellStyleMap = tableStyle.method_17();

            if (dxfCellStyleMap != null)
            {
                dxfCellStyleMap.CellStyles.Clear();
                foreach (DxfTableCellStyle cellStyle in (Collection <DxfTableCellStyle>)tableStyle.CellStyles)
                {
                    dxfCellStyleMap.CellStyles.Add(cellStyle);
                }
            }
            foreach (Class567 class567 in this.list_1)
            {
                int index1 = -1;
                for (int index2 = tableStyle.CellStyles.Count - 1; index2 >= 0; --index2)
                {
                    if (string.Compare(tableStyle.CellStyles[index2].Name, class567.CellStyle.Name, StringComparison.InvariantCultureIgnoreCase) == 0)
                    {
                        index1 = index2;
                        break;
                    }
                }
                class567.ResolveReferences(modelBuilder);
                if (index1 >= 0)
                {
                    tableStyle.CellStyles[index1] = class567.CellStyle;
                }
                else
                {
                    tableStyle.CellStyles.Add(class567.CellStyle);
                }
            }
        }
Example #2
0
 public Class264(DxfCellStyleMap cellStyleMap)
     : base((DxfObject)cellStyleMap)
 {
 }
Example #3
0
        public override void ResolveReferences(Class374 modelBuilder)
        {
            base.ResolveReferences(modelBuilder);
            foreach (Class567 class567 in this.list_1)
            {
                class567.ResolveReferences(modelBuilder);
            }
            bool          flag = false;
            DxfDictionary extensionDictionary = this.dxfTableStyle_0.ExtensionDictionary;

            if (extensionDictionary != null && extensionDictionary.Entries.Count > 0)
            {
                IDictionaryEntry first = extensionDictionary.Entries.GetFirst("ACAD_ROUNDTRIP_2008_TABLESTYLE_CELLSTYLEMAP");
                if (first != null)
                {
                    DxfCellStyleMap key = first.Value as DxfCellStyleMap;
                    Class264        class264;
                    if (key != null && modelBuilder.CellStyleMapBuilders.TryGetValue(key, out class264))
                    {
                        class264.ResolveReferences(modelBuilder, this.dxfTableStyle_0);
                        flag = true;
                    }
                }
            }
            if (flag)
            {
                return;
            }
            if (this.dxfTableStyle_0.DataCellStyle == null && this.list_1.Count > 0)
            {
                DxfTableCellStyle cellStyle = this.list_1[0].CellStyle;
                if (string.IsNullOrEmpty(cellStyle.Name))
                {
                    cellStyle.Name = "_DATA";
                }
                this.dxfTableStyle_0.method_8(cellStyle);
            }
            if (this.dxfTableStyle_0.TitleCellStyle == null && this.list_1.Count > 1)
            {
                DxfTableCellStyle cellStyle = this.list_1[1].CellStyle;
                if (string.IsNullOrEmpty(cellStyle.Name))
                {
                    cellStyle.Name = "_TITLE";
                }
                this.dxfTableStyle_0.method_10(cellStyle);
            }
            if (this.dxfTableStyle_0.HeaderCellStyle == null && this.list_1.Count > 2)
            {
                DxfTableCellStyle cellStyle = this.list_1[2].CellStyle;
                if (string.IsNullOrEmpty(cellStyle.Name))
                {
                    cellStyle.Name = "_HEADER";
                }
                this.dxfTableStyle_0.method_9(cellStyle);
            }
            foreach (Class567 class567 in this.list_1)
            {
                if (class567.CellStyle != this.dxfTableStyle_0.TableCellStyle)
                {
                    DxfTableCellStyle cellStyle = class567.CellStyle;
                    DxfTableCellStyle dxfTableCellStyle;
                    if (this.dxfTableStyle_0.CellStyles.TryGetValue(cellStyle.Name, out dxfTableCellStyle))
                    {
                        this.dxfTableStyle_0.CellStyles[this.dxfTableStyle_0.CellStyles.IndexOf(dxfTableCellStyle)] = cellStyle;
                    }
                    else
                    {
                        this.dxfTableStyle_0.CellStyles.Add(cellStyle);
                    }
                }
            }
        }
Example #4
0
 public void Visit(DxfCellStyleMap cellStyleMap)
 {
 }
Example #5
0
 public void Visit(DxfCellStyleMap cellStyleMap)
 {
     this.bool_0 = true;
 }