aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbobzel <zzzman@gmail.com>2020-12-12 20:35:05 -0500
committerbobzel <zzzman@gmail.com>2020-12-12 20:35:05 -0500
commitd66d362c8baed297842cdcaf3dee0d9eda38dcea (patch)
tree84a5269db1edeebe744d681f8c848cb51010abb8
parentf56420c57f5f68af00d175fd81ee8a6b69ac39ae (diff)
another attempt to fix document decorations for documents nested in treeviews/stackingviews etc.
-rw-r--r--src/client/views/nodes/ContentFittingDocumentView.tsx5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/client/views/nodes/ContentFittingDocumentView.tsx b/src/client/views/nodes/ContentFittingDocumentView.tsx
index fed857c83..7e5c254f9 100644
--- a/src/client/views/nodes/ContentFittingDocumentView.tsx
+++ b/src/client/views/nodes/ContentFittingDocumentView.tsx
@@ -44,10 +44,7 @@ export class ContentFittingDocumentView extends React.Component<DocumentViewProp
if (this.props.DataDoc) return 1; // this is intended to detect when a document is being rendered inside itself as part of a template, but not as a leaf node where nativeWidth & height would apply.
const layoutStr = (this.props.LayoutTemplateString || StrCast(this.layoutDoc.layout));
if (this.nativeWidth || layoutStr.includes("FormattedTextBox")) return this.nativeScaling;
-
- const wscale = this.layoutDoc[WidthSym]() / this.props.PanelWidth();
- const hscale = this.layoutDoc[HeightSym]() / this.props.PanelHeight();
- return this.nativeScaling * Math.max(wscale, hscale);
+ return 1;
}
private getTransform = () => this.props.ScreenToLocalTransform().