Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
fc48c494
Kaydet (Commit)
fc48c494
authored
May 11, 2012
tarafından
Markus Mohrhard
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
import formulas for color scales from xlsx
Change-Id: If19c6486c95cab0106bf04a4ec68359f7a4ed220
üst
caa7f3f5
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
3 deletions
+15
-3
condformatbuffer.hxx
sc/source/filter/inc/condformatbuffer.hxx
+2
-1
condformatbuffer.cxx
sc/source/filter/oox/condformatbuffer.cxx
+13
-2
No files found.
sc/source/filter/inc/condformatbuffer.hxx
Dosyayı görüntüle @
fc48c494
...
@@ -84,6 +84,7 @@ struct ColorScaleRuleModelEntry
...
@@ -84,6 +84,7 @@ struct ColorScaleRuleModelEntry
bool
mbMin
;
bool
mbMin
;
bool
mbMax
;
bool
mbMax
;
bool
mbPercent
;
bool
mbPercent
;
rtl
::
OUString
maFormula
;
ColorScaleRuleModelEntry
()
:
ColorScaleRuleModelEntry
()
:
maColor
(),
maColor
(),
...
@@ -101,7 +102,7 @@ public:
...
@@ -101,7 +102,7 @@ public:
void
importCfvo
(
const
AttributeList
&
rAttribs
);
void
importCfvo
(
const
AttributeList
&
rAttribs
);
void
importColor
(
const
AttributeList
&
rAttribs
);
void
importColor
(
const
AttributeList
&
rAttribs
);
void
AddEntries
(
ScColorScaleFormat
*
pFormat
);
void
AddEntries
(
ScColorScaleFormat
*
pFormat
,
ScDocument
*
pDoc
,
const
ScAddress
&
rAddr
);
private
:
private
:
const
CondFormat
&
mrCondFormat
;
const
CondFormat
&
mrCondFormat
;
...
...
sc/source/filter/oox/condformatbuffer.cxx
Dosyayı görüntüle @
fc48c494
...
@@ -182,6 +182,11 @@ void ColorScaleRule::importCfvo( const AttributeList& rAttribs )
...
@@ -182,6 +182,11 @@ void ColorScaleRule::importCfvo( const AttributeList& rAttribs )
// between percent and percentile should be when calculating colors
// between percent and percentile should be when calculating colors
maColorScaleRuleEntries
[
mnCfvo
].
mbPercent
=
true
;
maColorScaleRuleEntries
[
mnCfvo
].
mbPercent
=
true
;
}
}
else
if
(
aType
==
"formula"
)
{
rtl
::
OUString
aFormula
=
rAttribs
.
getString
(
XML_val
,
rtl
::
OUString
()
);
maColorScaleRuleEntries
[
mnCfvo
].
maFormula
=
aFormula
;
}
++
mnCfvo
;
++
mnCfvo
;
}
}
...
@@ -212,7 +217,7 @@ void ColorScaleRule::importColor( const AttributeList& rAttribs )
...
@@ -212,7 +217,7 @@ void ColorScaleRule::importColor( const AttributeList& rAttribs )
++
mnCol
;
++
mnCol
;
}
}
void
ColorScaleRule
::
AddEntries
(
ScColorScaleFormat
*
pFormat
)
void
ColorScaleRule
::
AddEntries
(
ScColorScaleFormat
*
pFormat
,
ScDocument
*
pDoc
,
const
ScAddress
&
rAddr
)
{
{
//assume that both vectors contain the same entries
//assume that both vectors contain the same entries
// TODO: check it
// TODO: check it
...
@@ -228,6 +233,9 @@ void ColorScaleRule::AddEntries( ScColorScaleFormat* pFormat )
...
@@ -228,6 +233,9 @@ void ColorScaleRule::AddEntries( ScColorScaleFormat* pFormat )
if
(
rEntry
.
mbPercent
)
if
(
rEntry
.
mbPercent
)
pEntry
->
SetPercent
(
true
);
pEntry
->
SetPercent
(
true
);
if
(
!
rEntry
.
maFormula
.
isEmpty
())
pEntry
->
SetFormula
(
rEntry
.
maFormula
,
pDoc
,
rAddr
,
formula
::
FormulaGrammar
::
GRAM_ENGLISH_XL_A1
);
pFormat
->
AddEntry
(
pEntry
);
pFormat
->
AddEntry
(
pEntry
);
}
}
}
}
...
@@ -699,7 +707,6 @@ void CondFormatRule::finalizeImport( const Reference< XSheetConditionalEntries >
...
@@ -699,7 +707,6 @@ void CondFormatRule::finalizeImport( const Reference< XSheetConditionalEntries >
ScDocument
&
rDoc
=
getScDocument
();
ScDocument
&
rDoc
=
getScDocument
();
ScColorScaleFormat
*
pFormat
=
new
ScColorScaleFormat
(
&
rDoc
);
ScColorScaleFormat
*
pFormat
=
new
ScColorScaleFormat
(
&
rDoc
);
mpColor
->
AddEntries
(
pFormat
);
sal_Int32
nIndex
=
rDoc
.
AddColorScaleFormat
(
pFormat
);
sal_Int32
nIndex
=
rDoc
.
AddColorScaleFormat
(
pFormat
);
ScRangeList
aList
;
ScRangeList
aList
;
...
@@ -720,6 +727,10 @@ void CondFormatRule::finalizeImport( const Reference< XSheetConditionalEntries >
...
@@ -720,6 +727,10 @@ void CondFormatRule::finalizeImport( const Reference< XSheetConditionalEntries >
aList
.
Append
(
aRange
);
aList
.
Append
(
aRange
);
}
}
pFormat
->
SetRange
(
aList
);
pFormat
->
SetRange
(
aList
);
if
(
aList
.
size
())
mpColor
->
AddEntries
(
pFormat
,
&
rDoc
,
aList
.
front
()
->
aStart
);
else
mpColor
->
AddEntries
(
pFormat
,
&
rDoc
,
ScAddress
()
);
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment