Remove redundant setting

This commit is contained in:
Anton Thomasson 2020-09-23 20:23:23 +02:00
parent f6d6b51b9f
commit a5f5e41493
11 changed files with 5 additions and 74 deletions

View file

@ -104,13 +104,6 @@ ApplicationWindow
defaultValue: false
}
ConfigurationValue
{
id: removeRedundantConvertAttrsSetting
key: "/apps/harbour-seaprint/settings/remove-redundant-convert-attributes"
defaultValue: true
}
ConfigurationValue
{
id: alwaysUseMediaColSetting

View file

@ -31,7 +31,6 @@ Page {
PageStackAction.Immediate)
printer.print(jobParams, page.selectedFile,
alwaysConvertSetting.value,
removeRedundantConvertAttrsSetting.value,
alwaysUseMediaColSetting.value)
}
}

View file

@ -53,15 +53,6 @@ Page {
}
}
TextSwitch {
text: qsTr("Remove redundant attributes")
description: qsTr("Remove redundant IPP attributes, if they are also conveyed in the transfer format. Some printers reject the job even if the settings are consistent.")
checked: removeRedundantConvertAttrsSetting.value
onCheckedChanged: {
removeRedundantConvertAttrsSetting.value = checked
}
}
TextSwitch {
text: qsTr("Always use media-col")
description: qsTr("Use the attribute media-col instead of media for paper sizes. I.e. do parametric selection of print media rather than by name. If you use zero print margins, parametric selection will be used regardless of this setting.")

View file

@ -308,11 +308,9 @@ QString targetFormatIfAuto(QString documentFormat, QString mimeType, QJsonArray
return documentFormat;
}
void IppPrinter::print(QJsonObject attrs, QString filename,
bool alwaysConvert, bool removeRedundantConvertAttrs, bool alwaysUseMediaCol)
void IppPrinter::print(QJsonObject attrs, QString filename, bool alwaysConvert, bool alwaysUseMediaCol)
{
qDebug() << "printing" << filename << attrs
<< alwaysConvert << removeRedundantConvertAttrs;
qDebug() << "printing" << filename << attrs << alwaysConvert;
_progress = "";
emit progressChanged();
@ -440,14 +438,13 @@ void IppPrinter::print(QJsonObject attrs, QString filename,
}
QString Sides = getAttrOrDefault(attrs, "sides").toString();
if(removeRedundantConvertAttrs && (documentFormat=="image/pwg-raster" ||
documentFormat=="image/urf"))
if(documentFormat=="image/pwg-raster" || documentFormat=="image/urf")
{
attrs.remove("sides");
attrs.remove("print-color-mode");
attrs.remove("page-ranges");
}
else if(removeRedundantConvertAttrs && documentFormat == "application/postscript")
else if(documentFormat == "application/postscript")
{
attrs.remove("sides");
attrs.remove("page-ranges");

View file

@ -54,8 +54,7 @@ signals:
void progressChanged();
public slots:
void print(QJsonObject attrs, QString file,
bool alwaysConvert, bool removeRedundantAttributesForRaster, bool alwaysUseMediaCol);
void print(QJsonObject attrs, QString file, bool alwaysConvert, bool alwaysUseMediaCol);
void onUrlChanged();

View file

@ -413,14 +413,6 @@
<source>Force conversion to PWG/URF raster format. This is mainly intended for testing.</source>
<translation>Konvertierung in das PWG/URF Rasterformat erzwingen. Die ist hauptsächlich für Testzwecke vorgesehen.</translation>
</message>
<message>
<source>Remove redundant attributes</source>
<translation>Redundante Attribute entfernen</translation>
</message>
<message>
<source>Remove redundant IPP attributes, if they are also conveyed in the transfer format. Some printers reject the job even if the settings are consistent.</source>
<translation>Rdundante IPP Attribute entfernen, wenn sie in dem Tranferformat übermittelt werden. Einige Drucker lehnen Aufträge ab, selbst wenn die Einstellungen konsistent sind.</translation>
</message>
<message>
<source>Display the warning page about optional dependencies not being installed, if they are not installed.</source>
<translation>Warnseite über nicht installierte optionalen Abhängigkeiten anzeigen, wenn diese nicht installiert sind.</translation>

View file

@ -413,14 +413,6 @@
<source>Force conversion to PWG/URF raster format. This is mainly intended for testing.</source>
<translation>Forzar conversión a formato ráster PWG/URF. Esto es para hacer pruebas principalmente.</translation>
</message>
<message>
<source>Remove redundant attributes</source>
<translation>Eliminar atributos redundantes</translation>
</message>
<message>
<source>Remove redundant IPP attributes, if they are also conveyed in the transfer format. Some printers reject the job even if the settings are consistent.</source>
<translation>Elimina los atributos IPP redundantes, si también se transmiten en el formato de transferencia. Algunas impresoras rechazan el trabajo aunque la configuración sea coherente.</translation>
</message>
<message>
<source>Display the warning page about optional dependencies not being installed, if they are not installed.</source>
<translation>Mostrar página de advertencia sobre las dependencias opcionales no instaladas cuando no están instaladas.</translation>

View file

@ -413,14 +413,6 @@
<source>Force conversion to PWG/URF raster format. This is mainly intended for testing.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Remove redundant attributes</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Remove redundant IPP attributes, if they are also conveyed in the transfer format. Some printers reject the job even if the settings are consistent.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Display the warning page about optional dependencies not being installed, if they are not installed.</source>
<translation type="unfinished"></translation>

View file

@ -421,14 +421,6 @@
<source>Force conversion to PWG/URF raster format. This is mainly intended for testing.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Remove redundant attributes</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Remove redundant IPP attributes, if they are also conveyed in the transfer format. Some printers reject the job even if the settings are consistent.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Always use media-col</source>
<translation type="unfinished"></translation>

View file

@ -413,14 +413,6 @@
<source>Force conversion to PWG/URF raster format. This is mainly intended for testing.</source>
<translation> PWG URF </translation>
</message>
<message>
<source>Remove redundant attributes</source>
<translation></translation>
</message>
<message>
<source>Remove redundant IPP attributes, if they are also conveyed in the transfer format. Some printers reject the job even if the settings are consistent.</source>
<translation>IPP属性 使</translation>
</message>
<message>
<source>Display the warning page about optional dependencies not being installed, if they are not installed.</source>
<translation></translation>

View file

@ -413,14 +413,6 @@
<source>Force conversion to PWG/URF raster format. This is mainly intended for testing.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Remove redundant attributes</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Remove redundant IPP attributes, if they are also conveyed in the transfer format. Some printers reject the job even if the settings are consistent.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Display the warning page about optional dependencies not being installed, if they are not installed.</source>
<translation type="unfinished"></translation>