~phablet-team/ubuntu-settings-components/printer-components

« back to all changes in this revision

Viewing changes to examples/Printers.qml

  • Committer: Jonas G. Drange
  • Date: 2017-01-20 12:22:39 UTC
  • mfrom: (207.1.7 quality-read-write)
  • Revision ID: jonas.drange@canonical.com-20170120122239-tgiaem78dpz6y0zc
* Implements read/write of select Quality ppd settings
* Updates PrinterJob to use the correct quality setting
* Fixes broken ColorModel system, now reflects most ppds, and leaves the ppd implementation details in the ppd (colorspace, organization, etc)

Show diffs side-by-side

added added

removed removed

Lines of Context:
121
121
                            if (enabled)
122
122
                                selectedIndex = printer.colorModel
123
123
                        }
 
124
                    }
124
125
 
 
126
                    ListItems.ValueSelector {
 
127
                        anchors {
 
128
                            left: parent.left
 
129
                            right: parent.right
 
130
                        }
 
131
                        visible: printer.supportedPrintQualities.length
 
132
                        text: "Quality"
 
133
                        values: printer.supportedPrintQualities
 
134
                        enabled: values.length > 1
 
135
                        onSelectedIndexChanged: printer.printQuality = selectedIndex
 
136
                        Component.onCompleted: {
 
137
                            if (enabled)
 
138
                                selectedIndex = printer.printQuality
 
139
                        }
125
140
                    }
126
141
                }
127
142
            }
128
 
 
129
143
        }
130
144
    }
131
145