File indexing completed on 2024-04-28 11:31:16

0001 // SPDX-License-Identifier: LGPL-2.1-or-later
0002 //
0003 // SPDX-FileCopyrightText: 2010 Dennis Nienhüser <nienhueser@kde.org>
0004 //
0005 
0006 #include "PrintOptionsWidget.h"
0007 
0008 namespace Marble
0009 {
0010 
0011 PrintOptionsWidget::PrintOptionsWidget( QWidget * parent, Qt::WindowFlags flags ) :
0012         QWidget( parent, flags )
0013 {
0014     setupUi( this );
0015 }
0016 
0017 bool PrintOptionsWidget::printMap() const
0018 {
0019     return mapCheckBox->isChecked();
0020 }
0021 
0022 void PrintOptionsWidget::setPrintMap( bool print )
0023 {
0024     mapCheckBox->setChecked( print );
0025 }
0026 
0027 bool PrintOptionsWidget::printBackground() const
0028 {
0029     return backgroundCheckBox->isChecked();
0030 }
0031 
0032 void PrintOptionsWidget::setPrintBackground( bool print )
0033 {
0034     backgroundCheckBox->setChecked( print );
0035 }
0036 
0037 bool PrintOptionsWidget::printLegend() const
0038 {
0039     return legendCheckBox->isChecked();
0040 }
0041 
0042 void PrintOptionsWidget::setPrintLegend( bool print )
0043 {
0044     legendCheckBox->setChecked( print );
0045 }
0046 
0047 bool PrintOptionsWidget::printRouteSummary() const
0048 {
0049     return routeSummaryCheckBox->isChecked();
0050 }
0051 
0052 void PrintOptionsWidget::setPrintRouteSummary( bool print )
0053 {
0054     routeSummaryCheckBox->setChecked( print );
0055 }
0056 
0057 bool PrintOptionsWidget::printDrivingInstructions() const
0058 {
0059     return drivingInstructionsCheckBox->isChecked();
0060 }
0061 
0062 void PrintOptionsWidget::setPrintDrivingInstructions( bool print )
0063 {
0064     drivingInstructionsCheckBox->setChecked( print );
0065 }
0066 
0067 void PrintOptionsWidget::setBackgroundControlsEnabled( bool enabled )
0068 {
0069     backgroundCheckBox->setEnabled( enabled );
0070 }
0071 
0072 void PrintOptionsWidget::setLegendControlsEnabled( bool enabled )
0073 {
0074     legendCheckBox->setEnabled( enabled );
0075 }
0076 
0077 void PrintOptionsWidget::setRouteControlsEnabled( bool enabled )
0078 {
0079     routeGroupBox->setEnabled( enabled );
0080 }
0081 
0082 bool PrintOptionsWidget::printDrivingInstructionsAdvice() const
0083 {
0084     return drivingInstructionsAdviceCheckBox->isChecked();
0085 }
0086 
0087 void PrintOptionsWidget::setPrintDrivingInstructionsAdvice( bool enabled )
0088 {
0089     drivingInstructionsAdviceCheckBox->setChecked( enabled );
0090 }
0091 
0092 }
0093 
0094 #include "moc_PrintOptionsWidget.cpp"