Search for usage in LXR

#include <skymaplite.h>

Inheritance diagram for SkyMapLite:


bool automaticMode
bool centerLocked
QStringList FOVSymbols
double magLim
double skyRotation
bool slewing
- Properties inherited from QQuickItem
- Properties inherited from QObject


void automaticModeChanged (bool)
void centerLockedChanged (bool)
void destinationChanged ()
void magLimChanged (double magLim)
void mousePointChanged (SkyPoint *)
void objectChanged ()
void objectLiteChanged ()
void pointLiteChanged ()
void posClicked (QPointF pos)
void positionChanged ()
void positionClicked (SkyPoint *)
void skyRotationChanged (double skyRotation)
void slewingChanged (bool)
void symbolsFOVChanged (QStringList)
void zoomChanged ()

Public Slots

void forceUpdate ()
void forceUpdateNow ()
void resizeItem ()
void setSkyRotation (double skyRotation)
void slewFocus ()
void slotCenter ()
void slotClockSlewing ()
void slotSelectObject (SkyObject *skyObj)
void slotUpdateSky (bool now)
void slotZoomDefault ()
void slotZoomIn ()
void slotZoomOut ()
void updateAutomaticMode ()

Public Member Functions

 ~SkyMapLite ()
Q_INVOKABLE void addFOVSymbol (const QString &FOVName, bool initialState=false)
SkyObjectclickedObject () const
SkyPointclickedPoint ()
void deleteSkyNode (SkyNode *skyNode)
SkyPointdestination ()
SkyPointfocus ()
SkyObjectfocusObject () const
SkyPointfocusPoint ()
bool getAutomaticMode () const
QSGTexturegetCachedTexture (int size, char spType)
bool getCenterLocked ()
SkyObjectLitegetClickedObjectLite ()
SkyPointLitegetClickedPointLite ()
Q_INVOKABLE QStringList getFOVSymbols ()
QVector< QVector< QPixmap * > > getImageCache ()
double getMagLim ()
double getSkyRotation () const
bool getSlewing () const
int harvardToIndex (char c)
void initialize (QQuickItem *parent)
void initStarImages ()
bool isFOVVisible (int index)
bool isSlewing () const
void loadingFinished ()
const Projectorprojector () const
Q_INVOKABLE uint projType () const
Q_INVOKABLE void setAutomaticMode (bool automaticMode)
void setCenterLocked (bool centerLocked)
void setClickedObject (SkyObject *o)
void setClickedPoint (SkyPoint *f)
void setDestination (const dms &ra, const dms &dec)
void setDestination (const SkyPoint &f)
void setDestinationAltAz (const dms &alt, const dms &az, bool altIsRefracted)
void setFocus (const dms &ra, const dms &dec)
void setFocus (SkyPoint *f)
void setFocusAltAz (const dms &alt, const dms &az)
void setFocusObject (SkyObject *o)
void setFocusPoint (SkyPoint *f)
Q_INVOKABLE void setFOVVisible (int index, bool visible)
void setMagLim (double magLim)
void setSizeMagLim (float sizeMagLim)
void setSlewing (bool newSlewing)
void setupProjector ()
void setZoomFactor (double factor)
float sizeMagLim () const
void stopTracking ()
QSGTexturetextToTexture (QString text, QColor color=QColor(255, 255, 255), bool zoomFont=false)
void updateFocus ()
- Public Member Functions inherited from QQuickItem
 QQuickItem (QQuickItem *parent)
