Details
-
Bug
-
Resolution: Done
-
P3: Somewhat important
-
4.7.0
-
None
Description
Whenever I use an SVG in an Image element there are problems with the binding.
A simple testcase:
Rectangle
{
width: 1024
height: 768
Image { source: "images/Qt-logo.svg"; fillMode: Image.PreserveAspectFit; anchors.centerIn: parent; width: parent.width / 2}
}
This testcase semi-works, in that the SVG is resized. It is however resized after converting the SVG to a pixmap. Is it not possible to have the SVG rendered-to-pixmap at a different size? SVG loading is currently completely useless because of this.
When the width of the parent is not explicitly set more problems occur (does not occur when the parent has an explicit width):
width: parent.width * 2 //Not resized, drawn at file's normal size width: parent.width - 200 //Not resized, drawn at file's normal size width: parent.width + 200 //Not resized, drawn at file's normal size
See also QT-3128
Attachments
Issue Links
- depends on
-
QTBUG-9053 SVG image plugin does not implement CanRead
- Closed
-
QTBUG-9091 JPEG loader cannot read size header from stream
- Closed