TechDraw: hard type enums, part 3 (#19418)
* Remove magic number and hard type enums in LineNameEnum.h - Remove currently present magic numbers - Hard type enums, so magic numbers can no longer be introduced. We don't want people to introduce magic numbers. * Remove magic number and hard type enums in QGIFace.h - Remove currently present magic numbers - Hard type enums, so magic numbers can no longer be introduced. We don't want people to introduce magic numbers. * Remove magic number and hard type enums in Enums.h - Remove currently present magic numbers - Hard type enums, so magic numbers can no longer be introduced. We don't want people to introduce magic numbers. * Remove magic number and hard type enums in QGVPage.h - Remove currently present magic numbers - Hard type enums, so magic numbers can no longer be introduced. We don't want people to introduce magic numbers. * Remove magic number and hard type enums in TaskSurfaceFinishSymbols.h - Remove currently present magic numbers - Hard type enums, so magic numbers can no longer be introduced. We don't want people to introduce magic numbers. * Remove magic number and hard type enums in QGTracker.h - Remove currently present magic numbers - Hard type enums, so magic numbers can no longer be introduced. We don't want people to introduce magic numbers.
This commit is contained in:
committed by
GitHub
parent
38797d1fa4
commit
bf1f99c070
@@ -34,6 +34,7 @@
|
||||
|
||||
|
||||
using namespace TechDrawGui;
|
||||
using FillMode = QGIFace::FillMode;
|
||||
|
||||
void QGIViewSection::draw()
|
||||
{
|
||||
@@ -91,10 +92,10 @@ void QGIViewSection::drawSectionFace()
|
||||
QColor faceColor = (sectionVp->CutSurfaceColor.getValue()).asValue<QColor>();
|
||||
faceColor.setAlpha((100 - sectionVp->CutSurfaceTransparency.getValue())*255/100);
|
||||
newFace->setFillColor(faceColor);
|
||||
newFace->setFillMode(faceColor.alpha() ? QGIFace::PlainFill : QGIFace::NoFill);
|
||||
newFace->setFillMode(faceColor.alpha() ? FillMode::PlainFill : FillMode::NoFill);
|
||||
} else if (section->CutSurfaceDisplay.isValue("SvgHatch")) {
|
||||
newFace->isHatched(true);
|
||||
newFace->setFillMode(QGIFace::SvgFill);
|
||||
newFace->setFillMode(FillMode::SvgFill);
|
||||
newFace->setHatchColor(sectionVp->HatchColor.getValue());
|
||||
newFace->setHatchScale(section->HatchScale.getValue());
|
||||
newFace->setHatchRotation(section->HatchRotation.getValue());
|
||||
@@ -103,7 +104,7 @@ void QGIViewSection::drawSectionFace()
|
||||
newFace->setHatchFile(hatchSpec);
|
||||
} else if (section->CutSurfaceDisplay.isValue("PatHatch")) {
|
||||
newFace->isHatched(true);
|
||||
newFace->setFillMode(QGIFace::GeomHatchFill);
|
||||
newFace->setFillMode(FillMode::GeomHatchFill);
|
||||
newFace->setHatchColor(sectionVp->GeomHatchColor.getValue());
|
||||
newFace->setHatchScale(section->HatchScale.getValue());
|
||||
newFace->setHatchRotation(section->HatchRotation.getValue());
|
||||
|
||||
Reference in New Issue
Block a user