Commit a8c1ce70 authored by Alexander.Trofimov's avatar Alexander.Trofimov Committed by Alexander Trofimov

(1.0.0.101) - XlsxSerializerCom.dll

Для ячеек вместо Ref (строка с буквой столбца и номером строки, например "A1") пишем два числа: номер строки + номер столбца (парсинг на C++, вместо JavaScript). Тем самым ускорил открытие файла.

git-svn-id: svn://fileserver/activex/AVS/Sources/TeamlabOffice/trunk/ServerComponents@53945 954022d7-b5bf-4e40-9824-e11837661b57
parent c3cb7fd1
......@@ -236,7 +236,8 @@ namespace BinXlsxRW
Style = 1,
Type = 2,
Value = 3,
Formula = 4
Formula = 4,
RefRowCol = 5
};}
namespace c_oSerFormulaTypes{enum c_oSerFormulaTypes
{
......
......@@ -2710,10 +2710,20 @@ namespace BinXlsxRW {
//Ref
if(oCell.m_oRef.IsInit())
{
m_oBcw.m_oStream.WriteByte(c_oSerCellTypes::Ref);
m_oBcw.m_oStream.WriteString2(oCell.m_oRef.get2());
int nRow = 0;
int nCol = 0;
OOX::Spreadsheet::CWorksheet::parseRef(oCell.m_oRef.get2(), nRow, nCol);
// , 2 ( JavaScript, .. C++ ). .
nCurPos = m_oBcw.WriteItemStart(c_oSerCellTypes::RefRowCol);
m_oBcw.m_oStream.WriteLong(nRow);
m_oBcw.m_oStream.WriteLong(nCol);
m_oBcw.WriteItemEnd(nCurPos);
//m_oBcw.m_oStream.WriteByte(c_oSerCellTypes::Ref);
//m_oBcw.m_oStream.WriteString2(oCell.m_oRef.get2());
}
//Ref
//Style
if(oCell.m_oStyle.IsInit())
{
nCurPos = m_oBcw.WriteItemStart(c_oSerCellTypes::Style);
......
......@@ -3306,6 +3306,13 @@ namespace BinXlsxRW {
pCell->m_oRef.Init();
pCell->m_oRef->Append(sRef);
}
else if(c_oSerCellTypes::RefRowCol == type)
{
int nRow = m_oBufferedStream.ReadLong();
int nCol = m_oBufferedStream.ReadLong();
pCell->m_oRef.Init();
pCell->m_oRef = OOX::Spreadsheet::CWorksheet::combineRef(nRow, nCol);
}
else if(c_oSerCellTypes::Style == type)
{
pCell->m_oStyle.Init();
......
......@@ -2,6 +2,6 @@
//1
//0
//0
//100
#define INTVER 1,0,0,100
#define STRVER "1,0,0,100\0"
//101
#define INTVER 1,0,0,101
#define STRVER "1,0,0,101\0"
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