39enum class BITMAPS :
unsigned int;
57namespace google {
namespace protobuf {
class Any; } }
176 virtual bool IsType(
const std::vector<KICAD_T>& aScanTypes )
const
178 for(
KICAD_T scanType : aScanTypes )
229 virtual bool HitTest(
const BOX2I& aRect,
bool aContained,
int aAccuracy = 0 )
const
290 const std::vector<KICAD_T>& aScanTypes );
297 const std::vector<KICAD_T>& scanTypes )
299 for(
const auto& it : aList )
303 scanTypes ) == INSPECT_RESULT::QUIT )
305 return INSPECT_RESULT::QUIT;
309 return INSPECT_RESULT::CONTINUE;
317 void* testData,
const std::vector<KICAD_T>& scanTypes )
319 for(
const auto& it : aList )
323 scanTypes ) == INSPECT_RESULT::QUIT )
325 return INSPECT_RESULT::QUIT;
329 return INSPECT_RESULT::CONTINUE;
457 virtual void Show(
int nestLevel, std::ostream& os )
const { ShowDummy( os ); };
459 void ShowDummy( std::ostream& os )
const;
468 static std::ostream& NestedSpace(
int nestLevel, std::ostream& os );
474 EDA_ITEM(
KICAD_T idType,
bool isSCH_ITEM =
false,
bool isBOARD_ITEM =
false );
520 assert( item1 !=
nullptr && item2 !=
nullptr );
523 return item1 < item2;
BITMAPS
A list of all bitmap identifiers.
The base class for create windows for drawing purpose.
A base class for most all the KiCad significant classes used in schematics and boards.
virtual bool HitTest(const BOX2I &aRect, bool aContained, int aAccuracy=0) const
Test if aRect intersects this item.
virtual VECTOR2I GetPosition() const
virtual void ClearEditFlags()
EDA_ITEM & operator=(const EDA_ITEM &aItem)
Assign the members of aItem to another object.
virtual const VECTOR2I GetFocusPosition() const
Similar to GetPosition, but allows items to return their visual center rather than their anchor.
virtual void SetPosition(const VECTOR2I &aPos)
virtual const BOX2I GetBoundingBox() const
Return the orthogonal bounding box of this object for display purposes.
wxString GetTypeDesc() const
Return a translated description of the type for this EDA_ITEM for display in user facing messages.
static bool Sort(const EDA_ITEM *aLeft, const EDA_ITEM *aRight)
Helper function to be used by the C++ STL sort algorithm for sorting a STL container of EDA_ITEM poin...
EDA_ITEM_FLAGS GetEditFlags() const
void SetFlags(EDA_ITEM_FLAGS aMask)
virtual wxString GetItemDescription(UNITS_PROVIDER *aUnitsProvider, bool aFull) const
Return a user-visible description string of this item.
KICAD_T Type() const
Returns the type of object.
bool operator<(const EDA_ITEM &aItem) const
Test if another item is less than this object.
void SetForceVisible(bool aEnable)
Set and clear force visible flag used to force the item to be drawn even if it's draw attribute is se...
void ClearFlags(EDA_ITEM_FLAGS aMask=EDA_ITEM_ALL_FLAGS)
virtual bool Replace(const EDA_SEARCH_DATA &aSearchData, void *aAuxData=nullptr)
Perform a text replace using the find and replace criteria in aSearchData on items that support text ...
void SetIsShownAsBitmap(bool aBitmap)
virtual std::vector< int > ViewGetLayers() const override
Return the all the layers within the VIEW the object is painted on.
EDA_ITEM_FLAGS GetTempFlags() const
virtual bool Matches(const EDA_SEARCH_DATA &aSearchData, void *aAuxData) const
Compare the item against the search criteria in aSearchData.
static INSPECT_RESULT IterateForward(std::deque< T > &aList, INSPECTOR inspector, void *testData, const std::vector< KICAD_T > &scanTypes)
This changes first parameter to avoid the DList and use the main queue instead.
virtual void GetMsgPanelInfo(EDA_DRAW_FRAME *aFrame, std::vector< MSG_PANEL_ITEM > &aList)
Populate aList of MSG_PANEL_ITEM objects with it's internal state for display purposes.
virtual bool IsType(const std::vector< KICAD_T > &aScanTypes) const
Check whether the item is one of the listed types.
virtual INSPECT_RESULT Visit(INSPECTOR inspector, void *testData, const std::vector< KICAD_T > &aScanTypes)
May be re-implemented for each derived class in order to handle all the types given by its member dat...
virtual void SetParent(EDA_ITEM *aParent)
bool IsShownAsBitmap() const
virtual bool HitTest(const VECTOR2I &aPosition, int aAccuracy=0) const
Test if aPosition is inside or on the boundary of this item.
virtual wxString GetFriendlyName() const
EDA_ITEM * GetParent() const
virtual EDA_ITEM * Clone() const
Create a duplicate of this item with linked list members set to NULL.
bool HasFlag(EDA_ITEM_FLAGS aFlag) const
virtual EMBEDDED_FILES * GetEmbeddedFiles()
bool IsBrightened() const
virtual VECTOR2I GetSortPosition() const
Return the coordinates that should be used for sorting this element visually compared to other elemen...
void XorFlags(EDA_ITEM_FLAGS aMask)
virtual wxString GetClass() const =0
Return the class name.
virtual const BOX2I ViewBBox() const override
Return the bounding box of the item covering all its layers.
virtual bool RenderAsBitmap(double aWorldScale) const
static INSPECT_RESULT IterateForward(std::vector< T > &aList, INSPECTOR inspector, void *testData, const std::vector< KICAD_T > &scanTypes)
Change first parameter to avoid the DList and use std::vector instead.
EDA_ITEM * m_parent
Linked list: Link (parent struct)
bool IsForceVisible() const
EDA_ITEM_FLAGS GetFlags() const
static bool Replace(const EDA_SEARCH_DATA &aSearchData, wxString &aText)
Perform a text replace on aText using the find and replace criteria in aSearchData on items that supp...
KICAD_T m_structType
Run time identification, keep private so it can never be changed after a ctor sets it.
virtual bool IsReplaceable() const
Override this method in any derived object that supports test find and replace.
virtual void ClearTempFlags()
virtual BITMAPS GetMenuImage() const
Return a pointer to an image to be used in menus.
An abstract base class for deriving all objects that can be added to a VIEW.
EDA_MSG_PANEL items for displaying messages.
Interface for objects that can be serialized to Protobuf messages.
EDA_ITEM * new_clone(const EDA_ITEM &aItem)
Provide cloning capabilities for all Boost pointer containers of EDA_ITEM pointers.
std::vector< EDA_ITEM * > EDA_ITEMS
Define list of drawing items for screens.
std::set< EDA_ITEM *, CompareByUuid > EDA_ITEM_SET
const INSPECTOR_FUNC & INSPECTOR
std::function< INSPECT_RESULT(EDA_ITEM *aItem, void *aTestData) > INSPECTOR_FUNC
Used to inspect and possibly collect the (search) results of iterating over a list or tree of KICAD_T...
#define IS_PASTED
Modifier on IS_NEW which indicates it came from clipboard.
#define IS_CHANGED
Item was edited, and modified.
#define BRIGHTENED
item is drawn with a bright contour
#define IS_SHOWN_AS_BITMAP
#define IS_NEW
New item, just created.
#define IS_LINKED
Used in calculation to mark linked items (temporary use)
#define SELECTED
Item was manually selected by the user.
#define SELECTED_BY_DRAG
Item was algorithmically selected as a dragged item.
#define EDA_ITEM_ALL_FLAGS
#define IS_BROKEN
Is a segment just broken by BreakSegment.
#define ENTERED
indicates a group has been entered
#define STRUCT_DELETED
flag indication structures to be erased
#define SKIP_STRUCT
flag indicating that the structure should be ignored
std::uint32_t EDA_ITEM_FLAGS
#define CANDIDATE
flag indicating that the structure is connected
#define IS_ROLLOVER
Rollover active. Used for hyperlink highlighting.
#define IS_MOVING
Item being moved.
Comparison functor for sorting EDA_ITEM pointers by their UUID.
bool operator()(const EDA_ITEM *item1, const EDA_ITEM *item2) const
KICAD_T
The set of class identification values stored in EDA_ITEM::m_structType.
VECTOR2< int32_t > VECTOR2I