17 #ifndef QGSEXTERNALRESOURCEWIDGET_H 18 #define QGSEXTERNALRESOURCEWIDGET_H 51 if ( qobject_cast<QgsExternalResourceWidget *>( sipCpp ) )
52 sipType = sipType_QgsExternalResourceWidget;
59 Q_PROPERTY(
bool fileWidgetVisible READ fileWidgetVisible WRITE setFileWidgetVisible )
60 Q_PROPERTY(
DocumentViewerContent documentViewerContent READ documentViewerContent WRITE setDocumentViewerContent )
61 Q_PROPERTY(
int documentViewerHeight READ documentViewerHeight WRITE setDocumentViewerHeight )
62 Q_PROPERTY(
int documentViewerWidth READ documentViewerWidth WRITE setDocumentViewerWidth )
63 Q_PROPERTY(
QgsFileWidget::RelativeStorage relativeStorage READ relativeStorage WRITE setRelativeStorage )
64 Q_PROPERTY( QString defaultRoot READ defaultRoot WRITE setDefaultRoot )
85 QVariant documentPath( QVariant::Type type = QVariant::String )
const;
86 void setDocumentPath(
const QVariant &documentPath );
92 bool fileWidgetVisible()
const;
94 void setFileWidgetVisible(
bool visible );
102 int documentViewerHeight()
const;
108 void setDocumentViewerHeight(
int height );
110 int documentViewerWidth()
const;
116 void setDocumentViewerWidth(
int width );
119 void setReadOnly(
bool readOnly );
138 QString defaultRoot()
const;
144 void setDefaultRoot(
const QString &defaultRoot );
148 void valueChanged(
const QString & );
151 void loadDocument(
const QString &path );
154 void updateDocumentViewer();
156 QString resolvePath(
const QString &path );
159 bool mFileWidgetVisible =
true;
161 int mDocumentViewerHeight = 0;
162 int mDocumentViewerWidth = 0;
164 QString mDefaultRoot;
170 QWebView *mWebView =
nullptr;
176 #endif // QGSEXTERNALRESOURCEWIDGET_H
#define SIP_CONVERT_TO_SUBCLASS_CODE(code)
The QgsPixmapLabel class shows a pixmap and adjusts its size to the space given to the widget by the ...