Commit 91c62fc6 authored by Alexander.Trofimov's avatar Alexander.Trofimov Committed by Alexander.Trofimov

Убрал код из ревизии 49640 (только визуально отображали, что есть wrap при justify)

Поправил проблему с wrap при justify (http://bugzserver/show_bug.cgi?id=14484)

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@49695 954022d7-b5bf-4e40-9824-e11837661b57
parent a3cb79f4
......@@ -3893,7 +3893,7 @@ function Cell(worksheet){
this.formulaParsed = null;
this.merged = null;
this.hyperlinks = new Array();
};
}
Cell.prototype.getStyle=function(){
if(this.bNeedCompileXfs)
{
......@@ -3901,7 +3901,7 @@ Cell.prototype.getStyle=function(){
this.compileXfs();
}
return this.compiledXfs;
}
};
Cell.prototype.compileXfs=function(){
this.compiledXfs = null;
if(null != this.xfs || null != this.tableXfs || null != this.conditionalFormattingXfs)
......@@ -3923,7 +3923,7 @@ Cell.prototype.compileXfs=function(){
this.compiledXfs = this.xfs;
}
}
}
};
Cell.prototype.clone=function(){
var oNewCell = new Cell(this.ws);
oNewCell.oId = new CellAddress(this.oId.getRow(), this.oId.getCol());
......@@ -6517,32 +6517,32 @@ Range.prototype.getShrinkToFit=function(){
}
return g_oDefaultAlign.shrink;
};
Range.prototype.getWrapByAlign = function (align) {
// Для justify wrap всегда true
return "justify" === align.hor ? true : align.wrap;
};
Range.prototype.getWrap=function(){
var nRow = this.bbox.r1;
var nCol = this.bbox.c1;
var cell = this.worksheet._getCellNoEmpty(nRow, nCol);
if(null != cell)
{
if(null != cell) {
var xfs = cell.getStyle();
if(null != xfs)
{
if(null != xfs) {
if(null != xfs.align)
return xfs.align.wrap;
return this.getWrapByAlign(xfs.align);
else
return g_oDefaultAlignAbs.wrap;
return this.getWrapByAlign(g_oDefaultAlignAbs);
}
}
else
{
} else {
//стили столбов и колонок
var row = this.worksheet._getRowNoEmpty(nRow);
if(null != row && null != row.xfs && null != row.xfs.align)
return row.xfs.align.wrap;
return this.getWrapByAlign(row.xfs.align);
var col = this.worksheet._getColNoEmptyWithAll(nCol);
if(null != col && null != col.xfs && null != col.xfs.align)
return col.xfs.align.wrap;
return this.getWrapByAlign(col.xfs.align);
}
return g_oDefaultAlign.wrap;
return this.getWrapByAlign(g_oDefaultAlign);
};
Range.prototype.getAngle=function(){
//угол от -90 до 90 против часовой стрелки от оси OX
......
......@@ -5739,7 +5739,7 @@
cell_info.flags = new asc_CCellFlag();
cell_info.flags.merge = !!this._getMergedCellsRange(c1, r1);
cell_info.flags.shrinkToFit = c.getShrinkToFit();
cell_info.flags.wrapText = (khaJustify === cell_info.halign) ? true : c.getWrap(); // Для khaJustify - всегда true
cell_info.flags.wrapText = c.getWrap();
var graphicObjects = this.objectRender.getSelectedGraphicObjects();
if ( graphicObjects.length == 1 )
......
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