PR feedback

This commit is contained in:
Jake Norbut committed 2019-07-31 08:46:33 -05:00
1 parent ef5dc90406
commit aa62338401
2 files changed
+11 -13

No files matched your search

+1 -1
View File
@@ -334,7 +334,7 @@ namespace mbts.ui.controls {
}
}
var qty_g = _gcr.create_glyph_run();
var qty_g = _gcr.glyph_run;
if (qty_g != null) {
var qty_geom = qty_g.BuildGeometry();
@@ -135,18 +135,16 @@ namespace mbts.ui {
public Size available_size { get => _vcr.available_size; set => _vcr.available_size = value; }
public Size layout_size { get { _ensure_current(); return _vcr.layout_size; } }
public Rect content_area { get { _ensure_current(); return _vcr.content_area; } }
public GlyphRun create_glyph_run() {
if (_text_lines.is_null_or_empty())
return null;
_ensure_current();
Point pt = _vcr.content_area.BottomLeft;
//if (_glyph_run == null) {
// _glyph_run = _glyph_context.from_arranged(_font_size, pt, _glyph_indices, _advance_widths, _glyph_offsets);
//} else if (_glyph_run.BaselineOrigin != pt) {
// _glyph_run.BaselineOrigin = pt;
//}
_glyph_run = _glyph_context.from_arranged(_font_size, pt, _glyph_indices, _advance_widths, _glyph_offsets);
return _glyph_run;
public GlyphRun glyph_run {
get {
if (_text_lines.is_null_or_empty())
return null;
_ensure_current();
Point pt = _vcr.content_area.BottomLeft;
if (_glyph_run == null || _glyph_run.BaselineOrigin != pt)
_glyph_run = _glyph_context.from_arranged(_font_size, pt, _glyph_indices, _advance_widths, _glyph_offsets);
return _glyph_run;
}
}
void _ensure_current() {