mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Printing: scale fonts when printing
This seem to work better, but it misses a couple of items at times (for example the highest label on some of the axis). Needs lots more testing. See #590 Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
2d77788cb2
commit
76a8e83a54
5 changed files with 30 additions and 4 deletions
|
@ -90,7 +90,8 @@ ProfileWidget2::ProfileWidget2(QWidget *parent) : QGraphicsView(parent),
|
|||
isGrayscale(false),
|
||||
printMode(false),
|
||||
shouldCalculateMaxTime(true),
|
||||
shouldCalculateMaxDepth(true)
|
||||
shouldCalculateMaxDepth(true),
|
||||
fontPrintScale(1.0)
|
||||
{
|
||||
memset(&plotInfo, 0, sizeof(plotInfo));
|
||||
|
||||
|
@ -1054,12 +1055,30 @@ void ProfileWidget2::changeGas()
|
|||
replot();
|
||||
}
|
||||
|
||||
bool ProfileWidget2::getPrintMode()
|
||||
{
|
||||
return printMode;
|
||||
}
|
||||
|
||||
void ProfileWidget2::setPrintMode(bool mode, bool grayscale)
|
||||
{
|
||||
printMode = mode;
|
||||
isGrayscale = mode ? grayscale : false;
|
||||
}
|
||||
|
||||
void ProfileWidget2::setFontPrintScale(double scale)
|
||||
{
|
||||
fontPrintScale = scale;
|
||||
}
|
||||
|
||||
double ProfileWidget2::getFontPrintScale()
|
||||
{
|
||||
if (printMode)
|
||||
return fontPrintScale;
|
||||
else
|
||||
return 1.0;
|
||||
}
|
||||
|
||||
void ProfileWidget2::editName()
|
||||
{
|
||||
QAction *action = qobject_cast<QAction *>(sender());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue