[Marble-devel] (no subject)

Bernhard Beschow bbeschow at cs.tu-berlin.de
Wed Feb 22 10:22:42 UTC 2012

On Samstag, 18. Februar 2012 19:09:07 Lucas Betschart wrote:
> Hello,

Hi Lukas,

> I'm using MarbleWidget in my Qt Application.
> How can I mark a position on the map?
> Something additional to Messure Points & Directions.

If you want to add an entry in the context menu and you're targeting Marble-master, you can do:

1. get a hand on MarbleWidget's menu:
  MarbleWidgetPopupMenu *menu = m_marbleWidget->popupMenu();
2. add a menu entry:
  menu->addAction( Qt::RightButton, new QAction( ... ) );

See MeasureToolPlugin::addContextItems() in src/plugins/render/measure/MeasureToolPlugin.cpp for more details.


More information about the Marble-devel mailing list