KiCad PCB EDA Suite
Loading...
Searching...
No Matches
dialog_board_reannotate.cpp File Reference
#include "dialog_board_reannotate.h"
#include <algorithm>
#include <base_units.h>
#include <bitmaps.h>
#include <board_commit.h>
#include <confirm.h>
#include <ctype.h>
#include <gal/graphics_abstraction_layer.h>
#include <string_utils.h>
#include <kiface_base.h>
#include <pcbnew_settings.h>
#include <refdes_utils.h>
#include <richio.h>
#include <tool/grid_menu.h>
#include <widgets/wx_html_report_panel.h>
#include <wx/valtext.h>

Go to the source code of this file.

Macros

#define SetSortCodes(DirArray, Code)
 

Functions

static bool ChangeArrayCompare (const REFDES_CHANGE &aA, const REFDES_CHANGE &aB)
 Compare function used to compare ChangeArray element for sort.
 
static bool FootprintCompare (const REFDES_INFO &aA, const REFDES_INFO &aB)
 Compare function to sort footprints.
 

Variables

bool g_SortYFirst
 
bool g_DescendingFirst
 
bool g_DescendingSecond
 
int FrontDirectionsArray []
 
int BackDirectionsArray []
 
wxString ActionMessage []
 

Macro Definition Documentation

◆ SetSortCodes

#define SetSortCodes (   DirArray,
  Code 
)
Value:
{ \
g_SortYFirst = ( ( DirArray[Code] & SORTYFIRST ) != 0 ); \
g_DescendingFirst = ( ( DirArray[Code] & DESCENDINGFIRST ) != 0 ); \
g_DescendingSecond = ( ( DirArray[Code] & DESCENDINGSECOND ) != 0 ); \
}
bool g_DescendingFirst
bool g_DescendingSecond
bool g_SortYFirst
#define DESCENDINGFIRST
#define DESCENDINGSECOND
#define SORTYFIRST

Definition at line 79 of file dialog_board_reannotate.cpp.

Function Documentation

◆ ChangeArrayCompare()

static bool ChangeArrayCompare ( const REFDES_CHANGE aA,
const REFDES_CHANGE aB 
)
static

Compare function used to compare ChangeArray element for sort.

Returns
true is A < B

Definition at line 348 of file dialog_board_reannotate.cpp.

References REFDES_CHANGE::OldRefDesString, and StrNumCmp().

Referenced by DIALOG_BOARD_REANNOTATE::BuildFootprintList().

◆ FootprintCompare()

static bool FootprintCompare ( const REFDES_INFO aA,
const REFDES_INFO aB 
)
static

Compare function to sort footprints.

Returns
true if the first coordinate should be before the second coordinate

Definition at line 356 of file dialog_board_reannotate.cpp.

References g_DescendingFirst, g_DescendingSecond, g_SortYFirst, REFDES_INFO::roundedx, and REFDES_INFO::roundedy.

Referenced by DIALOG_BOARD_REANNOTATE::BuildFootprintList().

Variable Documentation

◆ ActionMessage

wxString ActionMessage[]
Initial value:
= {
"",
_( "Empty" ),
_( "Invalid" ),
_( "Excluded" )
}
#define _(s)

Definition at line 87 of file dialog_board_reannotate.cpp.

Referenced by DIALOG_BOARD_REANNOTATE::LogChangePlan().

◆ BackDirectionsArray

◆ FrontDirectionsArray

◆ g_DescendingFirst

bool g_DescendingFirst

Definition at line 46 of file dialog_board_reannotate.cpp.

Referenced by FootprintCompare().

◆ g_DescendingSecond

bool g_DescendingSecond

Definition at line 47 of file dialog_board_reannotate.cpp.

Referenced by FootprintCompare().

◆ g_SortYFirst

bool g_SortYFirst

Definition at line 45 of file dialog_board_reannotate.cpp.

Referenced by FootprintCompare().