private double GetStartSize() { MapSizeRule mapSizeRule = (MapSizeRule)m_mapRule; ReportSizeProperty startSize = mapSizeRule.StartSize; ReportSize size = startSize.IsExpression ? mapSizeRule.Instance.StartSize : startSize.Value; return(MappingHelper.ToPixels(size, m_mapMapper.DpiX)); }
protected override void ResetInstanceCache() { base.ResetInstanceCache(); m_text = null; m_textEvaluated = false; m_angle = null; m_textShadowOffset = null; }
internal ReportSizeProperty(ExpressionInfo expressionInfo) : base(expressionInfo?.IsExpression ?? false, expressionInfo?.OriginalText) { if (expressionInfo != null && !expressionInfo.IsExpression) { m_value = new ReportSize(expressionInfo.StringValue); } }
internal ReportSizeProperty(ExpressionInfo expressionInfo, bool allowNegative) : base(expressionInfo?.IsExpression ?? false, expressionInfo?.OriginalText) { if (expressionInfo != null && !expressionInfo.IsExpression) { m_value = new ReportSize(expressionInfo.StringValue, validate: true, allowNegative); } }
protected override void ResetInstanceCache() { base.ResetInstanceCache(); m_hueColor = null; m_transparency = null; m_offsetX = null; m_offsetY = null; }
internal void SetCachedHeight(double sizeDelta) { if (m_isOldSnapshot) { double sizeInMM = RenderReportItem.Height.ToMillimeters() + sizeDelta; string size = sizeInMM.ToString("f5", CultureInfo.InvariantCulture) + "mm"; m_cachedHeight = new ReportSize(size, sizeInMM); } }
protected override void ResetInstanceCache() { base.ResetInstanceCache(); m_textResult = null; m_formattedText = null; m_angle = null; m_resizeMode = null; m_textShadowOffset = null; m_useFontPercent = null; }
public static bool TryParse(string value, bool allowNegative, out ReportSize reportSize) { if (Microsoft.ReportingServices.ReportPublishing.Validator.ValidateSize(value, allowNegative, out double sizeInMM)) { reportSize = new ReportSize(value, sizeInMM); return(true); } reportSize = null; return(false); }
protected override void ResetInstanceCache() { m_colorEvaluated = false; m_colorAssigned = false; m_color = null; m_styleEvaluated = false; m_styleAssigned = false; m_widthEvaluated = false; m_widthAssigned = false; m_width = null; }
protected override void ResetInstanceCache() { base.ResetInstanceCache(); m_layout = null; m_autoFitTextDisabled = null; m_minFontSize = null; m_interlacedRows = null; m_interlacedRowsColor = null; m_equallySpacedItems = null; m_textWrapThreshold = null; }
protected override void ResetInstanceCache() { base.ResetInstanceCache(); m_leftIndent = null; m_rightIndent = null; m_hangingIndent = null; m_spaceBefore = null; m_spaceAfter = null; m_listStyle = null; m_listLevel = null; }
public static ReportSize SumSizes(ReportSize size1, ReportSize size2) { if (size1 == null) { return(size2); } if (size2 == null) { return(size1); } return(FromMillimeters(size1.ToMillimeters() + size2.ToMillimeters())); }
internal ReportSizeProperty(ExpressionInfo expressionInfo, ReportSize defaultValue) : base(expressionInfo?.IsExpression ?? false, (expressionInfo == null) ? defaultValue.ToString() : expressionInfo.OriginalText) { if (expressionInfo != null && !expressionInfo.IsExpression) { m_value = new ReportSize(expressionInfo.StringValue); } else { m_value = defaultValue; } }
internal ReportSizeProperty(bool isExpression, string expressionString, ReportSize value, ReportSize defaultValue) : base(isExpression, expressionString) { if (!isExpression) { m_value = value; } else { m_value = defaultValue; } }
internal ReportSize DeepClone() { ReportSize reportSize = new ReportSize(); if (m_size != null) { reportSize.m_size = string.Copy(m_size); } reportSize.m_parsed = m_parsed; reportSize.m_sizeInMM = m_sizeInMM; return(reportSize); }
private ReportSize GetOrEvaluateMarginProperty(ref ReportSize property, Microsoft.ReportingServices.ReportIntermediateFormat.Tablix.MarginPosition marginPosition) { if (m_owner.IsOldSnapshot) { return(null); } if (property == null) { property = new ReportSize(m_owner.TablixDef.EvaluateTablixMargin(ReportScopeInstance, marginPosition, m_reportElementDef.RenderingContext.OdpContext)); } return(property); }
protected override void ResetInstanceCache() { base.ResetInstanceCache(); m_tickMarkLength = null; m_colorBarBorderColor = null; m_labelInterval = null; m_labelFormat = null; m_labelPlacement = null; m_labelBehavior = null; m_hideEndLabels = null; m_rangeGapColor = null; m_noDataText = null; }
protected override void ResetInstanceCache() { base.ResetInstanceCache(); m_mapCoordinateSystem = null; m_mapProjection = null; m_projectionCenterX = null; m_projectionCenterY = null; m_maximumZoom = null; m_minimumZoom = null; m_contentMargin = null; m_gridUnderContent = null; m_simplificationResolution = null; }
internal static int GetStyleShadowOffset(Style style, StyleInstance styleInstance, float dpi) { ReportSizeProperty shadowOffset = style.ShadowOffset; if (!shadowOffset.IsExpression) { return(ToIntPixels(shadowOffset.Value, dpi)); } ReportSize shadowOffset2 = styleInstance.ShadowOffset; if (shadowOffset2 != null) { return(ToIntPixels(shadowOffset2, dpi)); } return(0); }
private bool HasPaddingValue(string attrName, ReportSize generalPadding, out ReportSize effectivePadding) { if (m_currentHtmlElement.CssStyle.TryGetValue(attrName, out string value)) { if (ReportSize.TryParse(value, out ReportSize reportSize)) { effectivePadding = reportSize; return(true); } m_richTextLogger.RegisterInvalidSizeWarning("padding", value, m_currentHtmlElement.CharacterPosition); } if (generalPadding != null) { effectivePadding = generalPadding; return(true); } effectivePadding = null; return(false); }
internal void SetAssignedDynamicValue(BorderStyleProperty prop, Microsoft.ReportingServices.ReportIntermediateFormat.AttributeInfo value, bool allowTransparency) { switch (prop) { case BorderStyleProperty.Color: m_colorEvaluated = true; m_color = new ReportColor(value.Value, allowTransparency); break; case BorderStyleProperty.Style: m_styleEvaluated = true; m_style = (BorderStyles)value.IntValue; break; case BorderStyleProperty.Width: m_widthEvaluated = true; m_width = new ReportSize(value.Value); break; } }
internal static float GetStyleFontSize(Style style, StyleInstance styleInstance) { ReportSizeProperty fontSize = style.FontSize; if (IsStylePropertyDefined(fontSize)) { if (!fontSize.IsExpression) { return((float)fontSize.Value.ToPoints()); } if (styleInstance.FontSize != null) { ReportSize fontSize2 = styleInstance.FontSize; if (fontSize2 != null) { return((float)fontSize2.ToPoints()); } } } return(DefaultFontSize); }
internal static int GetStyleBorderWidth(Border border, float dpi) { ReportSizeProperty width = border.Width; int result = GetDefaultBorderWidth(dpi); if (!width.IsExpression) { if (width.Value != null) { result = ToIntPixels(width.Value, dpi); } } else { ReportSize width2 = border.Instance.Width; if (width2 != null) { result = ToIntPixels(width2, dpi); } } return(result); }
internal static int ToIntPixels(ReportSize size, float dpi) { return(Convert.ToInt32(ToPixels(size, dpi))); }
internal static double ToPixels(ReportSize size, float dpi) { return(size.ToInches() * (double)dpi); }
protected override void ResetInstanceCache() { base.ResetInstanceCache(); m_width = null; m_labelPlacement = null; }
protected override void ResetInstanceCache() { base.ResetInstanceCache(); m_startSize = null; m_endSize = null; }
internal ReportSizeProperty(bool isExpression, string expressionString, ReportSize value) : this(isExpression, expressionString, value, null) { }
protected override void ResetInstanceCache() { base.ResetInstanceCache(); m_dynamicHeight = null; m_dynamicWidth = null; }
internal override void SetNewContext() { m_topMargin = (m_bottomMargin = (m_leftMargin = (m_rightMargin = null))); base.SetNewContext(); }