Qt::MouseButtons acceptedMouseButtons () const const
bool acceptHoverEvents () const const
bool acceptTouchEvents () const const
void activeFocusChanged (bool)
bool activeFocusOnTab () const const
void activeFocusOnTabChanged (bool)
bool antialiasing () const const
void antialiasingChanged (bool)
qreal baselineOffset () const const
void baselineOffsetChanged (qreal)
QBindable< qreal > bindableHeight ()
QBindable< qreal > bindableWidth ()
QBindable< qreal > bindableX ()
QBindable< qreal > bindableY ()
virtual QRectF boundingRect () const const
QQuickItemchildAt (qreal x, qreal y) const const
QList< QQuickItem * > childItems () const const
QRectF childrenRect ()
void childrenRectChanged (const QRectF &)
bool clip () const const
void clipChanged (bool)
virtual QRectF clipRect () const const
QObjectcontainmentMask () const const
void containmentMaskChanged ()
virtual bool contains (const QPointF &point) const const
QCursor cursor () const const
void dumpItemTree () const const
void enabledChanged ()
void ensurePolished ()
bool filtersChildMouseEvents () const const
Flags flags () const const
void focusChanged (bool)
void forceActiveFocus ()
void forceActiveFocus (Qt::FocusReason reason)
void grabMouse ()
QSharedPointer< QQuickItemGrabResultgrabToImage (const QSize &targetSize)
void grabTouchPoints (const QList< int > &ids)
bool hasActiveFocus () const const
bool hasFocus () const const
qreal height () const const
void heightChanged ()
qreal implicitHeight () const const
void implicitHeightChanged ()
qreal implicitWidth () const const
void implicitWidthChanged ()
virtual QVariant inputMethodQuery (Qt::InputMethodQuery query) const const
bool isAncestorOf (const QQuickItem *child) const const
bool isEnabled () const const
bool isFocusScope () const const
virtual bool isTextureProvider () const const
bool isVisible () const const
bool keepMouseGrab () const const
bool keepTouchGrab () const const
QPointF mapFromGlobal (const QPointF &point) const const
QPointF mapFromItem (const QQuickItem *item, const QPointF &point) const const
QPointF mapFromScene (const QPointF &point) const const
QRectF mapRectFromItem (const QQuickItem *item, const QRectF &rect) const const
QRectF mapRectFromScene (const QRectF &rect) const const
QRectF mapRectToItem (const QQuickItem *item, const QRectF &rect) const const
QRectF mapRectToScene (const QRectF &rect) const const
QPointF mapToGlobal (const QPointF &point) const const
QPointF mapToItem (const QQuickItem *item, const QPointF &point) const const
QPointF mapToScene (const QPointF &point) const const
QQuickItemnextItemInFocusChain (bool forward)
qreal opacity () const const
void opacityChanged ()
void parentChanged (QQuickItem *)
QQuickItemparentItem () const const
void polish ()
void resetAntialiasing ()
void resetHeight ()
void resetWidth ()
qreal rotation () const const
void rotationChanged ()
qreal scale () const const
void scaleChanged ()
QQuickItemscopedFocusItem () const const
void setAcceptedMouseButtons (Qt::MouseButtons buttons)
void setAcceptHoverEvents (bool enabled)
void setAcceptTouchEvents (bool enabled)
void setActiveFocusOnTab (bool)
void setAntialiasing (bool)
void setBaselineOffset (qreal)
void setClip (bool)
void setContainmentMask (QObject *mask)
void setCursor (const QCursor &cursor)
void setEnabled (bool)
void setFiltersChildMouseEvents (bool filter)
void setFlag (Flag flag, bool enabled)
void setFlags (Flags flags)
void setFocus (bool focus, Qt::FocusReason reason)
void setFocus (bool)
void setHeight (qreal)
void setImplicitHeight (qreal)
void setImplicitWidth (qreal)
void setKeepMouseGrab (bool keep)
void setKeepTouchGrab (bool keep)
void setOpacity (qreal)
void setParentItem (QQuickItem *parent)
void setRotation (qreal)
void setScale (qreal)
void setSize (const QSizeF &size)
void setSmooth (bool)
void setState (const QString &)
void setTransformOrigin (TransformOrigin)
void setVisible (bool)
void setWidth (qreal)
void setX (qreal)
void setY (qreal)
void setZ (qreal)
QSizeF size () const const
bool smooth () const const
void smoothChanged (bool)
void stackAfter (const QQuickItem *sibling)
void stackBefore (const QQuickItem *sibling)
QString state () const const
void stateChanged (const QString &)
virtual QSGTextureProvidertextureProvider () const const
TransformOrigin transformOrigin () const const
void transformOriginChanged (TransformOrigin)
void ungrabMouse ()
void ungrabTouchPoints ()
void unsetCursor ()
void update ()
QQuickItemviewportItem () const const
void visibleChanged ()
qreal width () const const
void widthChanged ()
QQuickWindowwindow () const const
void windowChanged (QQuickWindow *window)
qreal x () const const
void xChanged ()
qreal y () const const
void yChanged ()
qreal z () const const
void zChanged ()
- Public Member Functions inherited from QObject
 QObject (QObject *parent)
QBindable< QStringbindableObjectName ()
bool blockSignals (bool block)
const QObjectListchildren () const const
QMetaObject::Connection connect (const QObject *sender, const char *signal, const char *method, Qt::ConnectionType type) const const
void deleteLater ()
void destroyed (QObject *obj)
bool disconnect (const char *signal, const QObject *receiver, const char *method) const const
bool disconnect (const QObject *receiver, const char *method) const const
void dumpObjectInfo () const const
void dumpObjectTree () const const
QList< QByteArraydynamicPropertyNames () const const
virtual bool eventFilter (QObject *watched, QEvent *event)
findChild (const QString &name, Qt::FindChildOptions options) const const
QList< T > findChildren (const QRegularExpression &re, Qt::FindChildOptions options) const const
QList< T > findChildren (const QString &name, Qt::FindChildOptions options) const const
QList< T > findChildren (Qt::FindChildOptions options) const const
bool inherits (const char *className) const const
void installEventFilter (QObject *filterObj)
bool isQuickItemType () const const
bool isWidgetType () const const
bool isWindowType () const const
void killTimer (int id)
virtual const QMetaObjectmetaObject () const const
void moveToThread (QThread *targetThread)
QString objectName () const const
void objectNameChanged (const QString &objectName)
QObjectparent () const const
QVariant property (const char *name) const const
 Q_CLASSINFO (Name, Value)
 Q_ENUM (...)
 Q_ENUM_NS (...)
 Q_ENUMS (...)
 Q_FLAG (...)
 Q_FLAG_NS (...)
 Q_FLAGS (...)
qobject_cast (const QObject *object)
qobject_cast (QObject *object)
void removeEventFilter (QObject *obj)
void setObjectName (const QString &name)
void setObjectName (QAnyStringView name)
void setParent (QObject *parent)
bool setProperty (const char *name, const QVariant &value)
bool setProperty (const char *name, QVariant &&value)
bool signalsBlocked () const const
int startTimer (int interval, Qt::TimerType timerType)
int startTimer (std::chrono::milliseconds interval, Qt::TimerType timerType)
QThreadthread () const const

Static Public Member Functions

static SkyMapLitecreateInstance ()
static double deleteLimit ()
static SkyMapLiteInstance ()
static bool IsSlewing ()
static RootNoderootNode ()
static void setRootNode (RootNode *root)
- Static Public Member Functions inherited from QObject
QMetaObject::Connection connect (const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type)
QMetaObject::Connection connect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method, Qt::ConnectionType type)
QMetaObject::Connection connect (const QObject *sender, PointerToMemberFunction signal, const QObject *context, Functor functor, Qt::ConnectionType type)
QMetaObject::Connection connect (const QObject *sender, PointerToMemberFunction signal, const QObject *receiver, PointerToMemberFunction method, Qt::ConnectionType type)
QMetaObject::Connection connect (const QObject *sender, PointerToMemberFunction signal, Functor functor)
bool disconnect (const QMetaObject::Connection &connection)
bool disconnect (const QObject *sender, const char *signal, const QObject *receiver, const char *method)
bool disconnect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method)
bool disconnect (const QObject *sender, PointerToMemberFunction signal, const QObject *receiver, PointerToMemberFunction method)
QString tr (const char *sourceText, const char *disambiguation, int n)

Protected Member Functions

virtual void mouseDoubleClickEvent (QMouseEvent *e) override
virtual void mouseMoveEvent (QMouseEvent *e) override
virtual void mousePressEvent (QMouseEvent *e) override
virtual void mouseReleaseEvent (QMouseEvent *e) override
virtual void touchEvent (QTouchEvent *e) override
virtual QSGNodeupdatePaintNode (QSGNode *oldNode, UpdatePaintNodeData *updatePaintNodeData) override
virtual void wheelEvent (QWheelEvent *e) override
- Protected Member Functions inherited from QQuickItem
virtual bool childMouseEventFilter (QQuickItem *item, QEvent *event)
virtual void classBegin () override
virtual void componentComplete () override
virtual void dragEnterEvent (QDragEnterEvent *event)
virtual void dragLeaveEvent (QDragLeaveEvent *event)
virtual void dragMoveEvent (QDragMoveEvent *event)
virtual void dropEvent (QDropEvent *event)
virtual bool event (QEvent *ev) override
virtual void focusInEvent (QFocusEvent *)
virtual void focusOutEvent (QFocusEvent *)
virtual void geometryChange (const QRectF &newGeometry, const QRectF &oldGeometry)
bool heightValid () const const
virtual void hoverEnterEvent (QHoverEvent *event)
virtual void hoverLeaveEvent (QHoverEvent *event)
virtual void hoverMoveEvent (QHoverEvent *event)
virtual void inputMethodEvent (QInputMethodEvent *event)
bool isComponentComplete () const const
virtual void itemChange (ItemChange change, const ItemChangeData &value)
virtual void keyPressEvent (QKeyEvent *event)
virtual void keyReleaseEvent (QKeyEvent *event)
virtual void mouseUngrabEvent ()
virtual void releaseResources ()
virtual void touchUngrabEvent ()
void updateInputMethod (Qt::InputMethodQueries queries)
virtual void updatePolish ()
bool widthValid () const const
- Protected Member Functions inherited from QObject
virtual void childEvent (QChildEvent *event)
virtual void connectNotify (const QMetaMethod &signal)
virtual void customEvent (QEvent *event)
virtual void disconnectNotify (const QMetaMethod &signal)
bool isSignalConnected (const QMetaMethod &signal) const const
int receivers (const char *signal) const const
QObjectsender () const const
int senderSignalIndex () const const
virtual void timerEvent (QTimerEvent *event)

