diff options
author | Vladimir Glazounov <vg@openoffice.org> | 2007-05-22 17:18:23 +0000 |
---|---|---|
committer | Vladimir Glazounov <vg@openoffice.org> | 2007-05-22 17:18:23 +0000 |
commit | 4e776dd6d2e48c9dfa3aa66a07a730009daa762d (patch) | |
tree | f93948486156530ede23391a21b009a4f323a8db /chart2/source/inc/LegendHelper.hxx | |
parent | b7a990af26fb5c6fedca5c69c52874497f973f4d (diff) |
INTEGRATION: CWS chart2mst3 (1.5.4); FILE MERGED
2006/10/16 15:38:32 bm 1.5.4.5: #i70287# +hasLegend (used by toolbar toggle legend command)
2005/12/21 21:29:14 iha 1.5.4.4: remove identifiers from model objects and create an index based CID protocol instead for selection purposes
2005/10/07 11:41:36 bm 1.5.4.3: RESYNC: (1.5-1.6); FILE MERGED
2005/06/16 12:52:49 iha 1.5.4.2: create legend on demand
2004/09/16 14:43:48 iha 1.5.4.1: implement api redesign
Diffstat (limited to 'chart2/source/inc/LegendHelper.hxx')
-rw-r--r-- | chart2/source/inc/LegendHelper.hxx | 42 |
1 files changed, 17 insertions, 25 deletions
diff --git a/chart2/source/inc/LegendHelper.hxx b/chart2/source/inc/LegendHelper.hxx index 7bba1a1bff8e..634eae92033c 100644 --- a/chart2/source/inc/LegendHelper.hxx +++ b/chart2/source/inc/LegendHelper.hxx @@ -4,9 +4,9 @@ * * $RCSfile: LegendHelper.hxx,v $ * - * $Revision: 1.6 $ + * $Revision: 1.7 $ * - * last change: $Author: rt $ $Date: 2005-09-08 00:41:51 $ + * last change: $Author: vg $ $Date: 2007-05-22 18:18:23 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -40,9 +40,6 @@ #include <rtl/ustring.hxx> #endif -#ifndef _COM_SUN_STAR_FRAME_XMODEL_HPP_ -#include <com/sun/star/frame/XModel.hpp> -#endif #ifndef _COM_SUN_STAR_CHART2_XLEGEND_HPP_ #include <com/sun/star/chart2/XLegend.hpp> #endif @@ -50,6 +47,13 @@ #include <com/sun/star/chart2/XDiagram.hpp> #endif +#ifndef _COM_SUN_STAR_FRAME_XMODEL_HPP_ +#include <com/sun/star/frame/XModel.hpp> +#endif +#ifndef _COM_SUN_STAR_UNO_XCOMPONENTCONTEXT_HPP_ +#include <com/sun/star/uno/XComponentContext.hpp> +#endif + //............................................................................. namespace chart { @@ -62,31 +66,19 @@ namespace chart class LegendHelper { public: - static rtl::OUString getIdentifierForLegend(); - static ::com::sun::star::uno::Reference< ::com::sun::star::chart2::XLegend > getLegend( const ::com::sun::star::uno::Reference< - ::com::sun::star::frame::XModel >& xModel ); - - /** fills the legend given with XChartTypeGroup elements as XLegendEntry - objects. - - Note: In, e.g., a standard bar chart the legend contains only one entry, - which is the chart type group. To display all series in the legend, you - have to get all XDataSeries in the tree starting at the chart type group - */ - static void defaultFillEmptyLegend( - const ::com::sun::star::uno::Reference< - ::com::sun::star::chart2::XLegend > & xLegend, - const ::com::sun::star::uno::Reference< - ::com::sun::star::chart2::XDiagram > & xDiagram ); + ::com::sun::star::frame::XModel >& xModel + , const ::com::sun::star::uno::Reference< + ::com::sun::star::uno::XComponentContext >& xContext = 0 + , bool bCreate = false ); - /** removes all legend entries + /** returns <FALSE/>, if either there is no legend at the diagram, or there + is a legend which has a "Show" property of value <FALSE/>. Otherwise, + <TRUE/> is returned. */ - static void flushLegend( - const ::com::sun::star::uno::Reference< - ::com::sun::star::chart2::XLegend > & xLegend ); + static bool hasLegend( const ::com::sun::star::uno::Reference< ::com::sun::star::chart2::XDiagram > & xDiagram ); }; //............................................................................. |