OpenCPN Partial API docs
ChartCanvas Class Reference
Inheritance diagram for ChartCanvas:

Public Member Functions

 ChartCanvas (wxFrame *frame, int canvasIndex)
 
void SetupGlCanvas ()
 
void OnKeyDown (wxKeyEvent &event)
 
void OnKeyUp (wxKeyEvent &event)
 
void OnKeyChar (wxKeyEvent &event)
 
void OnPaint (wxPaintEvent &event)
 
void PaintCleanup ()
 
void Scroll (int dx, int dy)
 
void OnToolLeftClick (wxCommandEvent &event)
 
bool MouseEventOverlayWindows (wxMouseEvent &event)
 
bool MouseEventChartBar (wxMouseEvent &event)
 
bool MouseEventMUIBar (wxMouseEvent &event)
 
bool MouseEventToolbar (wxMouseEvent &event)
 
bool MouseEventIENCBar (wxMouseEvent &event)
 
bool MouseEventSetup (wxMouseEvent &event, bool b_handle_dclick=true)
 
bool MouseEventProcessObjects (wxMouseEvent &event)
 
bool MouseEventProcessCanvas (wxMouseEvent &event)
 
void SetCanvasCursor (wxMouseEvent &event)
 
void OnKillFocus (wxFocusEvent &WXUNUSED(event))
 
void OnSetFocus (wxFocusEvent &WXUNUSED(event))
 
void PopupMenuHandler (wxCommandEvent &event)
 
bool IsPrimaryCanvas ()
 
bool SetUserOwnship ()
 
double GetCanvasRangeMeters ()
 
void SetCanvasRangeMeters (double range)
 
void EnablePaint (bool b_enable)
 
virtual bool SetCursor (const wxCursor &c)
 
virtual void Refresh (bool eraseBackground=true, const wxRect *rect=(const wxRect *) NULL)
 
virtual void Update ()
 
void LostMouseCapture (wxMouseCaptureLostEvent &event)
 
void CancelMouseRoute ()
 
void SetDisplaySizeMM (double size)
 
double GetDisplaySizeMM ()
 
bool SetVPScale (double sc, bool b_refresh=true)
 
bool SetVPProjection (int projection)
 
bool SetViewPoint (double lat, double lon)
 
bool SetViewPointByCorners (double latSW, double lonSW, double latNE, double lonNE)
 
bool SetViewPoint (double lat, double lon, double scale_ppm, double skew, double rotation, int projection=0, bool b_adjust=true, bool b_refresh=true)
 
void ReloadVP (bool b_adjust=true)
 
void LoadVP (ViewPort &vp, bool b_adjust=true)
 
ChartStackGetpCurrentStack ()
 
void SetGroupIndex (int index, bool autoswitch=false)
 
bool CheckGroup (int igroup)
 
void canvasRefreshGroupIndex (void)
 
void canvasChartsRefresh (int dbi_hint)
 
void CheckGroupValid (bool showMessage=true, bool switchGroup0=true)
 
void UpdateCanvasS52PLIBConfig ()
 
void TriggerDeferredFocus ()
 
void OnDeferredFocusTimerEvent (wxTimerEvent &event)
 
void OnRouteFinishTimerEvent (wxTimerEvent &event)
 
void ClearS52PLIBStateHash ()
 
void SetupCanvasQuiltMode (void)
 
void ApplyCanvasConfig (canvasConfig *pcc)
 
bool SetVPRotation (double angle)
 
double GetVPRotation (void)
 
double GetVPSkew (void)
 
double GetVPTilt (void)
 
void ClearbFollow (void)
 
void SetbFollow (void)
 
void TogglebFollow (void)
 
void JumpToPosition (double lat, double lon, double scale)
 
void SetFirstAuto (bool b_auto)
 
void GetDoubleCanvasPointPix (double rlat, double rlon, wxPoint2DDouble *r)
 
void GetDoubleCanvasPointPixVP (ViewPort &vp, double rlat, double rlon, wxPoint2DDouble *r)
 