Additional Inherited Members

- Public Types inherited from QQuickItem
enum  Flag
enum  ItemChange
enum  TransformOrigin
- Public Attributes inherited from QQuickItem
typedef Flags
- Public Attributes inherited from QObject
typedef QObjectList

Detailed Description

This is the main item that displays all SkyItems.

After its instantiation it is reparanted to an object with objectName SkyMapLiteWrapper in main.qml. To display SkyItems they are reparanted to instance of SkyMapLite.

SkyMapLite handles most user interaction events (both mouse and keyboard).

Item for displaying sky objects; also handles user interaction events.

Artem Fedoskin

Definition at line 58 of file skymaplite.h.

Property Documentation

◆ automaticMode

bool SkyMapLite::automaticMode

Definition at line 75 of file skymaplite.h.

◆ centerLocked

bool SkyMapLite::centerLocked

true if SkyMapLite is centered on an object and only pinch-to-zoom needs to be available

Definition at line 74 of file skymaplite.h.

◆ clickedObjectLite

SkyObjectLite * SkyMapLite::clickedObjectLite

Definition at line 66 of file skymaplite.h.

◆ clickedPointLite

SkyPointLite * SkyMapLite::clickedPointLite

wrappers for clickedPoint and clickedObject.

Used to set clicked object and point from QML

Definition at line 65 of file skymaplite.h.

◆ FOVSymbols

QStringList SkyMapLite::FOVSymbols

list of FOVSymbols that are currently available

Definition at line 68 of file skymaplite.h.

◆ magLim

double SkyMapLite::magLim

magnitude limit.

Used in QML

Definition at line 62 of file skymaplite.h.

◆ skyRotation

double SkyMapLite::skyRotation

Definition at line 76 of file skymaplite.h.

◆ slewing

bool SkyMapLite::slewing

true if SkyMapLite is being panned

Definition at line 70 of file skymaplite.h.

Constructor & Destructor Documentation

◆ SkyMapLite()

SkyMapLite::SkyMapLite ( )

Definition at line 91 of file skymaplite.cpp.

◆ ~SkyMapLite()

SkyMapLite::~SkyMapLite ( )


Clear star images.

Definition at line 241 of file skymaplite.cpp.

Member Function Documentation

◆ addFOVSymbol()

void SkyMapLite::addFOVSymbol ( const QString & FOVName,
bool initialState = false )

adds FOV symbol to m_FOVSymbols

FOVNamename of a FOV symbol
initialStatedefines whether the state is initial

Definition at line 919 of file skymaplite.cpp.

◆ clickedObject()

SkyObject * SkyMapLite::clickedObject ( ) const

Retrieve the object nearest to a mouse click event.

If the user clicks on the sky map, a pointer to the nearest SkyObject is stored in the private member ClickedObject. This function returns the ClickedObject pointer, or nullptr if there is no CLickedObject.

a pointer to the object nearest to a user mouse click.

Definition at line 234 of file skymaplite.h.

◆ clickedPoint()

SkyPoint * SkyMapLite::clickedPoint ( )

Retrieve the ClickedPoint position.

When the user clicks on a point in the sky map, the sky coordinates of the mouse cursor are stored in the private member ClickedPoint. This function retrieves a pointer to ClickedPoint.

a pointer to ClickedPoint, the sky coordinates where the user clicked.

Definition at line 217 of file skymaplite.h.

◆ createInstance()

SkyMapLite * SkyMapLite::createInstance ( )

Creates instance of SkyMapLite (delete the old one if any)

Definition at line 215 of file skymaplite.cpp.

◆ deleteLimit()

double SkyMapLite::deleteLimit ( )

return limit of hides for the node to delete it

Definition at line 199 of file skymaplite.cpp.

◆ deleteSkyNode()

void SkyMapLite::deleteSkyNode ( SkyNode * skyNode)

skyNode will be deleted on the next call to updatePaintNode (currently used only in StarNode(struct in StarBlock))

Definition at line 205 of file skymaplite.cpp.

◆ destination()

SkyPoint * SkyMapLite::destination ( )

retrieve the Destination position.

The Destination is the point on the sky to which the focus will be moved.

a pointer to the destination point of the sky map

Definition at line 135 of file skymaplite.h.

◆ destinationChanged

