OpenCPN Partial API docs
|
Represents a compass display in the OpenCPN navigation system. More...
#include <compass.h>
Public Member Functions | |
ocpnCompass (ChartCanvas *parent, bool bShowGPS=true) | |
bool | IsShown () const |
void | Show (bool show) |
void | Paint (ocpnDC &dc) |
void | UpdateStatus (bool newColorScheme=false) |
bool | MouseEvent (wxMouseEvent &event) |
void | SetColorScheme (ColorScheme cs) |
int | GetXOffset (void) const |
int | GetYOffset (void) const |
float | GetScaleFactor () |
void | SetScaleFactor (float factor) |
void | Move (const wxPoint &pt) |
wxRect | GetRect (void) const |
Return the coordinates of the compass widget, in physical pixels relative to the canvas window. | |
wxRect | GetLogicalRect (void) const |
Return the coordinates of the compass widget, in logical pixels. | |
Represents a compass display in the OpenCPN navigation system.
The ocpnCompass class provides a visual compass display for the OpenCPN application. It shows the current heading and, optionally, GPS status. This compass is typically displayed as an overlay on the main chart view.
ocpnCompass::ocpnCompass | ( | ChartCanvas * | parent, |
bool | bShowGPS = true |
||
) |
Definition at line 43 of file compass.cpp.
ocpnCompass::~ocpnCompass | ( | ) |
Definition at line 71 of file compass.cpp.
wxRect ocpnCompass::GetLogicalRect | ( | void | ) | const |
Return the coordinates of the compass widget, in logical pixels.
This can be compared with data returned from wxWidgets APIs.
Definition at line 193 of file compass.cpp.
|
inline |
bool ocpnCompass::MouseEvent | ( | wxMouseEvent & | event | ) |
Definition at line 166 of file compass.cpp.
void ocpnCompass::Paint | ( | ocpnDC & | dc | ) |
Definition at line 82 of file compass.cpp.
void ocpnCompass::SetColorScheme | ( | ColorScheme | cs | ) |
Definition at line 188 of file compass.cpp.
void ocpnCompass::SetScaleFactor | ( | float | factor | ) |
Definition at line 222 of file compass.cpp.
void ocpnCompass::UpdateStatus | ( | bool | newColorScheme = false | ) |
Definition at line 212 of file compass.cpp.