bool GetCanvasPointPix (double rlat, double rlon, wxPoint *r)
 
bool GetCanvasPointPixVP (ViewPort &vp, double rlat, double rlon, wxPoint *r)
 
void GetCanvasPixPoint (double x, double y, double &lat, double &lon)
 
void WarpPointerDeferred (int x, int y)
 
void UpdateShips ()
 
void UpdateAIS ()
 
void UpdateAlerts ()
 
void ToggleCPAWarn ()
 
bool IsMeasureActive ()
 
wxBitmap & GetTideBitmap ()
 
void UnlockQuilt ()
 
void SetQuiltMode (bool b_quilt)
 
bool GetQuiltMode (void)
 
std::vector< int > GetQuiltIndexArray (void)
 
bool IsQuiltDelta (void)
 
void SetQuiltChartHiLiteIndex (int dbIndex)
 
void SetQuiltChartHiLiteIndexArray (std::vector< int > hilite_array)
 
void ClearQuiltChartHiLiteIndexArray ()
 
int GetQuiltReferenceChartIndex (void)
 
double GetBestStartScale (int dbi_hint, const ViewPort &vp)
 
void ConfigureChartBar ()
 
int GetNextContextMenuId ()
 
TCWingetTCWin ()
 
bool StartTimedMovement (bool stoptimer=true)
 
void DoTimedMovement ()
 
void DoMovement (long dt)
 
void StopMovement ()
 
void SetColorScheme (ColorScheme cs)
 
ColorScheme GetColorScheme ()
 
void CanvasApplyLocale ()
 
void RebuildCursors ()
 
int GetCanvasWidth ()
 
int GetCanvasHeight ()
 
float GetVPScale ()
 
float GetVPChartScale ()
 
double GetCanvasScaleFactor ()
 
double GetCanvasTrueScale ()
 
double GetAbsoluteMinScalePpm ()
 
ViewPortGetVP ()
 
ViewPortGetpVP ()
 
void SetVP (ViewPort &)
 
ChartBaseGetChartAtCursor ()
 
ChartBaseGetOverlayChartAtCursor ()
 
PianoGetPiano ()
 
int GetPianoHeight ()
 
bool isRouteEditing (void)
 
bool isMarkEditing (void)
 
GSHHSChartGetWorldBackgroundChart ()
 
void ResetWorldBackgroundChart ()
 
void SetbTCUpdate (bool f)
 
bool GetbTCUpdate ()
 
void SetbShowCurrent (bool f)
 
bool GetbShowCurrent ()
 
void SetbShowTide (bool f)
 
bool GetbShowTide ()
 
void SetShowVisibleSectors (bool val)
 
bool GetShowVisibleSectors ()
 
double GetPixPerMM ()
 
void SetOwnShipState (ownship_state_t state)
 
void SetCursorStatus (double cursor_lat, double cursor_lon)
 
void GetCursorLatLon (double *lat, double *lon)
 
bool PanCanvas (double dx, double dy)
 
void StopAutoPan (void)
 
void ZoomCanvas (double factor, bool can_zoom_to_cursor=true, bool stoptimer=true)
 
void ZoomCanvasSimple (double factor)
 
void DoZoomCanvas (double factor, bool can_zoom_to_cursor=true)
 
void RotateCanvas (double dir)
 
void DoRotateCanvas (double rotation)
 
void DoTiltCanvas (double tilt)
 
void ShowAISTargetList (void)
 
void ShowGoToPosition (void)
 
void HideGlobalToolbar ()
 
void ShowGlobalToolbar ()
 
ChartBaseGetLargestScaleQuiltChart ()
 
ChartBaseGetFirstQuiltChart ()
 
ChartBaseGetNextQuiltChart ()
 
int GetQuiltChartCount ()
 
void InvalidateAllQuiltPatchs (void)
 
void SetQuiltRefChart (int dbIndex)
 
std::vector< int > GetQuiltCandidatedbIndexArray (bool flag1=true, bool flag2=true)
 
std::vector< int > & GetQuiltExtendedStackdbIndexArray ()
 
