mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-08 00:05:32 -04:00
Enable annotation items in composer. Remove gui export from classes that have been moved to app
git-svn-id: http://svn.osgeo.org/qgis/trunk@13191 c8812cc2-4d05-0410-92ff-de0c093fc19c
This commit is contained in:
parent
c0a4ee3951
commit
0558eae3ce
@ -25,7 +25,7 @@ class QgsMarkerSymbolV2;
|
|||||||
|
|
||||||
/**A configuration widget to configure the annotation item properties. Usually embedded by QgsAnnotationItem
|
/**A configuration widget to configure the annotation item properties. Usually embedded by QgsAnnotationItem
|
||||||
subclass configuration dialogs*/
|
subclass configuration dialogs*/
|
||||||
class GUI_EXPORT QgsAnnotationWidget: public QWidget, private Ui::QgsAnnotationWidgetBase
|
class QgsAnnotationWidget: public QWidget, private Ui::QgsAnnotationWidgetBase
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
public:
|
public:
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
class QgsAnnotationWidget;
|
class QgsAnnotationWidget;
|
||||||
|
|
||||||
class GUI_EXPORT QgsFormAnnotationDialog: public QDialog, private Ui::QgsFormAnnotationDialogBase
|
class QgsFormAnnotationDialog: public QDialog, private Ui::QgsFormAnnotationDialogBase
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
public:
|
public:
|
||||||
|
@ -23,7 +23,7 @@
|
|||||||
class QgsAnnotationWidget;
|
class QgsAnnotationWidget;
|
||||||
class QgsTextAnnotationItem;
|
class QgsTextAnnotationItem;
|
||||||
|
|
||||||
class GUI_EXPORT QgsTextAnnotationDialog: public QDialog, private Ui::QgsTextAnnotationDialogBase
|
class QgsTextAnnotationDialog: public QDialog, private Ui::QgsTextAnnotationDialogBase
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
public:
|
public:
|
||||||
|
@ -270,7 +270,7 @@ void QgsComposerMap::paint( QPainter* painter, const QStyleOptionGraphicsItem* i
|
|||||||
painter->restore();
|
painter->restore();
|
||||||
|
|
||||||
//draw canvas items
|
//draw canvas items
|
||||||
//drawCanvasItems( painter, itemStyle );
|
drawCanvasItems( painter, itemStyle );
|
||||||
}
|
}
|
||||||
else if ( mComposition->plotStyle() == QgsComposition::Print ||
|
else if ( mComposition->plotStyle() == QgsComposition::Print ||
|
||||||
mComposition->plotStyle() == QgsComposition::Postscript )
|
mComposition->plotStyle() == QgsComposition::Postscript )
|
||||||
@ -311,7 +311,7 @@ void QgsComposerMap::paint( QPainter* painter, const QStyleOptionGraphicsItem* i
|
|||||||
painter->restore();
|
painter->restore();
|
||||||
|
|
||||||
//draw canvas items
|
//draw canvas items
|
||||||
//drawCanvasItems( painter, itemStyle );
|
drawCanvasItems( painter, itemStyle );
|
||||||
|
|
||||||
mDrawing = false;
|
mDrawing = false;
|
||||||
}
|
}
|
||||||
@ -1478,7 +1478,7 @@ QPointF QgsComposerMap::composerMapPosForItem( const QGraphicsItem* item ) const
|
|||||||
double mapX = item->scenePos().x() / mMapCanvas->width() * mMapRenderer->extent().width() + mMapRenderer->extent().xMinimum();
|
double mapX = item->scenePos().x() / mMapCanvas->width() * mMapRenderer->extent().width() + mMapRenderer->extent().xMinimum();
|
||||||
double mapY = mMapRenderer->extent().yMaximum() - item->scenePos().y() / mMapCanvas->height() * mMapRenderer->extent().height();
|
double mapY = mMapRenderer->extent().yMaximum() - item->scenePos().y() / mMapCanvas->height() * mMapRenderer->extent().height();
|
||||||
|
|
||||||
double itemX = rect().width() * ( mapX - mExtent.xMinimum() ) / mExtent.width();
|
double itemX = rect().width() * ( mapX - mExtent.xMinimum() ) / mExtent.width() + mXOffset;
|
||||||
double itemY = rect().height() * ( mExtent.yMaximum() - mapY ) / mExtent.height();
|
double itemY = rect().height() * ( mExtent.yMaximum() - mapY ) / mExtent.height() + mYOffset;
|
||||||
return QPointF( itemX, itemY );
|
return QPointF( itemX, itemY );
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user