Kaydet (Commit) 41df7db9 authored tarafından Tomaž Vajngerl's avatar Tomaž Vajngerl

refactor sw Sidebar classes to use RenderContext

Change-Id: I09a4abd8fb34470c4c365aa1f604accd80631ab3
üst 7587cf88
...@@ -182,7 +182,7 @@ class SwSidebarWin : public vcl::Window ...@@ -182,7 +182,7 @@ class SwSidebarWin : public vcl::Window
protected: protected:
virtual void DataChanged( const DataChangedEvent& aEvent) SAL_OVERRIDE; virtual void DataChanged( const DataChangedEvent& aEvent) SAL_OVERRIDE;
virtual void LoseFocus() SAL_OVERRIDE; virtual void LoseFocus() SAL_OVERRIDE;
virtual void Paint( vcl::RenderContext& rRenderContext, const Rectangle& rRect) SAL_OVERRIDE; virtual void Paint(vcl::RenderContext& rRenderContext, const Rectangle& rRect) SAL_OVERRIDE;
virtual void GetFocus() SAL_OVERRIDE; virtual void GetFocus() SAL_OVERRIDE;
virtual VclPtr<MenuButton> CreateMenuButton() = 0; virtual VclPtr<MenuButton> CreateMenuButton() = 0;
......
...@@ -29,31 +29,30 @@ SwDashedLine::~SwDashedLine( ) ...@@ -29,31 +29,30 @@ SwDashedLine::~SwDashedLine( )
{ {
} }
void SwDashedLine::Paint( vcl::RenderContext& /*rRenderContext*/, const Rectangle& ) void SwDashedLine::Paint(vcl::RenderContext& rRenderContext, const Rectangle&)
{ {
const drawinglayer::geometry::ViewInformation2D aNewViewInfos; const drawinglayer::geometry::ViewInformation2D aNewViewInfos;
boost::scoped_ptr<drawinglayer::processor2d::BaseProcessor2D> pProcessor( boost::scoped_ptr<drawinglayer::processor2d::BaseProcessor2D> pProcessor(
drawinglayer::processor2d::createBaseProcessor2DFromOutputDevice( drawinglayer::processor2d::createBaseProcessor2DFromOutputDevice(rRenderContext, aNewViewInfos));
*this, aNewViewInfos ));
// Compute the start and end points // Compute the start and end points
const Rectangle aRect( Rectangle( Point( 0, 0 ), PixelToLogic( GetSizePixel() ) ) ); const Rectangle aRect(Rectangle(Point(0, 0), rRenderContext.PixelToLogic(GetSizePixel())));
double nHalfWidth = double( aRect.Top() + aRect.Bottom() ) / 2.0; double nHalfWidth = double(aRect.Top() + aRect.Bottom()) / 2.0;
basegfx::B2DPoint aStart( double( aRect.Left() ), nHalfWidth ); basegfx::B2DPoint aStart(double(aRect.Left()), nHalfWidth);
basegfx::B2DPoint aEnd( double( aRect.Right() ), nHalfWidth ); basegfx::B2DPoint aEnd(double(aRect.Right()), nHalfWidth);
basegfx::B2DPolygon aPolygon; basegfx::B2DPolygon aPolygon;
aPolygon.append( aStart ); aPolygon.append(aStart);
aPolygon.append( aEnd ); aPolygon.append(aEnd);
drawinglayer::primitive2d::Primitive2DSequence aSeq( 1 ); drawinglayer::primitive2d::Primitive2DSequence aSeq(1);
const StyleSettings& rSettings = Application::GetSettings().GetStyleSettings(); const StyleSettings& rSettings = Application::GetSettings().GetStyleSettings();
std::vector< double > aStrokePattern; std::vector<double> aStrokePattern;
basegfx::BColor aColor = m_pColorFn().getBColor(); basegfx::BColor aColor = m_pColorFn().getBColor();
if ( rSettings.GetHighContrastMode( ) ) if (rSettings.GetHighContrastMode())
{ {
// Only a solid line in high contrast mode // Only a solid line in high contrast mode
aColor = rSettings.GetDialogTextColor().getBColor(); aColor = rSettings.GetDialogTextColor().getBColor();
...@@ -61,37 +60,36 @@ void SwDashedLine::Paint( vcl::RenderContext& /*rRenderContext*/, const Rectangl ...@@ -61,37 +60,36 @@ void SwDashedLine::Paint( vcl::RenderContext& /*rRenderContext*/, const Rectangl
else else
{ {
// Get a color for the contrast // Get a color for the contrast
basegfx::BColor aHslLine = basegfx::tools::rgb2hsl( aColor ); basegfx::BColor aHslLine = basegfx::tools::rgb2hsl(aColor);
double nLuminance = aHslLine.getZ(); double nLuminance = aHslLine.getZ();
nLuminance += ( 1.0 - nLuminance ) * 0.75; nLuminance += (1.0 - nLuminance) * 0.75;
if ( aHslLine.getZ() > 0.7 ) if (aHslLine.getZ() > 0.7)
nLuminance = aHslLine.getZ() * 0.7; nLuminance = aHslLine.getZ() * 0.7;
aHslLine.setZ( nLuminance ); aHslLine.setZ(nLuminance);
const basegfx::BColor aOtherColor = basegfx::tools::hsl2rgb( aHslLine ); const basegfx::BColor aOtherColor = basegfx::tools::hsl2rgb(aHslLine);
// Compute the plain line // Compute the plain line
drawinglayer::primitive2d::PolygonHairlinePrimitive2D * pPlainLine = drawinglayer::primitive2d::PolygonHairlinePrimitive2D * pPlainLine =
new drawinglayer::primitive2d::PolygonHairlinePrimitive2D( new drawinglayer::primitive2d::PolygonHairlinePrimitive2D(aPolygon, aOtherColor);
aPolygon, aOtherColor );
aSeq[0] = drawinglayer::primitive2d::Primitive2DReference( pPlainLine ); aSeq[0] = drawinglayer::primitive2d::Primitive2DReference(pPlainLine);
// Dashed line in twips // Dashed line in twips
aStrokePattern.push_back( 3 ); aStrokePattern.push_back(3);
aStrokePattern.push_back( 3 ); aStrokePattern.push_back(3);
aSeq.realloc( 2 ); aSeq.realloc(2);
} }
// Compute the dashed line primitive // Compute the dashed line primitive
drawinglayer::primitive2d::PolyPolygonStrokePrimitive2D * pLine = drawinglayer::primitive2d::PolyPolygonStrokePrimitive2D * pLine =
new drawinglayer::primitive2d::PolyPolygonStrokePrimitive2D ( new drawinglayer::primitive2d::PolyPolygonStrokePrimitive2D(
basegfx::B2DPolyPolygon( aPolygon ), basegfx::B2DPolyPolygon(aPolygon),
drawinglayer::attribute::LineAttribute( m_pColorFn().getBColor() ), drawinglayer::attribute::LineAttribute(m_pColorFn().getBColor()),
drawinglayer::attribute::StrokeAttribute( aStrokePattern ) ); drawinglayer::attribute::StrokeAttribute(aStrokePattern));
aSeq[ aSeq.getLength() - 1 ] = drawinglayer::primitive2d::Primitive2DReference( pLine ); aSeq[aSeq.getLength() - 1] = drawinglayer::primitive2d::Primitive2DReference(pLine);
pProcessor->process( aSeq ); pProcessor->process(aSeq);
} }
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
...@@ -135,86 +135,86 @@ void SwPageBreakWin::dispose() ...@@ -135,86 +135,86 @@ void SwPageBreakWin::dispose()
MenuButton::dispose(); MenuButton::dispose();
} }
void SwPageBreakWin::Paint( vcl::RenderContext& /*rRenderContext*/, const Rectangle& ) void SwPageBreakWin::Paint(vcl::RenderContext& rRenderContext, const Rectangle&)
{ {
const Rectangle aRect( Rectangle( Point( 0, 0 ), PixelToLogic( GetSizePixel() ) ) ); const Rectangle aRect(Rectangle(Point(0, 0), rRenderContext.PixelToLogic(GetSizePixel())));
// Properly paint the control // Properly paint the control
BColor aColor = SwViewOption::GetPageBreakColor().getBColor(); BColor aColor = SwViewOption::GetPageBreakColor().getBColor();
BColor aHslLine = rgb2hsl( aColor ); BColor aHslLine = rgb2hsl(aColor);
double nLuminance = aHslLine.getZ(); double nLuminance = aHslLine.getZ();
nLuminance += ( 1.0 - nLuminance ) * 0.75; nLuminance += (1.0 - nLuminance) * 0.75;
if ( aHslLine.getZ() > 0.7 ) if ( aHslLine.getZ() > 0.7 )
nLuminance = aHslLine.getZ() * 0.7; nLuminance = aHslLine.getZ() * 0.7;
aHslLine.setZ( nLuminance ); aHslLine.setZ(nLuminance);
BColor aOtherColor = hsl2rgb( aHslLine ); BColor aOtherColor = hsl2rgb(aHslLine);
const StyleSettings& rSettings = Application::GetSettings().GetStyleSettings(); const StyleSettings& rSettings = Application::GetSettings().GetStyleSettings();
if ( rSettings.GetHighContrastMode( ) ) if (rSettings.GetHighContrastMode())
{ {
aColor = rSettings.GetDialogTextColor().getBColor(); aColor = rSettings.GetDialogTextColor().getBColor();
aOtherColor = rSettings.GetDialogColor( ).getBColor(); aOtherColor = rSettings.GetDialogColor().getBColor();
} }
bool bRtl = AllSettings::GetLayoutRTL(); bool bRtl = AllSettings::GetLayoutRTL();
drawinglayer::primitive2d::Primitive2DSequence aSeq( 3 ); drawinglayer::primitive2d::Primitive2DSequence aSeq(3);
B2DRectangle aBRect( double( aRect.Left() ), double( aRect.Top( ) ), B2DRectangle aBRect(double(aRect.Left()), double(aRect.Top()),
double( aRect.Right() ), double( aRect.Bottom( ) ) ); double(aRect.Right()), double(aRect.Bottom()));
B2DPolygon aPolygon = createPolygonFromRect( aBRect, 3.0 / BUTTON_WIDTH, 3.0 / BUTTON_HEIGHT ); B2DPolygon aPolygon = createPolygonFromRect(aBRect, 3.0 / BUTTON_WIDTH, 3.0 / BUTTON_HEIGHT);
// Create the polygon primitives // Create the polygon primitives
aSeq[0] = Primitive2DReference( new drawinglayer::primitive2d::PolyPolygonColorPrimitive2D( aSeq[0] = Primitive2DReference(new drawinglayer::primitive2d::PolyPolygonColorPrimitive2D(
B2DPolyPolygon( aPolygon ), aOtherColor ) ); B2DPolyPolygon(aPolygon), aOtherColor));
aSeq[1] = Primitive2DReference( new drawinglayer::primitive2d::PolygonHairlinePrimitive2D( aSeq[1] = Primitive2DReference(new drawinglayer::primitive2d::PolygonHairlinePrimitive2D(
aPolygon, aColor ) ); aPolygon, aColor));
// Create the primitive for the image // Create the primitive for the image
Image aImg( SW_RES( IMG_PAGE_BREAK ) ); Image aImg(SW_RES(IMG_PAGE_BREAK));
double nImgOfstX = 3.0; double nImgOfstX = 3.0;
if ( bRtl ) if (bRtl)
nImgOfstX = aRect.Right() - aImg.GetSizePixel().Width() - 3.0; nImgOfstX = aRect.Right() - aImg.GetSizePixel().Width() - 3.0;
aSeq[2] = Primitive2DReference( new drawinglayer::primitive2d::DiscreteBitmapPrimitive2D( aSeq[2] = Primitive2DReference(new drawinglayer::primitive2d::DiscreteBitmapPrimitive2D(
aImg.GetBitmapEx(), B2DPoint( nImgOfstX, 1.0 ) ) ); aImg.GetBitmapEx(), B2DPoint(nImgOfstX, 1.0)));
double nTop = double( aRect.getHeight() ) / 2.0; double nTop = double(aRect.getHeight()) / 2.0;
double nBottom = nTop + 4.0; double nBottom = nTop + 4.0;
double nLeft = aRect.getWidth( ) - ARROW_WIDTH - 6.0; double nLeft = aRect.getWidth() - ARROW_WIDTH - 6.0;
if ( bRtl ) if (bRtl)
nLeft = ARROW_WIDTH - 2.0; nLeft = ARROW_WIDTH - 2.0;
double nRight = nLeft + 8.0; double nRight = nLeft + 8.0;
B2DPolygon aTriangle; B2DPolygon aTriangle;
aTriangle.append( B2DPoint( nLeft, nTop ) ); aTriangle.append(B2DPoint(nLeft, nTop));
aTriangle.append( B2DPoint( nRight, nTop ) ); aTriangle.append(B2DPoint(nRight, nTop));
aTriangle.append( B2DPoint( ( nLeft + nRight ) / 2.0, nBottom ) ); aTriangle.append(B2DPoint((nLeft + nRight) / 2.0, nBottom));
aTriangle.setClosed( true ); aTriangle.setClosed(true);
BColor aTriangleColor = Color( COL_BLACK ).getBColor( ); BColor aTriangleColor = Color(COL_BLACK).getBColor();
if ( Application::GetSettings().GetStyleSettings().GetHighContrastMode() ) if (Application::GetSettings().GetStyleSettings().GetHighContrastMode())
aTriangleColor = Color( COL_WHITE ).getBColor( ); aTriangleColor = Color(COL_WHITE).getBColor();
aSeq.realloc( aSeq.getLength() + 1 ); aSeq.realloc(aSeq.getLength() + 1);
aSeq[ aSeq.getLength() - 1 ] = Primitive2DReference( new drawinglayer::primitive2d::PolyPolygonColorPrimitive2D( aSeq[aSeq.getLength() - 1] = Primitive2DReference(
B2DPolyPolygon( aTriangle ), aTriangleColor ) ); new drawinglayer::primitive2d::PolyPolygonColorPrimitive2D(
B2DPolyPolygon(aTriangle), aTriangleColor));
Primitive2DSequence aGhostedSeq( 1 );
double nFadeRate = double( m_nFadeRate ) / 100.0; Primitive2DSequence aGhostedSeq(1);
double nFadeRate = double(m_nFadeRate) / 100.0;
const basegfx::BColorModifierSharedPtr aBColorModifier( const basegfx::BColorModifierSharedPtr aBColorModifier(
new basegfx::BColorModifier_interpolate( new basegfx::BColorModifier_interpolate(Color(COL_WHITE).getBColor(),
Color( COL_WHITE ).getBColor(), 1.0 - nFadeRate));
1.0 - nFadeRate)); aGhostedSeq[0] = Primitive2DReference(
aGhostedSeq[0] = Primitive2DReference( new drawinglayer::primitive2d::ModifiedColorPrimitive2D( new drawinglayer::primitive2d::ModifiedColorPrimitive2D(
aSeq, aBColorModifier ) ); aSeq, aBColorModifier));
// Create the processor and process the primitives // Create the processor and process the primitives
const drawinglayer::geometry::ViewInformation2D aNewViewInfos; const drawinglayer::geometry::ViewInformation2D aNewViewInfos;
boost::scoped_ptr<drawinglayer::processor2d::BaseProcessor2D> pProcessor( boost::scoped_ptr<drawinglayer::processor2d::BaseProcessor2D> pProcessor(
drawinglayer::processor2d::createBaseProcessor2DFromOutputDevice( drawinglayer::processor2d::createBaseProcessor2DFromOutputDevice(rRenderContext, aNewViewInfos));
*this, aNewViewInfos ));
pProcessor->process( aGhostedSeq ); pProcessor->process(aGhostedSeq);
} }
void SwPageBreakWin::Select( ) void SwPageBreakWin::Select( )
...@@ -466,7 +466,7 @@ IMPL_LINK_NOARG_TYPED(SwPageBreakWin, FadeHandler, Timer *, void) ...@@ -466,7 +466,7 @@ IMPL_LINK_NOARG_TYPED(SwPageBreakWin, FadeHandler, Timer *, void)
Invalidate(); Invalidate();
} }
if ( IsVisible( ) && m_nFadeRate > 0 && m_nFadeRate < 100 ) if (IsVisible( ) && m_nFadeRate > 0 && m_nFadeRate < 100)
m_aFadeTimer.Start(); m_aFadeTimer.Start();
} }
......
...@@ -151,43 +151,37 @@ void SidebarTxtControl::Draw(OutputDevice* pDev, const Point& rPt, const Size& r ...@@ -151,43 +151,37 @@ void SidebarTxtControl::Draw(OutputDevice* pDev, const Point& rPt, const Size& r
} }
} }
void SidebarTxtControl::Paint( vcl::RenderContext& /*rRenderContext*/, const Rectangle& rRect) void SidebarTxtControl::Paint(vcl::RenderContext& rRenderContext, const Rectangle& rRect)
{ {
if ( !Application::GetSettings().GetStyleSettings().GetHighContrastMode() ) if (!rRenderContext.GetSettings().GetStyleSettings().GetHighContrastMode())
{ {
if ( mrSidebarWin.IsMouseOverSidebarWin() || if (mrSidebarWin.IsMouseOverSidebarWin() || HasFocus())
HasFocus() )
{ {
DrawGradient( Rectangle( Point(0,0), PixelToLogic(GetSizePixel()) ), rRenderContext.DrawGradient(Rectangle(Point(0,0), rRenderContext.PixelToLogic(GetSizePixel())),
Gradient( GradientStyle_LINEAR, Gradient(GradientStyle_LINEAR, mrSidebarWin.ColorDark(), mrSidebarWin.ColorDark()));
mrSidebarWin.ColorDark(),
mrSidebarWin.ColorDark() ) );
} }
else else
{ {
DrawGradient( Rectangle( Point(0,0), PixelToLogic(GetSizePixel()) ), rRenderContext.DrawGradient(Rectangle(Point(0,0), rRenderContext.PixelToLogic(GetSizePixel())),
Gradient( GradientStyle_LINEAR, Gradient(GradientStyle_LINEAR, mrSidebarWin.ColorLight(), mrSidebarWin.ColorDark()));
mrSidebarWin.ColorLight(),
mrSidebarWin.ColorDark()));
} }
} }
if ( GetTextView() ) if (GetTextView())
{ {
GetTextView()->Paint( rRect ); GetTextView()->Paint(rRect, &rRenderContext);
} }
if ( mrSidebarWin.GetLayoutStatus()==SwPostItHelper::DELETED ) if (mrSidebarWin.GetLayoutStatus() == SwPostItHelper::DELETED)
{ {
SetLineColor(mrSidebarWin.GetChangeColor()); rRenderContext.SetLineColor(mrSidebarWin.GetChangeColor());
DrawLine( PixelToLogic( GetPosPixel() ), rRenderContext.DrawLine(rRenderContext.PixelToLogic(GetPosPixel()),
PixelToLogic( GetPosPixel() + rRenderContext.PixelToLogic(GetPosPixel() + Point(GetSizePixel().Width(),
Point( GetSizePixel().Width(), GetSizePixel().Height())));
GetSizePixel().Height() ) ) ); rRenderContext.DrawLine(rRenderContext.PixelToLogic(GetPosPixel() + Point(GetSizePixel().Width(),
DrawLine( PixelToLogic( GetPosPixel() + 0)),
Point( GetSizePixel().Width(),0) ), rRenderContext.PixelToLogic(GetPosPixel() + Point(0,
PixelToLogic( GetPosPixel() + GetSizePixel().Height())));
Point( 0, GetSizePixel().Height() ) ) );
} }
} }
......
...@@ -89,14 +89,14 @@ namespace sw { namespace sidebarwindows { ...@@ -89,14 +89,14 @@ namespace sw { namespace sidebarwindows {
#define POSTIT_META_HEIGHT (sal_Int32) 30 #define POSTIT_META_HEIGHT (sal_Int32) 30
#define POSTIT_MINIMUMSIZE_WITHOUT_META 50 #define POSTIT_MINIMUMSIZE_WITHOUT_META 50
SwSidebarWin::SwSidebarWin( SwEditWin& rEditWin, SwSidebarWin::SwSidebarWin(SwEditWin& rEditWin,
WinBits nBits, WinBits nBits,
SwPostItMgr& aMgr, SwPostItMgr& aMgr,
SwPostItBits aBits, SwPostItBits aBits,
SwSidebarItem& rSidebarItem ) SwSidebarItem& rSidebarItem)
: Window(&rEditWin, nBits) : Window(&rEditWin, nBits)
, mrMgr(aMgr) , mrMgr(aMgr)
, mrView( rEditWin.GetView() ) , mrView(rEditWin.GetView())
, nFlags(aBits) , nFlags(aBits)
, mnEventId(0) , mnEventId(0)
, mpOutlinerView(0) , mpOutlinerView(0)
...@@ -106,23 +106,23 @@ SwSidebarWin::SwSidebarWin( SwEditWin& rEditWin, ...@@ -106,23 +106,23 @@ SwSidebarWin::SwSidebarWin( SwEditWin& rEditWin,
, mpMetadataAuthor(0) , mpMetadataAuthor(0)
, mpMetadataDate(0) , mpMetadataDate(0)
, mpMenuButton(0) , mpMenuButton(0)
, mpAnchor( NULL ) , mpAnchor(NULL)
, mpShadow( NULL ) , mpShadow(NULL)
, mpTextRangeOverlay( NULL ) , mpTextRangeOverlay(NULL)
, mColorAnchor() , mColorAnchor()
, mColorDark() , mColorDark()
, mColorLight() , mColorLight()
, mChangeColor() , mChangeColor()
, meSidebarPosition( sw::sidebarwindows::SidebarPosition::NONE ) , meSidebarPosition(sw::sidebarwindows::SidebarPosition::NONE)
, mPosSize() , mPosSize()
, mAnchorRect() , mAnchorRect()
, mPageBorder( 0 ) , mPageBorder(0)
, mbMouseOver( false ) , mbMouseOver(false)
, mLayoutStatus( SwPostItHelper::INVISIBLE ) , mLayoutStatus(SwPostItHelper::INVISIBLE)
, mbReadonly( false ) , mbReadonly(false)
, mbIsFollow( false ) , mbIsFollow(false)
, mrSidebarItem( rSidebarItem ) , mrSidebarItem(rSidebarItem)
, mpAnchorFrm( rSidebarItem.maLayoutInfo.mpAnchorFrm ) , mpAnchorFrm(rSidebarItem.maLayoutInfo.mpAnchorFrm)
{ {
mpShadow = ShadowOverlayObject::CreateShadowOverlayObject( mrView ); mpShadow = ShadowOverlayObject::CreateShadowOverlayObject( mrView );
if ( mpShadow ) if ( mpShadow )
...@@ -208,29 +208,29 @@ void SwSidebarWin::dispose() ...@@ -208,29 +208,29 @@ void SwSidebarWin::dispose()
vcl::Window::dispose(); vcl::Window::dispose();
} }
void SwSidebarWin::Paint( vcl::RenderContext& rRenderContext, const Rectangle& rRect) void SwSidebarWin::Paint(vcl::RenderContext& rRenderContext, const Rectangle& rRect)
{ {
Window::Paint(rRenderContext, rRect); Window::Paint(rRenderContext, rRect);
if (mpMetadataAuthor->IsVisible() ) if (mpMetadataAuthor->IsVisible())
{ {
//draw left over space //draw left over space
if ( Application::GetSettings().GetStyleSettings().GetHighContrastMode() ) if (Application::GetSettings().GetStyleSettings().GetHighContrastMode())
{ {
SetFillColor(COL_BLACK); rRenderContext.SetFillColor(COL_BLACK);
} }
else else
{ {
SetFillColor(mColorDark); rRenderContext.SetFillColor(mColorDark);
} }
SetLineColor();
DrawRect( PixelToLogic( rRenderContext.SetLineColor();
Rectangle( Point( mpMetadataAuthor->GetPosPixel().X() + Rectangle aRectangle(Point(mpMetadataAuthor->GetPosPixel().X() + mpMetadataAuthor->GetSizePixel().Width(),
mpMetadataAuthor->GetSizePixel().Width(), mpMetadataAuthor->GetPosPixel().Y()),
mpMetadataAuthor->GetPosPixel().Y() ), Size(GetMetaButtonAreaWidth(),
Size( GetMetaButtonAreaWidth(), mpMetadataAuthor->GetSizePixel().Height() + mpMetadataDate->GetSizePixel().Height()));
mpMetadataAuthor->GetSizePixel().Height() +
mpMetadataDate->GetSizePixel().Height() ) ) ) ); rRenderContext.DrawRect(PixelToLogic(aRectangle));
} }
} }
...@@ -302,12 +302,8 @@ void SwSidebarWin::Draw(OutputDevice* pDev, const Point& rPt, const Size& rSz, s ...@@ -302,12 +302,8 @@ void SwSidebarWin::Draw(OutputDevice* pDev, const Point& rPt, const Size& rSz, s
} }
} }
void SwSidebarWin::SetPosSizePixelRect( long nX, void SwSidebarWin::SetPosSizePixelRect(long nX, long nY, long nWidth, long nHeight,
long nY, const SwRect& aAnchorRect, const long aPageBorder)
long nWidth,
long nHeight,
const SwRect& aAnchorRect,
const long aPageBorder)
{ {
mPosSize = Rectangle(Point(nX,nY),Size(nWidth,nHeight)); mPosSize = Rectangle(Point(nX,nY),Size(nWidth,nHeight));
mAnchorRect = aAnchorRect; mAnchorRect = aAnchorRect;
......
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