QGIS API Documentation 3.99.0-Master (26c88405ac0)
Loading...
Searching...
No Matches
qgslayouthtmlwidget.h
Go to the documentation of this file.
1/***************************************************************************
2 qgslayouthtmlwidget.h
3 ---------------------
4 begin : November 2017
5 copyright : (C) 2017 by Nyall Dawson
6 email : nyall dot dawson at gmail dot com
7 ***************************************************************************
8 * *
9 * This program is free software; you can redistribute it and/or modify *
10 * it under the terms of the GNU General Public License as published by *
11 * the Free Software Foundation; either version 2 of the License, or *
12 * (at your option) any later version. *
13 * *
14 ***************************************************************************/
15#ifndef QGSLAYOUTHTMLWIDGET_H
16#define QGSLAYOUTHTMLWIDGET_H
17
18// We don't want to expose this in the public API
19#define SIP_NO_FILE
20
21#include "ui_qgslayouthtmlwidgetbase.h"
22
23#include "qgis_gui.h"
24#include "qgslayoutitemwidget.h"
25
27class QgsLayoutFrame;
30
38class GUI_EXPORT QgsLayoutHtmlWidget : public QgsLayoutItemBaseWidget, private Ui::QgsLayoutHtmlWidgetBase
39{
40 Q_OBJECT
41 public:
45 void setMasterLayout( QgsMasterLayoutInterface *masterLayout ) override;
46
47 protected:
48 bool setNewItem( QgsLayoutItem *item ) override;
49
50 private slots:
51 void mUrlLineEdit_editingFinished();
52 void mFileToolButton_clicked();
53 void mResizeModeComboBox_currentIndexChanged( int index );
54 void mEvaluateExpressionsCheckbox_toggled( bool checked );
55 void mUseSmartBreaksCheckBox_toggled( bool checked );
56 void mMaxDistanceSpinBox_valueChanged( double val );
57 void htmlEditorChanged();
58 void stylesheetEditorChanged();
59 void mUserStylesheetCheckBox_toggled( bool checked );
60 void mRadioManualSource_clicked( bool checked );
61 void mRadioUrlSource_clicked( bool checked );
62 void mInsertExpressionButton_clicked();
63
64 void mReloadPushButton_clicked();
65 void mAddFramePushButton_clicked();
66 void mEmptyFrameCheckBox_toggled( bool checked );
67 void mHideEmptyBgCheckBox_toggled( bool checked );
68
70 void setGuiElementValues();
71
72 protected slots:
75
76 private:
77 void blockSignals( bool block );
78
79 QPointer<QgsLayoutItemHtml> mHtml;
80 QPointer<QgsLayoutFrame> mFrame;
81 QgsLayoutItemPropertiesWidget *mItemPropertiesWidget = nullptr;
82
83 QgsCodeEditorHTML *mHtmlEditor = nullptr;
84 QgsCodeEditorCSS *mStylesheetEditor = nullptr;
85};
86
87#endif // QGSLAYOUTHTMLWIDGET_H
A CSS editor based on QScintilla2.
A HTML editor based on QScintilla2.
Base class for frame items, which form a layout multiframe item.
void populateDataDefinedButtons()
Initializes data defined buttons to current atlas coverage layer.
QgsLayoutHtmlWidget()=delete
virtual bool setNewItem(QgsLayoutItem *item)
Attempts to update the widget to show the properties for the specified item.
virtual void setMasterLayout(QgsMasterLayoutInterface *masterLayout)
Sets the master layout associated with the item.
QgsLayoutItemBaseWidget(QWidget *parent SIP_TRANSFERTHIS, QgsLayoutObject *layoutObject)
Constructor for QgsLayoutItemBaseWidget, linked with the specified layoutObject.
A layout multiframe subclass for HTML content.
A widget for controlling the common properties of layout items (e.g.
Base class for graphical items within a QgsLayout.
Interface for master layout type objects, such as print layouts and reports.