public static void GetFontFormatInformation(RPLElementProps elementProperties, out RPLFormat.WritingModes writingMode, out RPLFormat.Directions direction, out RPLFormat.VerticalAlignments verticalAlign, out RPLFormat.TextAlignments textAlign, ref bool stringFormatFromInstance)
 {
     writingMode   = (RPLFormat.WritingModes)SharedRenderer.GetStylePropertyValueObject(elementProperties, (byte)30, ref stringFormatFromInstance);
     direction     = (RPLFormat.Directions)SharedRenderer.GetStylePropertyValueObject(elementProperties, (byte)29, ref stringFormatFromInstance);
     verticalAlign = (RPLFormat.VerticalAlignments)SharedRenderer.GetStylePropertyValueObject(elementProperties, (byte)26, ref stringFormatFromInstance);
     textAlign     = (RPLFormat.TextAlignments)SharedRenderer.GetStylePropertyValueObject(elementProperties, (byte)25, ref stringFormatFromInstance);
 }
示例#2
0
        public override RPLElement CreateRPLElement(RPLElementProps props, PageContext pageContext)
        {
            RPLElement rPLElement = this.CreateRPLElement();

            base.WriteElementProps(rPLElement.ElementProps, pageContext);
            return(rPLElement);
        }
示例#3
0
        public override void WriteCustomNonSharedItemProps(RPLElementProps nonSharedProps, PageContext pageContext)
        {
            ActionInfoWithDynamicImageMapCollection actionInfoWithDynamicImageMapCollection = null;
            RPLDynamicImageProps rPLDynamicImageProps = (RPLDynamicImageProps)nonSharedProps;

            rPLDynamicImageProps.DynamicImageContent = this.LoadDynamicImage(out actionInfoWithDynamicImageMapCollection, pageContext);
        }
示例#4
0
        public void RenderReportItem(RPLElement reportItem, RPLItemMeasurement measurement, StyleContext styleContext, ref int borderContext, bool renderId, bool treatAsTopLevel)
        {
            RPLElementProps    elementProps = reportItem.ElementProps;
            RPLElementPropsDef definition   = elementProps.Definition;

            this.RenderLine((RPLLine)reportItem, elementProps, (RPLLinePropsDef)definition, measurement, renderId, styleContext);
        }
示例#5
0
        public void RenderReportItem(RPLElement reportItem, RPLItemMeasurement measurement, StyleContext styleContext, ref int borderContext, bool renderId, bool treatAsTopLevel)
        {
            RPLElementProps    elementProps = reportItem.ElementProps;
            RPLElementPropsDef definition   = elementProps.Definition;

            RenderRectangle((RPLContainer)reportItem, elementProps, definition, measurement, ref borderContext, renderId, styleContext, treatAsTopLevel);
        }
 internal static void GetFontFormatInformation(RPLElementProps elementProperties, out RPLFormat.WritingModes writingMode, out RPLFormat.Directions direction, out RPLFormat.VerticalAlignments verticalAlign, out RPLFormat.TextAlignments textAlign, ref bool stringFormatFromInstance)
 {
     writingMode   = (RPLFormat.WritingModes)GetStylePropertyValueObject(elementProperties, 30, ref stringFormatFromInstance);
     direction     = (RPLFormat.Directions)GetStylePropertyValueObject(elementProperties, 29, ref stringFormatFromInstance);
     verticalAlign = (RPLFormat.VerticalAlignments)GetStylePropertyValueObject(elementProperties, 26, ref stringFormatFromInstance);
     textAlign     = (RPLFormat.TextAlignments)GetStylePropertyValueObject(elementProperties, 25, ref stringFormatFromInstance);
 }