std::vector< int > & GetQuiltFullScreendbIndexArray ()
 
std::vector< int > GetQuiltEclipsedStackdbIndexArray ()
 
int GetQuiltRefChartdbIndex (void)
 
void InvalidateQuilt (void)
 
double GetQuiltMaxErrorFactor ()
 
bool IsChartQuiltableRef (int db_index)
 
bool IsChartLargeEnoughToRender (ChartBase *chart, ViewPort &vp)
 
int GetCanvasChartNativeScale ()
 
int FindClosestCanvasChartdbIndex (int scale)
 
void UpdateCanvasOnGroupChange (void)
 
void SetUpMode (int mode)
 
void ToggleLookahead ()
 
void SetShowGPS (bool show)
 
void ShowObjectQueryWindow (int x, int y, float zlat, float zlon)
 
void ShowMarkPropertiesDialog (RoutePoint *markPoint)
 
void ShowRoutePropertiesDialog (wxString title, Route *selected)
 
void ShowTrackPropertiesDialog (Track *selected)
 
void DrawTCWindow (int x, int y, void *pIDX)
 
void UpdateGPSCompassStatusBox (bool b_force_new)
 
ocpnCompassGetCompass ()
 
wxColour GetFogColor ()
 
void ShowChartInfoWindow (int x, int dbIndex)
 
void HideChartInfoWindow (void)
 
void ShowCompositeInfoWindow (int x, int n_charts, int scale, const std::vector< int > &index_vector)
 
void StartMeasureRoute ()
 
void CancelMeasureRoute ()
 
bool DoCanvasUpdate (void)
 
void SelectQuiltRefdbChart (int db_index, bool b_autoscale=true)
 
void SelectQuiltRefChart (int selected_index)
 
double GetBestVPScale (ChartBase *pchart)
 
void selectCanvasChartDisplay (int type, int family)
 
void RemoveChartFromQuilt (int dbIndex)
 
void HandlePianoClick (int selected_index, const std::vector< int > &selected_dbIndex_array)
 
void HandlePianoRClick (int x, int y, int selected_index, const std::vector< int > &selected_dbIndex_array)
 
void HandlePianoRollover (int selected_index, const std::vector< int > &selected_dbIndex_array, int n_charts, int scale)
 
void ClearPianoRollover ()
 
void UpdateCanvasControlBar (void)
 
void FormatPianoKeys (void)
 
void PianoPopupMenu (int x, int y, int selected_index, const std::vector< int > &selected_dbIndex_array)
 
void OnPianoMenuDisableChart (wxCommandEvent &event)
 
void OnPianoMenuEnableChart (wxCommandEvent &event)
 
bool IsPianoContextMenuActive ()
 
bool DoCanvasCOGSet (void)
 
void UpdateFollowButtonState (void)
 
void ApplyGlobalSettings ()
 
void SetShowGPSCompassWindow (bool bshow)
 
void FreezePiano ()
 
void ThawPiano ()
 
void DrawBlinkObjects (void)
 
void StartRoute (void)
 
void FinishRoute (void)
 
void InvalidateGL ()
 
void JaggyCircle (ocpnDC &dc, wxPen pen, int x, int y, int radius)
 
bool CheckEdgePan (int x, int y, bool bdragging, int margin, int delta)
 
wxString FindValidUploadPort ()
 
int GetMinAvailableGshhgQuality ()
 
int GetMaxAvailableGshhgQuality ()
 
RouteGetSelectedRoute () const
 
TrackGetSelectedTrack () const
 
RoutePointGetSelectedRoutePoint () const
 
void SetAISCanvasDisplayStyle (int StyleIndx)
 
void TouchAISToolActive (void)
 
void UpdateAISTBTool (void)
 
void SelectChartFromStack (int index, bool bDir=false, ChartTypeEnum New_Type=CHART_TYPE_DONTCARE, ChartFamilyEnum New_Family=CHART_FAMILY_DONTCARE)
 
void SelectdbChart (int dbindex)
 
void ShowTides (bool bShow)
 
