Image fails to load if only sourceSize.height or width is specified
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Ubuntu UI Toolkit |
Confirmed
|
Low
|
Unassigned | ||
ubuntu-ui-toolkit (Ubuntu) |
Confirmed
|
Low
|
Unassigned |
Bug Description
By using the example at the bottom of this description, an error is reported on the console:
QML QQuickImage: Failed to get image from provider: image:/
(path is obviously specific to that test run, but the image mentioned in the error actually exists on disk)
Either removing sourceSize.height or adding sourceSize.width makes the error disappear and the image loads correctly.
So it seems that the two sourceSize properties need to be either both set or both unset, but it can't be just one.
import QtQuick 2.0
import Ubuntu.Components 0.1
Item {
width: 600
height: 600
Image {
source: "assets/
}
}
Changed in ubuntu-ui-toolkit (Ubuntu): | |
importance: | Undecided → Low |
status: | New → Confirmed |
Although this is a valid bug using sourceSize with assets should not be done as it will result in unnecessary scaling.