Kaydet (Commit) b523c024 authored tarafından Markus Mohrhard's avatar Markus Mohrhard

add first useful version of new conditional format UNO API

Change-Id: I8b58ae33ad71d0df6ea30f205b4f331541f5b821
üst 52f4d152
......@@ -3449,6 +3449,9 @@ $(eval $(call gb_UnoApi_add_idlfiles,offapi,com/sun/star/sheet,\
XCellRangesQuery \
XCellSeries \
XCompatibilityNames \
XConditionalFormat \
XConditionalFormats \
XConditionEntry \
XConsolidatable \
XConsolidationDescriptor \
XDDELink \
......
/* -*- 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/.
*/
#ifndef __com_sun_star_sheet_Colorscale_idl__
#define __com_sun_star_sheet_Colorscale_idl__
#include <com/sun/star/sheet/XConditionEntry.idl>
#include <com/sun/star/sheet/XColorScaleEntry.idl>
module com { module sun { module star { module sheet {
service ColorScale
{
interface XConditionEntry;
[property] sequence<XColorScaleEntry> ColorScaleEntries;
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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/.
*/
#ifndef __com_sun_star_sheet_ColorScaleEntryType_idl__
#define __com_sun_star_sheet_ColorScaleEntryType_idl__
module com { module sun { module star { module sheet {
constants ColorScaleEntryType
{
const long COLORSCALE_MIN = 0;
const long COLORSCALE_MAX = 1;
const long COLORSCALE_PERCENTILE = 2;
const long COLORSCALE_VALUE = 3;
const long COLORSCALE_PERCENT = 4;
const long COLORSCALE_FORMULA = 5;
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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/.
*/
#ifndef __com_sun_star_sheet_ConditionEntryType_idl__
#define __com_sun_star_sheet_ConditionEntryType_idl__
module com { module sun { module star { module sheet {
constants ConditionEntryType
{
const long CONDITION = 0;
const long COLORSCALE = 0;
const long DATABAR = 0;
const long ICONSET = 0;
const long DATE = 0;
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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/.
*/
#ifndef __com_sun_star_sheet_ConditionFormatEntry_idl__
#define __com_sun_star_sheet_ConditionFormatEntry_idl__
module com { module sun { module star { module sheet {
service ConditionFormatEntry
{
interface XConditionEntry;
[property] ConditionFormatOperator Operator;
[property] string StyleName;
[optional, property] Formula1;
[optional, property] Formula2;
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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/.
*/
#ifndef __com_sun_star_sheet_ConditionFormatOperator_idl__
#define __com_sun_star_sheet_ConditionFormatOperator_idl__
module com { module sun { module star { module sheet {
constants ConditionFormatOperator
{
const long EQUAL = 0;
const long LESS = 1;
const long GREATER = 2;
const long LESS_EQUAL = 3;
const long GREATER_EQUAL = 4;
const long NOT_EQUAL = 5;
const long BETWEEN = 6;
const long NOT_BETWEEN = 7;
const long DUPLICATE = 8;
const long UNIQUE = 9;
const long TOP_N_ELEMENTS = 10;
const long BOTTOM_N_ELEMENTS = 11;
const long TOP_N_PERCENT = 12;
const long BOTTOM_N_PERCENT = 13;
const long ABOVE_AVERAGE = 14;
const long BELOW_AVERAGE = 15;
const long ABOVE_EQUAL_AVERAGE = 16;
const long BELOW_EQUAL_AVERAGE = 17;
const long ERROR = 18;
const long NO_ERROR = 19;
const long CONTAINS = 20;
const long NOT_CONTAINS = 21;
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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/.
*
* This file incorporates work covered by the following license notice:
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed
* with this work for additional information regarding copyright
* ownership. The ASF licenses this file to you under the Apache
* License, Version 2.0 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a copy of
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
#ifndef __com_sun_star_sheet_ConditionalFormat_idl__
#define __com_sun_star_sheet_ConditionalFormat_idl__
#include <com/sun/star/sheet/XConditionalFormat.idl>
#include <com/sun/star/sheet/XSheetCellRanges.idl>
module com { module sun { module star { module sheet {
/** represents a conditional format
*/
service ConditionalFormat
{
interface com::sun::star::beans::XPropertySet;
interface com::sun::star::uno::XConditionalFormat;
/** represents the range for the conditional format
All ranges have to be in the same sheet.
*/
[property] XSheetCellRanges range;
[property] long ID;
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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/.
*/
#ifndef __com_sun_star_sheet_Databar_idl__
#define __com_sun_star_sheet_Databar_idl__
#include <com/sun/star/sheet/XConditionEntry.idl>
#include <com/sun/star/sheet/XColorScaleEntry.idl>
#include <com/sun/star/sheet/DataBarAxis.idl>
module com { module sun { module star { module sheet {
service DataBar
{
interface XConditionEntry;
[property] boolean ShowValue;
[property] DataBarAxis AxisPosition;
[property] boolean Gradient;
[property] com::sun::star::util::Color Color;
[property] com::sun::star::util::Color AxisColor;
[property] boolean UseNegativeColor;
[property, optional] com::sun::star::util::Color NegativeColor;
[property] sequence<XDataBarEntry> DataBarEntries;
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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/.
*/
#ifndef __com_sun_star_sheet_DataBarAxis_idl__
#define __com_sun_star_sheet_DataBarAxis_idl__
module com { module sun { module star { module sheet {
constants DataBarAxis
{
const long AXIS_NONE = 0;
const long AXIS_MIDDLE = 1;
const long AXIS_AUTOMATIC = 2;
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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/.
*/
#ifndef __com_sun_star_sheet_DataBarEntryType_idl__
#define __com_sun_star_sheet_DataBarEntryType_idl__
module com { module sun { module star { module sheet {
constants DataBarEntryType
{
const long DATABAR_AUTO = 1;
const long DATABAR_MIN = 1;
const long DATABAR_MAX = 2;
const long DATABAR_PERCENTILE = 3;
const long DATABAR_VALUE = 4;
const long DATABAR_PERCENT = 5;
const long DATABAR_FORMULA = 6;
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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/.
*/
#ifndef __com_sun_star_sheet_IconSet_idl__
#define __com_sun_star_sheet_IconSet_idl__
#include <com/sun/star/sheet/XConditionEntry.idl>
module com { module sun { module star { module sheet {
service IconSet
{
interface XConditionEntry;
[property] boolean ShowValue;
[property] boolean Reverse;
[property] IconSetType Icons;
[property] sequence<XIconSetEntry> IconSetEntries;
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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/.
*/
#ifndef __com_sun_star_sheet_IconSetEntryType_idl__
#define __com_sun_star_sheet_IconSetEntryType_idl__
module com { module sun { module star { module sheet {
constants IconSetEntryType
{
const long ICONSET_PERCENTILE = 0;
const long ICONSET_VALUE = 1;
const long ICONSET_PERCENT = 2;
const long ICONSET_FORMULA = 3;
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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/.
*/
#ifndef __com_sun_star_sheet_IconSetType_idl__
#define __com_sun_star_sheet_IconSetType_idl__
module com { module sun { module star { module sheet {
constants IconSetType
{
const long ICONSET_3ARROWS = 0;
const long ICONSET_3ARROWS_GRAY = 1;
const long ICONSET_3FLAGS = 2;
const long ICONSET_3TRAFFICLIGHTS1 = 3;
const long ICONSET_3TRAFFICLIGHTS2 = 4;
const long ICONSET_3SIGNS = 5;
const long ICONSET_3SYMBOLS = 6;
const long ICONSET_3SYMBOLS2 = 7;
const long ICONSET_3SMILIES = 8;
const long ICONSET_3COLOR_SIMILIES = 9;
const long ICONSET_4ARROWS = 10;
const long ICONSET_4ARROWS_GRAY = 11;
const long ICONSET_4RED_TO_BLACK = 12;
const long ICONSET_4RATING = 13;
const long ICONSET_4TRAFFICLIGHTS = 14;
const long ICONSET_5ARROWS = 15;
const long ICONSET_5ARROWS_GRAY = 16;
const long ICONSET_5RATINGS = 17;
const long ICONSET_5QUARTERS = 18;
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
......@@ -37,6 +37,7 @@
#include <com/sun/star/sheet/XSheetLinkable.idl>
#include <com/sun/star/sheet/Scenario.idl>
#include <com/sun/star/sheet/XExternalSheetName.idl>
#include <com/sun/star/sheet/XConditionalFormats.idl>
#include <com/sun/star/util/Color.idl>
......@@ -187,6 +188,10 @@ service Spreadsheet
/** specifies the color of the sheet tab, if any.
*/
[optional, property] com::sun::star::util::Color TabColor;
/** specifies all conditional formats of that sheet
*/
[optional, property] com::sun::star::sheet::XConditionalFormats ConditionalFormats;
};
......
/* -*- 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/.
*/
#ifndef __com_sun_star_sheet_XColorScaleEntry_idl__
#define __com_sun_star_sheet_XColorScaleEntry_idl__
module com { module sun { module star { module sheet {
interface XColorScaleEntry
{
com::sun::star::util::Color getColor();
void setColor(com::sun::star::util::Color Color);
string getFormula();
void setFormula(string Formula);
ColorScaleEntryType getType();
void setType(ColorScaleEntryType Type);
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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/.
*/
#ifndef __com_sun_star_sheet_XConditionalFormat_idl__
#define __com_sun_star_sheet_XConditionalFormat_idl__
#include <com/sun/star/uno/XInterface.idl>
#include <com/sun/star/sheet/ConditionEntryType.idl>
module com { module sun { module star { module sheet {
/**
* Abstract base interface for any conditional format
*
* Is extended by any conditional format entry, e.g. color scale, data bar, icon set, date formats, condition formats
*/
interface XConditionEntry : com::sun::star::uno::XInterface
{
long getType();
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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/.
*/
#ifndef __com_sun_star_sheet_XConditionalFormat_idl__
#define __com_sun_star_sheet_XConditionalFormat_idl__
#include <com/sun/star/container/XIndexAccess.idl>
#include <com/sun/star/sheet/XConditionEntry.idl>
module com { module sun { module star { module sheet {
interface XConditionalFormat : com::sun::star::container::XIndexAccess
{
void addEntry( [in] com::sun::star::sheet::XConditionEntry entry );
void removeByIndex( [in] long Index );
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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/.
*/
#ifndef __com_sun_star_sheet_XConditionalFormats_idl__
#define __com_sun_star_sheet_XConditionalFormats_idl__
#include <com/sun/star/sheet/XConditionalFormat.idl>
#include <com/sun/star/sheet/XSheetCellRanges.idl>
#include <com/sun/star/uno/XInterface.idl>
module com { module sun { module star { module sheet {
interface XConditionalFormats : com::sun::star::uno::XInterface
{
/**
* adds a conditional format to the existing list
* returns the id of the inserted conditional format
*/
long addByRange( [in] com::sun::star::sheet::XConditionalFormat conditionalFormat, [in] com::sun::star::sheet::XSheetCellRanges range);
void removeByID( [in] long ID);
sequence< XConditionalFormat > getConditionalFormats();
long getLength();
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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/.
*/
#ifndef __com_sun_star_sheet_XDataBarEntry_idl__
#define __com_sun_star_sheet_XDataBarEntry_idl__
module com { module sun { module star { module sheet {
interface XDataBarEntry
{
string getFormula();
void setFormula(string Formula);
DataBarEntryType getType();
void setType(DataBarEntryType Type);
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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/.
*/
#ifndef __com_sun_star_sheet_XIconSetEntry_idl__
#define __com_sun_star_sheet_XIconSetEntry_idl__
#include <com/sun/star/sheet/IconSetEntryType.idl>
module com { module sun { module star { module sheet {
interface XIconSetEntry
{
string getFormula();
void setFormula(string Formula);
IconSetEntryType getType();
void setType(IconSetEntryType Type);
};
}; }; }; };
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment