34 mLayout =
new QGridLayout(
this );
35 mLayout->setContentsMargins( 0, 0, 0, 0 );
37 QLabel *minLbl =
new QLabel( tr(
"Minimum (exclusive)" ),
this );
38 minLbl->setWordWrap(
true );
39 minLbl->setAlignment( Qt::AlignTop );
40 minLbl->setToolTip( tr(
"Minimum scale, i.e. most \"zoomed out\". "
41 "This limit is exclusive, that means the layer will not be displayed on this scale." ) );
42 QLabel *maxLbl =
new QLabel( tr(
"Maximum (inclusive)" ),
this );
43 maxLbl->setWordWrap(
true );
44 maxLbl->setAlignment( Qt::AlignTop );
45 maxLbl->setToolTip( tr(
"Maximum scale, i.e. most \"zoomed in\". "
46 "This limit is inclusive, that means the layer will be displayed on this scale." ) );
49 mMinimumScaleIconLabel =
new QLabel(
this );
51 mMaximumScaleIconLabel =
new QLabel(
this );
57 mMinimumScaleWidget->setShowCurrentScaleButton(
true );
58 mMaximumScaleWidget->setShowCurrentScaleButton(
true );
61 mMinimumScaleWidget->setScale( 100000 );
62 mMaximumScaleWidget->setScale( 1000 );
64 mLayout->addWidget( minLbl, 0, 0, 1, 2 );
65 mLayout->addWidget( mMinimumScaleIconLabel, 1, 0 );
66 mLayout->addWidget( mMinimumScaleWidget, 1, 1 );
67 mLayout->addWidget( maxLbl, 0, 2, 1, 2 );
68 mLayout->addWidget( mMaximumScaleIconLabel, 1, 2 );
69 mLayout->addWidget( mMaximumScaleWidget, 1, 3 );
71 mLayout->setColumnStretch( 0, 0 );
72 mLayout->setColumnStretch( 1, 3 );
73 mLayout->setColumnStretch( 2, 0 );
74 mLayout->setColumnStretch( 3, 3 );