示例#7
0
 private static void GetReportItemPaddingStyleMM(RPLElementProps instanceProperties, out float paddingLeft, out float paddingTop, out float paddingRight, out float paddingBottom)
 {
     paddingLeft   = GetStylePropertyValueSizeMM(instanceProperties, 15, 0f);
     paddingTop    = GetStylePropertyValueSizeMM(instanceProperties, 17, 0f);
     paddingRight  = GetStylePropertyValueSizeMM(instanceProperties, 16, 0f);
     paddingBottom = GetStylePropertyValueSizeMM(instanceProperties, 18, 0f);
 }
 internal static void GetFontStyleInformation(RPLElementProps elementProperties, out RPLFormat.FontStyles fontStyle, out RPLFormat.FontWeights fontWeight, out RPLFormat.TextDecorations textDecoration, out float fontSize, out string fontFamily, ref bool fontStyleFromInstance)
 {
     fontSize       = (float)new RPLReportSize(GetStylePropertyValueString(elementProperties, 21, ref fontStyleFromInstance)).ToPoints();
     fontStyle      = (RPLFormat.FontStyles)GetStylePropertyValueObject(elementProperties, 19, ref fontStyleFromInstance);
     fontWeight     = (RPLFormat.FontWeights)GetStylePropertyValueObject(elementProperties, 22, ref fontStyleFromInstance);
     textDecoration = (RPLFormat.TextDecorations)GetStylePropertyValueObject(elementProperties, 24, ref fontStyleFromInstance);
     fontFamily     = GetStylePropertyValueString(elementProperties, 20, ref fontStyleFromInstance);
 }
示例#9
0
 internal static void CalculateUsableReportItemRectangle(RPLElementProps properties, ref RectangleF position)
 {
     GetReportItemPaddingStyleMM(properties, out float paddingLeft, out float paddingTop, out float paddingRight, out float paddingBottom);
     position.X      += paddingLeft;
     position.Y      += paddingTop;
     position.Width  -= paddingLeft + paddingRight;
     position.Height -= paddingTop + paddingBottom;
 }
 public static void GetFontStyleInformation(RPLElementProps elementProperties, out RPLFormat.FontStyles fontStyle, out RPLFormat.FontWeights fontWeight, out RPLFormat.TextDecorations textDecoration, out float fontSize, out string fontFamily, ref bool fontStyleFromInstance)
 {
     fontSize       = (float)new RPLReportSize(SharedRenderer.GetStylePropertyValueString(elementProperties, (byte)21, ref fontStyleFromInstance)).ToPoints();
     fontStyle      = (RPLFormat.FontStyles)SharedRenderer.GetStylePropertyValueObject(elementProperties, (byte)19, ref fontStyleFromInstance);
     fontWeight     = (RPLFormat.FontWeights)SharedRenderer.GetStylePropertyValueObject(elementProperties, (byte)22, ref fontStyleFromInstance);
     textDecoration = (RPLFormat.TextDecorations)SharedRenderer.GetStylePropertyValueObject(elementProperties, (byte)24, ref fontStyleFromInstance);
     fontFamily     = SharedRenderer.GetStylePropertyValueString(elementProperties, (byte)20, ref fontStyleFromInstance);
 }
        public static RPLFormat.BorderStyles GetStylePropertyValueBorderStyle(RPLElementProps properties, byte style, RPLFormat.BorderStyles defaultStyle)
        {
            object stylePropertyValueObject = SharedRenderer.GetStylePropertyValueObject(properties, style);

            if (stylePropertyValueObject != null)
            {
                return((RPLFormat.BorderStyles)stylePropertyValueObject);
            }
            return(defaultStyle);
        }
示例#12
0
 internal override void WriteCustomNonSharedItemProps(RPLElementProps nonSharedProps, RPLWriter rplWriter, PageContext pageContext)
 {
     Microsoft.ReportingServices.OnDemandReportRendering.Report report = ((Microsoft.ReportingServices.OnDemandReportRendering.SubReport)m_source).Report;
     if (report != null && report.Language != null)
     {
         string text = null;
         text = ((!report.Language.IsExpression) ? report.Language.Value : report.Instance.Language);
         ((RPLSubReportProps)nonSharedProps).Language = text;
     }
 }
示例#13
0
        internal static float GetStylePropertyValueSizePT(RPLElementProps properties, byte style, ref bool fromInstance)
        {
            string text = (string)SharedRenderer.GetStylePropertyValueObject(properties, style, ref fromInstance);

            if (string.IsNullOrEmpty(text))
            {
                return(float.NaN);
            }
            return((float)new RPLReportSize(text).ToPoints());
        }
