/
qgsrelationreferencewidget.sip
48 lines (33 loc) · 1.14 KB
/
qgsrelationreferencewidget.sip
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
class QgsRelationReferenceWidget : QWidget
{
%TypeHeaderCode
#include <qgsrelationreferencewidget.h>
%End
public:
enum CanvasExtent
{
Fixed,
Pan,
Scale
};
explicit QgsRelationReferenceWidget( QWidget* parent );
~QgsRelationReferenceWidget();
void setRelation( QgsRelation relation , bool allowNullValue );
void setRelationEditable( bool editable );
//! this sets the related feature using from the foreign key
void setRelatedFeature( const QVariant &value );
//! returns the related feature foreign key
QVariant foreignKey();
void setEditorContext( QgsAttributeEditorContext context, QgsMapCanvas* canvas, QgsMessageBar* messageBar );
bool embedForm() {return mEmbedForm;}
void setEmbedForm( bool display );
bool readOnlySelector() {return mReadOnlySelector;}
void setReadOnlySelector( bool readOnly );
bool allowMapIdentification() {return mAllowMapIdentification;}
void setAllowMapIdentification( bool allowMapIdentification );
protected:
virtual void showEvent( QShowEvent* e );
void init();
signals:
void relatedFeatureChanged( QVariant );
};