本文整理汇总了C++中Theme::shadowRadius方法的典型用法代码示例。如果您正苦于以下问题:C++ Theme::shadowRadius方法的具体用法?C++ Theme::shadowRadius怎么用?C++ Theme::shadowRadius使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Theme
的用法示例。
在下文中一共展示了Theme::shadowRadius方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: file
//.........这里部分代码省略.........
// Create blur group
m_blur = new QGroupBox(tr("Blur Text Background"), contents);
m_blur->setCheckable(true);
m_blur->setChecked(m_theme.blurEnabled());
connect(m_blur, SIGNAL(clicked()), this, SLOT(renderPreview()));
m_blur_radius = new QSpinBox(m_blur);
m_blur_radius->setCorrectionMode(QSpinBox::CorrectToNearestValue);
m_blur_radius->setSuffix(tr(" pixels"));
m_blur_radius->setRange(theme.blurRadius().minimumValue(), theme.blurRadius().maximumValue());
m_blur_radius->setValue(m_theme.blurRadius());
connect(m_blur_radius, SIGNAL(valueChanged(int)), this, SLOT(renderPreview()));
QFormLayout* blur_layout = new QFormLayout(m_blur);
blur_layout->setFieldGrowthPolicy(QFormLayout::FieldsStayAtSizeHint);
blur_layout->addRow(tr("Radius:"), m_blur_radius);
// Create shadow group
m_shadow = new QGroupBox(tr("Text Background Drop Shadow"), contents);
m_shadow->setCheckable(true);
m_shadow->setChecked(m_theme.shadowEnabled());
connect(m_shadow, SIGNAL(clicked()), this, SLOT(renderPreview()));
m_shadow_color = new ColorButton(m_shadow);
m_shadow_color->setColor(m_theme.shadowColor());
connect(m_shadow_color, SIGNAL(changed(QColor)), this, SLOT(renderPreview()));
m_shadow_radius = new QSpinBox(m_shadow);
m_shadow_radius->setCorrectionMode(QSpinBox::CorrectToNearestValue);
m_shadow_radius->setSuffix(tr(" pixels"));
m_shadow_radius->setRange(theme.shadowRadius().minimumValue(), theme.shadowRadius().maximumValue());
m_shadow_radius->setValue(m_theme.shadowRadius());
connect(m_shadow_radius, SIGNAL(valueChanged(int)), this, SLOT(renderPreview()));
m_shadow_offset = new QSpinBox(m_shadow);
m_shadow_offset->setCorrectionMode(QSpinBox::CorrectToNearestValue);
m_shadow_offset->setSuffix(tr(" pixels"));
m_shadow_offset->setRange(theme.shadowOffset().minimumValue(), theme.shadowOffset().maximumValue());
m_shadow_offset->setValue(m_theme.shadowOffset());
connect(m_shadow_offset, SIGNAL(valueChanged(int)), this, SLOT(renderPreview()));
QFormLayout* shadow_layout = new QFormLayout(m_shadow);
shadow_layout->setFieldGrowthPolicy(QFormLayout::FieldsStayAtSizeHint);
shadow_layout->addRow(tr("Color:"), m_shadow_color);
shadow_layout->addRow(tr("Radius:"), m_shadow_radius);
shadow_layout->addRow(tr("Vertical Offset:"), m_shadow_offset);
// Create margins group
QGroupBox* margins_group = new QGroupBox(tr("Margins"), contents);
m_foreground_margin = new QSpinBox(margins_group);
m_foreground_margin->setCorrectionMode(QSpinBox::CorrectToNearestValue);
m_foreground_margin->setSuffix(tr(" pixels"));
m_foreground_margin->setRange(theme.foregroundMargin().minimumValue(), theme.foregroundMargin().maximumValue());
m_foreground_margin->setValue(m_theme.foregroundMargin());
connect(m_foreground_margin, SIGNAL(valueChanged(int)), this, SLOT(renderPreview()));
m_foreground_padding = new QSpinBox(margins_group);
m_foreground_padding->setCorrectionMode(QSpinBox::CorrectToNearestValue);
m_foreground_padding->setSuffix(tr(" pixels"));
m_foreground_padding->setRange(theme.foregroundPadding().minimumValue(), theme.foregroundPadding().maximumValue());
m_foreground_padding->setValue(m_theme.foregroundPadding());