示例#14
0
        internal static float GetStylePropertyValueSizeMM(RPLElementProps properties, byte style)
        {
            string text = (string)SharedRenderer.GetStylePropertyValueObject(properties, style);

            if (string.IsNullOrEmpty(text))
            {
                return(float.NaN);
            }
            return((float)new RPLReportSize(text).ToMillimeters());
        }
示例#15
0
        internal static Color GetStylePropertyValueColor(RPLElementProps properties, byte style)
        {
            string text = (string)SharedRenderer.GetStylePropertyValueObject(properties, style);

            if (string.IsNullOrEmpty(text) || string.Compare(text, "TRANSPARENT", StringComparison.OrdinalIgnoreCase) == 0)
            {
                return(Color.Empty);
            }
            return(new RPLReportColor(text).ToColor());
        }
        public static string GetStylePropertyValueString(RPLElementProps properties, byte style, ref bool fromInstance)
        {
            object stylePropertyValueObject = SharedRenderer.GetStylePropertyValueObject(properties, style, ref fromInstance);

            if (stylePropertyValueObject == null)
            {
                return(null);
            }
            return((string)stylePropertyValueObject);
        }
示例#17
0
        public override void WriteSharedItemProps(RPLElementProps elemProps, RPLWriter rplWriter, PageContext pageContext)
        {
            AspNetCore.ReportingServices.OnDemandReportRendering.Paragraph paragraph = base.m_source as AspNetCore.ReportingServices.OnDemandReportRendering.Paragraph;
            RSTrace.RenderingTracer.Assert(paragraph != null, "The paragraph definition cannot be null");
            Hashtable hashtable = pageContext.ItemPropsStart;

            if (hashtable != null)
            {
                object obj = hashtable[this.SourceID];
                if (obj != null)
                {
                    elemProps.Definition = (RPLParagraphPropsDef)obj;
                    return;
                }
            }
            RPLParagraphProps    rPLParagraphProps    = elemProps as RPLParagraphProps;
            RPLParagraphPropsDef rPLParagraphPropsDef = rPLParagraphProps.Definition as RPLParagraphPropsDef;

            if (hashtable == null)
            {
                hashtable = (pageContext.ItemPropsStart = new Hashtable());
            }
            hashtable.Add(this.SourceID, rPLParagraphPropsDef);
            rPLParagraphPropsDef.ID = this.SourceID;
            if (this.IsNotExpressionValue(paragraph.LeftIndent))
            {
                rPLParagraphPropsDef.LeftIndent = new RPLReportSize(paragraph.LeftIndent.Value.ToString());
            }
            if (this.IsNotExpressionValue(paragraph.RightIndent))
            {
                rPLParagraphPropsDef.RightIndent = new RPLReportSize(paragraph.RightIndent.Value.ToString());
            }
            if (this.IsNotExpressionValue(paragraph.HangingIndent))
            {
                rPLParagraphPropsDef.HangingIndent = new RPLReportSize(paragraph.HangingIndent.Value.ToString());
            }
            if (!paragraph.ListStyle.IsExpression)
            {
                rPLParagraphPropsDef.ListStyle = (RPLFormat.ListStyles)StyleEnumConverter.Translate(paragraph.ListStyle.Value);
            }
            if (!paragraph.ListLevel.IsExpression)
            {
                rPLParagraphPropsDef.ListLevel = paragraph.ListLevel.Value;
            }
            if (this.IsNotExpressionValue(paragraph.SpaceBefore))
            {
                rPLParagraphPropsDef.SpaceBefore = new RPLReportSize(paragraph.SpaceBefore.Value.ToString());
            }
            if (this.IsNotExpressionValue(paragraph.SpaceAfter))
            {
                rPLParagraphPropsDef.SpaceAfter = new RPLReportSize(paragraph.SpaceAfter.Value.ToString());
            }
            rPLParagraphPropsDef.SharedStyle = this.WriteSharedStyle(null, pageContext);
        }
