20#ifndef INCLUDED_VCL_REGION_HXX
21#define INCLUDED_VCL_REGION_HXX
43 friend class ::OutputDevice;
44 friend class ::vcl::Window;
45 friend class ::Bitmap;
48 std::optional< basegfx::B2DPolyPolygon >
50 std::optional< tools::PolyPolygon >
52 std::shared_ptr< RegionBand >
66 explicit Region(
bool bIsNull =
false);
76 const std::optional<basegfx::B2DPolyPolygon>&
getB2DPolyPolygon()
const {
return mpB2DPolyPolygon; }
77 const std::optional<tools::PolyPolygon>&
getPolyPolygon()
const {
return mpPolyPolygon; }
88 void Scale(
double fScaleX,
double fScaleY );
99 bool IsNull()
const {
return mbIsNull;}
104 bool IsRectangle()
const;
110 bool Contains(
const Point& rPoint )
const;
135template<
typename charT,
typename traits >
136inline std::basic_ostream<charT, traits> &
operator <<(
137 std::basic_ostream<charT, traits> & stream,
const Region& rRegion)
139 if (rRegion.IsEmpty())
141 if (rRegion.getB2DPolyPolygon())
142 return stream <<
"B2DPolyPolygon("
143 << *rRegion.getB2DPolyPolygon()
145 if (rRegion.getPolyPolygon())
146 return stream <<
"PolyPolygon("
147 << *rRegion.getPolyPolygon()
149 if (rRegion.getRegionBand())
153 rRegion.GetRegionRectangles(rects);
156 for (
size_t i = 0;
i < rects.size(); ++
i)
157 stream <<
"[" << i <<
"] " << rects[i];
Some things multiple-inherit from VclAbstractDialog and OutputDevice, so we need to use virtual inher...
const RegionBand * getRegionBand() const
std::optional< tools::PolyPolygon > mpPolyPolygon
bool operator==(const vcl::Region &rRegion) const
const std::optional< basegfx::B2DPolyPolygon > & getB2DPolyPolygon() const
Region(const vcl::Region &rRegion)
bool operator!=(const vcl::Region &rRegion) const
bool HasPolyPolygonOrB2DPolyPolygon() const
std::optional< basegfx::B2DPolyPolygon > mpB2DPolyPolygon
const std::optional< tools::PolyPolygon > & getPolyPolygon() const
vcl::Region & operator=(const vcl::Region &rRegion)
std::shared_ptr< RegionBand > mpRegionBand
Reference< XOutputStream > stream
std::basic_ostream< charT, traits > & operator<<(std::basic_ostream< charT, traits > &stream, const Region &rRegion)
SvStream & ReadRegion(SvStream &rIStrm, vcl::Region &rRegion)
SvStream & WriteRegion(SvStream &rOStrm, const vcl::Region &rRegion)
std::vector< tools::Rectangle > RectangleVector
bool operator==(const ItalicMatrix &a, const ItalicMatrix &b)