void SkyMapLite::destinationChanged ( )

Emitted by setDestination(), and connected to slewFocus().

Whenever the Destination point is changed, slewFocus() will iteratively step the Focus toward Destination until it is reached.

See also

◆ focus()

SkyPoint * SkyMapLite::focus ( )

Retrieve the Focus point; the position on the sky at the center of the skymap.

a pointer to the central focus point of the sky map

Definition at line 125 of file skymaplite.h.

◆ focusObject()

SkyObject * SkyMapLite::focusObject ( ) const

Retrieve the object which is centered in the sky map.

If the user centers the sky map on an object (by double-clicking or using the Find Object dialog), a pointer to the "focused" object is stored in the private member FocusObject. This function returns a pointer to the FocusObject, or nullptr if there is not FocusObject.

a pointer to the object at the center of the sky map.

Definition at line 252 of file skymaplite.h.

◆ focusPoint()

SkyPoint * SkyMapLite::focusPoint ( )

retrieve the FocusPoint position.

The FocusPoint stores the position on the sky that is to be focused next. This is not exactly the same as the Destination point, because when the Destination is set, it will begin slewing immediately.

a pointer to the sky point which is to be focused next.

Definition at line 149 of file skymaplite.h.

◆ forceUpdate

void SkyMapLite::forceUpdate ( )

Recalculates the positions of objects in the sky, and then repaints the sky map.

Definition at line 639 of file skymaplite.cpp.

◆ forceUpdateNow

void SkyMapLite::forceUpdateNow ( )

Left for compatibility reasons.

See also

Definition at line 466 of file skymaplite.h.

◆ getAutomaticMode()

bool SkyMapLite::getAutomaticMode ( ) const

True if automatic mode is on (SkyMapLite is controlled by smartphones accelerometer magnetometer)

Definition at line 438 of file skymaplite.h.

◆ getCachedTexture()

QSGTexture * SkyMapLite::getCachedTexture ( int size,
char spType )

returns cached texture from textureCache.

Use outside of scene graph rendering thread (e.g. not during call to updatePaintNode) is prohibited!

sizesize of the star
spTypespectral class
cached QSGTexture from textureCache

Definition at line 210 of file skymaplite.cpp.

◆ getCenterLocked()

bool SkyMapLite::getCenterLocked ( )

getter for centerLocked

Definition at line 409 of file skymaplite.h.

◆ getClickedObjectLite()

SkyObjectLite * SkyMapLite::getClickedObjectLite ( )

getter for clickedObjectLite

Definition at line 401 of file skymaplite.h.

◆ getClickedPointLite()

SkyPointLite * SkyMapLite::getClickedPointLite ( )

getter for clickedPointLite

Definition at line 393 of file skymaplite.h.

◆ getFOVSymbols()

Q_INVOKABLE QStringList SkyMapLite::getFOVSymbols ( )

this QList should be used as a model in QML to switch on/off FOV symbols

Definition at line 382 of file skymaplite.h.

◆ getImageCache()

QVector< QVector< QPixmap * > > SkyMapLite::getImageCache ( )

returns cache of star images

star images cache

Definition at line 844 of file skymaplite.cpp.

◆ getMagLim()

double SkyMapLite::getMagLim ( )
current magnitude limit

Definition at line 310 of file skymaplite.h.

◆ getSkyRotation()

double SkyMapLite::getSkyRotation ( ) const

Definition at line 448 of file skymaplite.h.

◆ getSlewing()

bool SkyMapLite::getSlewing ( ) const

Proxy method for SkyMapDrawAbstract::drawObjectLabels()

true if SkyMapLite is being slewed

Definition at line 422 of file skymaplite.h.

◆ harvardToIndex()

int SkyMapLite::harvardToIndex ( char c)

Returns index for a Harvard spectral classification.

Definition at line 810 of file skymaplite.cpp.

◆ initialize()

void SkyMapLite::initialize ( QQuickItem * parent)

Bind size to parent's size and initialize star images.

Definition at line 222 of file skymaplite.cpp.

◆ initStarImages()

void SkyMapLite::initStarImages ( )

Initializes images of Stars and puts them in cache (copied from SkyQPainter)

Definition at line 996 of file skymaplite.cpp.

◆ Instance()

static SkyMapLite * SkyMapLite::Instance ( )

Definition at line 99 of file skymaplite.h.

◆ isFOVVisible()

bool SkyMapLite::isFOVVisible ( int index)
indexof FOVSymbol in m_FOVSymbols
true if FOV symbol with name FOVName should be drawn.

Definition at line 928 of file skymaplite.cpp.

◆ IsSlewing()

static bool SkyMapLite::IsSlewing ( )

