Esempio n. 1
0
        public override void Render(RdlRender.Container box)
        {
            base.Render(box);

            base.Render(box);

            bool visible = true;

            if (_visibility != null && _visibility.IsHidden && _visibility.ToggleItem == null)
            {
                visible = false;
            }
            if (box != null && visible)
            {
                _box = box.AddFixedContainer(this, Style);
                _box.PageBreakBefore = _pageBreakAtStart;
                _box.PageBreakAfter  = _pageBreakAtEnd;
                _box.Name            = "Rectangle";
                if (IsInCell)
                {
                    _box.Width             = box.Width;
                    _box.MatchParentHeight = true;
                }
                else
                {
                    _box.Top    = _top.points;
                    _box.Left   = _left.points;
                    _box.Width  = (_width == null) ? box.Width : _width.points;
                    _box.Height = _height.points;
                }
            }

            _reportItems.Render(_box);
        }
Esempio n. 2
0
        public override void Render(RdlRender.Container box)
        {
            base.Render(box);

            RdlRender.FixedContainer rowBox = null;
            bool visible = true;

            if (_visibility != null && _visibility.IsHidden && _visibility.ToggleItem == null)
            {
                visible = false;
            }
            if (box != null && visible)
            {
                rowBox        = box.AddFixedContainer(this, Style);
                rowBox.Name   = "TableRow";
                rowBox.Width  = box.Width;
                rowBox.Height = _height.points;
            }
            decimal cellPos = 0;

            foreach (TableCell tc in _tableCells)
            {
                tc.Render(rowBox, ref cellPos);
            }
        }
Esempio n. 3
0
        public void Render(RdlRender.Container box, ref decimal cellPos)
        {
            base.Render(box);

            Table table = FindTable(this);

            RdlRender.FixedContainer cellBox = null;

            bool visible = true;

            if (table.TableColumns[_colIndex].Visibility != null && table.TableColumns[_colIndex].Visibility.IsHidden && table.TableColumns[_colIndex].Visibility.ToggleItem == null)
            {
                visible = false;
            }
            if (box != null && visible)
            {
                cellBox      = box.AddFixedContainer(this, Style);
                cellBox.Name = "TableCell";
                cellBox.Left = cellPos;
                for (int i = 0; i < _colSpan; i++)
                {
                    cellBox.Width += table.TableColumns[_colIndex + i].Width.points;
                }

                cellPos += cellBox.Width;
                cellBox.MatchParentHeight = true;
            }

            _reportItem.Render(cellBox);
        }
Esempio n. 4
0
        public override void Render(RdlRender.Container box)
        {
            bool hidden = false;

            base.Render(box);

            RdlRuntime.Context parentContext = ParentContext(null);
            _context = new RdlRuntime.Context(
                parentContext,
                null,
                null,
                _grouping,
                _sortBy);

            if (_visibility != null && _visibility.ToggleItem == null)
            {
                hidden = _visibility.IsHidden;
            }

            // Loop through all of the rows in the data context
            decimal top = 0;

            while (true)
            {
                if (_grouping == null && _context.CurrentRow == null)
                {
                    break;
                }
                if (_grouping != null && _context.GroupIndex >= _context.GroupCount)
                {
                    break;
                }

                foreach (TableRow tr in _tableRows)
                {
                    RdlRender.FixedContainer rowBox = null;
                    if (box != null && !hidden)
                    {
                        rowBox             = box.AddFixedContainer(this, Style);
                        rowBox.Name        = "RowBox";
                        rowBox.Top         = top;
                        rowBox.Width       = box.Width;
                        rowBox.ContextBase = true;
                    }

                    tr.Render(rowBox);

                    if (box != null && !hidden)
                    {
                        top       += rowBox.Height;
                        box.Height = top;
                    }
                }

                if (_grouping == null)
                {
                    _context.MoveNext();
                }
                else
                {
                    _context.NextGroup();
                }
            }
        }