示例#18
0
 internal override void WriteCustomNonSharedItemProps(RPLElementProps nonSharedProps, PageContext pageContext)
 {
     Microsoft.ReportingServices.OnDemandReportRendering.Report report = ((Microsoft.ReportingServices.OnDemandReportRendering.SubReport)m_source).Report;
     if (report != null)
     {
         string reportLanguage = Report.GetReportLanguage(report);
         if (reportLanguage != null)
         {
             ((RPLSubReportProps)nonSharedProps).Language = reportLanguage;
         }
     }
 }
        public void RenderReportItem(RPLElement reportItem, RPLItemMeasurement measurement, StyleContext styleContext, ref int borderContext, bool renderId, bool treatAsTopLevel)
        {
            RPLSubReport       rPLSubReport = (RPLSubReport)reportItem;
            RPLElementProps    elementProps = reportItem.ElementProps;
            RPLElementPropsDef definition   = elementProps.Definition;

            using (html5Renderer.m_reportContext.EnterSubreport(definition))
            {
                if (!styleContext.InTablix || renderId)
                {
                    styleContext.RenderMeasurements = false;
                    html5Renderer.WriteStream(HTMLElements.m_openDiv);
                    html5Renderer.RenderReportItemStyle(rPLSubReport, elementProps, definition, measurement, styleContext, ref borderContext, definition.ID);
                    if (renderId)
                    {
                        html5Renderer.RenderReportItemId(elementProps.UniqueName);
                    }
                    html5Renderer.WriteStreamCR(HTMLElements.m_closeBracket);
                }
                RPLItemMeasurement[] children = rPLSubReport.Children;
                int  num             = 0;
                int  num2            = borderContext;
                bool usePercentWidth = children.Length != 0;
                int  num3            = children.Length;
                for (int i = 0; i < num3; i++)
                {
                    if (i == 0 && num3 > 1 && (borderContext & 8) > 0)
                    {
                        num2 &= -9;
                    }
                    else if (i == 1 && (borderContext & 4) > 0)
                    {
                        num2 &= -5;
                    }
                    if (i > 0 && i == num3 - 1 && (borderContext & 8) > 0)
                    {
                        num2 |= 8;
                    }
                    num = num2;
                    RPLItemMeasurement rPLItemMeasurement = children[i];
                    RPLContainer       rPLContainer       = (RPLContainer)rPLItemMeasurement.Element;
                    RPLElementProps    elementProps2      = rPLContainer.ElementProps;
                    RPLElementPropsDef definition2        = elementProps2.Definition;
                    html5Renderer.m_isBody          = true;
                    html5Renderer.m_usePercentWidth = usePercentWidth;
                    new RectangleRenderer(html5Renderer).RenderReportItem(rPLContainer, rPLItemMeasurement, new StyleContext(), ref num, renderId: false, treatAsTopLevel);
                }
                if (!styleContext.InTablix || renderId)
                {
                    html5Renderer.WriteStreamCR(HTMLElements.m_closeDiv);
                }
            }
        }
示例#20
0
 public override void WriteCustomNonSharedItemProps(RPLElementProps nonSharedProps, PageContext pageContext)
 {
     AspNetCore.ReportingServices.OnDemandReportRendering.Report report = ((AspNetCore.ReportingServices.OnDemandReportRendering.SubReport)base.m_source).Report;
     if (report != null)
     {
         string reportLanguage = Report.GetReportLanguage(report);
         if (reportLanguage != null)
         {
             ((RPLSubReportProps)nonSharedProps).Language = reportLanguage;
         }
     }
 }