Definition at line 104 of file skymaplite.h.

◆ isSlewing()

bool SkyMapLite::isSlewing ( ) const
true if the map is in slewing mode or clock is active

Definition at line 805 of file skymaplite.cpp.

◆ loadingFinished()

void SkyMapLite::loadingFinished ( )

called when SkyMapComposite finished loading all SkyComponents

Definition at line 301 of file skymaplite.h.

◆ magLimChanged

void SkyMapLite::magLimChanged ( double magLim)

Emitted when magnitude limit is changed.

◆ mouseDoubleClickEvent()

void SkyMapLite::mouseDoubleClickEvent ( QMouseEvent * e)

Center SkyMap at double-clicked location

Reimplemented from QQuickItem.

Definition at line 138 of file skymapliteevents.cpp.

◆ mouseMoveEvent()

void SkyMapLite::mouseMoveEvent ( QMouseEvent * e)

This function does several different things depending on the state of the program:

  • If Angle-measurement mode is active, update the end-ruler point to the mouse cursor, and continue this function.
  • If we are defining a ZoomBox, update the ZoomBox rectangle, redraw the screen, and return.
  • If dragging the mouse in the map, update focus such that RA, Dec under the mouse cursor remains constant.
  • If just moving the mouse, simply update the curso coordinates in the status bar.

Reimplemented from QQuickItem.

Definition at line 148 of file skymapliteevents.cpp.

◆ mousePointChanged

void SkyMapLite::mousePointChanged ( SkyPoint * )

Emitted when position under mouse changed.

◆ mousePressEvent()

void SkyMapLite::mousePressEvent ( QMouseEvent * e)

Process keystrokes:

  • arrow keys Slew the map
  • +/- keys Zoom in and out
  • Space Toggle between Horizontal and Equatorial coordinate systems
  • 0-9 Go to a major Solar System body (0=Sun; 1-9 are the major planets, except 3=Moon)
  • [ Place starting point for measuring an angular distance
  • ] End point for Angular Distance; display measurement.
  • Escape Cancel Angular measurement
  • ,/< Step backward one time step
  • ./> Step forward one time step When keyRelease is triggered, just set the "slewing" flag to false, and update the display (to draw objects that are hidden when slewing==true). Determine RA, Dec coordinates of clicked location. Find the SkyObject which is nearest to the clicked location.

If left-clicked: Set set mouseButtonDown==true, slewing==true; display nearest object name in status bar. If right-clicked: display popup menu appropriate for nearest object.

Reimplemented from QQuickItem.

Definition at line 21 of file skymapliteevents.cpp.

◆ mouseReleaseEvent()

void SkyMapLite::mouseReleaseEvent ( QMouseEvent * e)

set mouseButtonDown==false, slewing==false

Reimplemented from QQuickItem.

Definition at line 100 of file skymapliteevents.cpp.

◆ objectChanged

void SkyMapLite::objectChanged ( )

Emitted when current object changed.

◆ objectLiteChanged

void SkyMapLite::objectLiteChanged ( )

Wrapper of ClickedObject for QML.

◆ pointLiteChanged

void SkyMapLite::pointLiteChanged ( )

Wrapper of ClickedPoint for QML.

◆ posClicked

void SkyMapLite::posClicked ( QPointF pos)

Emitted when user clicks on SkyMapLite (analogous to positionClicked but sends QPoint)

◆ positionChanged

void SkyMapLite::positionChanged ( )

Emitted when pointing changed.

(At least should)

◆ positionClicked

void SkyMapLite::positionClicked ( SkyPoint * )

Emitted when a position is clicked.

◆ projector()

const Projector * SkyMapLite::projector ( ) const

Get the current projector.

a pointer to the current projector.

Definition at line 323 of file skymaplite.h.

◆ projType()

uint SkyMapLite::projType ( ) const

used in QML

type of current projection system

Definition at line 524 of file skymapliteevents.cpp.

◆ resizeItem

void SkyMapLite::resizeItem ( )

Called whenever wrappers' width or height are changed.

Probably will be used to update positions of items.

Definition at line 565 of file skymaplite.cpp.

◆ rootNode()

static RootNode * SkyMapLite::rootNode ( )

Definition at line 346 of file skymaplite.h.

◆ setAutomaticMode()

void SkyMapLite::setAutomaticMode ( bool automaticMode)

switch automatic mode on/off according to isOn parameter

Definition at line 957 of file skymaplite.cpp.

◆ setCenterLocked()

void SkyMapLite::setCenterLocked ( bool centerLocked)

sets whether SkyMapLite is centered on an object and locked(olny pinch-to-zoom is available)

