KiCad PCB EDA Suite
|
An interface for classes handling user events controlling the view behavior such as zooming, panning, mouse grab, etc. More...
#include <view_controls.h>
Public Member Functions | |
VIEW_CONTROLS (VIEW *aView) | |
virtual | ~VIEW_CONTROLS () |
virtual void | SetGrabMouse (bool aEnabled) |
Turn on/off mouse grabbing. | |
virtual void | SetAutoPan (bool aEnabled) |
Turn on/off auto panning (this feature is used when there is a tool active (eg. | |
virtual void | EnableAutoPan (bool aEnabled) |
Turn on/off auto panning (user setting to disable it entirely). | |
virtual void | SetAutoPanSpeed (float aSpeed) |
Set the speed of autopanning. | |
virtual void | SetAutoPanAcceleration (float aAcceleration) |
Set the speed of autopanning. | |
virtual void | SetAutoPanMargin (float aMargin) |
Set the margin for autopanning (ie. | |
virtual void | PinCursorInsideNonAutoscrollArea (bool aWarpMouseCursor)=0 |
virtual VECTOR2D | GetMousePosition (bool aWorldCoordinates=true) const =0 |
Return the current mouse pointer position. | |
VECTOR2D | GetCursorPosition () const |
Return the current cursor position in world coordinates. | |
virtual VECTOR2D | GetRawCursorPosition (bool aSnappingEnabled=true) const =0 |
Return the current cursor position in world coordinates ignoring the cursorUp position force mode. | |
virtual VECTOR2D | GetCursorPosition (bool aEnableSnapping) const =0 |
Return the current cursor position in world coordinates. | |
virtual void | ForceCursorPosition (bool aEnabled, const VECTOR2D &aPosition=VECTOR2D(0, 0)) |
Place the cursor immediately at a given point. | |
virtual void | SetCursorPosition (const VECTOR2D &aPosition, bool aWarpView=true, bool aTriggeredByArrows=false, long aArrowCommand=0)=0 |
Move cursor to the requested position expressed in world coordinates. | |
virtual void | SetCrossHairCursorPosition (const VECTOR2D &aPosition, bool aWarpView=true)=0 |
Move the graphic crosshair cursor to the requested position expressed in world coordinates. | |
virtual void | ShowCursor (bool aEnabled) |
Enable or disables display of cursor. | |
bool | IsCursorShown () const |
Return true when cursor is visible. | |
virtual void | CaptureCursor (bool aEnabled) |
Force the cursor to stay within the drawing panel area. | |
virtual void | WarpMouseCursor (const VECTOR2D &aPosition, bool aWorldCoordinates=false, bool aWarpView=false)=0 |
If enabled (. | |
void | EnableCursorWarping (bool aEnable) |
Enable or disable warping the cursor. | |
bool | IsCursorWarpingEnabled () const |
virtual void | CenterOnCursor ()=0 |
Set the viewport center to the current cursor position and warps the cursor to the screen center. | |
virtual void | Reset () |
Restore the default VIEW_CONTROLS settings. | |
const VC_SETTINGS & | GetSettings () const |
Apply VIEW_CONTROLS settings from an object. | |
void | ApplySettings (const VC_SETTINGS &aSettings) |
Load new settings from program common settings. | |
virtual void | LoadSettings () |
Protected Attributes | |
VIEW * | m_view |
< Pointer to controlled VIEW. | |
bool | m_cursorWarped |
Current VIEW_CONTROLS settings. | |
VC_SETTINGS | m_settings |
An interface for classes handling user events controlling the view behavior such as zooming, panning, mouse grab, etc.
Definition at line 138 of file view_controls.h.
|
inline |
Definition at line 141 of file view_controls.h.
|
inlinevirtual |
Definition at line 147 of file view_controls.h.
void VIEW_CONTROLS::ApplySettings | ( | const VC_SETTINGS & | aSettings | ) |
Load new settings from program common settings.
Definition at line 90 of file view_controls.cpp.
References CaptureCursor(), ForceCursorPosition(), KIGFX::VC_SETTINGS::m_autoPanEnabled, KIGFX::VC_SETTINGS::m_autoPanMargin, KIGFX::VC_SETTINGS::m_autoPanSpeed, KIGFX::VC_SETTINGS::m_cursorCaptured, KIGFX::VC_SETTINGS::m_forceCursorPosition, KIGFX::VC_SETTINGS::m_forcedPosition, KIGFX::VC_SETTINGS::m_grabMouse, KIGFX::VC_SETTINGS::m_showCursor, SetAutoPan(), SetAutoPanMargin(), SetAutoPanSpeed(), SetGrabMouse(), and ShowCursor().
Referenced by TOOL_MANAGER::applyViewControls(), DIALOG_PAD_PROPERTIES::prepareCanvas(), and Reset().
|
inlinevirtual |
Force the cursor to stay within the drawing panel area.
aEnabled | determines if the cursor should be captured. |
Reimplemented in KIGFX::WX_VIEW_CONTROLS.
Definition at line 323 of file view_controls.h.
Referenced by ApplySettings(), KIGFX::WX_VIEW_CONTROLS::CaptureCursor(), SCH_LINE_WIRE_BUS_TOOL::doDrawSegments(), SYMBOL_EDITOR_DRAWING_TOOLS::doDrawShape(), PCB_TOOL_BASE::doInteractiveItemPlacement(), DRAWING_TOOL::drawArc(), DRAWING_TOOL::DrawDimension(), MICROWAVE_TOOL::drawMicrowaveInductor(), DRAWING_TOOL::drawOneBezier(), SCH_DRAWING_TOOLS::DrawRuleArea(), SCH_DRAWING_TOOLS::DrawShape(), PL_DRAWING_TOOLS::DrawShape(), DRAWING_TOOL::drawShape(), SCH_DRAWING_TOOLS::DrawSheet(), SCH_DRAWING_TOOLS::DrawTable(), DRAWING_TOOL::DrawTable(), DRAWING_TOOL::DrawZone(), SCH_LINE_WIRE_BUS_TOOL::finishSegments(), EE_POINT_EDITOR::Main(), EE_SELECTION_TOOL::Main(), PL_POINT_EDITOR::Main(), GERBVIEW_INSPECTION_TOOL::MeasureTool(), BOARD_EDITOR_CONTROL::PlaceFootprint(), SCH_DRAWING_TOOLS::PlaceImage(), PL_DRAWING_TOOLS::PlaceItem(), DRAWING_TOOL::PlaceReferenceImage(), SCH_DRAWING_TOOLS::PlaceSymbol(), DRAWING_TOOL::PlaceText(), DRAWING_TOOL::PlaceTuningPattern(), POSITION_RELATIVE_TOOL::PositionRelativeInteractively(), DRAWING_TOOL::SetAnchor(), PICKER_TOOL::setControls(), PCB_PICKER_TOOL::setControls(), SCH_DRAWING_TOOLS::TwoClickPlace(), and SYMBOL_EDITOR_DRAWING_TOOLS::TwoClickPlace().
|
pure virtual |
Set the viewport center to the current cursor position and warps the cursor to the screen center.
Implemented in KIGFX::WX_VIEW_CONTROLS.
Referenced by COMMON_TOOLS::doZoomToPreset(), SCH_BASE_FRAME::RedrawScreen(), and COMMON_TOOLS::ZoomCenter().
|
inlinevirtual |
Turn on/off auto panning (user setting to disable it entirely).
aEnabled | tells if the autopanning should be enabled. |
Definition at line 178 of file view_controls.h.
|
inline |
Enable or disable warping the cursor.
aEnable | is true if the cursor is allowed to be warped. |
Definition at line 349 of file view_controls.h.
|
inlinevirtual |
Place the cursor immediately at a given point.
Mouse movement is ignored.
aEnabled | enable forced cursor position |
aPosition | the position (world coordinates). |
Reimplemented in KIGFX::WX_VIEW_CONTROLS.
Definition at line 273 of file view_controls.h.
Referenced by ApplySettings(), EE_SELECTION_TOOL::autostartEvent(), TOOL_MANAGER::DispatchContextMenu(), SCH_LINE_WIRE_BUS_TOOL::doDrawSegments(), SYMBOL_EDITOR_DRAWING_TOOLS::doDrawShape(), PCB_TOOL_BASE::doInteractiveItemPlacement(), EDIT_TOOL::doMoveSelection(), SYMBOL_EDITOR_MOVE_TOOL::doMoveSelection(), EDIT_TOOL::DragArcTrack(), DRAWING_TOOL::drawArc(), DRAWING_TOOL::DrawDimension(), DRAWING_TOOL::drawOneBezier(), SCH_DRAWING_TOOLS::DrawRuleArea(), SCH_DRAWING_TOOLS::DrawShape(), DRAWING_TOOL::drawShape(), SCH_DRAWING_TOOLS::DrawSheet(), SCH_DRAWING_TOOLS::DrawTable(), DRAWING_TOOL::DrawTable(), DRAWING_TOOL::DrawZone(), PAD_TOOL::EnumeratePads(), ROUTER_TOOL::finishInteractive(), SCH_DRAWING_TOOLS::ImportGraphics(), SYMBOL_EDITOR_DRAWING_TOOLS::ImportGraphics(), SCH_DRAWING_TOOLS::ImportSheet(), ROUTER_TOOL::InlineBreakTrack(), ROUTER_TOOL::InlineDrag(), EE_POINT_EDITOR::Main(), EE_SELECTION_TOOL::Main(), PICKER_TOOL::Main(), PL_EDIT_TOOL::Main(), PL_POINT_EDITOR::Main(), PCB_PICKER_TOOL::Main(), ROUTER_TOOL::MainLoop(), PCB_POINT_EDITOR::OnSelectionChange(), ROUTER_TOOL::performDragging(), SCH_DRAWING_TOOLS::PlaceImage(), DRAWING_TOOL::PlaceImportedGraphics(), PAD_TOOL::PlacePad(), DRAWING_TOOL::PlaceReferenceImage(), SCH_DRAWING_TOOLS::PlaceSymbol(), DRAWING_TOOL::PlaceText(), DRAWING_TOOL::PlaceTuningPattern(), POSITION_RELATIVE_TOOL::PositionRelativeInteractively(), ROUTER_TOOL::RouteSelected(), DRAWING_TOOL::SetAnchor(), EE_POINT_EDITOR::setEditedPoint(), PL_POINT_EDITOR::setEditedPoint(), PCB_POINT_EDITOR::setEditedPoint(), SCH_DRAWING_TOOLS::SingleClickPlace(), SCH_DRAWING_TOOLS::TwoClickPlace(), SYMBOL_EDITOR_DRAWING_TOOLS::TwoClickPlace(), PNS::TOOL_BASE::updateEndItem(), and PNS::TOOL_BASE::updateStartItem().
|
inline |
Return the current cursor position in world coordinates.
Definition at line 239 of file view_controls.h.
Referenced by EE_POINT_EDITOR::addCorner(), PCB_POINT_EDITOR::addCorner(), EE_POINT_EDITOR::addCornerCondition(), FOOTPRINT_VIEWER_FRAME::AddFootprintToPCB(), SCH_EDIT_TOOL::BreakWire(), PCB_POINT_EDITOR::chamferCorner(), ZONE_CREATE_HELPER::createNewZone(), EDIT_TOOL::DeleteItems(), TOOL_MANAGER::DispatchContextMenu(), EDIT_TOOL::doMoveSelection(), SYMBOL_EDITOR_MOVE_TOOL::doMoveSelection(), SCH_MOVE_TOOL::doMoveSelection(), DRAWING_TOOL::DrawCircle(), DRAWING_TOOL::DrawLine(), MICROWAVE_TOOL::drawMicrowaveInductor(), DRAWING_TOOL::DrawRectangle(), PL_DRAWING_TOOLS::DrawShape(), TOOL_MANAGER::GetCursorPosition(), SCH_EDITOR_CONTROL::HighlightNet(), SCH_DRAWING_TOOLS::ImportGraphics(), SYMBOL_EDITOR_DRAWING_TOOLS::ImportGraphics(), SCH_EDIT_TOOL::Init(), EDIT_TOOL::Init(), ROUTER_TOOL::InlineDrag(), DRAWING_TOOL::InteractivePlaceWithPreview(), EE_POINT_EDITOR::Main(), EE_SELECTION_TOOL::Main(), PICKER_TOOL::Main(), PL_EDIT_TOOL::Main(), PL_POINT_EDITOR::Main(), GERBVIEW_INSPECTION_TOOL::MeasureTool(), COMMON_TOOLS::OnGridChanged(), SCH_EDITOR_CONTROL::Paste(), SYMBOL_EDITOR_DRAWING_TOOLS::PlaceAnchor(), BOARD_EDITOR_CONTROL::PlaceFootprint(), DRAWING_TOOL::PlaceImportedGraphics(), PL_DRAWING_TOOLS::PlaceItem(), DRAWING_TOOL::PlaceReferenceImage(), DRAWING_TOOL::PlaceText(), SCH_EDIT_TOOL::Properties(), EDIT_TOOL::Properties(), SCH_EDIT_TOOL::RepeatDrawItem(), PL_SELECTION_TOOL::RequestSelection(), EE_SELECTION_TOOL::RequestSelection(), COMMON_TOOLS::ResetLocalCoords(), FOOTPRINT_EDIT_FRAME::SaveFootprintToBoard(), EE_SELECTION_TOOL::SelectNode(), ALIGN_DISTRIBUTE_TOOL::selectTarget(), ARC_POINT_EDIT_BEHAVIOR::UpdateItem(), PL_EDIT_TOOL::updateModificationPoint(), SCH_BASE_FRAME::UpdateStatusBar(), GERBVIEW_FRAME::UpdateStatusBar(), PCB_BASE_FRAME::UpdateStatusBar(), and PL_EDITOR_FRAME::UpdateStatusBar().
|
pure virtual |
Return the current cursor position in world coordinates.
aEnableSnapping | selects whether cursor position should be snapped to the grid. |
Implemented in KIGFX::WX_VIEW_CONTROLS, and KIGFX::WX_VIEW_CONTROLS.
|
pure virtual |
Return the current mouse pointer position.
aWorldCoordinates | if true, the result is given in world coordinates, otherwise it is given in screen coordinates. |
Implemented in KIGFX::WX_VIEW_CONTROLS.
Referenced by TOOL_DISPATCHER::DispatchWxEvent(), SCH_LINE_WIRE_BUS_TOOL::doDrawSegments(), SYMBOL_EDITOR_DRAWING_TOOLS::doDrawShape(), EDIT_TOOL::doMoveSelection(), EDIT_TOOL::DragArcTrack(), DRAWING_TOOL::drawArc(), DRAWING_TOOL::DrawDimension(), DRAWING_TOOL::drawOneBezier(), SCH_DRAWING_TOOLS::DrawRuleArea(), SCH_DRAWING_TOOLS::DrawShape(), DRAWING_TOOL::drawShape(), SCH_DRAWING_TOOLS::DrawSheet(), SCH_DRAWING_TOOLS::DrawTable(), DRAWING_TOOL::DrawTable(), DRAWING_TOOL::DrawZone(), PAD_TOOL::EnumeratePads(), TOOL_MANAGER::GetMousePosition(), NL_SCHEMATIC_PLUGIN_IMPL::GetPointerPosition(), NL_GERBVIEW_PLUGIN_IMPL::GetPointerPosition(), NL_PL_EDITOR_PLUGIN_IMPL::GetPointerPosition(), NL_PCBNEW_PLUGIN_IMPL::GetPointerPosition(), SCH_DRAWING_TOOLS::ImportGraphics(), SYMBOL_EDITOR_DRAWING_TOOLS::ImportGraphics(), SCH_DRAWING_TOOLS::ImportSheet(), SYMBOL_EDITOR_EDIT_TOOL::Increment(), EE_POINT_EDITOR::Main(), PCB_PICKER_TOOL::Main(), BOARD_EDITOR_CONTROL::PlaceFootprint(), SCH_DRAWING_TOOLS::PlaceImage(), DRAWING_TOOL::PlaceImportedGraphics(), DRAWING_TOOL::PlaceReferenceImage(), SCH_DRAWING_TOOLS::PlaceSymbol(), DRAWING_TOOL::PlaceText(), DRAWING_TOOL::PlaceTuningPattern(), POSITION_RELATIVE_TOOL::PositionRelativeInteractively(), DRAWING_TOOL::SetAnchor(), SCH_DRAWING_TOOLS::SingleClickPlace(), SCH_DRAWING_TOOLS::SyncSheetsPins(), SCH_DRAWING_TOOLS::TwoClickPlace(), SYMBOL_EDITOR_DRAWING_TOOLS::TwoClickPlace(), PNS::TOOL_BASE::updateStartItem(), DIALOG_IMPORT_NETLIST::~DIALOG_IMPORT_NETLIST(), and DIALOG_UPDATE_PCB::~DIALOG_UPDATE_PCB().
|
pure virtual |
Return the current cursor position in world coordinates ignoring the cursorUp position force mode.
Implemented in KIGFX::WX_VIEW_CONTROLS.
Referenced by COMMON_TOOLS::CursorControl().
|
inline |
Apply VIEW_CONTROLS settings from an object.
Definition at line 374 of file view_controls.h.
Referenced by EDIT_TOOL::doMoveSelection(), TOOL_MANAGER::GetCurrentToolVC(), DIALOG_PAD_PROPERTIES::prepareCanvas(), and TOOL_MANAGER::saveViewControls().
bool VIEW_CONTROLS::IsCursorShown | ( | ) | const |
Return true when cursor is visible.
Definition at line 41 of file view_controls.cpp.
References m_settings, and KIGFX::VC_SETTINGS::m_showCursor.
|
inline |
Definition at line 357 of file view_controls.h.
Referenced by KIGFX::WX_VIEW_CONTROLS::onWheel().
|
inlinevirtual |
Reimplemented in KIGFX::WX_VIEW_CONTROLS.
Definition at line 383 of file view_controls.h.
Referenced by EDA_DRAW_FRAME::CommonSettingsChanged().
|
pure virtual |
Implemented in KIGFX::WX_VIEW_CONTROLS.
Referenced by BOARD_EDITOR_CONTROL::PlaceFootprint(), SCH_DRAWING_TOOLS::PlaceImage(), DRAWING_TOOL::PlaceReferenceImage(), SCH_DRAWING_TOOLS::PlaceSymbol(), DRAWING_TOOL::PlaceText(), SCH_DRAWING_TOOLS::TwoClickPlace(), and SYMBOL_EDITOR_DRAWING_TOOLS::TwoClickPlace().
|
virtual |
Restore the default VIEW_CONTROLS settings.
Return the current VIEW_CONTROLS settings.
Definition at line 50 of file view_controls.cpp.
References ApplySettings(), and KIGFX::dummy().
|
inlinevirtual |
Turn on/off auto panning (this feature is used when there is a tool active (eg.
drawing a track) and user moves mouse to the VIEW edge - then the view can be translated or not).
aEnabled | tells if the autopanning should be active. |
Definition at line 168 of file view_controls.h.
Referenced by ApplySettings(), SCH_LINE_WIRE_BUS_TOOL::doDrawSegments(), SYMBOL_EDITOR_DRAWING_TOOLS::doDrawShape(), PCB_TOOL_BASE::doInteractiveItemPlacement(), EDIT_TOOL::doMoveSelection(), SYMBOL_EDITOR_MOVE_TOOL::doMoveSelection(), EDIT_TOOL::DragArcTrack(), DRAWING_TOOL::drawArc(), DRAWING_TOOL::DrawDimension(), MICROWAVE_TOOL::drawMicrowaveInductor(), DRAWING_TOOL::drawOneBezier(), SCH_DRAWING_TOOLS::DrawRuleArea(), SCH_DRAWING_TOOLS::DrawShape(), PL_DRAWING_TOOLS::DrawShape(), DRAWING_TOOL::drawShape(), SCH_DRAWING_TOOLS::DrawSheet(), SCH_DRAWING_TOOLS::DrawTable(), DRAWING_TOOL::DrawTable(), DRAWING_TOOL::DrawZone(), ROUTER_TOOL::finishInteractive(), SCH_LINE_WIRE_BUS_TOOL::finishSegments(), ROUTER_TOOL::InlineDrag(), EE_POINT_EDITOR::Main(), EE_SELECTION_TOOL::Main(), PL_EDIT_TOOL::Main(), PL_POINT_EDITOR::Main(), GERBVIEW_INSPECTION_TOOL::MeasureTool(), PCB_POINT_EDITOR::OnSelectionChange(), ROUTER_TOOL::performDragging(), ROUTER_TOOL::performRouting(), BOARD_EDITOR_CONTROL::PlaceFootprint(), SCH_DRAWING_TOOLS::PlaceImage(), PL_DRAWING_TOOLS::PlaceItem(), DRAWING_TOOL::PlaceReferenceImage(), SCH_DRAWING_TOOLS::PlaceSymbol(), DRAWING_TOOL::PlaceText(), DRAWING_TOOL::PlaceTuningPattern(), POSITION_RELATIVE_TOOL::PositionRelativeInteractively(), ROUTER_TOOL::prepareInteractive(), PCB_POINT_EDITOR::Reset(), EE_SELECTION_TOOL::selectMultiple(), PL_SELECTION_TOOL::selectMultiple(), PCB_SELECTION_TOOL::selectMultiple(), ZOOM_TOOL::selectRegion(), PCB_SELECTION_TOOL::selectTableCells(), EE_SELECTION_TOOL::selectTableCells(), DRAWING_TOOL::SetAnchor(), PICKER_TOOL::setControls(), PCB_PICKER_TOOL::setControls(), SCH_DRAWING_TOOLS::TwoClickPlace(), and SYMBOL_EDITOR_DRAWING_TOOLS::TwoClickPlace().
|
inlinevirtual |
Set the speed of autopanning.
aSpeed | is a new speed for autopanning. |
Definition at line 198 of file view_controls.h.
|
inlinevirtual |
Set the margin for autopanning (ie.
the area when autopanning becomes active).
aMargin | is a new margin for autopanning. |
Definition at line 208 of file view_controls.h.
Referenced by ApplySettings().
|
inlinevirtual |
Set the speed of autopanning.
aSpeed | is a new speed for autopanning. |
Definition at line 188 of file view_controls.h.
Referenced by ApplySettings().
|
pure virtual |
Move the graphic crosshair cursor to the requested position expressed in world coordinates.
aPosition | is the requested cursor position in the world coordinates. |
aWarpView | enables/disables view warp if the cursor is outside the current viewport. |
Implemented in KIGFX::WX_VIEW_CONTROLS.
Referenced by FOOTPRINT_VIEWER_FRAME::AddFootprintToPCB(), FOOTPRINT_EDITOR_CONTROL::CreateFootprint(), SCH_LINE_WIRE_BUS_TOOL::doUnfoldBus(), EDA_DRAW_FRAME::FocusOnLocation(), FOOTPRINT_EDITOR_CONTROL::ImportFootprint(), FOOTPRINT_EDIT_FRAME::LoadFootprintFromBoard(), FOOTPRINT_EDIT_FRAME::LoadFootprintFromLibrary(), EE_SELECTION_TOOL::Main(), FOOTPRINT_EDITOR_CONTROL::NewFootprint(), COMMON_TOOLS::OnGridChanged(), DIALOG_MIGRATE_BUSES::onItemSelected(), FOOTPRINT_EDIT_FRAME::OpenProjectFiles(), FOOTPRINT_EDIT_FRAME::SaveFootprintToBoard(), and SCH_DRAWING_TOOLS::SingleClickPlace().
|
pure virtual |
Move cursor to the requested position expressed in world coordinates.
The position is not forced and will be overridden with the next mouse motion event. Mouse cursor follows the world cursor.
aPosition | is the requested cursor position in the world coordinates. |
aWarpView | enables/disables view warp if the cursor is outside the current viewport. |
Implemented in KIGFX::WX_VIEW_CONTROLS.
Referenced by COMMON_TOOLS::CursorControl(), EDIT_TOOL::doMoveSelection(), SYMBOL_EDITOR_MOVE_TOOL::doMoveSelection(), ROUTER_TOOL::handleLayerSwitch(), ROUTER_TOOL::InlineDrag(), PL_EDIT_TOOL::Main(), PCB_CONTROL::placeBoardItems(), SCH_DRAWING_TOOLS::PlaceImage(), DRAWING_TOOL::PlaceReferenceImage(), SCH_DRAWING_TOOLS::TwoClickPlace(), SYMBOL_EDITOR_DRAWING_TOOLS::TwoClickPlace(), DIALOG_IMPORT_NETLIST::~DIALOG_IMPORT_NETLIST(), and DIALOG_UPDATE_PCB::~DIALOG_UPDATE_PCB().
|
inlinevirtual |
Turn on/off mouse grabbing.
When the mouse is grabbed, it cannot go outside the VIEW.
aEnabled | tells if mouse should be grabbed or not. |
Definition at line 157 of file view_controls.h.
Referenced by ApplySettings().
|
virtual |
Enable or disables display of cursor.
aEnabled | decides if the cursor should be shown. |
Definition at line 34 of file view_controls.cpp.
References KIGFX::VIEW::GetGAL(), m_settings, KIGFX::VC_SETTINGS::m_showCursor, m_view, and KIGFX::GAL::SetCursorEnabled().
Referenced by ApplySettings(), SCH_LINE_WIRE_BUS_TOOL::doDrawSegments(), SYMBOL_EDITOR_DRAWING_TOOLS::doDrawShape(), PCB_TOOL_BASE::doInteractiveItemPlacement(), EDIT_TOOL::doMoveSelection(), SYMBOL_EDITOR_MOVE_TOOL::doMoveSelection(), EDIT_TOOL::DragArcTrack(), DRAWING_TOOL::drawArc(), DRAWING_TOOL::DrawDimension(), MICROWAVE_TOOL::drawMicrowaveInductor(), DRAWING_TOOL::drawOneBezier(), SCH_DRAWING_TOOLS::DrawRuleArea(), SCH_DRAWING_TOOLS::DrawShape(), PL_DRAWING_TOOLS::DrawShape(), DRAWING_TOOL::drawShape(), SCH_DRAWING_TOOLS::DrawSheet(), SCH_DRAWING_TOOLS::DrawTable(), DRAWING_TOOL::DrawTable(), DRAWING_TOOL::DrawZone(), PAD_TOOL::EnumeratePads(), SCH_DRAWING_TOOLS::ImportGraphics(), SYMBOL_EDITOR_DRAWING_TOOLS::ImportGraphics(), SCH_DRAWING_TOOLS::ImportSheet(), ROUTER_TOOL::InlineDrag(), DRAWING_TOOL::InteractivePlaceWithPreview(), EE_POINT_EDITOR::Main(), PL_EDIT_TOOL::Main(), PL_POINT_EDITOR::Main(), PCB_PICKER_TOOL::Main(), ROUTER_TOOL::MainLoop(), GERBVIEW_INSPECTION_TOOL::MeasureTool(), PCB_POINT_EDITOR::OnSelectionChange(), SYMBOL_EDITOR_DRAWING_TOOLS::PlaceAnchor(), BOARD_EDITOR_CONTROL::PlaceFootprint(), SCH_DRAWING_TOOLS::PlaceImage(), DRAWING_TOOL::PlaceImportedGraphics(), PL_DRAWING_TOOLS::PlaceItem(), DRAWING_TOOL::PlaceReferenceImage(), SCH_DRAWING_TOOLS::PlaceSymbol(), DRAWING_TOOL::PlaceText(), DRAWING_TOOL::PlaceTuningPattern(), POSITION_RELATIVE_TOOL::PositionRelativeInteractively(), ROUTER_TOOL::RouteSelected(), DRAWING_TOOL::SetAnchor(), EE_POINT_EDITOR::setEditedPoint(), PL_POINT_EDITOR::setEditedPoint(), PCB_POINT_EDITOR::setEditedPoint(), SCH_DRAWING_TOOLS::SingleClickPlace(), SCH_DRAWING_TOOLS::TwoClickPlace(), and SYMBOL_EDITOR_DRAWING_TOOLS::TwoClickPlace().
|
pure virtual |
If enabled (.
aPosition | is the position where the cursor should be warped. |
aWorldCoordinates | if true treats aPosition as the world coordinates, otherwise it uses it as the screen coordinates. |
aWarpView | determines if the view can be warped too (only matters if the position is specified in the world coordinates and its not visible in the current viewport). |
Implemented in KIGFX::WX_VIEW_CONTROLS.
Referenced by ZONE_CREATE_HELPER::createNewZone(), TOOL_MANAGER::DispatchContextMenu(), SCH_LINE_WIRE_BUS_TOOL::doDrawSegments(), SCH_DRAWING_TOOLS::DrawRuleArea(), DRAWING_TOOL::drawShape(), DRAWING_TOOL::DrawZone(), EE_SELECTION_TOOL::Main(), ROUTER_TOOL::performRouting(), BOARD_EDITOR_CONTROL::PlaceFootprint(), SCH_DRAWING_TOOLS::PlaceImage(), DRAWING_TOOL::PlaceReferenceImage(), SCH_DRAWING_TOOLS::PlaceSymbol(), DRAWING_TOOL::PlaceText(), SCH_DRAWING_TOOLS::SingleClickPlace(), SCH_DRAWING_TOOLS::TwoClickPlace(), and SYMBOL_EDITOR_DRAWING_TOOLS::TwoClickPlace().
|
protected |
Current VIEW_CONTROLS settings.
Definition at line 390 of file view_controls.h.
Referenced by KIGFX::WX_VIEW_CONTROLS::handleAutoPanning(), KIGFX::WX_VIEW_CONTROLS::SetCursorPosition(), and KIGFX::WX_VIEW_CONTROLS::WX_VIEW_CONTROLS().
|
protected |
Definition at line 393 of file view_controls.h.
Referenced by KIGFX::WX_VIEW_CONTROLS::CancelDrag(), KIGFX::WX_VIEW_CONTROLS::ForceCursorPosition(), KIGFX::WX_VIEW_CONTROLS::GetCursorPosition(), KIGFX::WX_VIEW_CONTROLS::handleAutoPanning(), KIGFX::WX_VIEW_CONTROLS::handleCursorCapture(), IsCursorShown(), KIGFX::WX_VIEW_CONTROLS::LoadSettings(), KIGFX::WX_VIEW_CONTROLS::onButton(), KIGFX::WX_VIEW_CONTROLS::onMotion(), KIGFX::WX_VIEW_CONTROLS::onTimer(), KIGFX::WX_VIEW_CONTROLS::onWheel(), KIGFX::WX_VIEW_CONTROLS::PinCursorInsideNonAutoscrollArea(), KIGFX::WX_VIEW_CONTROLS::SetCursorPosition(), ShowCursor(), and KIGFX::WX_VIEW_CONTROLS::WX_VIEW_CONTROLS().
|
protected |
< Pointer to controlled VIEW.
Application warped the cursor, not the user (keyboard).
Definition at line 387 of file view_controls.h.
Referenced by KIGFX::WX_VIEW_CONTROLS::CenterOnCursor(), KIGFX::WX_VIEW_CONTROLS::GetMousePosition(), KIGFX::WX_VIEW_CONTROLS::GetRawCursorPosition(), KIGFX::WX_VIEW_CONTROLS::handleAutoPanning(), KIGFX::WX_VIEW_CONTROLS::onMagnify(), KIGFX::WX_VIEW_CONTROLS::onMotion(), KIGFX::WX_VIEW_CONTROLS::onPanGesture(), KIGFX::WX_VIEW_CONTROLS::onScroll(), KIGFX::WX_VIEW_CONTROLS::onTimer(), KIGFX::WX_VIEW_CONTROLS::onWheel(), KIGFX::WX_VIEW_CONTROLS::onZoomGesture(), KIGFX::WX_VIEW_CONTROLS::PinCursorInsideNonAutoscrollArea(), KIGFX::WX_VIEW_CONTROLS::refreshMouse(), KIGFX::WX_VIEW_CONTROLS::SetCrossHairCursorPosition(), ShowCursor(), KIGFX::WX_VIEW_CONTROLS::UpdateScrollbars(), and KIGFX::WX_VIEW_CONTROLS::WarpMouseCursor().