private void UpdateGlyphsWithCurrentFontSize() { //actvw.StartAnimating (); LoadFontAndGatherGlyphInfos(this.unitFontSize, (glyphInfos) => { InvokeOnMainThread(() => { //actvw.StopAnimating (); if (glyphInfos != null) { int nValid = 0; int nNG = 0; glyphInfos.ForEach((gi) => { if (gi.GlyphId != 0) { ++nValid; } else { ++nNG; } }); Window.LabelStatus.StringValue = String.Format("{0} glyphs, {1} valid, {2} NG", glyphInfos.Count, nValid, nNG); _tableViewSource = new XTableViewSource(glyphInfos); _tableViewSource.SetRowHeight(CalculateRowHeightFromUnitFontSize(this.unitFontSize)); NSTableColumn[] columns = Window.TableView.TableColumns(); var imgcol = columns.SingleOrDefault((col) => NSObject.Equals(col.Identifier, _idImageColumn)); imgcol.MinWidth = imgcol.MaxWidth = (float)this.unitFontSize; Window.TableView.Source = _tableViewSource; Window.TableView.ReloadData(); } }); }); }
private void UpdateGlyphsWithCurrentFontSize() { actvw.StartAnimating(); LoadFontAndGatherGlyphInfos(this.unitFontSize, (glyphInfos) => { InvokeOnMainThread(() => { actvw.StopAnimating(); if (glyphInfos != null) { _tableViewSource = new XTableViewSource(glyphInfos); _tableViewSource.SetHeightForRow(CalculateRowHeightFromUnitFontSize(this.unitFontSize)); tblvwGlyphList.Source = _tableViewSource; tblvwGlyphList.ReloadData(); } }); }); }
private void UpdateGlyphsWithCurrentFontSize() { //actvw.StartAnimating (); LoadFontAndGatherGlyphInfos (this.unitFontSize, (glyphInfos) => { InvokeOnMainThread (() => { //actvw.StopAnimating (); if (glyphInfos != null) { int nValid = 0; int nNG = 0; glyphInfos.ForEach ((gi) => { if (gi.GlyphId != 0) ++ nValid; else ++ nNG; }); Window.LabelStatus.StringValue = String.Format ("{0} glyphs, {1} valid, {2} NG", glyphInfos.Count, nValid, nNG); _tableViewSource = new XTableViewSource (glyphInfos); _tableViewSource.SetRowHeight (CalculateRowHeightFromUnitFontSize (this.unitFontSize)); NSTableColumn[] columns = Window.TableView.TableColumns (); var imgcol = columns.SingleOrDefault ((col) => NSObject.Equals (col.Identifier, _idImageColumn)); imgcol.MinWidth = imgcol.MaxWidth = (float)this.unitFontSize; Window.TableView.Source = _tableViewSource; Window.TableView.ReloadData (); } }); }); }
private void UpdateGlyphsWithCurrentFontSize() { actvw.StartAnimating (); LoadFontAndGatherGlyphInfos (this.unitFontSize, (glyphInfos) => { InvokeOnMainThread (() => { actvw.StopAnimating (); if (glyphInfos != null) { _tableViewSource = new XTableViewSource (glyphInfos); _tableViewSource.SetHeightForRow (CalculateRowHeightFromUnitFontSize (this.unitFontSize)); tblvwGlyphList.Source = _tableViewSource; tblvwGlyphList.ReloadData (); } }); }); }