Definition at line 951 of file skymaplite.cpp.

◆ setClickedObject()

void SkyMapLite::setClickedObject ( SkyObject * o)

Set the ClickedObject pointer to the argument.

opointer to the SkyObject to be assigned as the ClickedObject

Definition at line 312 of file skymaplite.cpp.

◆ setClickedPoint()

void SkyMapLite::setClickedPoint ( SkyPoint * f)

Set the ClickedPoint to the skypoint given as an argument.

fpointer to the new ClickedPoint.

Definition at line 306 of file skymaplite.cpp.

◆ setDestination() [1/2]

void SkyMapLite::setDestination ( const dms & ra,
const dms & dec )

sets the destination point of the skymap, using ra/dec coordinates.

This function behaves essentially like the above function. It differs only in the data types of its arguments.
rathe new right ascension
decthe new declination

Definition at line 283 of file skymaplite.cpp.

◆ setDestination() [2/2]

void SkyMapLite::setDestination ( const SkyPoint & f)

sets the destination point of the sky map.

setDestination() emits the destinationChanged() SIGNAL, which triggers the SLOT function SkyMap::slewFocus(). This function iteratively steps the Focus point toward Destination, repainting the sky at each step (if Options::useAnimatedSlewing()==true).
fa pointer to the SkyPoint the map should slew to

Definition at line 278 of file skymaplite.cpp.

◆ setDestinationAltAz()

void SkyMapLite::setDestinationAltAz ( const dms & alt,
const dms & az,
bool altIsRefracted )

sets the destination point of the sky map, using its alt/az coordinates.

altthe new altitude
azthe new azimuth
altIsRefractedset to true if the altitude supplied is apparent

Definition at line 290 of file skymaplite.cpp.

◆ setFocus() [1/2]

void SkyMapLite::setFocus ( const dms & ra,
const dms & dec )

sets the focus point of the skymap, using ra/dec coordinates

This function behaves essentially like the above function. It differs only in the data types of its arguments.
rathe new right ascension
decthe new declination

Definition at line 257 of file skymaplite.cpp.

◆ setFocus() [2/2]

void SkyMapLite::setFocus ( SkyPoint * f)

sets the central focus point of the sky map.

fa pointer to the SkyPoint the map should be centered on

Definition at line 252 of file skymaplite.cpp.

◆ setFocusAltAz()

void SkyMapLite::setFocusAltAz ( const dms & alt,
const dms & az )

sets the focus point of the sky map, using its alt/az coordinates

altthe new altitude (actual, i.e. without refraction correction)
azthe new azimuth

Definition at line 266 of file skymaplite.cpp.

◆ setFocusObject()

void SkyMapLite::setFocusObject ( SkyObject * o)

Set the FocusObject pointer to the argument.

opointer to the SkyObject to be assigned as the FocusObject

Definition at line 318 of file skymaplite.cpp.

◆ setFocusPoint()

void SkyMapLite::setFocusPoint ( SkyPoint * f)

set the FocusPoint; the position that is to be the next Destination.

fa pointer to the FocusPoint SkyPoint.

Definition at line 204 of file skymaplite.h.

◆ setFOVVisible()

void SkyMapLite::setFOVVisible ( int index,
bool visible )

updates visibility of FOV symbol according to visible

indexof FOVSymbol in m_FOVSymbols
visibledefines whether the FOV symbol should be visible

Definition at line 933 of file skymaplite.cpp.

◆ setMagLim()

void SkyMapLite::setMagLim ( double magLim)

set magnitude limit

Definition at line 499 of file skymapliteevents.cpp.

◆ setRootNode()

static void SkyMapLite::setRootNode ( RootNode * root)

Definition at line 351 of file skymaplite.h.

◆ setSizeMagLim()

void SkyMapLite::setSizeMagLim ( float sizeMagLim)

Set magnitude limit for size of stars.

Used in StarItem

Definition at line 335 of file skymaplite.h.

◆ setSkyRotation

void SkyMapLite::setSkyRotation ( double skyRotation)

Definition at line 605 of file skymaplite.cpp.

◆ setSlewing()

void SkyMapLite::setSlewing ( bool newSlewing)

sets whether SkyMapLite is being slewed

Definition at line 942 of file skymaplite.cpp.

◆ setupProjector()

void SkyMapLite::setupProjector ( )

Call to set up the projector before update of SkyItems positions begins.

Definition at line 735 of file skymaplite.cpp.

◆ setZoomFactor()

void SkyMapLite::setZoomFactor ( double factor)

@ Set zoom factor.

factorzoom factor

Definition at line 631 of file skymaplite.cpp.

◆ sizeMagLim()

