summaryrefslogtreecommitdiffstats
path: root/src/corelib/tools/qrect.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/corelib/tools/qrect.h')
-rw-r--r--src/corelib/tools/qrect.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/corelib/tools/qrect.h b/src/corelib/tools/qrect.h
index d114fa7ae0..e69a217f48 100644
--- a/src/corelib/tools/qrect.h
+++ b/src/corelib/tools/qrect.h
@@ -16,6 +16,11 @@
#if defined(Q_OS_DARWIN) || defined(Q_QDOC)
struct CGRect;
#endif
+#if defined(Q_OS_WASM) || defined(Q_QDOC)
+namespace emscripten {
+class val;
+}
+#endif
QT_BEGIN_NAMESPACE
@@ -586,6 +591,11 @@ public:
[[nodiscard]] CGRect toCGRect() const noexcept;
#endif
+#if defined(Q_OS_WASM) || defined(Q_QDOC)
+ [[nodiscard]] static QRectF fromDOMRect(emscripten::val domRect);
+ [[nodiscard]] emscripten::val toDOMRect() const;
+#endif
+
private:
qreal xp;
qreal yp;