diff options
author | kamel5 <vdr.kamel5 (at) gmx (dot) net> | 2022-06-05 19:04:27 +0200 |
---|---|---|
committer | kamel5 <vdr.kamel5 (at) gmx (dot) net> | 2022-06-09 13:51:21 +0200 |
commit | fa070762889086cdc9128daa1d79575163665527 (patch) | |
tree | aad99e74ab9cb725ee24979a031be6862d56153c /displaychannelview.c | |
parent | 7c1871ce4778b7e889e8546c506084aa2fa66487 (diff) | |
download | skin-nopacity-fa070762889086cdc9128daa1d79575163665527.tar.gz skin-nopacity-fa070762889086cdc9128daa1d79575163665527.tar.bz2 |
Better vertical align of SignalMeter
Diffstat (limited to 'displaychannelview.c')
-rw-r--r-- | displaychannelview.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/displaychannelview.c b/displaychannelview.c index 929faa4..03debb2 100644 --- a/displaychannelview.c +++ b/displaychannelview.c @@ -537,7 +537,7 @@ void cNopacityDisplayChannelView::DrawPoster(const cEvent *event, bool initial) void cNopacityDisplayChannelView::DrawSignalMeter(void) { signalWidth = geoManager->channelWidth * 0.15; - signalHeight = signalWidth *15 / 200; + signalHeight = signalWidth * 15 / 200; cFont *fontInfoline = cFont::CreateFont(config.fontName, signalHeight - 2); cString signalStrength = "STR"; cString signalQuality = "SNR"; @@ -546,7 +546,7 @@ void cNopacityDisplayChannelView::DrawSignalMeter(void) { signalWidth = imgSignal->Width(); signalHeight = imgSignal->Height(); int signalMeterY = geoManager->channelFooterY + - (geoManager->channelFooterHeight - 2*signalHeight - 5)/2; + (geoManager->channelFooterHeight - 2 * signalHeight - 7) / 2; // 2 * (signalHeight + 2) + 3 + 2 int labelWidth = std::max(fontInfoline->Width(*signalStrength), fontInfoline->Width(*signalQuality)) + 2; signalX = geoManager->channelFooterHeight / 2 + labelWidth; @@ -562,14 +562,14 @@ void cNopacityDisplayChannelView::DrawSignalMeter(void) { signalHeight + 2)); pixmapSignalMeter = osd->CreatePixmap(4, cRect(geoManager->channelContentX + 10 + signalX + 1, - signalMeterY + 3, signalWidth, - 2*signalHeight + 3)); + signalMeterY + 3, + signalWidth, + 2 * signalHeight + 3)); pixmapSignalLabel = osd->CreatePixmap(3, - cRect(geoManager->channelContentX + 10 - + geoManager->channelFooterHeight / 2, + cRect(geoManager->channelContentX + 10 + geoManager->channelFooterHeight / 2, signalMeterY + 2, labelWidth, - 2*signalHeight + 3)); + 2 * signalHeight + 3)); pixmapSignalStrength->Fill(Theme.Color(clrProgressBarBack)); pixmapSignalQuality->Fill(Theme.Color(clrProgressBarBack)); pixmapSignalMeter->Fill(clrTransparent); |