40 aBoard.
Add( segment );
46 return { aShape,
true, aShape->
GetStart() };
63 if( dep.shape == aShape )
86 std::vector<BLOCK_DRAG_ENDPOINT> dependents;
99 exactCount += dep.shape == exact ? 1 : 0;
100 nearCount += dep.shape == nearSeg ? 1 : 0;
121 std::vector<BLOCK_DRAG_ENDPOINT> dependents;
138 std::vector<BLOCK_DRAG_ENDPOINT> dependents;
161 std::vector<BLOCK_DRAG_ENDPOINT> dependents;
196 std::vector<BLOCK_DRAG_ENDPOINT> dependents;
207 for(
const PCB_SHAPE* arc : { a1, a2, a3, a4 } )
213 if( dep.shape == arc )
234 std::vector<BLOCK_DRAG_ENDPOINT> dependents;
256 std::vector<BLOCK_DRAG_ENDPOINT> dependents;
277 if( drawing !=
moved )
281 std::vector<BLOCK_DRAG_ENDPOINT> dependents;
300 std::vector<BLOCK_DRAG_ENDPOINT> dependents;
316 std::vector<BLOCK_DRAG_ENDPOINT> dependents;
327 firstCount += dep.shape == first ? 1 : 0;
328 secondCount += dep.shape == second ? 1 : 0;
344 std::vector<BLOCK_DRAG_ENDPOINT> dependents;
362 std::vector<BLOCK_DRAG_ENDPOINT> dependents;
368 BOOST_CHECK( dependents.front().shape == neighbor );
378 locked->SetLocked(
true );
380 std::vector<BLOCK_DRAG_ENDPOINT> dependents;
406 footprint->
Add( child );
407 board.
Add( footprint );
409 std::vector<BLOCK_DRAG_ENDPOINT> dependents;
429 std::vector<BLOCK_DRAG_ENDPOINT> dependents;
437 BOOST_CHECK( dependents[0].isStart != dependents[1].isStart );
constexpr EDA_IU_SCALE pcbIUScale
BLOCK_DRAG_DEPENDENT_RESULT BlockDragFindDependents(const std::vector< PCB_SHAPE * > &aCandidates, const std::vector< BLOCK_DRAG_ENDPOINT > &aMovedEndpoints, bool aOverrideLocks, std::vector< BLOCK_DRAG_ENDPOINT > &aDependents)
Find the joined endpoints that have to follow the ones the drag moves.
BLOCK_DRAG_DEPENDENT_RESULT
@ LOCKED
A shape that would have to follow is locked and Override Locks is off, so the drag has to stop.
@ STRETCH
Only this end moves, so the shape stretches.
@ WHOLE
The whole shape moves, for a shape that moving one end alone would distort.
A base class for any item which can be embedded within the BOARD container class, and therefore insta...
void SetLocked(bool aLocked) override
Information pertinent to a Pcbnew printed circuit board.
void Add(BOARD_ITEM *aItem, ADD_MODE aMode=ADD_MODE::INSERT, bool aSkipConnectivity=false) override
Removes an item from the container.
void SetOutlinesChainingEpsilon(int aValue)
const DRAWINGS & Drawings() const
const VECTOR2I & GetStart() const
Return the starting point of the graphic.
void SetEnd(const VECTOR2I &aEnd) override
void SetLayer(PCB_LAYER_ID aLayer) override
Set the layer this item is on.
void SetStart(const VECTOR2I &aStart) override
void SetArcGeometry(const VECTOR2I &aStart, const VECTOR2I &aMid, const VECTOR2I &aEnd) override
Set the three controlling points for an arc.
static PCB_TRACK * makeSegment(BOARD *aBoard, const VECTOR2I &aStart, const VECTOR2I &aEnd)
PCB_LAYER_ID
A quick note on layer IDs:
One end of a graphic shape, used both for the ends that moved and for the ones found to follow them.
BOOST_AUTO_TEST_CASE(HorizontalAlignment)
BOOST_AUTO_TEST_CASE(ExactAndToleranceMatches)
BOOST_AUTO_TEST_SUITE(CadstarPartParser)
BOOST_CHECK(res.column_datatype(0)==SQL_NUMERIC||res.column_datatype(0)==SQL_DECIMAL)
BOOST_REQUIRE_EQUAL(rows.size(), 1)
BOOST_CHECK_EQUAL(std::any_cast< std::string >(rows[0].at("val")), "12345678901234567.89")
BOOST_REQUIRE(res.columns()==1)
static PCB_SHAPE makeArc(const VECTOR2I &aCenter, const VECTOR2I &aStart, double aAngle, PCB_LAYER_ID aLayer=Dwgs_User)
BOOST_AUTO_TEST_SUITE_END()
static std::vector< int > candidates(const SEGMENT_INDEX &aIndex, const SEG &aQuery, int aPadding)
SHAPE_CIRCLE circle(c.m_circle_center, c.m_circle_radius)
wxString result
Test unit parsing edge cases and error handling.
VECTOR2< int32_t > VECTOR2I