float SkyMapLite::sizeMagLim ( ) const

Used in PointSourceNode.

Definition at line 341 of file skymaplite.h.

◆ skyRotationChanged

void SkyMapLite::skyRotationChanged ( double skyRotation)

Emitted when skyRotation used to rotate coordinates of SkyPoints is changed.

◆ slewFocus

void SkyMapLite::slewFocus ( )

Step the Focus point toward the Destination point.

Do this iteratively, redrawing the Sky Map after each step, until the Focus point is within 1 step of the Destination point. For the final step, snap directly to Destination, and redraw the map.

Definition at line 401 of file skymaplite.cpp.

◆ slewingChanged

void SkyMapLite::slewingChanged ( bool )

Emitted when SkyMapLite is being slewed or slewing is finished.

◆ slotCenter

void SkyMapLite::slotCenter ( )

Center the display at the point ClickedPoint.

The essential part of the function is to simply set the Destination point, which will emit the destinationChanged() SIGNAL, which triggers the slewFocus() SLOT. Additionally, this function performs some bookkeeping tasks, such updating whether we are tracking the new object/position, adding a Planet Trail if required, etc.

See also

Definition at line 327 of file skymaplite.cpp.

◆ slotClockSlewing

void SkyMapLite::slotClockSlewing ( )

Checks whether the timestep exceeds a threshold value.

If so, sets ClockSlewing=true and sets the SimClock to ManualMode.

Definition at line 516 of file skymaplite.cpp.

◆ slotSelectObject

void SkyMapLite::slotSelectObject ( SkyObject * skyObj)

centres skyObj in SkyMap and opens context drawer with skyObj Used in FindDialogLite

Definition at line 590 of file skymaplite.cpp.

◆ slotUpdateSky

void SkyMapLite::slotUpdateSky ( bool now)

Update the focus point and call forceUpdate()

nowis saved for compatibility reasons

Definition at line 683 of file skymaplite.cpp.

◆ slotZoomDefault

void SkyMapLite::slotZoomDefault ( )

Set default zoom.

Definition at line 585 of file skymaplite.cpp.

◆ slotZoomIn

void SkyMapLite::slotZoomIn ( )

Zoom in one step.

Definition at line 575 of file skymaplite.cpp.

◆ slotZoomOut

void SkyMapLite::slotZoomOut ( )

Zoom out one step.

Definition at line 580 of file skymaplite.cpp.

◆ stopTracking()

void SkyMapLite::stopTracking ( )

Convenience function for shutting off tracking mode.

Just calls KStars::slotTrack()

Definition at line 516 of file skymapliteevents.cpp.

◆ symbolsFOVChanged

void SkyMapLite::symbolsFOVChanged ( QStringList )

Emitted when FOVSymbols list was changed (new value appended)

◆ textToTexture()

QSGTexture * SkyMapLite::textToTexture ( QString text,
QColor color = QColor(255, 255, 255),
bool zoomFont = false )

creates QImage from text and converts it to QSGTexture

textthe text string
colortext color
zoomFontif true zoom-dependent font from SkyLabeler will be used else standart font is used
QSGTexture with text
font size is set in SkyLabeler::SkyLabeler() by initializing m_stdFont with default font

Definition at line 849 of file skymaplite.cpp.

◆ touchEvent()

void SkyMapLite::touchEvent ( QTouchEvent * e)

this function handles zooming in and out using "pinch to zoom" gesture

Reimplemented from QQuickItem.

Definition at line 268 of file skymapliteevents.cpp.

◆ updateAutomaticMode

void SkyMapLite::updateAutomaticMode ( )

updates focus of SkyMapLite according to data from DeviceOrientation (Smartphone's sensors)

Definition at line 979 of file skymaplite.cpp.

◆ updateFocus()

void SkyMapLite::updateFocus ( )

Update the focus position according to current options.

Definition at line 690 of file skymaplite.cpp.

◆ updatePaintNode()

QSGNode * SkyMapLite::updatePaintNode ( QSGNode * oldNode,
UpdatePaintNodeData * updatePaintNodeData )

Updates SkyMapLite by calling RootNode::update(), which in turn initiates update of all child nodes.

Add or delete telescope crosshairs

Reimplemented from QQuickItem.

Definition at line 143 of file skymaplite.cpp.

◆ wheelEvent()

void SkyMapLite::wheelEvent ( QWheelEvent * e)

Zoom in and out with the mouse wheel.

Reimplemented from QQuickItem.

Definition at line 254 of file skymapliteevents.cpp.

◆ zoomChanged

void SkyMapLite::zoomChanged ( )

Emitted when zoom level is changed.

The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Jun 14 2024 11:55:05 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.