예제 #1
0
        /// <summary>
        /// Translates the report to the language specified
        /// </summary>
        /// <param name="translator">The translation dictionary</param>
        /// <param name="language">The language to translate into</param>
        public void Translate
        (
            PhraseTranslationDictionary translator,
            Language language
        )
        {
            Validate.IsNotNull(translator);
            Validate.IsNotNull(language);

            this.Title = translator.Translate
                         (
                this.Title,
                language
                         );

            this.Description = translator.Translate
                               (
                this.Description,
                language
                               );

            foreach (var section in this.AllSections)
            {
                if (section != null)
                {
                    section.Translate
                    (
                        translator,
                        language
                    );
                }
            }
        }
예제 #2
0
        /// <summary>
        /// Translates the report section to the language specified
        /// </summary>
        /// <param name="translator">The translation dictionary</param>
        /// <param name="language">The language to translate into</param>
        public void Translate
        (
            PhraseTranslationDictionary translator,
            Language language
        )
        {
            Validate.IsNotNull(translator);
            Validate.IsNotNull(language);

            this.Title = translator.Translate
                         (
                this.Title,
                language
                         );

            this.Description = translator.Translate
                               (
                this.Description,
                language
                               );

            foreach (var component in this.Components)
            {
                component.Translate
                (
                    translator,
                    language
                );
            }
        }
예제 #3
0
        /// <summary>
        /// Translates the report category to the language specified
        /// </summary>
        /// <param name="translator">The translation dictionary</param>
        /// <param name="language">The language to translate into</param>
        public void Translate
        (
            PhraseTranslationDictionary translator,
            Language language
        )
        {
            Validate.IsNotNull(translator);
            Validate.IsNotNull(language);

            this.Title = translator.Translate
                         (
                this.Title,
                language
                         );

            this.Description = translator.Translate
                               (
                this.Description,
                language
                               );

            foreach (var subCategory in this.SubCategories.ToList())
            {
                subCategory.Translate
                (
                    translator,
                    language
                );
            }
        }
예제 #4
0
        /// <summary>
        /// Translates the text in the component to the language specified
        /// </summary>
        /// <param name="translator">The translation dictionary</param>
        /// <param name="language">The language to translate into</param>
        public override void Translate
        (
            PhraseTranslationDictionary translator,
            Language language
        )
        {
            base.Translate(translator, language);

            foreach (var column in this.Columns)
            {
                TranslateColumn(column);
            }

            foreach (var row in this.AllRows)
            {
                foreach (var cell in row)
                {
                    TranslateColumn(cell.Column);
                }
            }

            if (this.HasTotals)
            {
                foreach (var cell in this.Totals)
                {
                    TranslateColumn(cell.Column);
                }
            }

            void TranslateColumn(TableColumn column)
            {
                column.Name = translator.Translate
                              (
                    column.Name,
                    language
                              );

                column.Title = translator.Translate
                               (
                    column.Title,
                    language
                               );
            }
        }
예제 #5
0
        /// <summary>
        /// Translates the registered report to the language specified
        /// </summary>
        /// <param name="translator">The translation dictionary</param>
        /// <param name="language">The language to translate into</param>
        public void Translate
        (
            PhraseTranslationDictionary translator,
            Language language
        )
        {
            Validate.IsNotNull(translator);
            Validate.IsNotNull(language);

            this.Title = translator.Translate
                         (
                this.Title,
                language
                         );

            this.Description = translator.Translate
                               (
                this.Description,
                language
                               );
        }
예제 #6
0
        /// <summary>
        /// Translates the text in the component to the language specified
        /// </summary>
        /// <param name="translator">The translation dictionary</param>
        /// <param name="language">The language to translate into</param>
        public override void Translate
        (
            PhraseTranslationDictionary translator,
            Language language
        )
        {
            base.Translate(translator, language);

            this.Title = translator.Translate
                         (
                this.Title,
                language
                         );
        }
예제 #7
0
        /// <summary>
        /// Translates the text in the component to the language specified
        /// </summary>
        /// <param name="translator">The translation dictionary</param>
        /// <param name="language">The language to translate into</param>
        public override void Translate
        (
            PhraseTranslationDictionary translator,
            Language language
        )
        {
            base.Translate(translator, language);

            foreach (var label in this.XAxisLabels)
            {
                label.CustomText = translator.Translate
                                   (
                    label.CustomText,
                    language
                                   );

                label.ToolTip = translator.Translate
                                (
                    label.ToolTip,
                    language
                                );
            }
        }
예제 #8
0
        /// <summary>
        /// Translates the text in the component to the language specified
        /// </summary>
        /// <param name="translator">The translation dictionary</param>
        /// <param name="language">The language to translate into</param>
        public override void Translate
        (
            PhraseTranslationDictionary translator,
            Language language
        )
        {
            base.Translate(translator, language);

            foreach (var overlay in this.Overlays)
            {
                if (overlay.HasLabel)
                {
                    overlay.Label = translator.Translate
                                    (
                        overlay.Label,
                        language
                                    );
                }
            }

            foreach (var statistic in this.OverlayStatistics)
            {
                statistic.Value.ForEach
                (
                    s => s.Translate(translator, language)
                );
            }

            foreach (var area in this.Areas)
            {
                area.ToolTipText = translator.Translate
                                   (
                    area.ToolTipText,
                    language
                                   );
            }
        }