示例#21
0
        public override void WriteNonSharedItemProps(RPLElementProps elemProps, RPLWriter rplWriter, PageContext pageContext)
        {
            AspNetCore.ReportingServices.OnDemandReportRendering.TextRun textRun = base.m_source as AspNetCore.ReportingServices.OnDemandReportRendering.TextRun;
            RSTrace.RenderingTracer.Assert(textRun != null, "The text run definition cannot be null");
            TextRunInstance textRunInstance = null;
            bool            flag            = false;

            if (this.m_compiledSource != null)
            {
                textRunInstance = this.m_compiledSource;
                flag            = true;
            }
            else
            {
                textRunInstance = textRun.Instance;
                RSTrace.RenderingTracer.Assert(textRunInstance != null, "The text run instance cannot be null");
            }
            elemProps.UniqueName = textRunInstance.UniqueName;
            RPLTextRunProps rPLTextRunProps = elemProps as RPLTextRunProps;

            if (!flag)
            {
                rPLTextRunProps.ProcessedWithError = textRunInstance.ProcessedWithError;
                if (textRun.MarkupType.IsExpression)
                {
                    rPLTextRunProps.Markup = (RPLFormat.MarkupStyles)StyleEnumConverter.Translate(textRunInstance.MarkupType);
                }
                if (textRun.ToolTip != null && textRun.ToolTip.IsExpression && textRunInstance.ToolTip != null)
                {
                    rPLTextRunProps.ToolTip = textRunInstance.ToolTip;
                }
                rPLTextRunProps.ActionInfo = base.WriteActionInfo(textRun.ActionInfo, pageContext);
            }
            else
            {
                rPLTextRunProps.Markup = (RPLFormat.MarkupStyles)StyleEnumConverter.Translate(textRunInstance.MarkupType);
                if (textRunInstance.ToolTip != null)
                {
                    rPLTextRunProps.ToolTip = textRunInstance.ToolTip;
                }
                if (this.m_compiledSource.ActionInstance != null)
                {
                    rPLTextRunProps.ActionInfo = this.WriteActionInstance(this.m_compiledSource.ActionInstance, pageContext);
                }
            }
            if ((pageContext.HideDuplicates || textRun.FormattedValueExpressionBased) && textRunInstance.Value != null)
            {
                rPLTextRunProps.Value = textRunInstance.Value;
            }
            pageContext.HideDuplicates     = false;
            pageContext.TypeCodeNonString  = false;
            rPLTextRunProps.NonSharedStyle = this.WriteNonSharedStyle(null, null, pageContext, this.m_compiledSource);
        }
示例#22
0
        public override void WriteSharedItemProps(RPLElementProps elemProps, RPLWriter rplWriter, PageContext pageContext)
        {
            AspNetCore.ReportingServices.OnDemandReportRendering.TextRun textRun = base.m_source as AspNetCore.ReportingServices.OnDemandReportRendering.TextRun;
            RSTrace.RenderingTracer.Assert(textRun != null, "The text run definition cannot be null");
            Hashtable hashtable = pageContext.ItemPropsStart;

            if (hashtable != null)
            {
                object obj = hashtable[this.SourceID];
                if (obj != null)
                {
                    elemProps.Definition = (RPLTextRunPropsDef)obj;
                    return;
                }
            }
            RPLTextRunProps    rPLTextRunProps    = elemProps as RPLTextRunProps;
            RPLTextRunPropsDef rPLTextRunPropsDef = rPLTextRunProps.Definition as RPLTextRunPropsDef;

            if (hashtable == null)
            {
                hashtable = (pageContext.ItemPropsStart = new Hashtable());
            }
            hashtable.Add(this.SourceID, rPLTextRunPropsDef);
            rPLTextRunPropsDef.ID = this.SourceID;
            if (!textRun.MarkupType.IsExpression)
            {
                rPLTextRunPropsDef.Markup = (RPLFormat.MarkupStyles)StyleEnumConverter.Translate(textRun.MarkupType.Value);
            }
            if (textRun.Label != null)
            {
                rPLTextRunPropsDef.Label = textRun.Label;
            }
            if (textRun.ToolTip != null && !textRun.ToolTip.IsExpression && textRun.ToolTip.Value != null)
            {
                rPLTextRunPropsDef.ToolTip = textRun.ToolTip.Value;
            }
            if (textRun.Value.IsExpression)
            {
                rPLTextRunPropsDef.Formula = textRun.Value.ExpressionString;
            }
            if (!pageContext.HideDuplicates && !textRun.FormattedValueExpressionBased && textRun.Value.Value != null)
            {
                if (textRun.SharedTypeCode == TypeCode.String)
                {
                    rPLTextRunPropsDef.Value = textRun.Value.Value;
                }
                else
                {
                    rPLTextRunPropsDef.Value = textRun.Instance.Value;
                }
            }
            rPLTextRunPropsDef.SharedStyle = this.WriteSharedStyle(null, pageContext);
        }
示例#23
0
 protected void RenderLine(RPLLine reportItem, RPLElementProps rplProps, RPLLinePropsDef rplPropsDef, RPLItemMeasurement measurement, bool renderId, StyleContext styleContext)
 {
     if (this.html5Renderer.IsLineSlanted(measurement))
     {
         if (renderId)
         {
             this.html5Renderer.RenderNavigationId(rplProps.UniqueName);
         }
         if (this.html5Renderer.m_deviceInfo.BrowserMode == BrowserMode.Quirks)
         {
             this.RenderVMLLine(reportItem, measurement, styleContext);
         }
     }
     else
     {
         bool flag = measurement.Height == 0.0;
         this.html5Renderer.WriteStream(HTMLElements.m_openSpan);
         if (renderId)
         {
             this.html5Renderer.RenderReportItemId(rplProps.UniqueName);
         }
         int    num = 0;
         object obj = rplProps.Style[10];
         if (obj != null)
         {
             this.html5Renderer.OpenStyle();
             if (flag)
             {
                 this.html5Renderer.WriteStream(HTMLElements.m_styleHeight);
             }
             else
             {
                 this.html5Renderer.WriteStream(HTMLElements.m_styleWidth);
             }
             this.html5Renderer.WriteStream(obj);
             this.html5Renderer.WriteStream(HTMLElements.m_semiColon);
         }
         obj = rplProps.Style[0];
         if (obj != null)
         {
             this.html5Renderer.OpenStyle();
             this.html5Renderer.WriteStream(HTMLElements.m_backgroundColor);
             this.html5Renderer.WriteStream(obj);
         }
         this.html5Renderer.RenderReportItemStyle(reportItem, measurement, ref num);
         this.html5Renderer.CloseStyle(true);
         this.html5Renderer.WriteStream(HTMLElements.m_closeBracket);
         this.html5Renderer.WriteStream(HTMLElements.m_closeSpan);
     }
 }
        public override void WriteCustomNonSharedItemProps(RPLElementProps nonSharedProps, RPLWriter rplWriter, PageContext pageContext)
        {
            ActionInfoWithDynamicImageMapCollection actionInfoWithDynamicImageMapCollection = null;
            RPLDynamicImageProps rPLDynamicImageProps = (RPLDynamicImageProps)nonSharedProps;
            string streamName = null;

            System.Drawing.Rectangle empty = System.Drawing.Rectangle.Empty;
            rPLDynamicImageProps.DynamicImageContent       = this.LoadDynamicImage(pageContext, ref streamName, out actionInfoWithDynamicImageMapCollection, out empty);
            rPLDynamicImageProps.ImageConsolidationOffsets = empty;
            rPLDynamicImageProps.StreamName = streamName;
            if (actionInfoWithDynamicImageMapCollection != null)
            {
                rPLDynamicImageProps.ActionImageMapAreas = base.WriteImageMapAreaInstanceCollection(actionInfoWithDynamicImageMapCollection, pageContext);
            }
        }
示例#25
0
        internal override void WriteCustomNonSharedItemProps(RPLElementProps nonSharedProps, PageContext pageContext)
        {
            Microsoft.ReportingServices.OnDemandReportRendering.Image image = (Microsoft.ReportingServices.OnDemandReportRendering.Image)m_source;
            ImageInstance imageInstance = (ImageInstance)image.Instance;
            RPLImageProps rPLImageProps = (RPLImageProps)nonSharedProps;

            if (m_invalidImage)
            {
                WriteInvalidImage(rPLImageProps, pageContext, m_imageProps);
            }
            else
            {
                WriteImage(imageInstance, null, rPLImageProps, pageContext, m_imageProps);
            }
            rPLImageProps.ActionInfo = PageItem.WriteActionInfo(image.ActionInfo);
        }
示例#26
0
        public override void WriteCustomNonSharedItemProps(RPLElementProps nonSharedProps, PageContext pageContext)
        {
            AspNetCore.ReportingServices.OnDemandReportRendering.Image image = (AspNetCore.ReportingServices.OnDemandReportRendering.Image)base.m_source;
            ImageInstance imageInstance = (ImageInstance)image.Instance;
            RPLImageProps rPLImageProps = (RPLImageProps)nonSharedProps;

            if (this.m_invalidImage)
            {
                base.WriteInvalidImage(rPLImageProps, pageContext, this.m_imageProps);
            }
            else
            {
                base.WriteImage(imageInstance, null, rPLImageProps, pageContext, this.m_imageProps);
            }
            rPLImageProps.ActionInfo = PageItem.WriteActionInfo(image.ActionInfo);
        }
示例#27
0
 public override void WriteCustomNonSharedItemProps(RPLElementProps nonSharedProps, RPLWriter rplWriter, PageContext pageContext)
 {
     AspNetCore.ReportingServices.OnDemandReportRendering.Report report = ((AspNetCore.ReportingServices.OnDemandReportRendering.SubReport)base.m_source).Report;
     if (report != null && report.Language != null)
     {
         string text = null;
         if (report.Language.IsExpression)
         {
             ReportInstance instance = report.Instance;
             text = instance.Language;
         }
         else
         {
             text = report.Language.Value;
         }
         ((RPLSubReportProps)nonSharedProps).Language = text;
     }
 }
        internal void ProcessBackgroundColorAndImage(GdiContext context, RPLElementProps properties)
        {
            m_backgroundColor = GdiContext.GetStylePropertyValueColor(properties, 34);
            object stylePropertyValueObject = SharedRenderer.GetStylePropertyValueObject(properties, 33);

            if (stylePropertyValueObject != null)
            {
                m_backgroundImage = GetImage(context, (RPLImageData)stylePropertyValueObject);
                object stylePropertyValueObject2 = SharedRenderer.GetStylePropertyValueObject(properties, 35);
                if (stylePropertyValueObject2 == null)
                {
                    m_backgroundRepeat = RPLFormat.BackgroundRepeatTypes.Repeat;
                }
                else
                {
                    m_backgroundRepeat = (RPLFormat.BackgroundRepeatTypes)stylePropertyValueObject2;
                }
            }
        }
示例#29
0
        internal override void WriteCustomNonSharedItemProps(RPLElementProps nonSharedProps, RPLWriter rplWriter, PageContext pageContext)
        {
            Microsoft.ReportingServices.OnDemandReportRendering.Image image = (Microsoft.ReportingServices.OnDemandReportRendering.Image)m_source;
            ImageInstance imageInstance = (ImageInstance)image.Instance;

            System.Drawing.Image gdiImage      = null;
            RPLImageProps        rPLImageProps = (RPLImageProps)nonSharedProps;

            if (AutoSizeImage(pageContext, imageInstance, out gdiImage))
            {
                WriteImage(null, "InvalidImage", rPLImageProps, pageContext, gdiImage);
            }
            else
            {
                WriteImage(imageInstance, null, rPLImageProps, pageContext, gdiImage);
            }
            rPLImageProps.ActionInfo          = WriteActionInfo(image.ActionInfo, pageContext);
            rPLImageProps.ActionImageMapAreas = WriteImageMapAreaInstanceCollection(imageInstance.ActionInfoWithDynamicImageMapAreas, pageContext);
        }
        public static object GetStylePropertyValueObject(RPLElementProps properties, byte style, ref bool fromInstance)
        {
            object obj = null;

            if (properties.NonSharedStyle != null)
            {
                obj = properties.NonSharedStyle[style];
                if (obj != null)
                {
                    fromInstance = true;
                    return(obj);
                }
            }
            if (properties.Definition.SharedStyle != null)
            {
                obj = properties.Definition.SharedStyle[style];
            }
            return(obj);
        }