mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-10-21 15:55:02 +00:00
remove dead code
This commit is contained in:
1 parent
662050b89f
commit
94a44d7af4
1 file changed
-29
@@ -119,7 +119,6 @@ var CPSystemTypesetterFactory;
|
||||
float _lineWidth;
|
||||
|
||||
unsigned _indexOfCurrentContainer;
|
||||
CPArray _thisLineFragments;
|
||||
}
|
||||
|
||||
|
||||
@@ -175,7 +174,6 @@ var CPSystemTypesetterFactory;
|
||||
|
||||
[_layoutManager setTextContainer:_currentTextContainer forGlyphRange:lineRange]; // creates a new lineFragment
|
||||
[_layoutManager setLineFragmentRect:rect forGlyphRange:lineRange usedRect:rect];
|
||||
_thisLineFragments.push([_layoutManager._lineFragments lastObject]);
|
||||
|
||||
switch ([_currentParagraph alignment])
|
||||
{
|
||||
@@ -204,29 +202,6 @@ var CPSystemTypesetterFactory;
|
||||
return ([_layoutManager _rescuingInvalidFragmentsWasPossibleForGlyphRange:lineRange]);
|
||||
}
|
||||
|
||||
- (void)_fixupLineFragmentsOfCurrentLine
|
||||
{
|
||||
var rect,
|
||||
l = _thisLineFragments.length;
|
||||
|
||||
for (var i = 0; i < l; i++)
|
||||
{
|
||||
if (rect)
|
||||
rect = CGRectUnion(rect, _thisLineFragments[i]._usedRect);
|
||||
else
|
||||
rect = CGRectCreateCopy(_thisLineFragments[i]._usedRect);
|
||||
}
|
||||
|
||||
for (var i = 0; i < l; i++)
|
||||
{
|
||||
var diff = rect.size.height - _thisLineFragments[i]._usedRect.size.height;
|
||||
// _thisLineFragments[i]._fragmentRect.origin.y += diff;
|
||||
// _thisLineFragments[i]._fragmentRect.size.height = rect.size.height;
|
||||
}
|
||||
|
||||
_thisLineFragments = [];
|
||||
}
|
||||
|
||||
- (void)layoutGlyphsInLayoutManager:(CPLayoutManager)layoutManager
|
||||
startingAtGlyphIndex:(unsigned)glyphIndex
|
||||
maxNumberOfLineFragments:(unsigned)maxNumLines
|
||||
@@ -275,8 +250,6 @@ var CPSystemTypesetterFactory;
|
||||
if (![_textStorage length])
|
||||
return;
|
||||
|
||||
_thisLineFragments = [];
|
||||
|
||||
for (; numLines != maxNumLines && glyphIndex < numberOfGlyphs; glyphIndex++)
|
||||
{
|
||||
if (!CPLocationInRange(glyphIndex, _attributesRange))
|
||||
@@ -384,7 +357,6 @@ var CPSystemTypesetterFactory;
|
||||
lineOrigin.x = 0;
|
||||
numLines++;
|
||||
isNewline = NO;
|
||||
[self _fixupLineFragmentsOfCurrentLine];
|
||||
}
|
||||
|
||||
_lineWidth = 0;
|
||||
@@ -405,7 +377,6 @@ var CPSystemTypesetterFactory;
|
||||
if (lineRange.length)
|
||||
{
|
||||
[self _flushRange:lineRange lineOrigin:lineOrigin currentContainer:_currentTextContainer advancements:advancements lineCount:numLines];
|
||||
[self _fixupLineFragmentsOfCurrentLine]
|
||||
}
|
||||
|
||||
if (_isNewlineCharacter(theString.charAt(theString.length - 1)))
|
||||
|
||||
Reference in new issue
Block a user