void ShowCurrents (bool bShow)
 
void DoCanvasStackDelta (int direction)
 
void ProcessNewGUIScale ()
 
bool GetShowDepthUnits ()
 
void SetShowDepthUnits (bool show)
 
bool GetShowGrid ()
 
void SetShowGrid (bool show)
 
bool GetShowOutlines ()
 
void SetShowOutlines (bool show)
 
bool GetShowChartbar ()
 
wxRect GetMUIBarRect ()
 
void SetMUIBarPosition ()
 
void DestroyMuiBar ()
 
void CreateMUIBar ()
 
void ToggleChartOutlines (void)
 
void ToggleCanvasQuiltMode (void)
 
wxString GetScaleText ()
 
double GetScaleValue ()
 
bool GetShowENCText ()
 
void SetShowENCText (bool show)
 
bool GetShowENCDepth ()
 
void SetShowENCDepth (bool show)
 
bool GetShowENCLightDesc ()
 
void SetShowENCLightDesc (bool show)
 
bool GetShowENCBuoyLabels ()
 
void SetShowENCBuoyLabels (bool show)
 
bool GetShowENCLights ()
 
void SetShowENCLights (bool show)
 
int GetENCDisplayCategory ()
 
void SetENCDisplayCategory (int category)
 
bool GetShowENCAnchor ()
 
void SetShowENCAnchor (bool show)
 
bool GetShowENCDataQual ()
 
void SetShowENCDataQual (bool show)
 
int GetUpMode ()
 
bool GetLookahead ()
 
bool GetShowAIS ()
 
void SetShowAIS (bool show)
 
bool GetAttenAIS ()
 
void SetAttenAIS (bool show)
 
MUIBarGetMUIBar ()
 
void SetAlertString (wxString str)
 
wxString GetAlertString ()
 
wxRect GetScaleBarRect ()
 
void RenderAlertMessage (wxDC &dc, const ViewPort &vp)
 
bool IsTileOverlayIndexInYesShow (int index)
 
bool IsTileOverlayIndexInNoShow (int index)
 
void AddTileOverlayIndexToNoShow (int index)
 
std::vector< int > GetQuiltNoshowIindexArray ()
 
double GetDisplayScale ()
 

Public Attributes

bool m_bFollow
 
wxCursor * pCursorPencil
 
wxCursor * pCursorArrow
 
wxCursor * pCursorCross
 
wxCursor * pPlugIn_Cursor
 
TCWinpCwin
 
wxBitmap * pscratch_bm
 
bool m_brepaint_piano
 
double m_cursor_lon
 
double m_cursor_lat
 
Undoundo
 
wxPoint r_rband
 
double m_prev_rlat
 
double m_prev_rlon
 
RoutePointm_prev_pMousePoint
 
Quiltm_pQuilt
 
bool m_bShowNavobjects
 
int m_canvasIndex
 
int m_groupIndex
 
int m_routeState
 
ChartBasem_singleChart
 
int m_upMode
 
bool m_bLookAhead
 
double m_VPRotate
 
Routem_pMouseRoute
 
bool m_FinishRouteOnKillFocus
 
bool m_bMeasure_Active
 
bool m_bMeasure_DistCircle
 
wxString m_active_upload_port
 
bool m_bAppendingRoute
 
int m_nMeasureState
 
Routem_pMeasureRoute
 
MyFrameparent_frame
 
CanvasMenuHandlerm_canvasMenu
 
bool m_b_paint_enable
 
std::vector< int > m_tile_noshow_index_array
 
std::vector< int > m_tile_yesshow_index_array
 
std::vector< int > m_quilt_noshow_index_array
 

Friends

class glChartCanvas
 

Detailed Description

Definition at line 131 of file chcanv.h.

Member Function Documentation

◆ MouseEventSetup()

bool ChartCanvas::MouseEventSetup ( wxMouseEvent &  event,
bool  b_handle_dclick = true 
)

g_btouch

Definition at line 7129 of file chcanv.cpp.


The documentation for this class was generated from the following files: