summaryrefslogtreecommitdiff
path: root/include/vcl/regband.hxx
diff options
context:
space:
mode:
Diffstat (limited to 'include/vcl/regband.hxx')
-rw-r--r--include/vcl/regband.hxx23
1 files changed, 14 insertions, 9 deletions
diff --git a/include/vcl/regband.hxx b/include/vcl/regband.hxx
index 0b60a801d83e..24fe7584a7b7 100644
--- a/include/vcl/regband.hxx
+++ b/include/vcl/regband.hxx
@@ -49,7 +49,7 @@ struct ImplRegionBandSep
ImplRegionBandSep* mpNextSep;
long mnXLeft;
long mnXRight;
- sal_Bool mbRemoved;
+ bool mbRemoved;
};
enum LineType { LINE_ASCENDING, LINE_DESCENDING, LINE_HORIZONTAL };
@@ -60,7 +60,7 @@ struct ImplRegionBandPoint
ImplRegionBandPoint* mpNextBandPoint;
long mnX;
long mnLineId;
- sal_Bool mbEndPoint;
+ bool mbEndPoint;
LineType meLineType;
};
@@ -77,7 +77,9 @@ public:
ImplRegionBandPoint* mpFirstBandPoint; // root of the list with lines
long mnYTop; // actual boundary of the band
long mnYBottom;
- sal_Bool mbTouched;
+
+ // bitfield
+ bool mbTouched : 1;
// create y-band with boundaries
ImplRegionBand( long nYTop, long nYBottom );
@@ -102,14 +104,14 @@ public:
long GetXRightBoundary() const;
// combine overlapping bands
- sal_Bool OptimizeBand();
+ bool OptimizeBand();
// generate separations from lines and process
// union with existing separations
void ProcessPoints();
// insert point in the list for later processing
- sal_Bool InsertPoint( long nX, long nLineID,
- sal_Bool bEndPoint, LineType eLineType );
+ bool InsertPoint( long nX, long nLineID,
+ bool bEndPoint, LineType eLineType );
void Union( long nXLeft, long nXRight );
void Intersect( long nXLeft, long nXRight );
@@ -119,11 +121,14 @@ public:
void MoveX( long nHorzMove );
void ScaleX( double fHorzScale );
- sal_Bool IsInside( long nX );
+ bool IsInside( long nX );
+ bool IsInside( long nLeft, long nRight );
+ bool IsOver( long nLeft, long nRight );
+
- sal_Bool IsEmpty() const { return ((!mpFirstSep) && (!mpFirstBandPoint)); }
+ bool IsEmpty() const { return ((!mpFirstSep) && (!mpFirstBandPoint)); }
- sal_Bool operator==( const ImplRegionBand& rRegionBand ) const;
+ bool operator==( const ImplRegionBand& rRegionBand ) const;
/** Split the called band at the given vertical coordinate. After the
split the called band will cover the upper part not including nY.