KiCad PCB EDA Suite
|
Public Member Functions | |
FP_GRID_TRICKS (DIALOG_EDIT_LIBRARY_TABLES *aParent, WX_GRID *aGrid) | |
void | SetTooltipEnable (int aCol, bool aEnable=true) |
Enable the tooltip for a column. More... | |
bool | GetTooltipEnabled (int aCol) |
Query if the tooltip for a column is enabled. More... | |
Protected Member Functions | |
void | optionsEditor (int aRow) |
bool | handleDoubleClick (wxGridEvent &aEvent) override |
void | showPopupMenu (wxMenu &menu) override |
void | doPopupSelection (wxCommandEvent &event) override |
void | paste_text (const wxString &cb_text) override |
handle specialized clipboard text, with leading "(fp_lib_table", OR spreadsheet formatted text. More... | |
void | init () |
Shared initialization for various ctors. More... | |
void | getSelectedArea () |
Puts the selected area into a sensible rectangle of m_sel_{row,col}_{start,count} above. More... | |
void | onGridCellLeftClick (wxGridEvent &event) |
void | onGridCellLeftDClick (wxGridEvent &event) |
void | onGridCellRightClick (wxGridEvent &event) |
void | onGridLabelLeftClick (wxGridEvent &event) |
void | onGridLabelRightClick (wxGridEvent &event) |
void | onPopupSelection (wxCommandEvent &event) |
void | onKeyDown (wxKeyEvent &event) |
void | onCharHook (wxKeyEvent &event) |
void | onUpdateUI (wxUpdateUIEvent &event) |
void | onGridMotion (wxMouseEvent &event) |
bool | toggleCell (int aRow, int aCol, bool aPreserveSelection=false) |
bool | showEditor (int aRow, int aCol) |
virtual void | paste_clipboard () |
virtual void | cutcopy (bool doCopy, bool doDelete) |
Protected Attributes | |
DIALOG_EDIT_LIBRARY_TABLES * | m_dialog |
WX_GRID * | m_grid |
I don't own the grid, but he owns me. More... | |
int | m_sel_row_start |
int | m_sel_col_start |
int | m_sel_row_count |
int | m_sel_col_count |
std::function< void(wxCommandEvent &)> | m_addHandler |
std::bitset< GRIDTRICKS_MAX_COL > | m_tooltipEnabled |
Private Types | |
enum | { LIB_TABLE_GRID_TRICKS_ACTIVATE_SELECTED = GRIDTRICKS_FIRST_CLIENT_ID , LIB_TABLE_GRID_TRICKS_DEACTIVATE_SELECTED } |
Definition at line 250 of file panel_fp_lib_table.cpp.
|
privateinherited |
Enumerator | |
---|---|
LIB_TABLE_GRID_TRICKS_ACTIVATE_SELECTED | |
LIB_TABLE_GRID_TRICKS_DEACTIVATE_SELECTED |
Definition at line 24 of file lib_table_grid_tricks.h.
|
inline |
Definition at line 253 of file panel_fp_lib_table.cpp.
|
protectedvirtualinherited |
Definition at line 745 of file grid_tricks.cpp.
References COL_SEP, GRID_TRICKS::m_grid, GRID_TRICKS::m_sel_col_count, GRID_TRICKS::m_sel_col_start, GRID_TRICKS::m_sel_row_count, GRID_TRICKS::m_sel_row_start, and ROW_SEP.
Referenced by GRID_TRICKS::doPopupSelection(), and GRID_TRICKS::onKeyDown().
|
inlineoverrideprotectedvirtual |
Reimplemented from LIB_TABLE_GRID_TRICKS.
Definition at line 303 of file panel_fp_lib_table.cpp.
References LIB_TABLE_GRID_TRICKS::doPopupSelection(), GRID_TRICKS::m_grid, MYID_OPTIONS_EDITOR, and optionsEditor().
|
protectedinherited |
Puts the selected area into a sensible rectangle of m_sel_{row,col}_{start,count} above.
Definition at line 252 of file grid_tricks.cpp.
References GRID_TRICKS::m_grid, GRID_TRICKS::m_sel_col_count, GRID_TRICKS::m_sel_col_start, GRID_TRICKS::m_sel_row_count, and GRID_TRICKS::m_sel_row_start.
Referenced by GRID_TRICKS::onGridCellLeftClick(), GRID_TRICKS::onKeyDown(), and GRID_TRICKS::showPopupMenu().
|
inlineinherited |
Query if the tooltip for a column is enabled.
aCol | is the column to query |
Definition at line 86 of file grid_tricks.h.
References GRID_TRICKS::m_tooltipEnabled.
|
inlineoverrideprotectedvirtual |
Reimplemented from GRID_TRICKS.
Definition at line 281 of file panel_fp_lib_table.cpp.
References COL_OPTIONS, and optionsEditor().
|
protectedinherited |
Shared initialization for various ctors.
Definition at line 56 of file grid_tricks.cpp.
References GRIDTRICKS_FIRST_ID, GRIDTRICKS_LAST_ID, GRID_TRICKS::m_grid, GRID_TRICKS::m_sel_col_count, GRID_TRICKS::m_sel_col_start, GRID_TRICKS::m_sel_row_count, GRID_TRICKS::m_sel_row_start, GRID_TRICKS::onCharHook(), GRID_TRICKS::onGridCellLeftClick(), GRID_TRICKS::onGridCellLeftDClick(), GRID_TRICKS::onGridCellRightClick(), GRID_TRICKS::onGridLabelLeftClick(), GRID_TRICKS::onGridLabelRightClick(), GRID_TRICKS::onGridMotion(), GRID_TRICKS::onKeyDown(), GRID_TRICKS::onPopupSelection(), and GRID_TRICKS::onUpdateUI().
Referenced by GRID_TRICKS::GRID_TRICKS().
|
protectedinherited |
Definition at line 417 of file grid_tricks.cpp.
References COL_SEP, WX_GRID::CommitPendingChanges(), dummy, GRID_TRICKS::m_addHandler, GRID_TRICKS::m_grid, GRID_TRICKS::paste_text(), and ROW_SEP.
Referenced by GRID_TRICKS::init().
|
protectedinherited |
Definition at line 168 of file grid_tricks.cpp.
References GRID_TRICKS::getSelectedArea(), GRID_TRICKS::m_grid, GRID_TRICKS::m_sel_row_count, GRID_TRICKS::m_sel_row_start, GRID_TRICKS::showEditor(), and GRID_TRICKS::toggleCell().
Referenced by GRID_TRICKS::init(), and GRID_TRICKS::onGridCellLeftDClick().
|
protectedinherited |
Definition at line 215 of file grid_tricks.cpp.
References GRID_TRICKS::handleDoubleClick(), and GRID_TRICKS::onGridCellLeftClick().
Referenced by GRID_TRICKS::init().
|
protectedinherited |
Definition at line 292 of file grid_tricks.cpp.
References GRID_TRICKS::showPopupMenu().
Referenced by GRID_TRICKS::init().
|
protectedinherited |
Definition at line 300 of file grid_tricks.cpp.
References WX_GRID::CommitPendingChanges(), and GRID_TRICKS::m_grid.
Referenced by GRID_TRICKS::init().
|
protectedinherited |
Definition at line 308 of file grid_tricks.cpp.
References GRIDTRICKS_FIRST_SHOWHIDE, and GRID_TRICKS::m_grid.
Referenced by GRID_TRICKS::init().
|
protectedinherited |
Definition at line 222 of file grid_tricks.cpp.
References GRID_TRICKS::m_grid, and GRID_TRICKS::m_tooltipEnabled.
Referenced by GRID_TRICKS::init().
|
protectedinherited |
Definition at line 457 of file grid_tricks.cpp.
References GRID_TRICKS::cutcopy(), GRID_TRICKS::getSelectedArea(), GRID_TRICKS::m_grid, GRID_TRICKS::paste_clipboard(), and GRID_TRICKS::toggleCell().
Referenced by GRID_TRICKS::init().
|
protectedinherited |
Definition at line 368 of file grid_tricks.cpp.
References GRID_TRICKS::doPopupSelection().
Referenced by GRID_TRICKS::init().
|
protectedinherited |
Definition at line 790 of file grid_tricks.cpp.
References GRID_TRICKS::m_grid.
Referenced by GRID_TRICKS::init().
|
inlineprotected |
Definition at line 260 of file panel_fp_lib_table.cpp.
References FP_LIB_TABLE_GRID::at(), LIB_TABLE_ROW::GetNickName(), LIB_TABLE_GRID::GetNumberRows(), LIB_TABLE_ROW::GetOptions(), LIB_TABLE_ROW::GetType(), InvokePluginOptionsEditor(), m_dialog, GRID_TRICKS::m_grid, and LIB_TABLE_ROW::SetOptions().
Referenced by doPopupSelection(), and handleDoubleClick().
|
protectedvirtualinherited |
Definition at line 625 of file grid_tricks.cpp.
References GRID_TRICKS::m_grid, and GRID_TRICKS::paste_text().
Referenced by GRID_TRICKS::doPopupSelection(), and GRID_TRICKS::onKeyDown().
|
inlineoverrideprotectedvirtual |
handle specialized clipboard text, with leading "(fp_lib_table", OR spreadsheet formatted text.
Reimplemented from GRID_TRICKS.
Definition at line 313 of file panel_fp_lib_table.cpp.
References LIB_TABLE_GRID::AppendRows(), LIB_TABLE::At(), LIB_TABLE_ROW::clone(), DisplayError(), LIB_TABLE::GetCount(), LIB_TABLE_GRID::GetNumberRows(), m_dialog, GRID_TRICKS::m_grid, LIB_TABLE::m_rows, FP_LIB_TABLE::Parse(), GRID_TRICKS::paste_text(), TO_UTF8, and IO_ERROR::What().
|
inlineinherited |
Enable the tooltip for a column.
The tooltip is read from the string contained in the cell data.
aCol | is the column to use |
aEnable | is true to enable the tooltip (default) |
Definition at line 75 of file grid_tricks.h.
References GRID_TRICKS::m_tooltipEnabled.
Referenced by PANEL_FP_PROPERTIES_3D_MODEL::PANEL_FP_PROPERTIES_3D_MODEL().
|
protectedinherited |
Definition at line 133 of file grid_tricks.cpp.
References GRID_TRICKS::m_grid, and WX_GRID::ShowEditorOnMouseUp().
Referenced by GRID_TRICKS::onGridCellLeftClick().
|
inlineoverrideprotectedvirtual |
Reimplemented from LIB_TABLE_GRID_TRICKS.
Definition at line 292 of file panel_fp_lib_table.cpp.
References _, COL_OPTIONS, GRID_TRICKS::m_grid, MYID_OPTIONS_EDITOR, and LIB_TABLE_GRID_TRICKS::showPopupMenu().
|
protectedinherited |
Definition at line 89 of file grid_tricks.cpp.
References GRID_TRICKS::m_grid.
Referenced by GRID_TRICKS::onGridCellLeftClick(), and GRID_TRICKS::onKeyDown().
|
protectedinherited |
Definition at line 130 of file grid_tricks.h.
Referenced by GRID_TRICKS::onCharHook().
|
protected |
Definition at line 258 of file panel_fp_lib_table.cpp.
Referenced by optionsEditor(), and paste_text().
|
protectedinherited |
I don't own the grid, but he owns me.
Definition at line 121 of file grid_tricks.h.
Referenced by GRID_TRICKS::cutcopy(), GRID_TRICKS::doPopupSelection(), FIELDS_EDITOR_GRID_TRICKS::doPopupSelection(), FIELDS_GRID_TRICKS::doPopupSelection(), LIB_TABLE_GRID_TRICKS::doPopupSelection(), doPopupSelection(), GRID_TRICKS::getSelectedArea(), GRID_TRICKS::init(), GRID_TRICKS::onCharHook(), GRID_TRICKS::onGridCellLeftClick(), GRID_TRICKS::onGridLabelLeftClick(), GRID_TRICKS::onGridLabelRightClick(), GRID_TRICKS::onGridMotion(), GRID_TRICKS::onKeyDown(), GRID_TRICKS::onUpdateUI(), optionsEditor(), GRID_TRICKS::paste_clipboard(), GRID_TRICKS::paste_text(), SYMBOL_GRID_TRICKS::paste_text(), paste_text(), GRID_TRICKS::showEditor(), GRID_TRICKS::showPopupMenu(), FIELDS_EDITOR_GRID_TRICKS::showPopupMenu(), FIELDS_GRID_TRICKS::showPopupMenu(), LIB_TABLE_GRID_TRICKS::showPopupMenu(), showPopupMenu(), and GRID_TRICKS::toggleCell().
|
protectedinherited |
Definition at line 128 of file grid_tricks.h.
Referenced by GRID_TRICKS::cutcopy(), GRID_TRICKS::getSelectedArea(), GRID_TRICKS::init(), GRID_TRICKS::paste_text(), and GRID_TRICKS::showPopupMenu().
|
protectedinherited |
Definition at line 126 of file grid_tricks.h.
Referenced by GRID_TRICKS::cutcopy(), GRID_TRICKS::getSelectedArea(), GRID_TRICKS::init(), and GRID_TRICKS::paste_text().
|
protectedinherited |
Definition at line 127 of file grid_tricks.h.
Referenced by GRID_TRICKS::cutcopy(), LIB_TABLE_GRID_TRICKS::doPopupSelection(), GRID_TRICKS::getSelectedArea(), GRID_TRICKS::init(), GRID_TRICKS::onGridCellLeftClick(), GRID_TRICKS::paste_text(), GRID_TRICKS::showPopupMenu(), and LIB_TABLE_GRID_TRICKS::showPopupMenu().
|
protectedinherited |
Definition at line 125 of file grid_tricks.h.
Referenced by GRID_TRICKS::cutcopy(), LIB_TABLE_GRID_TRICKS::doPopupSelection(), GRID_TRICKS::getSelectedArea(), GRID_TRICKS::init(), GRID_TRICKS::onGridCellLeftClick(), GRID_TRICKS::paste_text(), and LIB_TABLE_GRID_TRICKS::showPopupMenu().
|
protectedinherited |
Definition at line 132 of file grid_tricks.h.
Referenced by GRID_TRICKS::GetTooltipEnabled(), GRID_TRICKS::onGridMotion(), and GRID_TRICKS::SetTooltipEnable().