mirror of
https://gitlab.com/kicad/code/kicad.git
synced 2025-09-13 17:53:11 +02:00
SCH_BITMAP, SCH_TABLE: add missing HitTest(SHAPE_LINE_CHAIN& aPoly, ...)
Fixes https://gitlab.com/kicad/code/kicad/-/issues/21669
This commit is contained in:
parent
3cca1e87d8
commit
9622cf8ff1
@ -159,6 +159,13 @@ bool SCH_BITMAP::HitTest( const BOX2I& aRect, bool aContained, int aAccuracy ) c
|
||||
}
|
||||
|
||||
|
||||
bool SCH_BITMAP::HitTest( const SHAPE_LINE_CHAIN& aPoly, bool aContained ) const
|
||||
{
|
||||
return KIGEOM::BoxHitTest( aPoly, GetBoundingBox(), aContained );
|
||||
}
|
||||
|
||||
|
||||
|
||||
void SCH_BITMAP::Plot( PLOTTER* aPlotter, bool aBackground, const SCH_PLOT_OPTS& aPlotOpts,
|
||||
int aUnit, int aBodyStyle, const VECTOR2I& aOffset, bool aDimmed )
|
||||
{
|
||||
|
@ -100,6 +100,7 @@ public:
|
||||
|
||||
bool HitTest( const VECTOR2I& aPosition, int aAccuracy = 0 ) const override;
|
||||
bool HitTest( const BOX2I& aRect, bool aContained, int aAccuracy = 0 ) const override;
|
||||
bool HitTest( const SHAPE_LINE_CHAIN& aPoly, bool aContained ) const override;
|
||||
|
||||
void Plot( PLOTTER* aPlotter, bool aBackground, const SCH_PLOT_OPTS& aPlotOpts,
|
||||
int aUnit, int aBodyStyle, const VECTOR2I& aOffset, bool aDimmed ) override;
|
||||
|
@ -33,6 +33,7 @@
|
||||
#include <sch_painter.h>
|
||||
#include <wx/log.h>
|
||||
#include <sch_table.h>
|
||||
#include <geometry/geometry_utils.h>
|
||||
|
||||
|
||||
SCH_TABLE::SCH_TABLE( int aLineWidth ) :
|
||||
@ -327,6 +328,12 @@ bool SCH_TABLE::HitTest( const BOX2I& aRect, bool aContained, int aAccuracy ) co
|
||||
}
|
||||
|
||||
|
||||
bool SCH_TABLE::HitTest( const SHAPE_LINE_CHAIN& aPoly, bool aContained ) const
|
||||
{
|
||||
return KIGEOM::BoxHitTest( aPoly, GetBoundingBox(), aContained );
|
||||
}
|
||||
|
||||
|
||||
void SCH_TABLE::DrawBorders( const std::function<void( const VECTOR2I& aPt1, const VECTOR2I& aPt2,
|
||||
const STROKE_PARAMS& aStroke )>& aCallback ) const
|
||||
{
|
||||
|
@ -214,8 +214,8 @@ public:
|
||||
std::vector<int> ViewGetLayers() const override;
|
||||
|
||||
bool HitTest( const VECTOR2I& aPosition, int aAccuracy = 0 ) const override;
|
||||
|
||||
bool HitTest( const BOX2I& aRect, bool aContained, int aAccuracy = 0 ) const override;
|
||||
bool HitTest( const SHAPE_LINE_CHAIN& aPoly, bool aContained ) const override;
|
||||
|
||||
void DrawBorders( const std::function<void( const VECTOR2I& aPt1, const VECTOR2I& aPt2,
|
||||
const STROKE_PARAMS& aStroke )>& aCallback ) const;
|
||||
|
Loading…
x
Reference in New Issue
Block a user