products/Sources/formale Sprachen/C/LibreOffice/test/source/sheet/   (Linux Kernel Version 6.17.9©)  Datei vom 5.10.2025 mit Größe 1 kB image not shown  

Quellverzeichnis  xviewpane.cxx   Interaktion und
PortierbarkeitC

 

/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*
 * This file is part of the LibreOffice project.
 *
 * This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
 */


#include <test/sheet/xviewpane.hxx>
#include <com/sun/star/sheet/XViewPane.hpp>
#include <com/sun/star/table/CellRangeAddress.hpp>

#include <cppunit/TestAssert.h>

using namespace css;
using namespace css::uno;

namespace apitest
{
void XViewPane::testFirstVisibleColumn()
{
    sal_Int32 nCol = 5;
    uno::Reference<sheet::XViewPane> xViewPane(init(), UNO_QUERY_THROW);
    xViewPane->setFirstVisibleColumn(nCol);
    CPPUNIT_ASSERT_EQUAL(xViewPane->getFirstVisibleColumn(), nCol);
}

void XViewPane::testFirstVisibleRow()
{
    sal_Int32 nRow = 3;
    uno::Reference<sheet::XViewPane> xViewPane(init(), UNO_QUERY_THROW);
    xViewPane->setFirstVisibleRow(nRow);
    CPPUNIT_ASSERT_EQUAL(xViewPane->getFirstVisibleRow(), nRow);
}

void XViewPane::testVisibleRange()
{
    constexpr sal_Int32 nCol = 5;
    constexpr sal_Int32 nRow = 3;
    uno::Reference<sheet::XViewPane> xViewPane(init(), UNO_QUERY_THROW);
    xViewPane->setFirstVisibleColumn(nCol);
    xViewPane->setFirstVisibleRow(nRow);

    table::CellRangeAddress aCellRangeAddress = xViewPane->getVisibleRange();
    CPPUNIT_ASSERT_EQUAL(short(0), aCellRangeAddress.Sheet);
    CPPUNIT_ASSERT_EQUAL(nRow, aCellRangeAddress.StartRow);
    CPPUNIT_ASSERT_EQUAL(nCol, aCellRangeAddress.StartColumn);
}
}

/* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Messung V0.5 in Prozent
C=93 H=100 G=96

¤ Diese beiden folgenden Angebotsgruppen bietet das Unternehmen0.9Angebot  (Wie Sie bei der Firma Beratungs- und Dienstleistungen beauftragen können 2026-10-01) ¤

*Eine klare Vorstellung vom Zielzustand






Wurzel

Suchen

PVS Prover

Isabelle Prover

NIST Cobol Testsuite

Cephes Mathematical Library

Vienna Development Method

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.