KiCad PCB EDA Suite
mirror.h File Reference

Go to the source code of this file.

Functions

template<typename T >
MIRRORVAL (T aPoint, T aMirrorRef)
 Returns the mirror of aPoint relative to the aMirrorRef. More...
 
template<typename T >
void MIRROR (T &aPoint, const T &aMirrorRef)
 Updates aPoint with the mirror of aPoint relative to the aMirrorRef. More...
 

Function Documentation

◆ MIRROR()

◆ MIRRORVAL()

template<typename T >
T MIRRORVAL ( aPoint,
aMirrorRef 
)

Returns the mirror of aPoint relative to the aMirrorRef.

Definition at line 31 of file mirror.h.

32{
33 return -( aPoint - aMirrorRef ) + aMirrorRef;
34}

Referenced by FP_TEXT::Flip(), FP_TEXTBOX::Flip(), PCB_TEXT::Flip(), FP_TEXT::Mirror(), PCB_TEXT::Mirror(), MIRROR(), SCH_TEXT::MirrorHorizontally(), and SCH_TEXT::MirrorVertically().