CSReportEditor.cEditor.pAddSectionLinesAux C# (CSharp) Метод

pAddSectionLinesAux() приватный Метод

private pAddSectionLinesAux ( cReportSection sec ) : void
sec CSReportDll.cReportSection
Результат void
        private void pAddSectionLinesAux(cReportSection sec)
        {
            csRptSectionType typeSecLn = csRptSectionType.CONTROL;
            cReportAspect aspect = null;
            float maxBottom = 0;
            float minBottom = 0;
            int index = 0;
            float y = 0;

            switch (sec.getTypeSection()) {
                case csRptSectionType.HEADER:
                case csRptSectionType.MAIN_HEADER:

                    pMoveHeader(sec.getKey(), out minBottom, out maxBottom);
                    aspect = sec.getAspect();
                    y = aspect.getHeight() + aspect.getTop();
                    typeSecLn = csRptSectionType.SECLN_HEADER;
                    index = sec.getSectionLines().count() - 2;
                    break;

                case csRptSectionType.DETAIL:
                case csRptSectionType.MAIN_DETAIL:

                    pMoveDetails(sec.getKey(), out minBottom, out maxBottom);
                    aspect = sec.getAspect();
                    y = aspect.getHeight() + aspect.getTop();
                    typeSecLn = csRptSectionType.SECLN_DETAIL;
                    index = sec.getSectionLines().count() - 2;
                    break;

                case csRptSectionType.GROUP_HEADER:

                    pMoveGroupHeader(sec.getKey(), out minBottom, out maxBottom);
                    aspect = sec.getAspect();
                    y = aspect.getHeight() + aspect.getTop();
                    typeSecLn = csRptSectionType.SECLN_GROUPH;
                    index = sec.getSectionLines().count() - 2;
                    break;

                case csRptSectionType.GROUP_FOOTER:

                    pMoveGroupFooter(sec.getKey(), out minBottom, out maxBottom);
                    aspect = sec.getAspect();
                    y = aspect.getHeight() + aspect.getTop();
                    typeSecLn = csRptSectionType.SECLN_GROUPF;
                    index = sec.getSectionLines().count() - 2;
                    break;

                case csRptSectionType.FOOTER:
                case csRptSectionType.MAIN_FOOTER:

                    aspect = sec.getAspect();
                    aspect.setTop(aspect.getTop() - cGlobals.C_HEIGHT_NEW_SECTION);
                    pMoveFooter(sec.getKey(), out minBottom, out maxBottom);
                    m_offY = 0;
                    y = aspect.getHeight() + aspect.getTop() - m_offSet - cGlobals.C_HEIGHT_BAR_SECTION;
                    typeSecLn = csRptSectionType.SECLN_FOOTER;
                    index = 0;
                    break;
            }
            // we add a paint object to all sectionlines except the last one
            // the last sectionline uses the paint object of the section
            //
            cReportSectionLine secL = sec.getSectionLines().item(index);
            secL.setKeyPaint(
                paintSection(secL.getAspect(),
                                secL.getKey(),
                                sec.getTypeSection(),
                                C_SECTIONLINE + (sec.getSectionLines().count() - 2).ToString(),
                                true));

            // section line
            cReportPaintObject po = m_paint.getPaintSections().item(secL.getKeyPaint());
            po.setRptType(typeSecLn);
            po.setRptKeySec(sec.getKey());

            // section
            po = m_paint.getPaintSections().item(sec.getKeyPaint());
            po.setTextLine(C_SECTIONLINE + (sec.getSectionLines().count() - 1).ToString());

            moveSection(m_paint.getPaintSections().item(m_keyFocus), 0, y, minBottom, maxBottom, sec, false);

            refreshBody();
            refreshRule();
        }

Same methods

cEditor::pAddSectionLinesAux ( cReportSection sec, CSReportPaint paintObj ) : void
cEditor