summaryrefslogtreecommitdiff
path: root/coreengine
diff options
context:
space:
mode:
authorlouis <louis.braun@gmx.de>2016-06-25 05:43:48 +0200
committerlouis <louis.braun@gmx.de>2016-06-25 05:43:48 +0200
commit3572c27dc98e5d7c52ea1513fa2056d323d7d396 (patch)
treecd825f0fb23c6ebd60c04e17ad25f9d3f6cba1cd /coreengine
parent3b2944496ab488c5e0812ef28d069461dbbdee13 (diff)
downloadvdr-plugin-skindesigner-3572c27dc98e5d7c52ea1513fa2056d323d7d396.tar.gz
vdr-plugin-skindesigner-3572c27dc98e5d7c52ea1513fa2056d323d7d396.tar.bz2
fixed scrolling with centered aligned text
Diffstat (limited to 'coreengine')
-rw-r--r--coreengine/area.c1
-rw-r--r--coreengine/functions.c3
2 files changed, 2 insertions, 2 deletions
diff --git a/coreengine/area.c b/coreengine/area.c
index 6e4beb1..fe96ca2 100644
--- a/coreengine/area.c
+++ b/coreengine/area.c
@@ -528,7 +528,6 @@ void cArea::CreatePixmap(cRect drawPort) {
pix = sdOsd->CreatePixmap(layer, viewPort, drawPort);
if (pix)
pix->Clear();
-
int pixTransparency = attribs->Transparency();
if (pixTransparency > 0) {
SetTransparency(pixTransparency, true);
diff --git a/coreengine/functions.c b/coreengine/functions.c
index 928abf3..35cff67 100644
--- a/coreengine/functions.c
+++ b/coreengine/functions.c
@@ -421,6 +421,7 @@ void cFuncDrawText::Render(cPixmap *p, int x0, int y0, int colWidth, int rowHeig
} else if (horAlign == eAlign::center) {
x = x0 + (contWidth - TextWidth(funcText)) / 2;
}
+ if (x < 0) x = 0;
int contHeight = rowHeight > 0 ? rowHeight : container.Height();
int y = Y() + y0;
@@ -449,7 +450,7 @@ int cFuncDrawText::FuncX(void) {
} else if (horAlign == eAlign::center) {
x = (container.Width() - TextWidth(funcText)) / 2;
}
- return x;
+ return (x >= 0) ? x : 0 ;
}
int cFuncDrawText::FuncY(void) {