LibreOffice Module sc (master) 1
xltracer.cxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 */
19
20#include <xltracer.hxx>
21#include <com/sun/star/beans/PropertyValue.hpp>
22#include <com/sun/star/uno/Sequence.hxx>
23#include <address.hxx>
24
25XclTracer::XclTracer(std::u16string_view /*rDocUrl*/)
26 : mbEnabled(false)
27 , maFirstTimes(eTraceLength, true)
28{
29}
30
32
34{
35 if (mbEnabled && maFirstTimes[eProblem])
36 {
37 maFirstTimes[eProblem] = false;
38 }
39}
40
41void XclTracer::TraceInvalidAddress(const ScAddress& rPos, const ScAddress& rMaxPos)
42{
43 TraceInvalidRow(rPos.Row(), rMaxPos.Row());
44 TraceInvalidTab(rPos.Tab(), rMaxPos.Tab());
45}
46
47void XclTracer::TraceInvalidRow(sal_uInt32 nRow, sal_uInt32 nMaxRow)
48{
49 if (nRow > nMaxRow)
51}
52
54{
55 if (nTab > nMaxTab)
57}
58
60
61void XclTracer::TraceDates(sal_uInt16 nNumFmt)
62{
63 // Short Date = 14 and Short Date+Time = 22
64 if (nNumFmt == 14 || nNumFmt == 22)
66}
67
68void XclTracer::TraceBorderLineStyle(bool bBorderLineStyle)
69{
70 if (bBorderLineStyle)
72}
73
74void XclTracer::TraceFillPattern(bool bFillPattern)
75{
76 if (bFillPattern)
78}
79
81{
82 // missing parameter in Formula record
84}
85
87{
88 if (bExternal)
90}
91
93{
94 // Pivot Charts not currently displayed.
96}
97
99
101
103{
104 // Data table is not supported.
106}
107
109{
110 // If position is set to "not docked or inside the plot area" then
111 // we cannot guarantee the legend position.
113}
114
116{
117 // Called from Excel 5.0 - limited Graphical object support.
119}
120
122
124{
125 // Custom types work if 'Data->validity dialog' is not OKed.
126 if (bType)
128}
129
130/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
SCTAB Tab() const
Definition: address.hxx:283
SCROW Row() const
Definition: address.hxx:274
void TracePrintRange()
Definition: xltracer.cxx:59
void TraceChartOnlySheet()
Definition: xltracer.cxx:100
void TraceFormulaMissingArg()
Definition: xltracer.cxx:80
void TraceChartLegendPosition()
Definition: xltracer.cxx:108
void TraceUnsupportedObjects()
Definition: xltracer.cxx:115
bool mbEnabled
Definition: xltracer.hxx:81
void TraceInvalidTab(SCTAB nTab, SCTAB nMaxTab)
Definition: xltracer.cxx:53
void TraceObjectNotPrintable()
Definition: xltracer.cxx:121
void TraceDVType(bool bType)
Definition: xltracer.cxx:123
void TraceChartDataTable()
Definition: xltracer.cxx:102
void TraceInvalidAddress(const ScAddress &rPos, const ScAddress &rMaxPos)
Definition: xltracer.cxx:41
void TraceFillPattern(bool bFillPattern)
Definition: xltracer.cxx:74
void TraceChartUnKnownType()
Definition: xltracer.cxx:98
void TracePivotDataSource(bool bExternal)
Definition: xltracer.cxx:86
void TracePivotChartExists()
Definition: xltracer.cxx:92
void TraceDates(sal_uInt16 nNumFmt)
Definition: xltracer.cxx:61
~XclTracer()
Definition: xltracer.cxx:31
XclTracer(std::u16string_view rDocUrl)
Definition: xltracer.cxx:25
void ProcessTraceOnce(XclTracerId eProblem)
Ensure that particular traces are logged once per document.
Definition: xltracer.cxx:33
void TraceBorderLineStyle(bool bBorderLineStyle)
Definition: xltracer.cxx:68
std::vector< bool > maFirstTimes
array of flags corresponding to each entry in the XclTracerDetails table.
Definition: xltracer.hxx:83
void TraceInvalidRow(sal_uInt32 nRow, sal_uInt32 nMaxrow)
Definition: xltracer.cxx:47
sal_Int16 SCTAB
Definition: types.hxx:22
XclTracerId
Definition: xltracer.hxx:28
@ eUnsupportedObject
Definition: xltracer.hxx:43
@ eChartDataTable
Definition: xltracer.hxx:41
@ eDVType
Definition: xltracer.hxx:45
@ eBorderLineStyle
Definition: xltracer.hxx:34
@ eChartUnKnownType
Definition: xltracer.hxx:39
@ eChartLegendPosition
Definition: xltracer.hxx:42
@ eTraceLength
this should always be the final entry
Definition: xltracer.hxx:46
@ eFormulaMissingArg
Definition: xltracer.hxx:36
@ eChartOnlySheet
Definition: xltracer.hxx:40
@ ePrintRange
Definition: xltracer.hxx:32
@ eRowLimitExceeded
unused but allows us to set the correct index
Definition: xltracer.hxx:30
@ eObjectNotPrintable
Definition: xltracer.hxx:44
@ ePivotDataSource
Definition: xltracer.hxx:37
@ eTabLimitExceeded
Definition: xltracer.hxx:31
@ eShortDate
Definition: xltracer.hxx:33
@ ePivotChartExists
Definition: xltracer.hxx:38
@ eFillPattern
Definition: xltracer.hxx:35